示例#1
0
        public String Decompile(String sFilename)
        {
            String rv = String.Empty;

            foreach (String s in File.ReadAllLines(sFilename).Where(x => !String.IsNullOrEmpty(x)))
            {
                SmaliLine l = SmaliLine.Parse(s);
                if (l != null)
                {
                    Lines.Add(l);
                }
            }

            SmaliClass c = new SmaliClass();

            c.Lines = Lines;
            c.LoadAttributes();
            c.LoadFields();
            c.LoadMethods();

            StringBuilder sb = new StringBuilder();

            sb.Append(c.ToJava());

            rv = sb.ToString();
            return(rv);
        }
示例#2
0
        public String Decompile(String sFilename)
        {
            String rv = String.Empty;

            foreach (String s in File.ReadAllLines(sFilename).Where(x => !String.IsNullOrEmpty(x)))
            {
                SmaliLine l = SmaliLine.Parse(s);
                if (l != null)
                    Lines.Add(l);
            }

            SmaliClass c = new SmaliClass();
            c.Lines = Lines;
            c.LoadAttributes();
            c.LoadFields();
            c.LoadMethods();

            StringBuilder sb = new StringBuilder();

            sb.Append(c.ToJava());

            rv = sb.ToString();
            return rv;
        }