text:
namespace chrome_cleaner {

class TestPUPData;
class SignatureMatcherAPI;
class UwSCatalog;

// This class exposes the data necessary to identify and remove Potentially
// Unwanted Programs (PUPs). We use a class instead of the null terminating
// C-Arrays directly so that we can filter based on UwSId's when only a subset
// of the PUPs are needed (e.g., the cleaner module is only interested in the
// PUPs that scanner has found).
class PUPData {
 public:
  // These flags are applied to whole PUPs.
  typedef uint32_t Flags;
  enum : Flags {
    FLAGS_NONE = 0,
    // Used when a PUP should be removed, otherwise it is only reported.
    FLAGS_ACTION_REMOVE = 1 << 0,
    // Used when a PUP should always be removed post-reboot, even when the
    // Restart Manager doesn't think a reboot is needed.
    FLAGS_REMOVAL_FORCE_REBOOT = 1 << 1,
    // When the UwS is detected activate the detailed system report.
    DEPRECATED_FLAGS_DETAILED_REPORT = 1 << 2,
    // Used for PUPs that interfere with the prompt, so we don't want to report
    // that a cleanup can be done when they are present. This only affects the
    // reporter, not the removal tool.
    DEPRECATED_FLAGS_INHIBIT_REPORTING = 1 << 3,
    // Used for PUPs that interfere with the cleaner, so we don't want to offer
    // a removal to the user when they are present. This affects both the
    // reporter and the removal tool.
    DEPRECATED_FLAGS_INHIBIT_REMOVAL = 1 << 4,
    // Behaviour that breaks our UwS policies
    // (https://www.google.com/about/unwanted-software-policy.html) has been
    // observed and confirmed. PUP's without this flag are still being
    // investigated and must not be removed.
    FLAGS_STATE_CONFIRMED_UWS = 1 << 5,
    // The UwS is considered a malware.
    DEPRECATED_FLAGS_CATEGORY_MALWARE = 1 << 6,
    // The UwS is hijacking the browser.
    DEPRECATED_FLAGS_CATEGORY_BROWSER_HIJACKER = 1 << 7,
    // The UwS is injecting an extension.
    DEPRECATED_FLAGS_CATEGORY_EXTENSIONS_INJECTOR = 1 << 8,
    // The UwS is injecting ads in webpages.
    DEPRECATED_FLAGS_CATEGORY_ADS_INJECTOR = 1 << 9,
    // The UwS is a scareware.
    DEPRECATED_FLAGS_CATEGORY_SCAREWARE = 1 << 10,
    // When adding new flags here, please update
    // chrome_cleaner/proto/uws_spec_by_version.proto.
  };

  // A matching rule describes how the content of a disk footprint is matched.
  enum DiskMatchRule {
    // An invalid matching rule.
    DISK_MATCH_INVALID = 0,
    // Any file will match. So a folder is always marked as found, as long as it
    // contains at least one file.
    DISK_MATCH_ANY_FILE,
    // Only binary files will match. So a folder is only marked as found if it
    // contains at least one binary file (i.e., .exe, .dll, or .sys).
    // Note, this can't be used as part of the scanning footprints for a removal
    // signature (it can be used with a remove only footprint).
    DISK_MATCH_BINARY_FILE,
    // When the file path is found, clean containing folder X levels up. E.g.,
    // if the path is C:\a\b\c\d.exe, then for DISK_MATCH_FILE_IN_FOLDER_DEPTH_1
    // the whole folder c:\a\b\c is deleted, but for
    // DISK_MATCH_FILE_IN_FOLDER_DEPTH_3 c:\a is deleted. Only paths to files
    // are
    // supported now, this won't match a folder within a folder.
    DISK_MATCH_FILE_IN_FOLDER_DEPTH_1,
    DISK_MATCH_FILE_IN_FOLDER_DEPTH_2,
    DISK_MATCH_FILE_IN_FOLDER_DEPTH_3,
    DISK_MATCH_FILE_IN_FOLDER_DEPTH_4,
    // DISK_MATCH_FILE_IN_FOLDER_END should only be used to indicate the end
    // value for file in folder depths.
    DISK_MATCH_FILE_IN_FOLDER_END,
  };

  // This invalid UwSId is used to identify the end of a PUP array.
  static const UwSId kInvalidUwSId = 0xFFFFFFFF;

  // This id indicates when a footprint isn't associated with any flavour.
  static const int kNoFlavour = -1;

  // The default number of active files to be willing to remove for various
  // UwS installation sizes.
  static const size_t kMaxFilesToRemoveLargeUwS = 200;
  static const size_t kMaxFilesToRemoveMediumUwS = 100;
  static const size_t kMaxFilesToRemoveSmallUwS = 50;

  // This id is used when a StaticDiskFootprint doesn't have a CSIDL.
  static const int kInvalidCsidl = -1;

  // The delimiters used to split registry values.
  static const wchar_t kCommaDelimiter[];
  static const size_t kCommaDelimiterLength;
  static const wchar_t kCommonDelimiters[];
  static const size_t kCommonDelimitersLength;

  // The character used to escape wild-cards into registry key name patterns.
  static const wchar_t kRegistryPatternEscapeCharacter;

  // A disk footprint is just a path.
  struct StaticDiskFootprint {
    // A flavour is used to indicate what footprints should be grouped and
    // removed together.
    int flavour;
    // A CSIDL value identifying the root of |path| if it is a relative path.
    // |csidl| is simply ignored when |path| is an absolute path or is null.
    int csidl;
    // Is only null for the last entry identifying the end of the array.
    // It can be either an absolute path, or a relative path, in which case,
    // |csidl| is used to get the proper root.
    const wchar_t* path;
    // Describe the way |path| is used to match the disk footprint.
    DiskMatchRule rule;
  };

  // Information stored in the registry. If |value_name| is empty, the whole
  // key at |key_path| is the footprint. If |value_substring| is not empty,
  // then |value_name| can not be empty, and only the substring in
  // |value_substring| is scanned for, or removed. For example, we may want to
  // only remove the PUP path from the AppInit_DLLs registry entry, and leave
  // other paths in there. When |value_substring| is null but not |value_name|,
  // then the whole value is to be removed.
  struct StaticRegistryFootprint {
    // A flavour is used to indicate what footprints should be grouped and
    // removed together.
    int flavour;
    // The root to use for this registry footprint. Ignored if |key_path| is
    // null.
    RegistryRoot registry_root;
    // Is only null for the last entry identifying the end of the array.
    const wchar_t* key_path;
    // Can be null if the whole key is to be removed. Can not be null when
    // |value_substring| is not null.
    const wchar_t* value_name;
    // Can be null if the whole value is to be removed.
    const wchar_t* value_substring;
    // Describe the way |value_substring| is used to match the content of the
    // registry value.
    RegistryMatchRule rule;
  };

  // Represents a path to be matched on disk using regular expressions. There is
  // a base path, which is either |csidl|/|path| if |path| is relative, or just
  // |path| if it is absolute. Then, the |regex_components| will be used to
  // match the remainder of the full path. |regex_components| can use
  // backreferences into previous components, as they will be successively
  // merged into the regex used to match the final path.
  struct MatchPath {
    // A CSIDL value identifying the root of |path| if it is a relative path.
    // |csidl| is simply ignored when |path| is an absolute path.
    int csidl;
    // Is only null for the last entry identifying the end of the array.
    // Can be either an absolute path, or a relative path, in which case,
    // |csidl| is used to get the proper root. Regex matching will start at this
    // path (but |path| itself is not a regex).
    const wchar_t* path;
    // The path components to be matched. A null entry indicates the end of the
    // list. These components must not use path separators. As the filesystem
    // gets enumerated, the components will be merged into one regex, which
    // means that backreferences of groups matched in previous components will
    // work.
    const wchar_t** regex_components;
  };

  // This is the expanded version of |StaticRegistryFootprint|. |key_path| and
  // |value_name| can no longer contain wildcards.
  struct RegistryFootprint {
    RegistryFootprint();
    RegistryFootprint(const RegKeyPath& key_path,
                      const base::string16& value_name,
                      const base::string16& value_substring,
                      RegistryMatchRule rule);
    RegistryFootprint(const RegistryFootprint& other);
    ~RegistryFootprint();

    RegistryFootprint& operator=(const RegistryFootprint& other);

    bool operator==(const RegistryFootprint& other) const;

    // Must not be empty.
    RegKeyPath key_path;
    // Can be empty for default value or when value is unused.
    base::string16 value_name;
    // Can be empty when unused.
    base::string16 value_substring;
    // Describe the way |value_substring| is used to match the content of the
    // registry value.
    RegistryMatchRule rule;
  };

  // Forward declaration.
  class PUP;

  // A container for PUP data, allows fast access.
  typedef std::unordered_map<UwSId, std::unique_ptr<PUP>> PUPDataMap;

  // The type of the function to execute the custom matcher. The |pup| structure
  // should be filled with the found footprint. The |active_footprint_found|
  // must be set to true when non-leftover footprint are found.
  // Return false on failure. On failure, the whole scan and remove process is
  // interrupted for this PUP.
  typedef bool (*CustomMatcher)(const MatchingOptions& options,
                                const SignatureMatcherAPI* signature_matcher,
                                PUP* pup,
                                bool* active_footprint_found);

