Class FormattedColumn<T>
java.lang.Object
org.refcodes.textual.ColumnWidthMetrics
org.refcodes.textual.ColumnFormatMetrics
org.refcodes.textual.ColumnSetupMetrics
org.refcodes.tabular.FormattedColumn<T>
- Type Parameters:
T- The type managed by theFormattedColumn.
- All Implemented Interfaces:
org.refcodes.graphical.VisibleAccessor,org.refcodes.graphical.VisibleAccessor.VisibleBuilder<org.refcodes.textual.ColumnSetupMetrics>,org.refcodes.graphical.VisibleAccessor.VisibleMutator,org.refcodes.graphical.VisibleAccessor.VisibleProperty,org.refcodes.mixin.ColumnWidthAccessor,org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthBuilder<org.refcodes.textual.ColumnWidthMetrics>,org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthMutator,org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthProperty,org.refcodes.mixin.KeyAccessor<String>,org.refcodes.mixin.NameAccessor,org.refcodes.mixin.NameAccessor.NameBuilder<org.refcodes.textual.ColumnSetupMetrics>,org.refcodes.mixin.NameAccessor.NameMutator,org.refcodes.mixin.NameAccessor.NameProperty,org.refcodes.mixin.TypeAccessor<T>,Column<T>,org.refcodes.textual.HorizAlignTextModeAccessor.HorizAlignTextModeBuilder<org.refcodes.textual.ColumnFormatMetrics>,org.refcodes.textual.HorizAlignTextModeAccessor.HorizAlignTextModeMutator,org.refcodes.textual.MoreTextModeAccessor.MoreTextModeBuilder<org.refcodes.textual.ColumnFormatMetrics>,org.refcodes.textual.MoreTextModeAccessor.MoreTextModeMutator,org.refcodes.textual.SplitTextModeAccessor.SplitTextModeBuilder<org.refcodes.textual.ColumnFormatMetrics>,org.refcodes.textual.SplitTextModeAccessor.SplitTextModeMutator,org.refcodes.textual.TextFormatModeAccessor.TextFormatModeBuilder<org.refcodes.textual.ColumnFormatMetrics>,org.refcodes.textual.TextFormatModeAccessor.TextFormatModeMutator
public class FormattedColumn<T>
extends org.refcodes.textual.ColumnSetupMetrics
implements Column<T>
The
FormattedColumn class enriches a Column with
rendering metrics (as of the ColumnSetupMetrics) mostly for
text-based output such as for generating output for a terminal / console.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.refcodes.mixin.ColumnWidthAccessor
org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthBuilder<B extends org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthBuilder<B>>, org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthMutator, org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthPropertyNested classes/interfaces inherited from interface org.refcodes.mixin.KeyAccessor
org.refcodes.mixin.KeyAccessor.KeyBuilder<K,B extends org.refcodes.mixin.KeyAccessor.KeyBuilder<K, B>>, org.refcodes.mixin.KeyAccessor.KeyMutator<K>, org.refcodes.mixin.KeyAccessor.KeyProperty<K> Nested classes/interfaces inherited from interface org.refcodes.mixin.NameAccessor
org.refcodes.mixin.NameAccessor.NameBuilder<B extends org.refcodes.mixin.NameAccessor.NameBuilder<B>>, org.refcodes.mixin.NameAccessor.NameMutator, org.refcodes.mixin.NameAccessor.NamePropertyNested classes/interfaces inherited from interface org.refcodes.mixin.TypeAccessor
org.refcodes.mixin.TypeAccessor.TypeBuilder<T,B extends org.refcodes.mixin.TypeAccessor.TypeBuilder<T, B>>, org.refcodes.mixin.TypeAccessor.TypeMutator<T>, org.refcodes.mixin.TypeAccessor.TypeProperty<T> Nested classes/interfaces inherited from interface org.refcodes.graphical.VisibleAccessor
org.refcodes.graphical.VisibleAccessor.VisibleBuilder<B extends org.refcodes.graphical.VisibleAccessor.VisibleBuilder<B>>, org.refcodes.graphical.VisibleAccessor.VisibleMutator, org.refcodes.graphical.VisibleAccessor.VisibleProperty -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedFormattedColumn(String aKey, Class<T> aType) Instantiates a new formatted column decorator.FormattedColumn(String aKey, Class<T> aType, org.refcodes.textual.ColumnSetupMetrics aColumnSetupMetrics) Wrapper for the providedColumnSetupMetricsdecorating it with additionalColumnfunctionality.FormattedColumn(Column<T> aColumn) Wrapper for the providedColumndecorating it with additionalColumnSetupMetricsfunctionality.FormattedColumn(Column<T> aColumn, org.refcodes.textual.ColumnSetupMetrics aColumnSetupMetrics) Wrapper for the providedColumnand the providedColumnSetupMetricsdecorating it with each other's additional functionality. -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidfromColumnFormatMetrics(org.refcodes.textual.ColumnFormatMetrics aColumnFormatMetrics) voidfromColumnSetupMetrics(org.refcodes.textual.ColumnSetupMetrics aColumnSetupMetrics) voidfromColumnWidthMetrics(org.refcodes.textual.ColumnWidthMetrics aColumnWidthMetrics) fromStorageString(String aStringValue) AColumnimplementation can provide its own text exchange format for the given objects.fromStorageStrings(String[] aStringArray) AColumnimplementation can provide its own text exchange format for the given objects.intorg.refcodes.textual.ColumnWidthTypeorg.refcodes.textual.EscapeCodeFactoryorg.refcodes.textual.HorizAlignTextModeorg.refcodes.textual.MoreTextModeorg.refcodes.textual.SplitTextModeorg.refcodes.textual.TextFormatModegetKey()getName()org.refcodes.textual.EscapeCodeFactoryorg.refcodes.textual.HorizAlignTextModeorg.refcodes.textual.MoreTextModeorg.refcodes.textual.SplitTextModeorg.refcodes.textual.TextFormatModegetType()voidhide()booleanvoidsetColumnWidth(int aColumnWidth) voidsetColumnWidthType(org.refcodes.textual.ColumnWidthType aColumnWidthType) voidsetEscapeCode(String aEscapeCode) voidsetEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) voidsetHeaderEscapeCode(String aEscapeCode) voidsetHeaderEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) voidsetHeaderHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) voidsetHeaderMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) voidsetHeaderSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) voidsetHeaderTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) voidsetHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) voidsetMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) voidvoidsetRowEscapeCode(String aEscapeCode) voidsetRowEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) voidsetRowHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) voidsetRowMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) voidsetRowSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) voidsetRowTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) voidsetSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) voidsetTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) voidsetVisible(boolean isVisible) voidshow()toHeaderEscapeCode(Object aIdentifier) toPrintable(T aValue) AColumnimplementation can provide its own printable format of the given objects; for example a human readable text representation of the value (or in very https://www.metacodes.proized cases even enriched with ANSI escape codes).toRowEscapeCode(Object aIdentifier) toStorageString(T aValue) AColumnimplementation can provide its own text exchange format for the given objects.String[]toStorageStrings(T aValue) AColumnimplementation can provide its own text exchange format for the given objects.org.refcodes.textual.ColumnSetupMetricswithColumnWidth(int aColumnWidth) org.refcodes.textual.ColumnSetupMetricswithColumnWidthType(org.refcodes.textual.ColumnWidthType aColumnWidthType) org.refcodes.textual.ColumnSetupMetricswithEscapeCode(String aEscapeCode) org.refcodes.textual.ColumnSetupMetricswithEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) org.refcodes.textual.ColumnSetupMetricswithHeaderEscapeCode(String aEscapeCode) org.refcodes.textual.ColumnSetupMetricswithHeaderEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) org.refcodes.textual.ColumnSetupMetricswithHeaderHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) org.refcodes.textual.ColumnSetupMetricswithHeaderMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) org.refcodes.textual.ColumnSetupMetricswithHeaderSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) org.refcodes.textual.ColumnSetupMetricswithHeaderTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) org.refcodes.textual.ColumnSetupMetricswithHide()org.refcodes.textual.ColumnSetupMetricswithHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) org.refcodes.textual.ColumnSetupMetricswithMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) org.refcodes.textual.ColumnSetupMetricsorg.refcodes.textual.ColumnSetupMetricswithRowEscapeCode(String aEscapeCode) org.refcodes.textual.ColumnSetupMetricswithRowEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) org.refcodes.textual.ColumnSetupMetricswithRowHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) org.refcodes.textual.ColumnSetupMetricswithRowMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) org.refcodes.textual.ColumnSetupMetricswithRowSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) org.refcodes.textual.ColumnSetupMetricswithRowTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) org.refcodes.textual.ColumnSetupMetricswithShow()org.refcodes.textual.ColumnSetupMetricswithSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) org.refcodes.textual.ColumnSetupMetricswithTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) org.refcodes.textual.ColumnSetupMetricswithVisible(boolean isVisible) Methods inherited from class org.refcodes.textual.ColumnWidthMetrics
toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.refcodes.tabular.Column
getValue, toStorageString_Methods inherited from interface org.refcodes.mixin.ColumnWidthAccessor.ColumnWidthProperty
letColumnWidthMethods inherited from interface org.refcodes.mixin.NameAccessor.NameProperty
letNameMethods inherited from interface org.refcodes.graphical.VisibleAccessor.VisibleProperty
letVisible
-
Constructor Details
-
FormattedColumn
-
FormattedColumn
-
FormattedColumn
public FormattedColumn(String aKey, Class<T> aType, org.refcodes.textual.ColumnSetupMetrics aColumnSetupMetrics) Wrapper for the providedColumnSetupMetricsdecorating it with additionalColumnfunctionality.- Parameters:
aKey- The key for theColumn.aType- The type to be used.aColumnSetupMetrics- TheColumnSetupMetricsto be decorated.
-
FormattedColumn
public FormattedColumn(Column<T> aColumn, org.refcodes.textual.ColumnSetupMetrics aColumnSetupMetrics) Wrapper for the providedColumnand the providedColumnSetupMetricsdecorating it with each other's additional functionality.- Parameters:
aColumn- TheColumnto be decorated.aColumnSetupMetrics- TheColumnSetupMetricsto be decorated.
-
-
Method Details
-
getName
- Specified by:
getNamein interfaceorg.refcodes.mixin.NameAccessor- Overrides:
getNamein classorg.refcodes.textual.ColumnSetupMetrics
-
isVisible
public boolean isVisible()- Specified by:
isVisiblein interfaceorg.refcodes.graphical.VisibleAccessor- Overrides:
isVisiblein classorg.refcodes.textual.ColumnSetupMetrics
-
getColumnWidth
public int getColumnWidth()- Specified by:
getColumnWidthin interfaceorg.refcodes.mixin.ColumnWidthAccessor- Overrides:
getColumnWidthin classorg.refcodes.textual.ColumnWidthMetrics
-
withVisible
public org.refcodes.textual.ColumnSetupMetrics withVisible(boolean isVisible) - Specified by:
withVisiblein interfaceorg.refcodes.graphical.VisibleAccessor.VisibleBuilder<T>- Overrides:
withVisiblein classorg.refcodes.textual.ColumnSetupMetrics
-
setName
- Specified by:
setNamein interfaceorg.refcodes.mixin.NameAccessor.NameMutator- Overrides:
setNamein classorg.refcodes.textual.ColumnSetupMetrics
-
setVisible
public void setVisible(boolean isVisible) - Specified by:
setVisiblein interfaceorg.refcodes.graphical.VisibleAccessor.VisibleMutator- Overrides:
setVisiblein classorg.refcodes.textual.ColumnSetupMetrics
-
setColumnWidth
public void setColumnWidth(int aColumnWidth) - Specified by:
setColumnWidthin interfaceorg.refcodes.mixin.ColumnWidthAccessor.ColumnWidthMutator- Overrides:
setColumnWidthin classorg.refcodes.textual.ColumnWidthMetrics
-
withName
-
withColumnWidth
public org.refcodes.textual.ColumnSetupMetrics withColumnWidth(int aColumnWidth) - Specified by:
withColumnWidthin interfaceorg.refcodes.mixin.ColumnWidthAccessor.ColumnWidthBuilder<T>- Overrides:
withColumnWidthin classorg.refcodes.textual.ColumnSetupMetrics
-
show
public void show()- Specified by:
showin interfaceorg.refcodes.graphical.VisibleAccessor.VisibleMutator
-
withShow
public org.refcodes.textual.ColumnSetupMetrics withShow()- Specified by:
withShowin interfaceorg.refcodes.graphical.VisibleAccessor.VisibleBuilder<T>- Overrides:
withShowin classorg.refcodes.textual.ColumnSetupMetrics
-
getColumnWidthType
public org.refcodes.textual.ColumnWidthType getColumnWidthType()- Overrides:
getColumnWidthTypein classorg.refcodes.textual.ColumnWidthMetrics
-
hide
public void hide()- Specified by:
hidein interfaceorg.refcodes.graphical.VisibleAccessor.VisibleMutator
-
withHide
public org.refcodes.textual.ColumnSetupMetrics withHide()- Specified by:
withHidein interfaceorg.refcodes.graphical.VisibleAccessor.VisibleBuilder<T>- Overrides:
withHidein classorg.refcodes.textual.ColumnSetupMetrics
-
withEscapeCode
- Overrides:
withEscapeCodein classorg.refcodes.textual.ColumnSetupMetrics
-
setColumnWidthType
public void setColumnWidthType(org.refcodes.textual.ColumnWidthType aColumnWidthType) - Overrides:
setColumnWidthTypein classorg.refcodes.textual.ColumnWidthMetrics
-
withHeaderEscapeCode
- Overrides:
withHeaderEscapeCodein classorg.refcodes.textual.ColumnSetupMetrics
-
fromColumnWidthMetrics
public void fromColumnWidthMetrics(org.refcodes.textual.ColumnWidthMetrics aColumnWidthMetrics) - Overrides:
fromColumnWidthMetricsin classorg.refcodes.textual.ColumnWidthMetrics
-
withRowEscapeCode
- Overrides:
withRowEscapeCodein classorg.refcodes.textual.ColumnSetupMetrics
-
withColumnWidthType
public org.refcodes.textual.ColumnSetupMetrics withColumnWidthType(org.refcodes.textual.ColumnWidthType aColumnWidthType) - Overrides:
withColumnWidthTypein classorg.refcodes.textual.ColumnSetupMetrics
-
withHorizAlignTextMode
public org.refcodes.textual.ColumnSetupMetrics withHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) - Specified by:
withHorizAlignTextModein interfaceorg.refcodes.textual.HorizAlignTextModeAccessor.HorizAlignTextModeBuilder<T>- Overrides:
withHorizAlignTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withHeaderHorizAlignTextMode
public org.refcodes.textual.ColumnSetupMetrics withHeaderHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) - Overrides:
withHeaderHorizAlignTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withRowHorizAlignTextMode
public org.refcodes.textual.ColumnSetupMetrics withRowHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) - Overrides:
withRowHorizAlignTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withMoreTextMode
public org.refcodes.textual.ColumnSetupMetrics withMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) - Specified by:
withMoreTextModein interfaceorg.refcodes.textual.MoreTextModeAccessor.MoreTextModeBuilder<T>- Overrides:
withMoreTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withHeaderMoreTextMode
public org.refcodes.textual.ColumnSetupMetrics withHeaderMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) - Overrides:
withHeaderMoreTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
setEscapeCodeFactory
public void setEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) - Overrides:
setEscapeCodeFactoryin classorg.refcodes.textual.ColumnFormatMetrics
-
withRowMoreTextMode
public org.refcodes.textual.ColumnSetupMetrics withRowMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) - Overrides:
withRowMoreTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withTextFormatMode
public org.refcodes.textual.ColumnSetupMetrics withTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) - Specified by:
withTextFormatModein interfaceorg.refcodes.textual.TextFormatModeAccessor.TextFormatModeBuilder<T>- Overrides:
withTextFormatModein classorg.refcodes.textual.ColumnSetupMetrics
-
withSplitTextMode
public org.refcodes.textual.ColumnSetupMetrics withSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) - Specified by:
withSplitTextModein interfaceorg.refcodes.textual.SplitTextModeAccessor.SplitTextModeBuilder<T>- Overrides:
withSplitTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withHeaderSplitTextMode
public org.refcodes.textual.ColumnSetupMetrics withHeaderSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) - Overrides:
withHeaderSplitTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withRowSplitTextMode
public org.refcodes.textual.ColumnSetupMetrics withRowSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) - Overrides:
withRowSplitTextModein classorg.refcodes.textual.ColumnSetupMetrics
-
withHeaderTextFormatMode
public org.refcodes.textual.ColumnSetupMetrics withHeaderTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) - Overrides:
withHeaderTextFormatModein classorg.refcodes.textual.ColumnSetupMetrics
-
withRowTextFormatMode
public org.refcodes.textual.ColumnSetupMetrics withRowTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) - Overrides:
withRowTextFormatModein classorg.refcodes.textual.ColumnSetupMetrics
-
withEscapeCodeFactory
public org.refcodes.textual.ColumnSetupMetrics withEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) - Overrides:
withEscapeCodeFactoryin classorg.refcodes.textual.ColumnSetupMetrics
-
setHeaderEscapeCodeFactory
public void setHeaderEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) - Overrides:
setHeaderEscapeCodeFactoryin classorg.refcodes.textual.ColumnFormatMetrics
-
withHeaderEscapeCodeFactory
public org.refcodes.textual.ColumnSetupMetrics withHeaderEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) - Overrides:
withHeaderEscapeCodeFactoryin classorg.refcodes.textual.ColumnSetupMetrics
-
withRowEscapeCodeFactory
public org.refcodes.textual.ColumnSetupMetrics withRowEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) - Overrides:
withRowEscapeCodeFactoryin classorg.refcodes.textual.ColumnSetupMetrics
-
getHeaderEscapeCodeFactory
public org.refcodes.textual.EscapeCodeFactory getHeaderEscapeCodeFactory()- Overrides:
getHeaderEscapeCodeFactoryin classorg.refcodes.textual.ColumnFormatMetrics
-
fromColumnSetupMetrics
public void fromColumnSetupMetrics(org.refcodes.textual.ColumnSetupMetrics aColumnSetupMetrics) - Overrides:
fromColumnSetupMetricsin classorg.refcodes.textual.ColumnSetupMetrics
-
toHeaderEscapeCode
-
setRowEscapeCodeFactory
public void setRowEscapeCodeFactory(org.refcodes.textual.EscapeCodeFactory aEscapeCodeFactory) - Overrides:
setRowEscapeCodeFactoryin classorg.refcodes.textual.ColumnFormatMetrics
-
getRowEscapeCodeFactory
public org.refcodes.textual.EscapeCodeFactory getRowEscapeCodeFactory()- Overrides:
getRowEscapeCodeFactoryin classorg.refcodes.textual.ColumnFormatMetrics
-
toRowEscapeCode
-
setEscapeCode
- Overrides:
setEscapeCodein classorg.refcodes.textual.ColumnFormatMetrics
-
setHeaderEscapeCode
- Overrides:
setHeaderEscapeCodein classorg.refcodes.textual.ColumnFormatMetrics
-
getHeaderEscapeCode
- Overrides:
getHeaderEscapeCodein classorg.refcodes.textual.ColumnFormatMetrics
-
setRowEscapeCode
- Overrides:
setRowEscapeCodein classorg.refcodes.textual.ColumnFormatMetrics
-
getRowEscapeCode
- Overrides:
getRowEscapeCodein classorg.refcodes.textual.ColumnFormatMetrics
-
setHorizAlignTextMode
public void setHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) - Specified by:
setHorizAlignTextModein interfaceorg.refcodes.textual.HorizAlignTextModeAccessor.HorizAlignTextModeMutator- Overrides:
setHorizAlignTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setHeaderHorizAlignTextMode
public void setHeaderHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) - Overrides:
setHeaderHorizAlignTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
getHeaderHorizAlignTextMode
public org.refcodes.textual.HorizAlignTextMode getHeaderHorizAlignTextMode()- Overrides:
getHeaderHorizAlignTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setRowHorizAlignTextMode
public void setRowHorizAlignTextMode(org.refcodes.textual.HorizAlignTextMode aHorizAlignTextMode) - Overrides:
setRowHorizAlignTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
getRowHorizAlignTextMode
public org.refcodes.textual.HorizAlignTextMode getRowHorizAlignTextMode()- Overrides:
getRowHorizAlignTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setMoreTextMode
public void setMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) - Specified by:
setMoreTextModein interfaceorg.refcodes.textual.MoreTextModeAccessor.MoreTextModeMutator- Overrides:
setMoreTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setHeaderMoreTextMode
public void setHeaderMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) - Overrides:
setHeaderMoreTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
getHeaderMoreTextMode
public org.refcodes.textual.MoreTextMode getHeaderMoreTextMode()- Overrides:
getHeaderMoreTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setRowMoreTextMode
public void setRowMoreTextMode(org.refcodes.textual.MoreTextMode aMoreTextMode) - Overrides:
setRowMoreTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
getRowMoreTextMode
public org.refcodes.textual.MoreTextMode getRowMoreTextMode()- Overrides:
getRowMoreTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setTextFormatMode
public void setTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) - Specified by:
setTextFormatModein interfaceorg.refcodes.textual.TextFormatModeAccessor.TextFormatModeMutator- Overrides:
setTextFormatModein classorg.refcodes.textual.ColumnFormatMetrics
-
setSplitTextMode
public void setSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) - Specified by:
setSplitTextModein interfaceorg.refcodes.textual.SplitTextModeAccessor.SplitTextModeMutator- Overrides:
setSplitTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setHeaderSplitTextMode
public void setHeaderSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) - Overrides:
setHeaderSplitTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
getHeaderSplitTextMode
public org.refcodes.textual.SplitTextMode getHeaderSplitTextMode()- Overrides:
getHeaderSplitTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setRowSplitTextMode
public void setRowSplitTextMode(org.refcodes.textual.SplitTextMode aSplitTextMode) - Overrides:
setRowSplitTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
getRowSplitTextMode
public org.refcodes.textual.SplitTextMode getRowSplitTextMode()- Overrides:
getRowSplitTextModein classorg.refcodes.textual.ColumnFormatMetrics
-
setHeaderTextFormatMode
public void setHeaderTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) - Overrides:
setHeaderTextFormatModein classorg.refcodes.textual.ColumnFormatMetrics
-
getHeaderTextFormatMode
public org.refcodes.textual.TextFormatMode getHeaderTextFormatMode()- Overrides:
getHeaderTextFormatModein classorg.refcodes.textual.ColumnFormatMetrics
-
setRowTextFormatMode
public void setRowTextFormatMode(org.refcodes.textual.TextFormatMode aTextFormatMode) - Overrides:
setRowTextFormatModein classorg.refcodes.textual.ColumnFormatMetrics
-
getRowTextFormatMode
public org.refcodes.textual.TextFormatMode getRowTextFormatMode()- Overrides:
getRowTextFormatModein classorg.refcodes.textual.ColumnFormatMetrics
-
fromColumnFormatMetrics
public void fromColumnFormatMetrics(org.refcodes.textual.ColumnFormatMetrics aColumnFormatMetrics) - Overrides:
fromColumnFormatMetricsin classorg.refcodes.textual.ColumnFormatMetrics
-
getType
-
getKey
-
toStorageString
AColumnimplementation can provide its own text exchange format for the given objects. This method enables theColumnto convert a value of the given type to aStringand viaColumn.fromStorageString(String)back to the value (bijective). This method supports data sinks (such as relational databases) which allow only a single value in a row's entry: In case T is an array type, then the storageStringrepresentation of the elements in that array are represented by a single returnedString. Question: Why does the detour through the methodColumn.toStorageString(Object)not function?!? Having this snippet in the code seems to be fine for the compiler ... tryingColumn.toStorageString_(Object)instead :-( In case a data sink (such as Amazon's SimpleDb) is to be addressed which provides dedicated support for multiple values in one row's entry, then the methodColumn.toStorageStrings(Object)may be used instead.- Specified by:
toStorageStringin interfaceColumn<T>- Parameters:
aValue- the element to be converted to aString.- Returns:
- The
Stringrepresentation of the value.
-
toStorageStrings
AColumnimplementation can provide its own text exchange format for the given objects. This method enables theColumnto convert a value of the given type to aStringarray and viaColumn.fromStorageStrings(String[])back to the value (bijective). This method supports data sinks (such as Amazon's SimpleDb) which provide dedicated support for multiple values in a row's entry: In case T is an array type, then the storageStringrepresentations of the elements in that array may be placed in dedicated entries of the returnedStringarray. In case T is not an array type then the returnedStringarray may contain just one value. In case data sinks (such as relational databases) are to be addressed which allow only a single value in a row's entry, then the methodColumn.toStorageString(Object)may be used instead.- Specified by:
toStorageStringsin interfaceColumn<T>- Parameters:
aValue- the element to be converted to aStringarray.- Returns:
- The
Stringarray representation of the value.
-
fromStorageString
AColumnimplementation can provide its own text exchange format for the given objects. This method enables theColumnto convert aStringvalue to a value of the given type and viaColumn.toStorageString(Object)back to theString(bijective). This method supports data sinks (such as relational databases) which allow only a single value in a row's entry: In case T is an array type, then the storageStringrepresentation of the elements in that array are represented by the single passedString. In case a data sink (such as Amazon's SimpleDb) is to be addressed which provides dedicated support for multiple values in one row's entry, then the methodColumn.fromStorageStrings(String[])may be used instead.- Specified by:
fromStorageStringin interfaceColumn<T>- Parameters:
aStringValue- The value to be converted to a type instance.- Returns:
- The type representation of the value.
- Throws:
ParseException- in case parsing theStringwas not possible
-
fromStorageStrings
AColumnimplementation can provide its own text exchange format for the given objects. This method enables theColumnto convert aStringarray value to a value of the given type and viaColumn.toStorageStrings(Object)back to theStringarray (bijective). This method supports data sinks (such as Amazon's SimpleDb) which provide dedicated support for multiple values in a row's entry: In case T is an array type, then the storageStringrepresentations of the elements in that array may be placed in dedicated entries of the providedStringarray. In case T is not an array type then the passedStringarray may contain just one value. In case data sinks (such as relational databases) are to be addressed which allow only a single value in a row's entry, then the methodColumn.fromStorageString(String)may be used instead.- Specified by:
fromStorageStringsin interfaceColumn<T>- Parameters:
aStringArray- The value to be converted to a type instance.- Returns:
- The type representation of the value.
- Throws:
ParseException- in case parsing theStringwas not possible
-
toPrintable
AColumnimplementation can provide its own printable format of the given objects; for example a human readable text representation of the value (or in very https://www.metacodes.proized cases even enriched with ANSI escape codes). This method enables theColumnto convert a value of the given type to a human readable text. The human readable text, in comparison to the methodObject.toString()(orColumn.toStorageString(Object)) is not intended to be converted back to the actual value (not bijective). This method may be used aHeaderinstance's methodHeaderRow.toPrintable(Record).- Specified by:
toPrintablein interfaceColumn<T>- Parameters:
aValue- the element to be converted to a human readable text.- Returns:
- The human readable representation of the value.
-
contains
Tests whether theRecordcontains a value identified by theColumninstance's key and where the value's type is assignable to theColumninstance's type. Only if them both criteria match, then true is returned. False is returned if there is no such value or the value is not assignable to theColumninstance's type.- Specified by:
containsin interfaceColumn<T>- Parameters:
aRecord- TheRecordwhich to test if there is a value associated to theColumninstance's key and if it can be casted to theColumninstance's type.- Returns:
- True in case the
Recordcontains a value identified by theColumninstance's key and where the value's type is assignable to theColumninstance's type.
-
get
Retrieves a type correct value from theRecordidentified by theColumninstance's key. In case the type of theColumninstance does not match the value's type associated with theColumninstance's key, then aColumnMismatchExceptionis thrown.- Specified by:
getin interfaceColumn<T>- Parameters:
aRecord- TheRecordfrom which to retrieve the value associated to theColumninstances key.- Returns:
- The value from the
Recordassociated to theColumninstances key. - Throws:
ColumnMismatchException- in case the value in theRecordassociated with theColumninstance's key does not fit theColumninstance's type.
-
remove
Removes an entry (key and value pair) from the providedRecordmatching the key and the type of theColumn.- Specified by:
removein interfaceColumn<T>- Parameters:
aRecord- TheRecordfrom which to remove the related entry.- Returns:
- The value related to the given
Columninstance's key or null if there was none such value found. - Throws:
ColumnMismatchException- in case the value in theRecordassociated with theColumninstance's key does not fit theColumninstance's type.
-