Package com.orientechnologies.orient.core.hook.ORecordHook

Examples of com.orientechnologies.orient.core.hook.ORecordHook.TYPE


        checkSecurity(ODatabaseSecurityResources.CLUSTER, wasNew ? ORole.PERMISSION_CREATE : ORole.PERMISSION_UPDATE, iClusterName);

        if (stream != null && stream.length > 0) {
          if (iCallTriggers) {
            final TYPE triggerType = wasNew ? TYPE.BEFORE_CREATE : TYPE.BEFORE_UPDATE;

            final RESULT hookResult = callbackHooks(triggerType, record);
            if (hookResult == RESULT.RECORD_CHANGED)
              stream = updateStream(record);
            else if (hookResult == RESULT.SKIP_IO)
View Full Code Here


  }

  private void callbackHookSuccess(ORecord record, boolean iCallTriggers, boolean wasNew, byte[] stream,
      OStorageOperationResult<ORecordVersion> operationResult) {
    if (iCallTriggers && stream != null && stream.length > 0) {
      final TYPE hookType;
      if (!operationResult.isMoved()) {
        hookType = wasNew ? TYPE.AFTER_CREATE : TYPE.AFTER_UPDATE;
      } else {
        hookType = wasNew ? TYPE.CREATE_REPLICATED : TYPE.UPDATE_REPLICATED;
      }
View Full Code Here

TOP

Related Classes of com.orientechnologies.orient.core.hook.ORecordHook.TYPE

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.