Get resource name from path. The format of the object id is

<pre>
type / path / objectName
</pre>

@param id
object id
@return resource name
186305
protected String getObjectName(String id) {
        // The format of the object id is <type>/<path>/<objectName>
        String result = id.substring(id.lastIndexOf('/') + 1);
        if (result.equals(PERSISTENCE_NO_NAME)) {
            result = null;
        }
        return result;
    }
914021
public static DataSourceBackendId getInstance(String id) {
        DataSourceBackendId result = cache.get(id);
        if (result == null) {
            id = id.intern();
            result = new DataSourceBackendId(id);
            cache.put(id, result);
        }
        return result;
    }
531732
public static String parentResourceIdFromResourceId(String id) {
        if (id == null) {
            return null;
        }
        ResourceId resourceId = ResourceId.fromString(id);
        if (resourceId != null && resourceId.parent() != null) {
            return ResourceId.fromString(id).parent().id();
        }

        return null;
    }
1097407
public static String resourceTypeFromResourceId(String id) {
        return (id != null) ? ResourceId.fromString(id).resourceType() : null;
    }
864253
@Override
	public Set<String> getResourceNames(String path) {
		return helper.getResourceNames(resolver.getResourcePath(path));
	}
1084040
protected function getFileName($id)
    {
        if (is_dir($id)) {
            return sprintf('%1$s/%2$s.%3$s', rtrim($id, DIRECTORY_SEPARATOR), StringUtils::random(20), $this->extension);
        }

        $dirName = dirname($id);

        if (!file_exists($id) && $dirName === '.') {
             return sprintf('%1$s/%2$s', $this->directory, $id);
        }

        if (!file_exists($id) && !is_writable($dirName)) {
            throw new NotWritableException(sprintf('File could not be written to system as target is not writable: %s', $id));
        }

        return $id;
    }
708704
public static int getId(Context context, String id, String defType) {
        String type = "R." + defType + ".";
        if (id.startsWith(type)) {
            id = id.substring(type.length());
        }

        Resources r = context.getResources();
        int resId = r.getIdentifier(id, defType,
                context.getPackageName());
        if (resId > 0) {
            return resId;
        } else {
            throw new RuntimeAssertion("Specified resource '%s' could not be found", id);
        }
    }
150728
@Override
	public Set<String> getResourceNames(String path) {
		path = path.replace('/', File.separatorChar);
		File resource = new File(baseDir, path);
		return FileUtils.getResourceNames(resource);
	}
418254
public String getUserResourceInstanceUri(final String path, final String instanceId){
        if(StringUtils.isEmpty(path) || StringUtils.isEmpty(instanceId)) {
            throw new IllegalArgumentException("Path and Instance Id cannot be null");
        }
        return getUserResourceUri(path) + "/" + instanceId;
    }
714275
public Map<String, Object> loadById(String id) {
        final String sid = sessionPrefix + ":" + id;
        try {
            return this.executor.execute(new RedisCallback<Map<String, Object>>() {
                public Map<String, Object> execute(Jedis jedis) {
                    String session = jedis.get(sid);
                    if (!Strings.isNullOrEmpty(session)) {
                        return serializer.deserialize(session);
                    }
                    return Collections.emptyMap();
                }
            });
        } catch (Exception e) {
            log.error("failed to load session(key={}), cause:{}", sid, Throwables.getStackTraceAsString(e));
            throw new SessionException("load session failed", e);
        }
    }
1302708
@RequestMapping(value = "/get.action", method = RequestMethod.GET)
    public ResponseEntity<?> getFile(@RequestParam Integer id) {

        final HttpHeaders responseHeaders = new HttpHeaders();
        Map<String, Object> responseMap = new HashMap<String, Object>();

        try {
            File file = service.findById(id);

            if (file == null) {
                throw new Exception("Could not find the file with id " + id);
            }

            byte[] fileBytes = file.getFile();

            responseHeaders.setContentType(
                MediaType.parseMediaType(file.getFileType()));

            LOG.info("Successfully got the file " + file.getFileName());

            responseMap = ResultSet.success(file);
            return new ResponseEntity<byte[]>(
                fileBytes, responseHeaders, HttpStatus.OK);
        } catch (Exception e) {
            LOG.error("Could not get the file: " + e.getMessage());
            responseMap = ResultSet.error("Could not get the file: " +
                e.getMessage());

            responseHeaders.setContentType(MediaType.APPLICATION_JSON);

            return new ResponseEntity<Map<String, Object>>(
                responseMap, responseHeaders, HttpStatus.OK);
        }
    }
398955
@Override
    protected String getInstanceIdName(int id)
    {
        switch (id - super.getMaxInstanceId()) {
          case Id_ignoreComments:               return "ignoreComments";
          case Id_ignoreProcessingInstructions: return "ignoreProcessingInstructions";
          case Id_ignoreWhitespace:             return "ignoreWhitespace";
          case Id_prettyIndent:                 return "prettyIndent";
          case Id_prettyPrinting:               return "prettyPrinting";
        }
        return super.getInstanceIdName(id);
    }
1265419
protected String getObjectPath(String id, String name) {
        // The format of the object id is <type>/<path>/<objectName>
        id = id.substring(id.indexOf('/') + 1);
        if (id.charAt(0) == '/') {
            id = id.substring(1);
        }
        if (id.lastIndexOf(name) <= 0) {
            return id;
        }
        return id.substring(0, id.lastIndexOf(name) - 1);
    }
466361
@Override
  public Collection<Block> getByResourceId(String resourceId) {
    ensureSorted();

    // prepare resourceId for binary search
    resourceIds[size] = resourceId;
    resourceIdsIndex[size] = size;

    int index = DataUtils.binarySearch(byResourceId);

    List<Block> result = new ArrayList<>();
    int realIndex = resourceIdsIndex[index];
    while (index < size && FastStringComparator.INSTANCE.compare(resourceIds[realIndex], resourceId) == 0) {
      result.add(getBlock(realIndex, resourceId));

      index++;
      realIndex = resourceIdsIndex[index];
    }
    return result;
  }
180506
public static String getArtefactDirectory(String path) {

        if (path != null) {
            final Matcher matcher = RESOURCE_PATH_PATTERN.matcher(path);
            if (matcher.find()) {
                return matcher.group(1);
            }
        }
        return null;
    }
937667
public Resource getResource(String path) {
        final Resource descriptorResource = descriptor.getResource();

        try {
            Resource resource = descriptorResource.createRelative("static" + path);
            if (resource.exists()) {
                return resource;
            }
        } catch (IOException e) {
            return null;
        }
        return null;
    }
493831
public static Bridge get(final String id) throws Exception {
        
        final BandwidthClient client = BandwidthClient.getInstance();
        return get(client, id); 
    }