This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface IQuote { | |
/** Ex. Petrobrás */ | |
public abstract String getNome(); | |
public abstract void setNome(String nome); | |
/** Ex.: PETR3 */ | |
public abstract String getCodigo(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface ICodeQuote extends IQuote, Serializable{ | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.edpichler.bovespa.persistent.impl; | |
import java.util.Date; | |
import com.edpichler.osgi.bovespa.quote.IQuote; | |
public abstract class Quote implements IQuote { | |
@Override | |
public String toString() { | |
return "Quote [nome=" + nome + ", codigo=" + codigo + ", data=" + data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class StockQuote extends Quote implements ICodeQuote , Serializable{ | |
public static ICodeQuote createFrom(IQuote quote) { | |
StockQuote q = new StockQuote(); | |
q.setAbertura(quote.getAbertura()); | |
q.setCodigo(quote.getCodigo()); | |
q.setData(quote.getData()); | |
q.setMaximo(quote.getMaximo()); | |
q.setMedio(quote.getMedio()); | |
q.setMinimo(quote.getMinimo()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.edpichler.bovespa.process.appengine; | |
import java.util.HashMap; | |
import java.util.HashSet; | |
import java.util.Map; | |
import java.util.Set; | |
import net.sf.jsr107cache.CacheException; | |
import net.sf.jsr107cache.CacheFactory; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class AppengineMemCacheMap implements IQuoteCache { | |
private Cache cache; | |
public AppengineMemCacheMap() { | |
Map props = new HashMap(); | |
props.put(GCacheFactory.EXPIRATION_DELTA, 60);// seconds | |
try { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public CompositeObject[] getObjetos(){ | |
CompositeObject[] obj = new CompositeObject[10]; | |
for (int i = 0; i < 10; i++) { | |
obj[i] = new CompositeObject(); | |
} | |
return obj; | |
} | |
public class CompositeObject{ | |
public Double getDouble(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<mx:DataGrid x="18" y="619" id="dataGrid" creationComplete="dataGrid_creationCompleteHandler(event)" dataProvider="{getObjetosResult.lastResult}"> | |
<mx:columns> | |
<mx:DataGridColumn headerText="otherPart" dataField="otherPart"/> | |
<mx:DataGridColumn headerText="objeto" dataField="objeto"/> | |
<mx:DataGridColumn headerText="string" dataField="string"/> | |
<mx:DataGridColumn headerText="double" dataField="double"/> | |
<mx:DataGridColumn headerText="objetos" dataField="objetos"/> | |
</mx:columns> | |
</mx:DataGrid> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Animal { | |
private String name; | |
private int age; | |
public Animal() { | |
name = "Name " + System.currentTimeMillis(); | |
age = (int) +System.currentTimeMillis(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
C:\Program Files\Oracle\VirtualBox>VBoxManage.exe modifyhd "D:\Users\eduardo.pichler\VirtualBox VMs\win7" --resize 30720 | |
OlderNewer