Interface IXServerEvents

All Superinterfaces:
byps.Remote, de.elo.utils.net.Remote, Remote
All Known Implementing Classes:
IXServerEventsBase, IXServerEventsHandler

public interface IXServerEvents extends byps.Remote
The Indexserver fires this events while processing API calls. Event handler functions can be written in JavaScript and their script files have to be stored below the archive folder "Administration/Indexserver Scripting Base".

The first level of entries in "Administration/Indexserver Scripting Base" consists of the mandatory folder "_ALL" and optional folders that are named like the Indexserver instances. An Indexserver instance name is usually the computer name on which the Indexserver is running. But an arbitary name can be explicitly assigned by setting the servlet parameter "ixid" in the web.xml or config.xml files.

The second level below "Administration/IndexServer Scripting Base" shold contain folders named by the person or company that provide the JavaScript modules.

The Indexserver recursively searches in the folder "_ALL" and the folder with the instance name for JavaScript files with extension ".js". All functions in this files named like the functions defined in this interface are recognized as event handler functions. There might be more than one handler per event. All handers are executed in a random order, if the event is raised.

An IX plugin should extend class IXServerEventsBase instead of implementing this interface. This avoids re-compiling the plugin if the interface is extended.

  • Method Details

    • getAppInfo

      String getAppInfo(IXServerEventsContext ec) throws byps.RemoteException
      This mandatory method returns information about the application that implements the interface. It should return the application name and version and the implementors name. The returned String is printed into the log file and is added to error messages. This method is mandatory.
      Parameters:
      ec - Execution context.
      Returns:
      String
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • hasMethod

      boolean hasMethod(IXServerEventsContext ec, String methodName) throws byps.RemoteException
      This mandatory method tests, wether an interace method is implemented. The Indexserver calls this function for each method, before the method is called the first time.
      Parameters:
      ec - Execution context.
      methodName - Method name.
      Returns:
      true, if the method is implemented.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • onBeforeCheckinSord

      void onBeforeCheckinSord(IXServerEventsContext ec, Sord sord, Sord sordDB, Sord parentSord, SordZ sordZ, LockZ unlockZ) throws byps.RemoteException
      This synchronous event is raised before a Sord object is written. It is raised in checkinSord, checkinDocEnd, checkinDocsEnd, startImport.
      Parameters:
      ec - Execution context
      sord - Parameter supplied in checkinSord
      sordDB - Current DB record, is null for new Sords
      parentSord - Parent Sord, might be null.
      sordZ - Members to be written
      unlockZ - Parameter supplied in checkinSord
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC. Execption thrown by the script itself or scripting engine.
    • onAfterCheckinSord

      void onAfterCheckinSord(IXServerEventsContext ec, Sord sord, Sord sordDB, Sord parentSord, SordZ sordZ, LockZ unlockZ) throws byps.RemoteException
      This asynchronous event is raised after a Sord object has been written. It is raised in checkinSord, checkinDocEnd, checkinDocsEnd, checkinSordPath, startImport.
      Parameters:
      ec - Execution context
      sord - Parameter supplied in checkinSord
      sordDB - Current DB record, is null for new Sords
      parentSord - Parent Sord, might be null.
      sordZ - Members written
      unlockZ - Parameter supplied in checkinSord
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC. Execption thrown by the script itself or scripting engine.
    • onBeforeCheckinDocEnd

      void onBeforeCheckinDocEnd(IXServerEventsContext ec, Sord sord, Sord sordDB, Sord parentSord, Document doc, SordZ sordZ, LockZ unlockZ) throws byps.RemoteException
      This synchronous event is raised before a document or a document version is checked in. It is raised in checkinDocEnd, checkinDocsEnd, startImport.
      Parameters:
      ec - Execution context
      sord - Parameter supplied in checkinDocEnd, can be null.
      sordDB - Current DB record, is null for new Sords
      parentSord - Parent Sord, might be null.
      doc - Parameter supplied in checkinDocEnd
      sordZ - Members to be written, can be null.
      unlockZ - Parameter supplied in checkinDocEnd
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC. Execption thrown by the script itself or scripting engine.
    • onAfterCheckinDocEnd

      void onAfterCheckinDocEnd(IXServerEventsContext ec, Sord sord, Sord sordDB, Sord parentSord, Document doc, SordZ sordZ, LockZ unlockZ) throws byps.RemoteException
      This asynchronous event is raised after a document or a document version has been checked in. It is raised in checkinDocEnd, checkinDocsEnd, startImport.
      Parameters:
      ec - Execution context
      sord - Parameter supplied in checkinDocEnd, can be null.
      sordDB - Current DB record, is null for new Sords
      parentSord - Parent Sord, might be null.
      doc - Parameter supplied in checkinDocEnd
      sordZ - Members to be written, can be null.
      unlockZ - Parameter supplied in checkinDocEnd
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC. Execption thrown by the script itself or scripting engine.
    • onBeforeDeleteSord

      void onBeforeDeleteSord(IXServerEventsContext ec, Sord parentSord, Sord sord, LockZ unlockZ, DeleteOptions delOpts) throws byps.RemoteException
      This synchronous event is raised before a Sord is deleted. It is raised in deleteSord, cleanupStart.
      Parameters:
      ec - Execution context
      parentSord - Parent Sord Valid members are defined by parentSord.changedMembers. In JavaScript, use new SordZ(parentSord.changedMembers).isTrue(SordC.mb...) to test whether a member is valid.
      sord - Sord to be deleted (might be a logical reference in parentSord) Valid members are defined by sord.changedMembers.
      unlockZ - Lock mode
      delOpts - Delete options
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • onAfterDeleteSord

      void onAfterDeleteSord(IXServerEventsContext ec, Sord parentSord, Sord sord, LockZ unlockZ, DeleteOptions delOpts, boolean ret) throws byps.RemoteException
      This asynchronous event is raised after a Sord is deleted. It is raised in deleteSord, cleanupStart.
      Parameters:
      ec - Execution context
      parentSord - Parent Sord Valid members are defined by parentSord.changedMembers. In JavaScript, use new SordZ(parentSord.changedMembers).isTrue(SordC.mb...) to test whether a member is valid.
      sord - Sord to be deleted (might be a logical reference in parentSord) Valid members are defined by sord.changedMembers.
      unlockZ - Lock mode
      delOpts - Delete options
      ret - Return value of deleteSord
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • onBeforeRefSord

      void onBeforeRefSord(IXServerEventsContext ec, Sord parentSordOld, Sord parentSordNew, Sord sord, int manSortIndex) throws byps.RemoteException
      This synchronous event is raised before a Sord is moved or a reference is created. It is raised in refSord, copySord.
      Parameters:
      ec - Execution context
      parentSordOld - Previsious parent
      parentSordNew - New parent
      sord - Object or reference to be moved.
      manSortIndex - Manually sort order in the new parent.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • onAfterRefSord

      void onAfterRefSord(IXServerEventsContext ec, Sord parentSordOld, Sord parentSordNew, Sord sord, int manSortIndex) throws byps.RemoteException
      This asynchronous event is raised after a Sord is moved or a reference is created. It is raised in refSord, copySord.
      Parameters:
      ec - Execution context
      parentSordOld - Previsious parent
      parentSordNew - New parent
      sord - Object or reference to be moved.
      manSortIndex - Manually sort order in the new parent.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • onAfterEndEditWorkFlowNode

      void onAfterEndEditWorkFlowNode(IXServerEventsContext ec, WFDiagram workflow, int nodeId, Sord sord, SordZ sordZ) throws byps.RemoteException
      This asynchronous event is raised after a workflow node is forwarded by endEditWorkFlowNode.
      Parameters:
      ec - Execution context
      workflow - Workflow object
      nodeId - Forwarded node ID
      sord - Sord object, valid members as in sordZ
      sordZ - Valid members of Sord object, SordC.mbLeanMembers|SordC.mbDocVersion
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      8.00.008
    • onAfterCheckinReminder

      void onAfterCheckinReminder(IXServerEventsContext ec, Reminder[] remiArray, Sord sord, SordZ sordZ, LockZ unlockZ) throws byps.RemoteException
      This asynchronous event is raised after checkinReminder was called.
      Parameters:
      ec - Execution context
      remiArray - Created or written reminder objects.
      sord - Sord object, valid members as in sordZ
      sordZ - Valid members of Sord object, SordC.mbLeanMembers|SordC.mbDocVersion
      unlockZ - Unlock mode.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      8.00.008
    • executeRegisteredFunction

      Any executeRegisteredFunction(IXServerEventsContext ec, String functionName, Any any) throws byps.RemoteException
      This event is raised when the IXServicePortIF function executeRegisteredFunction is called.
      Parameters:
      ec - Execution context
      functionName - Name of the function to be executed. Function hasMethod(IXServerEventsContext, String) must return true for the given functionName.
      any - Parameter
      Returns:
      An Any object
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • executeRegisteredFunctionString

      String executeRegisteredFunctionString(IXServerEventsContext ec, String functionName, String args) throws byps.RemoteException
      This event is raised when the IXServicePortIF function executeRegisteredFunctionString is called.
      Parameters:
      ec - Execution context
      functionName - Name of the function to be executed. Function hasMethod(IXServerEventsContext, String) must return true for the given functionName.
      args - Parameter
      Returns:
      Result as String
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.022.002
    • onBeforeStartWorkFlow

      void onBeforeStartWorkFlow(IXServerEventsContext ec, WFDiagram workflow, Sord sord, SordZ sordZ) throws byps.RemoteException
      This synchronous event is raised before a workflow is started.
      Parameters:
      ec - Execution context
      workflow - Workflow object
      sord - Sord object, valid members as in sordZ
      sordZ - Valid members of Sord object, SordC.mbLeanMembers|SordC.mbDocVersion
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      10.17.059.001
    • onAfterStartWorkFlow

      void onAfterStartWorkFlow(IXServerEventsContext ec, WFDiagram workflow, Sord sord, SordZ sordZ) throws byps.RemoteException
      This asynchronous event is raised after a workflow is started.
      Parameters:
      ec - Execution context
      workflow - Workflow object
      sord - Sord object, valid members as in sordZ
      sordZ - Valid members of Sord object, SordC.mbLeanMembers|SordC.mbDocVersion
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      8.00.008
    • onBeforeTerminateDeleteWorkFlow

      void onBeforeTerminateDeleteWorkFlow(IXServerEventsContext ec, WFDiagram workflow, Sord sord, SordZ sordZ, int status) throws byps.RemoteException
      This synchronous event is raised before a workflow is terminated or deleted.
      Parameters:
      ec - Execution context
      workflow - Workflow object
      sord - Sord object, valid members as in sordZ
      sordZ - Valid members of Sord object, SordC.mbLeanMembers|SordC.mbDocVersion
      status - 0, if workflow is terminated. 1, if workflow is deleted.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      21.00.000.009
    • onAfterTerminateDeleteWorkFlow

      void onAfterTerminateDeleteWorkFlow(IXServerEventsContext ec, WFDiagram workflow, Sord sord, SordZ sordZ, int status) throws byps.RemoteException
      This asynchronous event is raised after a workflow is terminated or deleted.
      Parameters:
      ec - Execution context
      workflow - Workflow object
      sord - Sord object, valid members as in sordZ
      sordZ - Valid members of Sord object, SordC.mbLeanMembers|SordC.mbDocVersion
      status - 0, if workflow is terminated. 1, if workflow is deleted.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      21.00.000.009
    • onBeforeCheckinActivity

      void onBeforeCheckinActivity(IXServerEventsContext ec, Activity act, boolean isNew, Sord sord, SordZ sordZ, LockZ unlockZ) throws byps.RemoteException
      This event is raised before an activity is written. The event is invoked too, if the activity is to be deleted. An activity is called deleted, if member activity.backAt is not empty.
      Parameters:
      ec - Execution context
      act - Activity object
      isNew - true, if a new activity is to be created. false, if an existing activity is updated.
      sord - Associated sord object.
      sordZ - Valid members of Sord object
      unlockZ - Unlock mode.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • onAfterCheckinActivity

      void onAfterCheckinActivity(IXServerEventsContext ec, Activity act, boolean isNew, Sord sord, SordZ sordZ, LockZ unlockZ) throws byps.RemoteException
      This event is raised asynchronously after an activity is written. The event is invoked too, if the activity was deleted. An activity is called deleted, if member activity.backAt is not empty.
      Parameters:
      ec - Execution context
      act - Activity object
      isNew - true, if a new activity is to be created. false, if an existing activity is updated.
      sord - Associated sord object.
      sordZ - Valid members of Sord object
      unlockZ - Unlock mode.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
    • onBeforeCheckinNotes

      void onBeforeCheckinNotes(IXServerEventsContext ec, Note[] notes, Sord[] sords, long noteC, LockZ unlockZ) throws byps.RemoteException
      This synchronous event is raised before a Note object is written. It is raised in checkinNotes
      Parameters:
      ec - Execution context
      notes - Notes to checkin.
      sords - Sord objects that belong to the notes.
      noteC - Element selector that defines the valid Note members.
      unlockZ - Unlock mode.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.018.000
    • onAfterCheckinNotes

      void onAfterCheckinNotes(IXServerEventsContext ec, Note[] notes, Sord[] sords, long noteC, LockZ unlockZ) throws byps.RemoteException
      This asynchronous event is raised after a Note object has been written. It is raised in
      Parameters:
      ec - Execution context
      notes - Notes to checkin.
      sords - Sord objects that belong to the notes.
      noteC - Element selector that defines the valid Note members.
      unlockZ - Unlock mode.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.018.000
    • onFileUploadBuildResponse

      void onFileUploadBuildResponse(IXServerEventsContext ec, DocVersion dv, String fileName, HttpRequestInfo requestInfo, HttpResponseInfo responseInfo) throws byps.RemoteException
      This event is raised after files has been uploaded by the JSON API to build the response message. The response message depends on the file upload solution used by the client side JavaScript. This event can only be implemented as a JavaScript function. It is not possible to process it in a WEB-service like other events in this interface.
      Parameters:
      ec - Execution context
      dv - DocVersion object with the following valid members: ext, size, guid, uploadResult, physPath. DocVersion.uploadResult has to be returned to the client application. It must be set into its DocVersion.uploadResult before checkinDocEnd can be called. DocVersion.physPath is set to the location of the uploaded file in the servers temporary directory.
      fileName - Name of the uploaded file.
      requestInfo - Information of the underlying HttpServletRequest object.
      responseInfo - Information for the underlying HttpServletResponse object.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      8.00.012.002
    • getUserNames

      UserName[] getUserNames(IXServerEventsContext ec, String[] ids, CheckoutUsersZ checkoutUsersZ) throws byps.RemoteException
      Get lean user and group information. This method is called to internally process the API function IXServicePortIF.getUserNames(ClientInfo, String[], CheckoutUsersZ). This method should call IXServicePortIF.getUserNames(ClientInfo, String[], CheckoutUsersZ) internally and should only modify UserName.flags2 or UserName.flags2 in the returned array. E.g. UserName.flags2 can be changed in order to hide particular users by removing the bit AccessC.FLAG2_VISIBLE_USER.
      Parameters:
      ec - Execution context
      ids - User or group IDs or names.
      checkoutUsersZ - See IXServicePortIF.checkoutUsers(ClientInfo, String[], CheckoutUsersZ, LockZ).
      Returns:
      Array of Names and IDs
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      8.00.020.007
    • onReadSord

      void onReadSord(IXServerEventsContext ec, Sord sord, SordZ sordZ, Document doc, LockZ lockZ) throws byps.RemoteException
      Modify the Sord information returned in checkoutSord, checkoutDoc, findFirstSords, etc. This function is called, before a Sord object is returned to the client application. It can be used to modify or delete some of the transmitted data. But it must not change the members sord.id and sord.guid. Furthermore it cannot prevent the Sord object from being transmitted. This method cannot be implemented by services because of the output parameters. This method is frequently called and should perform as fast as possible.
      Parameters:
      ec - Execution context
      sord - Sord object, "in/out" parameter, can be null.
      sordZ - Valid members in the Sord object, "in" parameter, can be null.
      doc - Document object, "in/out" parameter, can be null.
      lockZ - reserved.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC..
      Since:
      8.00.032.003
      See Also:
    • onCheckSordAccess

      boolean onCheckSordAccess(IXServerEventsContext ec, Sord sord, SordZ sordZ, int lur, CheckAccessOptions opts) throws byps.RemoteException
      Check access to Sord object. Use this method to replace the internal access checking of the ACL for Sord objects. In order to deny access to the given sord, return false, otherwise return true.

      This method should not be implemented by services for performance reasons. It is frequently called and should perform as fast as possible.

      The Indexserver's access check function can be called via class de.elo.ix.jscript.Access.

      Example code:

      
       function onCheckSordAccess(ec, sord, sordZ, lur, opts) {
         var acc = new Packages.de.elo.ix.jscript.Access();
         var succ = acc.checkAccess(sord, lur);
         return succ;
       } 
       
      Parameters:
      ec - Execution context
      sord - Sord object, "in" parameter.
      sordZ - Valid members in the Sord object, "in" parameter.
      lur - Combination of AccessC.LUR_* access modes.
      opts - Options for access checking
      Returns:
      true, if at least one access mode given in lur is allowed. false, if access is denied.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.. Do not throw an exception in order to deny access, return false instead. Any exception will be reported as error in the log file and the access check function of Indexserver is called.
      Since:
      8.00.032.003
      See Also:
    • onBeforeLogin

      void onBeforeLogin(IXServerEventsContext ec, String userName, LoginScriptOptions opts) throws byps.RemoteException
      Before a user is authenticated the IX calls this method. Use it to allow or deny the the login to the user. If the user is not allowed to login according to the LoginScriptOptions opts, an exception has to be thrown.

      Example code:

      
       function onBeforeLogin(ec, user, opts) {
         if (username == "OnlyWithWebClient" && options.getClientName() != LoginScriptOptionsC.CLIENT_NAME_WEBCLIENT) {
           throw "User may login only with the WebClient";
         }
       }
       
      Parameters:
      ec - Execution context
      userName - of the user that is trying to login. If a run-as login is being processed, this parameter contains the run-as user name. The technical user used for authentication can be found it LoginScriptOptions.techUser.
      opts - additional information.
      Throws:
      byps.RemoteException
      Since:
      9.00.000.024
    • onAfterLogin

      void onAfterLogin(IXServerEventsContext ec, String userName, LoginScriptOptions opts) throws byps.RemoteException
      This method is called asynchronously after a user has been successfully authenticated.
      Parameters:
      ec - Execution context
      userName - of the user that has been logged in successfully. If a run-as login has been processed, this parameter contains the run-as user name. The technical user used for authentication can be found it LoginScriptOptions.techUser.
      opts - additional information.
      Throws:
      byps.RemoteException
      Since:
      10.17.059.004
    • onCreateSord

      EditInfo onCreateSord(IXServerEventsContext ec, String parentId, String maskId, EditInfoZ editZ) throws byps.RemoteException
      This event is triggered in createSord, checkinSordPath and optionally in createDoc. Use this event in order to customize the initialization of an EditInfo resp. Sord object. The script can call the IXServicePortIF.createSord(ClientInfo, String, String, EditInfoZ) function in order to get a new EditInfo object. The script can return null, if the standard initialization should be used. Before the EditInfo object created by this function is returned to the client application, the following mebers are overwritten: EditInfo.sord.id=-1, EditInfo.sord.guid=random GUID. All members in EditInfo that are not assigned by this function but requested from the element selector editZ, are assigned (as far as possible) before the EditInfo object is returned to the client. Hint: Although this function is named createSord, it has to return an EditInfo object. This event is not triggered, if there is an onCreateDoc event customized.
      Parameters:
      ec - Execution context
      parentId - Same value as the client supplies in its call to createSord. Exception: an empty String is received for a null value.
      maskId - Same value as the client supplies in its call to createSord. Exception: an empty String is received for a null value.
      editZ - Element selector supplied by the client application in createSord or createDoc.
      Returns:
      Initialized EditInfo object.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.014.010
    • onCreateDoc

      EditInfo onCreateDoc(IXServerEventsContext ec, String parentId, String maskId, String docTemplate, EditInfoZ editInfoZ) throws byps.RemoteException
      This event is triggered in createDoc. If an onCreateDoc event is configured, the event onCreateSord is not triggered in onCreateSord.
      Parameters:
      ec - Execution context
      parentId - Same value as the client supplies in its call to createDoc. Exception: an empty String is received for a null value.
      maskId - Same value as the client supplies in its call to createDoc. Exception: an empty String is received for a null value.
      docTemplate - Same value as the client supplies in its call to createDoc. Exception: an empty String is received for a null value.
      editInfoZ - Element selector supplied by the client application in createDoc.
      Returns:
      Initialized EditInfo object.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.014.010
      See Also:
    • onBeforeCheckinUsers

      UserInfo[] onBeforeCheckinUsers(IXServerEventsContext ec, UserInfo[] userInfos, CheckinUsersZ checkinUsersZ, LockZ unlockZ) throws byps.RemoteException
      This event is invoked before IXServicePortIF.checkinUsers(ClientInfo, UserInfo[], CheckinUsersZ, LockZ) processes the supplied UserInfo objects.
      Parameters:
      ec - Execution context
      userInfos - Array of UserInfo objects. Can be null or empty if only the lock should be released.
      checkinUsersZ - CheckinUsersC constant.
      unlockZ - Lock mode.
      Returns:
      Potentially modified UserInfo objects. This objects will be written to the database.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.016.015
    • onAfterCheckinUsers

      void onAfterCheckinUsers(IXServerEventsContext ec, UserInfo[] userInfos, CheckinUsersZ checkinUsersZ, LockZ unlockZ) throws byps.RemoteException
      This event is called after IXServicePortIF.checkinUsers(ClientInfo, UserInfo[], CheckinUsersZ, LockZ) has processed the supplied UserInfo objects. Indexserver invokes this event asynchronously after the users have been written.
      Parameters:
      ec - Execution context
      userInfos - Array of UserInfo objects. Can be null or empty if only the lock should be released.
      checkinUsersZ - CheckinUsersC constant.
      unlockZ - reserved.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.016.015
    • onBeforeCheckinMap

      KeyValue[] onBeforeCheckinMap(IXServerEventsContext ec, String domainName, String id, int objId, KeyValue[] data, LockZ unlockZ) throws byps.RemoteException
      Parameters:
      ec - Execution context
      id - map ID
      objId - Sord ID, if the map should be attached to a Sord object; otherwise 0
      data - map items
      unlockZ - Remove lock
      Returns:
      New array of KeyValue objects to be inserted. Or null, if the array passed in parameter data should be stored.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.018.003
    • onAfterCheckinMap

      void onAfterCheckinMap(IXServerEventsContext ec, String domainName, String id, int objId, KeyValue[] data, LockZ unlockZ) throws byps.RemoteException
      Parameters:
      ec - Execution context
      id - map ID
      objId - Sord ID, if the map should be attached to a Sord object; otherwise 0
      data - map items
      unlockZ - Remove lock
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.018.003
    • onBeforeDeleteMap

      String[] onBeforeDeleteMap(IXServerEventsContext ec, String domainName, String id, String[] keyNames, LockZ unlockZ) throws byps.RemoteException
      Parameters:
      ec - Execution context
      domainName - map domain name; an arbitrary (existing name) or a predefined name from MapDomainC
      id - map ID. In order to delete the map values associated to a Sord object pass the numeric Sord ID (Sord#id).
      keyNames - keys to be deleted; null to delete the entire map with all keys and history; wildcards allowed
      unlockZ - Remove lock
      Returns:
      New array of keys to be deleted. Or null, if the key names passed in parameter keyNames should be deleted.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.018.003
    • onAfterDeleteMap

      void onAfterDeleteMap(IXServerEventsContext ec, String domainName, String id, String[] keyNames, LockZ unlockZ) throws byps.RemoteException
      Parameters:
      ec - Execution context
      domainName - map domain name; an arbitrary (existing name) or a predefined name from MapDomainC
      id - map ID. In order to delete the map values associated to a Sord object pass the numeric Sord ID (Sord#id).
      keyNames - keys to be deleted; null to delete the entire map with all keys and history; wildcards allowed
      unlockZ - Remove lock
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.018.003
    • onBeforeTakeWorkFlowNode

      void onBeforeTakeWorkFlowNode(IXServerEventsContext ec, WFDiagram workflow, WFNode node, UserInfo user, int flags, LockZ lockZ) throws byps.RemoteException
      Parameters:
      ec - Execution context
      workflow - Workflow object
      node - WFNode object to be taken. This object is a reference to one of the elements in workflow.nodes[].
      user - UserInfo object of the user that receives the task.
      flags - Combination of WFTakeNodeC values.
      lockZ - Specifies the lock mode used to access the workflow. Only administrators can use FORCE. The current lock is not changed.
      Throws:
      byps.RemoteException - Exception with message text of format "[ELOIX:number] text". The number is one of the constants defined in IXExceptionC.
      Since:
      9.00.030.003
    • onBeforeFindSords

      void onBeforeFindSords(IXServerEventsContext ec, FindInfo findInfo, SordZ sordZ) throws byps.RemoteException
      This event is fired before the FindInfo object passed in findFirstSords is evaluated. The passed findInfo object can be modified.
      Parameters:
      ec - Execution context
      findInfo - FindInfo from IXServicePortIF.findFirstSords(ClientInfo, FindInfo, int, SordZ)
      sordZ - SordZ from IXServicePortIF.findFirstSords(ClientInfo, FindInfo, int, SordZ)
      Throws:
      byps.RemoteException
      Since:
      9.00.030.029
    • onBeforeFindSordsInternalSQL

      void onBeforeFindSordsInternalSQL(IXServerEventsContext ec, FindInfo findInfo, SordZ sordZ, FindInfoAsInternalSQL findSql) throws byps.RemoteException
      This event is fired before findFirstSords executes the search statement. Be aware of the fact that there is no guaranty about the generated FindSql data. Subsequent IX versions can create different FindSql objects for the same FindInfo object. Hence, modifications of the FindSql data might not work in future releases. Prefer to use onBeforeFindSords(IXServerEventsContext, FindInfo, SordZ) wherever possible.
      Parameters:
      ec - Execution context
      findInfo - FindInfo from IXServicePortIF.findFirstSords(ClientInfo, FindInfo, int, SordZ), read-only.
      sordZ - SordZ from IXServicePortIF.findFirstSords(ClientInfo, FindInfo, int, SordZ)
      findSql - Describes the SQL select statement.
      Throws:
      byps.RemoteException
      Since:
      9.00.030.029
    • onFindSordsResult

      void onFindSordsResult(IXServerEventsContext ec, FindInfo findInfo, SordZ sordZ, FindResult findResult) throws byps.RemoteException
      This event is called for find results found by findFirstSords and findNextSords.
      Parameters:
      ec - ExecContext
      findInfo - FindInfo passed to IXServicePortIF.findFirstSords(ClientInfo, FindInfo, int, SordZ), read-only.
      sordZ - Element selector, read-only.
      findResult - Find results, read-only.
      Throws:
      byps.RemoteException
      Since:
      9.00.030.029
    • onFindClose

      void onFindClose(IXServerEventsContext ec, Object findInfo) throws byps.RemoteException
      This event is called when a search via findFirstSords/findNextSords is closed.
      Parameters:
      ec - Execution context
      findInfo - FindInfo passed to IXServicePortIF.findFirstSords(ClientInfo, FindInfo, int, SordZ)
      Throws:
      byps.RemoteException
      Since:
      9.00.030.029
    • onInheritKeywording

      InheritKeywordingResult onInheritKeywording(IXServerEventsContext ec, Sord sord, Sord parentSord, String[] okeyNames, Object reserved) throws byps.RemoteException
      This event is called when index values are inherited.

      Example:

       
       function onInheritKeywording(ec, sord, parent, okeyNames, reserved) {
         for (var i = 0; i < okeyNames.length; i++) {
           var key = okeyNames[i];
           var value = getObjKey(parent, key);
           log.info("inherit " + key + ", value=" + value);
           setObjKey(sord, key, value);
         }
         return InheritKeywordingResult.INHERITED;
       }
       
       
      Parameters:
      ec - Execution context
      sord - Sord object to be updated. The object contains at least the members of SordC.mbLeanMembers.
      parentSord - Parent of sord. The object contains at least the members of SordC.mbLeanMembers.
      okeyNames - Inheritable group names of index values as defined in keywording form definition.
      reserved - Reserved.
      Returns:
      Control value that defines how to continue processing, see InheritKeywordingResult.
      Throws:
      byps.RemoteException
      Since:
      9.00.049.001
    • onSendSordToISearch

      void onSendSordToISearch(IXServerEventsContext ec, Sord sord, DocMask mask, String fulltext) throws byps.RemoteException
      Every time a Sord is send to the iSearch to add it to the iSearch index, this event is called.
      Parameters:
      ec - Execution context
      sord -
      fulltext -
      Throws:
      byps.RemoteException
      Since:
      11.00.000.048
    • onSendFeedToISearch

      void onSendFeedToISearch(IXServerEventsContext ec, List<FeedPost> feedPosts) throws byps.RemoteException
      Every time feed documents are send to the iSearch to add it to the iSearch index, this event is called.
      Parameters:
      ec - Execution context
      feedPosts -
      Throws:
      byps.RemoteException
      Since:
      11.00.000.051
    • onBeforeDelegateWorkflowNode

      void onBeforeDelegateWorkflowNode(IXServerEventsContext ec, WFDelegateNodeInfo delegateNodeInfo, LockZ lockZ) throws byps.RemoteException
      This event is invoked before a workflow node is delegated. The implementor can use this function to perform additional checks on delegation before Indexserver performs its plausibility and access checks. Furthermore, it can be used to modify the members of the passed delegateNodeInfo obect. To deny delegation, throw an exception like:
       
       throw [ IXExceptionC.ACCESS_DENIED, "Delegate workflow denied." ];
       
       
      This event function is executed synchronously to the API call delegateWorkflowNode.
      Parameters:
      ec - Execution context
      delegateNodeInfo - WFDelegateNodeInfo object
      lockZ - Lock mode
      Throws:
      byps.RemoteException
      Since:
      20.00.000.007
      See Also:
    • onAfterDelegateWorkflowNode

      void onAfterDelegateWorkflowNode(IXServerEventsContext ec, WFDelegateNodeInfo delegateNodeInfo, LockZ lockZ) throws byps.RemoteException
      This event is invoked after a workflow node has been delegated. The implementor can use this function to notify other systems about the delegation. It is executed asynchronously after the API call delegateWorkflowNode has been successfully executed. Modifications to parameters or thrown exceptions are ignored.
      Parameters:
      ec - Execution context
      delegateNodeInfo - WFDelegateNodeInfo object
      lockZ - Lock mode
      Throws:
      byps.RemoteException
      Since:
      20.00.000.007
      See Also:
    • onAfterPackageImport

      void onAfterPackageImport(IXServerEventsContext ec, PackageImportEventInfo eventInfo) throws byps.RemoteException
      This event is invoked after a packacke has been imported. It is raised in checkinSord, checkinDocEnd, checkinDocsEnd, checkinSordPath, startImport.
      Parameters:
      ec - Execution context
      eventInfo - PackageImportEventInfo object
      Throws:
      byps.RemoteException
      Since:
      21.03.000.018