fn example_emulator_identity() -> Identity {
    // Hci Emulators currently default to address 0
    let emulator_address = Address::Public([0, 0, 0, 0, 0, 0]);

    let host_data = sys::HostData {
        irk: Some(sys::Key { value: [16, 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1] }),
    };
    let csrk = sys::PeerKey {
        data: sys::Key { value: [0; 16] },
        security: sys::SecurityProperties {
            authenticated: false,
            secure_connections: true,
            encryption_key_size: 0,
        },
    };
    let le_data = LeData {
        address: emulator_address,
        connection_parameters: None,
        services: vec![],
        ltk: None,
        irk: None,
        csrk: Some(csrk),
    };
    let bonds = vec![BondingData {
        identifier: PeerId(42),
        local_address: emulator_address,
        name: None,
        data: OneOrBoth::Left(le_data),
    }];
    Identity { host: host_data, bonds }
}
/// An example identity for an Hci Emulator backed host
An example identity for an Hci Emulator backed host
An example identity for an Hci Emulator backed host
fn example_emulator_identity() -> Identity {
    // Hci Emulators currently default to address 0
    let emulator_address = Address::Public([0, 0, 0, 0, 0, 0]);
    let host_data = sys::HostData {
        irk: Some(sys::Key { value: [16, 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1] }),
    };
    let csrk = sys::PeerKey {
        data: sys::Key { value: [0; 16] },
        security: sys::SecurityProperties {
            authenticated: false,
            secure_connections: true,
            encryption_key_size: 0,
        },
    };
    let le_data = LeData {
        address: emulator_address,
        connection_parameters: None,
        services: vec![],
        ltk: None,
        irk: None,
        csrk: Some(csrk),
    };
    let bonds = vec![BondingData {
        identifier: PeerId(42),
        local_address: emulator_address,
        name: None,
        data: OneOrBoth::Left(le_data),
    }];
    Identity { host: host_data, bonds }
}
fn example_emulator_identity ( ) -> Identity { // Hci Emulators currently default to address 0 let emulator_address = Address :: Public ( [ 0 , 0 , 0 , 0 , 0 , 0 ] ) ; let host_data = sys :: HostData { irk : Some ( sys :: Key { value : [ 16 , 15 , 14 , 13 , 12 , 11 , 10 , 9 , 8 , 7 , 6 , 5 , 4 , 3 , 2 , 1 ] } ) , } ; let csrk = sys :: PeerKey { data : sys :: Key { value : [ 0 ; 16 ] } , security : sys :: SecurityProperties { authenticated : false , secure_connections : true , encryption_key_size : 0 , } , } ; let le_data = LeData { address : emulator_address , connection_parameters : None , services : vec ! [ ] , ltk : None , irk : None , csrk : Some ( csrk ) , } ; let bonds = vec ! [ BondingData { identifier PeerId ( 42 ) local_address emulator_address name None data OneOrBoth Left ( le_data ) } ] ; Identity { host : host_data , bonds } }
An example identity for an Hci Emulator backed host
An example identity for an Hci Emulator backed host