  // All the information and footprints of a single UwS.
  //
  // The fields of this structure should point to static memory so that they
  // remain valid as UwSSignature objects are copied. This structure cannot
  // have an explicit constructor because it is commonly aggregate-initialized.
  struct UwSSignature {
    UwSId id = 0;
    Flags flags = 0;
    // The name of the UwS. Can be null for anonymous UwS.
    const char* name = nullptr;
    // An upper limit on the number of files allowed to be deleted for the UwS
    // to avoid damage caused by internal errors or malware interactions.
    size_t max_files_to_remove = 0;
    // The following arrays are terminated by an entry with a null [key_]path.
    const StaticDiskFootprint* disk_footprints = nullptr;
    const StaticRegistryFootprint* registry_footprints = nullptr;
    // Custom matchers to scan UwS with dynamic footprints.
    const CustomMatcher* custom_matchers = nullptr;
  };

  struct FileInfo {
    FileInfo();
    FileInfo(const FileInfo&);
    explicit FileInfo(const std::set<UwS::TraceLocation>& found_in);
    ~FileInfo();

    bool operator==(const FileInfo& other) const;

    std::set<UwS::TraceLocation> found_in;
  };

  // The data that was matched for an UwS during scanning.
  //
  // PUP objects are created in the engine sandbox process as the engine finds
  // UwS, and then copied to the broker process using the Mojo interface in
  // interfaces/pup.mojom.
  //
  // For the legacy scanning engine PUP objects are created directly in the
  // sandbox broker process.
  class PUP {
   public:
    typedef FilePathMap<FileInfo> FileInfoMap;

    // Default constructor required by Mojo. Initializes signature with a null
    // pointer, since no information encoded there needs to be transmitted.
    PUP();
    explicit PUP(const UwSSignature* signature);
    PUP(const PUP& other);
    ~PUP();

    PUP& operator=(const PUP& other);

    // Static data for an UwS. This will be empty in the sandbox target
    // process. In the broker process the UwSSignature is looked up by UwSId
    // and added to the PUP structure.
    const UwSSignature& signature() const { return *signature_; }

    // Add the given |file_path| to |expanded_disk_footprints|. Return false if
    // |file_path| was already in the set.
    bool AddDiskFootprint(const base::FilePath& file_path);
    void ClearDiskFootprints();

    // Mark disk footprint |file_path| as detected in |location|.
    void AddDiskFootprintTraceLocation(const base::FilePath& file_path,
                                       UwS::TraceLocation location);

    // Add all matching data from |other| to the current pup.
    void MergeFrom(const PUP& other);

    // The set of expanded disk footprints generated by the scanner. Populated
    // in the target process when the engine is sandboxed.
    FilePathSet expanded_disk_footprints;

    // The set of expanded registry footprints generated by the scanner. Only
    // populated by the legacy unsandboxed engine.
    std::vector<RegistryFootprint> expanded_registry_footprints;

    // The list of expanded scheduled task names generated by the scanner.
    // Only populated by the legacy unsandboxed engine.
    std::vector<base::string16> expanded_scheduled_tasks;

    // Mapping from detected files to where they were found. Populated in the
    // target process when the engine is sandboxed.
    FileInfoMap disk_footprints_info;

    // List of UwE found by the scanner. Populated in the broker process after
    // the PUPData is copied from the target process.
    std::vector<ForceInstalledExtension> matched_extensions;

   protected:
    // Allow PUPData to update |signature_| when UpdateCachedUwSForTesting is
    // called. The signature pointers can be invalidated when TestPUPData
    // creates new test UwS, causing an existing vector of test UwS to be
    // resized.
    friend PUPData;

    const UwSSignature* signature_;
  };

  PUPData();
  ~PUPData();

  using UwSCatalogs = std::vector<const UwSCatalog*>;

  // Loads cached information from the given |uws_catalogs|. Must be called in
  // order to use static functions of PUPData. Calling it again will delete all
  // cached PUP structures, which will lose their state (detected disk
  // footprints, etc.)
  static void InitializePUPData(const UwSCatalogs& uws_catalogs);

  // Returns the |uws_catalogs| used in the last call to InitializePUPData.
  static const UwSCatalogs& GetUwSCatalogs() {
    DCHECK(last_uws_catalogs_);
    return *last_uws_catalogs_;
  }

  // Returns true if |uws_id| corresponds to a cached pup.
  static bool IsKnownPUP(UwSId uws_id);

  // Retrieves information about a given PUP. The ID must be valid otherwise
  // the function generates an error. The data returned is still owned by
  // PUPData.
  static PUP* GetPUP(UwSId uws_id);

  // Returns a vector of UwSId's used to iterate over all pups.
  static const std::vector<UwSId>* GetUwSIds();

  // Return the name of |pup| if it has one, and "???" otherwise.
  static const char* GetPUPName(const PUP* pup);

  // Return whether |flags| identify a report only PUPs.
  static bool HasReportOnlyFlag(Flags flags);

  // Return whether |flags| identify PUPs to remove.
  static bool HasRemovalFlag(Flags flags);

  // Return whether |flags| identify PUPs that needs a reboot.
  static bool HasRebootFlag(Flags flags);

  // Return whether |flags| identify PUPs that has been confirmed malicious.
  static bool HasConfirmedUwSFlag(Flags flags);

  // Return whether |uws_id| corresponds to a report only UwS.
  static bool IsReportOnlyUwS(UwSId uws_id);

  // Return whether |uws_id| corresponds to a removable UwS.
  static bool IsRemovable(UwSId uws_id);

  // Return whether |uws_id| corresponds to a confirmed malicious UwS.
  static bool IsConfirmedUwS(UwSId uws_id);

  // Copy PUP ids to |output| when the predicate |chooser| returns true.
  static void ChoosePUPs(const std::vector<UwSId>& input_pup_list,
                         bool (*chooser)(Flags),
                         std::vector<UwSId>* output);

  // Return whether there is at least one PUP with flags matched by |chooser|.
  static bool HasFlaggedPUP(const std::vector<UwSId>& input_pup_list,
                            bool (*chooser)(Flags));

  // Convert a RegistryRoot to its corresponding HKEY. If
  // |registry_root| is a group policy, and |policy_file| is not null, the path
  // to the group policy file is set in |policy_file|.
  // Return false on failure.
  static bool GetRootKeyFromRegistryRoot(RegistryRoot registry_root,
                                         HKEY* key,
                                         base::FilePath* policy_file);

  // Add a dynamic registry footprint to delete the registry key |key_path|.
  static void DeleteRegistryKey(const RegKeyPath& key_path, PUP* pup);

  // Add a dynamic registry footprint to delete the registry key |key_path|,
  // only if the key exists.
  static void DeleteRegistryKeyIfPresent(const RegKeyPath& key_path, PUP* pup);

  // Add a dynamic registry footprint to delete the registry value
  // |key_path|/|value_name|.
  static void DeleteRegistryValue(const RegKeyPath& key_path,
                                  const wchar_t* value_name,
                                  PUP* pup);

  // Add a dynamic registry footprint to delete the registry value
  // |key_path|/|value_name| with |rule|.
  static void UpdateRegistryValue(const RegKeyPath& key_path,
                                  const wchar_t* value_name,
                                  const wchar_t* value_substring,
                                  RegistryMatchRule rule,
                                  PUP* pup);

  // Add a dynamic footprint to delete a scheduled task.
  static void DeleteScheduledTask(const wchar_t* task_name, PUP* pup);

  // Return the engine this UwSId belongs to.
  static Engine::Name GetEngine(UwSId id);

 private:
  // So that tests can call UpdateCachedUwSForTesting to add new test UwS.
  friend TestPUPData;

  // Returns a cached map of PUPs from static arrays and caches it in a map.
  // Exposed for testing.
  static const PUPData::PUPDataMap* GetAllPUPs();

  // Updates all cached UwSSignature objects to point to the current contents
  // of the catalogs. Creates new PUP objects and adds them to the cache for
  // any UwSSignature's that are not already in the cache. Does not delete any
  // cached UwS; for that, call InitializePUPData again.
  //
  // This can be used when new test UwS is created to add that UwS to the cache
  // without invalidating any existing PUP objects that may already contain
  // expanded disk footprints.
  static void UpdateCachedUwSForTesting();

  static void AddPUPToMap(std::unique_ptr<PUPData::PUP> pup);

  // Cached PUPData information.
  static PUPDataMap* cached_pup_map_;

  // Cached UwSId list.
  static std::vector<UwSId>* cached_uws_ids_;

  static UwSCatalogs* last_uws_catalogs_;

  DISALLOW_COPY_AND_ASSIGN(PUPData);
};

// This macro makes it easier to create strings with the
// kRegistryPatternEscapeCharacter.
#define ESCAPE_REGISTRY_STR(str) L"\uFFFF" L##str

const PUPData::StaticDiskFootprint kNoDisk[] = {{}};
const PUPData::StaticRegistryFootprint kNoRegistry[] = {{}};
const PUPData::CustomMatcher kNoCustomMatcher[] = {{}};

}  // namespace chrome_cleaner

