Java Code Examples for jdk.nashorn.internal.objects.annotations.Attribute.CONSTANT

The following are Jave code examples for showing how to use CONSTANT of the jdk.nashorn.internal.objects.annotations.Attribute class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
Example 1
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.input property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "input")
public static Object getLastInput(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getInput();
}
 
Example 2
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$8 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$8")
public static Object getGroup8(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(8);
}
 
Example 3
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$2 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$2")
public static Object getGroup2(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(2);
}
 
Example 4
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.lastParen property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "lastParen")
public static Object getLastParen(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getLastParen();
}
 
Example 5
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$4 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$4")
public static Object getGroup4(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(4);
}
 
Example 6
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$1 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$1")
public static Object getGroup1(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(1);
}
 
Example 7
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$1 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$1")
public static Object getGroup1(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(1);
}
 
Example 8
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$2 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$2")
public static Object getGroup2(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(2);
}
 
Example 9
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$3 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$3")
public static Object getGroup3(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(3);
}
 
Example 10
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$6 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$6")
public static Object getGroup6(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(6);
}
 
Example 11
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$7 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$7")
public static Object getGroup7(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(7);
}
 
Example 12
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$6 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$6")
public static Object getGroup6(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(6);
}
 
Example 13
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.rightContext property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "rightContext")
public static Object getRightContext(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getInput().substring(match.getIndex() + match.length());
}
 
Example 14
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$8 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$8")
public static Object getGroup8(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(8);
}
 
Example 15
Project: OpenJSharp   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$9 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$9")
public static Object getGroup9(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(9);
}
 
Example 16
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.input property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "input")
public static Object getLastInput(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getInput();
}
 
Example 17
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.lastMatch property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "lastMatch")
public static Object getLastMatch(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(0);
}
 
Example 18
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.$5 property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "$5")
public static Object getGroup5(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getGroup(5);
}
 
Example 19
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 4 votes
/**
 * Getter for non-standard RegExp.leftContext property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "leftContext")
public static Object getLeftContext(final Object self) {
    final RegExpResult match = Global.instance().getLastRegExpResult();
    return match == null ? "" : match.getInput().substring(0, match.getIndex());
}
 
Example 20
Project: openjdk-jdk10   File: NativeRegExp.java   Source Code and License Vote up 2 votes
/**
 * Getter for non-standard RegExp.multiline property.
 * @param self self object
 * @return last regexp input
 */
@Getter(where = Where.CONSTRUCTOR, attributes = Attribute.CONSTANT, name = "multiline")
public static Object getLastMultiline(final Object self) {
    return false; // doesn't ever seem to become true and isn't documented anyhwere
}