Documentation ¶
Index ¶
- type Controller
- type FabricSetup
- type PeerController
- func (p *PeerController) InvokeCreateResource(request rest_resources.CreateResourceRequest) rest_resources.CreateResourceResponse
- func (p *PeerController) InvokeGetResource(request rest_resources.GetResourceRequest) rest_resources.GetResourceResponse
- func (p *PeerController) InvokeQuery(request rest_resources.QueryRequest) rest_resources.QueryResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Controller ¶
type Controller interface { InvokeCreateResource(resources.CreateResourceRequest) resources.CreateResourceResponse InvokeGetResource(resources.GetResourceRequest) resources.GetResourceResponse InvokeQuery(resources.QueryRequest) resources.QueryResponse }
Controller to run invoke and queries on chaincode
func NewPeerController ¶
func NewPeerController(c context.Context, l *log.Logger, setup FabricSetup) Controller
func NewPeerControllerWithExecutor ¶
func NewPeerControllerWithExecutor(c context.Context, l *log.Logger, setup FabricSetup, exec utils.Executor) Controller
type FabricSetup ¶
type FabricSetup struct { ConfigFile string OrgID string OrdererID string OrdererURL string ChannelID string ChainCodeID string ChannelConfig string ChaincodeGoPath string ChaincodePath string OrgAdmin string OrgName string UserName string // contains filtered or unexported fields }
FabricSetup implementation
func (*FabricSetup) Initialize ¶
func (setup *FabricSetup) Initialize() error
Initialize reads the configuration file and sets up the client, chain and event hub
func (*FabricSetup) InstallAndInstantiateCC ¶
func (setup *FabricSetup) InstallAndInstantiateCC() error
func (*FabricSetup) InvokeGetBusiness ¶
func (setup *FabricSetup) InvokeGetBusiness(businessID string) (resources.Business, error)
type PeerController ¶
type PeerController struct {
// contains filtered or unexported fields
}
func (*PeerController) InvokeCreateResource ¶
func (p *PeerController) InvokeCreateResource(request rest_resources.CreateResourceRequest) rest_resources.CreateResourceResponse
func (*PeerController) InvokeGetResource ¶
func (p *PeerController) InvokeGetResource(request rest_resources.GetResourceRequest) rest_resources.GetResourceResponse
func (*PeerController) InvokeQuery ¶
func (p *PeerController) InvokeQuery(request rest_resources.QueryRequest) rest_resources.QueryResponse
Click to show internal directories.
Click to hide internal directories.