示例#1
0
        /// <summary>
        /// Converts a value returned from a LearningStore query to a
        /// <c>LearnerGlobalObjectiveItemIdentifier</c>.  Throws an exception if the value is
        /// <c>DBNull</c>.
        /// </summary>
        ///
        /// <param name="value">A value from a <c>DataRow</c> within a <c>DataTable</c>
        /// returned from a LearningStore query.</param>
        ///
        /// <param name="result">Where to store the result.</param>
        ///
        public static void CastNonNull(object value, out LearnerGlobalObjectiveItemIdentifier result)
        {
            LearningStoreItemIdentifier id;

            CastNonNull(value, out id);
            result = new LearnerGlobalObjectiveItemIdentifier(id);
        }
示例#2
0
        /// <summary>
        /// Converts a value returned from a LearningStore query to a
        /// <c>LearnerGlobalObjectiveItemIdentifier</c>, or <c>null</c> if the value is
        /// <c>DBNull</c>.
        /// </summary>
        ///
        /// <param name="value">A value from a <c>DataRow</c> within a <c>DataTable</c>
        /// returned from a LearningStore query.</param>
        ///
        /// <param name="result">Where to store the result.</param>
        ///
        public static void Cast(object value, out LearnerGlobalObjectiveItemIdentifier result)
        {
            LearningStoreItemIdentifier id;

            Cast(value, out id);
            result = (id == null) ? null : new LearnerGlobalObjectiveItemIdentifier(id);
        }