|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.unihalle.informatik.Alida.operator.ALDOperator
de.unihalle.informatik.Alida.demo.MatrixSum
@ALDAOperator(genericExecutionMode=ALL, level=APPLICATION) public class MatrixSum
Demo operator to calculate colum or row sums of a 2D array.
Nested Class Summary | |
---|---|
static class |
MatrixSum.SummarizeMode
Choose row or colum wise sum |
Nested classes/interfaces inherited from class de.unihalle.informatik.Alida.operator.ALDOperator |
---|
ALDOperator.HidingMode |
Field Summary | |
---|---|
private java.lang.Double[][] |
matrix
Input matrix |
private MatrixSum.SummarizeMode |
summarizeMode
Mode of summarizing |
private java.lang.Double[] |
sums
1D Array of sums. |
Fields inherited from class de.unihalle.informatik.Alida.operator.ALDOperator |
---|
completeDAG, name, portHashAccess, verbose, versionProvider |
Constructor Summary | |
---|---|
MatrixSum()
Default constructor. |
|
MatrixSum(java.lang.Double[][] _matrix)
Constructor. |
Method Summary | |
---|---|
java.lang.Double[] |
getSums()
Returns the calculated sums. |
protected void |
operate()
This method does the actual work and needs to be implemented by every subclass. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
@Parameter(label="Input matrix", required=true, direction=IN, description="Input matrix.") private java.lang.Double[][] matrix
@Parameter(label="Summarize mode", required=true, direction=IN, description="Sum over columns or rows?") private MatrixSum.SummarizeMode summarizeMode
@Parameter(label="sums", direction=OUT, description="Row or column wise sums.") private transient java.lang.Double[] sums
Constructor Detail |
---|
public MatrixSum() throws ALDOperatorException
ALDOperatorException
public MatrixSum(java.lang.Double[][] _matrix) throws ALDOperatorException
matrix
- Input matrix.
ALDOperatorException
Method Detail |
---|
public java.lang.Double[] getSums()
protected void operate() throws ALDOperatorException
ALDOperator
operate
in class ALDOperator
ALDOperatorException
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |