public static IIdentity GetNewIdentity()
        {
            IIdentity result = null;

            switch (IdentityType)
            {
            case IdentityFactoryTypes.Decimal:
                result = new NullableDecimalIdentity(1);
                break;

            case IdentityFactoryTypes.Guid:
                result = new GuidIdentity(Guid.NewGuid());
                break;

            case IdentityFactoryTypes.String:
                result = new StringIdentity("Hello");
                break;
            }
            return(result);
        }
        public static IIdentity GetIdentity(object source)
        {
            IIdentity result = null;

            switch (IdentityType)
            {
            case IdentityFactoryTypes.Decimal:
                result = new NullableDecimalIdentity(source);
                break;

            case IdentityFactoryTypes.Guid:
                result = new GuidIdentity(source);
                break;

            case IdentityFactoryTypes.String:
                result = new StringIdentity(source);
                break;
            }
            return(result);
        }