code: func NewMockStub(name string, cc Chaincode) *MockStub {
  	mockLogger.Debug("MockStub(", name, cc, ")")
  	s := new(MockStub)
  	s.Name = name
  	s.cc = cc
  	s.State = make(map[string][]byte)
  	s.PvtState = make(map[string]map[string][]byte)
  	s.EndorsementPolicies = make(map[string]map[string][]byte)
  	s.Invokables = make(map[string]*MockStub)
  	s.Keys = list.New()
  	s.ChaincodeEventsChannel = make(chan *pb.ChaincodeEvent, 100) //define large capacity for non-blocking setEvent calls.
  	s.Decorations = make(map[string][]byte)
  
  	return s
  }
docs: // Constructor to initialise the internal State map