<pre>
Desired runtime. Example: `python27`.
</pre>

<code>string runtime = 10;</code>
353599
public com.google.protobuf.ByteString
      getRuntimeBytes() {
    java.lang.Object ref = runtime_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      runtime_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }
709534
public int run() {
		try {
			
			if ( compile )
			{
				compile();
			}
			
			
			String separator = "/";
			String cpseperator = ":";
			if (System.getProperty("os.name").contains("indows")){
				separator = "\\";
				cpseperator = ";";
			}
			String s = fileName.replace(separator, ".");
			if ( ".java".equals(s.substring(s.length()-5)))
			{
				s = s.substring(0, s.length()-5); // .java Entfernen
			}
			else
			{
				s = s.substring(0, s.length() - 6); // .class entfernen
			}
			
			
			String localClasspath = classpath;
			if (compileFolder != null)
				localClasspath = localClasspath + cpseperator + compileFolder;
			String command = "java -cp "+localClasspath;
			if (libraryPath != null && libraryPath!= "")
				command += "-Djava.library.path="+libraryPath;
			command = command + " de.kopeme.testrunner.PerformanceTestRunner " + s;
			
//			System.out.println(command);
			Process p = Runtime.getRuntime().exec(command);
			BufferedReader br = new BufferedReader(new InputStreamReader(p.getInputStream()));
			String line;
			
			BufferedWriter bw = null;
//			System.out.println("ExternalOutputFile: " + externalOutputFile);
			if ( externalOutputFile != null && externalOutputFile != "")
			{
				File output = new File(externalOutputFile);
				try {
					bw = new BufferedWriter( new FileWriter(output));
				} catch (IOException e1) {
					// TODO Automatisch generierter Erfassungsblock
					e1.printStackTrace();
				}
			}
			
			
			while ( (line = br.readLine()) != null )
			{
				if ( bw == null)
				{
					System.out.println(line);
				}
				else
				{
					bw.write(line+"\n");
				}
			}
			
			br = new BufferedReader(new InputStreamReader(p.getErrorStream()));
			while ( (line = br.readLine()) != null )
			{
				if ( bw == null)
				{
					System.out.println(line);
				}
				else
				{
					bw.write(line+"\n");
				}
			}
			if ( bw != null )
				bw.close();
			int returnValue = p.waitFor();
//			System.out.println("Returnvalue: " + returnValue);
			return returnValue;
		} catch (IOException e) {
			// TODO Automatisch generierter Erfassungsblock
			e.printStackTrace();
		} catch (InterruptedException e) {
			// TODO Automatisch generierter Erfassungsblock
			e.printStackTrace();
		}
		return 1;
	}
1336867
def create_runtime(self,
                       env,            # type: MutableMapping[Text, Text]
                       runtime_context  # type: RuntimeContext
                      ):  # type: (...) -> Tuple[List, Optional[Text]]
        
        any_path_okay = self.builder.get_requirement("DockerRequirement")[1] \
            or False
        runtime = [u"singularity", u"--quiet", u"exec", u"--contain", u"--pid",
                   u"--ipc"]
        if _singularity_supports_userns():
            runtime.append(u"--userns")
        runtime.append(u"--bind")
        runtime.append(u"{}:{}:rw".format(
            docker_windows_path_adjust(os.path.realpath(self.outdir)),
            self.builder.outdir))
        runtime.append(u"--bind")
        tmpdir = "/tmp"  # nosec
        runtime.append(u"{}:{}:rw".format(
            docker_windows_path_adjust(os.path.realpath(self.tmpdir)), tmpdir))

        self.add_volumes(self.pathmapper, runtime, any_path_okay=True,
                         secret_store=runtime_context.secret_store,
                         tmpdir_prefix=runtime_context.tmpdir_prefix)
        if self.generatemapper is not None:
            self.add_volumes(
                self.generatemapper, runtime, any_path_okay=any_path_okay,
                secret_store=runtime_context.secret_store,
                tmpdir_prefix=runtime_context.tmpdir_prefix)

        runtime.append(u"--pwd")
        runtime.append(u"%s" % (docker_windows_path_adjust(self.builder.outdir)))

        if runtime_context.custom_net:
            raise UnsupportedRequirement(
                "Singularity implementation does not support custom networking")
        elif runtime_context.disable_net:
            runtime.append(u"--net")

        env["SINGULARITYENV_TMPDIR"] = tmpdir
        env["SINGULARITYENV_HOME"] = self.builder.outdir

        for name, value in self.environment.items():
            env["SINGULARITYENV_{}".format(name)] = str(value)
        return (runtime, None)
