text stringlengths 14 410k | label int32 0 9 |
|---|---|
public void actionPerformed(ActionEvent action) {
if(action.getSource().equals(connect)) {
int desired = 48;
try {
pf.setString("connect_hostname", serverName.getText());
pf.setInt("connect_port", Integer.parseInt(portNum.getText()));
pf.setInt("listen_port", Integer.parseInt(localServerPortnum.... | 5 |
public String getSumbitIp() {
return this.sumbitIp;
} | 0 |
private static double[] getSupportPoints(int lineNumber, double[] lowPrices) {
double[] sPoints = new double[lineNumber];
for(int i =0;i<lineNumber-1;i++){
double price = 999999999;
for(int j=-5;j<=0;j++){
if((i+j>=0) && (i+j<lineNumber-1) && lowPrices[i+j]<pri... | 5 |
public boolean execute() {
try {
updateGraph();
System.out.print(name+": ");
// initialize output streams
FileOutputStream fos = null;
PrintStream pstr = System.out;
if( baseName != null )
{
String fname = fng.nextCounterName();
fos = new FileOutputStream(fname);
System.out.println("writing to file "+... | 9 |
public Actor getActor(int x, int y){
for (Actor actor : actorList){
if (actor.getPosX() == x && actor.getPosY() == y){
return actor;
}
}
return null;
} | 3 |
public void run() {
// Call to
// /api/0.1/getBugs?b=36.17496&t=61.03797&l=-9.9793&r=31.54902&ucid=1
// Reply is something like: putAJAXMarker(552542, 6.971592, 50.810296,
// 'Strassensystem auf Friedhof fehlt [TobiR, 2010-08-09 23:30:37
// CEST]', 0);
try {
S... | 9 |
public void draw(Graphics2D g) {
for(
int row = rowOffset;
row < rowOffset + numRowsToDraw;
row++) {
if(row >= numRows) break;
for(
int col = colOffset;
col < colOffset + numColsToDraw;
col++) {
if(col >= numCols) break;
if(map[row][col] == 0) continue;
... | 5 |
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onSignChange(final SignChangeEvent changing) {
final List<String> worldFilters = this.worlds.get(changing.getBlock().getWorld().getName());
if (worldFilters == null) return;
final String[] lines = changing.g... | 3 |
public boolean isConvex() throws TypeOverflowException {
int signPlus = 0,
signMinus = 0;
double z;
int n = vertices.size();
for (int i = 0; i < n; ++i) {
int j = (i + 1) % n;
int k = (i + 2) % n;
z = (vertices.get(j).x - vertices.get(i).x) * (vertices.get(k).y - vertices.get(j).y);
z -= ... | 9 |
public ArrayList<ConnectedComponent> findTrajectory()
{
ArrayList<ConnectedComponent> traj = new ArrayList<ConnectedComponent>();
boolean searched[][] = new boolean[_height][_width];
for (int x = 50; x < _width - 50; x++)
for (int y = _groundLevel - 1; y > _height * 0.1; y--... | 6 |
private boolean safe(boolean[][]board, int i, int j) {
int d45x = j + i, d135x = j - i;
for (int k = 0; k < board.length; k ++) {
if (board[i][k]) return false;
if (board[k][j]) return false;
if (d45x - k >= 0 && d45x - k < board.length && board[k][d45x - k]) return f... | 9 |
public static void clearLowInventoryTable(DrugInventoryPage drugP){
int rows= drugP.getLowInventoryTable().getRowCount();
for(int i=0;i<rows;i++){
drugP.getLowInventoryTable().setValueAt("",i,0);
}
} | 1 |
private Repository getRepository(String organizationName, String repositoryName) throws IOException {
for (Repository repository : getRepositories(organizationName)) {
if (repository.getName().equals(repositoryName)) {
return repository;
}
}
// We... | 2 |
public static void combatinitialize() {
int enemyInit; //enemies Initiative
int playerInit; //Players Initiative
Random rnd = new Random();
do{
enemyInit = rnd.nextInt(10) + 3; //Randomize chance Variable for enemy Initiative
playerInit = rnd.nextInt(10) + 1; //Randomize chance Variable for Player Initia... | 3 |
private void addFleatingSpring() {
if (getModel().getView().isClicked()) {
double x = getModel().getView().getLastMousePosition().x;
double y = getModel().getView().getLastMousePosition().y;
Mass fleatingMass = new MoveableMass(x, y, 1);
if (myCurrentMass == null)... | 2 |
public static void main(String[] args) {
// TODO Auto-generated method stub
// set variables for port, socket
final int port = 3344;
Socket sock = null;
// set variables for RSAKeySize, public key, private key
final int RSAKeySize = 1024;
PublicKey pubKey = null;
PrivateKey priKey = null;
Key serverPu... | 6 |
public void addItem(int type){
for(int i = 0; i < invCount; i++){
if(inv[i].type == 0){
inv[i].type = type;
if(invCount < inv.length)invCount++;
break;
}
}
} | 3 |
private String getVariablesList() {
StringBuilder list = new StringBuilder();
for ( int i = 0; i < sqlVariables.size(); i++ ) {
if ( i % 5 == 0 && i != 0 )
list.append( "\n" + TAB + TAB + TAB );
switch ( databaseType ) {
case H2:
case ORA... | 6 |
public void PaymentHandler(){} | 0 |
public static void export(ResolveReport resolved,String output,String classpath,String pattern,String pathprefix) throws IOException {
File outputPath = new File(output);
if( !outputPath.exists() )
outputPath.mkdirs();
if( !outputPath.exists() || !outputPath.isDirectory())
throw new RuntimeExceptio... | 9 |
private static void eliminarTienda()
{
boolean salir;
Integer idTienda;
do
{
try
{
System.out.print( "Introduce el Id de la tienda: ");
idTienda = Integer.parseInt( scanner.nextLine());
Tienda.eliminar( idTienda);
System.out.println( "- Tienda id " + idTienda + " eliminada del registr... | 2 |
private Piece checkCase(Piece[] B,int X, int Y,boolean isCapture) {
if (!(Utils.isVoid(B,X,Y))) {
Piece obstacle = Utils.getPiece(B,X,Y);
//Warning : pawn can move only to capture vertically
if ((isCapture) && (obstacle.isWhite()!=null) && (isWhite()!=obstacle.isWhite())) {
possibleMoves.add(obstacle.get... | 5 |
public static String pad(String s) {
if (s.length() == 0) return " ";
char first = s.charAt(0);
char last = s.charAt(s.length()-1);
if (first == ' ' && last == ' ') return s;
if (first == ' ' && last != ' ') return s + " ";
if (first != ' ' && last == ' ') return " " + s;... | 9 |
public FlacPicture(PropertyTree parent) {
super(MediaProperty.PICTURE, parent);
} | 0 |
public void addAP(MapleClient c, byte stat, short amount) {
MapleCharacter player = c.getPlayer();
switch (stat) {
case 1: // STR
player.getStat().setStr(player.getStat().getStr() + amount);
player.updateSingleStat(MapleStat.STR, player.getStat().getStr());
... | 6 |
public void startElement(String uri, String localName, String qName, Attributes attributes) {
String value;
if (qName.equals("eblast")) {
if ((value = attributes.getValue("port")) != null) mSettings.setPort(Integer.valueOf(value));
if ((value = attributes.getValue("maxpeers")) != null) mSettings.setMaxPeers(I... | 7 |
private void setTimerDelay() {
switch (gameState.getDifficultyLevel()) {
case GameState.DIFFICULTY_EASY:
changePinTimer.setInitialDelay(randomGen.nextInt(10000) + 10000);
changePinTimer.restart();
break;
case GameState.DIFFICULTY_MEDIUM:
... | 3 |
public int getRound()
{
return round;
} | 0 |
@Override
public Object invoke(Object proxy, Method method, Object[] args)
throws Throwable {
Class declaringClass = method.getDeclaringClass();
if (declaringClass == Object.class) {
if (method.equals(hashCodeMethod)) {
return proxyHashCode(proxy);
} else if (method.equals(equalsMethod)) {
return... | 7 |
public static <E> Map<E,int[][]> intTwoDArrayMapCopy(Map<E,int[][]> map) {
Map<E,int[][]> copy = null;
if (map instanceof HashMap<?,?>) {
copy = new HashMap<E,int[][]>();
} else if (map instanceof TreeMap<?,?>) {
copy = new TreeMap<E,int[][]>();
}
for (E e... | 9 |
Power(String name, int properties, String imgFile, String helpInfo) {
this.name = name ;
this.helpInfo = helpInfo ;
this.buttonTex = Texture.loadTexture(IMG_DIR+imgFile) ;
this.properties = properties ;
} | 4 |
@Override
public void execute(VirtualMachine vm) {
super.execute(vm);
((DebuggerVirtualMachine) vm).enterFunction();
((DebuggerVirtualMachine) vm).saveFunctionArgs(functionArgList);
((DebuggerVirtualMachine) vm).saveFunctionAddress(address);
} | 0 |
public String nextToken() throws JSONException {
char c;
char q;
StringBuffer sb = new StringBuffer();
do {
c = next();
} while (Character.isWhitespace(c));
if (c == '"' || c == '\'') {
q = c;
for (;;) {
c = next();
... | 9 |
@Override
public boolean execute(RuleExecutorParam param) {
Rule rule=param.getRule();
String compareValue=rule.getValue();
try {
if(!Util.isNullOrEmpty(compareValue)){
Class<? extends RuleExecutor> methExe= Thread.currentThread().getContextClassLoader().loadClass(compareValue.trim()).asSubclass(RuleEx... | 5 |
public String getLstServicios() {
String lista = "";
for (Servicio s : lstServicios) {
lista += s;
}
return lista;
} | 1 |
@Override
public void onEnable() {
reloadPlugin();
joinListener = new PlayerJoinListener(this);
moveListener = new PlayerMoveListener(this);
if (getConfig().getBoolean("options.allow-plugin-metrics", true)) {
try {
metrics = new Metrics(this);
me... | 5 |
public NodeId (byte[] bytes) {
Objects.requireNonNull(bytes);
if (bytes.length != 20) {
throw new IllegalArgumentException("invalid length");
}
this.bytes = Arrays.copyOf(bytes, bytes.length);
this.hash = Arrays.hashCode(bytes);
// Hex String
String... | 3 |
@Override
public void run() {
while (cloudMap.getNoMaps()<CloudMapPanel.sampleSize && !stop) {
cloudMap.addMaps( 1 );
try {
Thread.sleep( 5 );
}
catch (InterruptedException e) {
e.printStackTrace();
}
}
... | 5 |
public int getInvalidRxCount() {
return invalidRxPackets;
} | 0 |
private JMenu createFillMenu(){
fill = new JMenu("Fill");
algorithmZatravki = new JCheckBoxMenuItem(new AbstractAction() {
@Override
public void actionPerformed(ActionEvent arg0) {
// TODO Auto-generated method stub
if(algorithmZatravki.isSelected()){
algorithmZatravki.setSelected(false);
... | 4 |
@Override
public boolean useItem(Player player, int type) {
Block block = Block.blocks[type];
if (block == Block.RED_MUSHROOM && minecraft.player.inventory.removeResource(type)) {
player.health += 4;
if (player.health > 30) {
player.health = 30;
}
... | 6 |
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (!(o instanceof OAuthToken)) return false;
OAuthToken that = (OAuthToken) o;
if (secretKeySpec != null ? !secretKeySpec.equals(that.secretKeySpec) : that.secretKeySpec != null)
return false;
... | 6 |
private Submission is_rankier( List<Submission> input ) {
if ( input.isEmpty() ) return null;
Submission winner = null;
for ( Submission s : input ) {
if ( winner == null ) {
winner = s;
}
else {
if ( s.card.rank() > winner.car... | 4 |
public void warn(final String msg) {
if(disabled) return;
else logger.warning(msg);
// System.out.debug(route_name + "-" + connection_id + "[warn]: " + msg);
} | 1 |
public static void main(String args[]) {
/* Set the Nimbus look and feel */
//<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
/* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
* For details see http://down... | 6 |
public int stepthrough(int i) {
switch(sim40.memory[i]) {
/* stop */
case 0: this.isProgramTerminated = true;
return i;
/* print, printb, printch */
case 1: case 2: case 3:
this.stdStream.getOutput().add(result(i));
++i;
break;
default:
/* jump, comp, xcomp, ycomp, jineg, jipos, jizero, j... | 8 |
private Vector<String> getNext() throws ServerException {
if (m_exhausted) return null;
try {
if (m_rs.next()) {
Vector<String> result = new Vector<String> ();
Integer recordKey = m_rs.getInt(1);
result.add(m_rs.getString(2));
D... | 8 |
public static Collection getDatas(Collection result, ResultSet rs, Class clazz) {
try {
while (rs.next()) {
//创建类的实例
Object vo = clazz.newInstance();
//获取本对象的属性
Field[] fields = clazz.getDeclaredFields();
//获取父类的属性
// Field[] superFields = clazz.getSuperclass().getDeclaredFields();
/... | 3 |
private void search(int step){
searchCount++;
if(searchCount%100000==0){
System.out.println("Search count:"+searchCount);
}
int estimate=lowerBound(curPancakes);
if(step+estimate>curPancakes.size()*2) return;
if(isSorted(curPancakes) && step<minSwap){
minSwap=step;
finalResults=new ArrayLi... | 8 |
public void leavePercentageOutSplit(String filename, int percentage, boolean random) {
List<Bookmark> trainLines = new ArrayList<Bookmark>();
List<Bookmark> testLines = new ArrayList<Bookmark>();
Set<Integer> indices = new HashSet<Integer>();
int currentUser = -1, userIndex = -1, userSize = -1;
for (int i = 0... | 8 |
public EncryptionPropertiesType getEncryptionProperties() {
return encryptionProperties;
} | 0 |
@Override
public boolean containsAll(Collection<?> c) {
int count = 0;
for(Object o : c) {
if(this.contains(o)) {
count++;
}
}
if(count == c.size()) {
return true;
}
return false;
} | 4 |
@Override
public void quickPlay( boolean priority, boolean toStream, boolean toLoop,
String sourcename, FilenameURL filenameURL, float x,
float y, float z, int attModel, float distOrRoll,
boolean temporary )
{
SoundBuffer b... | 6 |
public String toString() {
String output = "suited: \n";
for (int i = 0; i < suitedPreFlop.length; i++) {
for (int j = 0; j < suitedPreFlop[i].length; j++) {
output += "\t" + suitedPreFlop[i][j];
}
output += "\n";
}
output += "\nunsuited: \n";
for (int i = 0; i < unsuitedPreFlop.length; i++) {
... | 4 |
@Override
public int hashCode() {
final int prime = 31;
int result = 1;
result = prime * result + bitsPerSample;
result = prime * result
+ (int) (frameDataStart ^ (frameDataStart >>> 32));
result = prime * result + Arrays.hashCode(md5);
result = prime * result + numChannels;
result = prime * result +... | 0 |
* @param destination the array to hold the conversion
* @param destOffset the index where output will be put
* @param options alphabet type is pulled from this (standard, url-safe, ordered)
* @return the number of decoded bytes converted
* @throws NullPointerException if source or destination arrays ar... | 8 |
private void fireDebuff()
{
int[] debuffList = getDebuffs();
ArrayList <Integer> numDebuffs = new ArrayList<Integer>();
for (int i = 0; i < debuffList.length; i++){
if (Math.random() <= Data.debuffChance[debuffList[i] ] ){
numDebuffs.add (debuffList[i]);
... | 3 |
public void fillDialogFields(StockItem stockItem) {
if (stockItem != null) {
barCodeField.setText(stockItem.getId() + "");
getNameField().setText(stockItem.getName());
String priceString = String.valueOf(stockItem.getPrice());
priceField.setText(priceString);
... | 1 |
public String compareCountryRank(Stats previousStats)
{
if(previousStats == null)
return "";
if(previousStats.getCountryRank() < 1)
return "";
double delta = previousStats.getCountryRank() - getCountryRank();
if(delta == 0D)
return "";
return "<font color=" + (delta >= 0 ? "green" : "red") + ">(" + ... | 4 |
public String getAsString(FacesContext context, UIComponent component,
Object value) {
if (context == null || component == null) {
throw new NullPointerException();
}
try {
// If the specified value is null, return a zero-length String
... | 9 |
public static void set(int addr, int val) {
val &= 0xFF;
if (Util.inRange(addr, 0, 0x00EF)) { // Zero page
mem[addr] = val;
return;
} else if (Util.inRange(addr, 0x00F0, 0x00FF)) { // Function registers
writeReg(addr, val);
return;
} else if (Util.inRange(addr, 0x0100, 0x7FFF)) { // Sound RAM
mem... | 6 |
public void zoomImage()
{
//For clarity of code, create some variables to hold slide dimensions
//and original image dimensions
int slideWidth = hostSize.width;
int slideHeight = hostSize.height;
int originalWidth = getMainImage().getWidth(null);
int originalHeight = getMainImage().getHeight(null);
//De... | 5 |
static void draw_sprites(osd_bitmap bitmap)
{
int offs;
if (zaxxon_vid_type == CONGO_VID)
{
int i;
/* Draw the sprites. Note that it is important to draw them exactly in this */
/* order, to have the correct priorities. */
/* Sprites actually start at 0xff * [0xc031], it seems to be static tho'*/... | 9 |
public static int[] loadSource(String filepath, int maxSources, boolean looping) {
// Load .wav data into a buffer.
int buffer = AL10.alGenBuffers();
int error = AL10.alGetError();
if(error != AL10.AL_NO_ERROR) {
System.err.println("Encountered AL error code " + error + "!");
System.exit(-1);
}
//Lo... | 7 |
@Override
public void crearFichero(String ruta)
{
FileInputStream from = null;
FileOutputStream to = null;
File toFile = new File(ruta + this.getMetadato("nombre") + this.getMetadato("extension"));
try
{
from = new FileInputStream(this.audio);
... | 6 |
public List<String> getAllValidAliases()
{
List<String> list = new ArrayList<>();
for(String alias : backingMap.keySet())
{
list.add(alias);
}
for(String alias : aliasesMap.keySet())
{
if(aliasesMap.get(alias).valid())
{
list.add(alias);
}
}
return list;
} | 3 |
public final static boolean isLongOp(final Object obj0, final Object obj1) {
return (obj0 instanceof Long
|| obj1 instanceof Long
|| obj0 instanceof Integer
|| obj1 instanceof Integer
|| obj0 instanceof Character
|| obj1 instanceof ... | 9 |
public boolean moveEast(int w)
{
boolean moved = false;
if(isFighting==false && isConcious() && getEnergy()>0)
{
if(w==3 || w==4)
{
setX(getX()+1);
moved = true;
}
else if(w>=10)
{
updateLoc... | 7 |
public static String toLanguageTag(Locale locale) {
return locale.getLanguage() + (hasText(locale.getCountry()) ? "-" + locale.getCountry() : "");
} | 1 |
public Release calculateDelta(File aTopTempDir, File aTempXmlDir,
File aTempMD5Dir) throws Exception
{
int nbDeleted = 0;
int nbCreated = 0;
int nbModified = 0;
// create a temp release
File releaseTempDir = FileSystem.createTempDirectory("release-",
... | 9 |
@Override
public String[] getTableRenameStatements(String oldTableName,Class<?>oldClass, String newTableName,Class<?>newClass)
{
String [] res = new String[2];
res[0] = "CREATE TABLE "+newTableName+" AS SELECT * FROM " +oldTableName+" WITH DATA";
res[1] = "DROP TABLE " + oldTableName;
return res;
} | 2 |
public static int getSailplaneTensionUnit() throws ClassNotFoundException {
int weightUnit = 0;
try{
//Class derbyClass = RMIClassLoader.loadClass("lib/", "derby.jar");
Class.forName(driverName);
Class.forName(clientDriverName);
}catch(java.lang.ClassNotFoundE... | 4 |
private boolean isWhitespace( int v ) {
return ( v == 0x20 || v == 0x09 || v == 0x0A || v == 0x0D );
} | 3 |
@Override
protected boolean doStep() {
double minDeltaCost = Double.MAX_VALUE;
Move11 bestMove = null;
boolean moveFound = false;
Set<Move11> moves = generator.getMoves();
for (Move11 move : moves) {
if (move.getDeltaCost() < minDeltaCost &&
move.... | 5 |
public ConfigurationSection getConfigurationSection(String path) {
Object val = get(path, null);
if (val != null) {
return (val instanceof ConfigurationSection) ? (ConfigurationSection) val : null;
}
val = get(path, getDefault(path));
return (val instanceof Configura... | 3 |
public static boolean copyFile(File from, File to, byte[] buf) {
if (buf == null) buf = new byte[BUFFER_SIZE];
FileInputStream from_s = null;
FileOutputStream to_s = null;
try {
from_s = new FileInputStream(from);
to_s = new FileOutputStream(to);
for(int bytesRea... | 7 |
public static void main(String[] args)
{
File dictionary = null;
File document = null;
String option = "";
if(args.length < 2 || args.length > 3)
{
System.out.println("Incorrect number of arguments!");
return;
}
dictionary = new File(args[0]);
if(!dictionary.isFile()){
System.out.printl... | 7 |
public void connect() throws IOException {
if (level != 0) // otherwise disconnected or connect
throw new SocketException("Socket closed or already open ("+ level +")");
IOException exception = null;
Socket s = null;
for (int i = 0; i < ports.length && s == null; i++) {
try {
s = new Socket(host, port... | 6 |
public static boolean getKeyUp(int keyCode)
{
return !getKey(keyCode) && lastKeys[keyCode];
} | 1 |
public static void boostByMarketingTagMatch(ScoredSolrDoc doc, String keyword, float boost) {
if (doc == null || keyword == null)
return;
if (boost <= 0)
boost = 5.0f;
List<String> keywordList = StringUtil.stringToStringList(keyword, "[ ]");
int keywordCount = keywordList.size();
// to keep the... | 9 |
public static final boolean method983(int z, int x, int y) {
int l = Canvas_Sub1.anIntArrayArrayArray52[z][x][y];
if (l == -Class142_Sub10.anInt3361) {
return false;
}
if (l == Class142_Sub10.anInt3361) {
return true;
}
int i1 = x... | 6 |
private void changeValueRandomly(Random r, int numOfValues,
int indexOfAtt,
Instance instance,
boolean useMissing) {
int currValue;
// get current value
// if value is missing set current value to nu... | 7 |
private void paintEnemyPath(Graphics2D g2, Iterable<Point> enemyPath) {
g2.setColor(Color.gray);
for (Point currentGridPoint : enemyPath) {
g2.fill(new Rectangle(GlobalPositioning.getXPixel(currentGridPoint.getX()), GlobalPositioning.getYPixel(currentGridPoint.getY()),
B... | 1 |
public static String getModifierKeyText() {
boolean isMac = (System.getProperty("os.name").startsWith("Mac"));
String text = "";
if ((MENU_SHORTCUT_KEY_MASK & InputEvent.SHIFT_MASK) == InputEvent.SHIFT_MASK) {
text = "Shift";
}
if ((MENU_SHORTCUT_KEY_MASK & InputEvent.CTRL_MASK) == InputEvent.CTRL_MASK)... | 9 |
public void setNextMessage() {
try{
clearMessageBoard();
message1 = message[currentMessageIndex].substring(0,message[currentMessageIndex].length() > 40 ? 40 : message[currentMessageIndex].length());
message2 = message[currentMessageIndex].length() > 40?message[currentMessageI... | 3 |
private static TobiiHeader readHeader(CSVReader reader) throws IOException {
TobiiHeader header = new TobiiHeader();
//
// SYSTEM PROPERTIES section
String line[] = reader.readNext();
assert(line[0].equalsIgnoreCase("System Properties:"));
line = reader.readNext();
assert(line[0].equalsIgnoreCase... | 5 |
@PersistenceContext
public void setEm(EntityManager em) {
this.em = em;
} | 0 |
private void initCharacterFlowPane() {
ColorUtil picker = new ColorUtil();
for (int k = 0; k < 10; k++) {
FlowPane content = new FlowPane();
TitledPane tPane = new TitledPane();
tPane.setText("Test_" + k);
/**
* Add content *
*/... | 2 |
public static boolean isSupportedOutputFormatType(String format, String type)
{
if (!isSupportedOutputFormat(format))
{
return false;
}
if (format == ThumbnailParameter.ORIGINAL_FORMAT
&& type == ThumbnailParameter.DEFAULT_FORMAT_TYPE)
{
return true;
}
else if (format == ThumbnailParameter.O... | 8 |
static final int method1812(int i) {
anInt2122++;
if (Class213.aBoolean2510) {
return 6;
}
if (i != 5) {
LOCAL_PLAYERS_INDEXES_COUNT = -106;
}
if (Node_Sub38_Sub23.aCacheNode_Sub13_10343 == null) {
return 0;
}
int i_5_ = Node_Sub38_Sub23.aCacheNode_Sub13_10343.anInt9562;
if (Class251.method31... | 9 |
private List expand(List symbols) {
if (contexts == null)
return expandNoContext(symbols);
return expandContext(symbols);
} | 1 |
static public TreeMap<Integer, TreeSet<Integer> > graphBuilder(String fichierTexte)
{
TreeMap<Integer, TreeSet<Integer> > tmpNoeuds = new TreeMap<Integer, TreeSet<Integer> >();
StringTokenizer tokenizer = new StringTokenizer(fichierTexte);
while (tokenizer.hasMoreTokens()) {
Integer token = Integ... | 1 |
public static boolean isDouble(String DBL)
{
if (DBL.length() == 0)
return false;
if (DBL.startsWith("-") && (DBL.length() > 1))
DBL = DBL.substring(1);
boolean alreadyDot = false;
for (int i = 0; i < DBL.length(); i++)
{
if (!Character.isDigit(DBL.charAt(i)))
{
if (DBL.charAt(i) == '.')
... | 7 |
@Override
public void addMedia(String name, String year, String genre,
Object[] objects, int duration, int mediaType) throws SQLException {
CallableStatement stMedia = null;
CallableStatement stCreator = null;
try {
connection.setAutoCommit(false);
//parameters: username, password, name, year, genre, du... | 2 |
@Override
public void mouseMoved(MouseEvent e) {
if (state == 0) {
if (e.getX() > getWidth() / 2 + 16) {
user.setFacingRight(true);
} else {
user.setFacingRight(false);
}
if (user.getInHand() instanceof ProjectileShooter)
if (user.isFacingRight())
((ProjectileShooter) user.getInHand()).s... | 4 |
private void refFtActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_refFtActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_refFtActionPerformed | 0 |
public boolean equals(Network A){
boolean result = true;
if(numNodes == A.getNumNodes()){
for(int i=0; i<numNodes; i++){
if(!Arrays.equals(nodes.get(i).getInputs(), A.getNodes().get(i).getInputs())){
result = false;
}
}
}
else{
result = fa... | 3 |
@Override
public void documentAdded(DocumentRepositoryEvent e) {} | 0 |
public int step()
{
boolean found=false;
boolean growth=false;//used to check growth of the search
GridCell goal = GridCell.getgoalCell();
@SuppressWarnings("unchecked")
Vector<GridCell> temp = (Vector<GridCell>) edge.clone();
for(int i=0;i<temp.size();i++)//runs as many ti... | 8 |
private static void copyPri(File inputFile, File outputFile,
boolean isOverWrite) throws IOException {
// 是个文件。
if (inputFile.isFile()) {
copySimpleFile(inputFile, outputFile, isOverWrite);
} else {
// 文件夹
if (!outputFile.exists()) {
outputFile.mkdir();
}
// 循环子文件夹
for (File child : ... | 3 |
Subsets and Splits
SQL Console for giganticode/java-cmpx-v1
The query retrieves a limited number of text entries within a specific length range, providing basic filtering but minimal analytical insight.