Skip to content

Instantly share code, notes, and snippets.

package com.favtest.app;
import android.app.Activity;
import android.content.Context;
import android.support.v7.app.ActionBarActivity;
import android.support.v7.app.ActionBar;
import android.support.v4.app.Fragment;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.Menu;
@Override
public boolean onOptionsItemSelected(MenuItem menuItem) {
if (menuItem.getTitle().toString().equalsIgnoreCase("save")) {
new CreateItemTask(this,itemName.getText().toString(), catId).execute();
Intent returnIntent = new Intent();
returnIntent.putExtra("result", "one");
setResult(RESULT_OK, returnIntent);
finish();
return true;
}
@Omnipresent
Omnipresent / somegist
Created December 6, 2013 22:48
some gist
somegist
class MyMapScreen < PM::MapScreen
title "My Map"
start_position latitude: 35.090648651123, longitude: -82.965972900391, radius: 4
def on_appear
update_annotation_data
end
def annotation_data
[{
class FormController < Formotion::FormController
include BW::KVO
def initWithSomething
puts "came ere"
@form = Formotion::Form.new({
title: "",
sections: [
{
rows: [ {
App.obj = Ember.Object.create({
"things": Ember.A(["Dog", "CAT", "Rat"])
});
App.ApplicationController = Ember.ArrayController.extend({
selectterm: null,
submit: function (context) {
var term = this.get("selectterm");
alert(term);
}
{
"meta": {
"code": 200
}
"response": {
"stuff": [{
"id": 1,
"author": "someone",
"book": "some book"
},
package myapp
class Foo {
String message
static constraints = {
message nullable: true, blank: true
}
def save() {
request.withFormat {
json {
println "came here"
render params?.colors?.myParam
}
html {
render "html"
~/springws/spring-ws/samples/tutorial $ mvn jetty:run
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Spring WS Holiday Service Tutorial 2.1.4.RELEASE-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] >>> maven-jetty-plugin:6.1.26:run (default-cli) @ tutorial >>>
[WARNING] The POM for org.springframework.ws:spring-ws-core:jar:2.1.4.RELEASE-SNAPSHOT is missing, no dependency information available
[INFO] ------------------------------------------------------------------------