#endif  // CHROME_CHROME_CLEANER_PUP_DATA_PUP_DATA_H_


text:
(function() {
  //edit

  function SongPlayer($rootScope, Fixtures) {

/*
    @desc stopSong is a function to stop song;
*/
    var stopSong = function() {
      currentBuzzObject.stop();
      SongPlayer.currentSong.playing = null;
    };

/*
  * @var SongPlayer
  * @desc creating empty var
*/
    var SongPlayer = {};

    var currentAlbum = Fixtures.getAlbum();
/*
    @desc getting song number to know where at
*/
    var getSongIndex = function(song) {
      return currentAlbum.songs.indexOf(song);
    };

/*
* @desc Buzz object audio file
* @type {object}
*/

    var currentBuzzObject = null;

/*
  * @function setSong
  * @desc Stops currently playing song and loads new audio file as currentBuzzObject
  * @param {object} song
*/

    var playSong = function(song) {
      currentBuzzObject.play()
      song.playing = true;
    };

    var setSong = function(song) {
      if (currentBuzzObject) {
        stopSong();
      }

      currentBuzzObject = new buzz.sound(song.audioUrl, {
        formats: ['mp3'],
        preload: true
      });

      currentBuzzObject.bind('timeupdate', function() {
        $rootScope.$apply(function() {
          SongPlayer.currentTime = currentBuzzObject.getTime();
          SongPlayer.volume = currentBuzzObject.getVolume();
        });
      });

      SongPlayer.currentSong = song;
    };

/*
    @desc Active song object from list of songs
    @type {object}
*/

    SongPlayer.currentSong = null;

/*
    @desc Current playback time (in seconds) of currently playing song
    @type {Number}
*/
    SongPlayer.currentTime = null;

/*
    @desc SongPlayer.setVolume() interestingly enough sets the volume
*/

    SongPlayer.setVolume = function(volume) {
      if (currentBuzzObject) {
        currentBuzzObject.setVolume(volume);
      }
    };

/*
    @function setCurrentTime
    @desc Set current time (in seconds) of currently playing song
    @param {Number} time
*/
    SongPlayer.setCurrentTime = function(time) {
      if (currentBuzzObject) {
        currentBuzzObject.setTime(time);
      }
    };

/*
  * @function play(song)
  * @desc playing the music
*/

    SongPlayer.play = function(song) {
      song = song || SongPlayer.currentSong;
      if (SongPlayer.currentSong !== song) {
        setSong(song);
        playSong(song);
      } else if (SongPlayer.currentSong === song) {
        if (currentBuzzObject.isPaused()) {
          playSong(song);
        }
      }

    };

/*
  * @function pause(song)
  * @desc stop the music
*/

    SongPlayer.pause = function(song) {
      song = song || SongPlayer.currentSong;
      currentBuzzObject.pause();
      song.playing = false;
    };
/*
    @desc SongPlayer.previous its a previous button
*/
    SongPlayer.previous = function() {
      var currentSongIndex = getSongIndex(SongPlayer.currentSong);
      currentSongIndex--;

      if (currentSongIndex < 0) {
        stopSong();
      } else {
        var song = currentAlbum.songs[currentSongIndex];
        setSong(song);
        playSong(song);
      }
    };

/*
    @desc SongPlayer.next; its a next button
*/
    SongPlayer.next = function() {
      var currentSongIndex = getSongIndex(SongPlayer.currentSong);
      currentSongIndex++;

      if(currentSongIndex == currentAlbum.songs.length) {
        stopSong();
      } else {
        var song = currentAlbum.songs[currentSongIndex];
        setSong(song);
        playSong(song);
      }
    };

    return SongPlayer;
  }
/*
    @.factory
    @desc including Fixtures factory
*/
  angular
    .module('blocJams')
  //edit

    .factory('SongPlayer', ['$rootScope', 'Fixtures', SongPlayer]);

  //edit

    //.factory('SongPlayer', ['Fixtures', SongPlayer]);

  //end of edit
})();

redpajama_set_name: RedPajamaGithub


text:
class CreatePaintings < ActiveRecord::Migration
  def change
    create_table :paintings do |t|
      t.string :artist, :title, :time_frame, :medium, :surface, :small_img_url, :large_img_url
      t.integer :height, :weight
      t.timestamps
    end
  end
end


text:
package core.config;

import java.io.File;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.logging.Level;
import java.util.logging.Logger;

import javax.swing.JOptionPane;

import utilities.FileUtility;
import utilities.ILoggable;
import utilities.JSONUtility;
import argo.jdom.JsonNode;
import argo.jdom.JsonNodeFactories;
import argo.jdom.JsonRootNode;

import com.sun.glass.events.KeyEvent;

import core.ipc.IPCServiceManager;
import core.keyChain.KeyChain;
import core.languageHandler.compiler.DynamicCompilerManager;
import core.userDefinedTask.TaskGroup;
import frontEnd.MainBackEndHolder;

public class Config implements ILoggable {

	public static final String RELEASE_VERSION = "3.1.1";
	private static final String CONFIG_FILE_NAME = "config.json";
	public static final String EXPORTED_CONFIG_FILE_NAME = "exported_" + CONFIG_FILE_NAME;
	protected static final String CURRENT_CONFIG_VERSION = "2.0";

	private static final Level DEFAULT_NATIVE_HOOK_DEBUG_LEVEL = Level.WARNING;
	private static final boolean DEFAULT_TRAY_ICON_USE = true;

	private static final List<ConfigParser> knownParsers;

	private DynamicCompilerManager compilerFactory;
	private final MainBackEndHolder backEnd;

	public static final int HALT_TASK = KeyEvent.VK_ESCAPE; // This should be hardcoded, and must not be changed
	private KeyChain RECORD;
	private KeyChain REPLAY;
	private KeyChain COMPILED_REPLAY;

	private int mouseGestureActivationKey;
	private boolean useTrayIcon;
	private boolean enabledHaltingKeyPressed;
	/**
	 * If enabled will consider executing task on key released event. Otherwise will consider executing
	 * task on key pressed event.
	 */
	private boolean executeOnKeyReleased;
	private Level nativeHookDebugLevel;

	static {
		knownParsers = Arrays.asList(new ConfigParser[]{
				new Parser1_0(),
				new Parser1_1(),
				new Parser1_2(),
				new Parser1_3(),
				new Parser1_4(),
				new Parser1_5(),
				new Parser1_6(),
				new Parser1_7(),
				new Parser1_8(),
				new Parser1_9(),
				new Parser2_0()
			});
	}

	public Config(MainBackEndHolder backEnd) {
		this.backEnd = backEnd;
		useTrayIcon = DEFAULT_TRAY_ICON_USE;
		this.enabledHaltingKeyPressed = true;
		this.executeOnKeyReleased = false;
		this.nativeHookDebugLevel = DEFAULT_NATIVE_HOOK_DEBUG_LEVEL;

		this.mouseGestureActivationKey = KeyEvent.VK_CAPS_LOCK;
		RECORD = new KeyChain(KeyEvent.VK_F9);
		REPLAY = new KeyChain(KeyEvent.VK_F11);
		COMPILED_REPLAY = new KeyChain(KeyEvent.VK_F12);
	}

	public DynamicCompilerManager getCompilerFactory() {
		return compilerFactory;
	}

	protected static ConfigParser getConfigParser(String version) {
		for (ConfigParser parser : knownParsers) {
			if (parser.getVersion().equals(version)) {
				return parser;
			}
		}

		return null;
	}

	/**
	 * Get config parser whose previous version is this version
	 * @param version the version to consider
	 * @return the config parser whose previous version is this version
	 */
	protected static ConfigParser getNextConfigParser(String version) {
		for (ConfigParser parser : knownParsers) {
			String previousVersion = parser.getPreviousVersion();
			if (previousVersion != null && previousVersion.equals(version)) {
				return parser;
			}
		}

		return null;
	}

	public void loadConfig(File file) {
		compilerFactory = new DynamicCompilerManager();

		File configFile = file == null ? new File(CONFIG_FILE_NAME) : file;
		if (FileUtility.fileExists(configFile)) {
			JsonRootNode root = JSONUtility.readJSON(configFile);

			if (root == null) {
				JOptionPane.showMessageDialog(null, "Config file is not in json format");
				return;
			} else if (!root.isStringValue("version")) {
				JOptionPane.showMessageDialog(null, "Config file is in unknown version");
				return;
			}

			String version = root.getStringValue("version");
			ConfigParser parser = getConfigParser(version);
			boolean foundVersion = parser != null;
			boolean extractResult = false;
			if (foundVersion) {
				extractResult = parser.extractData(this, root);
			}

			if (!foundVersion) {
				JOptionPane.showMessageDialog(null, "Config file is in unknown version " + version);
				defaultExtract();
			}

			if (!extractResult) {
				JOptionPane.showMessageDialog(null, "Cannot extract result with version " + version);
				defaultExtract();
			}
		} else {
			defaultExtract();
		}
	}

