예제 #1
0
파일: ArchiveManager.cs 프로젝트: nistck/Jx
 internal static bool A()
 {
     if (ArchiveManager.r != null)
     {
         Log.Fatal("ArchiveManager: Init: The instance is already initialized.");
     }
     ArchiveManager.r = new ArchiveManager();
     if (!ArchiveManager.r.B())
     {
         ArchiveManager.a();
         return(false);
     }
     return(true);
 }
예제 #2
0
파일: ArchiveManager.cs 프로젝트: nistck/Jx
        private List <ArchiveManager.ClassB> C()
        {
            List <ArchiveManager.ClassB> list = new List <ArchiveManager.ClassB>();

            foreach (ArchiveFactory current in this.S)
            {
                string[] files = Directory.GetFiles(VirtualFileSystem.ResourceDirectoryPath, "*." + current.FileExtension, SearchOption.AllDirectories);
                string[] array = files;
                for (int i = 0; i < array.Length; i++)
                {
                    string text = array[i];
                    string path = Path.ChangeExtension(text, ".archive");
                    if (File.Exists(path))
                    {
                        TextBlock textBlock = TextBlockUtils.LoadFromRealFile(path);
                        if (textBlock != null)
                        {
                            ArchiveManager.ClassB b = new ArchiveManager.ClassB();
                            b.Factory            = current;
                            b.SourceRealFileName = text;
                            if (textBlock.IsAttributeExist("loadingPriority"))
                            {
                                b.LoadingPriority = float.Parse(textBlock.GetAttribute("loadingPriority"));
                            }
                            list.Add(b);
                        }
                    }
                }
            }
            List <ArchiveManager.ClassB> arg_FA_0 = list;

            if (ArchiveManager.U == null)
            {
                ArchiveManager.U = new Comparison <ArchiveManager.ClassB>(ArchiveManager.A);
            }
            ArchiveManager.A <ArchiveManager.ClassB>(arg_FA_0, ArchiveManager.U);
            return(list);
        }