org.simantics.databoard.accessor.file
Interface FileArrayAccessor

All Superinterfaces:
Accessor, ArrayAccessor, CloseableAccessor, FileAccessor
All Known Implementing Classes:
BinaryArray

public interface FileArrayAccessor
extends ArrayAccessor, FileAccessor


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.simantics.databoard.accessor.Accessor
Accessor.Listener
 
Method Summary
 void addAllNoflush(Binding binding, java.lang.Object[] values)
          Add an array of elements.
 void addAllNoflush(int index, Binding binding, java.lang.Object[] values)
          Add an array of elements.
 void addNoflush(Binding binding, java.lang.Object value)
          Add a new value.
 void addNoflush(int index, Binding binding, java.lang.Object value)
          Insert a new value.
 void removeNoflush(int index, int count)
          Remove an element at an index.
 void setNoflush(int index, Binding binding, java.lang.Object value)
          Replace a value container with a new value.
 void setSizeNoFlush(int newSize)
          Set new array size
 void setValueNoflush(Binding binding, java.lang.Object newValue)
          Set all elements from an Array Value.
 
Methods inherited from interface org.simantics.databoard.accessor.ArrayAccessor
add, add, addAll, addAll, get, getAccessor, getAll, getAll, remove, set, setSize, setValue, size, type
 
Methods inherited from interface org.simantics.databoard.accessor.file.FileAccessor
close, file, flush
 
Methods inherited from interface org.simantics.databoard.accessor.Accessor
addListener, apply, getComponent, getValue, getValue, removeListener
 

Method Detail

addNoflush

void addNoflush(Binding binding,
                java.lang.Object value)
                throws AccessorException
Add a new value.

Parameters:
binding -
value - value
Throws:
AccessorException

addAllNoflush

void addAllNoflush(Binding binding,
                   java.lang.Object[] values)
                   throws AccessorException
Add an array of elements.

Parameters:
binding -
values - value
Throws:
AccessorException

addAllNoflush

void addAllNoflush(int index,
                   Binding binding,
                   java.lang.Object[] values)
                   throws AccessorException
Add an array of elements. If elements are inserted in the middle of the array, existing interest sets are updated to reflect the new positions.

Parameters:
index - position to insert new value to
binding -
values -
Throws:
AccessorException

addNoflush

void addNoflush(int index,
                Binding binding,
                java.lang.Object value)
                throws AccessorException
Insert a new value. If elements are inserted in the middle of the array, existing interest sets are updated to reflect the new positions.

Parameters:
index - position to insert new value to
binding -
value - value
Throws:
AccessorException

setValueNoflush

void setValueNoflush(Binding binding,
                     java.lang.Object newValue)
                     throws AccessorException
Set all elements from an Array Value. If array becomes shorter and there are accessors to the removed elements, the accessors are invalidated.

Specified by:
setValueNoflush in interface FileAccessor
Parameters:
binding -
newValue -
Throws:
BindingException - binding error
java.lang.UnsupportedOperationException - cannot set a new value
AccessorException

setNoflush

void setNoflush(int index,
                Binding binding,
                java.lang.Object value)
                throws AccessorException
Replace a value container with a new value.

Parameters:
index -
binding -
value -
Throws:
AccessorException

removeNoflush

void removeNoflush(int index,
                   int count)
                   throws AccessorException
Remove an element at an index. If there are listeners to elements after the null, the interest sets and accessor paths are updated and decreased. If there was an accessor, it becomes invalid.

Parameters:
index -
count -
Throws:
AccessorException

setSizeNoFlush

void setSizeNoFlush(int newSize)
                    throws AccessorException
Set new array size

Parameters:
newSize -
Throws:
AccessorException