980126
public ByteString toByteString() {
    try {
      final ByteString.CodedBuilder out =
        ByteString.newCodedBuilder(getSerializedSize());
      writeTo(out.getCodedOutput());
      return out.build();
    } catch (final IOException e) {
      throw new RuntimeException(
        "Serializing to a ByteString threw an IOException (should " +
        "never happen).", e);
    }
  }
1349316
public static StringBuilder size(long size) {
        final StringBuilder buf = new StringBuilder(16);
        appendSize(buf, size);
        return buf;
    }
630267
@Override
    int guessApproxLength() {
        int total = super.guessApproxLength();
        int size = 0;
        List props;

        // Assume 40 bytes per property (string name + value)
        // Each property map may be cached in a transient, or in the base JMF (or both!)
        // If there are no properties, the names may be represented by the EMPTY
        // JMF List, in which case we do NOT want to actually get them.
        // The property will only be flattened 'once' so only count it once.
        if (jmsUserPropertyMap != null) {
            size += jmsUserPropertyMap.size();
        }
        else {
            if (getApi().isNotEMPTYlist(JsApiAccess.JMSPROPERTY_NAME)) {
                props = (List) getApi().getField(JsApiAccess.JMSPROPERTY_NAME);
                if (props != null) {
                    size += props.size();
                }
            }
        }

        if (otherUserPropertyMap != null) {
            size += otherUserPropertyMap.size();
        }
        else {
            if (getApi().isNotEMPTYlist(JsApiAccess.OTHERPROPERTY_NAME)) {
                props = (List) getApi().getField(JsApiAccess.OTHERPROPERTY_NAME);
                if (props != null) {
                    size += props.size();
                }
            }
        }

        if (jmsSystemPropertyMap != null) {
            size += jmsSystemPropertyMap.size();
        }
        else {
            if (getApi().isNotEMPTYlist(JsApiAccess.SYSTEMPROPERTY_NAME)) {
                props = (List) getApi().getField(JsApiAccess.SYSTEMPROPERTY_NAME);
                if (props != null) {
                    size += props.size();
                }
            }
        }

        if (systemContextMap != null) {
            size += systemContextMap.size();
        }
        else {
            if (getApi().isNotEMPTYlist(JsApiAccess.SYSTEMCONTEXT_NAME)) {
                props = (List) getApi().getField(JsApiAccess.SYSTEMCONTEXT_NAME);
                if (props != null) {
                    size += props.size();
                }
            }
        }

        if (mqMdSetPropertiesMap != null) {
            size += mqMdSetPropertiesMap.size();
        }
        else {
            // This field usually doesn't exist, so no need for the isNotEMPTY check
            props = (List) getHdr2().getField(JsHdr2Access.MQMDPROPERTIES_MAP_NAME);
            if (props != null) {
                size += props.size();
            }
        }

        total += size * 40;
        return total;
    }
294096
public com.google.protobuf.ByteString
      getPartialRunHandleBytes() {
    java.lang.Object ref = partialRunHandle_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      partialRunHandle_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }
1015080
public static String asString( Example example )
    {
        StringWriter sw = new StringWriter();
        PrintWriter writer = new PrintWriter( sw );
        example.print( writer );
        return sw.toString();
    }
1040835
def runtime(self):
        

        warnings.warn("admm.ADMM.runtime attribute has been replaced by "
                      "an upgraded timer class: please see the documentation "
                      "for admm.ADMM.solve method and util.Timer class",
                      PendingDeprecationWarning)
        return self.timer.elapsed('init') + self.timer.elapsed('solve')
363191
public static String times(String s, int num) {
        StringBuilder builder = new StringBuilder();
        for (int i = 0; i < num; ++i) {
            builder.append(s);
        }
        return builder.toString();
    }
