constructor: (@user) -> console.addHistory("DetailsLayout","INIT") super() @bindTo(Hub.vent, "notes:selected",(note) => @showNote(note)) @bindTo(Hub.vent, "notes:show", => @showNotes()) @bindTo(Hub.vent, "notes:save", (note) => @saveNote(note)) @bindTo(Hub.vent, "notes:delete", (note) => @deleteNote(note)) @bindTo(Hub.vent, "notes:new", => @showNote(new Note()))
package com.x.y; public class NoteDAO extends GenericDAO<Note> { public void persist(){ save(new Note()); } }
constructor: (@user) -> console.addHistory("DetailsLayout","INIT") super() Hub.vent.on("notes:selected",(note) => @showNote(note)) Hub.vent.on("notes:show", => @showNotes()) Hub.vent.on("notes:save", (note) => @saveNote(note)) Hub.vent.on("notes:delete", (note) => @deleteNote(note)) Hub.vent.on("notes:new", => @showNote(new Note()))
database = new Database(getBaseContext(),"notes", 1); database.add (Note.class, new Table<Note> (database, Note.class)); database.table(Note.class).save (new Note("first note")); database.table(Note.class).save (new Note("second note")); database.table(Note.class).save (new Note("best note")); items.addAll(database.table(Note.class).load());
import javax.xml.bind.JAXBContext; import javax.xml.bind.Marshaller; public class Demo { public static void main(String[] args) throws Exception { JAXBContext jc = JAXBContext.newInstance(Note.class); Marshaller marshaller = jc.createMarshaller(); marshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, true); marshaller.marshal(new Note(), System.out); } }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
/** * Create a named {@link Note} associated with this Request. * * @param <E> the {@link Note} type. * @param name the {@link Note} name. * @return the {@link Note}. */ @SuppressWarnings({"unchecked"}) public static <E> Note<E> createNote(final String name) { return new Note(ATTR_BUILDER.createAttribute(name)); }
package com.x.y; public class Client { public static void main(String[] args) { NoteDAO nDao = new NoteDAO(); nDao.save(new Note()); } }
var book = new Book({ id: 1, title: "My Book" }), note = new Note({ id: 1, title: "note test" }); var collection = new Backbone.Collection([book, note]); console.log(collection.length); // 1
Scanner in = new Scanner(System.in); int t = in.nextInt(); in.nextLine(); for (int c = 0; c < t; c++) { String word = in.nextLine(); Note note = new Note(word); System.out.println("Note " + c + " says: " + note.getContent()); }