Package org.dspace.administer
Class CommunityFiliator
- java.lang.Object
-
- org.dspace.administer.CommunityFiliator
-
public class CommunityFiliator extends Object
A command-line tool for setting/removing community/sub-community relationships. Takes community DB Id or handle arguments as inputs.- Version:
- $Revision$
- Author:
- rrodgers
-
-
Field Summary
Fields Modifier and Type Field Description protected CommunityServicecommunityServiceprotected HandleServicehandleService
-
Constructor Summary
Constructors Constructor Description CommunityFiliator()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddefiliate(Context c, Community parent, Community child)voidfiliate(Context c, Community parent, Community child)static voidmain(String[] argv)protected CommunityresolveCommunity(Context c, String communityID)Find a community by ID
-
-
-
Field Detail
-
communityService
protected CommunityService communityService
-
handleService
protected HandleService handleService
-
-
Method Detail
-
main
public static void main(String[] argv) throws Exception
- Parameters:
argv- the command line arguments given- Throws:
Exception- if error
-
filiate
public void filiate(Context c, Community parent, Community child) throws SQLException, AuthorizeException, IOException
- Parameters:
c- contextparent- parent Communitychild- child community- Throws:
SQLException- if database errorAuthorizeException- if authorize errorIOException- if IO error
-
defiliate
public void defiliate(Context c, Community parent, Community child) throws SQLException, AuthorizeException, IOException
- Parameters:
c- contextparent- parent Communitychild- child community- Throws:
SQLException- if database errorAuthorizeException- if authorize errorIOException- if IO error
-
resolveCommunity
protected Community resolveCommunity(Context c, String communityID) throws SQLException
Find a community by ID- Parameters:
c- contextcommunityID- community ID- Returns:
- Community object
- Throws:
SQLException- if database error
-
-