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
#!/usr/bin/env python | |
import sys | |
import os | |
import logging | |
from itertools import permutations | |
from appscript import * | |
from kuler import * |
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 Object execute(ExecutionEvent event) throws ExecutionException { | |
InputDialog dlg = new InputDialog( | |
HandlerUtil.getActiveShellChecked(event), "Title", | |
"Enter text", "Initial value", null); | |
if (dlg.open() == Window.OK) { | |
// User clicked OK; run perl | |
String input = dlg.getValue(); | |
// TODO:do something with value | |
} | |
return null; |
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 java.util; | |
public class ArrayList extends java.util.AbstractList implements List, RandomAccess, Cloneable, Serializable { | |
// Fields | |
private static final long serialVersionUID; | |
private transient Object[] elementData; | |
private int size; | |
private static final int MAX_ARRAY_SIZE; |
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 tp2; | |
import java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
public class ClassAnalyzer { | |
public static void analyzeClass(String className) | |
throws ClassNotFoundException { |
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 tp2; | |
/* | |
* Cay S. Horstmann & Gary Cornell, Core Java | |
* Published By Sun Microsystems Press/Prentice-Hall | |
* Copyright (C) 1997 Sun Microsystems Inc. | |
* All Rights Reserved. | |
* | |
* Permission to use, copy, modify, and distribute this | |
* software and its documentation for NON-COMMERCIAL purposes |
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 tp3; | |
public abstract class Set { | |
public abstract boolean contains(int n); | |
public Set even() { | |
// TODO implement | |
return null; | |
} |
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 generics; | |
import java.util.Arrays; | |
import java.util.NoSuchElementException; | |
/** | |
* This class represents an implementation of a stack datastructure. | |
* Unfortunatelly this version does not support generics and that makes it too | |
* difficult to use. Your task is to: | |
* |
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 generics; | |
import static org.junit.Assert.*; | |
import static org.junit.Assert.assertEquals; | |
import java.lang.reflect.Field; | |
import java.util.ArrayList; | |
import java.util.Collection; | |
import java.util.List; |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" | |
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>mirroring</groupId> | |
<artifactId>mirror</artifactId> | |
<version>1.0.0-SNAPSHOT</version> | |
<packaging>pom</packaging> |
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
MouseAdapter ma = new MouseAdapter() { | |
boolean dragging = false; | |
@Override | |
public void mouseDragged(MouseEvent e) { | |
if (!dragging) { | |
dragging = true; | |
System.out.println("Begin dragging: "+e.getPoint()); | |
} else { | |
System.out.println("Continue dragging: "+e.getPoint()); | |
} |
OlderNewer