Return to Navigation

APT API Detail

The following section provides further detail on the operations and processing performed by SSR_APT:API. Please note that when called from the Application Maintenance component, the Admissions Activate Applications process and the Student Program Plan component, the API creates only the APT Instance (SSR_APT_HDR). All other actions are performed when the API is called from the APT Request SSR_APT_REQ application engine.

See Understanding Entity Registry

Class APTAPI

Summary

Property Summary:

Data Type

Name and Description

public APTHeader

APTHeader

The APT Header APT Entity object that is populated when the getHeader() method is invoked.

public BasicEntity

CONTEXT_ROOT

The APT Entity object which is set as the root context for all method processing in the API. This is usually set as the planning node or equates to term node APT item. This property is set by consumers of the API so that only items that fall under this root item are processed. If this property is blank, the APT Header is considered as the root item. This property is set when the setContextRoot() method is invoked.

public BasicEntity

CONTEXT_ROOT_AIR

The AIR Entity object which is set as the root context for all method processing in the API. This is usually set as the planning node or equates to term node AIR item. This property is set by consumers of the API so that only items that fall under this root item are processed. If this property is blank, the PoS property is considered as the root item. This property is set when the setContextRoot() method is invoked.

public string

CRSE_FILTER

This property determines if the APT structure should fill completed and in-progress courses. Set value 'Y' if the Course should ignore completed and in-progress courses.

public EnrollmentCohort

EnrollmentCohort

The enrollment cohort object corresponding to the APT Header in context.

public boolean

FILL_COURSE_GROUP

Set this property to true if the course group entities should be populated in the AIR structure.

public boolean

FILL_COURSE_OFFERING

Set this property to false to turn off loading course offering details entity under AIR Course, default is true.

public boolean

FILL_NON_PFN_ITEMS

Set this property to false if non planning node items should be excluded from the AIR structure.

public boolean

PERFORM_VALIDATE

Set this property to false if validation logic should be ignored when save() method is invoked. By default validation logic is processed when save method is invoked.

public BaseAIREntity

PoS

The Program of Study AIR Entity object corresponding to the APT Header object. This property is automatically instantiated along with the APTHeader APT Entity object when the getHeader() method is invoked.

public ProgramFormatSetup

Program Format

The program format object corresponding to the APT Header in context.

public boolean

TERM_ACTIVATE

Set this property to true to term activate into terms defined in the equates to term items on save.

Constructor Summary:

Return Data Type

Name and Description

public void

APTAPI()

Method Summary:

Return Data Type

Name and Description

public boolean

activateCurrentPlanningNode (MessageLogBase p_Messages out)

Activates the current planning node and all its program format tree node child items by setting the APT Attempt status to 'Activated'. This method will perform this operation only if the attempt status of the current planning node is null.

public boolean

activateCurrentPlanningNodeInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Activates the current planning node and all its program format tree node child items by setting the APT Attempt status to 'Activated'. This method will perform this operation only if the attempt status of the current planning node is null.

public boolean

activateProgFormatNode(BaseAPTEntity p_APT_Entity, MessageLogBase p_Messages out)

Activates the Program Format node entity object passed in as a parameter.

public boolean

