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
<body> | |
<p id="bind">Pegar Localização:</p> | |
<button onclick="getLocation()">Localizar</button> | |
<div id="map"></div> | |
<form id="form1" runat="server"> | |
<div> | |
</div> | |
</form> | |
</body> |
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.Collections.Generic; | |
using System.ServiceModel; | |
using System.ServiceModel.Web; | |
namespace appRest | |
{ | |
[ServiceContract] | |
public interface IRestService | |
{ | |
//POST operation |
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.Runtime.Serialization; | |
namespace appRest | |
{ | |
[DataContract] | |
public class Pessoa | |
{ | |
[DataMember] | |
public string Id { get; set; } |
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.Collections.Generic; | |
using System.Globalization; | |
using System.Linq; | |
using System.ServiceModel; | |
using System.ServiceModel.Activation; | |
namespace appRest | |
{ | |
[AspNetCompatibilityRequirements |
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.ServiceModel.Activation; | |
using System.Web.Routing; | |
namespace appRest | |
{ | |
public class Global : System.Web.HttpApplication | |
{ | |
protected void Application_Start(object sender, EventArgs e) | |
{ |
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
<?xml version="1.0"?> | |
<configuration> | |
<system.web> | |
<compilation debug="true" targetFramework="4.0" /> | |
</system.web> | |
<system.serviceModel> | |
<serviceHostingEnvironment aspNetCompatibilityEnabled="true"> | |
</serviceHostingEnvironment> |
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
namespace cliente | |
{ | |
public class Pessoa | |
{ | |
public string Age { get; set; } | |
public string Name { get; set; } | |
} | |
} |
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 cliente.Helper; | |
using System; | |
using System.IO; | |
using System.Linq; | |
using System.Net; | |
using System.Text; | |
namespace cliente | |
{ | |
internal class Program |
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.Web.Script.Serialization; | |
namespace cliente.Helper | |
{ | |
public static class Json | |
{ | |
public static string ToJSON(this object obj) | |
{ | |
var _serializador = new JavaScriptSerializer(); | |
return _serializador.Serialize(obj); |
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
import java.io.IOException; | |
import java.net.HttpURLConnection; | |
import java.net.URL; | |
public class Program { | |
/** | |
* @param args | |
* @throws IOException |
OlderNewer