public class SubnetworkStorage extends Object implements Storable<SubnetworkStorage>
| Constructor and Description |
|---|
SubnetworkStorage(Directory dir,
String postfix) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
This method makes sure that the underlying used resources are released.
|
SubnetworkStorage |
create(long byteCount)
Creates the underlying storage.
|
void |
flush()
This method makes sure that the underlying data is written to the storage.
|
long |
getCapacity() |
int |
getSubnetwork(int nodeId)
Returns the subnetwork ID for the specified nodeId or 0 if non is associated e.g.
|
boolean |
isClosed() |
boolean |
loadExisting() |
void |
setSubnetwork(int nodeId,
int subnetwork)
This method sets the subnetwork if of the specified nodeId.
|
public int getSubnetwork(int nodeId)
public void setSubnetwork(int nodeId,
int subnetwork)
public boolean loadExisting()
loadExisting in interface Storable<SubnetworkStorage>public SubnetworkStorage create(long byteCount)
Storablecreate in interface Storable<SubnetworkStorage>public void flush()
Storableflush in interface Storable<SubnetworkStorage>public void close()
Storableclose in interface Storable<SubnetworkStorage>close in interface Closeableclose in interface AutoCloseablepublic boolean isClosed()
isClosed in interface Storable<SubnetworkStorage>public long getCapacity()
getCapacity in interface Storable<SubnetworkStorage>Copyright © 2012–2018. All rights reserved.