|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.buildforge.services.client.dbo.BuildClass
public final class BuildClass
An object representing a build class within the Build Forge system. A build class specifies the purging behavior for the jobs that are associated with it. It controls when jobs are purged automatically, what gets purged (whether the job was purged automatically or not), what project (if any) to run automatically when the job is purged, and so forth.
Field Summary | |
---|---|
static java.lang.Class<BuildClass> |
CLASS
|
Constructor Summary | |
---|---|
BuildClass(APIClientConnection conn)
Define a new build class object. |
Method Summary | |
---|---|
BuildClass |
create()
Creates a new build class as defined by this object. |
void |
delete()
Removes this build class from the system. |
static void |
deleteByName(APIClientConnection conn,
java.lang.String name)
Removes the specified build class from the system. |
static java.util.List<BuildClass> |
findAll(APIClientConnection conn)
Finds all build class objects in the system to which the user has access. |
static BuildClass |
findByName(APIClientConnection conn,
java.lang.String name)
Finds the build class with the specified name. |
int |
getEnterChainProjectId()
Returns the project id of the project to run if a build is moved into (enters) this build class. |
int |
getExitChainProjectId()
Return the project id of the project to run if a build is moved out of (exits) this build class. |
int |
getLevel()
Returns the level (access group ID) assigned to this class. |
int |
getMaxBuilds()
The maximum number of builds to keep. |
java.lang.String |
getName()
Returns the descriptive name of the class, as supplied by the user that created it. |
int |
getPurgeChainProjectId()
Returns the project ID of the project to run as a purge chain. |
int |
getPurgeDays()
Builds in this class will be purged if they are more than this many days old. |
BuildClassDBO.PurgeRule |
getPurgeRule()
Controls which builds are eligible for purging on the basis of whether or not they passed. |
BuildClassDBO.PurgeType |
getPurgeType()
Controls what gets deleted when a build is purged. |
void |
setEnterChainProjectId(int enterChainProjectId)
Sets the project ID of the project to run when a build is moved into (enters) this class. |
void |
setExitChainProjectId(int exitChainProjectId)
Sets the project ID of the project to run when a build is moved out of (exits) this class. |
void |
setLevel(int level)
Sets the level (access group id) assigned to this class. |
void |
setMaxBuilds(int maxBuilds)
Sets the maximum number of builds to keep. |
void |
setName(java.lang.String name)
Sets the name of the class |
void |
setPurgeChainProjectId(int purgeChainProjectId)
Sets the project id of a project to run as a purge chain. |
void |
setPurgeDays(int purgeDays)
Builds in this class will be purged if they are more than this many days old. |
void |
setPurgeRule(BuildClassDBO.PurgeRule purgeRule)
Controls which builds are eligible for purging on the basis of whether or not they passed. |
void |
setPurgeType(BuildClassDBO.PurgeType purgeType)
Controls what gets deleted when a build is purged. |
java.lang.String |
toString()
|
BuildClass |
update()
Updates this existing build class to use the modified values in this object. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.Class<BuildClass> CLASS
Constructor Detail |
---|
public BuildClass(APIClientConnection conn)
create()
method.
conn
- the services layer connection that the build class
object should use when submitting requestsMethod Detail |
---|
public static java.util.List<BuildClass> findAll(APIClientConnection conn) throws java.io.IOException, ServiceException
access group
.
conn
- the API client connection to use for the request
java.io.IOException
ServiceException
public static BuildClass findByName(APIClientConnection conn, java.lang.String name) throws java.io.IOException, ServiceException
conn
- the API client connection to use for the requestname
- The descriptive name of the build class to find
java.io.IOException
ServiceException
public BuildClass create() throws java.io.IOException, ServiceException
Restrictions: Requires Permission.AddClass
and direct or
indirect membership in the access group
. The
descriptive name
must be unique.
java.io.IOException
ServiceException
public void delete() throws java.io.IOException, ServiceException
Restrictions: Requires Permission.DeleteClass
. The
build class can not be referenced as the current class for any
build
, as the default class for
any project
, or as the selected
class for any scheduler entry
.
java.io.IOException
ServiceException
public static void deleteByName(APIClientConnection conn, java.lang.String name) throws java.io.IOException, ServiceException
Restrictions: As for delete()
conn
- the connection to user for this requestname
- the name of the build class to delete
java.io.IOException
ServiceException
public BuildClass update() throws java.io.IOException, ServiceException
Restrictions: Requires Permission.UpdateClass
and direct or
indirect membership in the access group
. The
descriptive name
must be unique.
java.io.IOException
ServiceException
public int getEnterChainProjectId()
public int getExitChainProjectId()
public int getLevel()
public int getMaxBuilds()
public java.lang.String getName()
public int getPurgeChainProjectId()
public int getPurgeDays()
public BuildClassDBO.PurgeRule getPurgeRule()
public BuildClassDBO.PurgeType getPurgeType()
public void setEnterChainProjectId(int enterChainProjectId)
enterChainProjectId
- the
project ID
of the project to run
when a build is moved into (enters) this classpublic void setExitChainProjectId(int exitChainProjectId)
exitChainProjectId
- the
project ID
of the project to run
when a build is moved out of (exits) this classpublic void setLevel(int level)
public void setMaxBuilds(int maxBuilds)
public void setName(java.lang.String name)
public void setPurgeChainProjectId(int purgeChainProjectId)
public void setPurgeDays(int purgeDays)
public void setPurgeRule(BuildClassDBO.PurgeRule purgeRule)
public void setPurgeType(BuildClassDBO.PurgeType purgeType)
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |