Android Open Source - SpareDeck Deck






From Project

Back to project page SpareDeck.

License

The source code is released under:

MIT License

If you think the Android project SpareDeck listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.hacsoft.sparedeck.decks;
/* w  w  w . j a va  2  s.co m*/
import java.util.ArrayList;

/**
 * Spare Deck - com.hacsoft.sparedeck.decks
 * Created by Fortyseven on 4/6/2014.
 */
public class Deck
{
    protected String          mDeckName;
    protected int             mDeckIconRes;
    protected ArrayList<Card> mCards;

    public Card getCard( int card_pos )
    {
        if ( card_pos > mCards.size() ) {
            throw new RuntimeException( "Card out of bounds: " + card_pos );
        }
        return mCards.get( card_pos );
    }

    public int getCardCount()
    {
        return mCards.size();
    }

    protected void addCard( String card_name, int card_image_res )
    {
        mCards.add( new Card( card_name, card_image_res ) );
    }

    protected void init( String deck_name, int deck_icon_res )
    {
        mCards = new ArrayList<Card>( 0 );
        mDeckName = deck_name;
        mDeckIconRes = deck_icon_res;
    }

    public int getDeckIconRes()
    {
        return mDeckIconRes;
    }
}




Java Source Code List

com.hacsoft.sparedeck.About.java
com.hacsoft.sparedeck.Card.java
com.hacsoft.sparedeck.DeckSelectAdapter.java
com.hacsoft.sparedeck.DeckViewer.java
com.hacsoft.sparedeck.Deck.java
com.hacsoft.sparedeck.ShowConfig.java
com.hacsoft.sparedeck.SpareDeck.java
com.hacsoft.sparedeck.decks.Card.java
com.hacsoft.sparedeck.decks.Deck.java
com.hacsoft.sparedeck.decks.IcarusDeck.java
com.hacsoft.sparedeck.decks.N3dsDeck.java
com.hacsoft.sparedeck.decks.VitaDeck.java
com.hacsoft.sparedeck.pokedex.CodeGridView.java
com.hacsoft.sparedeck.pokedex.PokedexActivity.java
com.robobunny.SeekBarPreference.java