BVB Source Codes

rouge Show java Source code

Return Download rouge: download java Source code - Download rouge Source code - Type:.java
  1. ////// badcase.java //////
  2.  
  3. // this used to take ages
  4. void foo() throws xxxxxxxxxxxxxxxxxxxxxx{ }
  5.  
  6. // numbers
  7. // [jneen] via http://docs.oracle.com/javase/7/docs/technotes/guides/language/underscores-literals.html
  8.  
  9. float pi1 = 3_.1415F;      // Invalid; cannot put underscores adjacent to a decimal point
  10. float pi2 = 3._1415F;      // Invalid; cannot put underscores adjacent to a decimal point
  11. long socialSecurityNumber1
  12.   = 999_99_9999_L;         // Invalid; cannot put underscores prior to an L suffix
  13.  
  14. int x1 = _52;              // This is an identifier, not a numeric literal
  15. int x2 = 5_2;              // OK (decimal literal)
  16. int x3 = 52_;              // Invalid; cannot put underscores at the end of a literal
  17. int x4 = 5_______2;        // OK (decimal literal)
  18.  
  19. int x5 = 0_x52;            // Invalid; cannot put underscores in the 0x radix prefix
  20. int x6 = 0x_52;            // Invalid; cannot put underscores at the beginning of a number
  21. int x7 = 0x5_2;            // OK (hexadecimal literal)
  22. int x8 = 0x52_;            // Invalid; cannot put underscores at the end of a number
  23.  
  24. int x9 = 0_52;             // OK (octal literal)
  25. int x10 = 05_2;            // OK (octal literal)
  26. int x11 = 052_;            // Invalid; cannot put underscores at the end of a number
  27.  
  28.  
  29. ////// test.java /////////
  30. /*
  31.  * Created on 13-Mar-2004
  32.  * Created by James Yeh
  33.  * Copyright (C) 2004, 2005, 2006 Aelitis, All Rights Reserved.
  34.  *
  35.  * This program is free software; you can redistribute it and/or
  36.  * modify it under the terms of the GNU General Public License
  37.  * as published by the Free Software Foundation; either version 2
  38.  * of the License, or (at your option) any later version.
  39.  * This program is distributed in the hope that it will be useful,
  40.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  41.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  42.  * GNU General Public License for more details.
  43.  * You should have received a copy of the GNU General Public License
  44.  * along with this program; if not, write to the Free Software
  45.  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
  46.  *
  47.  * AELITIS, SAS au capital de 46,603.30 euros
  48.  * 8 Allee Lenotre, La Grille Royale, 78600 Le Mesnil le Roi, France.
  49.  *
  50.  */
  51.  
  52. package org.gudy.azureus2.platform.macosx;
  53.  
  54. import org.gudy.azureus2.core3.logging.*;
  55. import org.gudy.azureus2.core3.util.AEMonitor;
  56. import org.gudy.azureus2.core3.util.Debug;
  57. import org.gudy.azureus2.core3.util.SystemProperties;
  58. import org.gudy.azureus2.platform.PlatformManager;
  59. import org.gudy.azureus2.platform.PlatformManagerCapabilities;
  60. import org.gudy.azureus2.platform.PlatformManagerListener;
  61. import org.gudy.azureus2.platform.macosx.access.jnilib.OSXAccess;
  62.  
  63. import org.gudy.azureus2.plugins.platform.PlatformManagerException;
  64.  
  65. import java.io.BufferedReader;
  66. import java.io.File;
  67. import java.io.IOException;
  68. import java.io.InputStreamReader;
  69. import java.text.MessageFormat;
  70. import java.util.HashSet;
  71.  
  72.  
  73. /**
  74.  * Performs platform-specific operations with Mac OS X
  75.  *
  76.  * @author James Yeh
  77.  * @version 1.0 Initial Version
  78.  * @see PlatformManager
  79.  */
  80. public class PlatformManagerImpl implements PlatformManager
  81. {
  82.     private static final LogIDs LOGID = LogIDs.CORE;
  83.  
  84.     protected static PlatformManagerImpl singleton;
  85.     protected static AEMonitor class_mon = new AEMonitor("PlatformManager");
  86.  
  87.     private static final String USERDATA_PATH = new File(System.getProperty("user.home") + "/Library/Application Support/").getPath();
  88.  
  89.     //T: PlatformManagerCapabilities
  90.     private final HashSet capabilitySet = new HashSet();
  91.  
  92.     /**
  93.      * Gets the platform manager singleton, which was already initialized
  94.      */
  95.     public static PlatformManagerImpl getSingleton()
  96.     {
  97.         return singleton;
  98.     }
  99.  
  100.     /**
  101.      * Tries to enable cocoa-java access and instantiates the singleton
  102.      */
  103.     static
  104.     {
  105.         initializeSingleton();
  106.     }
  107.  
  108.     /**
  109.      * Instantiates the singleton
  110.      */
  111.     private static void initializeSingleton()
  112.     {
  113.         try
  114.         {
  115.             class_mon.enter();
  116.             singleton = new PlatformManagerImpl();
  117.         }
  118.         catch (Throwable e)
  119.         {
  120.                 Logger.log(new LogEvent(LOGID, "Failed to initialize platform manager"
  121.                                         + " for Mac OS X", e));
  122.         }
  123.         finally
  124.         {
  125.             class_mon.exit();
  126.         }
  127.     }
  128.  
  129.     /**
  130.      * Creates a new PlatformManager and initializes its capabilities
  131.      */
  132.     public PlatformManagerImpl()
  133.     {
  134.         capabilitySet.add(PlatformManagerCapabilities.RecoverableFileDelete);
  135.         capabilitySet.add(PlatformManagerCapabilities.ShowFileInBrowser);
  136.         capabilitySet.add(PlatformManagerCapabilities.ShowPathInCommandLine);
  137.         capabilitySet.add(PlatformManagerCapabilities.CreateCommandLineProcess);
  138.         capabilitySet.add(PlatformManagerCapabilities.GetUserDataDirectory);
  139.         capabilitySet.add(PlatformManagerCapabilities.UseNativeScripting);
  140.         capabilitySet.add(PlatformManagerCapabilities.PlaySystemAlert);
  141.        
  142.         if (OSXAccess.isLoaded()) {
  143.                 capabilitySet.add(PlatformManagerCapabilities.GetVersion);
  144.         }
  145.     }
  146.  
  147.     /**
  148.      * {@inheritDoc}
  149.      */
  150.     public int getPlatformType()
  151.     {
  152.         return PT_MACOSX;
  153.     }
  154.  
  155.     /**
  156.      * {@inheritDoc}
  157.      */
  158.     public String getVersion() throws PlatformManagerException
  159.     {
  160.         if (!OSXAccess.isLoaded()) {
  161.         throw new PlatformManagerException("Unsupported capability called on platform manager");
  162.         }
  163.        
  164.         return OSXAccess.getVersion();
  165.     }
  166.  
  167.     /**
  168.      * {@inheritDoc}
  169.      * @see org.gudy.azureus2.core3.util.SystemProperties#getUserPath()
  170.      */
  171.     public String getUserDataDirectory() throws PlatformManagerException
  172.     {
  173.         return USERDATA_PATH;
  174.     }
  175.  
  176.         public File
  177.         getLocation(
  178.                 long    location_id )
  179.        
  180.                 throws PlatformManagerException
  181.         {
  182.                 if ( location_id == LOC_USER_DATA ){
  183.                        
  184.                         return( new File( USERDATA_PATH ));
  185.                 }
  186.                
  187.                 return( null );
  188.         }
  189.     /**
  190.      * Not implemented; returns True
  191.      */
  192.     public boolean isApplicationRegistered() throws PlatformManagerException
  193.     {
  194.         return true;
  195.     }
  196.  
  197.    
  198.         public String
  199.         getApplicationCommandLine()
  200.                 throws PlatformManagerException
  201.         {
  202.                 try{       
  203.                         String  bundle_path = System.getProperty("user.dir") +SystemProperties.SEP+ SystemProperties.getApplicationName() + ".app";
  204.  
  205.                         File osx_app_bundle = new File( bundle_path ).getAbsoluteFile();
  206.                        
  207.                         if( !osx_app_bundle.exists() ) {
  208.                                 String msg = "OSX app bundle not found: [" +osx_app_bundle.toString()+ "]";
  209.                                 System.out.println( msg );
  210.                                 if (Logger.isEnabled())
  211.                                         Logger.log(new LogEvent(LOGID, msg));          
  212.                                 throw new PlatformManagerException( msg );
  213.                         }
  214.                        
  215.                         return "open -a \"" +osx_app_bundle.toString()+ "\"";
  216.                         //return osx_app_bundle.toString() +"/Contents/MacOS/JavaApplicationStub";
  217.                        
  218.                 }
  219.                 catch( Throwable t ){  
  220.                         t.printStackTrace();
  221.                         return null;
  222.                 }
  223.         }
  224.        
  225.        
  226.         public boolean
  227.         isAdditionalFileTypeRegistered(
  228.                 String          name,                           // e.g. "BitTorrent"
  229.                 String          type )                          // e.g. ".torrent"
  230.        
  231.                 throws PlatformManagerException
  232.         {
  233.             throw new PlatformManagerException("Unsupported capability called on platform manager");
  234.         }
  235.        
  236.         public void
  237.         unregisterAdditionalFileType(
  238.                 String          name,                           // e.g. "BitTorrent"
  239.                 String          type )                          // e.g. ".torrent"
  240.                
  241.                 throws PlatformManagerException
  242.         {
  243.                 throw new PlatformManagerException("Unsupported capability called on platform manager");
  244.         }
  245.        
  246.         public void
  247.         registerAdditionalFileType(
  248.                 String          name,                           // e.g. "BitTorrent"
  249.                 String          description,            // e.g. "BitTorrent File"
  250.                 String          type,                           // e.g. ".torrent"
  251.                 String          content_type )          // e.g. "application/x-bittorrent"
  252.        
  253.                 throws PlatformManagerException
  254.         {
  255.            throw new PlatformManagerException("Unsupported capability called on platform manager");
  256.         }
  257.        
  258.     /**
  259.      * Not implemented; does nothing
  260.      */
  261.     public void registerApplication() throws PlatformManagerException
  262.     {
  263.         // handled by LaunchServices and/0r user interaction
  264.     }
  265.  
  266.     /**
  267.      * {@inheritDoc}
  268.      */
  269.     public void createProcess(String cmd, boolean inheritsHandles) throws PlatformManagerException
  270.     {
  271.         try
  272.         {
  273.             performRuntimeExec(cmd.split(" "));
  274.         }
  275.         catch (Throwable e)
  276.         {
  277.             throw new PlatformManagerException("Failed to create process", e);
  278.         }
  279.     }
  280.  
  281.     /**
  282.      * {@inheritDoc}
  283.      */
  284.     public void performRecoverableFileDelete(String path) throws PlatformManagerException
  285.     {
  286.         File file = new File(path);
  287.         if(!file.exists())
  288.         {
  289.                         if (Logger.isEnabled())
  290.                                                         Logger.log(new LogEvent(LOGID, LogEvent.LT_WARNING, "Cannot find "
  291.                                                                         + file.getName()));
  292.             return;
  293.         }
  294.  
  295.         boolean useOSA = !NativeInvocationBridge.sharedInstance().isEnabled() || !NativeInvocationBridge.sharedInstance().performRecoverableFileDelete(file);
  296.  
  297.         if(useOSA)
  298.         {
  299.             try
  300.             {
  301.                 StringBuffer sb = new StringBuffer();
  302.                 sb.append("tell application \"");
  303.                 sb.append("Finder");
  304.                 sb.append("\" to move (posix file \"");
  305.                 sb.append(path);
  306.                 sb.append("\" as alias) to the trash");
  307.  
  308.                 performOSAScript(sb);
  309.             }
  310.             catch (Throwable e)
  311.             {
  312.                 throw new PlatformManagerException("Failed to move file", e);
  313.             }
  314.         }
  315.     }
  316.  
  317.     /**
  318.      * {@inheritDoc}
  319.      */
  320.     public boolean hasCapability(PlatformManagerCapabilities capability)
  321.     {
  322.         return capabilitySet.contains(capability);
  323.     }
  324.  
  325.     /**
  326.      * {@inheritDoc}
  327.      */
  328.     public void dispose()
  329.     {
  330.         NativeInvocationBridge.sharedInstance().dispose();
  331.     }
  332.  
  333.     /**
  334.      * {@inheritDoc}
  335.      */
  336.     public void setTCPTOSEnabled(boolean enabled) throws PlatformManagerException
  337.     {
  338.         throw new PlatformManagerException("Unsupported capability called on platform manager");
  339.     }
  340.  
  341.         public void
  342.     copyFilePermissions(
  343.                 String  from_file_name,
  344.                 String  to_file_name )
  345.        
  346.                 throws PlatformManagerException
  347.         {
  348.             throw new PlatformManagerException("Unsupported capability called on platform manager");           
  349.         }
  350.        
  351.     /**
  352.      * {@inheritDoc}
  353.      */
  354.     public void showFile(String path) throws PlatformManagerException
  355.     {
  356.         File file = new File(path);
  357.         if(!file.exists())
  358.         {
  359.                 if (Logger.isEnabled())
  360.                         Logger.log(new LogEvent(LOGID, LogEvent.LT_WARNING, "Cannot find "
  361.                                         + file.getName()));
  362.             throw new PlatformManagerException("File not found");
  363.         }
  364.  
  365.         showInFinder(file);
  366.     }
  367.  
  368.     // Public utility methods not shared across the interface
  369.  
  370.     /**
  371.      * Plays the system alert (the jingle is specified by the user in System Preferences)
  372.      */
  373.     public void playSystemAlert()
  374.     {
  375.         try
  376.         {
  377.             performRuntimeExec(new String[]{"beep"});
  378.         }
  379.         catch (IOException e)
  380.         {
  381.                 if (Logger.isEnabled())
  382.                         Logger.log(new LogEvent(LOGID, LogEvent.LT_WARNING,
  383.                                                 "Cannot play system alert"));
  384.                 Logger.log(new LogEvent(LOGID, "", e));
  385.         }
  386.     }
  387.  
  388.     /**
  389.      * <p>Shows the given file or directory in Finder</p>
  390.      * @param path Absolute path to the file or directory
  391.      */
  392.     public void showInFinder(File path)
  393.     {
  394.         boolean useOSA = !NativeInvocationBridge.sharedInstance().isEnabled() || !NativeInvocationBridge.sharedInstance().showInFinder(path);
  395.  
  396.         if(useOSA)
  397.         {
  398.             StringBuffer sb = new StringBuffer();
  399.             sb.append("tell application \"");
  400.             sb.append(getFileBrowserName());
  401.             sb.append("\" to reveal (posix file \"");
  402.             sb.append(path);
  403.             sb.append("\" as alias)");
  404.  
  405.             try
  406.             {
  407.                 performOSAScript(sb);
  408.             }
  409.             catch (IOException e)
  410.             {
  411.                 Logger.log(new LogAlert(LogAlert.UNREPEATABLE, LogAlert.AT_ERROR, e
  412.                                                 .getMessage()));
  413.             }
  414.         }
  415.     }
  416.  
  417.     /**
  418.      * <p>Shows the given file or directory in Terminal by executing cd /absolute/path/to</p>
  419.      * @param path Absolute path to the file or directory
  420.      */
  421.     public void showInTerminal(String path)
  422.     {
  423.         showInTerminal(new File(path));
  424.     }
  425.  
  426.     /**
  427.      * <p>Shows the given file or directory in Terminal by executing cd /absolute/path/to</p>
  428.      * @param path Absolute path to the file or directory
  429.      */
  430.     public void showInTerminal(File path)
  431.     {
  432.         if (path.isFile())
  433.         {
  434.             path = path.getParentFile();
  435.         }
  436.  
  437.         if (path != null && path.isDirectory())
  438.         {
  439.             StringBuffer sb = new StringBuffer();
  440.             sb.append("tell application \"");
  441.             sb.append("Terminal");
  442.             sb.append("\" to do script \"cd ");
  443.             sb.append(path.getAbsolutePath().replaceAll(" ", "\\ "));
  444.             sb.append("\"");
  445.  
  446.             try
  447.             {
  448.                 performOSAScript(sb);
  449.             }
  450.             catch (IOException e)
  451.             {
  452.                 Logger.log(new LogAlert(LogAlert.UNREPEATABLE, LogAlert.AT_ERROR, e
  453.                                                 .getMessage()));
  454.             }
  455.         }
  456.         else
  457.         {
  458.                 if (Logger.isEnabled())
  459.                         Logger.log(new LogEvent(LOGID, LogEvent.LT_WARNING, "Cannot find "
  460.                                         + path.getName()));
  461.         }
  462.     }
  463.  
  464.     // Internal utility methods
  465.  
  466.     /**
  467.      * Compiles a new AppleScript instance and runs it
  468.      * @param cmd AppleScript command to execute; do not surround command with extra quotation marks
  469.      * @return Output of the script
  470.      * @throws IOException If the script failed to execute
  471.      */
  472.     protected static String performOSAScript(CharSequence cmd) throws IOException
  473.     {
  474.         return performOSAScript(new CharSequence[]{cmd});
  475.     }
  476.  
  477.     /**
  478.      * Compiles a new AppleScript instance and runs it
  479.      * @param cmds AppleScript Sequence of commands to execute; do not surround command with extra quotation marks
  480.      * @return Output of the script
  481.      * @throws IOException If the script failed to execute
  482.      */
  483.     protected static String performOSAScript(CharSequence[] cmds) throws IOException
  484.     {
  485.         long start = System.currentTimeMillis();
  486.         Debug.outNoStack("Executing OSAScript: ");
  487.         for (int i = 0; i < cmds.length; i++)
  488.         {
  489.             Debug.outNoStack("\t" + cmds[i]);
  490.         }
  491.  
  492.         String[] cmdargs = new String[2 * cmds.length + 1];
  493.         cmdargs[0] = "osascript";
  494.         for (int i = 0; i < cmds.length; i++)
  495.         {
  496.             cmdargs[i * 2 + 1] = "-e";
  497.             cmdargs[i * 2 + 2] = String.valueOf(cmds[i]);
  498.         }
  499.  
  500.         Process osaProcess = performRuntimeExec(cmdargs);
  501.         BufferedReader reader = new BufferedReader(new InputStreamReader(osaProcess.getInputStream()));
  502.         String line = reader.readLine();
  503.         reader.close();
  504.         Debug.outNoStack("OSAScript Output: " + line);
  505.  
  506.         reader = new BufferedReader(new InputStreamReader(osaProcess.getErrorStream()));
  507.         String errorMsg = reader.readLine();
  508.         reader.close();
  509.  
  510.         Debug.outNoStack("OSAScript Error (if any): " + errorMsg);
  511.  
  512.         Debug.outNoStack(MessageFormat.format("OSAScript execution ended ({0}ms)", new Object[]{String.valueOf(System.currentTimeMillis() - start)}));
  513.  
  514.         if (errorMsg != null)
  515.         {
  516.             throw new IOException(errorMsg);
  517.         }
  518.  
  519.         return line;
  520.     }
  521.  
  522.     /**
  523.      * Compiles a new AppleScript instance and runs it
  524.      * @param script AppleScript file (.scpt) to execute
  525.      * @return Output of the script
  526.      * @throws IOException If the script failed to execute
  527.      */
  528.     protected static String performOSAScript(File script) throws IOException
  529.     {
  530.         long start = System.currentTimeMillis();
  531.         Debug.outNoStack("Executing OSAScript from file: " + script.getPath());
  532.  
  533.         Process osaProcess = performRuntimeExec(new String[]{"osascript", script.getPath()});
  534.         BufferedReader reader = new BufferedReader(new InputStreamReader(osaProcess.getInputStream()));
  535.         String line = reader.readLine();
  536.         reader.close();
  537.         Debug.outNoStack("OSAScript Output: " + line);
  538.  
  539.         reader = new BufferedReader(new InputStreamReader(osaProcess.getErrorStream()));
  540.         String errorMsg = reader.readLine();
  541.         reader.close();
  542.  
  543.         Debug.outNoStack("OSAScript Error (if any): " + errorMsg);
  544.  
  545.         Debug.outNoStack(MessageFormat.format("OSAScript execution ended ({0}ms)", new Object[]{String.valueOf(System.currentTimeMillis() - start)}));
  546.  
  547.         if (errorMsg != null)
  548.         {
  549.             throw new IOException(errorMsg);
  550.         }
  551.  
  552.         return line;
  553.     }
  554.  
  555.     /**
  556.      * Compiles a new AppleScript instance to the specified location
  557.      * @param cmd         Command to compile; do not surround command with extra quotation marks
  558.      * @param destination Destination location of the AppleScript file
  559.      * @return True if compiled successfully
  560.      */
  561.     protected static boolean compileOSAScript(CharSequence cmd, File destination)
  562.     {
  563.         return compileOSAScript(new CharSequence[]{cmd}, destination);
  564.     }
  565.  
  566.     /**
  567.      * Compiles a new AppleScript instance to the specified location
  568.      * @param cmds Sequence of commands to compile; do not surround command with extra quotation marks
  569.      * @param destination Destination location of the AppleScript file
  570.      * @return True if compiled successfully
  571.      */
  572.     protected static boolean compileOSAScript(CharSequence[] cmds, File destination)
  573.     {
  574.         long start = System.currentTimeMillis();
  575.         Debug.outNoStack("Compiling OSAScript: " + destination.getPath());
  576.         for (int i = 0; i < cmds.length; i++)
  577.         {
  578.             Debug.outNoStack("\t" + cmds[i]);
  579.         }
  580.  
  581.         String[] cmdargs = new String[2 * cmds.length + 3];
  582.         cmdargs[0] = "osacompile";
  583.         for (int i = 0; i < cmds.length; i++)
  584.         {
  585.             cmdargs[i * 2 + 1] = "-e";
  586.             cmdargs[i * 2 + 2] = String.valueOf(cmds[i]);
  587.         }
  588.  
  589.         cmdargs[cmdargs.length - 2] = "-o";
  590.         cmdargs[cmdargs.length - 1] = destination.getPath();
  591.  
  592.         String errorMsg;
  593.         try
  594.         {
  595.             Process osaProcess = performRuntimeExec(cmdargs);
  596.  
  597.             BufferedReader reader = new BufferedReader(new InputStreamReader(osaProcess.getErrorStream()));
  598.             errorMsg = reader.readLine();
  599.             reader.close();
  600.         }
  601.         catch (IOException e)
  602.         {
  603.             Debug.outNoStack("OSACompile Execution Failed: " + e.getMessage());
  604.             Debug.printStackTrace(e);
  605.             return false;
  606.         }
  607.  
  608.         Debug.outNoStack("OSACompile Error (if any): " + errorMsg);
  609.  
  610.         Debug.outNoStack(MessageFormat.format("OSACompile execution ended ({0}ms)", new Object[]{String.valueOf(System.currentTimeMillis() - start)}));
  611.  
  612.         return (errorMsg == null);
  613.     }
  614.  
  615.     /**
  616.      * @see Runtime#exec(String[])
  617.      */
  618.     protected static Process performRuntimeExec(String[] cmdargs) throws IOException
  619.     {
  620.         try
  621.         {
  622.             return Runtime.getRuntime().exec(cmdargs);
  623.         }
  624.         catch (IOException e)
  625.         {
  626.             Logger.log(new LogAlert(LogAlert.UNREPEATABLE, e.getMessage(), e));
  627.             throw e;
  628.         }
  629.     }
  630.  
  631.     /**
  632.      * <p>Gets the preferred file browser name</p>
  633.      * <p>Currently supported browsers are Path Finder and Finder. If Path Finder is currently running
  634.      * (not just installed), then "Path Finder is returned; else, "Finder" is returned.</p>
  635.      * @return "Path Finder" if it is currently running; else "Finder"
  636.      */
  637.     private static String getFileBrowserName()
  638.     {
  639.         try
  640.         {
  641.             // slowwwwwwww
  642.             if ("true".equalsIgnoreCase(performOSAScript("tell application \"System Events\" to exists process \"Path Finder\"")))
  643.             {
  644.                 Debug.outNoStack("Path Finder is running");
  645.  
  646.                 return "Path Finder";
  647.             }
  648.             else
  649.             {
  650.                 return "Finder";
  651.             }
  652.         }
  653.         catch (IOException e)
  654.         {
  655.             Debug.printStackTrace(e);
  656.             Logger.log(new LogEvent(LOGID, e.getMessage(), e));
  657.  
  658.             return "Finder";
  659.         }
  660.     }
  661.    
  662.         public boolean
  663.         testNativeAvailability(
  664.                 String  name )
  665.        
  666.                 throws PlatformManagerException
  667.         {
  668.             throw new PlatformManagerException("Unsupported capability called on platform manager");           
  669.         }
  670.    
  671.     public void
  672.     addListener(
  673.         PlatformManagerListener         listener )
  674.     {
  675.     }
  676.    
  677.     public void
  678.     removeListener(
  679.         PlatformManagerListener         listener )
  680.     {
  681.     }
  682. }
  683.  
