Java File Name Create filename(String filename)

Here you can find the source of filename(String filename)

Description

filename

License

Open Source License

Declaration

public static String filename(String filename) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static String filename(String filename) {
        int dot = filename.lastIndexOf(".");

        if (dot == -1) {
            return filename;
        }/*w w w .  ja v a  2 s.c  o  m*/

        return filename.substring(0, dot);
    }
}

Related

  1. fileName(Class clazz)
  2. filename(final String path)
  3. fileName(String contentFile)
  4. fileName(String file)
  5. fileName(String file, String moduleName)
  6. fileName(String filename)
  7. filename(String filename)
  8. fileName(String name)
  9. filename(String name)