'use strict' ; import { IFabricWallet } from './IFabricWallet' ; import { OutputAdapter } from '../logging/OutputAdapter' ; import { FabricSmartContractDefinition } from '../fabricModel/FabricSmartContractDefinition' ; export interface IFabricGatewayConnection { identityName : string ; connect ( wallet , identityName , timeout ) : Promise < void > ; createChannelMap ( ) : Promise < Map < string , Array < string > > > ; disconnect ( ) : void ; getAllPeerNames ( ) : Array < string > ; getAllChannelsForPeer ( peerName ) : Promise < Array < string > > ; getChannelPeersInfo ( channelName ) : Promise < { name : string ; mspID : string ; } [ ] > ; getInstantiatedChaincode ( channelName ) : Promise < Array < FabricSmartContractDefinition > > ; isIBPConnection ( ) : boolean ; getMetadata ( instantiatedChaincodeName , channel ) : Promise < any > ; submitTransaction ( chaincodeName , transactionName , channel , args , namespace , transientData , evaluate ? , peerTargetNames ? ) : Promise < string | undefined > ; addContractListener ( channelName , contractName , eventName , outputAdapter ) : Promise < void > ; getChannelCapabilityFromPeer ( channelName , peerName ) : Promise < Array < string > > ; }