Example usage for java.lang String toLowerCase

List of usage examples for java.lang String toLowerCase

Introduction

In this page you can find the example usage for java.lang String toLowerCase.

Prototype

public String toLowerCase(Locale locale) 

Source Link

Document

Converts all of the characters in this String to lower case using the rules of the given Locale .

Usage

From source file:Main.java

public static void main(String[] args) {

    String str = "java2s.com";

    System.out.println(str.toLowerCase(Locale.getDefault()));
}

From source file:Main.java

private static String formatKey(String name) {
    return name.toLowerCase(Locale.US);
}

From source file:Main.java

public static boolean isOGGFile(String in) {
    return in.toLowerCase(Locale.US).endsWith(".ogg");
}

From source file:Main.java

public static boolean isOGMFile(String in) {
    return in.toLowerCase(Locale.US).endsWith(".ogm");
}

From source file:Main.java

public static boolean isFLACFile(String in) {
    in = in.toLowerCase(Locale.US);
    return in.endsWith(".flac") || in.endsWith(".fla");
}

From source file:Main.java

public static boolean isM4AFile(String in) {
    in = in.toLowerCase(Locale.US);
    return in.endsWith(".m4a") || in.endsWith(".m4p");
}

From source file:Main.java

public static String drawableName(String appName) {
    return appName.toLowerCase(Locale.getDefault()).replace(" ", "_");
}

From source file:Main.java

public static boolean isASFFile(String in) {
    in = in.toLowerCase(Locale.US);
    return in.endsWith(".asf") || in.endsWith(".wm");
}

From source file:Main.java

/**
 * Calculate bucket id for the specified path.
 * @param imageFilePath the file path of the local storage.
 * @return an identifier of the album bucket.
 *///from w w w .ja va 2  s  .c  om
public static int getBucketIdHash(String imageFilePath) {
    return imageFilePath.toLowerCase(Locale.US).hashCode();
}

From source file:Main.java

private static String trimUrlWebdav(String url) {
    if (url.toLowerCase(Locale.ROOT).endsWith(WEBDAV_PATH_4_0_AND_LATER)) {
        return url.substring(0, url.length() - WEBDAV_PATH_4_0_AND_LATER.length());
    }/*  w  w  w.j a v a  2 s  .  c om*/

    return url;
}