public class HierarchicalOrgLoaderHook extends LoaderHooks
METHOD_LOADER_POST_RUN, METHOD_LOADER_PRE_RUN
Constructor and Description |
---|
HierarchicalOrgLoaderHook() |
Modifier and Type | Method and Description |
---|---|
void |
loaderPreRun(HooksContext hooksContext,
HooksLoaderBean preRunBean)
called right before a loader run
|
static void |
main(String[] args) |
static Map<String,String> |
retrieveAllExistingNodes(GrouperLoaderDb grouperLoaderDb)
get all existing nodes from the db
|
static Map<String,edu.internet2.middleware.grouper.hooks.examples.HierarchicalOrgLoaderHook.OrgHierarchyNode> |
retrieveAllNodes(GrouperLoaderDb grouperLoaderDb,
String orgsTableName,
String orgsIdCol,
String orgsNameCol,
String orgsParentIdCol,
String orgsDisplayNameCol)
get all nodes from the db in map of id to OrgHierarchyNode object
|
static void |
syncUpHierarchicalOrgTable()
make sure the org hierarchical table is in sync
|
static void |
syncUpTables(GrouperLoaderDb grouperLoaderDb,
Map<String,edu.internet2.middleware.grouper.hooks.examples.HierarchicalOrgLoaderHook.OrgHierarchyNode> allNodes,
Map<String,String> existingNodes)
get all existing nodes from the db
|
loaderPostRun
public void loaderPreRun(HooksContext hooksContext, HooksLoaderBean preRunBean)
LoaderHooks
public static void main(String[] args)
args
- public static Map<String,String> retrieveAllExistingNodes(GrouperLoaderDb grouperLoaderDb)
grouperLoaderDb
- public static Map<String,edu.internet2.middleware.grouper.hooks.examples.HierarchicalOrgLoaderHook.OrgHierarchyNode> retrieveAllNodes(GrouperLoaderDb grouperLoaderDb, String orgsTableName, String orgsIdCol, String orgsNameCol, String orgsParentIdCol, String orgsDisplayNameCol)
grouperLoaderDb
- orgsTableName
- orgsIdCol
- orgsNameCol
- orgsParentIdCol
- orgsDisplayNameCol
- public static void syncUpHierarchicalOrgTable()
public static void syncUpTables(GrouperLoaderDb grouperLoaderDb, Map<String,edu.internet2.middleware.grouper.hooks.examples.HierarchicalOrgLoaderHook.OrgHierarchyNode> allNodes, Map<String,String> existingNodes)
grouperLoaderDb
- allNodes
- existingNodes
- Copyright © 2016 Internet2. All rights reserved.