Class OrganizationFactory
java.lang.Object
io.jenkins.blueocean.rest.factory.organization.OrganizationFactory
- All Implemented Interfaces:
ExtensionPoint
Maps BlueOcean organization and
ItemGroups.
BlueOcean introduces a notion of "organization", which maps to ItemGroup in Jenkins in some
application-defined way; for example you can map the whole Jenkins into one organization (default),
or you can map organization to each of the top-level folder, ...
For the rest of the BlueOcean code, the assumption is that some ItemGroup maps to an organization,
which means every Item in it belongs to this organization.
This is a singleton extension point. All but the highest ordinal implementation is ignored.
- Author:
- Kohsuke Kawaguchi
-
Nested Class Summary
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract BlueOrganizationLooks up an organization by its name.final BlueOrganizationFinds a nearest organization that contains the givenItemGroup.final BlueOrganizationDeprecated.in 1.2static OrganizationFactorystatic ModifiableTopLevelItemGroupgetItemGroup(BlueOrganization blueOrganization) static ModifiableTopLevelItemGroupgetItemGroup(String org) abstract Collection<BlueOrganization> list()Iterates over all the organizations.abstract BlueOrganizationIf given group is an org, return its representation, or null.
-
Constructor Details
-
OrganizationFactory
public OrganizationFactory()
-
-
Method Details
-
get
Looks up an organization by its name.- Returns:
- null if the no such org exists.
-
list
Iterates over all the organizations. -
of
If given group is an org, return its representation, or null. -
getContainingOrg
Finds a nearest organization that contains the givenItemGroup.- Returns:
- null if the given object doesn't belong to any organization.
-
getContainingOrg
Deprecated.in 1.2UsegetContainingOrg(Item)instead.- Parameters:
r- run- Returns:
- organization
-
getContainingOrg
-
getInstance
-
getItemGroup
-
getItemGroup
@CheckForNull public static ModifiableTopLevelItemGroup getItemGroup(BlueOrganization blueOrganization)
-