	private void defaultExtract() {
		List<TaskGroup> taskGroups = backEnd.getTaskGroups();
		taskGroups.add(new TaskGroup("default"));
		backEnd.setCurrentTaskGroup(taskGroups.get(0));
	}

	public boolean writeConfig() {
		List<JsonNode> taskNodes = new ArrayList<>();
		for (TaskGroup group : backEnd.getTaskGroups()) {
			taskNodes.add(group.jsonize());
		}

		JsonRootNode root = JsonNodeFactories.object(
				JsonNodeFactories.field("version", JsonNodeFactories.string(CURRENT_CONFIG_VERSION)),
				JsonNodeFactories.field("global_settings", JsonNodeFactories.object(
						JsonNodeFactories.field("debug", JsonNodeFactories.object(
								JsonNodeFactories.field("level", JsonNodeFactories.string(nativeHookDebugLevel.toString()))
								)),
						JsonNodeFactories.field("tray_icon_enabled", JsonNodeFactories.booleanNode(useTrayIcon)),
						JsonNodeFactories.field("enabled_halt_by_key", JsonNodeFactories.booleanNode(enabledHaltingKeyPressed)),
						JsonNodeFactories.field("execute_on_key_released", JsonNodeFactories.booleanNode(executeOnKeyReleased)),
						JsonNodeFactories.field("global_hotkey", JsonNodeFactories.object(
								JsonNodeFactories.field("mouse_gesture_activation", JsonNodeFactories.number(mouseGestureActivationKey)),
								JsonNodeFactories.field("record", RECORD.jsonize()),
								JsonNodeFactories.field("replay", REPLAY.jsonize()),
								JsonNodeFactories.field("replay_compiled", COMPILED_REPLAY.jsonize())
						))
				)),
				JsonNodeFactories.field("ipc_settings", IPCServiceManager.jsonize()),
				JsonNodeFactories.field("compilers", compilerFactory.jsonize()),
				JsonNodeFactories.field("task_groups", JsonNodeFactories.array(taskNodes))
				);

		return JSONUtility.writeJson(root, new File(CONFIG_FILE_NAME));
	}

	public boolean exportTasksConfig(File destination) {
		List<JsonNode> taskNodes = new ArrayList<>();
		for (TaskGroup group : backEnd.getTaskGroups()) {
			taskNodes.add(group.jsonize());
		}

		JsonRootNode root = JsonNodeFactories.object(
				JsonNodeFactories.field("version", JsonNodeFactories.string(CURRENT_CONFIG_VERSION)),
				JsonNodeFactories.field("task_groups", JsonNodeFactories.array(taskNodes)));
		String fullPath = FileUtility.joinPath(destination.getAbsolutePath(), EXPORTED_CONFIG_FILE_NAME);
		return JSONUtility.writeJson(root, new File(fullPath));
	}

	public boolean importTaskConfig() {
		File configFile = new File(EXPORTED_CONFIG_FILE_NAME);
		if (!configFile.isFile()) {
			getLogger().warning("Config file does not exist " + configFile.getAbsolutePath());
			return false;
		}
		JsonRootNode root = JSONUtility.readJSON(configFile);
		if (root == null) {
			getLogger().warning("Unable to import config file " + configFile.getAbsolutePath());
			return false;
		}
		String version = root.getStringValue("version");
		ConfigParser parser = getConfigParser(version);
		if (parser == null) {
			getLogger().warning("Uknown version " + version);
			return false;
		}

		boolean result = parser.importData(this, root);
		return result;
	}

	public int getMouseGestureActivationKey() {
		return mouseGestureActivationKey;
	}

	public void setMouseGestureActivationKey(int mouseGestureActivationKey) {
		this.mouseGestureActivationKey = mouseGestureActivationKey;
	}

	public KeyChain getRECORD() {
		return RECORD;
	}

	public void setRECORD(KeyChain RECORD) {
		if (RECORD != null) {
			this.RECORD = RECORD;
		}
	}

	public void setRECORD(int RECORD) {
		setRECORD(new KeyChain(Arrays.asList(RECORD)));
	}

	public KeyChain getREPLAY() {
		return REPLAY;
	}

	public void setREPLAY(KeyChain REPLAY) {
		if (REPLAY != null) {
			this.REPLAY = REPLAY;
		}
	}

	public KeyChain getCOMPILED_REPLAY() {
		return COMPILED_REPLAY;
	}

	public void setCOMPILED_REPLAY(KeyChain COMPILED_REPLAY) {
		if (COMPILED_REPLAY != null) {
			this.COMPILED_REPLAY = COMPILED_REPLAY;
		}
	}

	public boolean isUseTrayIcon() {
		return useTrayIcon;
	}

	public void setUseTrayIcon(boolean useTrayIcon) {
		this.useTrayIcon = useTrayIcon;
	}

	public boolean isExecuteOnKeyReleased() {
		return executeOnKeyReleased;
	}

	public void setExecuteOnKeyReleased(boolean executeOnKeyReleased) {
		this.executeOnKeyReleased = executeOnKeyReleased;
	}

	public Level getNativeHookDebugLevel() {
		return nativeHookDebugLevel;
	}

	public void setNativeHookDebugLevel(Level nativeHookDebugLevel) {
		this.nativeHookDebugLevel = nativeHookDebugLevel;
	}

	protected MainBackEndHolder getBackEnd() {
		return backEnd;
	}

	public boolean isEnabledHaltingKeyPressed() {
		return enabledHaltingKeyPressed;
	}

	public void setEnabledHaltingKeyPressed(boolean enabledHaltingKeyPressed) {
		this.enabledHaltingKeyPressed = enabledHaltingKeyPressed;
	}

	@Override
	public Logger getLogger() {
		return Logger.getLogger(Config.class.getName());
	}
}


text:
import os

import neat

def test_nonexistent_config():
    """Check that attempting to open a non-existent config file raises
    an Exception with appropriate message."""
    passed = False
    try:
        c = neat.Config(neat.DefaultGenome, neat.DefaultReproduction,
                        neat.DefaultSpeciesSet, neat.DefaultStagnation,
                        'wubba-lubba-dub-dub')
    except Exception as e:
        passed = 'No such config file' in str(e)
    assert passed

def test_bad_config_default_activation():
    """Check that an activation function default not in the list of options
    raises an Exception with the appropriate message."""
    test_bad_config_RuntimeError(config_file='bad_configuration0')

def test_bad_config_unknown_option():
    """Check that an unknown option (at least in some sections) raises an exception."""
    local_dir = os.path.dirname(__file__)
    config_path = os.path.join(local_dir, 'bad_configuration2')
    try:
        config = neat.Config(neat.DefaultGenome, neat.DefaultReproduction,
                             neat.DefaultSpeciesSet, neat.DefaultStagnation,
                             config_path)
    except NameError:
        pass
    else:
        raise Exception("Did not get a NameError from an unknown configuration file option (in the 'DefaultSpeciesSet' section)")
    config3_path = os.path.join(local_dir, 'bad_configuration3')
    try:
        config = neat.Config(neat.DefaultGenome, neat.DefaultReproduction,
                             neat.DefaultSpeciesSet, neat.DefaultStagnation,
                             config3_path)
    except NameError:
        pass
    else:
        raise Exception("Did not get a NameError from an unknown configuration file option (in the 'NEAT' section)")

def test_bad_config_RuntimeError(config_file='bad_configuration4'):
    """Test for RuntimeError with a bad configuration file."""
    local_dir = os.path.dirname(__file__)
    config_path = os.path.join(local_dir, config_file)
    try:
        config = neat.Config(neat.DefaultGenome, neat.DefaultReproduction,
                             neat.DefaultSpeciesSet, neat.DefaultStagnation,
                             config_path)
    except RuntimeError:
        pass
    else:
        raise Exception(
            "Should have had a RuntimeError with {!s}".format(config_file))

def test_bad_config5():
    """Test using bad_configuration5 for a RuntimeError."""
    test_bad_config_RuntimeError(config_file='bad_configuration5')

def test_bad_config6():
    """Test using bad_configuration6 for a RuntimeError."""
    test_bad_config_RuntimeError(config_file='bad_configuration6')

def test_bad_config7():
    """Test using bad_configuration7 for a RuntimeError."""
    test_bad_config_RuntimeError(config_file='bad_configuration7')

def test_bad_config8():
    """Test using bad_configuration8 for a RuntimeError."""
    test_bad_config_RuntimeError(config_file='bad_configuration8')

def test_bad_config9():
    """Test using bad_configuration9 for a RuntimeError."""
    test_bad_config_RuntimeError(config_file='bad_configuration9')

if __name__ == '__main__':
    test_nonexistent_config()
    # test_bad_config_activation()
    test_bad_config_unknown_option()
    test_bad_config_RuntimeError()
    test_bad_config5()
    test_bad_config6()
    test_bad_config7()
    test_bad_config8()
    test_bad_config9()


text:
<?php
/**
 * Sample_Banlist
 *
 * Short sample loader to display Banlist library usage.
 *
 * @package	sample
 * @require	false
 * @author	ArvYStaTe.net Team
 **/

