code: public static String getAssetFile(final Context context, final String assetName) {
          // if the file is not found create it and return that.
          // if we do not have a file we copy our asset out to create one.
          AssetManager assetManager = context.getAssets();
          BufferedReader in = null;
          try {
              StringBuilder buf = new StringBuilder();
              InputStream is = assetManager.open(assetName);
              in = new BufferedReader(new InputStreamReader(is));
  
              String str;
              boolean isFirst = true;
              while ((str = in.readLine()) != null) {
                  if (isFirst)
                      isFirst = false;
                  else
                      buf.append('\n');
                  buf.append(str);
              }
              return buf.toString();
          } catch (IOException e) {
              BoxLogUtils.e("getAssetFile", assetName, e);
          } finally {
              try {
                  if (in != null) {
                      in.close();
                  }
              } catch (Exception e) {
                  BoxLogUtils.e("getAssetFile", assetName, e);
              }
          }
          // should never get here unless the asset file is inaccessible or cannot be copied out.
          return null;
      }
docs: Helper method for reading an asset file into a string.
  
  @param context   current context.
  @param assetName the asset name
  @return a string representation of a file in assets.