This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static void sendSms(String phone, String mes) { | |
URL obj; | |
try { | |
obj = new URL(urlFor(phone, mes)); | |
HttpURLConnection con; | |
con = (HttpURLConnection) obj.openConnection(); | |
con.setRequestMethod("GET"); | |
BufferedReader in = new BufferedReader(new InputStreamReader( | |
con.getInputStream())); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bool AppDelegate::applicationDidFinishLaunching() { | |
// initialize director | |
auto director = Director::getInstance(); | |
auto glview = director->getOpenGLView(); | |
if(!glview) { | |
glview = GLView::create("SimpleRPG"); | |
director->setOpenGLView(glview); | |
} | |
//glview->setFrameSize(1024, 768); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rapidjson::Document jsonDoc; | |
rapidjson::Document::AllocatorType& allocator = jsonDoc.GetAllocator(); | |
jsonDoc.SetObject(); | |
rapidjson::Value mainArr(rapidjson::kArrayType); | |
for (int i = 0; i < 6; ++i) { | |
rapidjson::Value row(rapidjson::kArrayType); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Magick++.h> | |
using namespace Magick; | |
.... | |
vector<Image> imageList; | |
readImages( &imageList, "FAX.PDF" ); | |
for (int i = 0; i < imageList.size(); i++) { | |
stringstream fileName; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.File; | |
import java.io.IOException; | |
import java.io.PrintWriter; | |
import java.util.Arrays; | |
import java.util.Scanner; | |
public class Main { | |
public static void main(String [] args) throws IOException { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.File; | |
import java.io.IOException; | |
import java.io.PrintWriter; | |
import java.util.Arrays; | |
import java.util.Scanner; | |
public class Main { | |
public static void main(String [] args) throws IOException { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.File; | |
import java.io.IOException; | |
import java.io.PrintWriter; | |
import java.util.Arrays; | |
import java.util.Scanner; | |
public class Main { | |
public static void main(String [] args) throws IOException { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
template<class T> | |
class WrapperVector { | |
public: | |
WrapperVector(size_t n = 10): | |
_data(new T[n]()), | |
_size(n) | |
{ | |
} | |
WrapperVector(const WrapperVector<T> & other): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public override ActionResult Execute(RAIN.Core.AI ai) | |
{ | |
if (!WanderTargetVariable.IsVariable) | |
throw new Exception("The Choose Wander Position node requires a valid Wander Target Variable"); | |
float tWanderDistance = 0f; | |
if (WanderDistance.IsValid) | |
tWanderDistance = WanderDistance.Evaluate<float>(ai.DeltaTime, ai.WorkingMemory); | |
if (tWanderDistance <= 0f) |
OlderNewer