public static TokenContentSpec construct(char arity, PrefixedName elemName) { return new TokenContentSpec(arity, elemName); }
TokenContentSpec.construct(arity, thisName) : TokenContentSpec.getDummySpec(); subSpecs.add(cs); return TokenContentSpec.getDummySpec();
protected static PrefixedNameSet namesetFromSpecs(boolean nsAware, ContentSpec[] specs) { int len = specs.length; PrefixedName[] nameArray = new PrefixedName[len]; for (int i = 0; i < len; ++i) { nameArray[i] = ((TokenContentSpec)specs[i]).getName(); } if (len < 5) { // 4 or fewer elements -> small return new SmallPrefixedNameSet(nsAware, nameArray); } return new LargePrefixedNameSet(nsAware, nameArray); }
Object old = m.put(n, TokenContentSpec.construct(' ', n)); if (old != null) {
Object old = m.put(n, TokenContentSpec.construct(' ', n)); if (old != null) {
TokenContentSpec.construct(arity, thisName) : TokenContentSpec.getDummySpec(); subSpecs.add(cs); return TokenContentSpec.getDummySpec();
public StructValidator getSimpleValidator() { /* Can we create a simple validator? Yes, if the sub-specs are * all simple (leaves == element tokens with no arity modifier) */ ContentSpec[] specs = mContentSpecs; int i = 0; int len = specs.length; for (; i < len; ++i) { if (!specs[i].isLeaf()) { break; } } if (i == len) { // all leaves, kewl PrefixedName[] set = new PrefixedName[len]; for (i = 0; i < len; ++i) { TokenContentSpec ss = (TokenContentSpec) specs[i]; set[i] = ss.getName(); } return new Validator(mArity, set); } // Nope, need a DFA: return null; }
public static TokenContentSpec construct(char arity, PrefixedName elemName) { return new TokenContentSpec(arity, elemName); }
Object old = m.put(n, TokenContentSpec.construct(' ', n)); if (old != null) {
TokenContentSpec.construct(arity, thisName) : TokenContentSpec.getDummySpec(); subSpecs.add(cs); return TokenContentSpec.getDummySpec();
protected static PrefixedNameSet namesetFromSpecs(boolean nsAware, ContentSpec[] specs) { int len = specs.length; PrefixedName[] nameArray = new PrefixedName[len]; for (int i = 0; i < len; ++i) { nameArray[i] = ((TokenContentSpec)specs[i]).getName(); } if (len < 5) { // 4 or fewer elements -> small return new SmallPrefixedNameSet(nsAware, nameArray); } return new LargePrefixedNameSet(nsAware, nameArray); }
public static TokenContentSpec construct(char arity, NameKey elemName) { return new TokenContentSpec(arity, elemName); }
Object old = m.put(n, TokenContentSpec.construct(' ', n)); if (old != null) {
TokenContentSpec.construct(arity, thisName) : TokenContentSpec.getDummySpec(); subSpecs.add(cs); return TokenContentSpec.getDummySpec();
protected static NameKeySet namesetFromSpecs(boolean nsAware, ContentSpec[] specs) { int len = specs.length; NameKey[] nameArray = new NameKey[len]; for (int i = 0; i < len; ++i) { nameArray[i] = ((TokenContentSpec)specs[i]).getName(); } if (len < 5) { // 4 or fewer elements -> small return new SmallNameKeySet(nsAware, nameArray); } return new LargeNameKeySet(nsAware, nameArray); }
public static TokenContentSpec construct(char arity, NameKey elemName) { return new TokenContentSpec(arity, elemName); }
Object old = m.put(n, TokenContentSpec.construct(' ', n)); if (old != null) {
TokenContentSpec.construct(arity, thisName) : TokenContentSpec.getDummySpec(); subSpecs.add(cs); return TokenContentSpec.getDummySpec();
protected static NameKeySet namesetFromSpecs(boolean nsAware, ContentSpec[] specs) { int len = specs.length; NameKey[] nameArray = new NameKey[len]; for (int i = 0; i < len; ++i) { nameArray[i] = ((TokenContentSpec)specs[i]).getName(); } if (len < 5) { // 4 or fewer elements -> small return new SmallNameKeySet(nsAware, nameArray); } return new LargeNameKeySet(nsAware, nameArray); }
public static TokenContentSpec construct(char arity, PrefixedName elemName) { return new TokenContentSpec(arity, elemName); }