If the logo is local, you can provide a drawable instead of a URL
Provide the id from R.drawable.{id} as a String
@param id resource name of your logo
@param yourPackageName Package name of your app (should be a temporary thing)
@return Itself
553630
public Channel setLogoDrawable(String id, String yourPackageName) {
        String endpoint = "android.resource://"+id+"/drawable/";
        this.logoUrl = endpoint + id;
        return this;
    }
709755
public static String mapToID(final String aPtPath) throws InvalidPathException {
        final String encapsulatingDir = getEncapsulatingDir(aPtPath);

        String id = aPtPath;

        if (id.endsWith(Character.toString(mySeparator))) {
            id = id.substring(0, id.length() - 1);
        }

        if (encapsulatingDir != null) {
            id = id.substring(0, id.length() - encapsulatingDir.length());
        }

        id = id.replace(Character.toString(mySeparator), "");
        id = decodeID(id);

        return id;
    }
178054
public Content getPackageHeader(String packageName) {
        Content heading = HtmlTree.HEADING(HtmlConstants.PACKAGE_HEADING, true,
                contents.packageLabel);
        heading.addContent(Contents.SPACE);
        heading.addContent(packageName);
        return heading;
    }
1220371
function loadTheme(id) {
        var extension = extensions[id];
        if (extension.installInfo && extension.installInfo.metadata && extension.installInfo.metadata.theme) {
            ThemeManager.loadPackage(extension.installInfo);
        }
    }
800243
public String getAssetURL(String id) {
        String url = getRepositoryUrl() + "/assets/" + id + "?";
        if (getUserId() != null) {
            url += "userId=" + getUserId();
        }
        if (getUserId() != null && getPassword() != null) {
            url += "&password=" + getPassword();
        }
        if (getApiKey() != null) {
            url += "&apiKey=" + getApiKey();
        }
        return url;
    }
492004
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
    private static Drawable getDrawable(Context context, @DrawableRes int drawableResId) {
        if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
            return context.getDrawable(drawableResId);
        } else {
            return context.getResources().getDrawable(drawableResId);
        }
    }
903713
public static Expression id(String id) {
    CodeChunkUtils.checkId(id);
    return Leaf.create(id, /* isCheap= */ true);
  }
831591
static String fromPackageName(String packageName) {
        List<String> tokens = tokenOf(packageName);
        return fromTokens(tokens);
    }
277490
private StringBuilder makeNewPackageName(final StringBuilder packageName, final File dir) {
		if (packageName.length() == 0) {
			return new StringBuilder(dir.getName());
		} else {
			return new StringBuilder(packageName).append(PATH_SEPARATOR).append(dir.getName());
		}
	}
361651
@RequestMapping(value = "/getThumbnail.action", method = RequestMethod.GET)
    public ResponseEntity<?> getThumbnail(@RequestParam Integer id) {

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

        try {
            // try to get the image
            ImageFile image = service.findById(id);
            if (image == null) {
                throw new Exception("Could not find the image with id " + id);
            }

            byte[] imageBytes = null;

            imageBytes = image.getThumbnail();

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

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

            return new ResponseEntity<byte[]>(
                imageBytes, responseHeaders, HttpStatus.OK);
        } catch (Exception e) {
            final String errorMessage = "Could not get the image thumbnail: "
                + e.getMessage();

            LOG.error(errorMessage);
            responseMap = ResultSet.error(errorMessage);

            responseHeaders.setContentType(MediaType.APPLICATION_JSON);

            return new ResponseEntity<Map<String, Object>>(
                responseMap, responseHeaders, HttpStatus.OK);
        }
    }
1041000
public static String getCustomID(String id) {
        int[] fields = new int[4];
        if (parseCustomID(id, fields)) {
            return formatCustomID(fields[1], fields[2], fields[3], fields[0] < 0);
        }
        return null;
    }
841979
public static WComponent getComponentWithId(final WComponent root, final String id) {
		return getComponentWithId(root, id, false);
	}
166257
public String getPmPackageId() {
		StringBuilder sb = new StringBuilder();
		if (pm != null) sb.append(pm);
		sb.append(":");
		if (group != null) sb.append(group);
		sb.append(":");
		if (name != null) sb.append(name);
		sb.append(":");
		if (version != null) sb.append(version);
		sb.append(":");
		return sb.toString();
	}
1206307
private Drawable getIcon(@ColorRes int colorId) {
        Drawable icon = ContextCompat.getDrawable(this, R.drawable.ic_place_white_24dp);
        if (icon == null) {
            throw new NullPointerException();
        }
        icon = DrawableCompat.wrap(icon);
        DrawableCompat.setTint(icon, ContextCompat.getColor(this, colorId));
        return icon;
    }
193803
public String getIdValue(final URI id) {
        if (id == null) {
            return null;
        }
        final URI localId = id.normalize();
        return idMap.get(localId);
    }
676578
@Nullable
    public Container getContainerWithId(@Nonnull String id) {
        if (id == null || id.trim().length() == 0) {
            throw new IllegalArgumentException("A container ID must be provided.");
        }

        for (Container container : getContainers()) {
            if (container.getId().equals(id)) {
                return container;
            }
        }

        return null;
    }
715533
public String compress(int drawableID) throws IOException {

        // Create a bitmap from this drawable
        Bitmap bitmap = BitmapFactory.decodeResource(mContext.getApplicationContext().getResources(), drawableID);
        if (null != bitmap) {
            // Create a file from the bitmap

            // Create an image file name
            String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss", Locale.ENGLISH).format(new Date());
            String imageFileName = "JPEG_" + timeStamp + "_";
            File storageDir = Environment.getExternalStoragePublicDirectory(
                    Environment.DIRECTORY_PICTURES);
            File image = File.createTempFile(
                    imageFileName,  /* prefix */
                    ".jpg",         /* suffix */
                    storageDir      /* directory */
            );
            FileOutputStream out = new FileOutputStream(image);
            bitmap.compress(Bitmap.CompressFormat.JPEG, 100, out);

            // Compress the new file
            Uri copyImageUri = FileProvider.getUriForFile(mContext, FILE_PROVIDER_AUTHORITY, image);

            String compressedImagePath = compressImage(image.getAbsolutePath(), new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES), "Silicompressor/images"));

            // Delete the file created from the drawable Id
            if (image.exists()) {
                deleteImageFile(image.getAbsolutePath());
            }

            // return the path to the compressed image
            return compressedImagePath;
        }

        return null;
    }