Пример #1
0
            public override bool BeforeUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid)
            {
                _object = newObject;
                _oid    = oid;

                return(true);
            }
Пример #2
0
 public override bool BeforeUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid)
 {
     var so = (SimpleObject) newObject;
     // just add 1
     so.SetId(so.GetId() + 1);
     return true;
 }
Пример #3
0
        public override bool BeforeUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid)
        {
            var so = (SimpleObject)newObject;

            // just add 1
            so.SetId(so.GetId() + 1);
            return(true);
        }
Пример #4
0
        public static NonNativeObjectInfo GetNnoi(IObjectRepresentation objectRepresentation)
        {
            var defaultObjectRepresentation = objectRepresentation as ObjectRepresentation;
            if (defaultObjectRepresentation != null)
                return defaultObjectRepresentation.GetNnoi();

            throw new OdbRuntimeException(
                NDatabaseError.InternalError.AddParameter(string.Format("getNnoi not implemented for {0}",
                                                                       objectRepresentation.GetType().FullName)));
        }
Пример #5
0
        public static NonNativeObjectInfo GetNnoi(IObjectRepresentation objectRepresentation)
        {
            var defaultObjectRepresentation = objectRepresentation as ObjectRepresentation;

            if (defaultObjectRepresentation != null)
            {
                return(defaultObjectRepresentation.GetNnoi());
            }

            throw new OdbRuntimeException(
                      NDatabaseError.InternalError.AddParameter(string.Format("getNnoi not implemented for {0}",
                                                                              objectRepresentation.GetType().FullName)));
        }
Пример #6
0
 public override void AfterUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid)
 {
     throw new NotImplementedException();
 }
Пример #7
0
 /// <summary>
 /// Action which will happen after update
 /// </summary>
 /// <param name="oldObjectRepresentation">Object representation</param>
 /// <param name="newObject">Updated object</param>
 /// <param name="oid">Oid of updated object</param>
 public abstract void AfterUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid);
Пример #8
0
 /// <summary>
 /// Action which will happen before update
 /// </summary>
 /// <param name="oldObjectRepresentation">Object representation</param>
 /// <param name="newObject">Updated object</param>
 /// <param name="oid">Oid of updated object</param>
 /// <returns>True if updated, in other case false</returns>
 public abstract bool BeforeUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid);
Пример #9
0
 public override void AfterUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid)
 {
     _object = newObject;
     _oid    = oid;
 }
Пример #10
0
 public override void AfterUpdate(IObjectRepresentation oldObjectRepresentation, object newObject, OID oid)
 {
 }