This file contains hidden or 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
| package com.your.project; | |
| import java.io.IOException; | |
| import java.io.InputStream; | |
| import java.lang.ref.SoftReference; | |
| import java.net.MalformedURLException; | |
| import java.net.URL; | |
| import java.net.URLConnection; | |
| import java.util.Collections; | |
| import java.util.HashMap; |
This file contains hidden or 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
| var engine = new JintEngine(); | |
| engine.SetFunction("alert", new Action<string>(t => MessageBox.Show(t))); | |
| engine.Run("alert('Hello World, from dynamically interpereted JavaScript on WP7!')"); |
This file contains hidden or 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
| MongoServer server = MongoServer.Create("mongodb://TheUserName:ThePassword@The.Url.Com:12345/TheDatabaseId"); | |
| MongoDatabase mongo = server.GetDatabase("<TheDatabaseId>"); | |
| var employees = mongo.GetCollection<TheClass>("TheCollectionName"); | |
| var cursor = employees.FindAllAs<TheClass>(); | |
| var item = cursor.FirstOrDefault(); | |
| .... |
This file contains hidden or 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
| using System; | |
| using System.Threading.Tasks; | |
| namespace Life | |
| { | |
| public class LifeSimulation | |
| { | |
| private bool[,] world; | |
| private bool[,] nextGeneration; | |
| private Task processTask; |
NewerOlder