org.apache.ignite.internal.binary

## Class BinaryFieldMetadata

- java.lang.Object
- - org.apache.ignite.internal.binary.BinaryFieldMetadata

All Implemented Interfaces:
  Externalizable, Serializable

    public class BinaryFieldMetadata
    extends Object
    implements Externalizable

Binary field metadata.

See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`BinaryFieldMetadata()` For `Externalizable`.
`BinaryFieldMetadata(BinaryFieldAccessor accessor)` Constructor.
`BinaryFieldMetadata(int typeId, int fieldId)` Constructor.

### Method Summary

All Methods Instance Methods Concrete Methods
`int` `fieldId()`
`void` `readExternal(ObjectInput in)`
`void` `readFrom(DataInput in)` The object implements the readFrom method to restore its contents by calling the methods of DataInput for primitive types and strings or calling readExternal for other objects.
`String` `toString()`
`int` `typeId()`
`void` `writeExternal(ObjectOutput out)`
`void` `writeTo(DataOutput out)` The object implements the writeTo method to save its contents by calling the methods of DataOutput for its primitive values and strings or calling the writeTo method for other objects.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### BinaryFieldMetadata

    public BinaryFieldMetadata()

For `Externalizable`.

#### BinaryFieldMetadata

    public BinaryFieldMetadata(int typeId,
                               int fieldId)

Constructor.

Parameters:
  `typeId` - Field type ID.
  `fieldId` - Field id in schema.

#### BinaryFieldMetadata

    public BinaryFieldMetadata(BinaryFieldAccessor accessor)

Constructor.

Parameters:
  `accessor` - Field accessor.

### Method Detail

#### fieldId

    public int fieldId()

Returns:
  Field ID in binary schema.

#### typeId

    public int typeId()

Returns:
  ID of the type of the field.

#### writeExternal

    public void writeExternal(ObjectOutput out)
                       throws IOException

Specified by:
  `writeExternal` in interface `Externalizable`
Throws:
  `IOException`

#### writeTo

    public void writeTo(DataOutput out)
                 throws IOException

The object implements the writeTo method to save its contents by calling the methods of DataOutput for its primitive values and strings or calling the writeTo method for other objects.

Parameters:
  `out` - the stream to write the object to.
Throws:
  `IOException` - Includes any I/O exceptions that may occur.

#### readExternal

    public void readExternal(ObjectInput in)
                      throws IOException,
                             ClassNotFoundException

Specified by:
  `readExternal` in interface `Externalizable`
Throws:
  `IOException`
  `ClassNotFoundException`

#### readFrom

    public void readFrom(DataInput in)
                  throws IOException

The object implements the readFrom method to restore its contents by calling the methods of DataInput for primitive types and strings or calling readExternal for other objects. The readFrom method must read the values in the same sequence and with the same types as were written by writeTo.

Parameters:
  `in` - the stream to read data from in order to restore the object.
Throws:
  `IOException` - if I/O errors occur.

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

${current.year} Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.7.6
Release Date | : September 11 2019