System directories
| Method | Result |
|---|---|
| Environment.getDataDirectory() | /data |
| Environment.getDownloadCacheDirectory() | /cache |
| Environment.getRootDirectory() | /system |
External storage directories
| #!/bin/bash -e | |
| clear | |
| echo "============================================" | |
| echo "WordPress Install Script" | |
| echo "============================================" | |
| echo "Database Name: " | |
| read -e dbname | |
| echo "Database User: " | |
| read -e dbuser | |
| echo "Database Password: " |
| /* | |
| * Copyright (c) 2017 Emil Davtyan | |
| * | |
| * Permission is hereby granted, free of charge, to any person obtaining | |
| * a copy of this software and associated documentation files (the | |
| * "Software"), to deal in the Software without restriction, including | |
| * without limitation the rights to use, copy, modify, merge, publish, | |
| * distribute, sublicense, and/or sell copies of the Software, and to | |
| * permit persons to whom the Software is furnished to do so, subject to | |
| * the following conditions: |
System directories
| Method | Result |
|---|---|
| Environment.getDataDirectory() | /data |
| Environment.getDownloadCacheDirectory() | /cache |
| Environment.getRootDirectory() | /system |
External storage directories
| package com.example.youtubeparse; | |
| import java.io.IOException; | |
| import java.io.UnsupportedEncodingException; | |
| import java.net.URLDecoder; | |
| import java.net.URLEncoder; | |
| import java.util.ArrayList; | |
| import java.util.Collections; | |
| import java.util.HashMap; | |
| import java.util.List; |
| #!/bin/sh | |
| # Detects which OS and if it is Linux then it will detect which Linux Distribution. | |
| OS=`uname -s` | |
| REV=`uname -r` | |
| MACH=`uname -m` | |
| if [ "${OS}" = "SunOS" ] ; then | |
| OS=Solaris | |
| ARCH=`uname -p` |
| // Specific class for a RealmList<Bar> field | |
| public class BarListParcelConverter extends RealmListParcelConverter<Bar> { | |
| @Override | |
| public void itemToParcel(Bar input, Parcel parcel) { | |
| parcel.writeParcelable(Parcels.wrap(input), 0); | |
| } | |
| @Override | |
| public Bar itemFromParcel(Parcel parcel) { |
| #!/bin/sh | |
| # Linux(Distribution) MacOS SunOS AIX に対応 | |
| OS=`uname -s` | |
| REV=`uname -r` | |
| MACH=`uname -m` | |
| GetVersionFromFile() { | |
| VERSION="$(tr "\n" ' ' < cat "$1" | sed s/.*VERSION.*=\ // )" | |
| } |
| import android.content.Context; | |
| import android.util.Log; | |
| import com.jakewharton.picasso.OkHttp3Downloader; | |
| import com.squareup.picasso.Picasso; | |
| /** | |
| * Created by Hrishikesh Kadam on 19/12/2017 | |
| */ |