Пример #1
0
        public List<ContentPackDB> GetAllContentPacks(GenericEnumsContentPackType packType)
        {
            lock (this.dbLock)
            {

                using (SQLiteConnection sqlCon = new SQLiteConnection(this.DBPath))
                {

                    sqlCon.Execute(WZConstants.DBClauseSyncOff);

                    return sqlCon.Query<ContentPackDB>("SELECT * FROM ContentPackDB WHERE ContentPackTypeID=?", packType);

                }//end using sqlCon

            }//end lock
        }
Пример #2
0
        public static DrawingLayerType GetDrawingTypeForContentPackType(GenericEnumsContentPackType packType)
        {
            switch (packType) {

            case GenericEnumsContentPackType.Callout:

                return DrawingLayerType.Callout;

            case GenericEnumsContentPackType.Comix:

                return DrawingLayerType.Comix;

            case GenericEnumsContentPackType.RubberStamp:

                return DrawingLayerType.Stamp;

            default:

                throw new InvalidOperationException ("There is no equivalent drawing type for this content pack type!");

            }//end switch
        }