text stringlengths 3 1.18M |
|---|
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.nineoldandroids.view.animation;
import java.lang.ref.WeakReference;
import java.util.WeakHashMap;
import android.graphics.Matrix;
import android.graphics.RectF;
import android.os.Build;
import android.util.FloatMath;
import android.view.View;
import android.view.animation.Animati... |
package com.actionbarsherlock.internal.nineoldandroids.view;
import android.content.Context;
import android.util.AttributeSet;
import android.view.ViewGroup;
import com.actionbarsherlock.internal.nineoldandroids.view.animation.AnimatorProxy;
public abstract class NineViewGroup extends ViewGroup {
private final A... |
package com.actionbarsherlock.internal.nineoldandroids.widget;
import android.content.Context;
import android.util.AttributeSet;
import android.widget.FrameLayout;
import com.actionbarsherlock.internal.nineoldandroids.view.animation.AnimatorProxy;
public class NineFrameLayout extends FrameLayout {
private final ... |
package com.actionbarsherlock.internal.nineoldandroids.widget;
import android.content.Context;
import android.widget.HorizontalScrollView;
import com.actionbarsherlock.internal.nineoldandroids.view.animation.AnimatorProxy;
public class NineHorizontalScrollView extends HorizontalScrollView {
private final Animator... |
package com.actionbarsherlock.internal.nineoldandroids.widget;
import android.content.Context;
import android.util.AttributeSet;
import android.widget.LinearLayout;
import com.actionbarsherlock.internal.nineoldandroids.view.animation.AnimatorProxy;
public class NineLinearLayout extends LinearLayout {
private fin... |
package com.actionbarsherlock.internal.app;
import java.util.HashSet;
import java.util.Set;
import android.app.Activity;
import android.content.Context;
import android.graphics.drawable.Drawable;
import android.support.v4.app.FragmentActivity;
import android.support.v4.app.FragmentTransaction;
import android.view.Vie... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2011 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.view.menu;
import android.graphics.drawable.Drawable;
import android.view.View;
import com.actionbarsherlock.view.MenuItem;
import com.actionbarsherlock.view.SubMenu;
public class SubMenuWrapper extends MenuWrapper implements SubMenu {
private final android.view.SubMenu mNat... |
/*
* Copyright (C) 2011 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.view.menu;
import android.content.Intent;
import android.graphics.drawable.Drawable;
import android.view.ContextMenu.ContextMenuInfo;
import android.view.View;
import com.actionbarsherlock.internal.view.ActionProviderWrapper;
import com.actionbarsherlock.internal.widget.Collapsib... |
package com.actionbarsherlock.internal.view.menu;
import java.util.WeakHashMap;
import android.content.ComponentName;
import android.content.Intent;
import android.view.KeyEvent;
import com.actionbarsherlock.view.Menu;
import com.actionbarsherlock.view.MenuItem;
import com.actionbarsherlock.view.SubMenu;
public class... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2011 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.view;
import com.actionbarsherlock.internal.view.menu.SubMenuWrapper;
import com.actionbarsherlock.view.ActionProvider;
import android.view.View;
public class ActionProviderWrapper extends android.view.ActionProvider {
private final ActionProvider mProvider;
public Act... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.view;
import android.view.View;
public interface View_OnAttachStateChangeListener {
void onViewAttachedToWindow(View v);
void onViewDetachedFromWindow(View v);
}
|
package com.actionbarsherlock.internal.view;
public interface View_HasStateListenerSupport {
void addOnAttachStateChangeListener(View_OnAttachStateChangeListener listener);
void removeOnAttachStateChangeListener(View_OnAttachStateChangeListener listener);
}
|
package com.actionbarsherlock.internal;
import static android.view.ViewGroup.LayoutParams.MATCH_PARENT;
import static com.actionbarsherlock.internal.ResourcesCompat.getResources_getBoolean;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import org.xmlpull.v1.XmlPullParser;
import android.... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.widget;
import android.view.View;
import android.widget.FrameLayout;
import com.actionbarsherlock.view.CollapsibleActionView;
/**
* Wraps an ABS collapsible action view in a native container that delegates the calls.
*/
public class CollapsibleActionViewWrapper extends FrameLa... |
package com.actionbarsherlock.internal.widget;
import android.graphics.Canvas;
import android.graphics.ColorFilter;
import android.graphics.Paint;
import android.graphics.drawable.Drawable;
/**
* A version of {@link android.graphics.drawable.ColorDrawable} that respects bounds.
*/
public class IcsColorDrawable exte... |
/*
* Copyright (C) 2007 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.widget;
import android.content.Context;
import android.content.res.TypedArray;
import android.graphics.Canvas;
import android.graphics.drawable.Drawable;
import android.util.AttributeSet;
import android.view.View;
import android.widget.LinearLayout;
import com.actionbarsherlock.... |
package com.actionbarsherlock.internal.widget;
import com.actionbarsherlock.R;
import android.content.Context;
import android.content.res.Resources;
import android.database.DataSetObserver;
import android.graphics.Rect;
import android.graphics.drawable.Drawable;
import android.os.Build;
import android.os.Handler;
imp... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.widget;
import android.view.View;
final class IcsView {
//No instances
private IcsView() {}
/**
* Return only the state bits of {@link #getMeasuredWidthAndState()}
* and {@link #getMeasuredHeightAndState()}, combined into one integer.
* The width comp... |
package com.actionbarsherlock.internal.widget;
import android.content.Context;
import android.content.res.TypedArray;
import android.os.Build;
import android.util.AttributeSet;
import android.widget.TextView;
import java.util.Locale;
public class CapitalizingTextView extends TextView {
private static final boole... |
package com.actionbarsherlock.internal.widget;
import static android.view.View.MeasureSpec.EXACTLY;
import android.content.Context;
import android.content.res.TypedArray;
import android.util.AttributeSet;
import android.util.DisplayMetrics;
import android.util.TypedValue;
import android.widget.LinearLayout;
import com... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2011 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2006 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
/*
* Copyright (C) 2011 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
package com.actionbarsherlock.internal.widget;
import java.util.Locale;
import android.content.Context;
import android.content.res.TypedArray;
import android.os.Build;
import android.util.AttributeSet;
import android.widget.Button;
public class CapitalizingButton extends Button {
private static final boolean SANS... |
package com.actionbarsherlock.internal;
import android.content.Context;
import android.os.Build;
import android.util.DisplayMetrics;
import com.actionbarsherlock.R;
public final class ResourcesCompat {
//No instances
private ResourcesCompat() {}
/**
* Support implementation of {@code getResources()... |
package com.vdom.players;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Random;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.CurseCard;
import com.vdom.api.GameEvent;
import com.vdom.... |
package com.vdom.players;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.Random;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.GameType;
import com.vdom.api.TreasureCard;
import com.vdom.api.VictoryCard;
import com.vdom.core.BasePlayer;
import com.vdom.core.Car... |
package com.vdom.players;
import com.vdom.api.Card;
import com.vdom.api.GameType;
import com.vdom.core.Cards;
public class VDomPlayerDrew extends VDomPlayerSarah {
public boolean isAi() {
return true;
}
public void setupGameVariables(GameType gameType, Card[] cardsInPlay) {
trashCard... |
package com.vdom.players;
import java.util.ArrayList;
import com.vdom.api.Card;
import com.vdom.api.GameType;
import com.vdom.core.Cards;
public class VDomPlayerMary extends VDomPlayerSarah {
public boolean isAi() {
return true;
}
public void setupGameVariables(GameType gameType, Card[] cardsInP... |
package com.vdom.players;
import java.util.ArrayList;
import java.util.Random;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.TreasureCard;
import com.vdom.core.BasePlayer;
import com.vdom.core.Cards;
import com.vdom.core.MoveContext;
public class VDomPlayerChuck extends BasePlayer {
... |
package com.vdom.players;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.Random;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.CardCostComparator;
import com.vdom.api.GameEvent;
import com.vdom.api.TreasureCard;
import c... |
package com.vdom.core;
import java.net.URL;
import java.net.URLClassLoader;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Map.Entry;
i... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Iterator;
import com.vdom.api.Card;
import com.vdom.api.GameEvent;
public class CardList implements Iterable<Card> {
ArrayList<Card> a = new ArrayList<Card>();
Player player;
String n... |
package com.vdom.core;
import com.vdom.api.ReactionCard;
public class ReactionCardImpl extends CardImpl implements ReactionCard
{
public ReactionCardImpl(Cards.Type type, int cost)
{
super(type, cost);
}
protected ReactionCardImpl(Builder builder)
{
super(builder);
}
public ... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.List;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.TreasureCard;
import com.vdom.api.VictoryCard;
public abstract class QuickPlayPlayer extends BasePlayer {
protected static final Card[] TRASH_CARDS = new Card[] ... |
package com.vdom.core;
import java.util.ArrayList;
import com.vdom.api.Card;
public abstract class AbstractCardPile {
protected ArrayList<Card> cards;
protected boolean isSupply = true;
protected boolean tradeRouteToken = false;
static enum PileType {
RuinsPile, KnightsPile, SingleCardPile
}
... |
package com.vdom.core;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.LinkedHashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import com.vdom.api.ActionCard;
import com.vdom.a... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.CardCostComparator;
import com.vdom.api.DurationCard;
import com.vdom.api.GameEventListener;
import com.vdo... |
package com.vdom.core;
import com.vdom.api.Card;
public class CardImpl implements Card {
// Template (immutable)
Cards.Type type;
CardImpl templateCard;
String name;
String safeName;
int cost;
boolean costPotion = false;
String description = "";
String expansion = "";
protected int vp;... |
package com.vdom.core;
@SuppressWarnings("serial")
public class ExitException extends RuntimeException {
}
|
package com.vdom.core;
import java.util.ArrayList;
import java.util.HashSet;
import com.vdom.api.Card;
import com.vdom.api.GameEvent;
import com.vdom.api.TreasureCard;
import com.vdom.api.VictoryCard;
public class TreasureCardImpl extends CardImpl implements TreasureCard {
int value;
boolean providePotion;
... |
package com.vdom.core;
import java.util.ArrayList;
import com.vdom.api.*;
public class SingleCardPile extends AbstractCardPile {
private Card templateCard;
public SingleCardPile(Card card, int count) {
this.templateCard = card;
this.type = PileType.SingleCardPile;
this.cards = ne... |
package com.vdom.core;
import com.vdom.api.VictoryCard;
public class ActionVictoryCardImpl extends ActionCardImpl implements VictoryCard {
protected ActionVictoryCardImpl(Builder builder) {
super(builder);
}
public static class Builder extends ActionCardImpl.Builder {
public Builder(Cards... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Random;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.CurseCard;
import com.vdom.api.DurationCar... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.CurseCard;
import com.vdom.api.DurationCard;
import com.vd... |
package com.vdom.core;
import com.vdom.api.DurationCard;
public class ActionDurationCardImpl extends ActionCardImpl implements DurationCard {
protected int addActionsNextTurn;
protected int addBuysNextTurn;
protected int addCardsNextTurn;
protected int addGoldNextTurn;
protected boolean takeAnoth... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Random;
import com.vdom.api.Acti... |
package com.vdom.core;
import java.awt.BorderLayout;
import java.awt.Container;
import java.awt.Dimension;
import java.awt.FlowLayout;
import java.awt.GridLayout;
import java.awt.Image;
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.File;
import java.io.FileOutputStream;
import... |
package com.vdom.core;
import com.vdom.api.Card;
import com.vdom.api.GameType;
public class GameStats {
public GameType gameType;
public Card[] cards;
public int aveTurns;
int aveVictoryPoints;
int aveNumCards;
}
|
package com.vdom.core;
import com.vdom.api.Card;
import com.vdom.api.GameType;
import java.util.*;
/**
* This class contains a set of cards (for a given GameType) that can be used.
* If the GameType value is one of the random sets, a random CardSet is generated
* using the available cards specified.
*
* Note th... |
package com.vdom.core;
import com.vdom.api.VictoryCard;
public class TreasureVictoryCardImpl extends TreasureCardImpl implements VictoryCard {
protected TreasureVictoryCardImpl(Builder builder) {
super(builder);
}
public static class Builder extends TreasureCardImpl.Builder {
public Build... |
package com.vdom.core;
import com.vdom.api.CurseCard;
public class CurseCardImpl extends CardImpl implements CurseCard {
public CurseCardImpl(Cards.Type type, int cost, int vp) {
super(type, cost);
this.vp = vp;
}
@Override
public CardImpl instantiate() {
checkInstantiateOK();... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import com.vdom.api.Card;
public class Cards {
public static HashSet<Card> nonKingdomCards = new HashSet<Card>();
public static ArrayList<Card> actionCardsBaseGame = new ArrayList<Card>();
public static... |
package com.vdom.core;
import java.util.ArrayList;
import com.vdom.api.Card;
import com.vdom.core.MoveContext;
import com.vdom.api.VictoryCard;
public class VictoryCardImpl extends CardImpl implements VictoryCard {
public VictoryCardImpl(Cards.Type type, int cost, int vp) {
super(type, cost);
thi... |
package com.vdom.core;
import java.util.ArrayList;
import com.vdom.api.Card;
public class DumpCardResources {
public static void main(String[] args) throws Exception {
Game game = new Game();
game.initGameBoard();
ArrayList<Card> cards = new ArrayList<Card>();
cards.add(C... |
package com.vdom.core;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
public class VariableCardPile extends AbstractCardPile {
HashMap<String, SingleCardPile> piles;
public VariableCardPile(PileType piletype, int coun... |
package com.vdom.api;
public interface FrameworkEventListener {
public void frameworkEvent(FrameworkEvent frameworkEvent);
}
|
package com.vdom.api;
public enum GameType {
// Base Game
FirstGame("First Game (Base)"), BigMoney("Big Money (Base)"), Interaction("Interaction (Base)"), SizeDistortion("Size Distortion (Base)"), VillageSquare("Village Square (Base)"), RandomBaseGame("Random Base Game"),
// Intrigue
VictoryDance("Vi... |
package com.vdom.api;
import com.vdom.core.MoveContext;
public interface TreasureCard extends Card {
public boolean providePotion = false;
public int getValue();
public boolean providePotion();
public boolean playTreasure(MoveContext context);
}
|
package com.vdom.api;
public interface GameEventListener {
public void gameEvent(GameEvent event);
}
|
package com.vdom.api;
public interface ReactionCard extends Card
{
}
|
package com.vdom.api;
public interface CurseCard extends Card {
public int getVictoryPoints();
}
|
package com.vdom.api;
import java.util.Comparator;
import com.vdom.core.Cards;
public class CardCostComparator implements Comparator<Card> {
public int compare(Card cardOne, Card cardTwo) {
if (cardOne.getCost(null) == cardTwo.getCost(null)) {
if (cardOne.costPotion() || cardTwo.costPotion())... |
package com.vdom.api;
import com.vdom.core.CardImpl;
import com.vdom.core.Cards.Type;
import com.vdom.core.MoveContext;
public interface Card {
public Type getType();
public String getName();
public String getSafeName();
public String getExpansion();
public String getStats();
public Str... |
package com.vdom.api;
import com.vdom.core.Game;
import com.vdom.core.MoveContext;
public interface ActionCard extends Card {
public int getAddActions();
public int getAddBuys();
public int getAddCards();
public int getAddGold();
public int getAddVictoryTokens();
public boolean isAtta... |
package com.vdom.api;
public interface VictoryCard extends Card {
public int getVictoryPoints();
}
|
package com.vdom.api;
import java.util.Comparator;
public class CardValueComparator implements Comparator<TreasureCard> {
public int compare(TreasureCard cardOne, TreasureCard cardTwo) {
if (cardOne.getValue() == cardTwo.getValue()) {
return 0;
} else if (cardOne.getValue() > cardTwo.g... |
package com.vdom.api;
import com.vdom.core.MoveContext;
import com.vdom.core.Player;
public class GameEvent {
public enum Type {
GameStarting, // A new game is starting, called at the start of each game when multiple are played
GameOver, // Game completed
Embargo, // Embargo added to car... |
package com.vdom.api;
import java.util.HashMap;
public class FrameworkEvent {
public enum Type {
GameTypeStarting, // A new GameType is starting
GameTypeOver, // GameType completed
AllDone
}
private Type type;
private GameType gameType;
private HashMap<String, Double> gam... |
package com.vdom.api;
import java.util.ArrayList;
public class FrameworkEventHelper {
private static ArrayList<FrameworkEventListener> listeners = new ArrayList<FrameworkEventListener>();
public static void addFrameworkListener(FrameworkEventListener listener) {
if (!listeners.contains(listener)) {
... |
package com.vdom.api;
public interface DurationCard extends ActionCard {
public int getAddActionsNextTurn();
public int getAddBuysNextTurn();
public int getAddGoldNextTurn();
public int getAddCardsNextTurn();
public boolean takeAnotherTurn();
public int takeAnotherTurnCardCount();
}
|
package com.vdom.comms;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.EnumSet;
import com.vdom.api.ActionCard;
import com.vdom.api.Card;
import com.vdom.api.TreasureCard;
import com.vdom.api.VictoryCard;
import com.vdom.core.Cards;
import com.vdom.core.MoveContext;
/**
* Gives informatio... |
package com.vdom.comms;
import java.io.EOFException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.io.IOException;
import java.io.OptionalDataException;
import java.io.StreamCorruptedException;
import java.net.ServerSocket;
import java.net.Socket;
import java.net.SocketTime... |
package com.vdom.comms;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Comparator;
import com.vdom.core.Cards;
import com.vdom.core.Util.MultilevelComparator;
public class MyCard implements Serializable {
private static final long serialVersionUID = -1367468781663470597L;
public int id;... |
package com.vdom.comms;
/**
* These functions are called <b>FROM WITHIN NETWORK THREADS</b>
* <ul>
* <li> handle is called from the receiving thread </li>
* <li> sendErrorHandler is called from the sending thread </li>
* <li> debug is called from wherever. </li>
* </ul>
* ==> handle() and sendErrorHandler() are... |
package com.vdom.comms;
import java.io.Serializable;
/**
* Event class: This object makes up the communication protocol between RemotePlayer, running in vdom, and the game activity. <br>
* The content is:
* <ul>
* <li><b>t</b>: Type of the event, determines meaning of other class members.</li>
* <li><b>s</b>: S... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.