Examples of MyKryoInit


Examples of net.alteiar.kryo.MyKryoInit

    System.out.println("Setting up test");
    String address = "127.0.0.1";
    int port = 4545;

    CampaignFactoryNew.loadCampaign(address, port, "./save",
        getGlobalDirectory(), getCampaignDirectory(), new MyKryoInit());

    long before = System.currentTimeMillis();
    int currentSize = CampaignClient.getInstance().getPlayers().size();
    while (currentSize == 0) {
      currentSize = CampaignClient.getInstance().getPlayers().size();
View Full Code Here

Examples of net.alteiar.kryo.MyKryoInit

    String localDirectoryPath = getCampaignDirectory();

    deleteRecursive(new File(localDirectoryPath));

    CampaignFactoryNew.startNewCampaign(address, port, "./save",
        getGlobalDirectory(), new MyKryoInit());

    CampaignClient.getInstance().createPlayer(getPlayerName(), false,
        Color.BLUE);

    while (!CampaignClient.getInstance().isInitialized()) {
View Full Code Here

Examples of net.alteiar.kryo.MyKryoInit

    String localDirectoryPath = getCampaignDirectory();

    deleteRecursive(new File(localDirectoryPath));

    CampaignFactoryNew.startNewCampaign(address, port, "./save",
        getGlobalDirectory(), new MyKryoInit());

    CampaignClient.getInstance().createPlayer(getPlayerName(), true,
        Color.BLUE);

    System.out.println("test started");
View Full Code Here

Examples of net.alteiar.kryo.MyKryoInit

  public PluginSystem(PluginInfo pluginInfo) throws IOException {
    pluginPath = pluginInfo.getJar().getParentFile().getCanonicalPath()
        + "/global";

    kryo = new MyKryoInit();

    pluginDocument = new PluginList<DocumentPlugin>();
    pluginElements = new PluginList<MapElementPlugin>();

    try {
      for (File dep : pluginInfo.getDependencies()) {
        ClassLoaderUtil.addFile(dep);
      }

      ClassLoaderUtil.addFile(pluginInfo.getJar());

      core = (ICorePlugin) ClassLoader.getSystemClassLoader()
          .loadClass(pluginInfo.getCorePlugin()).newInstance();

      plugin = (IPlugin) ClassLoader.getSystemClassLoader()
          .loadClass(pluginInfo.getDocumentPlugin()).newInstance();

      for (DocumentPlugin plug : plugin.getDocuments()) {
        this.pluginDocument.addPlugin(plug);
      }

      for (MapElementPlugin plug : plugin.getMapElements()) {
        pluginElements.addPlugin(plug);
      }

      MyKryoInit kryo = new MyKryoInit();
      kryo.addPluginClasses(plugin.getClasses());

    } catch (Exception e) {
      Logger.getLogger(getClass()).error("enable to load plugin ", e);
      ExceptionTool.showError(e);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.