Get Target

package net.justinfront;

/**
 * 
 * @author JLM at justinfront dot net
 * 26 August 2012
 * Simple static function to get the current target, you can trace( net.justinfront.Util.getTarget() );
 */

enum Target
{
    FLASH;
    FLASH8;
    CPP;
    PHP;
    NEKO;
    JS;
    JAVA;
    CS;
}
class Util
{
    public static function getTarget(): Target
    {
        #if flash
            return FLASH;
        #elseif flash8
           return FLASH8;
        #elseif cpp
            return CPP;
        #elseif php
            return PHP;
        #elseif neko
            return NEKO;
        #elseif js
            return JS;
        #elseif java
            return JAVA;
        #elseif cs
            return CS;
        #end
    }
}

version #15417, modified 2012-08-26 20:24:06 by JLM