Class Document.Page.Matrix (2.45.0)

public static final class Document.Page.Matrix extends GeneratedMessageV3 implements Document.Page.MatrixOrBuilder

Representation for transformation matrix, intended to be compatible and used with OpenCV format for image manipulation.

Protobuf type google.cloud.documentai.v1.Document.Page.Matrix

Static Fields

COLS_FIELD_NUMBER

public static final int COLS_FIELD_NUMBER
Field Value
TypeDescription
int

DATA_FIELD_NUMBER

public static final int DATA_FIELD_NUMBER
Field Value
TypeDescription
int

ROWS_FIELD_NUMBER

public static final int ROWS_FIELD_NUMBER
Field Value
TypeDescription
int

TYPE_FIELD_NUMBER

public static final int TYPE_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static Document.Page.Matrix getDefaultInstance()
Returns
TypeDescription
Document.Page.Matrix

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static Document.Page.Matrix.Builder newBuilder()
Returns
TypeDescription
Document.Page.Matrix.Builder

newBuilder(Document.Page.Matrix prototype)

public static Document.Page.Matrix.Builder newBuilder(Document.Page.Matrix prototype)
Parameter
NameDescription
prototypeDocument.Page.Matrix
Returns
TypeDescription
Document.Page.Matrix.Builder

parseDelimitedFrom(InputStream input)

public static Document.Page.Matrix parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Document.Page.Matrix parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static Document.Page.Matrix parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static Document.Page.Matrix parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static Document.Page.Matrix parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static Document.Page.Matrix parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static Document.Page.Matrix parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static Document.Page.Matrix parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static Document.Page.Matrix parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Document.Page.Matrix parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static Document.Page.Matrix parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static Document.Page.Matrix parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Document.Page.Matrix
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<Document.Page.Matrix> parser()
Returns
TypeDescription
Parser<Matrix>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getCols()

public int getCols()

Number of columns in the matrix.

int32 cols = 2;

Returns
TypeDescription
int

The cols.

getData()

public ByteString getData()

The matrix data.

bytes data = 4;

Returns
TypeDescription
ByteString

The data.

getDefaultInstanceForType()

public Document.Page.Matrix getDefaultInstanceForType()
Returns
TypeDescription
Document.Page.Matrix

getParserForType()

public Parser<Document.Page.Matrix> getParserForType()
Returns
TypeDescription
Parser<Matrix>
Overrides

getRows()

public int getRows()

Number of rows in the matrix.

int32 rows = 1;

Returns
TypeDescription
int

The rows.

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getType()

public int getType()

This encodes information about what data type the matrix uses. For example, 0 (CV_8U) is an unsigned 8-bit image. For the full list of OpenCV primitive data types, please refer to https://docs.opencv.org/4.3.0/d1/d1b/group__core__hal__interface.html

int32 type = 3;

Returns
TypeDescription
int

The type.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public Document.Page.Matrix.Builder newBuilderForType()
Returns
TypeDescription
Document.Page.Matrix.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected Document.Page.Matrix.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
Document.Page.Matrix.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public Document.Page.Matrix.Builder toBuilder()
Returns
TypeDescription
Document.Page.Matrix.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException