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) 2010 David Wolever <david@wolever.net> and Verso Furniture Inc. | |
// See the bottom of this file for copyright details. | |
package flexunit4Param.testrunners | |
{ | |
import flash.utils.getQualifiedClassName; | |
import flex.lang.reflect.Method; | |
import flex.lang.reflect.metadata.MetaDataAnnotation; | |
import flex.lang.reflect.metadata.MetaDataArgument; |
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
private function mapServiceClasses():void | |
{ | |
for each (var serviceClass:Class in [ ServiceClassA, ServiceClassB, ServiceClassC ]) | |
{ | |
injector.mapFactory(serviceClass, prepareInstance(serviceClass)); | |
} | |
function prepareInstance(serviceClass:Class):Function | |
{ | |
return function():AbstractServiceClass |
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 | |
{ | |
import flash.display.Graphics; | |
import flash.display.Shape; | |
import flash.display.Sprite; | |
import flash.geom.Point; | |
public class LogarithmicSpiralTest extends Sprite | |
{ | |
public function LogarithmicSpiralTest() |
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 hype.framework.core { | |
import hype.framework.behavior.AbstractBehavior; | |
import hype.framework.trigger.AbstractTrigger; | |
/** | |
* Creates and manages pools of objects | |
*/ | |
public class ObjectPool { | |
private var _classList:Array; | |
private var _max:uint; |
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
// originally from Andy Shang http://bbs.9ria.com/viewthread.php?tid=47399 | |
package | |
{ | |
import flash.display.Sprite; | |
public class AOPTest extends Sprite | |
{ | |
public function AOPTest() | |
{ |
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 | |
{ | |
import flash.display.Loader; | |
import flash.display.Sprite; | |
import flash.events.Event; | |
import flash.geom.Point; | |
import flash.net.URLRequest; | |
import flash.system.ApplicationDomain; | |
import flash.system.LoaderContext; | |
import flash.utils.describeType; |
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
private var _selectedMetric:Metric; | |
[Bindable] | |
public function get selectedMetric():Metric | |
{ | |
return _selectedMetric; | |
} | |
public function set selectedMetric(value:Metric):void | |
{ |
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
(import '(java.awt.image BufferedImage)) | |
(import '(javax.imageio ImageIO IIOImage)) | |
(import '(javax.imageio.stream FileImageOutputStream)) | |
(import '(com.sun.imageio.plugins.png PNGMetadata PNGImageReader)) | |
(import '(java.io ByteArrayOutputStream File)) | |
;; See the following document for requirements | |
;; for upper- and lower-case letters in the four-letter chunk name: | |
;; http://en.wikipedia.org/wiki/Portable_Network_Graphics#.22Chunks.22_within_the_file | |
(def generator-chunk-name "gnTr") |
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
(ns rovers | |
(:use [clojure.string :only [split-lines]])) | |
(def *test-input* | |
"5 5 | |
1 2 N | |
LMLMLMLMM | |
3 3 E | |
MMRMMRMRRM") |
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
(ns account | |
(:import [java.util Date] | |
[java.lang Math]) | |
(:use [util])) | |
(def account-type [:checking :savings :money-market]) | |
(def interest-rate (zipmap account-type [0.02 0.04 0.06])) | |
(def overdraft-charge (zipmap account-type [0.10 0.075 0.05])) |
OlderNewer