addIAMEnrollentDataForItem(number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Adds Individual Activity Management (IAM) enrollment information to a student's APT course item.

public boolean

addIAMEnrollentDataForItemInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Adds Individual Activity Management (IAM) enrollment information to a student's APT course item.

public BaseAPTEntity

addItem (string p_AIR_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item to a student's APT. This method takes care of automatically adding the parent items (if they do not exist) and adds child items based on the enrollment category of the item being added.

This method requires that an APT header record already exists for the student and it should be populated in the APTAPI property APTHeader by invoking the getHeader method.

public BaseAPTEntity

addItemToAPTHeader(string p_Emplid, string p_Institution, number p_Instance, string p_AIR_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item to a student's APT. This method takes care of automatically adding the parent items (if they do not exist) and adds child items based on the enrollment category of the item being added. This method requires that an APT header record already exists for the student.

public BaseAPTEntity

addItemUnderAPTItem (string p_Emplid, string p_Institution, number p_Instance, string p_Parent_Item_ID, string p_Child_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item as a child to a specific APT item. This method can be used to add an item that is not present in the AIR hierarchy.

public BaseAPTEntity

addItemUnderAPTItemV2(string p_Emplid, string p_Institution, number p_Instance, string p_Parent_Item_ID, number p_Parent_Item_seq, string p_Child_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item as a child to a specific APT item. This method can be used to add an item that is not present in the AIR hierarchy.

public APTAttempt

createAPTAttemptForItem (BaseAPTEntity p_parent, BaseAIREntity p_parent_AIR_Entity, MessageLogBase p_Messages out)

Adds a new APT Attempt row for an APT item. This method also creates the APT schedule and APT Result data for the newly created APT Attempt.

public boolean

createAPTHeader (string p_Emplid, string p_Acad_career, number p_Student_car_nbr, string p_Institution, MessageLogBase p_Messages out)

Creates a new APT Header record. To save the newly created APT Header to the database invoke the save method.

Note: The student program stack ACAD_PROG.SSR_APT_INSTANCE is not updated by this method.

public boolean

createAPTHeaderFromEntity (StudentProgram p_StudentProgram, MessageLogBase p_Messages out)

Creates a new APT Header record. This method uses a pre-populated entity object SSR_CAREER_TERM:Accessors:StudentProgram. This method holds the core logic for creating the APT header and is invoked by all the other methods that create APT header. To save the newly created APT Header to the database invoke the save method.

Note: The student program stack ACAD_PROG.SSR_APT_INSTANCE is not updated by this method.

public boolean

createAPTHeaderFromRecord (Record p_recACAD_PROG, MessageLogBase p_Messages out)

Creates a new APT Header record. This method is meant to be used from online components by passing the ACAD_PROG component buffer record as the parameter. To save the newly created APT Header to the database invoke the save method.

Note: The student program stack ACAD_PROG.SSR_APT_INSTANCE is not updated by this method.

public BaseAPTEntity

createAPTItem (BasicEntity p_parent, string p_SSR_ITEM_ID, BaseAIREntity p_AIR_Entity, boolean p_full_mode, MessageLogBase p_Messages out)

Creates one APT item under a parent APT item. This also creates the APT attempt, schedule and result records. Child academic items are also created based on the mode parameter and the enrollment category associated with the item.

public void

createCounterRecord(string p_Emplid, string p_Institution, number p_Instance)

This method should be called to set up the counter record SSR_APT_ITM_CNT. If a row already exists for the given emplid, institution and APT instance key values, it verifies if the counter value is correct and updates it to the right value if it is not. If a counter row does not exist for the given keys then it creates a new row with the correct counter value.

public boolean

deleteAPTHeader (string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Deletes APT Header record. Delete is only allowed if there are no references in student program stack or admissions application stack.

public boolean

dropEnrolledItem (number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Deletes enrollment information from a student's APT course item.

public boolean

dropEnrolledItemInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Deletes enrollment information from a student's APT course item.

public boolean

enrollItem (number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Adds enrollment information to a student's APT course item.

public boolean

enrollItemInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Adds enrollment information to a student's APT course item.

public BaseAPTEntity

findAPTElementByItemSequence (BaseAPTEntity p_tree, number p_SSR_APT_ITEM_SEQ, array of string p_breadcrumbs out)

Searches for and returns an entity object based on the APT item sequence number specified. It can be used only in APT trees.

public BasicEntity

findElementByItemID (BasicEntity p_tree, string p_SSR_ITEM_ID, array of string p_breadcrumbs out)

Searches for and returns an entity object based on the item ID specified. It can be used for both AIR and APT trees.

public BaseAIREntity

getAIRItemByNodeID(number p_nodeID, MessageLogBase p_Messages out)

Retrieves the AIR entity object from the student's APT based on the node ID of the item in Program Format. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

public BaseAIREntity

getAIRItemByNodeIDInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_nodeID, MessageLogBase p_Messages out)

Retrieves the AIR entity object from the student's APT based on the node ID of the item in Program Format.

public void

getAllItemIDsByType (BasicEntity p_tree, string p_SSR_ITEM_TYPE, array of string p_Items out)

This method returns a list of all item IDs that match the parameter p_SSR_ITEM_TYPE in the entity tree p_tree.

public void

getAllItemsByType (BasicEntity p_tree, string p_SSR_ITEM_TYPE, array of BasicEntity p_Items out)

This method returns all items under &p_tree that match the item type value provided in &p_SSR_ITEM_TYPE.

public BaseAPTEntity

getAPTItemByNodeID (number p_nodeID, MessageLogBase p_Messages out)

Retrieves the APT entity object from the student's APT based on the node ID of the item in Program Format. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

public BaseAPTEntity

getAPTItemByNodeIDInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_nodeID, MessageLogBase p_Messages out)

Retrieves the APT entity object from the student's APT based on the node ID of the item in Program Format.

public string

getCurrentPlanningNodeItemID (string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Finds the current planning node item ID of the student from the APT. This method examines AIR and APT structures of the student and determines the planning node item ID.

public void

getHeader (string p_Emplid, string p_Institution, number p_Student_car_nbr)

Retrieves an existing header, allows adding/editing of children.

public void

getHeaderEfficiently (string emplid, string institution, number instance)

Retrieves an existing header, allows adding/editing of children. This method is more efficient from a performance perspective than getHeader().

public string

getNextPlanningNodeItemID (string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Finds the planning node item ID that should be activated next. This method examines AIR and APT structures of the student and determines the next planning node item ID that should be activated.

public void

Initialize()

Initializes state properties ProgramFormat, EnrollmentCohort and PoS based on the current APTHeader value.

public boolean

removeIAMEnrollentDataForItem(number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Removes Individual Activity Management (IAM) enrollment information from a student's APT course item.

public boolean

removeIAMEnrollentDataForItemInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Removes Individual Activity Management (IAM) enrollment information from a student's APT course item.

public boolean

removeItem (string p_APT_Item_ID, MessageLogBase p_Messages out)

Removes an APT Item from the student's APT structure. Invoke the APT API save() method to really delete it from the backend tables. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

public boolean

removeItemFromAPTHeader (string p_Emplid, string p_Institution, number p_Instance, string p_APT_Item_ID, MessageLogBase p_Messages out)

Removes an APT Item from the student's APT structure. Invoke the APT API save() method to really delete it from the backend tables.

public boolean

removeSubstituteItem (string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Remove a substitute item from the student's APT structure. This method must be used instead of removeItem or removeItemFromAPTHeader methods to remove a substitute item. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

public boolean

removeSubstituteItemInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Remove a substitute item from the student's APT structure. This method must be used instead of removeItem or removeItemFromAPTHeader methods to remove a substitute item.

public MessageLogBase

Save( )

Saves the header and all children, if it is a new header creates a counter row.

public void

saveExceptionToLog (string p_component, Exception p_exception)

This method will write debugging information to the SOA log file/table (based on SOA setup) based on the passed in exception object.

public boolean

setContextRoot (string p_itemID)

Provide an EQT or Planning node item ID as parameter to set it as the API's context root item. This will help the API perform certain operations faster as it operates within the APT sub-tree of the planning/term node. This is not mandatory, but greatly improves performance of the APIT methods.

public boolean

substituteItem (string p_Item_ID, string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Substitutes one APT Item with another in the student's APT structure. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

public boolean

substituteItemInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, string p_Item_ID, string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Substitutes one APT Item with another in the student's APT structure.

public boolean

TermActivate (BaseAPTEntity p_APTEnity, MessageLogBase p_Messages out)

This method creates a new row in STDNT_CAR_TERM for the term value specified in the APT schedule.

Details

Property Detail:

Name

Details

APTHeader

APTHeader

The APT Header APT Entity object that is populated when the getHeader() method is invoked.

CONTEXT_ROOT

public BasicEntity

The APT Entity object which is set as the root context for all method processing in the API. This is usually set as the planning node or equates to term node APT item. This property is set by consumers of the API so that only items that fall under this root item are processed. If this property is blank, the APT Header is considered as the root item. This property is set when the setContextRoot() method is invoked.

CONTEXT_ROOT_AIR

public BasicEntity

The AIR Entity object which is set as the root context for all method processing in the API. This is usually set as the planning node or equates to term node AIR item. This property is set by consumers of the API so that only items that fall under this root item is processed. If this property is blank, the PoS property is considered as the root item. This property is set when the setContextRoot() method is invoked.

CRSE_FILTER

public string

This property determines if the APT structure should fill completed and in-progress courses. Set value 'Y' if the Course should ignore completed and in-progress courses.

EnrollmentCohort

public EnrollmentCohort

The enrollment cohort object corresponding to the APT Header in context.

FILL_COURSE_GROUP

public Boolean

Set this property to true if the course group entities should be populated in the AIR structure.

FILL_COURSE_OFFERING

public Boolean

Set this property to false to turn off loading course offering details entity under AIR Course, default is true.

FILL_NON_PFN_ITEMS

public Boolean

Set this property to false if non planning node items should be excluded from the AIR structure.

PERFORM_VALIDATE

public Boolean

Set this property to false if validation logic should be ignored when save() method is invoked. By default, validation logic is processed when save method is invoked.

PoS

public BaseAIREntity

The Program of Study AIR Entity object corresponding to the APT Header object. This property is automatically instantiated along with the APTHeader APT Entity object when the getHeader() method is invoked.

ProgramFormat

public ProgramFormatSetup

The program format object corresponding to the APT Header in context.

TERM_ACTIVATE

public boolean

Set this property to true to term activate into terms defined in the EQT items on save.

Constructor Detail:

Name

Details

APTAPI

public APTAPI ()

Method Detail:

Name

Details

activateCurrentPlanningNode

public boolean activateCurrentPlanningNode (MessageLogBase p_Messages out)

Activates the current planning node and all its program format tree node child items by setting the APT Attempt status to 'Activated'. This method will perform this operation only if the attempt status of the current planning node is null.

Parameters:

MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

activateCurrentPlanningNodeInAPTHeader

public boolean activateCurrentPlanningNodeInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Activates the current planning node and all its program format tree node child items by setting the APT Attempt status to 'Activated'. This method will perform this operation only if the attempt status of the current planning node is null.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

activateProgFormatNode

public boolean activateProgFormatNode(BaseAPTEntity p_APT_Entity, MessageLogBase p_Messages out)

Activates the Program Format node entity object passed in as a parameter.

Parameters:

  • BaseAPTEntity p_APT_Entity - The program format node APT entity that should be activated.

  • MessageLogBase p_Messages(out)

Returns:

boolean

addIAMEnrollentDataForItem

public boolean addIAMEnrollentDataForItem (number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Adds Individual Activity Management (IAM) enrollment information to a student's APT course item.

Parameters:

  • number p_SSR_APT_ITEM_SEQ - APT item sequence of the item to be updated

  • number p_ATTEMPT_NBR - APT attempt number of the item to be updated

  • string p_Term

  • string p_SSR_ACTIVITY_ID - IAM activity ID

  • number p_SSR_ACT_ID_SEQ_NBR - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

addIAMEnrollentDataForItemInAPTHeader

public boolean addIAMEnrollentDataForItemInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Adds Individual Activity Management (IAM) enrollment information to a student's APT course item.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • number p_SSR_APT_ITEM_SEQ - APT item sequence of the item to be updated

  • number p_ATTEMPT_NBR - APT attempt number of the item to be updated

  • string p_Term

  • string p_SSR_ACTIVITY_ID - IAM activity ID

  • number p_SSR_ACT_ID_SEQ_NBR - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

addItem

public BaseAPTEntity addItem (string p_AIR_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item to a student's APT. This method takes care of automatically adding the parent items (if they do not exist) and adds child items based on the enrollment category of the item being added.

This method requires that an APT header record already exists for the student and it should be populated in the APTAPI property APTHeader by invoking the getHeader method.

Parameters:

  • string p_AIR_Item_ID - Item ID of the AIR item that must be added to the student's APT

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

BaseAPTEntity

addItemToAPTHeader

public BaseAPTEntity addItemToAPTHeader (string p_Emplid, string p_Institution, number p_Instance, string p_AIR_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item to a student's APT. This method takes care of automatically adding the parent items (if they do not exist) and adds child items based on the enrollment category of the item being added. This method requires that an APT header record already exists for the student.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • string p_AIR_Item_ID - Item ID of the AIR item that must be added to the student's APT

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

BaseAPTEntity

addItemUnderAPTItem

public BaseAPTEntity addItemUnderAPTItem (string p_Emplid, string p_Institution, number p_Instance, string p_Parent_Item_ID, string p_Child_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item as a child to a specific APT item. This method can be used to add an item that is not present in the AIR hierarchy.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • string p_Parent_Item_ID - Item ID of the parent APT item under which the new item must be created as a child

  • string p_Child_Item_ID - Item ID of the AIR item to be created

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

BaseAPTEntity

addItemUnderAPTItemV2

public BaseAPTEntity addItemUnderAPTItem(string p_Emplid, string p_Institution, number p_Instance, string p_Parent_Item_ID, number p_Parent_Item_seq, string p_Child_Item_ID, MessageLogBase p_Messages out)

Adds an AIR Item as a child to a specific APT item. This method can be used to add an item that is not present in the AIR hierarchy.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • string p_Parent_Item_ID - Item ID of the parent APT item under which the new item must be created as a child

  • number p_Parent_Item_seq - APT Item sequence (SSR_APT_ITEM_SEQ) of the parent APT item under which the new item must be created as a child

  • string p_Child_Item_ID - Item ID of the AIR item to be created

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

BaseAPTEntity

createAPTAttemptForItem

public APTAttempt createAPTAttemptForItem (BaseAPTEntity p_parent, BaseAIREntity p_parent_AIR_Entity, MessageLogBase p_Messages out)

Adds a new APT Attempt row for an APT item. This method also creates the APT schedule and APT Result data for the newly created APT Attempt.

Parameters:

  • BaseAPTEntity p_parent - Parent APT item under which this new APT Attempt must be created

  • BaseAIREntit p_parent_AIR_Entity – The corresponding AIR item of the p_parent APT item

  • MessageLogBase p_Messages(out)

Returns:

APTAttempt

createAPTHeader

public boolean createAPTHeader(string p_Emplid, string p_Acad_career, number p_Student_car_nbr, string p_Institution, MessageLogBase p_Messages out)

Creates a new APT Header record. To save the newly created APT Header to the database invoke the save method.

Note: The student program stack ACAD_PROG.SSR_APT_INSTANCE is not updated by this method.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Acad_career - The student's academic career in program/plan

  • number p_Student_car_nbr - The student's career number in program/plan

  • string p_Institution - The Institution value

  • MessageLogBase p_Messages(out) - Messages/Warnings if any will be added to this object.

Returns:

boolean

createAPTHeaderFromEntity

public boolean createAPTHeaderFromEntity (StudentProgram p_StudentProgram, MessageLogBase p_Messages out)

Creates a new APT Header record. This method uses a pre-populated entity object SSR_CAREER_TERM:Accessors:StudentProgram. This method holds the core logic for creating the APT header and is invoked by all the other methods that create APT header.

To save the newly created APT Header to the database invoke the save method.

Note: The student program stack ACAD_PROG.SSR_APT_INSTANCE is not updated by this method.

Parameters:

  • StudentProgram p_StudentProgram - ACAD_PROG entity object

  • MessageLogBase p_Messages(out) - Messages/Warnings if any will be added to this object

Returns:

boolean

createAPTHeaderFromRecord

public boolean createAPTHeaderFromRecord (Record p_recACAD_PROG, MessageLogBase p_Messages out)

Creates a new APT Header record. This method is meant to be used from online components by passing the ACAD_PROG component buffer record as the parameter. To save the newly created APT Header to the database invoke the save method.

Note: The student program stack ACAD_PROG.SSR_APT_INSTANCE is not updated by this method.

Parameters:

  • Record p_recACAD_PROG - ACAD_PROG component buffer record object

  • MessageLogBase p_Messages(out) - Messages/Warnings if any will be added to this object

Returns:

boolean

createAPTItem

public BaseAPTEntity createAPTItem (BasicEntity p_parent, string p_SSR_ITEM_ID, BaseAIREntity p_AIR_Entity, boolean p_full_mode, MessageLogBase p_Messages out)

Create one APT item under a parent APT item. This also creates the APT attempt, schedule and result records. Child academic items are also created based on the mode parameter and the enrollment category associated with the item.

Parameters:

  • BasicEntity p_parent - Parent APT item under which this new APT item must be created

  • string p_SSR_ITEM_ID - AIR item ID of the APT item to be created

  • BaseAIREntity p_AIR_Entity - The corresponding AIR entity object of the APT item to be created

  • boolean p_full_mode - If true then it creates all children and cascades to create grandchildren and so on, if false only creates itself and any children which have enrollment category auto add option turned on

  • MessageLogBase p_Messages(out)

Returns:

BaseAPTEntity

createCounterRecord

public void createCounterRecord(string p_Emplid, string p_Institution, number p_Instance)

This method should be called to setup the counter record SSR_APT_ITM_CNT. If a row already exists for the given emplid, institution and APT instance key values, it verifies if the counter value is correct and updates it to the right value if it is not. If a counter row does not exist for the given keys then it creates a new row with the correct counter value.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

deleteAPTHeader

public boolean deleteAPTHeader (string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Deletes APT Header record. Delete is only allowed if there are no references in student program stack or admissions application stack.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • MessageLogBase p_Messages(out) - Messages/Warnings if any will be added to this object

Returns:

boolean

dropEnrolledItem

public boolean dropEnrolledItem (number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Deletes enrollment information to a student's APT course item.

Parameters:

  • number p_SSR_APT_ITEM_SEQ

  • number p_ATTEMPT_NBR

  • string p_Term - Term into which the enrollment was made

  • number p_classNumber - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

dropEnrolledItemInAPTHeader

public boolean dropEnrolledItemInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Deletes enrollment information from a student's APT course item.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • number p_SSR_APT_ITEM_SEQ

  • number p_ATTEMPT_NBR

  • string p_Term - Term into which the enrollment was made

  • number p_classNumber - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

enrollItem

public boolean enrollItem(number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Adds enrollment information to a student's APT course item.

Parameters:

  • number p_SSR_APT_ITEM_SEQ

  • number p_ATTEMPT_NBR

  • string p_Term - Term into which the enrollment was made

  • number p_classNumber - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

enrollItemInAPTHeader

public boolean enrollItemInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, number p_classNumber, MessageLogBase p_Messages out)

Adds enrollment information to a student's APT course item.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • number p_SSR_APT_ITEM_SEQ

  • number p_ATTEMPT_NBR

  • string p_Term - Term into which the enrollment was made

  • number p_classNumber - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

findAPTElementByItemSequence

public BaseAPTEntity findAPTElementByItemSequence (BaseAPTEntity p_tree, number p_SSR_APT_ITEM_SEQ, array of string p_breadcrumbs out)

Searches for and returns an entity object based on the APT item sequence number specified. It can be used only in APT trees.

Parameters:

  • BaseAPTEntity p_tree - The root node from where the search should start

  • number p_SSR_APT_ITEM_SEQ - The Item ID of the item to be found

  • array of string p_breadcrumbs(out)- This array of string will be populated with entity IDs of the parent items from the element (being searched for) to the root.

Returns:

BaseAPTEntity

findElementByItemID

public BasicEntity findElementByItemID (BasicEntity p_tree, string p_SSR_ITEM_ID, array of string p_breadcrumbs out)

Searches for and returns an entity object based on the item ID specified. It can be used for both AIR and APT trees.

Parameters:

  • BasicEntity p_tree - The root node from where the search should start

  • string p_SSR_ITEM_ID - The Item ID of the item to be found

  • array of string p_breadcrumbs(out) - This array of string will be populated with entity IDs of the parent items from the element (being searched for) to the root.

Returns:

BasicEntity

getAIRItemByNodeID

public BaseAIREntity getAIRItemByNodeID(number p_nodeID, MessageLogBase p_Messages out)

Retrieves the AIR entity object from the student's APT based on the node ID of the item in Program Format. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

Parameters:

  • number p_nodeID - The node ID from Program Format

  • MessageLogBase p_Messages(out)

Returns:

BaseAIREntity

getAIRItemByNodeIDInAPTHeader

public BaseAIREntity getAIRItemByNodeIDInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_nodeID, MessageLogBase p_Messages out)

Retrieves the AIR entity object from the student's APT based on the node ID of the item in Program Format.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • number p_nodeID - The node ID from Program Format

  • MessageLogBase p_Messages(out)

Returns:

BaseAIREntity

getAllItemIDsByType

public void getAllItemIDsByType (BasicEntity p_tree, string p_SSR_ITEM_TYPE, array of string p_Items out)

This method returns a list of all item IDs that match the parameter p_SSR_ITEM_TYPE in the entity tree p_tree.

Parameters:

  • BasicEntity p_tree

  • string p_SSR_ITEM_TYPE

  • array of string p_Items(out)

public void

getAllItemsByType (BasicEntity p_tree, string p_SSR_ITEM_TYPE, array of BasicEntity p_Items out)

This method returns all items under parameter p_tree that match the item type value provided in p_SSR_ITEM_TYPE.

Parameters:

  • BasicEntity p_tree

  • string p_SSR_ITEM_TYPE

  • array of BasicEntity p_Items(out)

getAPTItemByNodeID

public BaseAPTEntity getAPTItemByNodeID(number p_nodeID, MessageLogBase p_Messages out)

Retrieves the APT entity object from the student's APT based on the node ID of the item in Program Format. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

Parameters:

  • number p_nodeID - The node ID from Program Format

  • MessageLogBase p_Messages(out)

Returns:

BaseAPTEntity

getAPTItemByNodeIDInAPTHeader

public BaseAPTEntity getAPTItemByNodeIDInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_nodeID, MessageLogBase p_Messages out)

Retrieves the APT entity object from the student's APT based on the node ID of the item in Program Format.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • number p_nodeID - The node ID from Program Format

  • MessageLogBase p_Messages(out)

Returns:

BaseAPTEntity

getCurrentPlanningNodeItemID

public string getCurrentPlanningNodeItemID (string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Finds the current planning node item ID of the student from the APT. This method examines AIR and APT structures of the student and determines the planning node item ID.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

string

getHeader

public void getHeader (string p_Emplid, string p_Institution, number p_Student_car_nbr)

Retrieves an existing header, allows adding/editing of children.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value of the student

  • number p_Student_car_nbr - The student's career number in program/plan

getHeaderEfficiently

public void getHeaderEfficiently(string emplid, string institution, number instance)

Retrieves an existing header, allows adding/editing of children. This method is more efficient from a performance perspective than getHeader().

Parameters:

  • string emplid

  • string institution

  • number instance

getNextPlanningNodeItemID

public string getNextPlanningNodeItemID (string p_Emplid, string p_Institution, number p_Instance, MessageLogBase p_Messages out)

Finds the planning node item ID that should be activated next. This method examines AIR and APT structures of the student and determines the next planning node item ID that should be activated.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

string

Initialize

public void Initialize()

Initializes state properties ProgramFormat, EnrollmentCohort and PoS based on the current APTHeader value.

removeIAMEnrollentDataForItem

public boolean removeIAMEnrollentDataForItem(number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Removes Individual Activity Management (IAM) enrollment information from a student's APT course item.

Parameters:

  • number p_SSR_APT_ITEM_SEQ - APT item sequence of the item to be updated

  • number p_ATTEMPT_NBR - APT attempt number of the item to be updated

  • string p_Term

  • string p_SSR_ACTIVITY_ID - IAM activity ID

  • number p_SSR_ACT_ID_SEQ_NBR - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

removeIAMEnrollentDataForItemInAPTHeader

public boolean removeIAMEnrollentDataForItemInAPTHeader(string p_Emplid, string p_Institution, number p_Instance, number p_SSR_APT_ITEM_SEQ, number p_ATTEMPT_NBR, string p_Term, string p_SSR_ACTIVITY_ID, number p_SSR_ACT_ID_SEQ_NBR, MessageLogBase p_Messages out)

Removes Individual Activity Management (IAM) enrollment information from a student's APT course item.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • number p_SSR_APT_ITEM_SEQ - APT item sequence of the item to be updated

  • number p_ATTEMPT_NBR - APT attempt number of the item to be updated

  • string p_Term

  • string p_SSR_ACTIVITY_ID - IAM activity ID

  • number p_SSR_ACT_ID_SEQ_NBR - The class enrolled into

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

removeItem

public boolean removeItem (string p_APT_Item_ID, MessageLogBase p_Messages out)

Removes an APT Item from the student's APT structure. Invoke the APT API save() method to really delete it from the backend tables.

The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

Parameters:

  • string p_APT_Item_ID - Item ID of the AIR item that must be removed from the student's APT

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

removeItemFromAPTHeader

public boolean removeItemFromAPTHeader (string p_Emplid, string p_Institution, number p_Instance, string p_APT_Item_ID, MessageLogBase p_Messages out)

Removes an APT Item from the student's APT structure. Invoke the APT API save() method to really delete it from the backend tables.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • string p_APT_Item_ID - Item ID of the AIR item that must be removed from the student's APT

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

removeSubstituteItem

public boolean removeSubstituteItem (string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Remove a substitute item from the student's APT structure. This method must be used instead of removeItem or removeItemFromAPTHeader to remove a substitute item The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

Parameters:

  • string p_Substitute_Item_ID - Item ID of the APT substitute item that must be removed

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

removeSubstituteItemInAPTHeader

public boolean removeSubstituteItemInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Remove a substitute item from the student's APT structure. This method must be used instead of removeItem or removeItemFromAPTHeader methods to remove a substitute item.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • string p_Substitute_Item_ID - Item ID of the APT substitute item that must be removed

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

save

public MessageLogBase Save()

Saves the header and all children, if it is a new header creates a counter row.

Returns:

MessageLogBase

saveExceptionToLog

public void saveExceptionToLog(string p_component, Exception p_exception)

This method will write debugging information to the SOA log file/table (based on SOA setup) based on the passed in exception object.

Parameters:

  • string p_component - Name of the component/process/event that encountered the exception. Used for identifying the source of entry in the log.

  • Exception p_exception - The exception object. Error message and stack trace information will extracted from this object to be saved to the log.

setContextRoot

public boolean setContextRoot (string p_itemID)

Provide an EQT or Planning node item ID as parameter to set it as the API's context root item. This will help the API perform certain operations faster as it operates within the APT sub-tree of the planning/term node. This is not mandatory, but greatly improves performance of the APIT methods.

Parameters:

string p_itemID - APT item ID of a planning or equates to term node in the APT

Returns:

boolean

substituteItem

public boolean substituteItem (string p_Item_ID, string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Substitutes one APT Item with another in the student's APT structure. The APT Header should be populated in the APTAPI property APTHeader by invoking the getHeader method prior to calling this method.

Parameters:

  • string p_Item_ID - Item ID of the AIR item that must be substituted

  • string p_Substitute_Item_ID - Item ID of the AIR item that must be substituted

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

substituteItemInAPTHeader

public boolean substituteItemInAPTHeader (string p_Emplid, string p_Institution, number p_Instance, string p_Item_ID, string p_Substitute_Item_ID, MessageLogBase p_Messages out)

Substitutes one APT Item with another in the student's APT structure.

Parameters:

  • string p_Emplid - The Employee ID of the student

  • string p_Institution - The Institution value

  • number p_Instance - The APT instance number of the student

  • string p_Item_ID - Item ID of the AIR item that must be substituted

  • string p_Substitute_Item_ID - Item ID of the AIR item that must be substituted

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean

TermActivate

public boolean TermActivate (BaseAPTEntity p_APTEnity, MessageLogBase p_Messages out)

This method creates a new row in STDNT_CAR_TERM for the term value specified in the APT schedule.

Parameters:

  • BaseAPTEntity p_APTEnity - The APT entity whose scheduler STRM should be used for term activation

  • MessageLogBase p_Messages(out) - Messages/Warning if any will be added to this object

Returns:

boolean