src/share/classes/com/sun/java/util/jar/pack/Attribute.java

Print this page


   1 /*
   2  * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any


 160 
 161     static {
 162         Map<Layout, Attribute> sd = standardDefs;
 163         define(sd, ATTR_CONTEXT_CLASS, "Signature", "RSH");
 164         define(sd, ATTR_CONTEXT_CLASS, "Synthetic", "");
 165         define(sd, ATTR_CONTEXT_CLASS, "Deprecated", "");
 166         define(sd, ATTR_CONTEXT_CLASS, "SourceFile", "RUH");
 167         define(sd, ATTR_CONTEXT_CLASS, "EnclosingMethod", "RCHRDNH");
 168         define(sd, ATTR_CONTEXT_CLASS, "InnerClasses", "NH[RCHRCNHRUNHFH]");
 169         define(sd, ATTR_CONTEXT_CLASS, "BootstrapMethods", "NH[RMHNH[KLH]]");
 170 
 171         define(sd, ATTR_CONTEXT_FIELD, "Signature", "RSH");
 172         define(sd, ATTR_CONTEXT_FIELD, "Synthetic", "");
 173         define(sd, ATTR_CONTEXT_FIELD, "Deprecated", "");
 174         define(sd, ATTR_CONTEXT_FIELD, "ConstantValue", "KQH");
 175 
 176         define(sd, ATTR_CONTEXT_METHOD, "Signature", "RSH");
 177         define(sd, ATTR_CONTEXT_METHOD, "Synthetic", "");
 178         define(sd, ATTR_CONTEXT_METHOD, "Deprecated", "");
 179         define(sd, ATTR_CONTEXT_METHOD, "Exceptions", "NH[RCH]");

 180         //define(sd, ATTR_CONTEXT_METHOD, "Code", "HHNI[B]NH[PHPOHPOHRCNH]NH[RUHNI[B]]");
 181 
 182         define(sd, ATTR_CONTEXT_CODE, "StackMapTable",
 183                ("[NH[(1)]]" +
 184                 "[TB" +
 185                 "(64-127)[(2)]" +
 186                 "(247)[(1)(2)]" +
 187                 "(248-251)[(1)]" +
 188                 "(252)[(1)(2)]" +
 189                 "(253)[(1)(2)(2)]" +
 190                 "(254)[(1)(2)(2)(2)]" +
 191                 "(255)[(1)NH[(2)]NH[(2)]]" +
 192                 "()[]" +
 193                 "]" +
 194                 "[H]" +
 195                 "[TB(7)[RCH](8)[PH]()[]]"));
 196 
 197         define(sd, ATTR_CONTEXT_CODE, "LineNumberTable", "NH[PHH]");
 198         define(sd, ATTR_CONTEXT_CODE, "LocalVariableTable", "NH[PHOHRUHRSHH]");
 199         define(sd, ATTR_CONTEXT_CODE, "LocalVariableTypeTable", "NH[PHOHRUHRSHH]");


   1 /*
   2  * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any


 160 
 161     static {
 162         Map<Layout, Attribute> sd = standardDefs;
 163         define(sd, ATTR_CONTEXT_CLASS, "Signature", "RSH");
 164         define(sd, ATTR_CONTEXT_CLASS, "Synthetic", "");
 165         define(sd, ATTR_CONTEXT_CLASS, "Deprecated", "");
 166         define(sd, ATTR_CONTEXT_CLASS, "SourceFile", "RUH");
 167         define(sd, ATTR_CONTEXT_CLASS, "EnclosingMethod", "RCHRDNH");
 168         define(sd, ATTR_CONTEXT_CLASS, "InnerClasses", "NH[RCHRCNHRUNHFH]");
 169         define(sd, ATTR_CONTEXT_CLASS, "BootstrapMethods", "NH[RMHNH[KLH]]");
 170 
 171         define(sd, ATTR_CONTEXT_FIELD, "Signature", "RSH");
 172         define(sd, ATTR_CONTEXT_FIELD, "Synthetic", "");
 173         define(sd, ATTR_CONTEXT_FIELD, "Deprecated", "");
 174         define(sd, ATTR_CONTEXT_FIELD, "ConstantValue", "KQH");
 175 
 176         define(sd, ATTR_CONTEXT_METHOD, "Signature", "RSH");
 177         define(sd, ATTR_CONTEXT_METHOD, "Synthetic", "");
 178         define(sd, ATTR_CONTEXT_METHOD, "Deprecated", "");
 179         define(sd, ATTR_CONTEXT_METHOD, "Exceptions", "NH[RCH]");
 180         define(sd, ATTR_CONTEXT_METHOD, "MethodParameters", "NB[RUNHI]");
 181         //define(sd, ATTR_CONTEXT_METHOD, "Code", "HHNI[B]NH[PHPOHPOHRCNH]NH[RUHNI[B]]");
 182 
 183         define(sd, ATTR_CONTEXT_CODE, "StackMapTable",
 184                ("[NH[(1)]]" +
 185                 "[TB" +
 186                 "(64-127)[(2)]" +
 187                 "(247)[(1)(2)]" +
 188                 "(248-251)[(1)]" +
 189                 "(252)[(1)(2)]" +
 190                 "(253)[(1)(2)(2)]" +
 191                 "(254)[(1)(2)(2)(2)]" +
 192                 "(255)[(1)NH[(2)]NH[(2)]]" +
 193                 "()[]" +
 194                 "]" +
 195                 "[H]" +
 196                 "[TB(7)[RCH](8)[PH]()[]]"));
 197 
 198         define(sd, ATTR_CONTEXT_CODE, "LineNumberTable", "NH[PHH]");
 199         define(sd, ATTR_CONTEXT_CODE, "LocalVariableTable", "NH[PHOHRUHRSHH]");
 200         define(sd, ATTR_CONTEXT_CODE, "LocalVariableTypeTable", "NH[PHOHRUHRSHH]");