mirror of
https://github.com/hyperledger/fabric-samples.git
synced 2026-06-17 23:45:10 +00:00
Created parser, contract and utils packages and extracted each piece of functionality into its own files. Removed "Get" prefix from methods and changed return values from interfaces to structs. Signed-off-by: Stanislav Jakuschevskij <stas@two-giants.com>
16 lines
332 B
Go
16 lines
332 B
Go
package parser
|
|
|
|
import "github.com/hyperledger/fabric-protos-go-apiv2/msp"
|
|
|
|
// Implements identity.Identity Interface
|
|
type identityImpl struct {
|
|
creator *msp.SerializedIdentity
|
|
}
|
|
|
|
func (i *identityImpl) MspID() string {
|
|
return i.creator.GetMspid()
|
|
}
|
|
|
|
func (i *identityImpl) Credentials() []byte {
|
|
return i.creator.GetIdBytes()
|
|
}
|