Java tutorial
//package com.java2s; /* * z2env.org - (c) ZFabrik Software KG * * Licensed under Apache 2. * * www.z2-environment.net */ public class Main { /** * Extracts the component simple name from the fully qualified component * name. This is simply the part following the last "/". */ public static String simpleName(String componentName) { int p = componentName.lastIndexOf('/'); if (p >= 0) { return componentName.substring(p + 1); } return null; } }