pub fn init_lending_market(
    program_id: Pubkey,
    owner: Pubkey,
    quote_currency: [u8; 32],
    lending_market_pubkey: Pubkey,
    oracle_program_id: Pubkey,
    switchboard_oracle_program_id: Pubkey,
) -> Instruction {
    Instruction {
        program_id,
        accounts: vec![
            AccountMeta::new(lending_market_pubkey, false),
            AccountMeta::new_readonly(sysvar::rent::id(), false),
            AccountMeta::new_readonly(spl_token::id(), false),
            AccountMeta::new_readonly(oracle_program_id, false),
            AccountMeta::new_readonly(switchboard_oracle_program_id, false),
        ],
        data: LendingInstruction::InitLendingMarket {
            owner,
            quote_currency,
        }
        .pack(),
    }
}
/// Creates an 'InitLendingMarket' instruction.
Creates an 'InitLendingMarket' instruction.
Creates an ' InitLendingMarket ' instruction .
pub fn init_lending_market(
    program_id: Pubkey,
    owner: Pubkey,
    quote_currency: [u8; 32],
    lending_market_pubkey: Pubkey,
    oracle_program_id: Pubkey,
    switchboard_oracle_program_id: Pubkey,
) -> Instruction {
    Instruction {
        program_id,
        accounts: vec![
            AccountMeta::new(lending_market_pubkey, false),
            AccountMeta::new_readonly(sysvar::rent::id(), false),
            AccountMeta::new_readonly(spl_token::id(), false),
            AccountMeta::new_readonly(oracle_program_id, false),
            AccountMeta::new_readonly(switchboard_oracle_program_id, false),
        ],
        data: LendingInstruction::InitLendingMarket {
            owner,
            quote_currency,
        }
        .pack(),
    }
}
pub fn init_lending_market ( program_id : Pubkey , owner : Pubkey , quote_currency : [ u8 ; 32 ] , lending_market_pubkey : Pubkey , oracle_program_id : Pubkey , switchboard_oracle_program_id : Pubkey , ) -> Instruction { Instruction { program_id , accounts : vec ! [ AccountMeta new ( lending_market_pubkey false ) AccountMeta new_readonly ( sysvar rent id ( ) false ) AccountMeta new_readonly ( spl_token id ( ) false ) AccountMeta new_readonly ( oracle_program_id false ) AccountMeta new_readonly ( switchboard_oracle_program_id false ) ] , data : LendingInstruction :: InitLendingMarket { owner , quote_currency , } . pack ( ) , } }
Creates an 'InitLendingMarket' instruction.
Creates an ' InitLendingMarket ' instruction .
program_id
Pubkey
owner
Pubkey
quote_currency
[u8; 32]
lending_market_pubkey
Pubkey
oracle_program_id
Pubkey
switchboard_oracle_program_id
Pubkey
program_id
Pubkey
owner
Pubkey
quote_currency
[u8; 32]
lending_market_pubkey
Pubkey
oracle_program_id
Pubkey
switchboard_oracle_program_id
Pubkey