예제 #1
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__TitleLanguage"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__TitleLanguage"/>,
        /// returns an instance of <see cref="__TitleLanguage"/>; otherwise returns null.</returns>
        public static new __TitleLanguage FromArray(byte[] byteArray)
        {
            __TitleLanguage o = null;

            try
            {
                o = (__TitleLanguage)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #2
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__PDFStatus"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__PDFStatus"/>,
        /// returns an instance of <see cref="__PDFStatus"/>; otherwise returns null.</returns>
        public static new __PDFStatus FromArray(byte[] byteArray)
        {
            __PDFStatus o = null;

            try
            {
                o = (__PDFStatus)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #3
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__MarcControl"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__MarcControl"/>,
        /// returns an instance of <see cref="__MarcControl"/>; otherwise returns null.</returns>
        public static new __MarcControl FromArray(byte[] byteArray)
        {
            __MarcControl o = null;

            try
            {
                o = (__MarcControl)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #4
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__Institution"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__Institution"/>,
        /// returns an instance of <see cref="__Institution"/>; otherwise returns null.</returns>
        public static new __Institution FromArray(byte[] byteArray)
        {
            __Institution o = null;

            try
            {
                o = (__Institution)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #5
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__TitleIdentifier"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__TitleIdentifier"/>,
        /// returns an instance of <see cref="__TitleIdentifier"/>; otherwise returns null.</returns>
        public static new __TitleIdentifier FromArray(byte[] byteArray)
        {
            __TitleIdentifier o = null;

            try
            {
                o = (__TitleIdentifier)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #6
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__Creator"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__Creator"/>,
        /// returns an instance of <see cref="__Creator"/>; otherwise returns null.</returns>
        public static new __Creator FromArray(byte[] byteArray)
        {
            __Creator o = null;

            try
            {
                o = (__Creator)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #7
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__PageSummaryView"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__PageSummaryView"/>,
        /// returns an instance of <see cref="__PageSummaryView"/>; otherwise returns null.</returns>
        public static new __PageSummaryView FromArray(byte[] byteArray)
        {
            __PageSummaryView o = null;

            try
            {
                o = (__PageSummaryView)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #8
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__vwMarcDataField"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__vwMarcDataField"/>,
        /// returns an instance of <see cref="__vwMarcDataField"/>; otherwise returns null.</returns>
        public static new __vwMarcDataField FromArray(byte[] byteArray)
        {
            __vwMarcDataField o = null;

            try
            {
                o = (__vwMarcDataField)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
예제 #9
0
        /// <summary>
        /// Deserializes the byte array and returns an instance of <see cref="__ItemSource"/>.
        /// </summary>
        /// <returns>If the byte array can be deserialized and cast to an instance of <see cref="__ItemSource"/>,
        /// returns an instance of <see cref="__ItemSource"/>; otherwise returns null.</returns>
        public static new __ItemSource FromArray(byte[] byteArray)
        {
            __ItemSource o = null;

            try
            {
                o = (__ItemSource)CustomObjectBase.FromArray(byteArray);
            }
            catch (Exception e)
            {
                throw e;
            }

            return(o);
        }
 public static async Task DeleteCustomObject(IClient client, CustomObjectBase obj)
 {
     try
     {
         await client.ExecuteAsync(new DeleteByIdCommand <CustomObject>(obj.Id, obj.Version));
     }
     catch (NotFoundException)
     {
     }
     catch (ConcurrentModificationException concurrentModificationException)
     {
         var currentVersion = concurrentModificationException.GetCurrentVersion();
         if (currentVersion.HasValue)
         {
             await client
             .ExecuteAsync(new DeleteByIdCommand <CustomObjectBase>(obj.Id, currentVersion.Value));
         }
     }
 }