Skip to content

Instantly share code, notes, and snippets.

View SaitejaP's full-sized avatar

Saiteja Parsi SaitejaP

View GitHub Profile
@SaitejaP
SaitejaP / java_tips.md
Last active March 17, 2022 03:33
Java tips and tricks

// To initialize the ArrayList with the same value for all of its elements // count is number of elements and element is the item value List arrList = new ArrayList(Collections.nCopies(count, element));

@SaitejaP
SaitejaP / wkhtmltopdf_wkhtmltoimage.md
Created November 16, 2017 12:53 — forked from isogram/wkhtmltopdf_wkhtmltoimage.md
How to manually install Wktohtmlpdf and Wkhtmltoimage in Ubuntu Server

How to Install Wkhtmltopdf and Wkhtmltoimage in Ubuntu

#!/bin/sh

sudo apt-get install -y openssl build-essential xorg libssl-dev
wget https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.4/wkhtmltox-0.12.4_linux-generic-amd64.tar.xz
tar xf wkhtmltox-0.12.4_linux-generic-amd64.tar.xz
cd wkhtmltox/bin/
mv wkhtmltopdf  /usr/bin/wkhtmltopdf
mv wkhtmltoimage /usr/bin/wkhtmltoimage
@SaitejaP
SaitejaP / activity_main.xml
Created October 21, 2015 13:32
Parallax Scrolling Tabs with Android Design Support Library
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.DrawerLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/navdrawer_layout"
android:layout_height="match_parent"
android:layout_width="match_parent"
android:fitsSystemWindows="true">
<android.support.design.widget.CoordinatorLayout
@SaitejaP
SaitejaP / log.txt
Created October 10, 2015 19:26
Leah analysis failed
In in.viato.app:1.0:1.
* FAILURE:
org.eclipse.mat.SnapshotException: SnapshotImpl_Error_ObjectNotFound
at org.eclipse.mat.parser.internal.SnapshotImpl.mapAddressToId(SnapshotImpl.java:1194)
at org.eclipse.mat.snapshot.model.ObjectReference.getObjectId(ObjectReference.java:38)
at org.eclipse.mat.snapshot.model.ObjectReference.getObject(ObjectReference.java:42)
at org.eclipse.mat.parser.model.AbstractObjectImpl.resolveValue(AbstractObjectImpl.java:149)
at com.squareup.leakcanary.HeapAnalyzer.findLeakingReference(HeapAnalyzer.java:161)
at com.squareup.leakcanary.HeapAnalyzer.checkForLeak(HeapAnalyzer.java:95)
at com.squareup.leakcanary.internal.HeapAnalyzerService.onHandleIntent(HeapAnalyzerService.java:57)