code: func (p *Property) UnmarshalBinary(data []byte) error {
  	buf := bytes.NewBuffer(data)
  
  	err := binary.Read(buf, binary.LittleEndian, &p.header)
  	if err != nil {
  		return err
  	}
  
  	switch p.header.Kind {
  	case vixPropertyTypeBool:
  		return binary.Read(buf, binary.LittleEndian, &p.data.Bool)
  	case vixPropertyTypeInt32:
  		return binary.Read(buf, binary.LittleEndian, &p.data.Int32)
  	case vixPropertyTypeInt64:
  		return binary.Read(buf, binary.LittleEndian, &p.data.Int64)
  	case vixPropertyTypeString:
  		s := make([]byte, p.header.Length)
  		if _, err := buf.Read(s); err != nil {
  			return err
  		}
  
  		p.data.String = string(bytes.TrimRight(s, "\x00"))
  	case vixPropertyTypeBlob:
  		p.data.Blob = make([]byte, p.header.Length)
  		if _, err := buf.Read(p.data.Blob); err != nil {
  			return err
  		}
  	default:
  		return errors.New("VIX_E_UNRECOGNIZED_PROPERTY")
  	}
  
  	return nil
  }
docs: // UnmarshalBinary implements the encoding.BinaryUnmarshaler interface