downloadjava Source code - Download rouge Source code
Related Source Codes/Software:
spring-security-oauth - Support for adding OAuth1(a) and OAuth2 features (... 2017-04-23
Toucan - Fabulous Image Processing in Swift 2017-04-23
CoffeeScriptRedux - 2017-04-23
breakpoint - Really simple media queries in Sa 2017-04-23
libsvm - 2017-04-22
sphinx_rtd_theme - Sphinx theme for readthedocs.org 2017-04-23
BlurEffectForAndroidDesign - Sample to show how to implement blur graphical tri... 2017-04-23
mama2 - Mother plan - all firewood high flame 2017-04-23
JKeyboardPanelSwitch - For resolve the layout conflict when keybord & amp... 2017-04-23
viz.js - A hack to put Graphviz on the web. ... 2017-04-23
browser-diet - 2017-04-30
react-music - Make beats with React! http... 2017-04-30
java-code-styles - IntelliJ IDEA code style settings for Square's Jav... 2017-04-30
swing - A swipeable cards interface. The swipe-left/swipe-... 2017-04-30
qTip2 - qTip2 - Pretty powerful tooltips ... 2017-04-30
jo - JSON output from a shell 2017-04-30
Fluidbox - Replicating and improving the lightbox module seen... 2017-04-30
boto3 - AWS SDK for Python http://a... 2017-04-30
PreloadJS - PreloadJS makes preloading assets & getting ag... 2017-04-29
gotraining - Go Training Class Material : ... 2017-04-29

 Back to top