org.chromattic.core.api
Class ChromatticSessionImpl
java.lang.Object
org.chromattic.core.api.ChromatticSessionImpl
- All Implemented Interfaces:
- ChromatticSession
public class ChromatticSessionImpl
- extends Object
- implements ChromatticSession
- Version:
- $Revision$
- Author:
- Julien Viet
|
Method Summary |
void |
addEventListener(EventListener listener)
|
void |
close()
|
|
create(Class<O> clazz)
|
|
create(Class<O> clazz,
String name)
|
QueryBuilder<?> |
createQueryBuilder()
|
|
findById(Class<O> clazz,
String id)
|
|
findByNode(Class<O> clazz,
javax.jcr.Node node)
|
|
findByPath(Class<O> clazz,
String relPath)
|
|
findByPath(Object origin,
Class<O> clazz,
String relPath)
|
Domain |
getDomain()
|
String |
getId(Object o)
|
javax.jcr.Session |
getJCRSession()
|
String |
getName(Object o)
|
javax.jcr.Node |
getNode(Object o)
|
String |
getPath(Object o)
|
javax.jcr.Node |
getRoot()
|
Status |
getStatus(Object o)
|
|
insert(Class<O> clazz,
String name)
|
|
insert(Object parent,
Class<O> clazz,
String name)
|
String |
persist(Object o)
|
String |
persist(Object parent,
Object child)
|
String |
persist(Object parent,
Object child,
String name)
|
String |
persist(Object o,
String relPath)
|
void |
remove(Object o)
|
void |
save()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ChromatticSessionImpl
public ChromatticSessionImpl(DomainSession domainSession)
getDomain
public final Domain getDomain()
getJCRSession
public final javax.jcr.Session getJCRSession()
- Specified by:
getJCRSession in interface ChromatticSession
getId
public final String getId(Object o)
throws UndeclaredRepositoryException
- Specified by:
getId in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
getName
public final String getName(Object o)
throws UndeclaredRepositoryException
- Specified by:
getName in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
getPath
public final String getPath(Object o)
throws UndeclaredRepositoryException
- Specified by:
getPath in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
create
public final <O> O create(Class<O> clazz)
throws NullPointerException,
IllegalArgumentException
- Specified by:
create in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
create
public final <O> O create(Class<O> clazz,
String name)
throws NullPointerException,
IllegalArgumentException
- Specified by:
create in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
insert
public final <O> O insert(Object parent,
Class<O> clazz,
String name)
throws NullPointerException,
IllegalArgumentException,
ChromatticException
- Specified by:
insert in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
ChromatticException
insert
public final <O> O insert(Class<O> clazz,
String name)
throws NullPointerException,
IllegalArgumentException,
UndeclaredRepositoryException
- Specified by:
insert in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
UndeclaredRepositoryException
persist
public final String persist(Object parent,
Object child,
String name)
throws NullPointerException,
IllegalArgumentException,
ChromatticException
- Specified by:
persist in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
ChromatticException
persist
public final String persist(Object parent,
Object child)
throws NullPointerException,
IllegalArgumentException,
ChromatticException
- Specified by:
persist in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
ChromatticException
persist
public final String persist(Object o)
throws NullPointerException,
IllegalArgumentException,
ChromatticException
- Specified by:
persist in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
ChromatticException
persist
public final String persist(Object o,
String relPath)
throws NullPointerException,
IllegalArgumentException,
ChromatticException
- Specified by:
persist in interface ChromatticSession
- Throws:
NullPointerException
IllegalArgumentException
ChromatticException
findByNode
public final <O> O findByNode(Class<O> clazz,
javax.jcr.Node node)
throws UndeclaredRepositoryException
- Specified by:
findByNode in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
findById
public final <O> O findById(Class<O> clazz,
String id)
throws UndeclaredRepositoryException
- Specified by:
findById in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
findByPath
public final <O> O findByPath(Object origin,
Class<O> clazz,
String relPath)
throws ChromatticException
- Specified by:
findByPath in interface ChromatticSession
- Throws:
ChromatticException
findByPath
public final <O> O findByPath(Class<O> clazz,
String relPath)
throws ChromatticException
- Specified by:
findByPath in interface ChromatticSession
- Throws:
ChromatticException
save
public final void save()
throws UndeclaredRepositoryException
- Specified by:
save in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
getStatus
public final Status getStatus(Object o)
throws UndeclaredRepositoryException
- Specified by:
getStatus in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
remove
public final void remove(Object o)
throws UndeclaredRepositoryException
- Specified by:
remove in interface ChromatticSession
- Throws:
UndeclaredRepositoryException
close
public void close()
- Specified by:
close in interface ChromatticSession
createQueryBuilder
public QueryBuilder<?> createQueryBuilder()
throws ChromatticException
- Specified by:
createQueryBuilder in interface ChromatticSession
- Throws:
ChromatticException
addEventListener
public void addEventListener(EventListener listener)
- Specified by:
addEventListener in interface ChromatticSession
getRoot
public javax.jcr.Node getRoot()
getNode
public javax.jcr.Node getNode(Object o)
Copyright © 2010 eXo Platform SAS. All Rights Reserved.