Monday, March 26, 2018

Calling EVE OpenAPI with Java

If you are into Java and want a quick example of a way you can read data from the EVE OpenAPI, here is an example I wrote using Jersey 2.26.

import java.util.List;

import javax.ws.rs.client.Client;
import javax.ws.rs.client.ClientBuilder;
import javax.ws.rs.core.GenericType;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.ext.ContextResolver;

import org.glassfish.jersey.moxy.json.MoxyJsonConfig;

/**
 * Example of calling the EVE OpenAPI using Jersey 2.26.  Specific Jersey components needed
 * include jersey-client 2.26, jersey-hk2 2.26, and jersey-media-moxy 2.26.
 */
public class EveOpenAPIExample {

 // variable names need to match names from the EVE OpenAPI
 private static class Region {
  private String region_id;
  private String name;
  private List<String> constellations;
  private String description;
  public String getRegion_id() {
   return region_id;
  }
  public void setRegion_id(String region_id) {
   this.region_id = region_id;
  }
  public String getName() {
   return name;
  }
  public void setName(String name) {
   this.name = name;
  }
  public List<String> getConstellations() {
   return constellations;
  }
  public void setConstellations(List<String> constellations) {
   this.constellations = constellations;
  }
  public String getDescription() {
   return description;
  }
  public void setDescription(String description) {
   this.description = description;
  }
 }
 
 public static void main(String[] args) {

  // setup the service information we will need for the example
  final String target = "https://esi.tech.ccp.is/latest/";
  final String path = "universe/regions/{regionid}/";
  final String regionId = "10000002";
  final String dataSource = "tranquility";
  
  // create the client configured to use MOXy for JSON binding
  final MoxyJsonConfig moxyJsonConfig = new MoxyJsonConfig();
  final ContextResolver jsonConfigResolver = moxyJsonConfig.resolver();
  Client client = ClientBuilder.newBuilder()
   .register(jsonConfigResolver).build();
  
  // execute example call on EVE OpenAPI to read information on a region
  Region region = client.target(target)
   .path(path)
   .resolveTemplate("regionid", regionId)
   .queryParam("datasource", dataSource)
   .request(MediaType.APPLICATION_JSON_TYPE)
   .get(new GenericType<Region>(){}); 
  
  // utilize the data
  System.out.println("Read information for region " + region.getName());
  
  System.exit(0);
 }
}

Monday, March 12, 2018

Planetary Interaction Tables

If you haven't tried it, Planetary Interaction is a great way to supplement your income, produce supplies you may need, and add some variety to your Eve experience. The key thing you need to know is what supplies can be created and what the "recipes" are for each. There are some great pages made by others that provide this information, but in my effort to host more of this information myself as well, I've provided some recipe tables here.

To find planets you are interested in close to the area you want to operate in, try using the Dotlan Planet Range tool.

1st Level RefinedRaw ResourceBarrenGasIceLavaOceanicPlasmaStormTemp.
BacteriaMicro Organisms X X X X
BiofuelsCarbon Compounds X X X
BiomassPlanktic Colonies X X
Chiral StructuresNon-CS Crystals X X
ElectrolytesIonic Solutions X X
Industrial FibersAutotrophs X
Oxidizing CompoundReactive Gas X
OxygenNoble Gas XX X
PlasmoidsSuspended Plasma X XX
Precious MetalsNoble Metals X X
ProteinsComplex Organisms X X
Reactive MetalsBase Metals XX X XX
SiliconFelsic Magma X
Toxic MetalsHeavy Metals XX X
WaterAqueous Liquids XXX X XX

2nd Level Refined1st Level Refined1st Level Refined
Biocells Biofuels+Precious Metals
Construction Blocks Reactive Metals+Toxic Metals
Consumer Electronics Toxic Metals+Chiral Structures
Coolant Water+Electrolytes
Enriched Uranium Toxic Metals+Precious Metals
Fertilizer Proteins+Bacteria
Gen Enhanced LivestockProteins+Biomass
Livestock Biofuels+Proteins
Mechanical Parts Reactive Metals+Precious Metals
Microfiber Shielding Industrial Fibers+Silicon
Miniature Electronics Silicon+Chiral Structures
Nanites Reactive Metals+Bacteria
Oxides Oxygen+Oxidizing Compound
Polyaramids Industrial Fibers+Oxidizing Compound
Polytextiles Industrial Fibers+Biofuels
Rocket Fuel Electrolytes+Plasmoids
Silicate Glass Silicon+Oxidizing Compound
Superconductors Water+Plasmoids
Supertensile Plastics Oxygen+Biomass
Synthetic Oil Electrolytes+Oxygen
Test Cultures Water+Bacteria
Transmitter Chiral Structures+Plasmoids
Viral Agent Bacteria+Biomass
Water-Cooled CPU Water+Reactive Metals

3rd Level Refined2nd Level Refined2nd Level Refined2nd Level Refined
Biotech Research Reports Construction Blocks+Livestock+Nanites
Camera Drones Rocket Fuel+Silicate Glass
Condensates Coolant+Oxides
Cryoprotectant Solution Fertilizer+Synthetic Oil+Test Cultures
Data Chips Microfiber Shielding+Supertensile Plastics
Gel-Matrix Biopaste Biocells+Oxides+Superconductors
Guidance Systems Transmitter+Water-Cooled CPU
Hazmat Detection Systems Polytextiles+Transmitter+Viral Agent
Hermetic Membranes Gen. Enhanced Livestock+Polyaramids
High-Tech Transmitters Polyaramids+Transmitter
Industrial Explosives Fertilizer+Polytextiles
Neocoms Biocells+Silicate Glass
Nuclear Reactors Enriched Uranium+Microfiber Shielding
Planetary Vehicles Mechanical Parts+Miniature Electronics+Supertensile Plastics
Robotics Consumer Electronics+Mechanical Parts
Smarfab Units Construction Blocks+Miniature Electronics+
Supercomputers Consumer Electronics+Coolant+Water-Cooled CPU
Synthetic Synapses Supertensile Plastics+Test Cultures
Transcranial MicrocontrollersBiocells+Nanites
Ukomi Super Conductors Superconductors+Synthetic Oil
Vaccines Livestock+Viral Agent

4th Level Refined3rd Level Refined3rd Level RefinedMisc. Refined (Level)
Broadcast Node Data Chips+High-Tech Transmitters+Neocoms (3rd)
Integrity Response Drones Gel-Matrix Biopaste+Hazmat Detection Systems+Planetary Vehicles (3rd)
Nano-Factory Industrial Explosives+Ukomi Super Conductors+Reactive Metals (1st)
Organic Mortar Applicators Condensates+Robotics+Bacteria (1st)
Recursive Computing Module Guidance Systems+Synthetic Synapses+Transcranial Microcontrollers (3rd)
Self-Harmonizing Power CoreCamera Drones+Hermetic Membranes+Nuclear Reactors (3rd)
Sterile Conduits Smartfab Units+Vaccines+Water (1st)
Wetware Mainframe Biotech Research Reports+Cryoprotectant Solution+Supercomputers (3rd)