code: func (s *lockBasedTxSimulator) SetPrivateData(ns, coll, key string, value []byte) error {
  	if err := s.helper.validateCollName(ns, coll); err != nil {
  		return err
  	}
  	if err := s.checkWritePrecondition(key, value); err != nil {
  		return err
  	}
  	s.writePerformed = true
  	s.rwsetBuilder.AddToPvtAndHashedWriteSet(ns, coll, key, value)
  	return nil
  }
docs: // SetPrivateData implements method in interface `ledger.TxSimulator`