Examples of group()


Examples of java.nio.file.attribute.PosixFileAttributes.group()

        {
            this.groupName = groupName;
        }
        else
        {
            this.groupName = posixFileAttributes.group().getName();
            groupCache.put( gid, this.groupName );
        }

        setLsModeParts( PosixFilePermissions.toString( posixFileAttributes.permissions() ).toCharArray() );
    }
View Full Code Here

Examples of java.util.regex.MatchResult.group()

      if (! matcher.matches()) {
        continue;
      }
      MatchResult res = matcher.toMatchResult();
      for (int grp=1; grp <= res.groupCount(); grp++) {
        String value = res.group(grp);
        if (grp == SYSLOG_TIMESTAMP_POS) {
          timeStampString = value;

          // apply available format replacements to timestamp
          if (value != null) {
View Full Code Here

Examples of java.util.regex.Matcher.group()

    Pattern pattern = Pattern.compile(regex);

    Matcher matcher = pattern.matcher(value);

    while (matcher.find()) {
      String sysKey = matcher.group(1);
      String p = pre + sysKey + post;
      String v = sysKey.equalsIgnoreCase("user.appdata") ? System.getenv("appdata") : System.getProperty(sysKey,"UNKNOWN");
     
      // We habe to replace '\' and '$' signs before replacement
      // see: http://java.sun.com/j2se/1.4.2/docs/api/java/util/regex/Matcher.html#replaceAll(java.lang.String)
View Full Code Here

Examples of java.util.regex.Matcher.group()

      String line=reader.readLine();

      while (line != null) {
        matcher=pluginTypePattern.matcher(line);
        if (matcher.find()) { // new plugin
          String type=matcher.group(1);
          String className=matcher.group(2);

          if ("plugin".equals(type)) {
            curItem=new PluginSoftwareUpdateItem(className);
          }
View Full Code Here

Examples of java.util.regex.Matcher.group()

      while (line != null) {
        matcher=pluginTypePattern.matcher(line);
        if (matcher.find()) { // new plugin
          String type=matcher.group(1);
          String className=matcher.group(2);

          if ("plugin".equals(type)) {
            curItem=new PluginSoftwareUpdateItem(className);
          }
          else if ("dataservice".equals(type)) {
View Full Code Here

Examples of java.util.regex.Matcher.group()

        }
        else {
          matcher=keyValuePattern.matcher(line);

          if (matcher.find()) { // new plugin
            String value = matcher.group(2);
            value = value.replaceAll("\\\\", ""); // fix wrong HTML encoding in plugin descriptions

            if(curItem != null) {
              curItem.addProperty(matcher.group(1), value);
            }
View Full Code Here

Examples of java.util.regex.Matcher.group()

          if (matcher.find()) { // new plugin
            String value = matcher.group(2);
            value = value.replaceAll("\\\\", ""); // fix wrong HTML encoding in plugin descriptions

            if(curItem != null) {
              curItem.addProperty(matcher.group(1), value);
            }
          }
        }
        line=reader.readLine();
      }
View Full Code Here

Examples of java.util.regex.Matcher.group()

      if (m[i].getName().equals("getClass")) continue;
      if (m[i].getParameterTypes().length > 0) continue;
      Matcher r = p.matcher(m[i].getName());
      if (r.matches()) {
        try {
          values.put(r.group(1).toLowerCase(), m[i].invoke(bean, new Object[0]));
        } catch (IllegalArgumentException e) {
          throw e;
        } catch (IllegalAccessException e) {
          throw new RuntimeException(e);
        } catch (InvocationTargetException e) {
View Full Code Here

Examples of java.util.regex.Matcher.group()

    Matcher matcher;

    pattern = Pattern.compile("bc://bt/([a-z0-9=\\+/]+)", Pattern.CASE_INSENSITIVE);
    matcher = pattern.matcher(text.replaceAll(" ", "+"));
    if (matcher.find()) {
      String base64 = matcher.group(1);
      byte[] decode = Base64.decode(base64);
      if (decode != null && decode.length > 0) {
        // Format is AA/<name>/<size>/<hash>/ZZ
        try {
          String decodeString = new String(decode, "utf8");
View Full Code Here

Examples of java.util.regex.Matcher.group()

        try {
          String decodeString = new String(decode, "utf8");
          pattern = Pattern.compile("AA.*/(.*)/ZZ", Pattern.CASE_INSENSITIVE);
          matcher = pattern.matcher(decodeString);
          if (matcher.find()) {
            String hash = matcher.group(1);
            String magnet = parseTextForMagnets(hash);
            if (magnet != null) {
              pattern = Pattern.compile("AA/(.*)/[0-9]+", Pattern.CASE_INSENSITIVE);
              matcher = pattern.matcher(decodeString);
              if (matcher.find()) {
View Full Code Here
TOP
Copyright © 2015 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.