852780
public double[] run(int times) {
        if (engine == null) {
            throw new RuntimeException("[benchmark error] engine not set for benchmark");
        }

        double[] runtimes = new double[times];
        final int offset = engine.getInputVariables().size();
        for (int t = 0; t < times; ++t) {
            obtained = new ArrayList<double[]>(expected.size());
            for (int i = 0; i < expected.size(); ++i) {
                obtained.add(new double[engine.numberOfInputVariables()
                        + engine.numberOfOutputVariables()]);
            }
            engine.restart();
            long start = System.nanoTime();

            for (int evaluation = 0; evaluation < expected.size(); ++evaluation) {
                double[] expectedValues = expected.get(evaluation);
                double[] obtainedValues = obtained.get(evaluation);

                if (expectedValues.length < engine.getInputVariables().size()) {
                    throw new RuntimeException(MessageFormat.format(
                            "[benchmark error] the number of input values given <{0}> "
                            + "at line <{1}> must be at least the same number of input variables "
                            + "<{2}> in the engine",
                            expectedValues.length, evaluation + 1, engine.numberOfInputVariables()));
                }

                for (int i = 0; i < engine.getInputVariables().size(); ++i) {
                    engine.getInputVariables().get(i).setValue(expectedValues[i]);
                    obtainedValues[i] = expectedValues[i];
                }

                engine.process();

                for (int i = 0; i < engine.getOutputVariables().size(); ++i) {
                    obtainedValues[i + offset] = engine.getOutputVariables().get(i).getValue();
                }
            }

            long end = System.nanoTime();
            runtimes[t] = end - start;
        }

        for (double x : runtimes) {
            this.times.add(x);
        }
        return runtimes;
    }
208912
def runnable? time
      result = [:minute,:hour,:day,:dow,:month].map{|ct|
        if self[ct] == true then
          true
        else
          case ct
          when :month,:day,:hour
            val = time.send(ct)
          when :dow
            val = time.wday
          when :minute
            val = time.min
          end

          case self[ct]
          when Numeric # Should be Fixnum
            self[ct] == val
          else # Assume array-like thing...
            self[ct].include?(val)
          end
        end
      }
      # Everything should be true to make us eligible for running:
      [result.inject(true){|s,v| s && v},result]
    end
432110
public static RuntimeException asRuntime(Throwable e) {
		if (e instanceof RuntimeException) {
			return (RuntimeException) e;
		} else {
			return new WrappedAsRuntimeException(e);
		}
	}
62055
static public byte[] convertStringToByteArr(String s) {
    if ((s.length() % 2) != 0) {
      throw new RuntimeException("String length must be even (was " + s.length() + ")");
    }

    ArrayList<Byte> byteArrayList = new ArrayList<Byte>();
    for (int i = 0; i < s.length(); i = i + 2) {
      String s2 = s.substring(i, i + 2);
      Integer i2 = Integer.parseInt(s2, 16);
      Byte b2 = (byte)(i2 & 0xff);
      byteArrayList.add(b2);
    }

    byte[] byteArr = new byte[byteArrayList.size()];
    for (int i = 0; i < byteArr.length; i++) {
      byteArr[i] = byteArrayList.get(i);
    }
    return byteArr;
  }
1338451
static int getMajorJavaVersion(String javaVersion) {
    int version = parseDotted(javaVersion);
    if (version == -1) {
      version = extractBeginningInt(javaVersion);
    }
    if (version == -1) {
      return 6;  // Choose minimum supported JDK version as default
    }
    return version;
  }
1014935
def p_len(p):
    
    arg = p[2]
    if arg is None:
        p[0] = None
    elif isinstance(arg, symbols.VAR) and arg.class_ == CLASS.array:
        p[0] = make_number(len(arg.bounds), lineno=p.lineno(1))  # Do constant folding
    elif arg.type_ != TYPE.string:
        api.errmsg.syntax_error_expected_string(p.lineno(1), TYPE.to_string(arg.type_))
        p[0] = None
    elif is_string(arg):  # Constant string?
        p[0] = make_number(len(arg.value), lineno=p.lineno(1))  # Do constant folding
    else:
        p[0] = make_builtin(p.lineno(1), 'LEN', arg, type_=TYPE.uinteger)
1050068
private Runtime getRuntime(int runtimeID) {
    ListRuntimesArg.Builder builder = ListRuntimesArg.newBuilder();
    builder.addRuntimeIDList(runtimeID);
    builder.setCreate(true);

    Response response = executeMessage(EcmascriptMessage.LIST_RUNTIMES, builder);
    RuntimeList.Builder runtimeListBuilder = RuntimeList.newBuilder();
    buildPayload(response, runtimeListBuilder);
    List<Runtime> runtimes = runtimeListBuilder.build().getRuntimeListList();
    return (runtimes.isEmpty()) ? null : runtimes.get(0);
  }