Documentation ¶
Index ¶
- func NewCore(mspId string, identity api.Identity, opts ...CoreOpt) (api.Core, error)
- type CoreOpt
- func WithConfigRaw(config config.Config) CoreOpt
- func WithConfigYaml(configPath string) CoreOpt
- func WithContext(ctx context.Context) CoreOpt
- func WithCrypto(cc config.CryptoConfig) CoreOpt
- func WithFabricV2(fabricV2 bool) CoreOpt
- func WithLogger(log *zap.Logger) CoreOpt
- func WithOrderer(orderer api.Orderer) CoreOpt
- func WithPeerPool(pool api.PeerPool) CoreOpt
- func WithPeers(mspID string, peers []config.ConnectionConfig) CoreOpt
- type SeekOptConverter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CoreOpt ¶
type CoreOpt func(c *core) error
CoreOpt describes opt which will be applied to coreOptions
func WithConfigRaw ¶
WithConfigRaw allows to pass to core created config instance
func WithConfigYaml ¶
WithConfigYaml allows to pass path to YAML configuration file
func WithContext ¶
WithContext allows to pass custom context. Otherwise, context.Background is used
func WithCrypto ¶
func WithCrypto(cc config.CryptoConfig) CoreOpt
WithCrypto allows to init core crypto suite.
func WithFabricV2 ¶
WithFabricV2 toggles core to use fabric version 2.
func WithLogger ¶
WithLogger allows to pass custom copy of zap.Logger insteadof logger.DefaultLogger
func WithOrderer ¶
WithOrderer allows to use custom instance of orderer in core
func WithPeerPool ¶
WithPeerPool allows to add custom peer pool
type SeekOptConverter ¶
type SeekOptConverter struct { GetChannelHeight func(ctx context.Context, channel string) (uint64, error) Logger *zap.Logger // contains filtered or unexported fields }
func NewSeekOptConverter ¶
func NewSeekOptConverter(c *core) *SeekOptConverter
func (*SeekOptConverter) ByBlockRange ¶
func (so *SeekOptConverter) ByBlockRange(ctx context.Context, channel string, blockRange ...int64) (api.EventCCSeekOption, error)
func (*SeekOptConverter) ChannelHeight ¶
Click to show internal directories.
Click to hide internal directories.