Returns the String identifying the given CUmemAttach_flags

@param n The CUmemAttach_flags
@return The String identifying the given CUmemAttach_flags
962120
public static String stringFor(int n)
    {
        if (n == 0)
        {
            return "INVALID CUmemAttach_flags: "+n;
        }
        String result = "";
        if ((n & CU_MEM_ATTACH_GLOBAL) != 0) result += "CU_MEM_ATTACH_GLOBAL ";
        if ((n & CU_MEM_ATTACH_HOST) != 0) result += "CU_MEM_ATTACH_HOST ";
        if ((n & CU_MEM_ATTACH_SINGLE) != 0) result += "CU_MEM_ATTACH_SINGLE ";
        return result;
    }
854596
public String getTextValueForPatternName(final String name) {
        Node n = this.getSingle(name);
        String text = n == null ? null : n.getText();
        return text;
    }
817982
public String getHeaderFieldKey(int n) {
        try {
            getInputStream();
        } catch (Exception e) {
            return null;
        }
        MessageHeader props = properties;
        return props == null ? null : props.getKey(n);
    }
475372
public static Pattern hasAtLeast(final int n) {
    return new Pattern() {
      @Override public int match(CharSequence src, int begin, int end) {
        if ((begin + n) > end) return MISMATCH;
        else return n;
      }
      @Override public String toString() {
        return ".{" + n + ",}";
      }
    };
  }
921181
public static String stringFor(int n)
    {
        if (n == 0)
        {
            return "CU_STREAM_WRITE_VALUE_DEFAULT";
        }
        String result = "";
        if ((n & CU_STREAM_WRITE_VALUE_NO_MEMORY_BARRIER) != 0) result += "CU_STREAM_WRITE_VALUE_NO_MEMORY_BARRIER ";
        return result;
    }
445301
public String[] getStringLabel(Instance instance,int n) {
		TPredict pred = classify(instance,Type.STRING);
		return (String[]) pred.getLabels();		
	}
900835
public static String stringFor(int n)
    {
        switch (n)
        {
            case CU_AD_FORMAT_UNSIGNED_INT8 : return "CU_AD_FORMAT_UNSIGNED_INT8";
            case CU_AD_FORMAT_UNSIGNED_INT16 : return "CU_AD_FORMAT_UNSIGNED_INT16";
            case CU_AD_FORMAT_UNSIGNED_INT32 : return "CU_AD_FORMAT_UNSIGNED_INT32";
            case CU_AD_FORMAT_SIGNED_INT8 : return "CU_AD_FORMAT_SIGNED_INT8";
            case CU_AD_FORMAT_SIGNED_INT16 : return "CU_AD_FORMAT_SIGNED_INT16";
            case CU_AD_FORMAT_SIGNED_INT32 : return "CU_AD_FORMAT_SIGNED_INT32";
            case CU_AD_FORMAT_HALF : return "CU_AD_FORMAT_HALF";
            case CU_AD_FORMAT_FLOAT : return "CU_AD_FORMAT_FLOAT";
        }
        return "INVALID CUarray_format: "+n;
    }
731687
public static String stringFor(int n)
    {
        switch (n)
        {
            case CUDNN_STATUS_SUCCESS: return "CUDNN_STATUS_SUCCESS";
            case CUDNN_STATUS_NOT_INITIALIZED: return "CUDNN_STATUS_NOT_INITIALIZED";
            case CUDNN_STATUS_ALLOC_FAILED: return "CUDNN_STATUS_ALLOC_FAILED";
            case CUDNN_STATUS_BAD_PARAM: return "CUDNN_STATUS_BAD_PARAM";
            case CUDNN_STATUS_INTERNAL_ERROR: return "CUDNN_STATUS_INTERNAL_ERROR";
            case CUDNN_STATUS_INVALID_VALUE: return "CUDNN_STATUS_INVALID_VALUE";
            case CUDNN_STATUS_ARCH_MISMATCH: return "CUDNN_STATUS_ARCH_MISMATCH";
            case CUDNN_STATUS_MAPPING_ERROR: return "CUDNN_STATUS_MAPPING_ERROR";
            case CUDNN_STATUS_EXECUTION_FAILED: return "CUDNN_STATUS_EXECUTION_FAILED";
            case CUDNN_STATUS_NOT_SUPPORTED: return "CUDNN_STATUS_NOT_SUPPORTED";
            case CUDNN_STATUS_LICENSE_ERROR: return "CUDNN_STATUS_LICENSE_ERROR";
            case CUDNN_STATUS_RUNTIME_PREREQUISITE_MISSING: return "CUDNN_STATUS_RUNTIME_PREREQUISITE_MISSING";
            case CUDNN_STATUS_RUNTIME_IN_PROGRESS: return "CUDNN_STATUS_RUNTIME_IN_PROGRESS";
            case CUDNN_STATUS_RUNTIME_FP_OVERFLOW: return "CUDNN_STATUS_RUNTIME_FP_OVERFLOW";
        }
        return "INVALID cudnnStatus: "+n;
    }
1052252
function getSymbolicString(bitmask, valueToName, zeroName) {
    const matchingFlagNames = [];

    for (const k in valueToName) {
      if (bitmask & valueToName[k]) {
        matchingFlagNames.push(k);
      }
    }

    // If no flags were matched, returns a special value.
    if (matchingFlagNames.length === 0) {
      return zeroName;
    }

    return matchingFlagNames.join(' | ');
  }
