getBaseName static method

String getBaseName(
  1. String fullName
)

Implementation

static String getBaseName(String fullName) {
  var idx = fullName.indexOf('.');
  if (idx > 0) {
    return fullName.substring(0, idx);
  } else {
    if (idx == 0) {
      return '';
    } else {
      return fullName;
    }
  }
}