R - T - public abstract class CommonResource<R extends IResource,T extends IResourceType<R>> extends Object implements IResource, Serializable
IResource abstraction.| Modifier and Type | Method and Description |
|---|---|
void |
begin()
begin is performed upon insertion of a resource in an active
ITransaction or upon start of an ITransaction already
containing the IResource. |
void |
commit()
commit is performed when the
ITransaction containing the
IResource is committed. |
static int |
getCounter() |
int |
getId() |
R |
getParent()
If this resource supports hierarchies, the optional parent is returned.
|
T |
getType()
The type that created this resource.
|
void |
resume()
resume is performed when the
ITransaction containing the
IResource is resumed. |
void |
rollback()
rollback is performed when the
ITransaction containing the
IResource is rolled back. |
static void |
setCounter(int counter) |
void |
suspend()
suspend is performed when the
ITransaction containing the
IResource is suspended. |
public static int getCounter()
public static void setCounter(int counter)
public void begin()
throws ResourceException
IResourceITransaction or upon start of an ITransaction already
containing the IResource.begin in interface IResourceResourceExceptionpublic void commit()
throws ResourceException
IResourceITransaction containing the
IResource is committed.commit in interface IResourceResourceExceptionpublic int getId()
public R getParent()
IResourcepublic T getType()
IResourcepublic void resume()
IResourceITransaction containing the
IResource is resumed.public void rollback()
throws ResourceException
IResourceITransaction containing the
IResource is rolled back.rollback in interface IResourceResourceExceptionpublic void suspend()
IResourceITransaction containing the
IResource is suspended.Copyright © 2013 intarsys consulting GmbH. All Rights Reserved.