191325
public static String getXAResourceEndFlagString(int flag) {
        switch (flag) {
            case XAResource.TMFAIL:
                return "TMFAIL (" + flag + ')'; 

            case XAResource.TMSUCCESS:
                return "TMSUCCESS (" + flag + ')'; 

            case XAResource.TMSUSPEND:
                return "TMSUSPEND (" + flag + ')'; 
        }

        return "UNKNOWN XA RESOURCE END FLAG (" + flag + ')'; 
    }
784578
public String shortOrdinal(Long n) {
        return (n == null) ? null : shortOrdinal(n.longValue());
    }
362714
public static String stringFor(int n)
    {
        switch (n)
        {
            case CURAND_RNG_TEST: return "CURAND_RNG_TEST";
            case CURAND_RNG_PSEUDO_DEFAULT: return "CURAND_RNG_PSEUDO_DEFAULT";
            case CURAND_RNG_PSEUDO_XORWOW: return "CURAND_RNG_PSEUDO_XORWOW";
            case CURAND_RNG_PSEUDO_MRG32K3A: return "CURAND_RNG_PSEUDO_MRG32K3A";
            case CURAND_RNG_PSEUDO_MTGP32: return "CURAND_RNG_PSEUDO_MTGP32";
            case CURAND_RNG_PSEUDO_MT19937: return "CURAND_RNG_PSEUDO_MT19937";
            case CURAND_RNG_QUASI_DEFAULT: return "CURAND_RNG_QUASI_DEFAULT";
            case CURAND_RNG_QUASI_SOBOL32: return "CURAND_RNG_QUASI_SOBOL32";
            case CURAND_RNG_QUASI_SCRAMBLED_SOBOL32: return "CURAND_RNG_QUASI_SCRAMBLED_SOBOL32";
            case CURAND_RNG_QUASI_SOBOL64: return "CURAND_RNG_QUASI_SOBOL64";
            case CURAND_RNG_QUASI_SCRAMBLED_SOBOL64: return "CURAND_RNG_QUASI_SCRAMBLED_SOBOL64";
        }
        return "INVALID curandRngType";
    }
736557
public String getCmdLineArg() {
        StringBuilder builder = new StringBuilder("  --server-groups=");
        boolean foundSelected = false;
        for (JCheckBox serverGroup : serverGroups) {
            if (serverGroup.isSelected()) {
                foundSelected = true;
                builder.append(serverGroup.getText());
                builder.append(",");
            }
        }
        builder.deleteCharAt(builder.length() - 1); // remove trailing comma

        if (!foundSelected) return "";
        return builder.toString();
    }
278014
@SuppressWarnings("ReferenceEquality")
  public final boolean matchesQualifiedName(Node n) {
    if (n.token != token) {
      return false;
    }
    switch (token) {
      case NAME:
        // ==, rather than equal as it is intern'd in setString
        return !getString().isEmpty() && getString() == n.getString();
      case THIS:
      case SUPER:
        return true;
      case GETPROP:
        // ==, rather than equal as it is intern'd in setString
        return getLastChild().getString() == n.getLastChild().getString()
            && getFirstChild().matchesQualifiedName(n.getFirstChild());

      case MEMBER_FUNCTION_DEF:
        // These are explicitly *not* qualified name components.
      default:
        return false;
    }
  }
1212934
public String xaFlagsToString(int flags)
    {
        StringBuilder retval = new StringBuilder("Flags=");
        retval.append(Integer.toHexString(flags));
        retval.append("( ");

        if (flags == XAResource.TMNOFLAGS)
        {
            retval.append("TMNOFLAGS ");
        }
        else
        {
            if ((flags & XAResource.TMENDRSCAN)   != 0) retval.append("TMENDRSCAN ");
            if ((flags & XAResource.TMFAIL)       != 0) retval.append("TMFAIL ");
            if ((flags & XAResource.TMJOIN)       != 0) retval.append("TMJOIN ");
            if ((flags & XAResource.TMONEPHASE)   != 0) retval.append("TMONEPHASE ");
            if ((flags & XAResource.TMRESUME)     != 0) retval.append("TMRESUME ");
            if ((flags & XAResource.TMSTARTRSCAN) != 0) retval.append("TMSTARTRSCAN ");
            if ((flags & XAResource.TMSUCCESS)    != 0) retval.append("TMSUCCESS ");
            if ((flags & XAResource.TMSUSPEND)    != 0) retval.append("TMSUSPEND ");
        }

        retval.append(")");
        return retval.toString();
    }
38427
public static String stringFor(int n)
    {
        switch (n)
        {
            case cudaGraphicsCubeFacePositiveX: return "cudaGraphicsCubeFacePositiveX";
            case cudaGraphicsCubeFaceNegativeX: return "cudaGraphicsCubeFaceNegativeX";
            case cudaGraphicsCubeFacePositiveY: return "cudaGraphicsCubeFacePositiveY";
            case cudaGraphicsCubeFaceNegativeY: return "cudaGraphicsCubeFaceNegativeY";
            case cudaGraphicsCubeFacePositiveZ: return "cudaGraphicsCubeFacePositiveZ";
            case cudaGraphicsCubeFaceNegativeZ: return "cudaGraphicsCubeFaceNegativeZ";
        }
        return "INVALID cudaGraphicsCubeFace: "+n;
    }
1064642
public static String stringFor(int m)
    {
        switch (m)
        {
            case CUFFT_R2C : return "CUFFT_R2C";
            case CUFFT_C2R : return "CUFFT_C2R";
            case CUFFT_C2C : return "CUFFT_C2C";
            case CUFFT_D2Z : return "CUFFT_D2Z";
            case CUFFT_Z2D : return "CUFFT_Z2D";
            case CUFFT_Z2Z : return "CUFFT_Z2Z";
        }
        return "INVALID cufftType: " + m;
    }