Package org.apache.sysds.runtime.compress.colgroup.scheme

## Interface ICLAScheme

All Known Implementing Classes:
  `ConstScheme`, `DDCScheme`, `EmptyScheme`

    public interface ICLAScheme

Abstract class for a scheme instance. Instances of this class has the purpose of encoding the minimum values required to reproduce a compression scheme, and apply it to unseen data. The reproduced compression scheme should be able to apply to unseen data and multiple instance of data into the same compression plan, and in extension make it possible to continuously extend already compressed data representations. A single scheme is only responsible for encoding a single column group type.

### Field Summary

Fields
`static org.apache.commons.logging.Log` `LOG` Logging access for the CLA Scheme encoders

### Method Summary

All Methods Instance Methods Abstract Methods
`AColGroup` `encode​(MatrixBlock data)` Encode the given matrix block into the scheme provided in the instance.
`AColGroup` `encode​(MatrixBlock data, IColIndex columns)` Encode a given matrix block into the scheme provided in the instance but overwrite what columns to use.

### Field Detail

#### LOG

    static final org.apache.commons.logging.Log LOG

Logging access for the CLA Scheme encoders

### Method Detail

#### encode

    AColGroup encode​(MatrixBlock data)

Encode the given matrix block into the scheme provided in the instance. The method returns null, if it is impossible to encode the input data with the given scheme.

Parameters:
  `data` - The data to encode
Returns:
  A compressed column group or null.

#### encode

    AColGroup encode​(MatrixBlock data,
                     IColIndex columns)

Encode a given matrix block into the scheme provided in the instance but overwrite what columns to use. The method returns null, if it is impossible to encode the input data with the given scheme.

Parameters:
  `data` - The data to encode
  `columns` - The columns to apply the scheme to, but must be of same number than the encoded scheme
Returns:
  A compressed column group or null
Throws:
  `IllegalArgumentException` - In the case the columns argument number of columns doesent corelate with the Schemes list of columns.