public class FwkColumnAccess extends FwkInfoBusDataAccess implements FwkColumnAccessInterface
Property Keyword | Datatype | Default | Description |
---|---|---|---|
FwkColumnAccessInterface.ConsiderFlags | boolean | false | This flag is used to control whether the column consider the flag value. |
,
Serialized FormModifier and Type | Class and Description |
---|---|
class |
FwkColumnAccess.FwkSubColumnAccess |
FwkInfoBusImmediateAccess.ElementConsumer
Modifier and Type | Field and Description |
---|---|
protected double |
average |
protected boolean |
averageIsValid |
protected java.lang.String |
columnName |
static boolean |
CONSIDER_FLAGS
The flags that decides whether the flags should be considered.
|
static java.lang.String[] |
DESCRIPTION_COLUMN_NAME
The description column header names.
|
protected static FwkIconInterface |
icon |
protected double |
lower |
protected double |
minPositiveValue |
protected FwkColumnDataObserverInterface |
observer |
protected javax.infobus.InfoBusDataProducer |
producer |
protected java.lang.Object |
range_lock |
protected boolean |
rangeIsValid |
protected java.lang.String |
shortName |
protected double |
standardDeviation |
protected boolean |
standardDeviationIsValid |
protected java.lang.String |
unit |
protected double |
upper |
static java.lang.String |
version |
children, properties, valid
changeManager, suspendChangeManager
source
author, buildnr, className, company, copyright, creationDate, dateFormatString, description, eMail, FWK_ICON, FWK_ICON_ARRAY, FWK_ICON_BG, FWK_ICON_BG_ARRAY, FWK_ICON_BG_LARGE, FWK_ICON_BG_LARGE_ARRAY, FWK_ICON_LARGE, FWK_ICON_LARGE_ARRAY, ICON, iconCount, iconKey, internetAddress, name, titleName
DATAARRAY_KEY, DEFINED_BIT, INVALID, NOT_MODIFIED_BIT, VALID, VALID_BIT, VISIBLE_BIT
AUTHOR, BUILDNR, COMPANY, COPYRIGHT, DATE_FORMAT, DEFAULT_ICON, DESCRIPTION, INTERNET, LARGE_ICON, LARGE_KEY_EXT, LARGE_OPAQUE_ICON, LARGE_OPAQUE_KEY_EXT, OPAQUE_ICON, OPAQUE_KEY_EXT, RCS_DATE_FORMAT, SUPPORT_EMAIL, TITLE_NAME
INFOBUS_SOURCE
Modifier | Constructor and Description |
---|---|
protected |
FwkColumnAccess()
A private default constructor.
|
|
FwkColumnAccess(java.lang.String name,
java.lang.String columnName,
java.lang.String unit,
FwkColumnDataObserverInterface observer)
The constructor receiving the value matrix and its name.
|
|
FwkColumnAccess(java.lang.String name,
java.lang.String columnName,
java.lang.String unit,
short[] flags,
double[] values)
The constructor receiving the value matrix and its name.
|
Modifier and Type | Method and Description |
---|---|
static FwkColumnAccessInterface |
createEmptyColumn(java.lang.String name)
Create an empty column.
|
java.lang.String[] |
dependsOn()
Retrieves a string array containing the dependant channels.
|
protected void |
determineRange()
Determine the lower and upper limits of the column.
|
double |
getAverage()
Returns the average of the column data.
|
short |
getAverageFlag()
Returns a boolean whether the average is a valid value.
|
java.lang.String |
getColumnName()
Get the name of the column without prefix that uniq the name.
|
FwkCommandInterface[] |
getCommands(FwkControllerInterface controller)
Get the commands of the column.
|
int |
getCount()
Get the length of the column data array.
|
int[] |
getDimensions()
Returns an array of integers which has the same number of elements as the number
of dimensions in the ArrayAccess and where each integer value is the the number
of elements in the respective ArrayAccess dimension.
|
short |
getFlagAt(int index)
Retrieves a value flag at a specific index.
|
short[] |
getFlags()
Retrieves the flags belongs to the column data.
|
long |
getIndex(double value)
Get the lower limit index relative to the given channel.
|
long[] |
getIndexRange(double lower,
double upper)
Get the index range relative to the given channel.
|
java.lang.Object |
getItemByCoordinates(int[] coord)
Returns the DataItem corresponding to the given coordinates.
|
double |
getMaximum()
Returns the upper value of the column.
|
double |
getMinimum()
Returns the lower value of the column.
|
double |
getMinPositiveValue()
Get the lowest value that is greater than 0.
|
java.lang.Class |
getNativeDatatype()
Get the data type of inner values.
|
java.lang.Object |
getNativeValues()
Get the inner values.
|
java.lang.Object |
getNativeValues(int lower,
int upper)
Get a range of the inner values.
|
java.lang.String |
getPresentationString(java.util.Locale locale)
Returns the string representation of the item.
|
java.lang.Object |
getProperty(java.lang.String propertyName)
Get Properties.
|
double[] |
getScale()
Get the scaling.
|
java.lang.String |
getShortName()
Get the short name of the column
|
double |
getStandardDeviation()
Returns the standard deviation of the column data.
|
short |
getStandardDeviationFlag()
Returns a boolean whether the standard deviation is a valid value.
|
java.lang.Object |
getTransferData(java.awt.datatransfer.DataFlavor flavor)
Returns an object which represents the data to be transferred.
|
java.awt.datatransfer.DataFlavor[] |
getTransferDataFlavors()
Returns an array of DataFlavor objects indicating the flavors the data can
be provided in.
|
java.lang.String |
getUnitString()
Retrieves the unit of the column.
|
java.lang.Object |
getValueAsObject()
Retrieves the local column of the data item.
|
java.lang.String |
getValueAsString()
Get the values as string.
|
double |
getValueAt(int index)
Retrieves a value at a specific index.
|
double[] |
getValues()
Get the values of the column.
|
java.lang.String |
getVersion()
Return the version string of the FWK component.
|
FwkColumnAccessInterface[] |
independentColumns()
Returns an array of dataitems this dataitem depends on.
|
boolean |
isDataFlavorSupported(java.awt.datatransfer.DataFlavor dataFlavor)
Returns whether or not the specified data flavor is supported for this object.
|
boolean |
isImplicit()
Return a boolean whether the column is an implict column.
|
boolean |
isIndependent()
Return whether the column is an independent column.
|
static void |
main(java.lang.String[] args)
The Main test body.
|
void |
release()
Release the column.
|
protected void |
reshape(int[] coord)
Reshape for the setter routine if necessary.
|
void |
setColumnName(java.lang.String newColumnName)
Set the columnName.
|
void |
setFlagAt(int index,
short flag)
Set a flag
|
void |
setFlags(short[] flags)
Set the flags of the column
|
void |
setIndependent(boolean flag)
Set the independent flag of the column.
|
protected void |
setItemByCoordinates(int[] coord,
byte[] item)
Set new data as byte.
|
protected void |
setItemByCoordinates(int[] coord,
char[] item)
Set new data as char.
|
protected void |
setItemByCoordinates(int[] coord,
double[] item)
Set new data as float.
|
protected void |
setItemByCoordinates(int[] coord,
float[] item)
Set new data as float.
|
protected void |
setItemByCoordinates(int[] coord,
int[] item)
Set new data as int.
|
protected void |
setItemByCoordinates(int[] coord,
long[] item)
Set new data as long.
|
void |
setItemByCoordinates(int[] coord,
java.lang.Object item)
Sets a new value for an item at the indicated coordinates in an ArrayAccess.
|
void |
setName(java.lang.String newName)
Set the name of the column.
|
void |
setScale(double[] scale)
Set the scaling.
|
void |
setValue(java.lang.Object col)
Set a new value.
|
void |
setValueAt(int index,
double value)
Set a value
|
javax.infobus.ArrayAccess |
subdivide(int[] start,
int[] end)
This method is currently not supported.
|
java.lang.String |
toString()
Retrieves the representation string.
|
addChild, addChildListener, containsChild, fireChildAdded, fireChildRemoved, getAllChildren, getAllChildren, getChildren, getChildren, getChildrenCount, hasChildren, hasValidValues, isGroup, removeAllChildren, removeChild, removeChild, removeChildListener, setChildren, setProperty, setValidValues
addDataItemChangeListener, fireItemAdded, fireItemDeleted, fireItemRevoked, fireItemValueChanged, getName, getPropertyGroup, getSource, isChangeManagerSuspended, removeDataItemChangeListener, setPropertyGroup, suspendChangeManager
addCommand, addCommand, addToGroup, addToGroup, addVetoableChangeListener, addVetoableChangeListener, clearCommands, commandsAvailable, compareTo, deleteGroup, destroyController, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getAuthor, getBuild, getCommand, getCommands, getCompany, getCompanyInternetAddress, getCopyright, getCreationDate, getCreationDate, getDateFormatString, getDescription, getFwkMimeTypes, getGroup, getIcon, getIcon, getIconKey, getIconKey, getPersistentObjectNames, getSupportEMail, getTitle, getTitleName, getVetoableChangeArray, getVetoableChangeListenerArray, getVetoableChangeListenerArray, groupExists, removeCommand, removeFromGroup, removeVetoableChangeListener, removeVetoableChangeListener, setAuthor, setBuild, setCommands, setCompany, setCompanyInternetAddress, setCopyright, setCreationDate, setDateFormatString, setDescription, setDescriptor, setDescriptor, setIcon, setIcon, setIconKey, setIconKey, setSource, setSupportEMail, setTitleName
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getPropertyChangeArray, getPropertyChangeListenerArray, getPropertyChangeListenerArray, isPropertyChangeEventSuspended, removePropertyChangeListener, removePropertyChangeListener, suspendPropertyChangeEvents
getClassName, getPresentationString, lostOwnership, setClassName, setCreationDate
getNiceVersion
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getName, hasValidValues, isGroup, setProperty, setValidValues
getAuthor, getBuild, getClassName, getCompany, getCompanyInternetAddress, getCopyright, getCreationDate, getCreationDate, getDateFormatString, getDescription, getIcon, getIcon, getIconKey, getIconKey, getPresentationString, getSupportEMail, getTitle, getTitleName, setAuthor, setBuild, setClassName, setCompany, setCompanyInternetAddress, setCopyright, setCreationDate, setCreationDate, setDateFormatString, setDescription, setDescriptor, setIcon, setIcon, setIconKey, setIconKey, setSupportEMail, setTitleName
addChild, addChildListener, containsChild, getAllChildren, getAllChildren, getChildren, getChildren, getChildrenCount, hasChildren, removeAllChildren, removeChild, removeChild, removeChildListener, setChildren
addDataItemChangeListener, removeDataItemChangeListener
isChangeManagerSuspended, suspendChangeManager
getPersistentObjectNames
destroyController
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getPropertyChangeArray, getPropertyChangeListenerArray, getPropertyChangeListenerArray, isPropertyChangeEventSuspended, removePropertyChangeListener, removePropertyChangeListener, setSource, suspendPropertyChangeEvents
addVetoableChangeListener, addVetoableChangeListener, getVetoableChangeArray, getVetoableChangeListenerArray, getVetoableChangeListenerArray, removeVetoableChangeListener, removeVetoableChangeListener
addCommand, addCommand, addToGroup, addToGroup, clearCommands, commandsAvailable, deleteGroup, getCommand, getCommands, getGroup, groupExists, removeCommand, removeFromGroup, setCommands
getPresentationString
public static final boolean CONSIDER_FLAGS
public static final java.lang.String[] DESCRIPTION_COLUMN_NAME
public static final java.lang.String version
protected java.lang.String columnName
protected boolean rangeIsValid
protected double upper
protected double lower
protected double minPositiveValue
protected double average
protected double standardDeviation
protected boolean averageIsValid
protected boolean standardDeviationIsValid
protected java.lang.String unit
protected javax.infobus.InfoBusDataProducer producer
protected static final FwkIconInterface icon
protected java.lang.String shortName
protected FwkColumnDataObserverInterface observer
protected java.lang.Object range_lock
protected FwkColumnAccess()
public FwkColumnAccess(java.lang.String name, java.lang.String columnName, java.lang.String unit, short[] flags, double[] values)
name
- The name of the column to be published.columnName
- The column name only. The name of the item may be longer.unit
- The unit of the column.flags
- The flags belongs to the values.values
- The values.public FwkColumnAccess(java.lang.String name, java.lang.String columnName, java.lang.String unit, FwkColumnDataObserverInterface observer)
name
- The name of the column to be published.columnName
- The column name only. The name of the item may be longer.unit
- The unit of the column.observer
- The data observer.public java.lang.String getVersion()
FwkInterface
getVersion
in interface FwkInterface
getVersion
in class FwkInfoBusDataAccess
public void release()
release
in interface FwkColumnDataObserverInterface
release
in interface FwkInterface
release
in interface javax.infobus.DataItem
release
in class FwkItem
public void setScale(double[] scale)
setScale
in interface FwkColumnDataObserverInterface
scale
- an double array containing the scaling.public double[] getScale()
getScale
in interface FwkColumnDataObserverInterface
public java.lang.String getColumnName()
getColumnName
in interface FwkColumnAccessInterface
public void setColumnName(java.lang.String newColumnName)
setColumnName
in interface FwkColumnAccessInterface
newColumnName
- the new column name.public void setName(java.lang.String newName)
setName
in interface FwkDescriptionInterface
setName
in class FwkItem
the
- new name of the columnFwkPersistence.getName()
public java.lang.String getShortName()
getShortName
in interface FwkColumnAccessInterface
public java.lang.Object getProperty(java.lang.String propertyName)
getProperty
in interface FwkItemInterface
getProperty
in interface javax.infobus.DataItem
getProperty
in class FwkInfoBusImmediateAccess
propertyName
- The keyword of the property.public java.lang.Object getTransferData(java.awt.datatransfer.DataFlavor flavor) throws java.io.IOException, java.awt.datatransfer.UnsupportedFlavorException
getTransferData
in interface java.awt.datatransfer.Transferable
getTransferData
in class FwkInfoBusImmediateAccess
flavor
- the requested flavor for the datajava.io.IOException
- - if the data is no longer available in the requested flavor.
UnsupportedFlavorException - if the requested data flavor is not supportejava.awt.datatransfer.UnsupportedFlavorException
java.awt.datatransfer.DataFlavor.getRepresentationClass()
public java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
getTransferDataFlavors
in interface java.awt.datatransfer.Transferable
getTransferDataFlavors
in class FwkInfoBusImmediateAccess
public boolean isDataFlavorSupported(java.awt.datatransfer.DataFlavor dataFlavor)
isDataFlavorSupported
in interface java.awt.datatransfer.Transferable
isDataFlavorSupported
in class FwkInfoBusImmediateAccess
flavor
- the requested flavor for the datapublic int[] getDimensions()
getDimensions
in interface javax.infobus.ArrayAccess
getDimensions
in class FwkInfoBusDataAccess
public void setValueAt(int index, double value)
setValueAt
in interface FwkColumnAccessInterface
setValueAt
in interface FwkColumnDataObserverInterface
index
- the index of the value to changed.value
- the new value.public void setItemByCoordinates(int[] coord, java.lang.Object item) throws javax.infobus.InvalidDataException, FwkException
setItemByCoordinates
in interface javax.infobus.ArrayAccess
setItemByCoordinates
in class FwkInfoBusDataAccess
coordinates
- the coordinates of the element to be set. It must have the length 2.newValue
- the new value of the element. Must be an instance of java.lang.Number[]javax.infobus.InvalidDataException
- if changes are supported but newValue is not a legal value for the elementjava.lang.UnsupportedOperationException
- if changes are not supportedFwkException
protected void setItemByCoordinates(int[] coord, double[] item) throws javax.infobus.InvalidDataException, FwkException
javax.infobus.InvalidDataException
FwkException
setItemByCoordinates(int[], Object)
protected void setItemByCoordinates(int[] coord, float[] item) throws javax.infobus.InvalidDataException, FwkException
javax.infobus.InvalidDataException
FwkException
setItemByCoordinates(int[], Object)
protected void setItemByCoordinates(int[] coord, long[] item) throws javax.infobus.InvalidDataException, FwkException
javax.infobus.InvalidDataException
FwkException
setItemByCoordinates(int[], Object)
protected void setItemByCoordinates(int[] coord, int[] item) throws javax.infobus.InvalidDataException, FwkException
javax.infobus.InvalidDataException
FwkException
setItemByCoordinates(int[], Object)
protected void setItemByCoordinates(int[] coord, char[] item) throws javax.infobus.InvalidDataException, FwkException
javax.infobus.InvalidDataException
FwkException
setItemByCoordinates(int[], Object)
protected void setItemByCoordinates(int[] coord, byte[] item) throws javax.infobus.InvalidDataException, FwkException
javax.infobus.InvalidDataException
FwkException
setItemByCoordinates(int[], Object)
protected void reshape(int[] coord)
coord
- The new coordinates.public javax.infobus.ArrayAccess subdivide(int[] start, int[] end) throws java.lang.UnsupportedOperationException
subdivide
in interface javax.infobus.ArrayAccess
subdivide
in class FwkInfoBusDataAccess
start
- The starting coordinates.end
- The starting coordinates.java.lang.UnsupportedOperationException
public java.lang.Object getItemByCoordinates(int[] coord)
getItemByCoordinates
in interface javax.infobus.ArrayAccess
getItemByCoordinates
in class FwkInfoBusDataAccess
coordinates
- - the coordinates of the desired DataItem in array formjava.lang.ArrayIndexOutOfBoundsException
- if any of coordinates[k] are less than 0 or greater
than getDimensions()[k] - 1public long getIndex(double value)
getIndex
in interface FwkColumnAccessInterface
value
- the physical value to be found as index.public long[] getIndexRange(double lower, double upper)
getIndexRange
in interface FwkColumnAccessInterface
lower
- The lower value to be found.upper
- The upper value to be found.public java.lang.Object getValueAsObject()
getValueAsObject
in interface javax.infobus.ImmediateAccess
getValueAsObject
in class FwkInfoBusImmediateAccess
public void setValue(java.lang.Object col) throws javax.infobus.InvalidDataException, FwkException
setValue
in interface javax.infobus.ImmediateAccess
setValue
in class FwkInfoBusImmediateAccess
col
- The new column value.
It must be an instance of java.lang.Number[].javax.infobus.InvalidDataException
FwkException
public java.lang.String toString()
toString
in class FwkDescription
l
- The Locale object or null.public java.lang.String getValueAsString()
TAB
.getValueAsString
in interface javax.infobus.ImmediateAccess
getValueAsString
in class FwkInfoBusImmediateAccess
public int getCount()
getCount
in interface FwkColumnAccessInterface
getCount
in interface FwkColumnDataObserverInterface
DataType
public double[] getValues() throws FwkException
getValues
in interface FwkColumnAccessInterface
FwkException
#getFlag
public double getValueAt(int index) throws FwkException
getValueAt
in interface FwkColumnAccessInterface
getValueAt
in interface FwkColumnDataObserverInterface
index
- The index of interest.An
- exception if the index is out of range.FwkException
FwkColumnAccessInterface.getFlagAt(int)
public short[] getFlags()
getFlags
in interface FwkColumnAccessInterface
Odsx Upper documentation.
public void setFlagAt(int index, short flag)
setFlagAt
in interface FwkColumnAccessInterface
setFlagAt
in interface FwkColumnDataObserverInterface
index
- the index of the flag to changed.flag
- the new flag.FwkColumnAccessInterface
public void setFlags(short[] flags)
setFlags
in interface FwkColumnAccessInterface
flags
- The array containing the new flags.public short getFlagAt(int index) throws FwkException
getFlagAt
in interface FwkColumnAccessInterface
getFlagAt
in interface FwkColumnDataObserverInterface
index
- The index of interest.An
- exception if the index is out of range.FwkException
FwkColumnAccessInterface.getFlags()
,
FwkColumnAccessInterface.getFlagAt(int)
protected void determineRange()
public double getMinimum()
getMinimum
in interface FwkColumnAccessInterface
public double getMinPositiveValue()
getMinPositiveValue
in interface FwkColumnAccessInterface
public double getMaximum()
getMaximum
in interface FwkColumnAccessInterface
public java.lang.String getUnitString()
getUnitString
in interface FwkColumnAccessInterface
public java.lang.String[] dependsOn()
dependsOn
in interface FwkColumnAccessInterface
public FwkColumnAccessInterface[] independentColumns()
independentColumns
in interface FwkColumnAccessInterface
public boolean isIndependent()
isIndependent
in interface FwkColumnAccessInterface
public void setIndependent(boolean flag)
flag
- if true the column will be independent.public boolean isImplicit()
For more information abount implicit columns see org.asam.ods.Column
isImplicit
in interface FwkColumnAccessInterface
isImplicit
in interface FwkColumnDataObserverInterface
public java.lang.Class getNativeDatatype()
getNativeDatatype
in interface FwkColumnDataObserverInterface
public java.lang.Object getNativeValues(int lower, int upper)
getNativeValues
in interface FwkColumnDataObserverInterface
lower
- the lower index of the range of interest.upper
- the upper index of the range of interest.public java.lang.Object getNativeValues()
getNativeValues
in interface FwkColumnDataObserverInterface
public double getAverage()
getAverage
in interface FwkColumnAccessInterface
public double getStandardDeviation()
getStandardDeviation
in interface FwkColumnAccessInterface
public short getAverageFlag()
getAverageFlag
in interface FwkColumnAccessInterface
public short getStandardDeviationFlag()
getStandardDeviationFlag
in interface FwkColumnAccessInterface
public java.lang.String getPresentationString(java.util.Locale locale)
getPresentationString
in interface FwkDescriptionInterface
getPresentationString
in interface FwkPresentationInterface
getPresentationString
in interface javax.infobus.ImmediateAccess
getPresentationString
in class FwkDescription
locale
- The Locale object or null.public FwkCommandInterface[] getCommands(FwkControllerInterface controller)
getCommands
in interface FwkPersistenceInterface
getCommands
in class FwkPersistence
controller
- The Command controller.public static FwkColumnAccessInterface createEmptyColumn(java.lang.String name)
name
- The name of the column.public static void main(java.lang.String[] args)