Пример #1
0
        public static IMDbType ItemType(this string itemType)
        {
            IMDbType retValue = IMDbType.Unknown;

            switch (itemType)
            {
            case "Video":
            case "Documentary":
            case "TV Movie":
            case "Short Film":
            case "Feature Film":
            case "Unknown Work":
                retValue = IMDbType.Movie;
                break;

            case "TV Special":
            case "Mini-Series":
            case "TV Series":
                retValue = IMDbType.Show;
                break;

            case "TV Episode":
                retValue = IMDbType.Episode;
                break;

            default:
                retValue = IMDbType.Unknown;
                break;
            }
            return(retValue);
        }
Пример #2
0
        public static IMDbType ItemType(this string itemType)
        {
            IMDbType retValue = IMDbType.Unknown;

            switch (itemType.ToLower())
            {
            case "video":
            case "documentary":
            case "tvmovie":
            case "tvshort":
            case "featurefilm":
            case "unknownwork":
            case "movie":
                retValue = IMDbType.Movie;
                break;

            case "tvspecial":
            case "tvminiseries":
            case "tvseries":
                retValue = IMDbType.Show;
                break;

            case "tvepisode":
                retValue = IMDbType.Episode;
                break;

            default:
                // most likely a movie
                retValue = IMDbType.Movie;
                break;
            }
            return(retValue);
        }
Пример #3
0
 public IManage.IManDatabase UserDb(IMDbType imDbType)
 {
     return UserSession().Databases.ItemByName(imDbType.ToString());
 }
Пример #4
0
 public IManage.IManDatabase AdminDb(IMDbType imDbType)
 {
     return AdminSession().Databases.ItemByName(imDbType.ToString());
 }
Пример #5
0
 public IManage.IManDatabase UserDb(IMDbType imDbType)
 {
     return(UserSession().Databases.ItemByName(imDbType.ToString()));
 }