Package com.appspot.bambugame.server.data

Examples of com.appspot.bambugame.server.data.HangmanQuestion


   
    protected void addNewSentence(String pHangmanSentence, String pHint, String pExtras)
    {
        pHangmanSentence = pHangmanSentence.trim().toLowerCase();
       
        HangmanQuestion tQuestion = new HangmanQuestion( pHangmanSentence, pHint, pExtras );
       
        Objectify tObjectify = ObjectifyService.begin();
        tObjectify.put( tQuestion );
       
       
View Full Code Here


    }
   
    protected void addNewSentence(String pHangmanSentence, String pHint, String pExtras)
    {
        pHangmanSentence = pHangmanSentence.trim().toLowerCase();
        HangmanQuestion tQuestion = new HangmanQuestion( pHangmanSentence, pHint, pExtras );
       
        Objectify tObjectify = ObjectifyService.begin();
        tObjectify.put( tQuestion );
    }
View Full Code Here

        QueryResultIterator<HangmanQuestion> tQueryResultIterable = tObjectify.query( HangmanQuestion.class ).fetch().iterator();
       
        List<String> tCountSentenceString = new ArrayList<String>();
        while (tQueryResultIterable.hasNext())
        {
            HangmanQuestion tQuestion = tQueryResultIterable.next();
            StringBuilder tQuestionCountBuilder = new StringBuilder("" + tQuestion.APPEARANCE_COUNT);
            while (tQuestionCountBuilder.length() < 9) tQuestionCountBuilder.insert( 0, '0' );
           
            tCountSentenceString.add( tQuestionCountBuilder.toString() + "|" + tQuestion.ID );
        }
View Full Code Here

        Long tRandomQuestionID = getRandomQuestionID();
       
        if (tRandomQuestionID == null) return; // this means there are no questions in the datastore
       
        Objectify tObjectify = ObjectifyService.begin();
        HangmanQuestion tQuestion = tObjectify.get( HangmanQuestion.class, tRandomQuestionID );
       
        HangmanPlurkQuestion tPlurkQuestion = new HangmanPlurkQuestion( 0, tQuestion.SENTENCE, tQuestion.HINT, tQuestion.EXTRAS );
       
        JSONObject tAddResponse = PlurkService.getInstance().plurkAdd( getQuestionSentence( tPlurkQuestion ), Qualifier.ASKS );
        tPlurkQuestion.PLURK_ID = tAddResponse.getLong( "plurk_id" );
View Full Code Here

TOP

Related Classes of com.appspot.bambugame.server.data.HangmanQuestion

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.