public abstract class DatabaseProfileManager extends Object implements ProfileManager
| Constructor and Description |
|---|
DatabaseProfileManager(Properties props)
DatabaseProfileManager
|
DatabaseProfileManager(Properties props,
Connection conn) |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
add(Connection conn,
Profile profile) |
void |
add(Profile profile)
Add a profile into the set of profiles managed by this profile server.
|
void |
addAll(Collection collection)
Add all of the profiles in the given collection to the set managed by this
server.
|
abstract void |
addAll(Connection conn,
Collection collection) |
void |
clear()
Clear all profiles.
|
abstract void |
clear(Connection conn) |
boolean |
contains(Profile profile)
Tell if the given profile is managed by this server.
|
boolean |
containsAll(Collection collection)
Tell if the given collection of profiles are managed by this server.
|
abstract List |
findProfiles(Connection conn,
XMLQuery query) |
List |
findProfiles(XMLQuery query)
findProfiles
Returns a list of matching profiles
|
abstract Profile |
get(Connection conn,
String profID) |
Profile |
get(String profId)
Get a profile.
|
Collection |
getAll()
Get all profiles.
|
abstract List |
getProfiles(Connection conn)
Dump profiles in the database.
|
boolean |
isEmpty()
Tell if the set of profiles managed by this server is empty.
|
Iterator |
iterator()
Iterate over the available profiles.
|
protected static Connection |
openConnection(Properties props) |
abstract boolean |
remove(Connection conn,
String profId) |
abstract boolean |
remove(Connection conn,
String profId,
String version) |
boolean |
remove(String profId)
Remove the profile with the given ID.
|
boolean |
remove(String profId,
String version)
Remove the profile with the given ID.
|
abstract void |
replace(Connection conn,
Profile profile) |
void |
replace(Profile profile)
Replace a profile into the set of profiles managed by this profile server.
|
int |
size()
Get the size of the set of profiles managed by this server.
|
abstract int |
size(Connection conn) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetIDpublic DatabaseProfileManager(Properties props) throws SQLException, Exception
SQLExceptionExceptionpublic DatabaseProfileManager(Properties props, Connection conn)
public abstract List getProfiles(Connection conn) throws ProfileException
ProfileException - If an error occurs.public List findProfiles(XMLQuery query) throws DOMException, ProfileException
findProfiles in interface ProfileHandlerquery - Search criteria.Profile objects.ProfileException - If any other error occurs.DOMExceptionpublic abstract List findProfiles(Connection conn, XMLQuery query) throws DOMException, ProfileException
DOMExceptionProfileExceptionpublic void add(Profile profile) throws ProfileException
ProfileManageradd in interface ProfileManagerprofile - The profile to add or replace.ProfileException - If any error occurs.public abstract void add(Connection conn, Profile profile) throws ProfileException
ProfileExceptionpublic void addAll(Collection collection) throws ProfileException
ProfileManageraddAll in interface ProfileManagercollection - Collection of Profiles to add.ProfileException - If any error occurs.public abstract void addAll(Connection conn, Collection collection) throws ProfileException
ProfileExceptionpublic abstract void clear(Connection conn) throws ProfileException
ProfileExceptionpublic void clear()
throws ProfileException
ProfileManagerclear in interface ProfileManagerProfileException - If any error occurs.public boolean contains(Profile profile) throws ProfileException
ProfileManagercontains in interface ProfileManagerprofile - The profile to check.ProfileException - If any error occurs.public boolean containsAll(Collection collection) throws ProfileException
ProfileManagercontainsAll in interface ProfileManagercollection - The collection of Profiles to check.Profile in collection are present in
the server, false otherwise.ProfileException - If any error occurs.public abstract Profile get(Connection conn, String profID) throws ProfileException
ProfileExceptionpublic Profile get(String profId) throws ProfileException
ProfileHandlerget in interface ProfileHandlerprofId - ID of the profile to get.ProfileException - If any error occurs.public Collection getAll() throws ProfileException
ProfileManagergetAll in interface ProfileManagerProfileException - If any error occurs.public boolean isEmpty()
throws ProfileException
ProfileManagerisEmpty in interface ProfileManagerProfileException - If any error occurs.public Iterator iterator() throws ProfileException
ProfileManagernext yields a copy of the next Profile object
managed by this server. Updates to profile objects are not backed by the
server; make your updates and then call ProfileManager.add(org.apache.oodt.profile.Profile).iterator in interface ProfileManagerProfiles.ProfileException - If any error occurs.public abstract boolean remove(Connection conn, String profId, String version) throws ProfileException
ProfileExceptionpublic abstract boolean remove(Connection conn, String profId) throws ProfileException
ProfileExceptionpublic boolean remove(String profId, String version) throws ProfileException
ProfileManagerremove in interface ProfileManagerprofId - What profile to remove.version - What version of the the profile identified by profID to remove.ProfileException - If any error occurs.public boolean remove(String profId) throws ProfileException
ProfileManagerremove in interface ProfileManagerprofId - ID of profile to remove.ProfileException - If any error occurs.public int size()
throws ProfileException
ProfileManagersize in interface ProfileManagerProfileException - If any error occurs.public abstract int size(Connection conn) throws ProfileException
ProfileExceptionpublic void replace(Profile profile) throws ProfileException
ProfileManagerreplace in interface ProfileManagerprofile - The profile to add or replace.ProfileException - If any error occurs.public abstract void replace(Connection conn, Profile profile) throws ProfileException
ProfileExceptionprotected static Connection openConnection(Properties props) throws SQLException, ProfileException
SQLExceptionProfileExceptionCopyright © 1999-2014 Apache OODT. All Rights Reserved.