$ xcrun simctl list --json
$ xcrun simctl delete unavailable
#include <iostream> | |
// get_type<i, Ts...>::type -> Ts[i] (Compile error of i >= length(Ts)) | |
template<size_t i, typename T, typename... Ts> | |
struct get_type { | |
typedef typename get_type<i - 1, Ts...>::type type; | |
}; | |
template<typename T, typename... Ts> |
package com.example.test; | |
import android.content.Intent; | |
import android.os.Bundle; | |
import android.util.Log; | |
import java.util.Set; | |
import static android.content.Intent.URI_INTENT_SCHEME; |
/* | |
* Copyright (c) 1996, 1998, Oracle and/or its affiliates. All rights reserved. | |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | |
* | |
* This code is free software; you can redistribute it and/or modify it | |
* under the terms of the GNU General Public License version 2 only, as | |
* published by the Free Software Foundation. Oracle designates this | |
* particular file as subject to the "Classpath" exception as provided | |
* by Oracle in the LICENSE file that accompanied this code. | |
* |
import android.content.Context; | |
import android.util.Log; | |
import com.mixpanel.android.mpmetrics.MixpanelAPI; | |
import org.json.JSONException; | |
import org.json.JSONObject; | |
import java.text.DateFormat; | |
import java.text.SimpleDateFormat; |
#ifndef BACKTRACE_UTILS_h | |
#define BACKTRACE_UTILS_h | |
// ref: http://stackoverflow.com/questions/8115192/android-ndk-getting-the-backtrace | |
#include <cstdio> | |
#include <ostream> | |
#include <sstream> | |
size_t captureBacktrace(void** buffer, size_t max); |
C++ code style written in markdown.
Astyle code automatic formatting settings
You can use clang-format too.
Use tools like vera++
#include <utils/CallStack.h> | |
namespace test { | |
void myfun(){ | |
android::CallStack stack; | |
stack.update(); | |
stack.log("<Stack prefix here>"); | |
} | |
} |
#ifndef _MACARON_BASE64_H_ | |
#define _MACARON_BASE64_H_ | |
/** | |
* The MIT License (MIT) | |
* Copyright (c) 2016-2024 tomykaira | |
* | |
* 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 |