class Sample_Banlist extends EmotionLoader
{
	protected function CustomLoad ()
	{
		//
		// Construct banned IP addresses (white list)
		//

		$bannedIp[0] = '*.*.*.*';
		$bannedIp[1] = '123.4.*.* e';
		$bannedIp[2] = '127.0.0.1 e';

		// Print IP
		echo ('Your IP Address: ' . $this->Load ('Session')->IpAddress () . '
');

		//
		// Checking ban list
		//

		if ($this->Load ('Banlist')->CheckBanList ($bannedIp, $this->Load ('Session')->IpAddress ()) === true)
		{
			//
			// Deny access or redirect user
			//

			echo ('You are banned. I need you to go away.
');
		}
		else
		{
			echo ('You have an exception. You must be the miracle worker.
');
		}

		unset ($bannedIp);

		//
		// Construct banned IP addresses (black list)
		//

		$bannedIp[0] = '155.5.*.*';
		$bannedIp[1] = '155.5.5.* e';

		// Checking ban list again
		if ($this->Load ('Banlist')->CheckBanList ($bannedIp, $this->Load ('Session')->IpAddress ()) === true)
		{
			echo ('You are banned. I need you to go away second time...
');
		}
		else
		{
			echo ('You have ANOTHER exception. You will be truly worshipped.
');
		}
	}
}
?>


text:
# ************************************************************
# Sequel Pro SQL dump
# Version 4499
#
# http://www.sequelpro.com/
# https://github.com/sequelpro/sequelpro
# ************************************************************

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

# Dump of table comment
# ------------------------------------------------------------

DROP TABLE IF EXISTS `comment`;

CREATE TABLE `comment` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `commenter` int(11) unsigned NOT NULL DEFAULT '0',
  `comment_body` int(11) unsigned NOT NULL DEFAULT '0',
  `comment_location` int(11) unsigned NOT NULL DEFAULT '0',
  `reply_to` int(11) unsigned NOT NULL DEFAULT '0',
  `comment_request` int(11) DEFAULT '0',
  `url` varchar(255) NOT NULL DEFAULT '',
  `notify` tinyint(1) NOT NULL DEFAULT '0',
  `display` tinyint(1) NOT NULL DEFAULT '0',
  `is_deleted` tinyint(1) NOT NULL DEFAULT '0',
  `create_time` datetime NOT NULL,
  `update_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

# Dump of table comment_body
# ------------------------------------------------------------

DROP TABLE IF EXISTS `comment_body`;

CREATE TABLE `comment_body` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `body` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

# Dump of table comment_domain
# ------------------------------------------------------------

DROP TABLE IF EXISTS `comment_domain`;

CREATE TABLE `comment_domain` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `domain` varchar(100) NOT NULL DEFAULT '',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

# Dump of table comment_location
# ------------------------------------------------------------

DROP TABLE IF EXISTS `comment_location`;

CREATE TABLE `comment_location` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `domain` int(11) unsigned NOT NULL,
  `path` int(11) unsigned DEFAULT NULL,
  `thread` int(11) unsigned DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

# Dump of table comment_path
# ------------------------------------------------------------

DROP TABLE IF EXISTS `comment_path`;

CREATE TABLE `comment_path` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `path` varchar(255) NOT NULL DEFAULT '',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

# Dump of table comment_request
# ------------------------------------------------------------

DROP TABLE IF EXISTS `comment_request`;

CREATE TABLE `comment_request` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `ip_address` binary(16) NOT NULL DEFAULT '\\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0',
  `user_agent` text NOT NULL,
  `referrer` text,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

# Dump of table comment_thread
# ------------------------------------------------------------

DROP TABLE IF EXISTS `comment_thread`;

CREATE TABLE `comment_thread` (
  `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
  `thread` varchar(100) NOT NULL DEFAULT '',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

# Dump of table commenter
# ------------------------------------------------------------

DROP TABLE IF EXISTS `commenter`;

CREATE TABLE `commenter` (
  `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(100) NOT NULL DEFAULT '',
  `email` varchar(100) NOT NULL DEFAULT '',
  `website` varchar(100) DEFAULT NULL,
  `key` char(10) NOT NULL DEFAULT '',
  `is_trusted` tinyint(1) unsigned NOT NULL DEFAULT '0',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;


text:
package org.jboss.fuse.docker.container;

import com.google.gson.annotations.SerializedName;

import java.util.Arrays;
import java.util.Map;

public class ContainerConfig {

    public static class Builder {
        private String hostname;
        private String user;
        private long memory;
        private long memorySwap;
        private boolean attachStdin;
        private boolean attachStdout;
        private boolean attachStderr;
        private String portSpecs;
        private boolean priviledged;
        private String tty;
        private boolean openStdin;
        private boolean stdinOnce;
        private String evn;
        private String[] cmd;
        private String dns;
        private String image;
        private Map<String, String> volumes;
        private String volumesFrom;
        private String workingDir;

        public Builder hostname(final String hostname) {
            this.hostname = hostname;
            return this;
        }

        public Builder user(final String user) {
            this.user = user;
            return this;
        }

        public Builder memory(final long memory) {
            this.memory = memory;
            return this;
        }

        public Builder memorySwap(final long memorySwap) {
            this.memorySwap = memorySwap;
            return this;
        }

        public Builder attachStdin() {
            this.attachStdin = true;
            return this;
        }

        public Builder attachStdin(final boolean attachStdin) {
            this.attachStdin = attachStdin;
            return this;
        }

        public Builder attachStdout() {
            this.attachStdout = true;
            return this;
        }

        public Builder attachStdout(final boolean attachStdout) {
            this.attachStdout = attachStdout;
            return this;
        }

        public Builder attachStderr() {
            this.attachStderr = true;
            return this;
        }

        public Builder attachStderr(final boolean attachStderr) {
            this.attachStderr = attachStderr;
            return this;
        }

        public Builder portSpecs(final String portSpecs) {
            this.portSpecs = portSpecs;
            return this;
        }

        public Builder priviledged() {
            this.priviledged = true;
            return this;
        }

        public Builder priviledged(final boolean priviledged) {
            this.priviledged = priviledged;
            return this;
        }

        public Builder tty(final String tty) {
            this.tty = tty;
            return this;
        }

        public Builder openStdin() {
            this.openStdin = true;
            return this;
        }

        public Builder openStdin(final boolean openStdin) {
            this.openStdin = openStdin;
            return this;
        }

        public Builder stdinOnce() {
            this.stdinOnce = true;
            return this;
        }

        public Builder stdinOnce(final boolean stdinOnce) {
            this.stdinOnce = stdinOnce;
            return this;
        }

        public Builder evn(final String evn) {
            this.evn = evn;
            return this;
        }

        public Builder cmd(final String[] cmd) {
            this.cmd = cmd;
            return this;
        }

        public Builder dns(final String dns) {
            this.dns = dns;
            return this;
        }

        public Builder image(final String image) {
            this.image = image;
            return this;
        }

        public Builder volumes(final Map<String, String> volumes) {
            this.volumes = volumes;
            return this;
        }

        public Builder volumesFrom(final String volumesFrom) {
            this.volumesFrom = volumesFrom;
            return this;
        }

        public Builder workingDir(final String workingDir) {
            this.workingDir = workingDir;
            return this;
        }

        public ContainerConfig build() {
            return new ContainerConfig(hostname, user, memory, memorySwap, attachStdin, attachStdout,attachStderr,portSpecs,priviledged,tty,openStdin,stdinOnce,evn,cmd,dns,image,volumes,volumesFrom, workingDir);
        }

    }

    @SerializedName("Hosntame")
    private final String hostname;
    @SerializedName("User")
    private final String user;
    @SerializedName("Memory")
    private final long memory;
    @SerializedName("MemorySwap")
    private final long memorySwap;
    @SerializedName("AttachStdin")
    private final boolean attachStdin;
    @SerializedName("AttachStdout")
    private final boolean attachStdout;
    @SerializedName("AttachStderr")
    private final boolean attachStderr;
    @SerializedName("PortSpecs")
    private final String portSpecs;
    @SerializedName("Priviledged")
    private final boolean priviledged;
    @SerializedName("Ttty")
    private final String tty;
    @SerializedName("OpenStdin")
    private final boolean openStdin;
    @SerializedName("StdinOnce")
    private final boolean stdinOnce;
    @SerializedName("Env")
    private final String evn;
    @SerializedName("Cmd")
    private final String[] cmd;
    @SerializedName("Dns")
    private final String dns;
    @SerializedName("Image")
    private final String image;
    @SerializedName("Volumes")
    private final Map<String, String> volumes;
    @SerializedName("VolumesFrom")
    private final String volumesFrom;
    @SerializedName("WorkingDir")
    private final String workingDir;

    public static Builder builder() {
        return new Builder();
    }

    public ContainerConfig(String hostname, String user, long memory, long memorySwap, boolean attachStdin, boolean attachStdout, boolean attachStderr, String portSpecs, boolean priviledged, String tty, boolean openStdin, boolean stdinOnce, String evn, String[] cmd, String dns, String image, Map<String, String> volumes, String volumesFrom, String workingDir) {
        this.hostname = hostname;
        this.user = user;
        this.memory = memory;
        this.memorySwap = memorySwap;
        this.attachStdin = attachStdin;
        this.attachStdout = attachStdout;
        this.attachStderr = attachStderr;
        this.portSpecs = portSpecs;
        this.priviledged = priviledged;
        this.tty = tty;
        this.openStdin = openStdin;
        this.stdinOnce = stdinOnce;
        this.evn = evn;
        this.cmd = cmd;
        this.dns = dns;
        this.image = image;
        this.volumes = volumes;
        this.volumesFrom = volumesFrom;
        this.workingDir = workingDir;
    }

    public String getHostname() {
        return hostname;
    }

    public String getUser() {
        return user;
    }

    public long getMemory() {
        return memory;
    }

    public long getMemorySwap() {
        return memorySwap;
    }

    public boolean isAttachStdin() {
        return attachStdin;
    }

    public boolean isAttachStdout() {
        return attachStdout;
    }

    public boolean isAttachStderr() {
        return attachStderr;
    }

    public String getPortSpecs() {
        return portSpecs;
    }

    public boolean isPriviledged() {
        return priviledged;
    }

    public String getTty() {
        return tty;
    }

    public boolean isOpenStdin() {
        return openStdin;
    }

    public boolean isStdinOnce() {
        return stdinOnce;
    }

    public String getEvn() {
        return evn;
    }

    public String[] getCmd() {
        return cmd;
    }

    public String getDns() {
        return dns;
    }

    public String getImage() {
        return image;
    }

    public Map<String, String> getVolumes() {
        return volumes;
    }

    public String getVolumesFrom() {
        return volumesFrom;
    }

    public String getWorkingDir() {
        return workingDir;
    }

    @Override
    public String toString() {
        return "ContainerConfig{" +
                "hostname='" + hostname + '\'' +
                ", user='" + user + '\'' +
                ", memory=" + memory +
                ", memorySwap=" + memorySwap +
                ", attachStdin=" + attachStdin +
                ", attachStdout=" + attachStdout +
                ", attachStderr=" + attachStderr +
                ", portSpecs='" + portSpecs + '\'' +
                ", priviledged=" + priviledged +
                ", tty='" + tty + '\'' +
                ", openStdin=" + openStdin +
                ", stdinOnce=" + stdinOnce +
                ", evn='" + evn + '\'' +
                ", cmd=" + Arrays.toString(cmd) +
                ", dns='" + dns + '\'' +
                ", image='" + image + '\'' +
                ", volumes=" + volumes +
                ", volumesFrom='" + volumesFrom + '\'' +
                ", workingDir='" + workingDir + '\'' +
                '}';
    }
}


text:
<?php

namespace Phapi\Tests\Endpoint\Asset;

use Phapi\Endpoint;

class Blog extends Endpoint
{

    /**
     * @apiUri /blog/12
     * @apiDescription Retrieve the blogs information like
     *                 id, name and description
     * @apiParams id int
     * @apiResponse id int Blog ID
     * @apiResponse name string The name of the blog
     * @apiResponse description string A description of the blog
     * @apiResponse links string
     *              A list of links
     */
    public function get()
    {
        return [
            'id' => 12,
            'name' => 'Dev blog'
        ];
    }

    /**
     * Change response to null to test exception
     */
    public function changeResponse()
    {
        $this->response = null;
    }
}


text:
/* -*- mode: c++; fill-column: 132; c-basic-offset: 4; indent-tabs-mode: nil -*- */

/*** Copyright (c), The Regents of the University of California            ***
 *** For more information please refer to files in the COPYRIGHT directory ***/
/* See dataObjPhymv.h for a description of this API call.*/

#include "dataObjPhymv.hpp"
#include "dataObjRepl.hpp"
#include "dataObjOpr.hpp"
#include "rodsLog.hpp"
#include "objMetaOpr.hpp"
#include "specColl.hpp"
#include "reGlobalsExtern.hpp"
#include "reDefines.hpp"
#include "reSysDataObjOpr.hpp"
#include "dataObjCreate.hpp"
#include "getRemoteZoneResc.hpp"

// =-=-=-=-=-=-=-
#include "irods_resource_redirect.hpp"

int
rsDataObjPhymv250( rsComm_t *rsComm, dataObjInp_t *dataObjInp,
                   transStat_t **transStat ) {
    int status;
    transferStat_t *transferStat = NULL;

    status = rsDataObjPhymv( rsComm, dataObjInp, &transferStat );

    if ( transStat != NULL && status >= 0 && transferStat != NULL ) {
        *transStat = ( transStat_t * ) malloc( sizeof( transStat_t ) );
        ( *transStat )->numThreads = transferStat->numThreads;
        ( *transStat )->bytesWritten = transferStat->bytesWritten;
        free( transferStat );
    }
    return status;
}

/* rsDataObjPhymv - The Api handler of the rcDataObjPhymv call - phymove
 * a data object from one resource to another.
 * Input -
 *    rsComm_t *rsComm
 *    dataObjInp_t *dataObjInp - The replication input
 *    transferStat_t **transStat - transfer stat output
 */

int
rsDataObjPhymv( rsComm_t *rsComm, dataObjInp_t *dataObjInp,
                transferStat_t **transStat ) {
    int status;
    dataObjInfo_t *dataObjInfoHead = NULL;
    dataObjInfo_t *oldDataObjInfoHead = NULL;
    rescGrpInfo_t *myRescGrpInfo = NULL;
    ruleExecInfo_t rei;
    int multiCopyFlag;
    char *accessPerm;
    int remoteFlag;
    rodsServerHost_t *rodsServerHost;
    specCollCache_t *specCollCache = NULL;

    resolveLinkedPath( rsComm, dataObjInp->objPath, &specCollCache,
                       &dataObjInp->condInput );
    remoteFlag = getAndConnRemoteZone( rsComm, dataObjInp, &rodsServerHost,
                                       REMOTE_OPEN );

    if ( remoteFlag < 0 ) {
        return ( remoteFlag );
    }
    else if ( remoteFlag == REMOTE_HOST ) {
        status = _rcDataObjPhymv( rodsServerHost->conn, dataObjInp,
                                  transStat );
        return status;
    }

    // =-=-=-=-=-=-=-
    // determine hierarchy string
    if ( getValByKey( &dataObjInp->condInput, RESC_HIER_STR_KW ) == NULL ) {
        std::string       hier;
        irods::error ret = irods::resolve_resource_hierarchy( irods::OPEN_OPERATION, rsComm,
                           dataObjInp, hier );
        if ( !ret.ok() ) {
            std::stringstream msg;
            msg << __FUNCTION__;
            msg << " :: failed in irods::resolve_resource_hierarchy for [";
            msg << dataObjInp->objPath << "]";
            irods::log( PASSMSG( msg.str(), ret ) );
            return ret.code();
        }

        // =-=-=-=-=-=-=-
        // we resolved the redirect and have a host, set the hier str for subsequent
        // api calls, etc.
        addKeyVal( &dataObjInp->condInput, RESC_HIER_STR_KW, hier.c_str() );

    } // if keyword

    *transStat = ( transferStat_t* )malloc( sizeof( transferStat_t ) );
    memset( *transStat, 0, sizeof( transferStat_t ) );

    if ( getValByKey( &dataObjInp->condInput, ADMIN_KW ) != NULL ) {
        if ( rsComm->clientUser.authInfo.authFlag < LOCAL_PRIV_USER_AUTH ) {
            return ( CAT_INSUFFICIENT_PRIVILEGE_LEVEL );
        }
        accessPerm = NULL;
    }
    else {
        accessPerm = ACCESS_DELETE_OBJECT;
    }

    /* query rcat for resource info and sort it */
    status = getRescGrpForCreate( rsComm, dataObjInp, &myRescGrpInfo );
    if ( status < 0 ) {
        return status;
    }

    initReiWithDataObjInp( &rei, rsComm, dataObjInp );
    status = applyRule( "acSetMultiReplPerResc", NULL, &rei, NO_SAVE_REI );
    if ( strcmp( rei.statusStr, MULTI_COPIES_PER_RESC ) == 0 ) {
        multiCopyFlag = 1;
    }
    else {
        multiCopyFlag = 0;
    }

    /* query rcat for dataObjInfo and sort it */
    status = getDataObjInfo( rsComm, dataObjInp, &dataObjInfoHead,
                             accessPerm, 1 );

    if ( status < 0 ) {
        rodsLog( LOG_NOTICE,
                 "rsDataObjPhymv: getDataObjInfo for %s", dataObjInp->objPath );
        return ( status );
    }

    status = resolveInfoForPhymv( &dataObjInfoHead, &oldDataObjInfoHead, &myRescGrpInfo, &dataObjInp->condInput, multiCopyFlag );

    if ( status < 0 ) {
        freeAllDataObjInfo( dataObjInfoHead );
        freeAllDataObjInfo( oldDataObjInfoHead );
        freeAllRescGrpInfo( myRescGrpInfo );
        if ( status == CAT_NO_ROWS_FOUND ) {
            return ( 0 );
        }
        else {
            return ( status );
        }
    }

    status = _rsDataObjPhymv( rsComm, dataObjInp, dataObjInfoHead,
                              myRescGrpInfo, *transStat, multiCopyFlag );

    freeAllDataObjInfo( dataObjInfoHead );
    freeAllDataObjInfo( oldDataObjInfoHead );
    freeAllRescGrpInfo( myRescGrpInfo );

    return ( status );
}

int
_rsDataObjPhymv( rsComm_t *rsComm, dataObjInp_t *dataObjInp,
                 dataObjInfo_t *srcDataObjInfoHead, rescGrpInfo_t *destRescGrpInfo,
                 transferStat_t *transStat, int multiCopyFlag ) {
    dataObjInfo_t *srcDataObjInfo;
    rescGrpInfo_t *tmpRescGrpInfo;
    rescInfo_t *tmpRescInfo;
    int status = 0;
    int savedStatus = 0;

    tmpRescGrpInfo = destRescGrpInfo;
    srcDataObjInfo = srcDataObjInfoHead;
    while ( tmpRescGrpInfo != NULL ) {
        tmpRescInfo = tmpRescGrpInfo->rescInfo;
        while ( srcDataObjInfo != NULL ) {
            /* use _rsDataObjReplS for the phymv */
            dataObjInp->oprType = PHYMV_OPR;    /* should be set already */
            status = _rsDataObjReplS( rsComm, dataObjInp, srcDataObjInfo,
                                      tmpRescInfo, tmpRescGrpInfo->rescGroupName, NULL, 0 );

            if ( multiCopyFlag == 0 ) {
                if ( status >= 0 ) {
                    srcDataObjInfo = srcDataObjInfo->next;
                }
                else {
                    savedStatus = status;
                }
                /* use another resc */
                break;
            }
            else {
                if ( status < 0 ) {
                    savedStatus = status;
                    /* use another resc */
                    break;
                }
            }
            srcDataObjInfo = srcDataObjInfo->next;
        }
        if ( status >= 0 ) {
            transStat->numThreads = dataObjInp->numThreads;
        }
        tmpRescGrpInfo = tmpRescGrpInfo->next;
    }

    if ( srcDataObjInfo != NULL ) {
        /* not everything got moved */
        if ( savedStatus == 0 ) {
            status = SYS_COPY_ALREADY_IN_RESC;
        }
    }
    else {
        savedStatus = 0;
    }

    return ( savedStatus );
}


text:
<?php

namespace Mitul\Generator\Commands;

use Mitul\Generator\CommandData;
use Mitul\Generator\Generators\Common\MigrationGenerator;
use Mitul\Generator\Generators\Common\ModelGenerator;
use Mitul\Generator\Generators\Common\PresenterGenerator;
use Mitul\Generator\Generators\Common\APIPresenterGenerator;
use Mitul\Generator\Generators\Common\TransformerGenerator;
use Mitul\Generator\Generators\Common\RepositoryGenerator;
use Mitul\Generator\Generators\Common\IRepositoryGenerator;
use Mitul\Generator\Generators\Common\AppBindGenerator;
use Mitul\Generator\Generators\Common\RequestGenerator;
use Mitul\Generator\Generators\Common\RoutesGenerator;
use Mitul\Generator\Generators\Scaffold\BreadcrumbsGenerator;
use Mitul\Generator\Generators\Scaffold\ViewControllerGenerator;
use Mitul\Generator\Generators\Scaffold\ViewGenerator;

class ScaffoldGeneratorCommand extends BaseCommand
{

	/**
	 * The console command name.
	 *
	 * @var string
	 */
	protected $name = 'mitul.generator:scaffold';

	/**
	 * The console command description.
	 *
	 * @var string
	 */
	protected $description = 'Create a full CRUD for given model with initial views';

	/**
	 * Create a new command instance.
	 *
	 */
	public function __construct()
	{
		parent::__construct();

		$this->commandData = new CommandData($this, CommandData::$COMMAND_TYPE_SCAFFOLD);
	}

	/**
	 * Execute the command.
	 *
	 * @return void
	 */
	public function handle()
	{
		parent::handle();

		if(!$this->commandData->skipMigration)
		{
			$migrationGenerator = new MigrationGenerator($this->commandData);
			$migrationGenerator->generate();
		}

		$modelGenerator = new ModelGenerator($this->commandData);
		$modelGenerator->generate();

		$presenterGenerator = new PresenterGenerator($this->commandData);
		$presenterGenerator->generate();

		$apipresenterGenerator = new APIPresenterGenerator($this->commandData);
		$apipresenterGenerator->generate();

		$transformerGenerator = new TransformerGenerator($this->commandData);
		$transformerGenerator->generate();

		$requestGenerator = new RequestGenerator($this->commandData);
		$requestGenerator->generate();

		$repositoryGenerator = new RepositoryGenerator($this->commandData);
		$repositoryGenerator->generate();

		$irepositoryGenerator = new IRepositoryGenerator($this->commandData);
		$irepositoryGenerator->generate();

		$appBindGenerator = new AppBindGenerator($this->commandData);
		$appBindGenerator->generate();

		$repoControllerGenerator = new ViewControllerGenerator($this->commandData);
		$repoControllerGenerator->generate();

		$viewsGenerator = new ViewGenerator($this->commandData);
		$viewsGenerator->generate();

		$routeGenerator = new RoutesGenerator($this->commandData);
		$routeGenerator->generate();

		if($this->commandData->breadcrumbs)
		{
			$breadcrumbsGenerator = new BreadcrumbsGenerator($this->commandData);
			$breadcrumbsGenerator->generate();
		}

		if($this->confirm("\nDo you want to migrate database? [y|N]", false))
			$this->call('migrate');
	}

	/**
	 * Get the console command arguments.
	 *
	 * @return array
	 */
	protected function getArguments()
	{
		return array_merge(parent::getArguments());
	}

	/**
	 * Get the console command options.
	 *
	 * @return array
	 */
	public function getOptions()
	{
		return array_merge(parent::getOptions(), []);
	}
}


text:
.. _how-to-contribute:

How to Contribute
=================

We would love to have you contribute to the project! There are several
ways that you can do so.

How to contribute without coding
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

* **Community** - Post your projects, code, screen-shots, and discuss the Arcade library on the `Python Arcade SubReddit`_.
* Try coding your own animations and games. Write down notes on anything that
  is difficult to implement or understand about the library.
* **Suggest improvements** - Post bugs and enhancement requests at the `Github Issue List`_.

How to contribute code
^^^^^^^^^^^^^^^^^^^^^^

First, take some time to understand the project layout:

* :ref:`directory-structure`
* :ref:`how-to-compile`
* :ref:`how-to-submit-changes`

Then you can improve these parts of the project:

* **Document** - Edit the reStructuredText_ and docstrings_ to make the Arcade
  documentation better.
* **Test** - Improve the unit testing.
* **Code** - Contribute bug fixes and enhancements to the code.

.. _Python Arcade SubReddit: https://www.reddit.com/r/pythonarcade
.. _Github Issue List: https://github.com/pvcraven/arcade/issues
.. _reStructuredText: http://www.sphinx-doc.org/en/stable/rest.html
.. _docstrings: http://www.pythonforbeginners.com/basics/python-docstrings


text:
<?php

use deluxcms\media\assets\ModalAsset;

ModalAsset::register($this);
?>

<div role="media-modal" class="modal" tabindex="-1" style="z-index:9999999"
data-frame-src="<?= $url ?>"
data-frame-id="<?= $id ?>">


text:
<?php

namespace Google\Service\Firebaseappcheck;

class GoogleFirebaseAppcheckV1betaPublicJwkSet extends \Google\Collection
{
  protected $collection_key = 'keys';
  protected $keysType = GoogleFirebaseAppcheckV1betaPublicJwk::class;
  protected $keysDataType = 'array';

  /**
   * @param GoogleFirebaseAppcheckV1betaPublicJwk[]
   */
  public function setKeys($keys)
  {
    $this->keys = $keys;
  }
  /**
   * @return GoogleFirebaseAppcheckV1betaPublicJwk[]
   */
  public function getKeys()
  {
    return $this->keys;
  }
}

// Adding a class alias for backwards compatibility with the previous class name.
class_alias(GoogleFirebaseAppcheckV1betaPublicJwkSet::class, 'Google_Service_Firebaseappcheck_GoogleFirebaseAppcheckV1betaPublicJwkSet');


text:
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ExomeSeqAnalysisPipe.clusterFeatureGenerated;

import ExomeSeqAnalysisPipe.FilelistReader;
import ExomeSeqAnalysisPipe.VCFrecord;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileWriter;
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.TimeUnit;
import java.util.logging.Level;
import java.util.logging.Logger;
import pub.Tools;
import pub.txtReader;

/**
 *
 * @author ZHAO Qi
 * @date 2014-2-28 16:04:34
 * @version 1.6.0
 */
public class FeatureGeneraterFinal {

    private final HashMap<String, LinkedList<VCFrecord>> getSampleVcfMap;
    public final HashMap<String, FAIterm> Chrom2FAImap;
    public final int BIN;
    public int TREAD_NUM=Tools.thread;
    public File outfile;
    public ArrayList<String> outlist = new ArrayList<String>();
    public final HashMap index2sampleMap;

//    public FeatureGeneraterFinal(String filedir, String faifile,int bin,int TreadNum) {
//        this.getSampleVcfMap = FilelistReader.getSampleVcfMap(filedir);
//        this.Chrom2FAImap = new FAItermReader(faifile).getChrom2FAImap();
//        System.out.println("initialized finished!");
//        this.BIN=bin;
//        this.TREAD_NUM=TreadNum;
//        this.FGmutiProcess();
//    }
    public FeatureGeneraterFinal(String filedir, String faifile, String mapfile, int bin, int TreadNum) throws FileNotFoundException, IOException {
        this.index2sampleMap = txtReader.getMap(mapfile);
        System.out.println(index2sampleMap.size());
        this.getSampleVcfMap = FilelistReader.getSampleVcfMap(filedir);
        this.Chrom2FAImap = new FAItermReader(faifile).getChrom2FAImap();
        System.out.println("initialized finished!");
        this.BIN = bin;
        this.TREAD_NUM = TreadNum;
        this.FGmutiProcess();
    }

    public void FGmutiProcess() {
        ExecutorService pool = Executors.newFixedThreadPool(TREAD_NUM);//creat a new thread pool
        for (Iterator it = getSampleVcfMap.keySet().iterator(); it.hasNext();) {
            String vcffilepath = (String) it.next();

            FeatureGeneraterThread singleFileCalculatorThread = new FeatureGeneraterThread(vcffilepath, this);
            pool.submit(singleFileCalculatorThread);
        }
        pool.shutdown();
        // wait for termination
        try {
            pool.awaitTermination(Long.MAX_VALUE, TimeUnit.DAYS);
        } catch (InterruptedException ex) {
        }

    }

    public void print(String outfile) {
        {
            FileWriter fw = null;
            try {
                fw = new FileWriter(outfile);
                for (int i = 0; i < this.outlist.size(); i++) {
                    String s = outlist.get(i);

                    fw.append(s);
                }
                fw.flush();
                fw.close();

            } catch (IOException ex) {
                Logger.getLogger(FeatureGeneraterFinal.class.getName()).log(Level.SEVERE, null, ex);
            }
        }

    }

    public static void main(String[] args) throws IOException {
        //new FeatureGeneraterFinal(args[0],args[1],Integer.parseInt(args[2]),Integer.parseInt(args[3])).print(args[4]);
        new FeatureGeneraterFinal("F:\\mywork\\project\\Peng\\snpsatustFinal\\1", "F:\\mywork\\project\\Peng\\ecoli.fa.fai", "F:\\mywork\\project\\Peng\\samplemapping.txt", 1000, 5).print("F:\\mywork\\project\\Peng\\snpstatfinal1.result");
    }
}


text:
class AddNotesToFlora < ActiveRecord::Migration[4.2]
  def change
    add_column :floras, :notes, :string
    add_column :floras, :private_notes, :string
  end
end


text:
package org.mlbdash.shared.gdx.masterscore;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

import name.pehl.piriti.commons.client.Format;
import name.pehl.piriti.commons.client.Path;

@SuppressWarnings("serial")
public class MasterScoreboard implements Serializable {

    @Path("@year") short year;
    @Path("@month") short month;
    @Path("@day") short day;
    @Path("@modified_date") @Format("yyyy-MM-dd'T'HH:mm:ss'Z'") Date modifiedDate;
    @Path("@next_day_date") @Format("yyyy-MM-dd") Date nextDayDate;
    @Path("game") List<Game> games;

    public short getYear() {
        return year;
    }

    public void setYear(short year) {
        this.year = year;
    }

    public short getMonth() {
        return month;
    }

    public void setMonth(short month) {
        this.month = month;
    }

    public short getDay() {
        return day;
    }

    public void setDay(short day) {
        this.day = day;
    }

    public Date getModifiedDate() {
        return modifiedDate;
    }

    public void setModifiedDate(Date modifiedDate) {
        this.modifiedDate = modifiedDate;
    }

    public Date getNextDayDate() {
        return nextDayDate;
    }

    public void setNextDayDate(Date nextDayDate) {
        this.nextDayDate = nextDayDate;
    }

    public List<Game> getGames() {
        return games;
    }

    public void setGames(List<Game> games) {
        this.games = games;
    }

}


text:
/**
 * PrimeUI checkbox widget
 */
 (function (factory) {
     if (typeof define === 'function' && define.amd) {
         // AMD. Register as an anonymous module.
         define(['jquery'], factory);
     } else if (typeof module === 'object' && module.exports) {
         // Node/CommonJS
         module.exports = function( root, jQuery ) {
             factory(jQuery);
             return jQuery;
         };
     } else {
         // Browser globals
         factory(jQuery);
     }
 }(function ($) {

    $.widget("primeui.puicheckbox", {

        _create: function() {
            this.element.wrap('

');
            this.container = this.element.parent().parent();
            this.box = $('
').appendTo(this.container);
            this.icon = $('').appendTo(this.box);
            this.disabled = this.element.prop('disabled');
            this.label = $('label[for="' + this.element.attr('id') + '"]');

            if(this.isChecked()) {
                this.box.addClass('ui-state-active');
                this.icon.addClass('fa fa-fw fa-check');
            }

            if(this.disabled) {
                this.box.addClass('ui-state-disabled');
            } else {
                this._bindEvents();
            }
        },

        _bindEvents: function() {
            var $this = this;

            this.box.on('mouseover.puicheckbox', function() {
                if(!$this.isChecked())
                    $this.box.addClass('ui-state-hover');
            })
            .on('mouseout.puicheckbox', function() {
                $this.box.removeClass('ui-state-hover');
            })
            .on('click.puicheckbox', function() {
                $this.toggle();
            });

            this.element.on('focus.puicheckbox', function() {
                if($this.isChecked()) {
                    $this.box.removeClass('ui-state-active');
                }

                $this.box.addClass('ui-state-focus');
            })
            .on('blur.puicheckbox', function() {
                if($this.isChecked()) {
                    $this.box.addClass('ui-state-active');
                }

                $this.box.removeClass('ui-state-focus');
            })
            .on('keydown.puicheckbox', function(e) {
                var keyCode = $.ui.keyCode;
                if(e.which == keyCode.SPACE) {
                    e.preventDefault();
                }
            })
            .on('keyup.puicheckbox', function(e) {
                var keyCode = $.ui.keyCode;
                if(e.which == keyCode.SPACE) {
                    $this.toggle(true);

                    e.preventDefault();
                }
            });

            this.label.on('click.puicheckbox', function(e) {
                $this.toggle();
                e.preventDefault();
            });
        },

        toggle: function(keypress) {
            if(this.isChecked()) {
                this.uncheck(keypress);
            } else {
                this.check(keypress);
            }

            this._trigger('change', null, this.isChecked());
        },

        isChecked: function() {
            return this.element.prop('checked');
        },

        check: function(activate, silent) {
            if(!this.isChecked()) {
                this.element.prop('checked', true);
                this.icon.addClass('fa fa-fw fa-check');

                if(!activate) {
                    this.box.addClass('ui-state-active');
                }

                if(!silent) {
                    this.element.trigger('change');
                }
            }
        },

        uncheck: function() {
            if(this.isChecked()) {
                this.element.prop('checked', false);
                this.box.removeClass('ui-state-active');
                this.icon.removeClass('fa fa-fw fa-check');

                this.element.trigger('change');
            }
        },

        _unbindEvents: function() {
            this.box.off('mouseover.puicheckbox mouseout.puicheckbox click.puicheckbox');
            this.element.off('focus.puicheckbox blur.puicheckbox keydown.puicheckbox keyup.puicheckbox');

            if (this.label.length) {
                this.label.off('click.puicheckbox');
            }
        },

        disable: function() {
            this.box.prop('disabled', true);
            this.box.attr('aria-disabled', true);
            this.box.addClass('ui-state-disabled').removeClass('ui-state-hover');
            this._unbindEvents();
        },

        enable: function() {
            this.box.prop('disabled', false);
            this.box.attr('aria-disabled', false);
            this.box.removeClass('ui-state-disabled');
            this._bindEvents();
        },

        _destroy: function() {
            this._unbindEvents();
            this.container.removeClass('ui-chkbox ui-widget');
            this.box.remove();
            this.element.unwrap().unwrap();
        }

    });

}));


text:
namespace Mapping.Commands
{
    using Services.Contracts;

    public class EmployeePersonalInfoCommand : Command
    {
        public EmployeePersonalInfoCommand(IEmployeeService employeeService)
            : base(employeeService)
        {
        }

        public override string Execute(params string[] tokens)
        {
            string result = this.CheckParamsCount(1, tokens);

            if (result == InvalidParams)
            {
                return result;
            }

            int emplId = int.Parse(tokens[0]);

            result = this.EmployeeService.EmployeeFullInfo(emplId);

            return result;
        }
    }
}