query stringlengths 7 33.1k | document stringlengths 7 335k | metadata dict | negatives listlengths 3 101 | negative_scores listlengths 3 101 | document_score stringlengths 3 10 | document_rank stringclasses 102 values |
|---|---|---|---|---|---|---|
Base interface for the network access. Covers access to all objects in the ECM system. Covers access to the authentication provider as well. NOTE: There is one instance of this class in each user session. To be implemented with the specific ECM system. Alfresco Workdesk Copyright (c) Alfresco Software, Inc. All rights reserved. For licensing information read the license.txt file or go to: | public interface OwNetwork<O extends OwObject> extends OwRepository<O>, OwAuthenticationProvider
{
// === Object types for application objects from the ECM Adapter, see method getApplicationObject(s)
/** object type for the virtual folders (Type: OwVirtualFolderObjectFactory)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#VIRTUAL_FOLDER}
* */
public static final int APPLICATION_OBJECT_TYPE_VIRTUAL_FOLDER = 1;
/** object type for the preferences, which can be user or application defined, like user settings, recent file list... (Type: OwObject)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#PREFERENCES}
* */
public static final int APPLICATION_OBJECT_TYPE_PREFERENCES = 2;
/** object type for the search templates (Type: OwSearchTemplate)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum}
* */
public static final int APPLICATION_OBJECT_TYPE_SEARCHTEMPLATE = 3;
/** object type for the XML streams (Type: org.w3c.dom.Node)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#XML_DOCUMENT}
* */
public static final int APPLICATION_OBJECT_TYPE_XML_DOCUMENT = 4;
/** object type for the attribute bags (Type: OwAttributeBag)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#ATTRIBUTE_BAG}
* */
public static final int APPLICATION_OBJECT_TYPE_ATTRIBUTE_BAG = 5;
/** object type for the attribute bags (Type: OwAttributeBagIterator)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#ATTRIBUTE_BAG_ITERATOR}
* */
public static final int APPLICATION_OBJECT_TYPE_ATTRIBUTE_BAG_ITERATOR = 6;
/** object type for the writable attribute bags like databases (Type: OwAttributeBagWritable)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#ATTRIBUTE_BAG_WRITABLE}
* */
public static final int APPLICATION_OBJECT_TYPE_ATTRIBUTE_BAG_WRITABLE = 7;
/** object type for the enum collections for choicelists (Type: OwEnumCollection)
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#ENUM_COLLECTION}
* */
public static final int APPLICATION_OBJECT_TYPE_ENUM_COLLECTION = 8;
/** object type for the read only attribute bags like databases (Type: OwAttributeBagWritable), i.e.: the attributenames of the bag represent the users
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#INVERTED_ATTRIBUTE_BAG}
* */
public static final int APPLICATION_OBJECT_TYPE_INVERTED_ATTRIBUTE_BAG = 9;
/** object type representing an entry template
* @since 3.2.0.0
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#ENTRY_TEMPLATE}
* */
public static final int APPLICATION_OBJECT_TYPE_ENTRY_TEMPLATE = 10;
/** user defined object types start here
* @deprecated since 4.2.0.0 use {@link OwAOTypesEnum#USER_START}
* */
public static final int APPLICATION_OBJECT_TYPE_USER_START = 0x1000;
// === extensible function code types for the canDo function
/** function code used in canDo(...) method to check if user can print the given object */
public static final int CAN_DO_FUNCTIONCODE_PRINT = 0x0001;
/** function code used in canDo(...) method to check if user can create annotations */
public static final int CAN_DO_FUNCTIONCODE_CREATE_ANNOTATION = 0x0002;
/** function code used in canDo(...) method to check if user can edit annotations */
public static final int CAN_DO_FUNCTIONCODE_EDIT_ANNOTATION = 0x0003;
/** function code used in canDo(...) method to check if user can delete annotations */
public static final int CAN_DO_FUNCTIONCODE_DELETE_ANNOTATION = 0x0004;
/** function code used in canDo(...) method to check if user can save the content to disk */
public static final int CAN_DO_FUNCTIONCODE_SAVE_CONTENT_TO_DISK = 0x0005;
/** function code used in canDo(...) method to check if user has the ACL to modify annotations, @since 3.2.0.1 */
public static final int CAN_DO_FUNCTIONCODE_ACL_TO_MODIFY_ANNOTATION = 0x0006;
/** user defined function codes start here */
public static final int CAN_DO_FUNCTIONCODE_USER_START = 0x1000;
// === custom dispatcher functions to extend the functionality for special usage like sending fax
/** get an additional interface, e.g. interface to a workflow engine, implements a service locator
*
* @param strInterfaceName_p Name of the interface
* @param oObject_p optional object to be wrapped
*
* @return a reference to the interface
*/
public abstract Object getInterface(String strInterfaceName_p, Object oObject_p) throws Exception;
/** check if an additional interface is available, e.g. interface to a workflow engine
* @param strInterfaceName_p Name of the interface
* @return true, if interface is available
*/
public abstract boolean hasInterface(String strInterfaceName_p);
/** get current locale */
public abstract java.util.Locale getLocale();
// === Initialization
/** initialize the network Adapter
*
* @param context_p OwNetworkContext
* @param networkSettings_p Settings DOM Node wrapped by OwXMLUtil
*/
public abstract void init(OwNetworkContext context_p, OwXMLUtil networkSettings_p) throws Exception;
/**
* return the network context that was past during initialization
* @return OwNetworkContext
* @since 3.1.0.0
*/
public OwNetworkContext getContext();
/** set the rolemanager to use
*
* @param roleManager_p OwRoleManager
*/
public abstract void setRoleManager(OwRoleManager roleManager_p);
/** set the rolemanager to use
*
* @param eventManager_p OwHistoryManager to write history to, only if ECM system does not write its own history
*/
public abstract void setEventManager(OwEventManager eventManager_p);
// === permission functions
/** get an instance of the edit access rights UI submodule for editing document access rights
* Access rights are very specific to the ECM System and can not be handled generically
* @param object_p OwObject to edit the access rights
*
* @return OwUIAccessRightsModul OwView derived module
*/
public abstract OwUIAccessRightsModul getEditAccessRightsSubModul(OwObject object_p) throws Exception;
/** check if access rights can be edited on the Object. I.e. if a AccessRightsSubModul can be obtained
*
* @param object_p OwObject to edit access rights for
*
* @return true if access rights can be edited
*/
public abstract boolean canEditAccessRights(OwObject object_p) throws Exception;
// === access to the site and user documents e.g. workflows, searchtemplates, preference settings
// It is up to the implementing ECM Adapter where the objects are stored, e.g. could also come from harddrive.
/** get a list of Objects for the application to work, like search templates, preferences...
* @param iTyp_p type as defined in OwNetwork.APPLICATION_OBJECT_TYPE_...
* @param strName_p Name of the object to retrieve e.g. "userprefs"
* @param fForceUserSpecificObject_p if true, the object must be specific to the logged in user, otherwise the ECM Adapter determines if it is common to a site or specific to a group or a user.
*
* @return Collection, which elements need to be cast to the appropriate type according to iTyp_p
* @deprecated since 4.2.0.0 use {@link OwAOProvider} for application object retrieval
*/
public abstract java.util.Collection getApplicationObjects(int iTyp_p, String strName_p, boolean fForceUserSpecificObject_p) throws Exception;
/** get a Objects for the application to work, like search templates, preferences...
*
* @param iTyp_p type as defined in OwNetwork.APPLICATION_OBJECT_TYPE_...
* @param strName_p Name of the object to retrieve e.g. "userprefs"
* @param param_p optional Object, can be null
* @param fForceUserSpecificObject_p if true, the object must be specific to the logged in user, otherwise the ECM Adapter determines if it is common to a site or specific to a group or a user.
* @param fCreateIfNotExist_p boolean true = create if not exist
*
* @return Object, which needs to be cast to the appropriate type according to iTyp_p
* @deprecated since 4.2.0.0 use {@link OwAOProvider} for application object retrieval
*/
public abstract Object getApplicationObject(int iTyp_p, String strName_p, Object param_p, boolean fForceUserSpecificObject_p, boolean fCreateIfNotExist_p) throws Exception;
/** get a Objects for the application to work, like search templates, preferences...
*
* @param iTyp_p type as defined in OwNetwork.APPLICATION_OBJECT_TYPE_...
* @param strName_p Name of the object to retrieve e.g. "userprefs"
* @param fForceUserSpecificObject_p if true, the object must be specific to the logged in user, otherwise the ECM Adapter determines if it is common to a site or specific to a group or a user.
* @param fCreateIfNotExist_p boolean true = create if not exist
*
*
*
* @return Object, which needs to be cast to the appropriate type according to iTyp_p
* @deprecated since 4.2.0.0 use {@link OwAOProvider} for application object retrieval
*/
public abstract Object getApplicationObject(int iTyp_p, String strName_p, boolean fForceUserSpecificObject_p, boolean fCreateIfNotExist_p) throws Exception;
/** creates a new object on the ECM System using the given parameters
*
* @param resource_p OwResource to add to
* @param strObjectClassName_p requested class name of the new object
* @param properties_p OwPropertyCollection with new properties to set, or null to use defaults
* @param permissions_p OwPermissionCollection ECM specific permissions or null to use defaults
* @param content_p OwContentCollection the new content to set, null to create an empty object
* @param parent_p OwObject the parent object to use as a container, e.g. a folder or a ECM root, can be null if no parent is required
* @param strMimeType_p String MIME Types of the new object content
* @param strMimeParameter_p extra info to the MIME type
*
* @return String the ECM ID of the new created object
*/
public abstract String createNewObject(OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p, OwObject parent_p, String strMimeType_p,
String strMimeParameter_p) throws Exception;
/** creates a new object on the ECM System using the given parameters
* has additional promote and checkin mode parameters for versionable objects
*
* @param fPromote_p boolean true = create a released version right away
* @param mode_p Object checkin mode for objects, see getCheckinModes, or null to use default
* @param resource_p OwResource to add to
* @param strObjectClassName_p requested class name of the new object
* @param properties_p OwPropertyCollection with new properties to set, or null to use defaults
* @param permissions_p OwPermissionCollection ECM specific permissions or null to use defaults
* @param content_p OwContentCollection the new content to set, null to create an empty object
* @param parent_p OwObject the parent object to use as a container, e.g. a folder or a ECM root, can be null if no parent is required
* @param strMimeType_p String MIME Types of the new object content
* @param strMimeParameter_p extra info to the MIME type
*
* @return String the ECM ID of the new created object
*/
public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,
OwObject parent_p, String strMimeType_p, String strMimeParameter_p) throws Exception;
/**
* Creates a new object on the ECM System using the given parameters.<br>
* Has additional promote and checkin mode parameters for versionable objects
* and the extra parameter fKeepCheckedOut_p to control whether the new
* objects are checked in automatically or not.<br />
* <p>
* <b>ATTENTION:</b> If keepCheckedOut is <code>true</code>, the promote flag (major/minor versioning) is ignored.
* </p>
* @param fPromote_p boolean true = create a released version right away
* @param mode_p Object checkin mode for objects, see getCheckinModes, or null to use default
* @param resource_p OwResource to add to
* @param strObjectClassName_p requested class name of the new object
* @param properties_p OwPropertyCollection with new properties to set, or null to use defaults
* @param permissions_p OwPermissionCollection ECM specific permissions or null to use defaults
* @param content_p OwContentCollection the new content to set, null to create an empty object
* @param parent_p OwObject the parent object to use as a container, e.g. a folder or a ECM root, can be null if no parent is required
* @param strMimeType_p String MIME Types of the new object content
* @param strMimeParameter_p extra info to the MIME type
* @param fKeepCheckedOut_p true = create a new object that is checked out
*
* @return String the ECM ID of the new created object
*
* @since 2.5.0
*/
public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,
OwObject parent_p, String strMimeType_p, String strMimeParameter_p, boolean fKeepCheckedOut_p) throws Exception;
/** check, if Adapter can create a new objects
*
* @param resource_p OwResource to add to
* @param parent_p OwObject the parent object to use as a container, e.g. a folder or a ECM root, can be null if no parent is required
* @param iContext_p int as defined in {@link OwStatusContextDefinitions}
* @return true, if object can be created
*/
public abstract boolean canCreateNewObject(OwResource resource_p, OwObject parent_p, int iContext_p) throws Exception;
/** creates a new empty object which can be used to set properties and then submitted to the createNewObject function
*
* @param objectclass_p OwObjectClass to create object from
* @param resource_p OwResource
* @return OwObjectSkeleton
* @throws Exception
*
* @since 2.5.0
*/
public abstract OwObjectSkeleton createObjectSkeleton(OwObjectClass objectclass_p, OwResource resource_p) throws Exception;
/** creates a cloned object with new properties on the ECM system
* copies the content as well
*
* @param obj_p OwObject to create a copy of
* @param properties_p OwPropertyCollection of OwProperties to set, or null to keep properties
* @param permissions_p OwPermissionCollection of OwPermissions to set, or null to keep permissions
* @param parent_p OwObject the parent object to use as a container, e.g. a folder or a ECM root, can be null if no parent is required
* @param childTypes_p int types of the child objects to copy with the object, can be null if no children should be copied
*
* @return String DMSID of created copy
*/
public abstract String createObjectCopy(OwObject obj_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwObject parent_p, int[] childTypes_p) throws Exception;
/** creates a cloned object with new properties on the ECM system
* @param parent_p OwObject the parent object to use as a container, e.g. a folder or a ECM root, can be null if no parent is required
* @param childTypes_p int types of the child objects to copy with the object, can be null if no children should be copied
* @param iContext_p int as defined in {@link OwStatusContextDefinitions}
*
* @return true, if clone can be created
*/
public abstract boolean canCreateObjectCopy(OwObject parent_p, int[] childTypes_p, int iContext_p) throws Exception;
/** check if a extended function like print can be performed on the given object
*
* @param obj_p OwObject where function should be performed, or null if function does not require a object
* @param iContext_p int as defined in {@link OwStatusContextDefinitions}
* @param iFunctionCode_p int code of requested function as defined in CAN_DO_FUNCTIONCODE_...
*/
public abstract boolean canDo(OwObject obj_p, int iFunctionCode_p, int iContext_p) throws Exception;
/**
*
* @return the current Role Manager
* @since 4.1.1.1
*/
public abstract OwRoleManager getRoleManager();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface SecurityMechanism extends EObject {\r\n}",
"public NetworkManager() {\n okHttpClient = new OkHttpClientProvider().getClient();\n retrofit = new RetrofitInstanceProvider(new RelatedTopicTypeAdapterFactory(), okHttpClient).getRetrofitInstance();\n }",
"public interface SingleAccessPoint {\t\n\t\n\t/**\n\t * This method returns some kind of message to the client, which could be anything\n\t * and needs to be implemented for the concrete accesspoint\n\t */\n\tpublic void returnMessage(String message);\n\t\n\t/**\n\t * \n\t * @param message Message to display\n\t * @return AuthenticationToken that needs to be compatible with backend.\n\t */\n\tpublic AuthenticationToken getAuthentication(String message);\n\t\n\n\t\t\n\t\n\t\n}",
"public interface NetworkClientManager {\n\n /**\n * Get a NetworkClientConnection\n *\n * @return NetworkClientConnection instance\n */\n NetworkClientConnection getConnection();\n\n /**\n * Get a NetworkClientConnection from uriToNode\n * @param uriToNode\n * @return NetworkClientConnection instance\n */\n NetworkClientConnection getConnection(String uriToNode);\n\n}",
"public interface Client {\n\n\t/**\n\t * Provides the ID of the current user. In case the application doesn't have\n\t * authentication, a static ID must be defined.\n\t * \n\t * @return the ID of the current user.\n\t */\n\tString getUserId();\n\n\t/**\n\t * Provides the username of the current user. In case the application\n\t * doesn't have authentication, a static ID must be defined.\n\t * \n\t * @return the username of the current user.\n\t */\n\tString getUserUsername();\n\n\t/**\n\t * Provides the password of the current user. In case the application\n\t * doesn't have authentication, a static password must be defined.\n\t * \n\t * @return the password of the current user.\n\t */\n\tString getUserPassword();\n\t\n\t/**\n\t * Provides the password hash of the current user.\n\t * \n\t * @return the password hash of the current user.\n\t */\n\tString getUserPasswordHash();\n\t\n\t/**\n\t * Sets the password hash of the current user\n\t * \n\t * @param passwordHash the password hash of the current user.\n\t */\n\tvoid setUserPasswordHash(String passwordHash);\n\n\t/**\n\t * Sets the username of the current user\n\t * \n\t * @param username the username of the current user.\n\t */\n\tvoid setUserUsername(String username);\n\n\t/**\n\t * Provides the ability to clear the user ID, username and user password.\n\t */\n\tvoid logout();\n\t\n\t/**\n\t * Provides the ability to track the current menu item.\n\t */\n\tvoid setMenuItem(MenuItem menuItem);\n\t\n\t/**\n\t * Provides the ability to track the current resource item.\n\t */\n\tvoid setResourceItem(BaseContentItem resourceItem);\n\t\n\t/**\n\t * Provides the ability to open a resource.\n\t */\n\tvoid openResource(String resourcePath);\n\t\n\t/**\n\t * Gets a value for a key on the native storage. Native storage is provided by the framework. It consists in a way to store key/value pairs. Like the HTML5 DB, this kind of storage is cleaned up automatically if the user removes the application. This storage should be used specially if you want to share data between the HTML content and native side of the application, otherwise we highly recommend use HTML5 DB. There are two ways of store data on the native storage, globally and content-specific.\n\t *\n\t * <p>\n\t * <strong>Globally</strong>\n\t * It's global on the application. The key can be retrieved from any content in any part of the system, as well as in any part of the native code. You must take care that the key can be used by other content developer. Below you can find the API calls to store and retrieve key/value pairs.\n\t * <ul>\n\t * <li>clientPlugin.getValue(MFStoreType.GLOBAL, key, callback);</li>\n\t * </ul>\n\t * </p>\n\t * <p>\n\t * <strong>Content-specific</strong>\n\t * It's connected to the current resource/menu-item. Below you can find the API calls to store and retrieve key/value pairs.\n\t * <ul>\n\t * <li>clientPlugin.getValue(MFStoreType.SPECIFIC, key, callback);</li>\n\t * </ul>\n\t * </p>\n\t * \n\t * @param type\t\tThe type of the native storage.\n\t * @param key\t\tThe key name.\n\t */\n\tString getValue(String type, String key);\n\t\n\t/**\n\t * Sets a value for a key on the native storage. Native storage is provided by the framework. It consists in a way to store key/value pairs. Like the HTML5 DB, this kind of storage is cleaned up automatically if the user removes the application. This storage should be used specially if you want to share data between the HTML content and native side of the application, otherwise we highly recommend use HTML5 DB. There are two ways of store data on the native storage, globally and content-specific.\n\t * <p>\n\t * <strong>Globally</strong>\n\t * It's global on the application. The key can be retrieved from any content in any part of the system, as well as in any part of the native code. You must take care that the key can be used by other content developer. Below you can find the API calls to store and retrieve key/value pairs.\n\t * <ul>\n\t * <li>clientPlugin.setValue(MFStoreType.GLOBAL, key, value, callback);</li>\n\t * </ul>\n\t * </p>\n\t * <p>\n\t * <strong>Content-specific</strong>\n\t * It's connected to the current resource/menu-item. Below you can find the API calls to store and retrieve key/value pairs.\n\t * <ul>\n\t * <li>clientPlugin.setValue(MFStoreType.SPECIFIC, key, value, callback);</li>\n\t * </ul>\n\t * </p>\n\t * \n\t * @param type\t\tThe type of the native storage.\n\t * @param key\t\tThe key name.\n\t * @param value\t\tThe value.\n\t */\n\tboolean setValue(String type, String key, String value);\n\n\t/**\n\t * Forces a sync. This method should be only used when user has set\n\t * {@link SyncType} to MANUAL.\n\t * \n\t */\n\tvoid sync();\n\n\t/**\n\t * Tracks the access to the current object. The time spent on this object is\n\t * calculated between calls to this method.\n\t * \n\t * @param sender\t\t\tThe sender. This will be 'mf' for internal mobile framework calls. It's a string value.\n\t * @param additionalInfo \tOptional additional information. This information must be used by content developers to track internal pages.\n\t */\n\tvoid track(String sender, String additionalInfo);\n\t\n\t/**\n\t * Tracks some information.\n\t * \n\t * @param sender\t\t\tThe sender. This will be 'mf' for internal mobile framework calls. It's a string value.\n\t * @param objectId\t\t\tObjectId.\n\t * @param additionalInfo \tOptional additional information. This information must be used by content developers to track internal pages.\n\t */\n\tvoid track(String sender, String objectId, String additionalInfo);\n\n\t/**\n\t * Provides the list of all available packages, installed or not.\n\t * \n\t * @param callback\n\t * the list of all available packages.\n\t */\n\tvoid getPackageCatalogue(PackageCatalogueRetrieved callback);\n\t\n\t/**\n\t * Retrieves the local path root for a particular course.\n\t * \n\t * @param courseId\t\t\tThe course id.\n\t * @param phoneGapCallback\tThe PhoneGap callback.\n\t * @param callback\t\t\tThe callback function. \n\t */\n\tvoid getCourseLocalPathRoot(String courseId, String phoneGapCallback, GetCourseLocalPathRootCompleted callback);\n\t\n\t/**\n\t * Retrieves the local path root for the currently opened course.\n\t * \n\t * @param phoneGapCallback\tThe PhoneGap callback.\n\t * @param callback\t\t\tThe callback function. \n\t */\n\tvoid getCurrentCourseLocalPathRoot(String phoneGapCallback, GetCourseLocalPathRootCompleted callback);\n\t\n\t/**\n\t * Initialises a temporary folder for the currently opened course.\n\t * If the folder already exists, the folder will be cleared. If it does not exist, it will be created.\n\t * \n\t * Callback will return a JSON object with the following key and value pairs:\n\t * \ttempFolderPath\tThe full local path to the temporary folder in the course directory. E.g. /mnt/sdcard/.../{uniqueCourseFolderId}/temp\n\t * \n\t * Error callback will return a JSON object with the following key and value pairs:\n\t * error\t\t\tAn error string to determine why the native method call failed.\n\t * \n\t * @param phoneGapCallback\tThe PhoneGap callback.\n\t * @param callback\t\t\tThe callback function. \n\t */\n\tvoid initialiseCurrentCourseLocalTempFolder(String phoneGapCallback, InitialiseCurrentCourseLocalTempFolderCompleted callback);\n\t\n\t/**\n\t * Clears the temporary folder for the currently opened course.\n\t * If the folder exists, the folder will be cleared and removed. If the folder does not exist, an error will occur.\n\t * \n\t * Callback will not return a value and will be invoked when the operation has finished.\n\t * \n\t * Error callback will return a JSON object with the following key and value pairs:\n\t * error\t\t\tAn error string to determine why the native method call failed.\n\t * \n\t * @param phoneGapCallback\tThe PhoneGap callback.\n\t * @param callback\t\t\tThe callback function.\n\t */\n\tvoid clearCurrentCourseLocalTempFolder(String phoneGapCallback, PhoneGapOperationNoResultCompleted callback);\n}",
"public interface NetworkConstatnts {\n\n interface ResponseCode {\n int success = 201;\n int sessionExpred = 203;\n }\n\n interface URL {\n // String BASE_URL = \"\"; //LIVE\n String BASE_URL = \"http://barber.xicom.info/\";//DEMO\n }\n\n interface KEYS {\n String secretKey = \"J3H7F9J6FG\";\n String deviceType = \"DeviceType\";\n String uniqueDeviceId = \"UniqueDeviceId\";\n // String deviceId = \"DeviceID\";\n String TimeStamp = \"TimeStamp\";\n String sessionToken = \"SessionToken\";\n String deviceToken = \"DeviceToken\";\n String userId = \"userId\";\n String sessionId = \"SessionId\";\n String ClientHash = \"ClientHash\";\n\n\n }\n\n interface API {\n String ABOUT_US = URL.BASE_URL + \"Page/AboutUs\";\n\n String loginUser = \"api/account/Login\";\n }\n\n interface Params {\n String firstName = \"firstName\";\n String email = \"Email\";\n String lastName = \"lastName\";\n String password = \"Password\";\n\n }\n\n interface RequestCode {\n int API_LOGIN = 1;\n int API_REGISTER = 2;\n int API_FORGET_PASSWORD = 3;\n\n }\n}",
"public interface TCNetworkManageInterface {\n\n public String serviceIdentifier();\n\n public String apiClassPath();\n\n public String apiMethodName();\n}",
"public interface CommunityService extends WorkspaceService\r\n{\r\n\r\n static final String COMMUNITY_SERVICE_KEY = \"COMMUNITY_SERVICE_KEY\";\r\n\r\n /**\r\n * Creations of a Community object reference.\r\n * @param name the initial name to asign to the community\r\n * @param user_short_pid storage object short pid representing the owner\r\n * @return Community object reference\r\n * @exception CommunityException\r\n */\r\n Community createCommunity( String name, byte[] user_short_pid ) \r\n throws CommunityException;\r\n\r\n /**\r\n * Creations of a Community storage instance.\r\n * @param name the initial name to asign to the community\r\n * @param user_short_pid storage object short pid representing the owner\r\n * @return CommunityStorage community storage\r\n * @exception CommunityException\r\n */\r\n CommunityStorage createCommunityStorage( String name, byte[] user_short_pid ) \r\n throws CommunityException;\r\n\r\n /**\r\n * Creation of a Community object reference based on a supplied storage object.\r\n * @param store a community storage object\r\n * @return Community a Community object reference\r\n * @exception CommunityException\r\n */\r\n Community getCommunityReference( CommunityStorage store ) \r\n throws CommunityException;\r\n\r\n /**\r\n * Returns a reference to a Community given a persistent storage object identifier.\r\n * @param pid community short persistent identifier\r\n * @return Desktop the corresponding PID\r\n * @exception NotFound if the supplied pid does not matach a know desktop\r\n */\r\n Community getCommunityReference( byte[] pid )\r\n throws NotFound;\r\n\r\n}",
"public interface AuthManager\n{\n void checkAuthAnnounce(Id<Node> nodeId, DynamicAnnouncement announcement, HttpServletRequest request);\n\n void checkAuthDelete(Id<Node> nodeId, HttpServletRequest request);\n\n void checkAuthReplicate(HttpServletRequest request);\n}",
"public interface RemoteStorageContext\n{\n // change detection\n\n /**\n * Returns the timestamp of latest change. Will propagate to parent if it is more recently changed as this (and\n * parent is set).\n */\n long getLastChanged();\n\n // parent\n\n /**\n * Returns the parent context, or null if not set.\n * \n * @return\n */\n RemoteStorageContext getParentRemoteStorageContext();\n\n /**\n * Sets the parent context, or nullify it.\n * \n * @return\n */\n void setParentRemoteStorageContext( RemoteStorageContext parent );\n\n // modification\n\n /**\n * Gets an object from context. Will propagate to parent if not found in this context (and parent is set).\n * \n * @param key\n * @return\n */\n Object getRemoteConnectionContextObject( String key );\n\n /**\n * Puts an object into this context.\n * \n * @param key\n * @param value\n */\n void putRemoteConnectionContextObject( String key, Object value );\n\n /**\n * Removed an object from this context. Parent is unchanged.\n * \n * @param key\n */\n void removeRemoteConnectionContextObject( String key );\n\n /**\n * Returns true if this context has an object under the given key.\n * \n * @param key\n * @return\n */\n boolean hasRemoteConnectionContextObject( String key );\n\n // --\n\n boolean hasRemoteConnectionSettings();\n\n RemoteConnectionSettings getRemoteConnectionSettings();\n\n void setRemoteConnectionSettings( RemoteConnectionSettings settings );\n\n void removeRemoteConnectionSettings();\n\n boolean hasRemoteAuthenticationSettings();\n\n RemoteAuthenticationSettings getRemoteAuthenticationSettings();\n\n void setRemoteAuthenticationSettings( RemoteAuthenticationSettings settings );\n\n void removeRemoteAuthenticationSettings();\n\n boolean hasRemoteProxySettings();\n\n RemoteProxySettings getRemoteProxySettings();\n\n void setRemoteProxySettings( RemoteProxySettings settings );\n\n void removeRemoteProxySettings();\n}",
"public interface ServerTokenExchangeProvider extends Provider, ServerTokenExchange\n{\n}",
"public interface CommunicationUser {\n\t\n\t/**\n\t * Provide communication API that allows for communication with other object in the simulator.\n\t * Method is a callback for the registration of the object in {@link CommunicationModel}\n\t * @param api the access to the communication infrastructure \n\t */\n\tvoid setCommunicationAPI(CommunicationAPI api);\n\t\n\t/**\n\t * Get position. The position is required to determine the entities you can communicate with \n\t * @return positing on the communication user or <code>null</code> if object is not positioned \n\t */\n\tPoint getPosition();\n\t\n\t/**\n\t * Get the distance in which you want to communicate. \n\t * @return\n\t */\n\tdouble getRadius();\n\t\n\t/**\n\t * Get the connection reliability. This is probability (0,1] that the message is send/received.\n\t * When two entities communicate the probability of message delivery is a product of their reliability. \n\t * @return\n\t */\n\tdouble getReliability();\n\t\n\t/**\n\t * Receive the message. Multiple messages might be delivered during one tick of the simulator. \n\t * The simple implementation of handling multiple messages is provided in {@link Mailbox} \n\t * @param message delivered\n\t */\n\tvoid receive(Message message);\n}",
"public interface NetOperation {\n String userLogin(String UID, String password) throws Exception;\n\n String userRegister(String UID, String password, String email, List<String> interests) throws Exception;\n\n Bitmap loadImg(String picId) throws Exception;\n\n String upload(InputStream inputStream, Map<String, String> data) throws Exception;\n\n BufferedInputStream download() throws Exception;\n}",
"public PublicNetworkAccess publicNetworkAccess() {\n return this.publicNetworkAccess;\n }",
"public PublicNetworkAccess publicNetworkAccess() {\n return this.publicNetworkAccess;\n }",
"public interface NodeService {\n\n /**\n * Given a Node's ID, return the point associated with that Node.\n * @param nodeId - Integer unique ID for the Node.\n * @return Point with the coordinates of the Node's coordinates.\n */\n Point getPointByNodeId(Integer nodeId);\n\n /**\n * Adding a candidate Node to the network which has yet been evaluated\n * against the network.\n *\n * @param lat - Latitude of the Node.\n * @param lon - Longitude of the Node.\n * @return JSON String listing the results of evaluating whether this Node is on\n * the Network or requires adding Edges to reach the network.\n */\n String addNewNode(Double lat, Double lon);\n\n // TODO: Diagnostic Service? This is being used however to Edit Nodes.\n String showAllNodes();\n\n String getNodeGroups();\n\n String setNodeGroup(Integer id, Double lat, Double lon);\n\n // TODO: Probably would go over to the EdgeService\n String getMatchingSegments(Integer pointId);\n\n /**\n * Given a Node's ID and a new Lat/Lon position, edit the Edges connected\n * to that node and return a Feature Collection with the updated Edges (the\n * Node itself will be still active in the browser and the position is\n * already known by the client).\n * @param pointId - Unique Integer representing the Node to edit.\n * @param lat - Latitude of the new location.\n * @param lng - Longitude of the new location.\n * @return Feature Collection with the updated Edges.\n */\n // TODO: Probably would go over to the EdgeService\n String getEdgesAtNewLocation(Integer pointId, Double lat, Double lng);\n\n /**\n * Accepts the last recommended position for the Node as the one to be\n * committed to the database.\n * @param pointId - Unique Integer representing the Node to edit.\n * @return String \"OK\" to confirm.\n */\n // TODO: Probably would go over to the EdgeService\n String confirmEdgesAtNewLocation(Integer pointId);\n}",
"public interface SelfContainedKerberosUserService extends KerberosUserService {\n\n}",
"public interface NetworkApplicationDataConsumer {\n\n\t/**\n\t * A new host has joined the group. If this host is a target\n\t * for receiving local status, then an invoke to \n\t * <code>networkCommunication.connectToServerHost()</code> is needed.\n\t * @param aHost the new host\n\t */\n\tpublic void newHost(Host aHost);\n\t\n\n\t/**\n\t * A new host has left the group (expectedly or not).\n\t * @param aHost the gone host \n\t */\n\tpublic void byeHost(Host aHost);\n\t\n\t\n\t/**\n\t * New communication message received.\n\t * @param receivedData is a subclass of {@link NetworkApplicationData} containing the received information\n\t */\n\tpublic void newData(NetworkApplicationData receivedData);\t\n}",
"public OpenShiftManagedClusterBaseIdentityProvider provider() {\n return this.provider;\n }",
"public NetworkManager getNetwork()\n {\n return network;\n }",
"public interface ProviderRepoxRestClient {\n /**\n * Creates a provider in Repox and assigns it to the specific Aggregator\n * \n * @param prov\n * Provider definition\n * @param agr\n * Aggregator reference\n * @return created provider\n * @throws RepoxException\n */\n Provider createProvider(Provider prov, Aggregator agr) throws RepoxException;\n\n /**\n * Moves a provider in Repox and assigns it to the new Aggregator\n * \n * @param providerId\n * provider id\n * @param aggregatorId\n * aggregator id\n * @return created provider\n * @throws RepoxException\n */\n Provider moveProvider(String providerId, String aggregatorId) throws RepoxException;\n\n /**\n * Deletes a provider from Repox\n * \n * @param providerId\n * the Provider reference\n * @return successful?\n * @throws RepoxException\n */\n String deleteProvider(String providerId) throws RepoxException;\n\n /**\n * Updates a provider within Repox\n * \n * @param prov\n * Provider object to update\n * @return updated provider\n * @throws RepoxException\n */\n Provider updateProvider(Provider prov) throws RepoxException;\n\n /**\n * Retrieves all available providers within Repox\n * \n * @return an object containing all provider references\n * @throws RepoxException\n */\n DataProviders retrieveProviders() throws RepoxException;\n\n /**\n * Retrieves all available providers within Repox given a specific Aggregator\n * \n * @param agr\n * Aggregator reference\n * @return an object containing all provider references\n * @throws RepoxException\n */\n DataProviders retrieveAggregatorProviders(Aggregator agr) throws RepoxException;\n\n /**\n * Retrieve a Provider given a specific Id\n * \n * @param providerId\n * @return specific provider\n * @throws RepoxException\n */\n eu.europeana.uim.repox.rest.client.xml.Provider retrieveProvider(String providerId)\n throws RepoxException;\n\n /**\n * Retrieve a Provider given a specific mnemonic\n * \n * @param mnemonic\n * @return specific provider\n * @throws RepoxException\n */\n eu.europeana.uim.repox.rest.client.xml.Provider retrieveProviderByMetadata(String mnemonic)\n throws RepoxException;\n}",
"public interface IRemoteCacheServerAttributes\n extends ICommonRemoteCacheAttributes\n{\n /**\n * Gets the localPort attribute of the IRemoteCacheAttributes object.\n * <p>\n * @return The localPort value\n */\n int getServicePort();\n\n /**\n * Sets the localPort attribute of the IRemoteCacheAttributes object.\n * <p>\n * @param p\n * The new localPort value\n */\n void setServicePort( int p );\n\n /**\n * Should we try to get remotely when the request does not come in from a\n * cluster. If local L1 asks remote server R1 for element A and R1 doesn't\n * have it, should R1 look remotely? The difference is between a local and a\n * remote update. The local update stays local. Normal updates, removes,\n * etc, stay local when they come from a client. If this is set to true,\n * then they can go remote.\n * <p>\n * @return The localClusterConsistency value\n */\n boolean isAllowClusterGet();\n\n /**\n * Should cluster updates be propagated to the locals.\n * <p>\n * @param r\n * The new localClusterConsistency value\n */\n void setAllowClusterGet( boolean r );\n\n /**\n * Gets the ConfigFileName attribute of the IRemoteCacheAttributes object.\n * <p>\n * @return The configuration file name\n */\n String getConfigFileName();\n\n /**\n * Sets the ConfigFileName attribute of the IRemoteCacheAttributes object.\n * <p>\n * @param s\n * The new configuration file name\n */\n void setConfigFileName( String s );\n\n /**\n * Should we try to keep the registry alive\n * <p>\n * @param useRegistryKeepAlive the useRegistryKeepAlive to set\n */\n void setUseRegistryKeepAlive( boolean useRegistryKeepAlive );\n\n /**\n * Should we try to keep the registry alive\n * <p>\n * @return the useRegistryKeepAlive\n */\n boolean isUseRegistryKeepAlive();\n\n /**\n * @param registryKeepAliveDelayMillis the registryKeepAliveDelayMillis to set\n */\n void setRegistryKeepAliveDelayMillis( long registryKeepAliveDelayMillis );\n\n /**\n * @return the registryKeepAliveDelayMillis\n */\n long getRegistryKeepAliveDelayMillis();\n}",
"public ObjectStore getCEObjectStore()\r\n\t{\r\n\t\tString Uri = ReadProperty.getProperty(\"URI\");\r\n\t\tConnection conn = Factory.Connection.getConnection(Uri); \r\n\t\t//String decryptpassword = encrypt.decrypt(ReadProperty.getProperty(\"PASSWORD\"));\r\n\t\tString decryptedpassword = encrypt.getDeMes(ReadProperty.getProperty(\"USER_NAME\"), ReadProperty.getProperty(\"PASSWORD\"));\r\n\t\tSubject subject = UserContext.createSubject(conn, ReadProperty.getProperty(\"USER_NAME\"),decryptedpassword,null);\r\n\t\tUserContext.get().pushSubject(subject);\r\n\t\tDomain domain = Factory.Domain.fetchInstance(conn, ReadProperty.getProperty(\"DOMAIN\"), null);\r\n\t\tobjstore=Factory.ObjectStore.fetchInstance(domain, ReadProperty.getProperty(\"OBJECTSTORE\"), null);\r\n\t\t\r\n\t\t\r\n\r\n\t\tlogger.info(\"In getCESession\");\r\n\r\n\r\n\t\tlogger.info(\"Connected To CE Succesfully \" + objstore.get_Name());\r\n\r\n\r\n\r\n\t\treturn objstore;\r\n\t}",
"public NetObject getObject();",
"public interface Iuser extends Remote{\r\n\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tpublic String getUsername();\r\n\r\n\t\t\r\n\t\tpublic String getPassword();\r\n\r\n\r\n\t\tpublic void setPassword(String string);\r\n\t\t\r\n\t\tpublic void setUsername(String string);\r\n\t\t\r\n\t\tpublic void getItem(IItem item);\r\n\t\t\r\n\t\tpublic void purchaseItems();\r\n\t\t\r\n\t public int getItemCounter();\r\n\t\t\r\n\t\t\r\n\r\n\t}",
"public interface IUserManagement {\n\n\t/**\n\t * Search users related to a realm It\n\t *\n\t * @param realm realm name\n\t * @return Returns a List<UserRepresentation>\n\t */\n\tList<UserRepresentation> getUsers(final String realm);\n\n\t/**\n\t * Search of an created user account. It will search with overgiven username in\n\t * the related user management system.\n\t *\n\t * @param username user name\n\t * @return Returns a List<UserRepresentation> with 1 item, if the user is found,\n\t * otherwise 0\n\t */\n\tList<UserRepresentation> searchUserAccount(final String username);\n\n\t/**\n\t * Returns all groups for the given keycloak user\n\t *\n\t * @param userId user id\n\t * @return Returns a List<GroupRepresentation>\n\t */\n\tList<GroupRepresentation> getUserGroups(final String userId);\n\n\t/**\n\t * Returns user representation object from keycloak\n\t *\n\t * @param userId keycloak user id\n\t * @return UserRepresentation instance\n\t */\n\tUserRepresentation getUserRepresentation(final String userId);\n\n\t/**\n\t * Creates an user account with all parameters in the user account management\n\t * system. The user account needs to be activated after creation before login.\n\t *\n\t * @param username user name\n\t * @param firstname first name\n\t * @param lastname last name\n\t * @param email email\n\t * @param password password\n\t * @return HttpStatus CREATED, if creation was successful. In all other cases\n\t * the response of the original response.\n\t */\n\tHttpStatus createUserAccount(final String realm, final String username, final String firstName,\n\t\t\tfinal String lastName, final String email, final String password);\n\n\t/**\n\t * Creates a group account with all parameters in the user account management\n\t * system.\n\t *\n\t * @param groupName group name\n\t * @return HttpStatus CREATED, if creation was successful. In all other cases\n\t * the response of the original response.\n\t */\n\tHttpStatus createGroup(final String groupName);\n\n\t/**\n\t * Get a group representation data by groupName\n\t *\n\t * @param groupName group name\n\t * @return GroupRepresentation instance\n\t */\n\tGroupRepresentation getGroup(final String groupName);\n\n\t/**\n\t * Add a user to a groupId\n\t *\n\t * @param user user\n\t * @param groupId groupId\n\t */\n\tvoid addUserToGroup(final String userId, final String groupId);\n\n\t/**\n\t * Add a realm to a user\n\t *\n\t * @param user username\n\t * @param realm realm\n\t */\n\tvoid addRealmToUser(final String username, final String realm);\n\n\t/**\n\t * Add a realm to a user\n\t *\n\t * @param user username\n\t * @param realm realm\n\t */\n\tvoid addRealmToUserAccount(final String userId, final String realm);\n\n\t/**\n\t * Activation of an created user account. It will search with overgiven username\n\t * in the related user management system. If it finds the user account, it will\n\t * activate that account. After this step the user can login.\n\t *\n\t * @param username user name\n\t * @return HttpStatus OK, if activation was successful, NOT_FOUND if username\n\t * was not found in the system.\n\t */\n\tHttpStatus activateUserAccount(final String username);\n\n\t/**\n\t * Reset the password of an created user account. If it finds the user account,\n\t * it will reset the password. After this step the user can login with the new\n\t * password.\n\t *\n\t * @param userRepresentation UserRepresentation instance\n\t * @param password password\n\t */\n\tHttpStatus resetPassword(final UserRepresentation userRepresentation, final String password);\n\n\tvoid updateEmailUserAccount(final String userId, final String email);\n\n\tvoid updateNameUserAccount(final String userId, final String name);\n\n\tvoid updateSurnameUserAccount(final String userId, final String surname);\n\n\tvoid disableUserAccount(final String userId);\n\n\tpublic RealmResource createRealmIfNotExists(final String realmName, final String displayName, final String... clients);\n\n\tpublic List<RealmInfo> getRealmsForUser(final String username);\n\n\tpublic void addClientToRealm(final String realm, final String client, final String... redirectUrls);\n\n\tvoid addRolesToRealm(final String realm, final String client, final List<RoleInfo> roles);\n\n\tList<String> getUsersForRealm(final String realm);\n\n\tList<String> getRolesForUser(final String user, final String realm, final String client);\n\n\tList<RoleInfo> getRolesForClient(final String realm, final String client);\n\n\tvoid setRolesForUser(final String realm, final String client, final List<UserRoles> userRoles);\n\n\tvoid setApplicationRolesForUser(final String realm, final String user, final List<ApplicationRoles> appRoles);\n}",
"public abstract void connect() throws OrmException;",
"public DocumentumCoreServicesImpl() {\r\n\r\n\t\tIObjectService iObjService = null;\r\n\r\n\t\tif (this.objectService == null) {\r\n\r\n\t\t\tlogger.info(INFO_INICIANDO_EMC);\r\n\r\n\t\t\ttry {\r\n\r\n\t\t\t\tRepositoryIdentityConstants repositoryIdentityConstants = EMCDocumentumFactory\r\n\t\t\t\t\t\t.getConstants(RepositoryIdentityConstants.class);\r\n\r\n\t\t\t\tthis.setRepositoryIdentityConstants(repositoryIdentityConstants);\r\n\r\n\t\t\t\tContextFactory contextFactory = ContextFactory.getInstance();\r\n\r\n\t\t\t\tIServiceContext serviceContext = contextFactory.getContext();\r\n\t\t\t\tserviceContext.setRuntimeProperty(IServiceContext.USER_TRANSACTION_HINT, IServiceContext.TRANSACTION_REQUIRED);\r\n\t\t\t\tserviceContext.setRuntimeProperty(IServiceContext.PAYLOAD_PROCESSING_POLICY, \"PAYLOAD_FAIL_ON_EXCEPTION\");\r\n\r\n\t\t\t\tsetServiceContext(serviceContext);\r\n\r\n\t\t\t\tRepositoryIdentity repoId = new RepositoryIdentity();\r\n\r\n\t\t\t\trepoId.setRepositoryName(REPOSITORY_NAME);\r\n\r\n\t\t\t\trepoId.setUserName(USER_NAME);\r\n\r\n\t\t\t\trepoId.setPassword(USER_PASSWORD);\r\n\r\n\t\t\t\tgetServiceContext().addIdentity(repoId);\r\n\r\n\t\t\t\t//\t\tcontextFactory.register(getServiceContext());\r\n\r\n\t\t\t\t//iObjectService = ServiceFactory.getInstance().getRemoteService(IObjectService.class, serviceContext, MODULE_NAME, DFS_SERVICE_URL);\r\n\t\t\t\tiObjService = ServiceFactory.getInstance().getLocalService(IObjectService.class, serviceContext);\r\n\r\n\t\t\t\tlogger.info(INFO_CONEXAO_EMC);\r\n\r\n\t\t\t\tthis.objectService = iObjService;\r\n\r\n\t\t\t} catch (ServiceInvocationException e) {\r\n\r\n\t\t\t\tlogger.error(ERROR_CONEXAO_EMC.concat(e.getLocalizedMessage()));\r\n\r\n\t\t\t}\r\n\r\n\t\t\tthis.setObjectService(iObjService);\r\n\t\t}\r\n\r\n\t}",
"public interface EcAuthService {\n\n /**\n * 接口信息鉴权\n * @param appKey appKey\n * @param appSecrect appSecrect\n * @param url 路径\n * @return 鉴权类信息\n */\n AuthResp auth(String appKey, String appSecrect, String url);\n}",
"public interface AccessSessionLocal\n extends javax.ejb.EJBLocalObject\n{\n /**\n * Business Method\n */\n public boolean authenticateUser( java.security.cert.X509Certificate[] certificates ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public org.emayor.servicehandling.interfaces.ServiceSessionLocal[] getAllServiceSessions( ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public org.emayor.servicehandling.interfaces.ServiceSessionLocal getServiceSession( java.lang.String ssid ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public java.lang.String startServiceSession( java.lang.String serviceId,boolean isForwarded,java.lang.String xmlDoc,java.lang.String docSig ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public java.lang.String startServiceSession( java.lang.String serviceId,java.lang.String requestDocument ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public boolean stopServiceSession( java.lang.String ssid ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public boolean stopAllServiceSessions( ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public org.emayor.servicehandling.kernel.ServiceInfo[] listAvailableServices( ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public boolean stop( ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public org.eMayor.PolicyEnforcement.C_UserProfile getUserProfile( ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public java.lang.String getSessionId( ) throws org.emayor.servicehandling.kernel.SessionException;\n\n /**\n * Business Method\n */\n public java.lang.String getUserId( ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public void setUserId( java.lang.String userId ) throws org.emayor.servicehandling.kernel.AccessSessionException;\n\n /**\n * Business Method\n */\n public java.util.Date getStartDate( ) throws org.emayor.servicehandling.kernel.SessionException;\n\n}",
"public interface EndpointBase {\n\n boolean isIdleNow();\n\n /**\n * @param connectionTimeout\n * @param methodTimeout\n */\n void setTimeouts(int connectionTimeout, int methodTimeout);\n\n /**\n * @param alwaysMainThread\n */\n void setCallbackThread(boolean alwaysMainThread);\n\n /**\n * @param flags\n */\n void setDebugFlags(int flags);\n\n int getDebugFlags();\n\n /**\n * @param delay\n */\n void setDelay(int delay);\n\n void addErrorLogger(ErrorLogger logger);\n\n void removeErrorLogger(ErrorLogger logger);\n\n void setOnRequestEventListener(OnRequestEventListener listener);\n\n\n void setPercentLoss(float percentLoss);\n\n int getThreadPriority();\n\n void setThreadPriority(int threadPriority);\n\n\n ProtocolController getProtocolController();\n\n void setUrlModifier(UrlModifier urlModifier);\n\n /**\n * No log.\n */\n int NO_DEBUG = 0;\n\n /**\n * Log time of requests.\n */\n int TIME_DEBUG = 1;\n\n /**\n * Log request content.\n */\n int REQUEST_DEBUG = 2;\n\n /**\n * Log response content.\n */\n int RESPONSE_DEBUG = 4;\n\n /**\n * Log cache behavior.\n */\n int CACHE_DEBUG = 8;\n\n /**\n * Log request code line.\n */\n int REQUEST_LINE_DEBUG = 16;\n\n /**\n * Log request and response headers.\n */\n int HEADERS_DEBUG = 32;\n\n /**\n * Log request errors\n */\n int ERROR_DEBUG = 64;\n\n /**\n * Log cancellations\n */\n int CANCEL_DEBUG = 128;\n\n /**\n * Log cancellations\n */\n int THREAD_DEBUG = 256;\n\n /**\n * Log everything.\n */\n int FULL_DEBUG = TIME_DEBUG | REQUEST_DEBUG | RESPONSE_DEBUG | CACHE_DEBUG | REQUEST_LINE_DEBUG | HEADERS_DEBUG | ERROR_DEBUG | CANCEL_DEBUG;\n\n int INTERNAL_DEBUG = FULL_DEBUG | THREAD_DEBUG;\n\n /**\n * Created by Kuba on 17/07/14.\n */\n interface UrlModifier {\n\n String createUrl(String url);\n\n }\n\n interface OnRequestEventListener {\n\n void onStart(Request request, int requestsCount);\n\n void onStop(Request request, int requestsCount);\n\n }\n}",
"public interface MnemeService\n{\n\t/** The type string for this application: should not change over time as it may be stored in various parts of persistent entities. */\n\tstatic final String APPLICATION_ID = \"sakai:mneme\";\n\n\t/** Event tracking event for deleting an assessment. */\n\tstatic final String ASSESSMENT_DELETE = \"mneme.assessment.delete\";\n\n\t/** Event tracking event for changing an assessment. */\n\tstatic final String ASSESSMENT_EDIT = \"mneme.assessment.edit\";\n\n\t/** Event tracking event for creating an assessment. */\n\tstatic final String ASSESSMENT_NEW = \"mneme.assessment.new\";\n\n\t/** Event tracking event for publishing an assessment. */\n\tstatic final String ASSESSMENT_PUBLISH = \"mneme.assessment.publish\";\n\n\t/** The sub-type for assessment in references (/mneme/assessment/...) */\n\tstatic final String ASSESSMENT_TYPE = \"assessment\";\n\n\t/** Event tracking event for un-publishing an assessment. */\n\tstatic final String ASSESSMENT_UNPUBLISH = \"mneme.assessment.unpublish\";\n\n\t/** The security function used to check if users can setup a formal course evaluation. */\n\tstatic final String COURSE_EVAL_PERMISSION = \"mneme.course.eval\";\n\n\t/** Event tracking event for download submissions for question. */\n\tstatic final String DOWNLOAD_SQ = \"mneme.download.sq\";\n\n\t/** The number of ms we allow answers and completions of submissions after hard deadlines. */\n\tstatic final long GRACE = 2 * 60 * 1000;\n\n\t/** The security function used to check if users can grade tests. */\n\tstatic final String GRADE_PERMISSION = \"mneme.grade\";\n\n\t/** The security function used to check if users have guest access. */\n\tstatic final String GUEST_PERMISSION = \"mneme.guest\";\n\n\t/** The security function used to check if users can manage tests. */\n\tstatic final String MANAGE_PERMISSION = \"mneme.manage\";\n\n\t/** Event tracking event for deleting a pool. */\n\tstatic final String POOL_DELETE = \"mneme.pool.delete\";\n\n\t/** Event tracking event for changing a pool. */\n\tstatic final String POOL_EDIT = \"mneme.pool.edit\";\n\n\t/** Event tracking event for creating a pool. */\n\tstatic final String POOL_NEW = \"mneme.pool.new\";\n\n\t/** The sub-type for pool in references (/mneme/pool/...) */\n\tstatic final String POOL_TYPE = \"pool\";\n\n\t/** Event tracking event for deleting a question. */\n\tstatic final String QUESTION_DELETE = \"mneme.question.delete\";\n\n\t/** Event tracking event for changing a question. */\n\tstatic final String QUESTION_EDIT = \"mneme.question.edit\";\n\n\t/** Event tracking event for creating a question. */\n\tstatic final String QUESTION_NEW = \"mneme.question.new\";\n\n\t/** The sub-type for question in references (/mneme/question/...) */\n\tstatic final String QUESTION_TYPE = \"question\";\n\n\t/** This string starts the references to resources in this service. */\n\tstatic final String REFERENCE_ROOT = \"/mneme\";\n\n\t/** Event tracking event for adding a submission. */\n\tstatic final String SUBMISSION_ADD = \"mneme.submit\";\n\n\t/** Event tracking event for answering a question in a submission. */\n\tstatic final String SUBMISSION_ANSWER = \"mneme.answer\";\n\n\t/** Event tracking event for the system automatically completing a submission. */\n\tstatic final String SUBMISSION_AUTO_COMPLETE = \"mneme.auto_complete\";\n\n\t/** Event tracking event for completing a submission. */\n\tstatic final String SUBMISSION_COMPLETE = \"mneme.complete\";\n\n\t/** Event tracking event for re-entering a submission. */\n\tstatic final String SUBMISSION_CONTINUE = \"mneme.continue\";\n\n\t/** Event tracking event for entering a submission. */\n\tstatic final String SUBMISSION_ENTER = \"mneme.enter\";\n\n\t/** Event tracking event for grading a submission. */\n\tstatic final String SUBMISSION_GRADE = \"mneme.grade\";\n\n\t/** Event tracking event for reviewing a submission. */\n\tstatic final String SUBMISSION_REVIEW = \"mneme.review\";\n\n\t/** The sub-type for submissions in references (/mneme/submission/...) */\n\tstatic final String SUBMISSION_TYPE = \"submission\";\n\n\t/** The security function used to check if users can submit to an assessment. */\n\tstatic final String SUBMIT_PERMISSION = \"mneme.submit\";\n\n\t/**\n\t * Find a question plugin for this question type.\n\t * \n\t * @param type\n\t * The question type.\n\t * @return The question plugin for this question type, or null if none found.\n\t */\n\tQuestionPlugin getQuestionPlugin(String type);\n\n\t/**\n\t * Access all the quesiton plugins, sorted by the (localized) type name.\n\t * \n\t * @return A List of all the quesiton plugins, sorted by the (localized) type name.\n\t */\n\tList<QuestionPlugin> getQuestionPlugins();\n\n\t/**\n\t * Register a question plugin.\n\t * \n\t * @param plugin\n\t * The question plugin.\n\t */\n\tvoid registerQuestionPlugin(QuestionPlugin plugin);\n}",
"public interface AccessManager {\n\n /**\n * predefined action constants\n */\n public String READ_ACTION = javax.jcr.Session.ACTION_READ;\n public String REMOVE_ACTION = javax.jcr.Session.ACTION_REMOVE;\n public String ADD_NODE_ACTION = javax.jcr.Session.ACTION_ADD_NODE;\n public String SET_PROPERTY_ACTION = javax.jcr.Session.ACTION_SET_PROPERTY;\n\n public String[] READ = new String[] {READ_ACTION};\n public String[] REMOVE = new String[] {REMOVE_ACTION};\n\n /**\n * Determines whether the specified <code>permissions</code> are granted\n * on the item with the specified path.\n *\n * @param parentState The node state of the next existing ancestor.\n * @param relPath The relative path pointing to the non-existing target item.\n * @param actions An array of actions that need to be checked.\n * @return <code>true</code> if the actions are granted; otherwise <code>false</code>\n * @throws ItemNotFoundException if the target item does not exist\n * @throws RepositoryException if another error occurs\n */\n boolean isGranted(NodeState parentState, Path relPath, String[] actions) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Determines whether the specified <code>permissions</code> are granted\n * on the item with the specified path.\n *\n * @param itemState\n * @param actions An array of actions that need to be checked.\n * @return <code>true</code> if the actions are granted; otherwise <code>false</code>\n * @throws ItemNotFoundException if the target item does not exist\n * @throws RepositoryException if another error occurs\n */\n boolean isGranted(ItemState itemState, String[] actions) throws ItemNotFoundException, RepositoryException;\n\n\n /**\n * Returns true if the existing item with the given <code>ItemId</code> can\n * be read.\n *\n * @param itemState\n * @return\n * @throws ItemNotFoundException\n * @throws RepositoryException\n */\n boolean canRead(ItemState itemState) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Returns true if the existing item state can be removed.\n *\n * @param itemState\n * @return\n * @throws ItemNotFoundException\n * @throws RepositoryException\n */\n boolean canRemove(ItemState itemState) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Determines whether the subject of the current context is granted access\n * to the given workspace.\n *\n * @param workspaceName name of workspace\n * @return <code>true</code> if the subject of the current context is\n * granted access to the given workspace; otherwise <code>false</code>.\n * @throws NoSuchWorkspaceException if a workspace with the given name does not exist.\n * @throws RepositoryException if another error occurs\n */\n boolean canAccess(String workspaceName) throws NoSuchWorkspaceException, RepositoryException;\n}",
"public interface SdnControllerProviderInterface {\n\n\t/**\n\t * Method used to read the current topology from the SDN controller\n\t * \n\t * @return the network topology\n\t * @throws NotExistingEntityException if the topology is not found on the controller\n\t * @throws MethodNotImplementedException if the method is not implemented\n\t */\n\tpublic NetworkTopology getNetworkTopology() throws NotExistingEntityException, MethodNotImplementedException;\n\t\n\t/**\n\t * Method used to set the power state of a given node \n\t * \n\t * @param deviceId ID of the network node to be configured\n\t * @param powerState power state to be activated on the network node\n\t * @param consumer the consumer that should receive a notification about the result of the requested command\n\t * @return the operation ID\n\t * @throws NotExistingEntityException if the node is not found\n\t * @throws FailedOperationException if the operation fails\n\t * @throws MethodNotImplementedException if the SDN controller does not support the feature\n\t */\n\tpublic String setPowerState(String deviceId, PowerState powerState, SdnControllerConsumerInterface consumer) throws NotExistingEntityException, FailedOperationException, MethodNotImplementedException;\n\t\n\t/**\n\t * Method used to set the power state of a set of given nodes in an atomic action.\n\t * If a single action fails, the method should automatically roll-back the action.\n\t * \n\t * @param devicesPowerState power states to be configured for the given set of network nodes\n\t * @throws NotExistingEntityException if the node is not found\n\t * @throws FailedOperationException if the operation fails\n\t * @throws MethodNotImplementedException if the SDN controller does not support the feature\n\t */\n\tpublic void setPowerState(Map<String,PowerState> devicesPowerState) throws NotExistingEntityException, FailedOperationException, MethodNotImplementedException;\n\t\n\t\n\t/**\n\t * Method used to establish a list of network paths. \n\t * The method must setup all the paths or none, i.e. if one of them fails, the others should be removed. \n\t * \n\t * @param networkPath list of network paths to be established\n\t * @return the operation ID\n\t * @throws NotExistingEntityException if one the entity in the network paths is not found\n\t * @throws FailedOperationException if the operation fails\n\t * @throws MethodNotImplementedException if the SDN controller does not support the feature\n\t */\n\tpublic String setupPaths(List<SbNetworkPath> networkPath, SdnControllerConsumerInterface consumer) throws NotExistingEntityException, FailedOperationException, MethodNotImplementedException;\n\t\n\t/**\n\t * Method used to remove a list of network paths.\n\t * \n\t * @param networkPathIds list of IDs of the network paths to be removed\n\t * @return the operation ID\n\t * @throws NotExistingEntityException if one of the network path is not found\n\t * @throws FailedOperationException if the operation fails\n\t * @throws MethodNotImplementedException if the SDN controller does not support the feature\n\t */\n\tpublic String removePaths(List<String> networkPathIds, SdnControllerConsumerInterface consumer) throws NotExistingEntityException, FailedOperationException, MethodNotImplementedException;\n\t\n}",
"public interface RemoteCoordinator extends Remote, Identify {\n /**\n * a method to add a Peer to this RemoteCoordinator's list of available Peers\n * called by a MembershipManager\n *\n * @param peer the Uuid of the Peer to be added\n */\n void addPeer(Uuid peer) throws RemoteException;\n\n /**\n * a method to remove a Peer from this RemoteCoordinator's list of available Peers\n * called by a MembershipManager\n *\n * @param peer the Uuid of the Peer to be removed\n */\n void removePeer(Uuid peer) throws RemoteException;\n\n /**\n * a method to get the Uuid of a live Peer in this Coordinator's list of active Peers,\n * removing any dead Peers encountered along the way from the service\n *\n * @return the Uuid of a live Peer\n */\n Uuid getActivePeer() throws RemoteException, NotBoundException;\n\n /**\n * a method to get the list of active Peers from this RemoteCoordinator\n * called by the MembershipManager when bringing new RemoteCoordinators online\n *\n * @return the list of available Uuids from this RemoteCoordinator\n */\n List<Uuid> getActivePeers() throws RemoteException;\n\n /**\n * a method to set the map of active Peers for this RemoteCoordinator\n * called by the MembershipManager when bringing new RemoteCoordinators online\n */\n void setActivePeers(List<Uuid> activePeers) throws RemoteException;\n\n /**\n * a method to assign a JobId to a JobCoordinator\n * called by a User\n * delegates responsibility to its corresponding Coordinator method\n *\n * @param jobId the JobId of the Job being assigned\n * @return true if the job was successfully assigned, false otherwise\n * @throws RemoteException\n */\n boolean assignJob(JobId jobId) throws RemoteException;\n\n /**\n * a method to get an allocation of TaskManagers\n * called by a JobManager\n *\n * @param numRequested the number of TaskManagers being requested by the JobManager\n * @return a list of Uuids to be used by the calling JobManager as TaskManagers\n * @throws RemoteException\n */\n List<Uuid> getTaskManagers(int numRequested) throws RemoteException;\n}",
"protected EscidocAuthenticationProvider() {\r\n }",
"public interface OServerAware {\n\n void init(OServer server);\n\n void coordinatedRequest(\n OClientConnection connection, int requestType, int clientTxId, OChannelBinary channel)\n throws IOException;\n\n ODistributedServerManager getDistributedManager();\n}",
"public OwNetworkContext getContext();",
"interface ResourceManager {\r\n\r\n /**\r\n * List all available resources.\r\n * @return A list of Resource objects\r\n */\r\n public List<Resource> getAvailableResources();\r\n \r\n /**\r\n * Attempt to use the user credentials to log in to \r\n * any and all other resources known to this User Manager.\r\n * \r\n * TODO Consider moving to OAuth.\r\n * @param user the user object\r\n * @param password The users password, in clear text.\r\n */\r\n public void propagateCredentials( User user, String password );\r\n\r\n}",
"public abstract I_Authenticate getSecurityCtx();",
"public interface IRCUser\n{\n public String getNick();\n\n public String getLogin();\n\n public String getHost();\n}",
"public interface VirtualisedNetworkResourceManagementInterface {\n\n /**\n * This operation allows an authorized consumer functional block to request the allocation of\n * virtualised network resources as indicated by the consumer functional block.\n *\n * @param allocateNetworkRequest\n * @return allocateNetworkResponse\n */\n AllocateNetworkResponse allocateVirtualisedNetworkResource(\n AllocateNetworkRequest allocateNetworkRequest, PoP poP) throws AdapterException;\n\n /**\n * This operation allows querying information about instantiated virtualised network resources.\n *\n * @param queryNetworkRequest\n * @return queryNetworkResponse\n */\n QueryNetworkResponse queryVirtualisedNetworkResource(\n QueryNetworkRequest queryNetworkRequest, PoP poP) throws AdapterException;\n\n /**\n * This operation allows updating the information of an instantiated virtualised network resource.\n *\n * @param updateNetworkRequest\n * @return updateNetworkResponse\n */\n UpdateNetworkResponse updateVirtualisedNetworkResource(\n UpdateNetworkRequest updateNetworkRequest, PoP poP);\n\n /**\n * This operation allows de-allocating and terminating one or more instantiated virtualised\n * network resource(s). When the operation is done on multiple ids, it is assumed to be\n * best-effort, i.e. it can succeed for a subset of the ids, and fail for the remaining ones.\n *\n * @param terminateNetworkRequest\n * @return terminateNetworkResponse\n */\n TerminateNetworkResponse terminateVirtualisedNetworkResource(\n TerminateNetworkRequest terminateNetworkRequest, PoP poP) throws AdapterException;\n}",
"public interface IHttpEngine {\n // get请求\n void get(Context context, String url, Map<String,Object> params,EngineCallBack callBack);\n\n // post请求\n void post(Context context,String url,Map<String,Object> params,EngineCallBack callBack);\n\n // 下载文件\n\n\n // 上传文件\n\n\n // https 添加证书\n}",
"@Override\n protected VmNetworkInterfaceDAO getVmNetworkInterfaceDAO() {\n return super.getVmNetworkInterfaceDAO();\n }",
"public RMIClient() {\n if(ipAdress == null){\n ipAdress = \"127.0.0.1\";\n }\n try {\n loginRegistry = LocateRegistry.getRegistry(ipAdress, 421);\n mainScreenRegistry = LocateRegistry.getRegistry(ipAdress, 422);\n } catch (RemoteException ex) {\n StageController.getInstance().popup(\"Server connection\", false, \"server connection failed.\");\n Logger.getLogger(RMIClient.class.getName()).log(Level.SEVERE, null, ex);\n }\n\n if (loginRegistry != null) {\n try {\n loginProvider = (ILoginProvider) loginRegistry.lookup(\"loginProvider\");\n } catch (RemoteException | NotBoundException ex) {\n StageController.getInstance().popup(\"Server connection\", false, \"server connection failed.\");\n Logger.getLogger(RMIClient.class.getName()).log(Level.SEVERE, null, ex);\n }\n }\n if (mainScreenRegistry != null) {\n try {\n mainScreenProvider = (IMainScreenProvider) mainScreenRegistry.lookup(\"mainScreenProvider\");\n } catch (RemoteException | NotBoundException ex) {\n StageController.getInstance().popup(\"Server connection\", false, \"server connection failed.\");\n Logger.getLogger(RMIClient.class.getName()).log(Level.SEVERE, null, ex);\n }\n }\n }",
"@RemoteServiceRelativePath(\"user\")\npublic interface Login extends RemoteService {\n public Pair<UserSession, String> getUserSession(String browserUrl);\n\n public Group[] getGroups(User user);\n\n void createNewMember(User user, Contact profile/*, Group[] groups*/);\n\n List<Payee> getPayeesForGroup(Serializable serializable);\n\n Payee addPayeeForGroup(Payee payee, Group group);\n\n void addGroup(User user, Group group);\n\n void deleteGroup(User user, Group group);\n\n void inviteUserToGroup(User user, Group group, String emailAddress);\n\n void createShare(Membership membership, Share.ShareType shareType, Float amount);\n\n Share[] getShares(Group group);\n\n Boolean createSharesFromInvite(User user, String invKey);\n\n Membership assignMembership(User to, User from, Group group);\n}",
"public interface IMcuContract {\n interface IView extends ImpBaseView{\n void loginRes(Type type);\n }\n interface IPresenter extends ImpBasePresenter{\n IPresenter initURL(Context c, String ip, int port, boolean isSSL);\n void login(String account,String pwd);\n }\n}",
"public AuthorizationManager() throws Exception {\n\t\tNCIASecurityManager mgr = (NCIASecurityManager)SpringApplicationContext.getBean(\"nciaSecurityManager\");\n securityRights = mgr.getSecurityMapForPublicRole();\n }",
"public interface IcsHmiPortalInterface {\r\n\t\r\n\t/** The HMI application(s) will call this method in order to receive incoming\r\n\t * Objects and notifications from the IcsDirector.\r\n\t * \r\n\t * @param listener The listener that will be registered.\r\n\t */\r\n\tpublic void addDirectorToHmiEventListener( DirectorToHmiEventListener listener );\r\n\t\r\n\t/** The HMI application will use this method to send a text message to Choeo. \r\n\t * \r\n\t * @param jsonTextMessage\r\n\t * \r\n\t * @return <code>true</code> if the json oject was decoded successfully and the text message\r\n\t * has been queued to be sent to Choreo.\r\n\t */\r\n\tpublic boolean sendTextMessageToChoreo( String jsonTextMessage );\r\n\t\r\n\t/** Inform the director that the specified message has been viewed by the driver.\r\n\t * \r\n\t * @param messageId The id of the message that was viewed.\r\n\t * @return <code>true</code> if the specified message id is associated with a received text message. If the \r\n\t * message id doesn't match a received message in the datbase <code>false</code> will be returned instead.\r\n\t */\r\n\tpublic boolean setMessageIsReadStatus( long messageId );\r\n\r\n\t/** Request the director to validate the given PIN code. If the PIN is valid, the \r\n\t * Director will notify the OBU that a valid PIN was entered on the touchscreen. \r\n\t * This may not result in a valid logon if the OBU has already validated a logon source\r\n\t * With a higher order of precedence (i.e. DTCO card). The HMI should not consider \r\n\t * that a logon exists until it receives the ObuLogonEvent object.\r\n\t * \r\n\t * @param pin The PIN code to be validated.\r\n\t * @return <code>true</code> if the PIN is valid. <code>false</code> otherwise.\r\n\t */\r\n\tpublic boolean validatePin( String pin );\r\n\t\r\n\t/** The End User License Agreement (EULA) has been accepted by the specified driver. The Director \r\n\t * will update the database with this information so that the EULA will not need to be shown to \r\n\t * this driver in the future.\r\n\t * \r\n\t * @param driverIdType The type associated with the currently logged on driver.\r\n\t * @param driverId The identifier string associated with the currently logged on driver.\r\n\t * @return <code>true</code> if the EULA was previously accepted by the specified driver. <code>false</code> otherwise.\r\n\t */\r\n\tpublic boolean eulaIsAcceptedBy( byte driverIdType, String driverId );\r\n\t\r\n\t/** Get the configuration object for the specified driver. The configuration information will be fetched via\r\n\t * the data broker if there is existing configuration information for the specified driver.\r\n\t * \r\n\t * @param driverIdType The type associated with the currently logged on driver.\r\n\t * @param driverId The identifier string associated with the currently logged on driver.\r\n\t * @return The object that contains the specified drivers configuration info. If there is no existing confiuration\r\n\t * for the requested driver then null will be returned.\r\n\t */\r\n\tpublic DriverConfiguration getDriverConfiguration( byte driverIdType, String driverId );\r\n\r\n\t/** Store a driver's configuration information. This will be written to persistant storage by the data broker.\r\n\t * \r\n\t * @param driverIdType The type associated with the currently logged on driver.\r\n\t * @param driverId The identifier string associated with the currently logged on driver.\r\n\t * @param configuration The configuration data to store and associate with the specified driver.\r\n\t * @return\r\n\t */\r\n\tpublic boolean setDriverConfiguration( byte driverIdType, String driverId, DriverConfiguration configuration );\r\n\t\r\n\t/** Return the content of a pre-defined text message in the specified language. \r\n\t * \r\n\t * @param language The language as ISO 639-2 requested for the pre-defined message. \r\n\t * @param preDefindeMsgId The pre-defined or \"Standard message\" identifier (Currently\r\n\t * \t\t there are 5 pre-defined messages defined ). \r\n\t * @return A string which contains the content of the pre-defined messaged in the specified language.\r\n\t */\r\n\tpublic String getPredefinedTextMessage( String language, int preDefindeMsgId );\r\n\t\r\n\t\r\n\tpublic static final int DRIVING_TIP_CATEGORY_SCORE = 1;\r\n\tpublic static final int DRIVING_TIP_CATEGORY_IDLING = 2; /// catagory representing vehicle idle time.\r\n\tpublic static final int DRIVING_TIP_CATEGORY_OVER_REV = 3;\r\n\tpublic static final int DRIVING_TIP_CATEGORY_HARSH_THROTTLE = 4;\r\n\tpublic static final int DRIVING_TIP_CATEGORY_BRAKING = 5;\r\n\tpublic static final int DRIVING_TIP_CATEGORY_CRUISE_CONTROL = 6;\r\n\tpublic static final int DRIVING_TIP_CATEGORY_COASTING = 7;\r\n\tpublic static final int DRIVING_TIP_LEVEL_NEEDS_IMPROVEMENT = 1;\r\n\tpublic static final int DRIVING_TIP_LEVEL_MEETS_TARGET = 2;\r\n\tpublic static final int DRIVING_TIP_LEVEL_GOOD_JOB = 3;\r\n\t\r\n\r\n\t/** Get a driving tip for the specified category, language, and level. \r\n\t *\r\n\t * @param category The category of driving tip desired. Should be one of {@code DRIVING_TIP_CATEGORY_SCORE \r\n\t * DRIVING_TIP_CATEGORY_IDLING, DRIVING_TIP_CATEGORY_OVER_REV, DRIVING_TIP_CATEGORY_HARSH_THROTTLE, \r\n\t * DRIVING_TIP_CATEGORY_CRUISE_CONTROL DRIVING_TIP_CATEGORY_COASTING}\r\n\t * @param language The desired language for the requested tip.\r\n\t * @param level An indication of how the results of the given shift compare against the targets. This will \r\n\t * help select a more appropriate tip to suit the specific condition. \r\n\t * @return A driving tip for the selected category in the selected language. The tip will be relevant to the category and the driver's current score against targets.\r\n\t * \r\n\t */\r\n\tpublic String getDrivingTip( int category, String language, int level );\r\n\t\r\n\t/** Fetch all messages for this vehicle and also those addressed to the driver that is currently logged on to the ICS.\r\n\t * The messages will be returned as an array of JSON Text Message objects that are sorted by date in descending order.\r\n\t * \r\n\t * @return A string containing an array of JSON TextMessage objects. If no messages are found addressed to the vehicle or current driver null will be returned.\r\n\t */\r\n\tpublic String getTextMessagesForVehicleAndCurrentDriver();\r\n}",
"public interface SecurityService\r\n{\r\n\t/**\r\n\t * This method return true if the given 'securityToken' is a valid token for the given security service. The security service can be any service\r\n\t * such as OAuth, LDAP, ActiveDirectory, OpenID etc. It is up to the implementor of this interface to interact with the appropriate security\r\n\t * service to determine if the given securityToken is valid. Reasons for a token to not be valid include but are not limited to, expired tokens, \r\n\t * incorrect tokens, not authenticated tokens etc.<br/>\r\n\t * This method will be used by the provider in a DIRECT environment to authenticate/validate a consumer.\r\n\t * \r\n\t * @param securityToken The token that shall be validated against a given security service such as LDAP, OAuth, Active Directory, etc.\r\n\t * @param requestMetadata Metadata that has been sourced from a request. The environmentID property is always null because the token is\r\n * not yet authenticated and therefore the environment is not yet determined. \r\n\t * \r\n\t * @return TRUE if the token is known and valid to the security server and not expired. If a token is expired then FALSE should be returned.\r\n\t */\r\n\tpublic boolean validate(String securityToken, RequestMetadata requestMetadata);\r\n\r\n\t/**\r\n\t * This method may contact the security server which can be an OAuth server, and LDAP server a Active Directory etc. In return it will provide \r\n\t * information that relate to the securityToken such as: <br/>\r\n\t * a) Information about the application and/or user of that securityToken (appUserInfo property populated in the TokenInfo) or<br/>\r\n\t * b) Information about the SIF environment or SIF session the securityToken relates to. This would be the case for already existing SIF\r\n\t * Environments.<br/>\r\n\t * Further an expire date might be set for the securityToken if the token has expired. If the securityToken does not expire then the \r\n\t * expire date is null in the returned TokenInfo object.<br/>\r\n * This method will be used by the provider in a DIRECT environment to get information about a consumer's security token.\r\n\t * \r\n\t * @param securityToken The security token for which the TokenInfo shall be returned.\r\n\t * @param requestMetadata Metadata that has been sourced from a request. The environmentID property is always null because the token is\r\n * not yet authenticated and therefore the environment is not yet determined. \r\n\t * \r\n\t * @return See Desc. It is expected that this method only returns either the environmentKey or the SIF environment ID or the SIF session token but\r\n\t * not all of these at the same time.\r\n\t */\r\n\tpublic TokenInfo getInfo(String securityToken, RequestMetadata requestMetadata);\r\n\t\r\n\t/**\r\n\t * This method may contact the security server which can be an OAuth server, and LDAP server a Active Directory etc. to generate a \r\n\t * security token based on the given 'coreInfo'. It is expected that any consumer or a provider in a BROKERED environment calls this \r\n\t * method to retrieve a security token which it will use as the authorisation token in all SIF requests to a provider or broker.\r\n\t * \r\n\t * @param coreInfo Information about the consumer/provider that might be used to generate a security token by the external security service.\r\n\t * In most cases it would at least need the application key.\r\n\t * @param password It is very likely that some sort of password will be required to generate a security token.\r\n\t * \r\n\t * @return A TokenInfo object which will have the 'token' property set (the security token). Optional the 'tokenExpiryDate' may be set\r\n\t * if the token has an expire date. If the 'tokenExpiryDate' is null it is assumed that the returned security token won't expire.\r\n\t * The returned token should only be a token without any authentication method as a prefix. For example the token may be\r\n\t * \"ZjI2NThiNTktNDM1Yi00YThkLTlmNzYtYzI0MDBiNjY1NWMxOlBhc3N3b3JkMQ\". It should not hold the authentication method such as 'Bearer'\r\n\t * (i.e. not look like this: \"Bearer ZjI2NThiNTktNDM1Yi00YThkLTlmNzYtYzI0MDBiNjY1NWMxOlBhc3N3b3JkMQ\"). The SIF3 Framework will\r\n\t * manage the authentication method.\r\n\t */\r\n\tpublic TokenInfo createToken(TokenCoreInfo coreInfo, String password);\r\n}",
"public interface ConnectionExchangeInterface\n{\n\n /*\n * The Connection entity is the top level element to describe the information needed to create a connector to an asset.\n */\n\n /**\n * Create a new metadata element to represent the connection.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this element\n * @param externalIdentifierProperties optional properties used to define an external identifier\n * @param connectionProperties properties to store\n *\n * @return unique identifier of the new metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n String createConnection(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n ExternalIdentifierProperties externalIdentifierProperties,\n ConnectionProperties connectionProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Create a new metadata element to represent a connection using an existing metadata element as a template.\n * The template defines additional classifications and relationships that should be added to the new asset.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this element\n * @param externalIdentifierProperties optional properties used to define an external identifier\n * @param templateGUID unique identifier of the metadata element to copy\n * @param templateProperties properties that override the template\n *\n * @return unique identifier of the new metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n String createConnectionFromTemplate(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String templateGUID,\n ExternalIdentifierProperties externalIdentifierProperties,\n TemplateProperties templateProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Update the metadata element representing a connection.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectionGUID unique identifier of the metadata element to update\n * @param connectionExternalIdentifier unique identifier of the connection in the external asset manager\n * @param isMergeUpdate should the new properties be merged with existing properties (true) or completely replace them (false)?\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n * @param connectionProperties new properties for this element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void updateConnection(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectionGUID,\n String connectionExternalIdentifier,\n boolean isMergeUpdate,\n ConnectionProperties connectionProperties,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Create a relationship between a connection and a connector type.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this relationship\n * @param connectionGUID unique identifier of the connection in the external asset manager\n * @param connectorTypeGUID unique identifier of the connector type in the external asset manager\n * @param effectiveFrom the date when this element is active - null for active now\n * @param effectiveTo the date when this element becomes inactive - null for active until deleted\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void setupConnectorType(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String connectionGUID,\n String connectorTypeGUID,\n Date effectiveFrom,\n Date effectiveTo,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Remove a relationship between a connection and a connector type.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectionGUID unique identifier of the connection in the external asset manager\n * @param connectorTypeGUID unique identifier of the connector type in the external asset manager\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void clearConnectorType(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectionGUID,\n String connectorTypeGUID,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Create a relationship between a connection and an endpoint.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this relationship\n * @param connectionGUID unique identifier of the connection in the external asset manager\n * @param endpointGUID unique identifier of the endpoint in the external asset manager\n * @param effectiveFrom the date when this element is active - null for active now\n * @param effectiveTo the date when this element becomes inactive - null for active until deleted\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void setupEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String connectionGUID,\n String endpointGUID,\n Date effectiveFrom,\n Date effectiveTo,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Remove a relationship between a connection and an endpoint.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectionGUID unique identifier of the connection in the external asset manager\n * @param endpointGUID unique identifier of the endpoint in the external asset manager\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void clearEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectionGUID,\n String endpointGUID,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Create a relationship between a virtual connection and an embedded connection.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this relationship\n * @param connectionGUID unique identifier of the virtual connection in the external asset manager\n * @param properties properties describing how to use the embedded connection such as: Which order should this connection be processed;\n * What additional properties should be passed to the embedded connector via the configuration properties;\n * What does this connector signify?\n * @param embeddedConnectionGUID unique identifier of the embedded connection in the external asset manager\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void setupEmbeddedConnection(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String connectionGUID,\n String embeddedConnectionGUID,\n EmbeddedConnectionProperties properties,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Remove a relationship between a virtual connection and an embedded connection.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectionGUID unique identifier of the virtual connection in the external asset manager\n * @param embeddedConnectionGUID unique identifier of the embedded connection in the external asset manager\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void clearEmbeddedConnection(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectionGUID,\n String embeddedConnectionGUID,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Create a relationship between an asset and its connection.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this relationship\n * @param assetGUID unique identifier of the asset\n * @param connectionGUID unique identifier of the connection\n * @param properties summary of the asset that is stored in the relationship between the asset and the connection.\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void setupAssetConnection(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String assetGUID,\n String connectionGUID,\n AssetConnectionProperties properties,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Remove a relationship between an asset and its connection.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetGUID unique identifier of the asset\n * @param connectionGUID unique identifier of the connection\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void clearAssetConnection(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String assetGUID,\n String connectionGUID,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Remove the metadata element representing a connection. This will delete all anchored\n * elements such as comments.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectionGUID unique identifier of the metadata element to remove\n * @param connectionExternalIdentifier unique identifier of the connection in the external asset manager\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void removeConnection(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectionGUID,\n String connectionExternalIdentifier,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of asset metadata elements that contain the search string.\n * The search string is treated as a regular expression.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param searchString string to find in the properties\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<ConnectionElement> findConnections(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String searchString,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of asset metadata elements with a matching qualified or display name.\n * There are no wildcards supported on this request.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param name name to search for\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<ConnectionElement> getConnectionsByName(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String name,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of assets created on behalf of the named asset manager.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<ConnectionElement> getConnectionsForAssetManager(String userId,\n String assetManagerGUID,\n String assetManagerName,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the connection metadata element with the supplied unique identifier.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectionGUID unique identifier of the requested metadata element\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return matching metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n ConnectionElement getConnectionByGUID(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectionGUID,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /*\n * The Endpoint entity describes the location of the resource.\n */\n\n /**\n * Create a new metadata element to represent the endpoint.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this element\n * @param externalIdentifierProperties optional properties used to define an external identifier\n * @param endpointProperties properties to store\n *\n * @return unique identifier of the new metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n String createEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n ExternalIdentifierProperties externalIdentifierProperties,\n EndpointProperties endpointProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Create a new metadata element to represent an endpoint using an existing metadata element as a template.\n * The template defines additional classifications and relationships that should be added to the new endpoint.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this element\n * @param externalIdentifierProperties optional properties used to define an external identifier\n * @param templateGUID unique identifier of the metadata element to copy\n * @param templateProperties properties that override the template\n *\n * @return unique identifier of the new metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n String createEndpointFromTemplate(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String templateGUID,\n ExternalIdentifierProperties externalIdentifierProperties,\n TemplateProperties templateProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Update the metadata element representing an endpoint.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param endpointGUID unique identifier of the metadata element to update\n * @param endpointExternalIdentifier unique identifier of the endpoint in the external asset manager\n * @param isMergeUpdate should the new properties be merged with existing properties (true) or completely replace them (false)?\n * @param endpointProperties new properties for this element\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void updateEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String endpointGUID,\n String endpointExternalIdentifier,\n boolean isMergeUpdate,\n EndpointProperties endpointProperties,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Remove the metadata element representing an endpoint. This will delete the endpoint and all categories\n * and terms.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param endpointGUID unique identifier of the metadata element to remove\n * @param endpointExternalIdentifier unique identifier of the endpoint in the external asset manager\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void removeEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String endpointGUID,\n String endpointExternalIdentifier,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of endpoint metadata elements that contain the search string.\n * The search string is treated as a regular expression.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param searchString string to find in the properties\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<EndpointElement> findEndpoints(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String searchString,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of endpoint metadata elements with a matching qualified or display name.\n * There are no wildcards supported on this request.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param name name to search for\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<EndpointElement> getEndpointsByName(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String name,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of glossaries created on behalf of the named asset manager.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<EndpointElement> getEndpointsForAssetManager(String userId,\n String assetManagerGUID,\n String assetManagerName,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the endpoint metadata element with the supplied unique identifier.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param endpointGUID unique identifier of the requested metadata element\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return matching metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n EndpointElement getEndpointByGUID(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String endpointGUID,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n\n /*\n * The ConnectorType entity describes a specific connector implementation.\n */\n\n\n /**\n * Create a new metadata element to represent the root of a connectorType.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this element\n * @param externalIdentifierProperties optional properties used to define an external identifier\n * @param connectorTypeProperties properties to store\n *\n * @return unique identifier of the new metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n String createConnectorType(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n ExternalIdentifierProperties externalIdentifierProperties,\n ConnectorTypeProperties connectorTypeProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Create a new metadata element to represent a connectorType using an existing metadata element as a template.\n * The template defines additional classifications and relationships that should be added to the new connectorType.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param assetManagerIsHome ensure that only the asset manager can update this element\n * @param externalIdentifierProperties optional properties used to define an external identifier\n * @param templateGUID unique identifier of the metadata element to copy\n * @param templateProperties properties that override the template\n *\n * @return unique identifier of the new metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n String createConnectorTypeFromTemplate(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String templateGUID,\n ExternalIdentifierProperties externalIdentifierProperties,\n TemplateProperties templateProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Update the metadata element representing a connectorType.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectorTypeGUID unique identifier of the metadata element to update\n * @param connectorTypeExternalIdentifier unique identifier of the connectorType in the external asset manager\n * @param isMergeUpdate should the new properties be merged with existing properties (true) or completely replace them (false)?\n * @param connectorTypeProperties new properties for this element\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void updateConnectorType(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectorTypeGUID,\n String connectorTypeExternalIdentifier,\n boolean isMergeUpdate,\n ConnectorTypeProperties connectorTypeProperties,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Remove the metadata element representing a connectorType. This will delete the connectorType and all categories\n * and terms.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param connectorTypeGUID unique identifier of the metadata element to remove\n * @param connectorTypeExternalIdentifier unique identifier of the connectorType in the external asset manager\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n void removeConnectorType(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String connectorTypeGUID,\n String connectorTypeExternalIdentifier,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of connectorType metadata elements that contain the search string.\n * The search string is treated as a regular expression.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param searchString string to find in the properties\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<ConnectorTypeElement> findConnectorTypes(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String searchString,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of connectorType metadata elements with a matching qualified or display name.\n * There are no wildcards supported on this request.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param name name to search for\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<ConnectorTypeElement> getConnectorTypesByName(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String name,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the list of glossaries created on behalf of the named asset manager.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param startFrom paging start point\n * @param pageSize maximum results that can be returned\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return list of matching metadata elements\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n List<ConnectorTypeElement> getConnectorTypesForAssetManager(String userId,\n String assetManagerGUID,\n String assetManagerName,\n int startFrom,\n int pageSize,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n\n\n /**\n * Retrieve the connectorType metadata element with the supplied unique identifier.\n *\n * @param userId calling user\n * @param assetManagerGUID unique identifier of software capability representing the caller\n * @param assetManagerName unique name of software capability representing the caller\n * @param openMetadataGUID unique identifier of the requested metadata element\n * @param effectiveTime when should the elements be effected for - null is anytime; new Date() is now\n * @param forLineage return elements marked with the Memento classification?\n * @param forDuplicateProcessing do not merge elements marked as duplicates?\n *\n * @return matching metadata element\n *\n * @throws InvalidParameterException one of the parameters is invalid\n * @throws UserNotAuthorizedException the user is not authorized to issue this request\n * @throws PropertyServerException there is a problem reported in the open metadata server(s)\n */\n ConnectorTypeElement getConnectorTypeByGUID(String userId,\n String assetManagerGUID,\n String assetManagerName,\n String openMetadataGUID,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;\n}",
"public interface Authentication extends Component {\n /**\n * Given an incoming HTTP request, determine who the user is and create a UserPermissions object with that\n * information. If the user cannot be identified and/or authenticated, don't set those attributes and throw an\n * exception. Otherwise return a UserPermissions object.\n */\n UserPermissions authenticate (Request request);\n}",
"protected OAuthProvider getOAuthProvider() {\r\n \tOAuthProvider provider = new CommonsHttpOAuthProvider(MendeleyApiUrls.OAuthUrls.REQUEST_TOKEN_URL,\r\n \t\t\tMendeleyApiUrls.OAuthUrls.ACCESS_TOKEN_URL, MendeleyApiUrls.OAuthUrls.AUTHORIZE_URL);\r\n \t\r\n \tprovider.setOAuth10a(true);\r\n// for (String headerName : requestHeaders.keySet()) {\r\n// \tprovider.setRequestHeader(headerName, requestHeaders.get(headerName));\r\n// }\r\n \t\r\n \treturn provider;\r\n\t}",
"public interface LdapConnectionManager {\n\n /**\n * Initializes an instance for use, typically by digesting the contents of the\n * assigned {@link LdapConnectionManagerConfig}.\n */\n // public void init() throws LdapException;\n\n /**\n * Retrieve an <code>LDAPConnection</code> -- the connection may already be\n * bound depending on the configuration\n *\n * @return a connected <code>LDAPConnection</code>\n * @throws LDAPException\n * if the <code>LDAPConnection</code> allocation fails\n */\n public LDAPConnection getConnection() throws LdapException;\n\n\t/**\n\t * Retrieve a bound <code>LDAPConnection</code> using the indicated credentials\n\t * @param dn the distringuished name for binding\n\t * @param pw the password for binding\n\t * @return a connected <code>LDAPConnection</code>\n\t * @throws LDAPException if the <code>LDAPConnection</code> allocation fails\n\t */\n public LDAPConnection getBoundConnection() throws LdapException;\n\n\t/**\n\t * Return an <code>LDAPConnection</code>. This can allow for\n\t * connections to be pooled instead of just destroyed.\n\t * @param conn an <code>LDAPConnection</code> that you no longer need\n\t */\n\tpublic void returnConnection(LDAPConnection conn);\n\n\t/**\n\t * Assign the LDAPConnection management configuration.\n\t * Should typically be invoked once and followed by a\n\t * call to init().\n\t * @param config a reference to a {@link LdapConnectionManagerConfig}. Should be cacheable without defensive copying.\n\t */\n\tpublic void setConfig(LdapConnectionManagerConfig config);\n\n\t/**\n\t * Retrieve the currently assigned {@link LdapConnectionManagerConfig}.\n\t * @return the currently assigned {@link LdapConnectionManagerConfig}, if any\n\t */\n\tpublic LdapConnectionManagerConfig getConfig();\n\n /**\n * Shuts down an instance.\n */\n public void destroy();\n}",
"public interface AccessTokenService extends Managed{\n public UserSession createAccessToken(UserSession userSession);\n\n public UserSession getUserFromAccessToken(String accessToken);\n\n public boolean isValidToken(String accessToken);\n\n public void removeAccessToken(String accessToken);\n\n public void removeUser(String userName);\n\n}",
"@Local\npublic interface HandleUser {\n\n /**\n * Method that check the user credential and return the id of the logged\n * user otherwise throw an exception to signal an error in the\n * authentication phase.\n *\n * @param username Username of the user\n * @param password Password of the user\n * @return id of the logged user\n * @throws ErrorRequestException expection throw if errors in the\n * authentication phase\n */\n long checkAccessCredential(String username, String password)\n throws ErrorRequestException;\n\n /**\n * Method that find and return the data of the user id passed via parameter.\n *\n * @param userID id of the user connected to MeteoCal\n * @return UserDTO the user data object\n * @throws ErrorRequestException if there is a problem retriving the user\n * info\n */\n UserDTO getUser(long userID)\n throws ErrorRequestException;\n\n /**\n * Method that add a new user to the MeteoCal application\n *\n * @param newUser the new user to add in MeteoCal\n * @throws ErrorRequestException\n */\n void addUser(UserDTO newUser) throws ErrorRequestException;\n\n /**\n * Method that handle the login of the user in MeteoCal\n *\n * @param loginUser the user that whant to login in MeteoCal\n * @return true if the login process was succesful; false otherwise.\n */\n boolean doLogin(UserDTO loginUser);\n\n /**\n * Method that return the owner of a calendar\n *\n * @param calendarId the calendar id of the user returned\n * @return the owner of the calendar; null otherwise;\n */\n UserDTO getOwner(String calendarId);\n\n /**\n * Method that search the user with a PUBLIC Calendar that match the given\n * query\n *\n * @param query\n * @return the list of the result that match the query\n */\n List<ResultDTO> search(String query);\n\n /**\n * Method that search the user that match the given query\n *\n * @param query\n * @return the list of the result that match the query\n */\n List<ResultDTO> searchUser(String query);\n\n /**\n * Method that change the user settings\n *\n * @param loggedUser the user with the new settings\n * @throws ErrorRequestException\n */\n void changeSettings(UserDTO loggedUser) throws ErrorRequestException;\n\n /**\n * Method that return the visibility of the given calendar id\n *\n * @param calendarId\n * @return Visibility.PUBLIC or Visibility.PRIVATE for the given calendarId\n * @throws it.polimi.meteocal.exception.ErrorRequestException\n */\n Visibility getCalendarVisibility(String calendarId) throws ErrorRequestException;\n\n /**\n * Method that change the calendar visibility of the current logged user\n *\n * @param visibility the wanted visibility for the current logged calendar\n * user\n * @throws it.polimi.meteocal.exception.ErrorRequestException\n */\n void changeCalendarVisibility(Visibility visibility) throws ErrorRequestException;\n\n /**\n * Method that save the notification in the DB\n *\n * @param notification the notification to save in the DB\n * @return true if the notification is added, false otherwise\n */\n boolean addNotification(EventNotificationDTO notification);\n\n /**\n * Method that handle the user accepts to a notification\n *\n * @param selectedNotification the notification that the user have accepted\n */\n void acceptNotification(NotificationDTO selectedNotification);\n\n /**\n * Method that handle the user declines to a notification\n *\n * @param selectedNotification the notification that the user have declined\n */\n void declineNotification(NotificationDTO selectedNotification);\n\n /**\n * Method that add the calendar to the logged user prefered\n *\n * @param calendarId the id of the prefered calendar to add\n */\n void addPreferedCalendar(String calendarId);\n\n /**\n * Method that remove the calendar from the logged user prefered\n *\n * @param calendarId the id of the prefered calendar to remove\n */\n void delPreferedCalendar(String calendarId);\n\n /**\n * Method that remove outdated notification from the user that refers to\n * passed event\n */\n void removeOldNotification();\n\n}",
"protected String getAuthority() {\n return \"com.activeharmony.content.ContentProvider\";\n }",
"public interface CloudServiceImpl {\n\n /**\n * This method provides an implementation of distributed map. All the nodes\n * on the cluster shares this instance.\n * @param mapName Name of the map.\n * @param <K> Type of the map's key.\n * @param <V> Type of the map's values.\n * @return Return the instance of the distributed map.\n */\n <K extends Object, V extends Object> Map<K, V> getMap(String mapName);\n\n /**\n * This method provides an implementation of distributed queue. All the nodes\n * on the cluster shares this instance.\n * @param queueName Name of the queue.\n * @param <V> Type of the queue's values.\n * @return Return the instance of the distributed queue.\n */\n <V extends Object> Queue<V> getQueue(String queueName);\n\n /**\n * This method provides an implementation of distributed set. All the nodes\n * on the cloud shares this instance.\n * @param setName Name of the set.\n * @param <V> Type of the set's values.\n * @return Return the instance of the distributed set.\n */\n <V extends Object> Set<V> getSet(String setName);\n\n /**\n * This method provides an implementation of distributed counter. All the nodes\n * on the cloud shares this instance.\n * @param counterName Name of the counter.\n * @return Return thr instance of the counter.\n */\n Counter getCounter(String counterName);\n\n /**\n * This method takes a resource an lock this for all the thread around the cluster\n * and this resource has locked for all the thread for execution.\n * This method is blocked until you can get the lock.\n * @param resourceName The name of the resource to lock.\n * @throws InterruptedException Interrupted exception\n */\n void lock(String resourceName) throws InterruptedException;\n\n /**\n * This method unlocks a previously locked resource.\n * @param resourceName The name of the resource locked.\n * @throws InterruptedException Interrupted exception.\n */\n void unlock(String resourceName) throws InterruptedException;\n\n /**\n * Return the implementation of the Lock interface distributed.\n * @param lockName Name of the lock.\n * @return Distributed lock implementation.\n */\n Lock getLock(String lockName);\n\n /**\n * Return the distributed lock condition over specific lock object.\n * @param conditionName Lock condition name.\n * @param lock Specific lock object.\n * @return Return the lock condition.\n */\n Condition getCondition(String conditionName, Lock lock);\n\n /**\n * Creates a instance of cache into the cloud using the specific strategy to\n * specify the behavior of the cache instance.\n * @param cacheName Name of the cache instance.\n * @param strategies Set with the strategies for the cache instance.\n */\n void createCache(String cacheName, Set<CloudCacheStrategy> strategies);\n\n /**\n * Return the instance of cache named with specific name.\n * @param cacheName Name of the instance of cache.\n * @return Instance of cache.\n */\n CloudCache getCache(String cacheName);\n\n /**\n * Dispatch the event instance to the cloud.\n * @param event Event instance.\n */\n void dispatchEvent(DistributedEvent event);\n\n /**\n * Publish a distributed layer into the cloud.\n * @param layerClass Layer class.\n * @param implName Layer implementation name.\n * @param regex Regex for match the implementation.\n */\n void publishDistributedLayer(Class<? extends LayerInterface> layerClass, String implName, String regex);\n\n /**\n * This method send the plugin for all the nodes into the cloud.\n * @param jarFile Byte array that represents the jar file.\n */\n void publishPlugin(byte[] jarFile);\n\n /**\n * This method verifies if the layer and name indicated are published into the cloud.\n * @param layerClass Layer class.\n * @param implName Layer implementation name.\n * @return Returns true if the layer is published and false in the otherwise.\n */\n boolean isLayerPublished(Class<? extends LayerInterface> layerClass, String implName);\n\n /**\n * Returns the object that represent the distributed layer.\n * @param layerClass Layer class.\n * @param implName Layer implementation name.\n * @return Regex if exist or null.\n */\n String getRegexFromDistributedLayer(Class<? extends LayerInterface> layerClass, String implName);\n\n /**\n * Invokes the remote instance of a layer.\n * @param layerClass Layer interface class.\n * @param implName Implementation name.\n * @param method Method to invoke.\n * @param parameters Parameters to invoke.\n * @param <O> Expected return data type.\n * @return Invocation result.\n */\n <O extends Object> O layerInvoke(Class<? extends LayerInterface> layerClass, String implName, Method method, Object... parameters);\n\n /**\n * This method must start the process of interaction with other services.\n */\n void publishMe();\n\n /**\n * This method start a worker over the cloud implementation to make a task and finish.\n * @param workerConfig Map with all the parameters to configure a worker instance.\n */\n void forkWorker(Map<String,Object> workerConfig);\n\n /**\n * Shutdown hook\n */\n void shutdown();\n\n}",
"public interface NetworkInterface {\n\n\t// starting the network on the given port at the localhost\n\tpublic void startNetwork(int port);\n\n\t// stopping the local network\n\tpublic void stopNetwork();\n\t\n\t\n}",
"public static interface Kernel {\n\n\t\t/**\n\t\t* This is an optional way of getting a connection. login with the given Credentials,\n\t\t* and the database file name.\n\t\t*\n\t\t* If valid, this will return a\n\t\t* \t\torg.sqlite.SQLite.SQLite3 pointer (which extends com.sun.jna.PointerType)\n\t\t*\n\t\t* You are not required to use this method to get the pointer, and you can get it directly\n\t\t* from the SQLite layer if you want. Make sure to close it when you are done.\n\t\t*\n\t\t* This will throw an exception if not authorized.\n\t\t*\n\t\t* Why am I passing around pointers? Because this is very low-level code.\n\t\t*/\n\t\tpublic com.sun.jna.PointerType login(Credentials c) throws RelationException;\n\n\t\t/**\n\t\t* close the connection when done. Will throw an exception only if the pointer passed in\n\t\t* is null or if it is not an org.sqlite.SQLite.SQLite3 pointer.\n\t\t*/\n\t\tpublic void close(com.sun.jna.PointerType connection) throws RelationException;\n\n\t\t/**\n\t\t* Get the database file name\n\t\t*/\n\t\tpublic String getDatabaseFileName();\n\n\t\t/**\n\t\t* Get a list of users from the system.\n\t\t* This doesn't require validation, because it is read only data.\n\t\t* I'm not saying that this should be exposed to the outside world, but someone on the \"inside\" can\n\t\t* just read the database directly.\n\t\t*/\n\t\tpublic String[] listUsers();\n\n\t\t/**\n\t\t* validate the user credentials. Returns true if valid, and false if invalid.\n\t\t* It is up to the code here to decide what to do if the credentials are not validated.\n\t\t* Throws an exception only if the database code fails for some other reason. This is so you\n\t\t* can test credentials without an exception being thrown.\n\t\t*/\n\t\tpublic boolean validate(Credentials c) throws RelationException;\n\n\t\t/**\n\t\t* First of all, this does throw an exception if the credentials are invalid. If you are not\n\t\t* sure, use the previous code to test it.\n\t\t*\n\t\t* Second, to make this more confusing, this doesn't actually start a transactions, it collects\n\t\t* metadata about a transaction. This is how you obtain a transaction id. The kernel\n\t\t* will do an insert into the _transaction. It is marked with a timestamp.\n\t\t*\n\t\t* If you use createTransaction() here, you must also call commitTransaction() with more information\n\t\t* when it is commited.\n\t\t*\n\t\t*/\n\t\tpublic long createTransaction(Credentials c, TransactionType tt) throws RelationException;\n\n\t\t/**\n\t\t* This doesn't actually commit the transaction instead it marks it as commited.\n\t\t* So maybe it should say \"markTransactionAsCommitted\"\n\t\t*/\n\t\tpublic void commitTransaction(long id) throws RelationException;\n\n\t\tpublic void rollbackTransaction(long id) throws RelationException;\n\n\t\t/**\n\t\t* This has more information about an accounting transaction.\n\t\t* Date must be in YYYY-MM-DD format\n\t\t* Source is the source journal, like \"General\"\n\t\t* Description is the description of the transaction\n\t\t*/\n\t\tpublic void commitAccountingTransaction(long id,String date,String source,String description) throws RelationException;\n\n\t\t/**\n\t\t* The _master table is an extension of SQLite master. It has the name of the\n\t\t* class that implements Tuple. This is used when retrieving data.\n\t\t*/\n\t\tpublic void insertClassNameIntoMaster(String tableName, String className) throws RelationException;\n\n\t\t//used when dropping a table\n\t\tpublic void deleteClassNameFromMaster(String tableName) throws RelationException;\n\n\t\t//audit\n\t\t//this must be called whenever changes are made to existing data\n\t\tpublic void audit(long oid,String _table,String undo_sql,String new_sql) throws RelationException;\n\t}",
"public interface RealmInformationProvider {\n\n /**\n * Returns the display name of the realm which is visible in the tab list or in the realm overview\n * menu on the lobby. This method is not rate limited.\n *\n * @return the display name of the realm.\n */\n String realmDisplayName();\n\n /**\n * Returns the description of the realm which is visible in the realm overview\n * menu on the lobby. This method is not rate limited.\n *\n * @return the description of the realm.\n */\n String description();\n\n /**\n * @return true if the realm is private, false otherwise\n */\n boolean privateRealm();\n\n /**\n * @return the currently allowed maximum player count\n */\n int maxPlayers();\n\n /**\n * @return the amount of currently active boosts\n */\n int boostCount();\n\n /**\n * Limits are specified by the realm boost level.\n *\n * @return the current realm limits\n */\n Limits limits();\n\n /**\n * The promotion state of the realm. A promoted realm will always be shown first on the lobby's\n * realm overview menu and at the banner stand. Only VIPs and higher are privileged to mark a realm as promoted.\n *\n * <br><br> Since a realm doesn't know it's promotion state, it has to be requested at the Cytooxien Realms\n * Backend Management service. So this method returns an {@link Action} and is rate-limited.\n *\n * @return The action containing information about the promotion state of the realm.\n */\n Action<Boolean> promotedRealm();\n\n /**\n * A realm is able to have it's own address. Using this address, players can directly join onto the running realm\n * without joining on Cytooxien first.\n *\n * <br><br> Since a realm doesn't know it's subdomain, it has to be requested at the Cytooxien Realms\n * Backend Management service. So this method returns an {@link Action} and is rate-limited.\n *\n * @return The action containing the FQDN under which the realm can also be joined.\n */\n Action<String> subdomain();\n\n /**\n * This changes the display name of the realm. The new name of the realm must not exceed 32 characters and mustn't\n * be null or empty. Otherwise this action will fail.\n *\n * <br><br> Since this has to be requested at the Cytooxien Realms\n * Backend Management service, this method returns an {@link Action} and is rate-limited.\n * @param name The new name of the realm\n * @return the action containing the success state\n */\n Action<Void> changeName(String name);\n\n /**\n * This changes the description of the realm. The new description of the realm must not exceed 128 characters otherwise this action will fail.\n *\n * <br><br> Since this has to be requested at the Cytooxien Realms\n * Backend Management service, this method returns an {@link Action} and is rate-limited.\n * @param description The new realm description\n * @return the action containing the success state\n */\n Action<Void> changeDescription(String description);\n\n /**\n * This changes the maximum allowed player count of the realm. The new player count of the realm must\n * not exceed the maximum player count specified by the {@link Limits} object otherwise this action will fail.\n *\n * <br><br> Since this has to be requested at the Cytooxien Realms\n * Backend Management service, this method returns an {@link Action} and is rate-limited.\n *\n * @param maxPlayers The new maximum player count\n * @return the action containing the success state\n */\n Action<Void> updateMaximumPlayers(int maxPlayers);\n\n /**\n * This changes the privacy state of the realm.\n *\n * <br><br> Since this has to be requested at the Cytooxien Realms\n * Backend Management service, this method returns an {@link Action} and is rate-limited.\n *\n * @param privateRealm true if the realm is private false otherwise\n * @return the action containing the success state\n */\n Action<Void> updatePrivacyState(boolean privateRealm);\n\n}",
"public interface LoginService {\n E3Result userLogin(String username, String password);\n}",
"public interface IDataSource {\r\n\t\r\n\t/**\r\n\t * Method to check if there are any stored credential in the data store for the user.\r\n\t * @param userId\r\n\t * @return\r\n\t * @throws IOException\r\n\t */\r\n\tabstract public boolean checkAuth(String userId) throws IOException;\r\n\t\r\n\t/**\r\n\t * Method to build the Uri used to redirect the user to the service provider site to give authorization.\r\n\t * @param userId\r\n\t * @param authCallback callback URL used when the app was registered on the service provider site. Some providers require\r\n\t * to specify it with every request.\r\n\t * @return\r\n\t * @throws IOException\r\n\t */\r\n\tabstract public String buildAuthRequest(String userId, String authCallback) throws IOException;\r\n\t\r\n\t/**\r\n\t * Once the user has authorized the application, the provider redirect it on the app using the callback URL. This method \r\n\t * saves the credentials sent back with the request in the data store.\r\n\t * @param userId\r\n\t * @param params HashMap containing all the parameters of the request\r\n\t * @throws IOException\r\n\t */\r\n\tabstract public void saveAuthResponse(String userId, HashMap<String, String> params) throws IOException;\r\n\t\r\n\t/**\r\n\t * Updates data of a single resource\r\n\t * @param userId\r\n\t * @param name resource name as in the XML config file\r\n\t * @param lastUpdate\r\n\t * @return\r\n\t * @throws IOException\r\n\t */\r\n\tabstract public String updateData(String userId, String resourceName, long lastUpdate) throws IOException;\r\n\t\r\n\t/**\r\n\t * Updates data of all resources\r\n\t * @param userId\r\n\t * @param lastUpdate\r\n\t * @return\r\n\t * @throws IOException\r\n\t */\r\n\tabstract public String[] updateAllData(String userId, long lastUpdate) throws IOException;\r\n\t\r\n}",
"public interface BlockStorageManagementController extends StorageController {\n\n /**\n * Add Storage system to SMIS Provider\n * \n * @param storage : URI of the storage system to add to the providers\n * @param providers : array of URIs where this system must be added\n * @param primaryProvider : indicate if the first provider in the list must\n * be treated as the active provider\n * @throws InternalException\n */\n public void addStorageSystem(URI storage, URI[] providers, boolean primaryProvider, String opId) throws InternalException;\n\n /**\n * Validate storage provider connection.\n * \n * @param ipAddress the ip address\n * @param portNumber the port number\n * @param interfaceType\n * @return true, if successful\n */\n public boolean validateStorageProviderConnection(String ipAddress, Integer portNumber, String interfaceType);\n}",
"public interface CommonService {\n public String getUUID() throws Exception;\n\n public List<NlbsDistributor> selectChildrenListDistributor(String distributorCode) throws Exception;\n\n public List<NlbsUser> selectChildrenListUser(String userCode) throws Exception;\n\n List<Map> queryAllMaterialTypeList() throws Exception;\n\n List<Map> queryAllApplyRecordStatusList() throws Exception;\n\n List<NlbsCity> queryAllCity() throws Exception;\n\n public NlbsUser queryNlbsUserByUserNoIgnoreStatus(String userNo) throws Exception;\n\n public boolean isAdministrator(String userNo, List<String> roleList) throws Exception;\n\n}",
"public interface ProvDomainMgr extends ReqMsgClient\n{\n\n /**\n * Returns the message model type that this domain manager provides. The\n * return value is one of the types defined in\n * {@linkplain com.reuters.rfa.rdm.RDMMsgTypes}.\n * \n * @return the message model type that this domain manager provides.\n */\n short getMsgModelType();\n\n /**\n * Returns the name of service that this domain manager provides.\n * \n * @return the name of service that this domain manager provides.\n */\n String getServiceName();\n\n /**\n * Returns an OMMPool used by this domain manager.\n * \n * @return an OMMPool used by this domain manager.\n */\n OMMPool getPool();\n\n /**\n * Sends an OMM message to a client.\n * \n * @param token the client request token\n * @param encmsg the OMM message to submit\n */\n void submit(Token token, OMMMsg encmsg);\n\n}",
"public interface IServiceAppAuthenticationClient {\n\n\t/**\n\t * This method gets the <strong>App</strong> authenticated by the Service. It uses Kerberos Protocol\n\t * to achieve mutual authentication between the App and the Service \n\t * @param url \n\t * <code>String</code> url of the web service to be invoked to authenticate App Service Ticket\n\t * @param serviceTicket \n\t * <code>ServiceTicket</code> Kerberos Service Ticket required to access the service\n\t * @return\n\t * <code>AppSession</code> \n\t * @throws IOException\n\t * In case there are some errors encountered while retrieving information\n\t * @throws RestClientException\n\t * If the status of the response is not <strong>200</strong>. The server side error message and error \n\t * response code can be accessed using <code>getMessage</code> and <code>getErrorCode</code> methods respectively\n\t * @throws ResponseDecryptionException \n\t * If the Application was unable to decrypt the Response sent by the server\n\t */\n\tAppSession authenticateAppServiceTicket(String url,\n\t\t\tServiceTicket serviceTicket) throws IOException, RestClientException, ResponseDecryptionException;\n\n}",
"private AbstractPhysicalNetwork() {\r\n super(IAbstractPhysicalNetwork.TYPE_ID);\r\n }",
"public void connect() throws IOException {\r\n \t\t \r\n \t\t \tClassLoader saved = Thread.currentThread().getContextClassLoader();\r\n\t\t\ttry {\r\n\t\t\t\t // Parse url (rsuite:/http://host/user/session/moId)\r\n\t\t\t\t log.println(\"INCOMING URL IS: \" + url);\r\n\t\t\t\t log.println(\"PARSING URL TO GET PARAMETERS...\");\r\n\t\t\t\t \r\n\t\t\t\t // url initially comes through with extension to avoid dialog window\r\n\t\t\t\t docURL = RSuiteProtocolUtils.parseRSuiteProtocolURL(url);\r\n\t\t\t\t host = docURL.getHost();\r\n\t\t\t\t protocol = docURL.getProtocol().concat(\"//\");\r\n\t\t\t\t username = docURL.getUserName();\r\n\t\t\t\t sessionKey = docURL.getSessionKey();\r\n\t\t\t\t moId = docURL.getMoId();\r\n\t\t\t\t // set the connection so we have it later\r\n\t\t\t\t _connection = this;\r\n\r\n\t\t\t\t log.println(\"HOST: \" + host);\r\n\t\t\t\t log.println(\"USERNAME: \" + username);\r\n\t\t\t\t log.println(\"SESSION KEY: \" + sessionKey);\r\n\t\t\t\t log.println(\"MOID: \" + moId);\r\n\t\t\t\t \r\n\t\t\t\t Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());\r\n\t\t\t\t \r\n\t\t\t\t // CONNECT TO RSUITE IF SESSION NOT PRESENT\t\t\t\t \r\n\t\t\t\t log.println(\"CONNECTION TO RSUITE...\");\r\n\t\t\t\t if(sessionKey == null){\r\n\t\t\t\t\t log.println(\"SESSION DOES NOT EXIST, PROMPT FOR LOGIN\");\r\n\t\t\t\t\t RSuiteLoginDialog login = new RSuiteLoginDialog();\r\n\t\t\t\t\t login.setLocationRelativeTo(null);\r\n\t\t\t\t\t login.setVisible(true);\r\n\t\t\t\t }\r\n\t\t\t\t \r\n\t\t\t\t // SESSION WAS PASSED IN, INITIALIZE REPOSITORY\r\n\t\t\t\t if(repository == null){\r\n\t\t\t\t\t log.println(\"SESSION PASSED IN BY URL, INITIALIZE REPOSITORY\");\r\n\t\t\t\t\t repository = new RsuiteRepositoryImpl(username, \"\", host);\r\n\t\t\t\t\t log.println(\"REPOSITORY INITIALIZED.\");\r\n\t\t\t\t\t \r\n\t\t\t\t\t // NO NEED TO LOGIN SINCE WE HAVE SESSION KEY ALREADY\r\n\t\t\t\t\t log.println(\"SETTING THE REPOSITORY SESSION KEY...\");\r\n\t\t\t\t\t repository.sessionKey = sessionKey;\r\n\t\t\t\t\t log.println(\"SESSION KEY SET. NO NEED FOR LOGIN\");\r\n\t\t\t\t }\t\t\t\t \r\n\t\t\t}\r\n\t\t\tcatch (Throwable t) {\r\n\t\t\t if (log != null) {\r\n\t\t\t t.printStackTrace(log);\r\n\t\t\t }\r\n\t\t\t}\r\n\t\t\tfinally{\r\n\t\t\t\tThread.currentThread().setContextClassLoader(saved);\r\n\t\t\t}\r\n\t\t}",
"public static void initializeClass() throws Exception {\n\t\tPacketPlayInUseEntity = PacketPlayOut.getNMSClass(\"PacketPlayInUseEntity\");\n\t\tPacketPlayOutEntity = PacketPlayOut.getNMSClass(\"PacketPlayOutEntity\");\n\t\tPacketPlayOutEntityDestroy = PacketPlayOut.getNMSClass(\"PacketPlayOutEntityDestroy\");\n\t\tPacketPlayOutNamedEntitySpawn = PacketPlayOut.getNMSClass(\"PacketPlayOutNamedEntitySpawn\");\n\t\tPacketPlayOutEntityTeleport = PacketPlayOut.getNMSClass(\"PacketPlayOutEntityTeleport\");\n\t\t(PacketPlayOutEntityTeleport_ENTITYID = PacketPlayOutEntityTeleport.getDeclaredField(\"a\")).setAccessible(true);\n\n\t\t(PacketPlayInUseEntity_ENTITY = PacketPlayInUseEntity.getDeclaredField(\"a\")).setAccessible(true);\n\t\t(PacketPlayOutEntity_ENTITYID = PacketPlayOutEntity.getDeclaredField(\"a\")).setAccessible(true);\n\t\t(PacketPlayOutEntityDestroy_ENTITIES = PacketPlayOutEntityDestroy.getDeclaredField(\"a\")).setAccessible(true);\n\t\t(PacketPlayOutNamedEntitySpawn_ENTITYID = PacketPlayOutNamedEntitySpawn.getDeclaredField(\"a\")).setAccessible(true);\n\n\t\tif (ProtocolVersion.SERVER_VERSION.getMinorVersion() >= 9) {\n\t\t\tPacketPlayOutMount = PacketPlayOut.getNMSClass(\"PacketPlayOutMount\");\n\t\t\t(PacketPlayOutMount_VEHICLE = PacketPlayOutMount.getDeclaredField(\"a\")).setAccessible(true);\n\t\t\t(PacketPlayOutMount_PASSENGERS = PacketPlayOutMount.getDeclaredField(\"b\")).setAccessible(true);\n\t\t} else {\n\t\t\tPacketPlayOutAttachEntity = PacketPlayOut.getNMSClass(\"PacketPlayOutAttachEntity\");\n\t\t\t(PacketPlayOutAttachEntity_A = PacketPlayOutAttachEntity.getDeclaredField(\"a\")).setAccessible(true);\n\t\t\t(PacketPlayOutAttachEntity_PASSENGER = PacketPlayOutAttachEntity.getDeclaredField(\"b\")).setAccessible(true);\n\t\t\t(PacketPlayOutAttachEntity_VEHICLE = PacketPlayOutAttachEntity.getDeclaredField(\"c\")).setAccessible(true);\n\t\t}\n\t}",
"@Link Network network();",
"public interface PortalModel extends BaseModel {\r\n\t/**\r\n\t * Returns the portal.\r\n\t * @return The portal.\r\n\t */\r\n\tPortal getPortal();\r\n\r\n\t/**\r\n\t * Returns the portal path.\r\n\t * @return The portal path.\r\n\t */\r\n\tPathSegments getPath();\r\n\r\n\t/**\r\n\t * Returns the portal URI Generator.\r\n\t * @return The portal URI Generator.\r\n\t */\r\n\tURIGenerator getURIGenerator();\r\n\r\n\t/**\r\n\t * Returns an started component module.\r\n\t * @param id Component module id.\r\n\t * @return Component module module.\r\n\t */\r\n\tStartedModule<?> getComponent(UUID id);\r\n\r\n\t/**\r\n\t * Returns the device capabilities provider.\r\n\t * @return The device capabilities provider.\r\n\t */\r\n\tDeviceCapabilitiesProvider getDeviceCapabilitiesProvider();\r\n\r\n\t/**\r\n\t * Returns the page resolver.\r\n\t * @return The page resolver.\r\n\t */\r\n\tPageResolver getPageResolver();\r\n\r\n\t/**\r\n\t * Returns a content loader for the portal.\r\n\t * @param context Client request context.\r\n\t * @return A content loader for the portal.\r\n\t */\r\n\tContentLoader getContentLoader(ClientRequestContext context);\r\n\r\n\t/**\r\n\t * Returns the portal pages.\r\n\t * @return The portal pages.\r\n\t */\r\n\tPages getPages();\r\n\r\n\t/**\r\n\t * Returns the cache model.\r\n\t * @return The cache model.\r\n\t */\r\n\tPortalCacheModel getCacheModel();\r\n}",
"public interface Provider {\n //Connection connect(String url, java.util.Properties info)\n Service newService();\n}",
"@SuppressWarnings(\"unused\")\npublic interface AccountI extends Remote {\n String login(String id, String passwd) throws RemoteException;\n String signUp(String id, String passwd, String secureQuestion, String answer)throws RemoteException;\n String logOut(String userName) throws RemoteException;\n String forgetPassword(String username)throws RemoteException;\n String resetPassword(String username,String answer, String password)throws RemoteException;\n void startIO()throws RemoteException;\n int getRuntimeServer()throws RemoteException;\n int getFileServer() throws RemoteException;\n int getIOUniqueNumber()throws RemoteException;\n}",
"public DefaultCniNetworkInner() {\n }",
"public interface GlobalServerConfiguration {\n\n /**\n * Gets the location for the AdapterConfig for the specified namespace\n */\n public String getAdapterConfigLocation(String namespace);\n\n /**\n * Gets the location of the FeedConfig for the specified namespace\n */\n public String getFeedConfigLocation(String namespace);\n\n /**\n * Gets the Feed Configuration suffix\n */\n public String getFeedConfigSuffix();\n\n /**\n * Gets the namespace\n */\n public String getFeedNamespace(String namespace);\n\n /**\n * Gets the namespace prefix\n */\n public String getFeedNamespacePrefix(String namespace);\n\n /**\n * Gets the Server port\n */\n public int getPort();\n\n /**\n * Gets the URI for the feedserver with the specified namespace\n */\n public String getServerUri(String namespace);\n\n /**\n * Gets URI prefix for Feeds\n */\n public String getFeedPathPrefix();\n\n /**\n * Gets the {@link FeedConfiguration} for the specified feed in the namespace\n * \n * @param namespace The namespace the feed is in\n * @param feedId The feed to get the {@link FeedConfiguration} for\n * @param userId User email of per user feed requested; null if not per user feed\n */\n public FeedConfiguration getFeedConfiguration(String namespace, String feedId, String userId)\n throws FeedConfigStoreException;\n\n /**\n * Get the fully qualified class name for adapter wrapper manager.\n * \n * @return fully qualified class name for adapter wrapper manager.\n */\n public String getWrapperManagerClassName();\n\n /**\n * Gets the {@link FeedConfigStore} for the Server Configuration\n */\n public FeedConfigStore getFeedConfigStore();\n\n /**\n * Get the fully qualified class name of the provider that will be used for\n * this server.\n * \n * @return fully qualified class name of the Provider.\n */\n public String getProviderClassName();\n\n @SuppressWarnings(\"unchecked\")\n public AdapterBackendPool getAdapterBackendPool(String poolId);\n\n @SuppressWarnings(\"unchecked\")\n public void setAdapterBackendPool(String poolId, AdapterBackendPool pool);\n\n public AclValidator getAclValidator();\n\n public void setAclValidator(AclValidator aclValidator);\n\n}",
"RemoteUserManager() { }",
"protected SecurityObject() {\n\t\t// Used by JPA provider.\n\n\t\tLOGGER.debug(\"SecurityObject#co\");\n\t}",
"public interface IXoClientHost {\n\n public ScheduledExecutorService getBackgroundExecutor();\n public ScheduledExecutorService getIncomingBackgroundExecutor();\n public IXoClientDatabaseBackend getDatabaseBackend();\n public KeyStore getKeyStore();\n public Thread.UncaughtExceptionHandler getUncaughtExceptionHandler();\n public InputStream openInputStreamForUrl(String url) throws IOException;\n\n public String getClientName();\n public String getClientLanguage();\n public String getClientVersionName();\n public int getClientVersionCode();\n public String getClientBuildVariant();\n public Date getClientTime();\n\n public String getDeviceModel();\n\n public String getSystemName();\n public String getSystemLanguage();\n public String getSystemVersion();\n}",
"public interface MRConnectionManagerContainer {\n\n\n String MR_GROUP_PATH = \"/zk/mr/\";\n\n void start() throws Exception;\n\n void start(Map<String, MRMessageListener> messageListenerMap) throws Exception;\n\n void register();\n\n void add(Map.Entry<String, String> entry) throws Exception;\n\n void update(Map.Entry<String, String> entry);\n\n void addListener(String topic, MRMessageListener mrMessageListener);\n\n void remove(Map.Entry<String, String> entry);\n\n void refresh();\n\n void shutdown();\n\n void shutdownAndWait() throws InterruptedException;\n\n Map<String, MRConnectionManager> getMrConnectionManagerCache();\n\n static String groupPath(String group) {\n return String.format(\"%s%s\", MR_GROUP_PATH, group);\n }\n\n void setPerfetchSize(int perfetchSize);\n\n\n}",
"public interface SecurityContext {\n\n}",
"public Object getCommunicationChannel()\r\n\t\t\tthrows PersistenceMechanismException {\n\t\treturn null;\r\n\t}",
"public void establishConnection() {\n httpNetworkService = new HTTPNetworkService(handler);\n }",
"public interface IXiangChildModel {\n public void login(String pscid, String page, OnNetLisenter<XiangChildBean> onNetLisenter);\n}",
"public interface IAuthenticationService extends IStatisticsProvider {\r\n\t/** Service's Name in {@link String} form */\r\n public static final String SERVICE_NAME = Constants.NAMESPACES.SERVICE_PREFIX + \"AuthenticationService\";\r\n\r\n /** Service's Name in {@link URI} form */\r\n public static final URI SERVICE_URI = Constants.valueFactory.createURI(SERVICE_NAME);\r\n\r\n /* Statistics object for this service\r\n public org.openanzo.services.stats.AuthenticationServiceStats getStatistics();\r\n */\r\n\t/**Constant for parameter password */\r\n\tpublic static final String PARAM_PASSWORD = \"password\";\r\n\t/**Constant for parameter userId */\r\n\tpublic static final String PARAM_USER_ID = \"userId\";\r\n\t/**authenticateUser operation name constant */\r\n public static final String AUTHENTICATE_USER = \"authenticateUser\";\r\n /**\r\n * Authenticate a User.\r\n *\r\n * @param context\r\n * {@link IOperationContext} context for this operation\r\n * @param userId\r\n * The id the user is authenticating against.\r\n * @param password\r\n * The password for the id the user is authenticating against.\r\n * @return User's URI.\r\n * @throws AnzoException\r\n */\r\n public org.openanzo.services.AnzoPrincipal authenticateUser(IOperationContext context,String userId,String password) throws AnzoException;\r\n\r\n /**\r\n * Authenticate a User.\r\n *\r\n * @param context\r\n * {@link IOperationContext} context for this operation\r\n * @param userId\r\n * The id the user is authenticating against.\r\n * @param password\r\n * The password for the id the user is authenticating against.\r\n * @param output\r\n * {@link java.io.Writer} onto which output is written\r\n * @param resultFormat\r\n * format of result data\r\n * @throws AnzoException\r\n */\r\n public void authenticateUser(IOperationContext context,String userId,String password, java.io.Writer output, String resultFormat) throws AnzoException;\r\n\t/**getUserPrincipal operation name constant */\r\n public static final String GET_USER_PRINCIPAL = \"getUserPrincipal\";\r\n /**\r\n * Get a User's URI.\r\n *\r\n * @param context\r\n * {@link IOperationContext} context for this operation\r\n * @param userId\r\n * The id of the user for which to retrieve a URI.\r\n * @return URI.\r\n * @throws AnzoException\r\n */\r\n public org.openanzo.services.AnzoPrincipal getUserPrincipal(IOperationContext context,String userId) throws AnzoException;\r\n\r\n /**\r\n * Get a User's URI.\r\n *\r\n * @param context\r\n * {@link IOperationContext} context for this operation\r\n * @param userId\r\n * The id of the user for which to retrieve a URI.\r\n * @param output\r\n * {@link java.io.Writer} onto which output is written\r\n * @param resultFormat\r\n * format of result data\r\n * @throws AnzoException\r\n */\r\n public void getUserPrincipal(IOperationContext context,String userId, java.io.Writer output, String resultFormat) throws AnzoException;\r\n}",
"interface UserManager extends Remote {\n int USER_HAS_LOGGEDIN = -1;\n int USER_NOT_EXIST = -2;\n int USER_INCORRECT_PASSWORD = -3;\n int VALID = 0;\n int HAS_REGISTERED = -4;\n int DATABASE_ERROR = -5;\n int REMOTE_ERROR = -6;\n int login(String username, char[] password) throws RemoteException;\n int register(String username, char[] password) throws RemoteException;\n User getUser(int id) throws RemoteException;\n void logout(int id) throws RemoteException;\n int getRank(int id) throws RemoteException;\n ArrayList<User> getAllUsers() throws RemoteException;\n}",
"public interface PeerRMI extends Remote {\n\n\t/**\n\t * Allows the backup of a document amongst the peers of the network\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString backup(String request) throws RemoteException;\n\n\t/**\n\t * Allows the enhanced backup of a document amongst the peers of the network\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString backupENH(String request) throws RemoteException;\n\t\n\t/**\n\t * Allows the deletion of a document saved in the peers of the network\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString delete(String request) throws RemoteException;\n\n\t/**\n\t * Allows the enhanced deletion of a document saved in the peers of the network\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString deleteENH(String request) throws RemoteException;\n\n\t/**\n\t * Allows the restoration of a document saved in the other peers of the network, the restored file will be saved in the peer-iniatior\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString restore(String request) throws RemoteException;\n\n\t/**\n\t * Allows the restoration of a document saved in the other peers of the network, the restored file will be saved in the peer-iniatior\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString restoreENH(String request) throws RemoteException;\n\n\t/**\n\t * Allows the enhanced reclaim of space of the initiator-peer\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString reclaim(String request) throws RemoteException;\n\n\t/**\n\t * Allows the user to get the state of the initiator-peer\n\t * @param request\n\t * \t\t\t\tString containing the details about the request\n\t * @return\n\t * \t\t\t\tString containing the status of the execution\n\t * @throws RemoteException\n\t */\n\tString state() throws RemoteException;\n}",
"public McqOfficialSession(){\n\t\tsuper(); \n\t}",
"public interface Communicator {\n public void respond(String data);\n public void goTo(String data);\n public void createSession(String key,String Value);\n public String getSession();\n}",
"public interface Communicator {\n\n\n public void sendData(String string);\n public void sendNIDcardObject(NIDCard nidCard);\n public void startWelcomeFragment();\n public void stopWelcomeFragment();\n public void startStepOne();\n}",
"@Override\n\tprotected ConnectionType getConnectionType() {\n\t\treturn ConnectionType.Network;\n\t}",
"public interface AdminOperations\n{\n\t/* constants */\n\t/* operations */\n\torg.jacorb.imr.HostInfo[] list_hosts();\n\torg.jacorb.imr.ServerInfo[] list_servers();\n\torg.jacorb.imr.ServerInfo get_server_info(java.lang.String name) throws org.jacorb.imr.UnknownServerName;\n\tvoid shutdown(boolean _wait);\n\tvoid save_server_table() throws org.jacorb.imr.AdminPackage.FileOpFailed;\n\tvoid register_server(java.lang.String name, java.lang.String command, java.lang.String host) throws org.jacorb.imr.AdminPackage.IllegalServerName,org.jacorb.imr.AdminPackage.DuplicateServerName;\n\tvoid unregister_server(java.lang.String name) throws org.jacorb.imr.UnknownServerName;\n\tvoid edit_server(java.lang.String name, java.lang.String command, java.lang.String host) throws org.jacorb.imr.UnknownServerName;\n\tvoid hold_server(java.lang.String name) throws org.jacorb.imr.UnknownServerName;\n\tvoid release_server(java.lang.String name) throws org.jacorb.imr.UnknownServerName;\n\tvoid start_server(java.lang.String name) throws org.jacorb.imr.ServerStartupFailed,org.jacorb.imr.UnknownServerName;\n\tvoid unregister_host(java.lang.String name) throws org.jacorb.imr.AdminPackage.UnknownHostName;\n}",
"public abstract void connectSystem();",
"@Override\n protected INetworkObject doInBackground(INetworkObject... params) {\n if(params==null){return null;}\n netObj = params[0];\n try {\n if(netObj.getClass()==NetworkObjectPosition.class){\n communicateWithServer((NetworkObjectPosition) netObj);\n }\n if(netObj.getClass()==NetworkObjectGetID.class){\n communicateWithServer((NetworkObjectGetID) netObj);\n }\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n return netObj;\n }",
"public interface AutenticacionIBS extends AuthenticationProvider {\r\n\r\n}",
"EvergreenProvision getEvergreenProvision();",
"public CCNNetworkManager(KeyManager keyManager) throws IOException {\n _managerId = _managerIdCount.incrementAndGet();\n _managerIdString = \"NetworkManager \" + _managerId + \": \";\n if (null == keyManager) {\n if (Log.isLoggable(Log.FAC_NETMANAGER, Level.INFO)) Log.info(Log.FAC_NETMANAGER, formatMessage(\"CCNNetworkManager: being created with null KeyManager. Must set KeyManager later to be able to register filters.\"));\n }\n _keyManager = keyManager;\n String portval = System.getProperty(PROP_AGENT_PORT);\n if (null != portval) {\n try {\n _port = new Integer(portval);\n } catch (Exception ex) {\n throw new IOException(formatMessage(\"Invalid port '\" + portval + \"' specified in \" + PROP_AGENT_PORT));\n }\n Log.warning(Log.FAC_NETMANAGER, formatMessage(\"Non-standard CCN agent port \" + _port + \" per property \" + PROP_AGENT_PORT));\n }\n String hostval = System.getProperty(PROP_AGENT_HOST);\n if (null != hostval && hostval.length() > 0) {\n _host = hostval;\n Log.warning(Log.FAC_NETMANAGER, formatMessage(\"Non-standard CCN agent host \" + _host + \" per property \" + PROP_AGENT_HOST));\n }\n _protocol = SystemConfiguration.AGENT_PROTOCOL;\n if (Log.isLoggable(Log.FAC_NETMANAGER, Level.INFO)) Log.info(Log.FAC_NETMANAGER, formatMessage(\"Contacting CCN agent at \" + _host + \":\" + _port));\n String tapname = System.getProperty(PROP_TAP);\n if (null == tapname) {\n tapname = System.getenv(ENV_TAP);\n }\n if (null != tapname) {\n long msecs = System.currentTimeMillis();\n long secs = msecs / 1000;\n msecs = msecs % 1000;\n String unique_tapname = tapname + \"-T\" + Thread.currentThread().getId() + \"-\" + secs + \"-\" + msecs;\n setTap(unique_tapname);\n }\n _channel = new CCNNetworkChannel(_host, _port, _protocol, _tapStreamIn);\n _ccndId = null;\n _channel.open();\n _threadpool = (ThreadPoolExecutor) Executors.newCachedThreadPool();\n _threadpool.setKeepAliveTime(THREAD_LIFE, TimeUnit.SECONDS);\n _threadpool.setMaximumPoolSize(SystemConfiguration.MAX_DISPATCH_THREADS);\n _thread = new Thread(this, \"CCNNetworkManager \" + _managerId);\n _thread.start();\n }",
"@RequestMapping(value = \"/endpoint_manager\", method = RequestMethod.GET, produces = \"application/json; charset=utf-8\")\r\n public String endpointManager(HttpServletRequest request, ModelMap model) throws ServletException, IOException {\r\n UserAuthorities ua = userAuthoritiesProvider.getInstance();\r\n if (ua.userIsAdmin() || ua.userIsSuperUser()) {\r\n return(renderPage(request, model, \"endpoint_manager\", null, null, null, false));\r\n } else {\r\n throw new SuperUserOnlyException(\"You are not authorised to manage WMS endpoints for this server\");\r\n }\r\n }",
"public interface CommonDispatcher extends javax.ejb.EJBObject {\n\t\n\t/**\n\t * An example business method\n\t * \n\t * @throws EJBException\n\t * Thrown if method fails due to system-level error.\n\t */\n\tpublic DataHolder processRequest(DataHolder indataholder) throws java.rmi.RemoteException;\n\tpublic ProcessResult processRequest(VTObject inputDTO) throws java.rmi.RemoteException;\n\t//public DataHolder processRequest(DataHolder indataholder) throws java.rmi.RemoteException;\n}",
"void onNetworkCredentialsRequested();"
] | [
"0.58601534",
"0.57852197",
"0.57733566",
"0.57077193",
"0.5641226",
"0.5559247",
"0.55260164",
"0.5508715",
"0.5465689",
"0.54393953",
"0.54021895",
"0.53911287",
"0.5386646",
"0.5385476",
"0.5385476",
"0.5371971",
"0.53572935",
"0.5308199",
"0.5298758",
"0.5298347",
"0.5286093",
"0.5254629",
"0.5243256",
"0.5237421",
"0.52342725",
"0.52222145",
"0.5210671",
"0.52071315",
"0.52054894",
"0.5205196",
"0.5184226",
"0.51729065",
"0.51669854",
"0.5165144",
"0.51485884",
"0.51199067",
"0.5119023",
"0.5112444",
"0.51070064",
"0.5103138",
"0.509302",
"0.5076395",
"0.5075561",
"0.506461",
"0.50613695",
"0.5061296",
"0.50599486",
"0.5056654",
"0.5046386",
"0.50454104",
"0.5025737",
"0.5024597",
"0.502307",
"0.5019108",
"0.5010928",
"0.50094247",
"0.5005315",
"0.50000525",
"0.49875966",
"0.4984713",
"0.49775365",
"0.49683553",
"0.49650005",
"0.49624482",
"0.49561027",
"0.49554378",
"0.49531993",
"0.49528947",
"0.4945711",
"0.4936175",
"0.49292478",
"0.49291012",
"0.49273193",
"0.49225128",
"0.4922363",
"0.4918254",
"0.49151152",
"0.49091825",
"0.4906447",
"0.49052826",
"0.4899554",
"0.48873895",
"0.4881754",
"0.48739284",
"0.4873044",
"0.48685992",
"0.48682934",
"0.48644733",
"0.48618114",
"0.4857488",
"0.4854976",
"0.48531446",
"0.48502272",
"0.48431292",
"0.48416775",
"0.48372898",
"0.48263624",
"0.4825009",
"0.48242444",
"0.48149514"
] | 0.5683982 | 4 |
=== custom dispatcher functions to extend the functionality for special usage like sending fax get an additional interface, e.g. interface to a workflow engine, implements a service locator | public abstract Object getInterface(String strInterfaceName_p, Object oObject_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract void dispatch(ExchangeContext context);",
"public interface CommonDispatcher extends javax.ejb.EJBObject {\n\t\n\t/**\n\t * An example business method\n\t * \n\t * @throws EJBException\n\t * Thrown if method fails due to system-level error.\n\t */\n\tpublic DataHolder processRequest(DataHolder indataholder) throws java.rmi.RemoteException;\n\tpublic ProcessResult processRequest(VTObject inputDTO) throws java.rmi.RemoteException;\n\t//public DataHolder processRequest(DataHolder indataholder) throws java.rmi.RemoteException;\n}",
"private void dispatch(CallContext context, HttpServletRequest request, HttpServletResponse response)\n throws Exception {\n\n CmisService service = null;\n try {\n // get the service\n service = getServiceFactory().getService(context);\n\n // analyze the path\n String[] pathFragments = HttpUtils.splitPath(request);\n\n if (pathFragments.length < 2) {\n // root -> service document\n dispatcher.dispatch(\"\", METHOD_GET, context, service, null, request, response);\n return;\n }\n\n String method = request.getMethod();\n String repositoryId = pathFragments[0];\n String resource = pathFragments[1];\n\n // dispatch\n boolean callServiceFound = dispatcher.dispatch(resource, method, context, service, repositoryId, request,\n response);\n\n // if the dispatcher couldn't find a matching service\n // -> return an error message\n if (!callServiceFound) {\n response.sendError(HttpServletResponse.SC_METHOD_NOT_ALLOWED, \"Unknown operation\");\n }\n } finally {\n if (service != null) {\n service.close();\n }\n }\n }",
"public interface ILauncherInteractor extends IBaseRequestInteractor {\n void callInitialDevice(InitDeviceRequest initialDeviceRequest, OnInitialDeviceListener listener);\n\n void callShutdownDevice(ImeiRequest imei);\n\n void callSOS(OnSOSListener listener, ImeiRequest imei);\n\n void callUpdateInfoAndGetEventService(OnEventListener listener, LocationUpdateRequest locationInfo);\n\n void callSendNewLocationService(RefreshLocationRequest locationInfo);\n\n void callTimezoneChanged(TimezoneUpdateRequest timeZoneParam);\n}",
"public interface ActionDispatcher {\n\n /**\n * Dispatches the provided action to a proper handler that is responsible for handling of that action.\n * <p/> To may dispatch the incomming action a proper handler needs to be bound\n * to the {@link com.clouway.gad.dispatch.ActionHandlerRepository} to may the dispatch method dispatch the\n * incomming request to it.\n * \n * @param action the action to be handled\n * @param <T> a generic response type\n * @return response from the provided execution\n * @throws ActionHandlerNotBoundException is thrown in cases where no handler has been bound to handle that action\n */\n <T extends Response> T dispatch(Action<T> action) throws ActionHandlerNotBoundException;\n \n}",
"public interface AdditionalOrderInforCaller {\n\t/*\n\t * Command define from Order Confirmation API Guide\n\t * JSON and XML format\n\t */\n\t@Headers({\"Accept: application/json\",\"Content-Type: application/json\"})\n\t@RequestLine(\"POST /ordermgmt/order/addorderinfo?sellerid={sellerid}\")\n\tGetAdditionalOrderInformationResponse sendAdditionalOrderInforRequestJSON(@Param(\"sellerid\") String sellerID, GetAdditionalOrderInformationRequest body);\n\t\n\t@Headers({\"Accept: application/xml\",\"Content-Type: application/xml\"})\n\t@RequestLine(\"POST /ordermgmt/order/addorderinfo?sellerid={sellerid}\")\n\tGetAdditionalOrderInformationResponse sendAdditionalOrderInforRequestXML(@Param(\"sellerid\") String sellerID, GetAdditionalOrderInformationRequest body);\n\n\t// Implement default method of interface class that according to Variables.MediaType to run at JSON or XML request.\n\tdefault GetAdditionalOrderInformationResponse sendAdditionalOrderInforRequest(GetAdditionalOrderInformationRequest body) {\n\t\tswitch(Variables.MediaType) {\n\t\tcase JSON:\t\t\t\n\t\t\treturn sendAdditionalOrderInforRequestJSON(Content.SellerID, body);\n\t\t\t\n\t\tcase XML:\t\t\t\n\t\t\treturn sendAdditionalOrderInforRequestXML(Content.SellerID, body);\t\n\t\t\t\n\t\tdefault:\n\t\t\tthrow new RuntimeException(\"Never Happened!\");\n\t\t}\n\t\t\t\t\n\t}\n\t\n\tstatic AdditionalOrderInforCaller buildJSON() {\n\t\tVariables.MediaType = MEDIA_TYPE.JSON;\n\t\t\n\t\treturn new CallerFactory<AdditionalOrderInforCaller>()\n\t\t\t.jsonBuild(AdditionalOrderInforCaller.class, Variables.LogLevel, Variables.Retryer, OrderClient.genClient());\t\t\n\t}\n\n\tstatic AdditionalOrderInforCaller buildXML() {\n\t\tVariables.MediaType = MEDIA_TYPE.XML;\n\t\t\n\t\treturn new CallerFactory<AdditionalOrderInforCaller>()\n\t\t\t.xmlBuild(AdditionalOrderInforCaller.class, Variables.LogLevel, Variables.Retryer, OrderClient.genClient());\t\t\n\t}\n\t\n}",
"public interface CoreServiceInvoker {\n\n\n GWRequest processRequest(Object requestData, InterfaceMapper mapper);\n\n /**\n * 处理请求信息\n */\n GWRequest processRequest(Object requestData, InterfaceMapper mapper, boolean needPackage);\n\n /**\n * 调用核心方法\n */\n GWResponse invoke(GWRequest request, boolean needPackage);\n\n /**\n * 处理返回信息\n */\n Object analysisResponse(GWRequest request, GWResponse response);\n Object analysisResp(GWRequest request, GWResponse response);\n}",
"public void dispatch();",
"public interface InterfaceWebRequest {\n void dispatchRequest();\n}",
"public interface ProcessOutputHandler\n{\n /**\n * Updates the fax job based on the data from the process output.\n * \n * @param faxClientSpi\n * The fax client SPI\n * @param faxJob\n * The fax job object\n * @param processOutput\n * The process output\n * @param faxActionType\n * The fax action type\n */\n public void updateFaxJob(FaxClientSpi faxClientSpi,FaxJob faxJob,ProcessOutput processOutput,FaxActionType faxActionType);\n \n /**\n * This function extracts the fax job status from the process output.\n * \n * @param faxClientSpi\n * The fax client SPI\n * @param processOutput\n * The process output\n * @return The fax job status\n */\n public FaxJobStatus getFaxJobStatus(FaxClientSpi faxClientSpi,ProcessOutput processOutput);\n}",
"public interface ITransportHandler {\n\n /**\n * Processing device returned messages\n * \n * @author\n * @param devReplyStr Message information returned by the device\n */\n void handlePacket(String devReplyStr);\n\n /**\n * Error information processing apparatus returns <br>\n * \n * @author\n * @param devReplyErr Error messages returned by the device\n */\n void handleError(String devReplyErr);\n\n /**\n * Device interaction with the end of the glyph packets <br>\n * \n * @author\n * @return End glyph packets\n */\n String getPacketEndTag();\n\n /**\n * Encoding packets\n * \n * @author\n * @return Encoding packets\n */\n String getCharsetName();\n\n}",
"public SoapAdminDispatcher() {\n\t interfaceMappings = new Hashtable();\n\t //Small hashtable for determing the query interface.\n\t interfaceMappings.put(\"http://www.astrogrid.org/wsdl/RegistryUpdate/v0.1\",\"0.1\");\t \n\t interfaceMappings.put(\"http://www.astrogrid.org/wsdl/RegistryUpdate/v1.0\",\"1.0\");\t \n\t \n }",
"public interface OnRequestDetailsListen {\n}",
"public interface IWXAPI {\n boolean handleIntent(Intent intent, IWXAPIEventHandler iWXAPIEventHandler);\n\n boolean registerApp(String str);\n\n boolean sendReq(BaseReq baseReq);\n}",
"public interface INetworkHandlerManager {\n public void registerHandler (String handlerName, INetworkHandler handler);\n public INetworkHandler getHandler (INetworkMessage message);\n}",
"public interface ServiceRedirection {\n\n /**\n * The interface method implemented in the java files activity or Fragments for Success Response\n *\n * @param taskID the id based on which the relevant action is performed\n * @return none\n */\n\n void onSuccessRedirection(Response object, int taskID);\n\n /***\n * The interface method implemented in the java files activity or Fragments for Server Error Response\n * @param errorModel\n * @param taskID\n */\n void onServerErrorRedirection(ErrorModel errorModel, int taskID);\n\n /**\n * The interface method implemented in the java files activity or Fragments for Failure Response\n *\n * @param errorModel the error message to be displayed\n * @return none\n */\n void onFailureRedirection(ErrorModel errorModel);\n}",
"public interface IngestHandlerService extends Remote {\r\n\r\n String ingest(String xmlData, String resourceType, SecurityContext securityContext) throws EscidocException,\r\n RemoteException;\r\n\r\n String ingest(String xmlData, String resourceType, String authHandle, Boolean restAccess) throws EscidocException,\r\n RemoteException;\r\n\r\n}",
"protected void service(HttpServletRequest aRequest, HttpServletResponse aResponse) throws ServletException, IOException {\n\tif (aRequest.getAttribute(\"EXTRANET_METHOD\") == null) {\n\t\tsuper.service(aRequest, aResponse);\n\t} else {\n\t\t// If comming from a forward, determine if GET method should be invoked\n\t\tString lMethod = (String) aRequest.getAttribute(\"EXTRANET_METHOD\");\n\t\tif (lMethod != null && lMethod.equals(\"GET\")) {\n\t\t\tdoGet(aRequest, aResponse);\n\t\t} else {\n\t\t\tsuper.service(aRequest, aResponse);\n\t\t}\n\t}\n}",
"public interface MsgTypeHandler {\n /**\n * 处理xml消息\n * @param postXmlData\n * @param which\n * @return\n */\n public String handleXmlMsg(String postXmlData, final String which);\n\n /**\n * 处理json消息\n * @param postJsonData\n * @param which\n * @return\n */\n public String handleJsonMsg(String postJsonData, final String which);\n}",
"public interface IFRestaurant4FindFrgView\n{\n void requestNetErrorCallback(String interfaceName, Throwable e);\n\n void getIndexRecommendSuccess(String type, FRestaurannt4FindBean restaurannt4FindBean);\n\n void getCarouselResSuccess(ArrayList<FPromotionBean> pBeenLst);\n}",
"public interface IShopCarModle {\n //Post请求\n public void doPost(String uri, Map<String,String> param, OnNetListener<ShopCarBean> onNetListener);\n //Post请求删除购物车商品\n public void postDel(String uri,Map<String,String> param);\n}",
"public interface NextBusXmlFeed {\n\n @GET(\"/service/publicXMLFeed?command=agencyList\")\n Call<AgenciesResponse> agencyList();\n\n @GET(\"/service/publicXMLFeed?command=routeList\")\n Call<RoutesResponse> routeList(@Query(\"a\") final String agency);\n\n @GET(\"/service/publicXMLFeed?command=routeConfig\")\n Call<RouteConfigResponse> routeConfig(@Query(\"a\") final String agency, @Query(\"r\") final String route);\n\n @GET(\"/service/publicXMLFeed?command=predictions\")\n Call<PredictionResponse> predictions(@Query(\"a\") final String agency, @Query(\"r\") final String route, @Query(\"s\") final String stop);\n}",
"public interface NotificationCatcher {\n public static final String COPYRIGHT_2009_2010 = Constants.COPYRIGHT_2009_2010;\n \n static final String SCM_REVISION = \"$Revision: 1.2 $\"; //$NON-NLS-1$\n\n /**\n * When the Manager is started, the Manager will invoke this method. The\n * Manager needs a way to start the NotificationCatcher when the Manager\n * starts. After that point, the NotificationCatcher can place Notifications\n * on the Manager's queue. This method will allow the NotificationCatcher to\n * do any initialization to receive events from devices (such as listening\n * on a network socket) after it has been instantiated by the\n * NotificationCatcherFactory.\n * \n * @see NotificationCatcherFactory\n * @see Manager\n */\n public void startup() throws AMPException;\n \n /**\n * When the Manager is shutdown, the Manager will invoke this method. For\n * any resources that were obtained via the NotificationCatcher's\n * constructor or {@link #startup()}, this method will allow those\n * resources (such as network sockets) to be released when the Manager is\n * shutdown.\n * \n * @see Manager\n */\n public void shutdown();\n \n /**\n * Get the URL that this NotificationCatcher listens on so Devices know\n * where to post Notifications. This URL is used when a subscription request (\n * {@link Commands#subscribeToDevice(DeviceContext, String, StringCollection, URL)})\n * is sent to a device so that the device knows where to send the\n * notifications (events).\n * \n * @return the URL that this NotificationCatcher listens on so Devices know\n * where to post Notifications. This value will be used when sending\n * subscription requests to Devices. This may be an https or http\n * url. Typically, the path part of the URL will not be relevant,\n * the relevant parts are the protocol, hostname, and port.\n */\n public URL getURL();\n}",
"public interface Action {\n\n /**\n * Execute.\n *\n * @param router the router\n * @param request the request\n * @return the response\n */\n public Response execute(Router router, Request request);\n\n}",
"public interface HTTPContract {\n void getRequirementList(AnnounceDataSource.GetRequirementListCallback callback);\n void getFeelingList(AnnounceDataSource.GetFeelingListCallback callback);\n void postFeelingCommend();\n void postFeelingComment();\n// void postRequirementBook();\n// void postRequirementComment();\n\n}",
"public interface ServerProcessor {\n\n\t/**\n\t * Handle request,then return Object\n\t * \n\t * @param request\n\t * @return Object\n\t */\n\tObject handle(Object request);\n\t\n}",
"public interface IInboundEventProcessor extends ITenantLifecycleComponent {\r\n\r\n /**\r\n * Called when a {@link IDeviceRegistrationRequest} is received.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onRegistrationRequest(String hardwareId, String originator, IDeviceRegistrationRequest request)\r\n\t throws SiteWhereException;\r\n\r\n /**\r\n * Called when an {@link IDeviceCommandResponseCreateRequest} is received.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceCommandResponseRequest(String hardwareId, String originator,\r\n\t IDeviceCommandResponseCreateRequest request) throws SiteWhereException;\r\n\r\n /**\r\n * Called to request the creation of a new {@link IDeviceMeasurements} based\r\n * on the given information.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceMeasurementsCreateRequest(String hardwareId, String originator,\r\n\t IDeviceMeasurementsCreateRequest request) throws SiteWhereException;\r\n\r\n /**\r\n * Called to request the creation of a new {@link IDeviceLocation} based on\r\n * the given information.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceLocationCreateRequest(String hardwareId, String originator,\r\n\t IDeviceLocationCreateRequest request) throws SiteWhereException;\r\n\r\n /**\r\n * Called to request the creation of a new {@link IDeviceAlert} based on the\r\n * given information.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceAlertCreateRequest(String hardwareId, String originator, IDeviceAlertCreateRequest request)\r\n\t throws SiteWhereException;\r\n\r\n /**\r\n * Called to request the creation of a new {@link IDeviceStateChange} based\r\n * on the given information.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceStateChangeCreateRequest(String hardwareId, String originator,\r\n\t IDeviceStateChangeCreateRequest request) throws SiteWhereException;\r\n\r\n /**\r\n * Called to request the creation of a new {@link IDeviceStream} based on\r\n * the given information.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceStreamCreateRequest(String hardwareId, String originator, IDeviceStreamCreateRequest request)\r\n\t throws SiteWhereException;\r\n\r\n /**\r\n * Called to request the creation of a new {@link IDeviceStreamData} based\r\n * on the given information.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceStreamDataCreateRequest(String hardwareId, String originator,\r\n\t IDeviceStreamDataCreateRequest request) throws SiteWhereException;\r\n\r\n /**\r\n * Called to request that a chunk of {@link IDeviceStreamData} be sent to a\r\n * device.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onSendDeviceStreamDataRequest(String hardwareId, String originator,\r\n\t ISendDeviceStreamDataRequest request) throws SiteWhereException;\r\n\r\n /**\r\n * Called to request that a device be mapped to a path on a composite\r\n * device.\r\n * \r\n * @param hardwareId\r\n * @param originator\r\n * @param request\r\n * @throws SiteWhereException\r\n */\r\n public void onDeviceMappingCreateRequest(String hardwareId, String originator, IDeviceMappingCreateRequest request)\r\n\t throws SiteWhereException;\r\n}",
"public interface Handle {\n public void handle(HttpExchange httpExchange);\n}",
"public interface ServiceandLocListner {\n public void failedtoConnect();\n public void GetServiceListFailed(String msg);\n\n public void GetServiceList(List<Services> servicesList);\n\n public void GetLocationList(List<PlaceLoc> placeLocList);\n\n public void GetLocationListFailed(String msg);\n\n public void AddLocationSuccess();\n\n public void AddLocationFailed(String msg);\n public void DeleteLocationSuccess();\n\n public void DeleteLocationFailed(String msg);\n public void AddServiceSuccess();\n\n public void AddServiceFailed(String msg);\n\n public void DeleteServiceSuccess();\n\n public void DeleteServiceFailed(String msg);\n\n\n\n}",
"public interface ICommonAction {\n\n void obtainData(Object data, String methodIndex, int status,Map<String, String> parameterMap);\n\n\n}",
"Registration registerDispatcher(Class<? extends Event<?>> type, Dispatcher<?> dispatcher);",
"public interface EndpointBase {\n\n boolean isIdleNow();\n\n /**\n * @param connectionTimeout\n * @param methodTimeout\n */\n void setTimeouts(int connectionTimeout, int methodTimeout);\n\n /**\n * @param alwaysMainThread\n */\n void setCallbackThread(boolean alwaysMainThread);\n\n /**\n * @param flags\n */\n void setDebugFlags(int flags);\n\n int getDebugFlags();\n\n /**\n * @param delay\n */\n void setDelay(int delay);\n\n void addErrorLogger(ErrorLogger logger);\n\n void removeErrorLogger(ErrorLogger logger);\n\n void setOnRequestEventListener(OnRequestEventListener listener);\n\n\n void setPercentLoss(float percentLoss);\n\n int getThreadPriority();\n\n void setThreadPriority(int threadPriority);\n\n\n ProtocolController getProtocolController();\n\n void setUrlModifier(UrlModifier urlModifier);\n\n /**\n * No log.\n */\n int NO_DEBUG = 0;\n\n /**\n * Log time of requests.\n */\n int TIME_DEBUG = 1;\n\n /**\n * Log request content.\n */\n int REQUEST_DEBUG = 2;\n\n /**\n * Log response content.\n */\n int RESPONSE_DEBUG = 4;\n\n /**\n * Log cache behavior.\n */\n int CACHE_DEBUG = 8;\n\n /**\n * Log request code line.\n */\n int REQUEST_LINE_DEBUG = 16;\n\n /**\n * Log request and response headers.\n */\n int HEADERS_DEBUG = 32;\n\n /**\n * Log request errors\n */\n int ERROR_DEBUG = 64;\n\n /**\n * Log cancellations\n */\n int CANCEL_DEBUG = 128;\n\n /**\n * Log cancellations\n */\n int THREAD_DEBUG = 256;\n\n /**\n * Log everything.\n */\n int FULL_DEBUG = TIME_DEBUG | REQUEST_DEBUG | RESPONSE_DEBUG | CACHE_DEBUG | REQUEST_LINE_DEBUG | HEADERS_DEBUG | ERROR_DEBUG | CANCEL_DEBUG;\n\n int INTERNAL_DEBUG = FULL_DEBUG | THREAD_DEBUG;\n\n /**\n * Created by Kuba on 17/07/14.\n */\n interface UrlModifier {\n\n String createUrl(String url);\n\n }\n\n interface OnRequestEventListener {\n\n void onStart(Request request, int requestsCount);\n\n void onStop(Request request, int requestsCount);\n\n }\n}",
"public interface IRequestCommHandler<T extends RequestComm<?>> {\r\n\r\n\tResponseComm serviceRequest(T requestcomm, HttpServletRequest httpservletrequest);\r\n}",
"protected void service(HttpServletRequest req, HttpServletResponse resp)\n\t\t\tthrows ServletException, IOException {\n\t\tString actionType=req.getParameter(\"actionType\");\n\t\tif(actionType.equals(\"query\"))\n\t\t{\n\t\t\tquery(req,resp);\n\t\t}\n\t\tif(actionType.equals(\"kanweizhang\"))\n\t\t{\n\t\t\tkanweizhang(req,resp);\n\t\t}\n\t\tif(actionType.equals(\"tuiweizhang\"))\n\t\t{\n\t\t\ttuiweizhang(req,resp);\n\t\t}\n\t\t\n\t\tif(actionType.equals(\"querywenlei\"))\n\t\t{\n\t\t\tquerywenlei(req,resp);\n\t\t}\n\t}",
"public interface ITaxHandler\n{\n Object getTaxes(Long cartId, Boolean submitTax);\n\n Object getOrderTaxes(Order order, Long userId, Boolean submitTax);\n\n //Simple single-item tax request\n Object getTaxes(Address shippingAddress, String itemReferenceId, int quantity, Float price,\n String userId, Boolean submitTax);\n}",
"public interface IMsgService {\n\n public String executeMsg(HttpServletRequest request);\n\n\n}",
"protected void doService(HttpServletRequest req, HttpServletResponse resp) throws Exception {\r\n // This class has been removed from all places where it was used and replaced by the Spring\r\n // dispatcher from which it inherits. Delegate to super for now in case this ever gets called.\r\n // There is one place that depends on the tool constants above, in CommentListGenerator.\r\n // These constants should be relocated and this class purged.\r\n super.doService(req, resp);\r\n }",
"public interface PageDispatcher {\n\t/**\n\t * Process a webpage\n\t * @param url The URL to process\n\t * @param link The link that was followed to get there\n\t */\n\tpublic void dispatch(URL url, Weblink link, long delay);\n\t\n\t/**\n\t * Register a redirect\n\t * @param oldURL The URL that was redirected\n\t * @param newURL The URL it was redirected to\n\t * @param delay The number of milliseconds to wait before loading the page\n\t */\n\tpublic void registerRedirect(String oldURL, String newURL);\n\t\n\t/**\n\t * Remove all traces of having crawled a URL\n\t * @param url the URL to remove\n\t */\n\tpublic void undispatchURL(String url);\n\t\n\t/**\n\t * Notify the dispatcher that a page has been parsed\n\t * @param page The final version of the page\n\t * @param link The link that was followed to reach the page\n\t */\n\tpublic void notifyPage(Webpage page, Weblink link);\n\t\n\t/**\n\t * Send a command to the Builders\n\t * @param cmd The Command to send\n\t */\n\tpublic void sendCommand(Command cmd);\n}",
"public interface IBemListaInteractor {\n\n void buscarBensPorDepartamento(IBemListaPresenter listener);\n void atualizarListaBens(IBemListaPresenter listener);\n void buscarBemTipo(Context context, IBemListaPresenter listener);\n void buscarDadosQrCode(IBemListaPresenter listener);\n\n}",
"public interface DispatchingService {\n void startMovingShips(int numberShipTypeA, int numberShipTypeD, int numberShipTypeP, ControlValues controlValues) throws InterruptedException;\n void clearSquare();\n ArrayList<CellSquare> getSquareToJSON();\n}",
"public interface IOnCompleteWeatherRequest {\n public void OnCompleteWeatherRequest(String Message);\n}",
"public interface RequestHandler {\r\n /**\r\n * Handle the request and response.\r\n *\r\n *\r\n * @param xmlRequest\r\n * the xml request element\r\n * @param req\r\n * the http request\r\n * @param res\r\n * the http response\r\n * @throws IllegalArgumentException\r\n * if argument is null\r\n * @throws IOException\r\n * if I/O error occurs\r\n */\r\n public void handle(Element xmlRequest, HttpServletRequest req, HttpServletResponse res) throws IOException;\r\n\r\n}",
"public interface Router {\n\n interface Message {\n /**\n * The reply-to header\n *\n * @return the reply-to header\n */\n default String replyTo() {\n return (String) metadata().get(\"reply-to\");\n }\n\n /**\n * The host header\n *\n * @return the host header\n */\n default String host() {\n return (String) metadata().get(\"x-host\");\n }\n\n /**\n * Get the name of the reply queue to send the message to\n *\n * @return the reply queue\n */\n default String replyQueue() {\n return (String) metadata().get(\"x-reply-queue\");\n }\n\n\n /**\n * The uri header\n *\n * @return the uri header\n */\n default String uri() {\n\n return (String) metadata().get(\"x-uri\");\n }\n\n /**\n * The scheme header\n *\n * @return the scheme header\n */\n default String scheme() {\n return (String) metadata().get(\"x-scheme\");\n }\n\n /**\n * The method header\n *\n * @return the method header\n */\n default String method() {\n String m = (String) metadata().get(\"x-method\");\n if (null == m) {\n m = \"get\";\n }\n return m.toLowerCase();\n }\n\n /**\n * Get the port... may be String, Number, or null\n *\n * @return get the port\n */\n default Object port() {\n return metadata().get(\"server-port\");\n }\n\n /**\n * get the protocol for the request\n *\n * @return\n */\n default String protocol() {\n return (String) metadata().get(\"x-server-protocol\");\n }\n\n /**\n * Get the uri args for the request\n *\n * @return the uri args for the request\n */\n default String args() {\n return (String) metadata().get(\"x-uri-args\");\n }\n\n /**\n * The content-type header\n *\n * @return the content-type header\n */\n default String contentType() {\n return (String) metadata().get(\"content-type\");\n }\n\n /**\n * The remote address of the client\n *\n * @return remote address\n */\n default String remoteAddr() {\n return (String) metadata().get(\"x-remote-addr\");\n }\n\n /**\n * The\n *\n * @return\n */\n Map<String, Object> metadata();\n\n Object body();\n\n byte[] rawBody();\n\n MessageBroker.ReceivedMessage underlyingMessage();\n }\n\n /**\n * Convert the message from the more generic one from the MessageBroker into\n * something that can be routed\n *\n * @param message\n * @return\n */\n default Message brokerMessageToRouterMessage(MessageBroker.ReceivedMessage message) {\n return new Message() {\n\n @Override\n public Map<String, Object> metadata() {\n return message.metadata();\n }\n\n @Override\n public Object body() {\n return message.body();\n }\n\n @Override\n public byte[] rawBody() {\n return message.rawBody();\n }\n\n @Override\n public MessageBroker.ReceivedMessage underlyingMessage() {\n return message;\n }\n };\n }\n\n /**\n * Route the message. This may cause the message to be queued to the next handler (Runner)\n * or route it to the handler Func.\n *\n * @param message the Message to route\n * @return the result of the Message application or void if this Router forwards the message\n */\n Object routeMessage(Message message) throws IOException;\n\n\n /**\n * Release any resources that the Router has... for example, any database pool connections\n */\n void endLife();\n\n /**\n * Get the host that this Router is listening for\n *\n * @return the name of the host. May be null\n */\n String host();\n\n /**\n * Get the base path for this Router\n *\n * @return the base path for the router\n */\n String basePath();\n\n /**\n * Return the name of the queue that is associated with the host/path combination\n *\n * @return the name of the queue associated with the host/path combination\n */\n String nameOfListenQueue();\n\n /**\n * Get the swagger for this Router\n *\n * @return the Swagger information for the router\n */\n Map<String, Object> swagger();\n\n}",
"public interface Resolution {\n\n /**\n * Called by the Stripes dispatcher to invoke the Resolution. Should use the\n * request and response provided to direct the user to an appropriate view.\n *\n * @param request the current HttpServletRequest\n * @param response the current HttpServletResponse\n * @throws Exception exceptions of any type may be thrown if the Resolution\n * cannot be executed as intended\n */\n void execute(HttpServletRequest request, HttpServletResponse response)\n throws Exception;\n}",
"public interface HttpRequestResolutionHandler {\r\n \r\n /**\r\n * Resolves the incoming HTTP request to a URL\r\n * that identifies a content binary \r\n *\r\n * @param inetAddress IP address the transaction was sent from.\r\n * @param url The <code>URL</code> requested by the transaction.\r\n * @param request The HTTP message request;\r\n * i.e., the request line and subsequent message headers.\r\n * @param networkInterface The <code>NetworkInterface</code> the request\r\n * came on.\r\n *\r\n * @return URL of the content binary if a match is found,\r\n * null otherwise.\r\n * \r\n */\r\n public URL resolveHttpRequest(InetAddress inetAddress,\r\n URL url,\r\n String[] request,\r\n NetworkInterface networkInterface);\r\n \r\n}",
"public interface IPaySlipInteractor extends IBaseInteractor{\n\n\n void fetchPaySlipData(String staff_Id);\n\n interface OnPaySlipListener extends BaseListener\n {\n void onSuccess(PaySlipResponseDo paySlipResponseDo);\n }\n}",
"public interface Request extends RegistryTask {\n\n}",
"public interface Delivery {\n\n void postDelivery(PlusRequest<?> plusRequest, Response<?> response);\n}",
"public interface MovimentacaoChainHandler {\n\n void handleMovimentacao(Movimentacao movimentacao);\n}",
"@Override\n\tpublic void dispatchHandler(Message msg) {\n\t\t\n\t}",
"public interface FaultService\r\n{\r\n\t\r\n\t/**\r\n\t * Raise an exception based on the given exception/argument\r\n\t * @param e the thrown error\r\n\t * @param argument the processed argument\r\n\t * @return the wrapped exception\r\n\t * @throws FaultException the GEDI exception will be thrown\r\n\t */\r\n\tpublic FaultException raise(Throwable e, Object argument);\r\n\t\r\n\t\r\n\t/**\r\n\t * Raise an exception based on the given exception\r\n\t * @param e the thrown error\r\n\t * @return the wrapper exception\r\n\t * @throws FaultException the GEDI exception will be thrown\r\n\t */\r\n\tpublic FaultException raise(Throwable e);\r\n\t\r\n}",
"public interface AppAction\n{\n void login(String name, String password, Handler handler);\n\n void access(Handler handler, String ...s);\n\n void gdata(Handler handler, List<EHentaiMangaInfo> list);\n\n void getMangaInfo(Handler handler);\n\n void getNews(Handler handler);\n\n void getNews(Handler handler, String title, String page);\n\n void getImg( String url, ImageView imageView,AppActionImpl.Callback<Void> callback,int height,int width);\n}",
"public interface IServerRouter {\n\t Optional<IServerAction> get(IServerExchange e);\n\n}",
"@Service\npublic interface EventHandler {\n public AppdirectAPIResponse handleEvent(EventInfo eventInfo);\n}",
"public interface ICore {\n\n /**\n * Send a request by unicast to the hostname.\n *\n * @param hostname IP address of the hostname.\n * @param message Message to send to the hostname.\n */\n void sendUnicast(InetAddress hostname, String message);\n\n /**\n * Send a request by multicast.\n *\n * @param message Message to send.\n */\n void sendMulticast(String message);\n\n /**\n * Stop the core.\n */\n void stop();\n}",
"public interface HomeResponseListener\n extends ResponseListener\n{\n\n public abstract void completed(ServiceCall servicecall);\n\n public abstract void receivedCartItems(CartItems cartitems, ServiceCall servicecall);\n\n public abstract void receivedCompletedRemembersItemIds(List list, ServiceCall servicecall);\n\n public abstract void receivedLoginData(LoginData logindata, ServiceCall servicecall);\n\n public abstract void receivedNotification(Notification notification, ServiceCall servicecall);\n\n public abstract void receivedPromoSlot0(PromoSlot promoslot, ServiceCall servicecall);\n\n public abstract void receivedPromoSlot1(PromoSlot promoslot, ServiceCall servicecall);\n\n public abstract void receivedShoveler0(HomeShoveler homeshoveler, ServiceCall servicecall);\n\n public abstract void receivedShoveler1(HomeShoveler homeshoveler, ServiceCall servicecall);\n}",
"public Dispatcher getDispatcher();",
"public interface ApiServer {\n//\n @GET(\"umIPmfS6c83237d9c70c7c9510c9b0f97171a308d13b611?uri=homepage\")\n Observable<HomeBean> getHome();\n @POST\n Observable<Login> getDengLu(@Url String name, @QueryMap Map<String, String> paw);\n @GET(\"product/getCatagory\")\n Observable<Sort_lift> lift();\n @GET\n Observable<Sort_right> right(@Url String s);\n @GET\n Observable<Commodity_pagingBean> xia(@Url String s);\n @GET\n Observable<detailsBean> spxq(@Url String ss);\n @GET\n Observable<AddcartBean> add(@Url String s);\n @GET\n Observable<QurryBean> qurry(@Url String s);\n @GET\n Observable<AddcartBean> delete(@Url String s);\n @GET\n Observable<AddcartBean> addDd(@Url String s);\n @GET\n Observable<OrderBean> Ddlb(@Url String s);\n\n\n\n\n\n\n}",
"protected void dispatchByType(Notification notification, OrderSummary orderSummary,\n BaseNotificationDispatcher dispatcher) throws Exception {\n if (notification instanceof AuthorizationAmountNotification) {\n dispatcher.onAuthorizationAmountNotification(\n orderSummary, (AuthorizationAmountNotification)notification);\n } else if (notification instanceof ChargeAmountNotification) {\n dispatcher.onChargeAmountNotification(\n orderSummary, (ChargeAmountNotification)notification);\n } else if (notification instanceof ChargebackAmountNotification) {\n dispatcher.onChargebackAmountNotification(\n orderSummary, (ChargebackAmountNotification)notification);\n } else if (notification instanceof NewOrderNotification) {\n dispatcher.onNewOrderNotification(\n orderSummary, (NewOrderNotification)notification);\n } else if (notification instanceof OrderStateChangeNotification) {\n dispatcher.onOrderStateChangeNotification(\n orderSummary, (OrderStateChangeNotification)notification);\n } else if (notification instanceof RefundAmountNotification) {\n dispatcher.onRefundAmountNotification(\n orderSummary, (RefundAmountNotification)notification);\n } else if (notification instanceof RiskInformationNotification) {\n dispatcher.onRiskInformationNotification(\n orderSummary, (RiskInformationNotification)notification);\n } else {\n dispatchUnknownNotification(notification, orderSummary, dispatcher);\n }\n }",
"@Override\n public String invoke(Event event, RequestMap requestMap, HttpServletRequest request, HttpServletResponse response) throws EventHandlerException {\n LocalDispatcher dispatcher = (LocalDispatcher) request.getAttribute(\"dispatcher\");\n if (dispatcher == null) {\n throw new EventHandlerException(\"The local service dispatcher is null\");\n }\n DispatchContext dctx = dispatcher.getDispatchContext();\n if (dctx == null) {\n throw new EventHandlerException(\"Dispatch context cannot be found\");\n }\n\n // get the details for the service(s) to call\n String mode = SYNC;\n String serviceName = null;\n\n if (UtilValidate.isEmpty(event.getPath())) {\n mode = SYNC;\n } else {\n mode = event.getPath();\n }\n\n // we only support SYNC mode in this handler\n if (!SYNC.equals(mode)) {\n throw new EventHandlerException(\"Async mode is not supported\");\n }\n\n // nake sure we have a defined service to call\n serviceName = event.getInvoke();\n if (serviceName == null) {\n throw new EventHandlerException(\"Service name (eventMethod) cannot be null\");\n }\n if (Debug.verboseOn()) {\n Debug.logVerbose(\"[Set mode/service]: \" + mode + \"/\" + serviceName, MODULE);\n }\n\n // some needed info for when running the service\n Locale locale = UtilHttp.getLocale(request);\n TimeZone timeZone = UtilHttp.getTimeZone(request);\n HttpSession session = request.getSession();\n GenericValue userLogin = (GenericValue) session.getAttribute(\"userLogin\");\n\n // get the service model to generate context(s)\n ModelService modelService = null;\n\n try {\n modelService = dctx.getModelService(serviceName);\n } catch (GenericServiceException e) {\n throw new EventHandlerException(\"Problems getting the service model\", e);\n }\n\n if (modelService == null) {\n throw new EventHandlerException(\"Problems getting the service model\");\n }\n\n if (Debug.verboseOn()) {\n Debug.logVerbose(\"[Processing]: SERVICE Event\", MODULE);\n }\n if (Debug.verboseOn()) {\n Debug.logVerbose(\"[Using delegator]: \" + dispatcher.getDelegator().getDelegatorName(), MODULE);\n }\n\n // check if we are using per row submit\n boolean useRowSubmit = request.getParameter(\"_useRowSubmit\") == null ? false\n : \"Y\".equalsIgnoreCase(request.getParameter(\"_useRowSubmit\"));\n\n // check if we are to also look in a global scope (no delimiter)\n boolean checkGlobalScope = request.getParameter(\"_checkGlobalScope\") == null ? true\n : !\"N\".equalsIgnoreCase(request.getParameter(\"_checkGlobalScope\"));\n\n // The number of multi form rows is retrieved\n int rowCount = UtilHttp.getMultiFormRowCount(request);\n if (rowCount < 1) {\n throw new EventHandlerException(\"No rows to process\");\n }\n\n // some default message settings\n String errorPrefixStr = UtilProperties.getMessage(\"DefaultMessagesUiLabels\", \"service.error.prefix\", locale);\n String errorSuffixStr = UtilProperties.getMessage(\"DefaultMessagesUiLabels\", \"service.error.suffix\", locale);\n String messagePrefixStr = UtilProperties.getMessage(\"DefaultMessagesUiLabels\", \"service.message.prefix\", locale);\n String messageSuffixStr = UtilProperties.getMessage(\"DefaultMessagesUiLabels\", \"service.message.suffix\", locale);\n\n // prepare the error message and success message lists\n List<Object> errorMessages = new LinkedList<>();\n List<String> successMessages = new LinkedList<>();\n\n boolean eventGlobalTransaction = event.isGlobalTransaction();\n\n // big try/finally to make sure commit or rollback are run\n boolean beganTrans = false;\n String returnString = null;\n try {\n if (eventGlobalTransaction) {\n // start the global transaction\n try {\n beganTrans = TransactionUtil.begin(modelService.getTransactionTimeout() * rowCount);\n } catch (GenericTransactionException e) {\n throw new EventHandlerException(\"Problem starting multi-service global transaction\", e);\n }\n }\n\n // now loop throw the rows and prepare/invoke the service for each\n for (int i = 0; i < rowCount; i++) {\n String curSuffix = UtilHttp.getMultiRowDelimiter() + i;\n boolean rowSelected = false;\n if (UtilValidate.isNotEmpty(request.getAttribute(UtilHttp.getRowSubmitPrefix() + i))) {\n rowSelected = request.getAttribute(UtilHttp.getRowSubmitPrefix() + i) == null ? false\n : \"Y\".equalsIgnoreCase((String) request.getAttribute(UtilHttp.getRowSubmitPrefix() + i));\n } else {\n rowSelected = request.getParameter(UtilHttp.getRowSubmitPrefix() + i) == null ? false\n : \"Y\".equalsIgnoreCase(request.getParameter(UtilHttp.getRowSubmitPrefix() + i));\n }\n\n // make sure we are to process this row\n if (useRowSubmit && !rowSelected) {\n continue;\n }\n\n // build the context\n Map<String, Object> serviceContext = new HashMap<>();\n for (ModelParam modelParam: modelService.getInModelParamList()) {\n String paramName = modelParam.getName();\n\n // Debug.logInfo(\"In ServiceMultiEventHandler processing input parameter [\" + modelParam.name +\n // (modelParam.optional?\"(optional):\":\"(required):\") + modelParam.mode + \"] for service [\" + serviceName + \"]\", MODULE);\n\n // don't include userLogin, that's taken care of below\n if (\"userLogin\".equals(paramName)) continue;\n // don't include locale, that is also taken care of below\n if (\"locale\".equals(paramName)) continue;\n // don't include timeZone, that is also taken care of below\n if (\"timeZone\".equals(paramName)) continue;\n\n Object value = null;\n if (UtilValidate.isNotEmpty(modelParam.getStringMapPrefix())) {\n Map<String, Object> paramMap = UtilHttp.makeParamMapWithPrefix(request, modelParam.getStringMapPrefix(), curSuffix);\n value = paramMap;\n } else if (UtilValidate.isNotEmpty(modelParam.getStringListSuffix())) {\n List<Object> paramList = UtilHttp.makeParamListWithSuffix(request, modelParam.getStringListSuffix(), null);\n value = paramList;\n } else {\n // check attributes; do this before parameters so that attribute which can be changed by code can\n // override parameters which can't\n value = request.getAttribute(paramName + curSuffix);\n\n // first check for request parameters\n if (value == null) {\n String name = paramName + curSuffix;\n\n String[] paramArr = request.getParameterValues(name);\n if (paramArr != null) {\n if (paramArr.length > 1) {\n value = Arrays.asList(paramArr);\n } else {\n value = paramArr[0];\n }\n }\n }\n\n // if the parameter wasn't passed and no other value found, check the session\n if (value == null) {\n value = session.getAttribute(paramName + curSuffix);\n }\n\n // now check global scope\n if (value == null) {\n if (checkGlobalScope) {\n String[] gParamArr = request.getParameterValues(paramName);\n if (gParamArr != null) {\n if (gParamArr.length > 1) {\n value = Arrays.asList(gParamArr);\n } else {\n value = gParamArr[0];\n }\n }\n if (value == null) {\n value = request.getAttribute(paramName);\n }\n if (value == null) {\n value = session.getAttribute(paramName);\n }\n }\n }\n\n // make any composite parameter data (e.g., from a set of parameters {name_c_date, name_c_hour, name_c_minutes})\n if (value == null) {\n value = UtilHttp.makeParamValueFromComposite(request, paramName + curSuffix);\n }\n\n if (value == null) {\n // still null, give up for this one\n continue;\n }\n\n if (value instanceof String && ((String) value).isEmpty()) {\n // interpreting empty fields as null values for each in back end handling...\n value = null;\n }\n }\n // set even if null so that values will get nulled in the db later on\n serviceContext.put(paramName, value);\n\n // Debug.logInfo(\"In ServiceMultiEventHandler got value [\" + value + \"] for input parameter [\" + paramName + \"] for service [\"\n // + serviceName + \"]\", MODULE);\n }\n\n // get only the parameters for this service - converted to proper type\n serviceContext = modelService.makeValid(serviceContext, ModelService.IN_PARAM, true, null, timeZone, locale);\n\n // include the UserLogin value object\n if (userLogin != null) {\n serviceContext.put(\"userLogin\", userLogin);\n }\n\n // include the Locale object\n if (locale != null) {\n serviceContext.put(\"locale\", locale);\n }\n\n // include the TimeZone object\n if (timeZone != null) {\n serviceContext.put(\"timeZone\", timeZone);\n }\n\n // Debug.logInfo(\"ready to call \" + serviceName + \" with context \" + serviceContext, MODULE);\n\n // invoke the service\n Map<String, Object> result = null;\n try {\n result = dispatcher.runSync(serviceName, serviceContext);\n } catch (ServiceAuthException e) {\n // not logging since the service engine already did\n errorMessages.add(messagePrefixStr + \"Service invocation error on row (\" + i + \"): \" + e.getNonNestedMessage());\n } catch (ServiceValidationException e) {\n // not logging since the service engine already did\n request.setAttribute(\"serviceValidationException\", e);\n List<String> errors = e.getMessageList();\n if (errors != null) {\n for (String message: errors) {\n errorMessages.add(\"Service invocation error on row (\" + i + \"): \" + message);\n }\n } else {\n errorMessages.add(messagePrefixStr + \"Service invocation error on row (\" + i + \"): \" + e.getNonNestedMessage());\n }\n } catch (GenericServiceException e) {\n Debug.logError(e, \"Service invocation error\", MODULE);\n errorMessages.add(messagePrefixStr + \"Service invocation error on row (\" + i + \"): \" + e.getNested() + messageSuffixStr);\n }\n\n if (result == null) {\n returnString = ModelService.RESPOND_SUCCESS;\n } else {\n // check for an error message\n String errorMessage = ServiceUtil.makeErrorMessage(result, messagePrefixStr, messageSuffixStr, \"\", \"\");\n if (UtilValidate.isNotEmpty(errorMessage)) {\n errorMessages.add(errorMessage);\n }\n\n // get the success messages\n if (UtilValidate.isNotEmpty(result.get(ModelService.SUCCESS_MESSAGE))) {\n String newSuccessMessage = (String) result.get(ModelService.SUCCESS_MESSAGE);\n if (!successMessages.contains(newSuccessMessage)) {\n successMessages.add(newSuccessMessage);\n }\n }\n if (UtilValidate.isNotEmpty(result.get(ModelService.SUCCESS_MESSAGE_LIST))) {\n List<String> newSuccessMessages = UtilGenerics.cast(result.get(ModelService.SUCCESS_MESSAGE_LIST));\n for (int j = 0; j < newSuccessMessages.size(); j++) {\n String newSuccessMessage = newSuccessMessages.get(j);\n if (!successMessages.contains(newSuccessMessage)) {\n successMessages.add(newSuccessMessage);\n }\n }\n }\n }\n // set the results in the request\n if ((result != null) && (result.entrySet() != null)) {\n for (Map.Entry<String, Object> rme: result.entrySet()) {\n String resultKey = rme.getKey();\n Object resultValue = rme.getValue();\n\n if (resultKey != null && !ModelService.RESPONSE_MESSAGE.equals(resultKey) && !ModelService.ERROR_MESSAGE.equals(resultKey)\n && !ModelService.ERROR_MESSAGE_LIST.equals(resultKey) && !ModelService.ERROR_MESSAGE_MAP.equals(resultKey)\n && !ModelService.SUCCESS_MESSAGE.equals(resultKey) && !ModelService.SUCCESS_MESSAGE_LIST.equals(resultKey)) {\n //set the result to request w/ and w/o a suffix to handle both cases: to have the result in each iteration and to prevent\n // its overriding\n request.setAttribute(resultKey + curSuffix, resultValue);\n request.setAttribute(resultKey, resultValue);\n }\n }\n }\n }\n } finally {\n if (!errorMessages.isEmpty()) {\n if (eventGlobalTransaction) {\n // rollback the global transaction\n try {\n TransactionUtil.rollback(beganTrans, \"Error in multi-service event handling: \" + errorMessages.toString(), null);\n } catch (GenericTransactionException e) {\n Debug.logError(e, \"Could not rollback multi-service global transaction\", MODULE);\n }\n }\n errorMessages.add(0, errorPrefixStr);\n errorMessages.add(errorSuffixStr);\n StringBuilder errorBuf = new StringBuilder();\n for (Object em: errorMessages) {\n errorBuf.append(em + \"\\n\");\n }\n request.setAttribute(\"_ERROR_MESSAGE_\", errorBuf.toString());\n returnString = \"error\";\n } else {\n if (eventGlobalTransaction) {\n // commit the global transaction\n try {\n TransactionUtil.commit(beganTrans);\n } catch (GenericTransactionException e) {\n Debug.logError(e, \"Could not commit multi-service global transaction\", MODULE);\n throw new EventHandlerException(\"Commit multi-service global transaction failed\");\n }\n }\n if (!successMessages.isEmpty()) {\n request.setAttribute(\"_EVENT_MESSAGE_LIST_\", successMessages);\n }\n returnString = \"success\";\n }\n }\n\n return returnString;\n }",
"public interface ActionCallBack {\n void acceptOrder(int position);\n void cancelOrder(int position);\n void readyToDeliver(int position);\n void showDetails(int position);\n\n\n\n}",
"public interface IRequest {\n void onRequestStart();\n\n void onRequestEnd();\n\n}",
"public interface IAction {\n /**\n * request dispatcher.\n * @param request objet resuete\n * @param response objet reponse\n * @return String return if the response is ok or ko\n */\n String execute(HttpServletRequest request, HttpServletResponse response);\n}",
"public interface IRequest {\n\n void onRequestStart();\n void onRequestEnd();\n}",
"@Override\n\tpublic List<Map<String,String>> dispatchRequest(Map<String, String[]> request) {\n\n\t\t// ********* LOGGING ********* \n\t\tSystem.out.println(\"reached DispatchRequest\");\n\t\tSystem.out.println(\"Request Keys : \");\n\t\tSystem.out.println(request.keySet());\n\t\t// ********* LOGGING ********* \n\n\n\t\tString classPrefix = request.get(\"requestID\")[0]; \n\n\t\t// ********* LOGGING ********* \n\t\tSystem.out.println(\"class name : \"+PACKAGE_NAME+classPrefix+CLASS_SUFFIX);\n\t\t// ********* LOGGING ********* \n\n\t\t// obtain class reference\t\t\n\t\tiManagementRequestHandlerObject = (IManagementRequestHandler) \n\t\t\t\tiReflectionManagerObject.getClass(PACKAGE_NAME+classPrefix+CLASS_SUFFIX);\n\n\t\t// ********* LOGGING *********\n\t\tSystem.out.println(\"object reference : \"+ iManagementRequestHandlerObject);\n\t\t// ********* LOGGING *********\n\n\t\t// Delegate the request to the appropriate class.\n\t\treturn (iManagementRequestHandlerObject.handleManagementRequest(request));\n\n\t}",
"public abstract void execute(String correlationId, ServiceRegistration sr, ServiceInput input);",
"public interface IQuestionInformationHandler\n{\n public void performQuestionaryRequest();\n public void sendQuestionaryInformation();\n}",
"public interface INetworkInterface {\n\n\n void getListOfItems(Callback<ListOfItems> callBack);\n\n void getDetailsItemsList(String id, Callback<DetailsListOfItems> callBack);\n\n void getLocationFromApi(String ltLong, String sensor, Callback<GoogleAPILocation> geoLocationCallback);\n\n\n}",
"public interface CommunicationService {\n public String postDeployment(UnitDeliveryResource unitDeliveryResource);\n\n public String postService(UnitServiceResource unitServiceResource);\n\n public boolean checkLocality(UnitDeliveryResource unitDeliveryResource);\n\n public List<SiteReource> getSites();\n}",
"public interface IRegModel extends BaseModel {\n void sendValidateRequest(ValidateRequest validateRequest, OnRequestResponse<ValidateResponse> onRequestResponse);\n\n void sendRegRequest(RegRequest regRequest, OnRequestResponse<RegResponse> onRequestResponse);\n\n void sendValiadateConfirmRequest(RegRequest regRequest, OnRequestResponse<ValidateResponse> onRequestResponse);\n}",
"public interface SendService {\n\n void send(String exchange,String routingKey,String content);\n}",
"public interface Target {\n void handleRequest();\n}",
"public interface XmlService {\n\n\t/**\n\t * Parse response file.\n\t * \n\t * @param xmlPath\n\t * @param orderId\n\t * @param complete_on\n\t * @return\n\t * @throws JAXBException\n\t */\n ResponseMQ parseResponseFile(String xmlPath, Long orderId, Date complete_on) throws JAXBException;\n \n /**\n * \n * @param xml\n * @param orderId\n * @param complete_on\n * @return\n * @throws JAXBException\n */\n\tResponseMQ parseResponse(String xml, Long orderId, Date complete_on) throws JAXBException;\n\n\t/**\n\t * Generate change status request.\n\t * \n\t * @param requestMQ\n\t * @return result string or NULL\n\t */\n\tString generateChangeStatusRequest(RequestMQ requestMQ);\n\t\n}",
"public interface MessageSender {\n boolean handle(Context context, MessageResponse response);\n}",
"public interface PaymentCallBackFacade {\n\n CommonResp callback(NotifyTradeStatusReq notifyTradeStatusReq);\n}",
"public interface RMASubmitCaller {\n\t/*\n\t * Command define from Order Confirmation API Guide JSON and XML format\n\t */\n\t@Headers({ \"Accept: application/json\", \"Content-Type: application/json\" })\n\t@RequestLine(\"POST /servicemgmt/rma/newrma?sellerid={sellerid}&version={version}\")\n\tSubmitRMAResponse sendRMASubmitRequestJSON(@Param(\"sellerid\") String sellerID, @Param(\"version\") String version,\n\t\t\tSubmitRMARequest body);\n\n\t@Headers({ \"Accept: application/xml\", \"Content-Type: application/xml\" })\n\t@RequestLine(\"POST /servicemgmt/rma/newrma?sellerid={sellerid}&version={version}\")\n\tSubmitRMAResponse sendRMASubmitRequestXML(@Param(\"sellerid\") String sellerID, @Param(\"version\") String version,\n\t\t\tSubmitRMARequest body);\n\n\t// Implement default method of interface class that according to\n\t// Variables.MediaType to run at JSON or XML request.\n\tdefault SubmitRMAResponse sendRMASubmitRequest(SubmitRMARequest body, String version) {\n\t\tswitch (Variables.MediaType) {\n\t\tcase JSON:\n\t\t\tif (Variables.SimulationEnabled)\n\t\t\t\treturn sendRMASubmitRequestJSON(Content.SellerID, \"307\", body);\n\t\t\telse\n\t\t\t\treturn sendRMASubmitRequestJSON(Content.SellerID, version, body);\n\n\t\tcase XML:\n\t\t\tif (Variables.SimulationEnabled)\n\t\t\t\treturn sendRMASubmitRequestXML(Content.SellerID, \"307\", body);\n\t\t\telse\n\t\t\t\treturn sendRMASubmitRequestXML(Content.SellerID, version, body);\n\n\t\tdefault:\n\t\t\tthrow new RuntimeException(\"Never Happened!\");\n\t\t}\n\n\t}\n\n\tstatic RMASubmitCaller buildJSON() {\n\t\tVariables.MediaType = MEDIA_TYPE.JSON;\n\n\t\treturn new CallerFactory<RMASubmitCaller>().jsonBuild(RMASubmitCaller.class, Variables.LogLevel,\n\t\t\t\tVariables.Retryer, RMAClient.genClient());\n\t}\n\n\tstatic RMASubmitCaller buildXML() {\n\t\tVariables.MediaType = MEDIA_TYPE.XML;\n\n\t\treturn new CallerFactory<RMASubmitCaller>().xmlBuild(RMASubmitCaller.class, Variables.LogLevel,\n\t\t\t\tVariables.Retryer, RMAClient.genClient());\n\t}\n\n}",
"public interface IServiceDriverCommunication {\n\n /**\n * This method is called when a network message is received.\n *\n * @param message\n * Network message.\n * @param <T>\n * Message object type.\n */\n <T> void onNetworkMessage(NetworkMessage<T> message) throws NetworkDriverException;\n\n /**\n * This method is called when a network event is received.\n *\n * @param event\n * Network event.\n */\n void onNetworkEvent(NetworkEvent event);\n}",
"public interface MetaInformationService extends BasicEcomService{\n\n public String listMetaInformationTypesForPage(String page);\n public Integer getTotalPagesForMetaInformationTypes();\n public Integer getTotalPagesForSearchedMetaInformationTypes(String metaType);\n public String listSearchedMetaInformationTypesForPage(String metaType,String page);\n\n\n}",
"public interface IHttpRequestHandler extends INamedObject\r\n{\t\r\n public HandlerResponse handleRequest( HttpRequestData httpRequest ) throws IOException;\r\n}",
"public interface RpcProcessorFactory {\n\n\n RpcProcessor getProcessor(\n String rpcMethod\n );\n\n\n}",
"public interface OIMBizLocal {\n \n public void localOp();\n \n public void processEvent(BusinessEvent event);\n}",
"public interface ApiAction {}",
"public interface IProcessor {\n\n Object onMsgHandle(int cmdId, Object... arg);\n}",
"@Override\n public void onDelectFlightInfo(ServResrouce info)\n {\n }",
"@Override\n public void onDelectFlightInfo(ServResrouce info)\n {\n }",
"@Override\n protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n super.service(req, resp);\n logger.log(Level.INFO, \"service(req, resp) Invoked\");\n }",
"public interface RequestFunction {}",
"protected interface Dispatcher {\n\n /**\n * Invokes the proxied action.\n *\n * @param argument The arguments provided.\n * @return The return value.\n * @throws Throwable If any error occurs.\n */\n @MaybeNull\n Object invoke(Object[] argument) throws Throwable;\n\n /**\n * Implements this dispatcher in a generated proxy.\n *\n * @param methodVisitor The method visitor to implement the method with.\n * @param method The method being implemented.\n * @return The maximal size of the operand stack.\n */\n int apply(MethodVisitor methodVisitor, Method method);\n\n /**\n * A dispatcher that performs an instance check.\n */\n @HashCodeAndEqualsPlugin.Enhance\n class ForInstanceCheck implements Dispatcher {\n\n /**\n * The checked type.\n */\n private final Class<?> target;\n\n /**\n * Creates a dispatcher for an instance check.\n *\n * @param target The checked type.\n */\n protected ForInstanceCheck(Class<?> target) {\n this.target = target;\n }\n\n /**\n * {@inheritDoc}\n */\n public Object invoke(Object[] argument) {\n return target.isInstance(argument[0]);\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n methodVisitor.visitVarInsn(Opcodes.ALOAD, 1);\n methodVisitor.visitTypeInsn(Opcodes.INSTANCEOF, Type.getInternalName(target));\n methodVisitor.visitInsn(Opcodes.IRETURN);\n return 1;\n }\n }\n\n /**\n * A dispatcher that creates an array.\n */\n @HashCodeAndEqualsPlugin.Enhance\n class ForContainerCreation implements Dispatcher {\n\n /**\n * The component type.\n */\n private final Class<?> target;\n\n /**\n * Creates a dispatcher for an array creation.\n *\n * @param target The component type.\n */\n protected ForContainerCreation(Class<?> target) {\n this.target = target;\n }\n\n /**\n * {@inheritDoc}\n */\n public Object invoke(Object[] argument) {\n return Array.newInstance(target, (Integer) argument[0]);\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n methodVisitor.visitVarInsn(Opcodes.ILOAD, 1);\n methodVisitor.visitTypeInsn(Opcodes.ANEWARRAY, Type.getInternalName(target));\n methodVisitor.visitInsn(Opcodes.ARETURN);\n return 1;\n }\n }\n\n /**\n * A dispatcher that returns a fixed value.\n */\n enum ForDefaultValue implements Dispatcher {\n\n /**\n * A dispatcher for a {@code void} type.\n */\n VOID(null, Opcodes.NOP, Opcodes.RETURN, 0),\n\n /**\n * A dispatcher for a {@code boolean} type.\n */\n BOOLEAN(false, Opcodes.ICONST_0, Opcodes.IRETURN, 1),\n\n /**\n * A dispatcher for a {@code boolean} type that returns {@code true}.\n */\n BOOLEAN_REVERSE(true, Opcodes.ICONST_1, Opcodes.IRETURN, 1),\n\n /**\n * A dispatcher for a {@code byte} type.\n */\n BYTE((byte) 0, Opcodes.ICONST_0, Opcodes.IRETURN, 1),\n\n /**\n * A dispatcher for a {@code short} type.\n */\n SHORT((short) 0, Opcodes.ICONST_0, Opcodes.IRETURN, 1),\n\n /**\n * A dispatcher for a {@code char} type.\n */\n CHARACTER((char) 0, Opcodes.ICONST_0, Opcodes.IRETURN, 1),\n\n /**\n * A dispatcher for an {@code int} type.\n */\n INTEGER(0, Opcodes.ICONST_0, Opcodes.IRETURN, 1),\n\n /**\n * A dispatcher for a {@code long} type.\n */\n LONG(0L, Opcodes.LCONST_0, Opcodes.LRETURN, 2),\n\n /**\n * A dispatcher for a {@code float} type.\n */\n FLOAT(0f, Opcodes.FCONST_0, Opcodes.FRETURN, 1),\n\n /**\n * A dispatcher for a {@code double} type.\n */\n DOUBLE(0d, Opcodes.DCONST_0, Opcodes.DRETURN, 2),\n\n /**\n * A dispatcher for a reference type.\n */\n REFERENCE(null, Opcodes.ACONST_NULL, Opcodes.ARETURN, 1);\n\n /**\n * The default value.\n */\n @MaybeNull\n private final Object value;\n\n /**\n * The opcode to load the default value.\n */\n private final int load;\n\n /**\n * The opcode to return the default value.\n */\n private final int returned;\n\n /**\n * The operand stack size of default value.\n */\n private final int size;\n\n /**\n * Creates a new default value dispatcher.\n *\n * @param value The default value.\n * @param load The opcode to load the default value.\n * @param returned The opcode to return the default value.\n * @param size The operand stack size of default value.\n */\n ForDefaultValue(@MaybeNull Object value, int load, int returned, int size) {\n this.value = value;\n this.load = load;\n this.returned = returned;\n this.size = size;\n }\n\n /**\n * Resolves a fixed value for a given type.\n *\n * @param type The type to resolve.\n * @return An appropriate dispatcher.\n */\n protected static Dispatcher of(Class<?> type) {\n if (type == void.class) {\n return VOID;\n } else if (type == boolean.class) {\n return BOOLEAN;\n } else if (type == byte.class) {\n return BYTE;\n } else if (type == short.class) {\n return SHORT;\n } else if (type == char.class) {\n return CHARACTER;\n } else if (type == int.class) {\n return INTEGER;\n } else if (type == long.class) {\n return LONG;\n } else if (type == float.class) {\n return FLOAT;\n } else if (type == double.class) {\n return DOUBLE;\n } else if (type.isArray()) {\n if (type.getComponentType() == boolean.class) {\n return OfPrimitiveArray.BOOLEAN;\n } else if (type.getComponentType() == byte.class) {\n return OfPrimitiveArray.BYTE;\n } else if (type.getComponentType() == short.class) {\n return OfPrimitiveArray.SHORT;\n } else if (type.getComponentType() == char.class) {\n return OfPrimitiveArray.CHARACTER;\n } else if (type.getComponentType() == int.class) {\n return OfPrimitiveArray.INTEGER;\n } else if (type.getComponentType() == long.class) {\n return OfPrimitiveArray.LONG;\n } else if (type.getComponentType() == float.class) {\n return OfPrimitiveArray.FLOAT;\n } else if (type.getComponentType() == double.class) {\n return OfPrimitiveArray.DOUBLE;\n } else {\n return OfNonPrimitiveArray.of(type.getComponentType());\n }\n } else {\n return REFERENCE;\n }\n }\n\n /**\n * {@inheritDoc}\n */\n @MaybeNull\n public Object invoke(Object[] argument) {\n return value;\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n if (load != Opcodes.NOP) {\n methodVisitor.visitInsn(load);\n }\n methodVisitor.visitInsn(returned);\n return size;\n }\n\n /**\n * A dispatcher for returning a default value for a primitive array.\n */\n protected enum OfPrimitiveArray implements Dispatcher {\n\n /**\n * A dispatcher for a {@code boolean} array.\n */\n BOOLEAN(new boolean[0], Opcodes.T_BOOLEAN),\n\n /**\n * A dispatcher for a {@code byte} array.\n */\n BYTE(new byte[0], Opcodes.T_BYTE),\n\n /**\n * A dispatcher for a {@code short} array.\n */\n SHORT(new short[0], Opcodes.T_SHORT),\n\n /**\n * A dispatcher for a {@code char} array.\n */\n CHARACTER(new char[0], Opcodes.T_CHAR),\n\n /**\n * A dispatcher for a {@code int} array.\n */\n INTEGER(new int[0], Opcodes.T_INT),\n\n /**\n * A dispatcher for a {@code long} array.\n */\n LONG(new long[0], Opcodes.T_LONG),\n\n /**\n * A dispatcher for a {@code float} array.\n */\n FLOAT(new float[0], Opcodes.T_FLOAT),\n\n /**\n * A dispatcher for a {@code double} array.\n */\n DOUBLE(new double[0], Opcodes.T_DOUBLE);\n\n /**\n * The default value.\n */\n private final Object value;\n\n /**\n * The operand for creating an array of the represented type.\n */\n private final int operand;\n\n /**\n * Creates a new dispatcher for a primitive array.\n *\n * @param value The default value.\n * @param operand The operand for creating an array of the represented type.\n */\n OfPrimitiveArray(Object value, int operand) {\n this.value = value;\n this.operand = operand;\n }\n\n /**\n * {@inheritDoc}\n */\n public Object invoke(Object[] argument) {\n return value;\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n methodVisitor.visitInsn(Opcodes.ICONST_0);\n methodVisitor.visitIntInsn(Opcodes.NEWARRAY, operand);\n methodVisitor.visitInsn(Opcodes.ARETURN);\n return 1;\n }\n }\n\n /**\n * A dispatcher for a non-primitive array type.\n */\n @HashCodeAndEqualsPlugin.Enhance\n protected static class OfNonPrimitiveArray implements Dispatcher {\n\n /**\n * The default value.\n */\n @HashCodeAndEqualsPlugin.ValueHandling(HashCodeAndEqualsPlugin.ValueHandling.Sort.IGNORE)\n private final Object value;\n\n /**\n * The represented component type.\n */\n private final Class<?> componentType;\n\n /**\n * Creates a new dispatcher for the default value of a non-primitive array.\n *\n * @param value The default value.\n * @param componentType The represented component type.\n */\n protected OfNonPrimitiveArray(Object value, Class<?> componentType) {\n this.value = value;\n this.componentType = componentType;\n }\n\n /**\n * Creates a new dispatcher.\n *\n * @param componentType The represented component type.\n * @return A dispatcher for the supplied component type.\n */\n protected static Dispatcher of(Class<?> componentType) {\n return new OfNonPrimitiveArray(Array.newInstance(componentType, 0), componentType);\n }\n\n /**\n * {@inheritDoc}\n */\n public Object invoke(Object[] argument) {\n return value;\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n methodVisitor.visitInsn(Opcodes.ICONST_0);\n methodVisitor.visitTypeInsn(Opcodes.ANEWARRAY, Type.getInternalName(componentType));\n methodVisitor.visitInsn(Opcodes.ARETURN);\n return 1;\n }\n }\n }\n\n /**\n * A dispatcher for invoking a constructor.\n */\n @HashCodeAndEqualsPlugin.Enhance\n class ForConstructor implements Dispatcher {\n\n /**\n * The proxied constructor.\n */\n private final Constructor<?> constructor;\n\n /**\n * Creates a dispatcher for invoking a constructor.\n *\n * @param constructor The proxied constructor.\n */\n protected ForConstructor(Constructor<?> constructor) {\n this.constructor = constructor;\n }\n\n /**\n * {@inheritDoc}\n */\n public Object invoke(Object[] argument) throws Throwable {\n return INVOKER.newInstance(constructor, argument);\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n Class<?>[] source = method.getParameterTypes(), target = constructor.getParameterTypes();\n methodVisitor.visitTypeInsn(Opcodes.NEW, Type.getInternalName(constructor.getDeclaringClass()));\n methodVisitor.visitInsn(Opcodes.DUP);\n int offset = 1;\n for (int index = 0; index < source.length; index++) {\n Type type = Type.getType(source[index]);\n methodVisitor.visitVarInsn(type.getOpcode(Opcodes.ILOAD), offset);\n if (source[index] != target[index]) {\n methodVisitor.visitTypeInsn(Opcodes.CHECKCAST, Type.getInternalName(target[index]));\n }\n offset += type.getSize();\n }\n methodVisitor.visitMethodInsn(Opcodes.INVOKESPECIAL,\n Type.getInternalName(constructor.getDeclaringClass()),\n MethodDescription.CONSTRUCTOR_INTERNAL_NAME,\n Type.getConstructorDescriptor(constructor),\n false);\n methodVisitor.visitInsn(Opcodes.ARETURN);\n return offset + 1;\n }\n }\n\n /**\n * A dispatcher for invoking a static proxied method.\n */\n @HashCodeAndEqualsPlugin.Enhance\n class ForStaticMethod implements Dispatcher {\n\n /**\n * The proxied method.\n */\n private final Method method;\n\n /**\n * Creates a dispatcher for invoking a static method.\n *\n * @param method The proxied method.\n */\n protected ForStaticMethod(Method method) {\n this.method = method;\n }\n\n /**\n * {@inheritDoc}\n */\n @MaybeNull\n public Object invoke(Object[] argument) throws Throwable {\n return INVOKER.invoke(method, null, argument);\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n Class<?>[] source = method.getParameterTypes(), target = this.method.getParameterTypes();\n int offset = 1;\n for (int index = 0; index < source.length; index++) {\n Type type = Type.getType(source[index]);\n methodVisitor.visitVarInsn(type.getOpcode(Opcodes.ILOAD), offset);\n if (source[index] != target[index]) {\n methodVisitor.visitTypeInsn(Opcodes.CHECKCAST, Type.getInternalName(target[index]));\n }\n offset += type.getSize();\n }\n methodVisitor.visitMethodInsn(Opcodes.INVOKESTATIC,\n Type.getInternalName(this.method.getDeclaringClass()),\n this.method.getName(),\n Type.getMethodDescriptor(this.method),\n this.method.getDeclaringClass().isInterface());\n methodVisitor.visitInsn(Type.getReturnType(this.method).getOpcode(Opcodes.IRETURN));\n return Math.max(offset - 1, Type.getReturnType(this.method).getSize());\n }\n }\n\n /**\n * A dispatcher for invoking a non-static proxied method.\n */\n @HashCodeAndEqualsPlugin.Enhance\n class ForNonStaticMethod implements Dispatcher {\n\n /**\n * Indicates a call without arguments.\n */\n private static final Object[] NO_ARGUMENTS = new Object[0];\n\n /**\n * The proxied method.\n */\n private final Method method;\n\n /**\n * Creates a dispatcher for invoking a non-static method.\n *\n * @param method The proxied method.\n */\n protected ForNonStaticMethod(Method method) {\n this.method = method;\n }\n\n /**\n * {@inheritDoc}\n */\n public Object invoke(Object[] argument) throws Throwable {\n Object[] reduced;\n if (argument.length == 1) {\n reduced = NO_ARGUMENTS;\n } else {\n reduced = new Object[argument.length - 1];\n System.arraycopy(argument, 1, reduced, 0, reduced.length);\n }\n return INVOKER.invoke(method, argument[0], reduced);\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n Class<?>[] source = method.getParameterTypes(), target = this.method.getParameterTypes();\n int offset = 1;\n for (int index = 0; index < source.length; index++) {\n Type type = Type.getType(source[index]);\n methodVisitor.visitVarInsn(type.getOpcode(Opcodes.ILOAD), offset);\n if (source[index] != (index == 0 ? this.method.getDeclaringClass() : target[index - 1])) {\n methodVisitor.visitTypeInsn(Opcodes.CHECKCAST, Type.getInternalName(index == 0\n ? this.method.getDeclaringClass()\n : target[index - 1]));\n }\n offset += type.getSize();\n }\n methodVisitor.visitMethodInsn(this.method.getDeclaringClass().isInterface() ? Opcodes.INVOKEINTERFACE : Opcodes.INVOKEVIRTUAL,\n Type.getInternalName(this.method.getDeclaringClass()),\n this.method.getName(),\n Type.getMethodDescriptor(this.method),\n this.method.getDeclaringClass().isInterface());\n methodVisitor.visitInsn(Type.getReturnType(this.method).getOpcode(Opcodes.IRETURN));\n return Math.max(offset - 1, Type.getReturnType(this.method).getSize());\n }\n }\n\n /**\n * A dispatcher for an unresolved method.\n */\n @HashCodeAndEqualsPlugin.Enhance\n class ForUnresolvedMethod implements Dispatcher {\n\n /**\n * The message for describing the reason why the method could not be resolved.\n */\n private final String message;\n\n /**\n * Creates a dispatcher for an unresolved method.\n *\n * @param message The message for describing the reason why the method could not be resolved.\n */\n protected ForUnresolvedMethod(String message) {\n this.message = message;\n }\n\n /**\n * {@inheritDoc}\n */\n public Object invoke(Object[] argument) throws Throwable {\n throw new IllegalStateException(\"Could not invoke proxy: \" + message);\n }\n\n /**\n * {@inheritDoc}\n */\n public int apply(MethodVisitor methodVisitor, Method method) {\n methodVisitor.visitTypeInsn(Opcodes.NEW, Type.getInternalName(IllegalStateException.class));\n methodVisitor.visitInsn(Opcodes.DUP);\n methodVisitor.visitLdcInsn(message);\n methodVisitor.visitMethodInsn(Opcodes.INVOKESPECIAL,\n Type.getInternalName(IllegalStateException.class),\n MethodDescription.CONSTRUCTOR_INTERNAL_NAME,\n Type.getMethodDescriptor(Type.VOID_TYPE, Type.getType(String.class)),\n false);\n methodVisitor.visitInsn(Opcodes.ATHROW);\n return 3;\n }\n }\n }",
"public interface HttpContract {\n\n WelfareService welfareHttp();\n\n}",
"public interface Handler {\n void handleRequest(String s);\n}",
"public interface MainRouter {\n void showWeather();\n\n void showSettings();\n\n void showAbout();\n}",
"public interface UHFCallbackLiatener {\n void refreshSettingCallBack(ReaderSetting readerSetting);\n void onInventoryTagCallBack(RXInventoryTag tag);\n void onInventoryTagEndCallBack(RXInventoryTag.RXInventoryTagEnd tagEnd);\n void onOperationTagCallBack(RXOperationTag tag);\n}",
"public interface RxViewDispatch {\n\n /**\n * All the stores will call this event after they process an action and the store change it.\n * The view can react and request the needed data\n */\n void onRxStoreChanged(@NonNull RxStoreChange change);\n\n\n}",
"public interface GetSerializerCallback\r\n{\r\n /**\r\n * Returns the serializer which shall be used for the specified response receiver id.\r\n * @param responseReceiverId response receiver id for which the implementation shall return the serializer.\r\n * @return\r\n */\r\n ISerializer invoke(String responseReceiverId);\r\n}",
"public interface ForecastItemHandler {\n\tvoid onForecastClicked(WeatherForecastResponse.Forecast forecast);\n}",
"public interface TelephoneCallRouter {\n\tpublic List<OperatorEntry> lookupPriceAtOpeartors(Long phonenumber);\n\tpublic Map<String,String> getCheapOperator(Long phonenumber);\n}",
"public interface Transport {\r\n /**\r\n * Prepares connection to server and returns connection output stream.\r\n * \r\n * @param info\r\n * connection information object containing target URL, content encoding, etc.\r\n * @return connection output stream\r\n * @throws TransportException\r\n */\r\n OutputStream prepare(ConnectionInfo info) throws TransportException;\r\n \r\n \r\n // this method used for wsg request -- by felix\r\n /**\r\n * Prepares connection to server and returns connection output stream.\r\n * \r\n * @param info\r\n * connection information object containing target URL, content encoding, etc.\r\n * @return connection output stream\r\n * @throws TransportException\r\n */\r\n void prepare(ConnectionInfo info,byte[] reqXml) throws TransportException;\r\n\tpublic InputStream configPrepare(ConnectionInfo info) throws TransportException;\r\n public InputStream prepareAndConnect(ConnectionInfo info) throws TransportException ;\r\n public void prepareWsgPost(ConnectionInfo info,byte[] reqXml) throws TransportException ;\r\n \r\n\r\n /**\r\n * Sends request to server and receives a response.\r\n * <em>{@link #prepare(ConnectionInfo)} should be called prior to performing an exchange.</em>\r\n * \r\n * @return input stream containing server response\r\n * \r\n * @throws TransportException\r\n */\r\n InputStream exchange() throws TransportException;\r\n\r\n /**\r\n * Closes any pending connections and frees transport resources.\r\n */\r\n void close();\r\n}",
"public interface LocationModel {\n void getLocation(Subscriber<CommonResult> subscriber, GetLocationParam param);\n\n void sendLocation(Subscriber<CommonResult> subscriber, SendLocationParam param);\n}",
"public interface IWxNotifyInfoService extends IBaseService<WxNotifyInfoModel> {\n\n}",
"public interface IMaintenanceEngineerService {\n\n void post(MaintenanceEngineerPayload payload, IErrorCallback callback);\n\n void get(Long id, IErrorCallback errorCallback);\n}",
"public interface IMyNewFirendView {\n\n public void onMyNewFirendGetFriendApplyListSuccess(List<ContactsFriend> datas);\n public void onMyNewFirendGetFriendApplyListFaile(String msg);\n\n public void onMyNewFirendConfirmApplySuccess(int confirm);\n public void onMyNewFirendConfirmApplyFaile(String msg, int confirm);\n\n}"
] | [
"0.6882834",
"0.6618683",
"0.63852787",
"0.6343007",
"0.6338396",
"0.6211582",
"0.619126",
"0.6143926",
"0.60249126",
"0.5946254",
"0.58677226",
"0.5860141",
"0.58310336",
"0.5830882",
"0.58164227",
"0.5790212",
"0.5782673",
"0.5777432",
"0.57675093",
"0.5759275",
"0.5728818",
"0.57264924",
"0.5721464",
"0.57182294",
"0.5717663",
"0.571667",
"0.5713827",
"0.5713302",
"0.5700176",
"0.56776243",
"0.56626403",
"0.56583226",
"0.565113",
"0.56505454",
"0.5645922",
"0.56424254",
"0.56211597",
"0.560102",
"0.55556",
"0.55555105",
"0.55433875",
"0.5538094",
"0.5535164",
"0.55255777",
"0.55244213",
"0.55207604",
"0.5513317",
"0.55128795",
"0.5501531",
"0.54939955",
"0.54910326",
"0.54887176",
"0.54713786",
"0.5471136",
"0.5469952",
"0.54669094",
"0.5466409",
"0.54647565",
"0.546452",
"0.54633063",
"0.5457012",
"0.5454619",
"0.54532474",
"0.54529107",
"0.54498875",
"0.5446048",
"0.5440296",
"0.5439235",
"0.54372084",
"0.5432334",
"0.5427517",
"0.5422218",
"0.54146147",
"0.541381",
"0.5408265",
"0.540801",
"0.54026246",
"0.5394822",
"0.53934824",
"0.53910184",
"0.5390944",
"0.53894794",
"0.53889704",
"0.5388459",
"0.5388459",
"0.53869826",
"0.53841287",
"0.5382959",
"0.5382006",
"0.53784037",
"0.5377319",
"0.53681874",
"0.5361351",
"0.53593516",
"0.53562945",
"0.53518975",
"0.5348697",
"0.53442633",
"0.534219",
"0.53365886",
"0.5336578"
] | 0.0 | -1 |
check if an additional interface is available, e.g. interface to a workflow engine | public abstract boolean hasInterface(String strInterfaceName_p); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean isInterface();",
"public boolean isInterface()\n {\n ensureLoaded();\n return m_flags.isInterface();\n }",
"public boolean checkInterface(Object obj) {\n return true;\n }",
"private boolean isSupportedInternal() {\n boolean z = false;\n synchronized (this.mLock) {\n if (this.mServiceManager == null) {\n Log.e(TAG, \"isSupported: called but mServiceManager is null!?\");\n return false;\n }\n try {\n if (this.mServiceManager.getTransport(IWifi.kInterfaceName, HAL_INSTANCE_NAME) != (byte) 0) {\n z = true;\n }\n } catch (RemoteException e) {\n Log.wtf(TAG, \"Exception while operating on IServiceManager: \" + e);\n return false;\n }\n }\n }",
"public boolean isRemoteInterface(Class paramClass) {\n/* 98 */ boolean bool = true;\n/* */ try {\n/* 100 */ validateRemoteInterface(paramClass);\n/* 101 */ } catch (IDLTypeException iDLTypeException) {\n/* 102 */ bool = false;\n/* */ } \n/* */ \n/* 105 */ return bool;\n/* */ }",
"public boolean isInterfaceConfigured() {\n\t\treturn (imsProxyAddr != null) && (imsProxyAddr.length() > 0);\n\t}",
"public interface IsisInterface {\n\n /**\n * Sets interface index.\n *\n * @param interfaceIndex interface index\n */\n void setInterfaceIndex(int interfaceIndex);\n\n /**\n * Sets intermediate system name.\n *\n * @param intermediateSystemName intermediate system name\n */\n void setIntermediateSystemName(String intermediateSystemName);\n\n /**\n * Sets system ID.\n *\n * @param systemId system ID\n */\n void setSystemId(String systemId);\n\n /**\n * Sets LAN ID.\n *\n * @param lanId LAN ID\n */\n void setLanId(String lanId);\n\n /**\n * Sets ID length.\n *\n * @param idLength ID length\n */\n void setIdLength(int idLength);\n\n /**\n * Sets max area addresses.\n *\n * @param maxAreaAddresses max area addresses\n */\n void setMaxAreaAddresses(int maxAreaAddresses);\n\n /**\n * Sets reserved packet circuit type.\n *\n * @param reservedPacketCircuitType reserved packet circuit type\n */\n void setReservedPacketCircuitType(int reservedPacketCircuitType);\n\n /**\n * Sets point to point.\n *\n * @param p2p point to point\n */\n void setP2p(int p2p);\n\n /**\n * Sets area address.\n *\n * @param areaAddress area address\n */\n void setAreaAddress(String areaAddress);\n\n /**\n * Sets area length.\n *\n * @param areaLength area length\n */\n void setAreaLength(int areaLength);\n\n /**\n * Sets link state packet ID.\n *\n * @param lspId link state packet ID\n */\n void setLspId(String lspId);\n\n /**\n * Sets holding time.\n *\n * @param holdingTime holding time\n */\n void setHoldingTime(int holdingTime);\n\n /**\n * Sets priority.\n *\n * @param priority priority\n */\n void setPriority(int priority);\n\n /**\n * Sets hello interval.\n *\n * @param helloInterval hello interval\n */\n void setHelloInterval(int helloInterval);\n}",
"public abstract boolean isAvailable();",
"public abstract boolean isAvailable();",
"public boolean isInterfaceInOutage(final String linterface, final Outage out) {\n if (out == null) return false;\n\n for (final Interface ointerface : out.getInterfaceCollection()) {\n if (ointerface.getAddress().equals(\"match-any\") || ointerface.getAddress().equals(linterface)) {\n return true;\n }\n }\n\n return false;\n }",
"boolean isDeclaredInInterface() {\n return (declaringClass != null) && (declaringClass.isInterface());\n }",
"private static boolean willGenerateExtentionFor(IInterfaceDefinition iDef, Environment base)\n \t{\n \t\treturn base.lookUpType(iDef.getName().getName()) != null && !isUtilityOrTemplateClass(iDef, base);\n \t}",
"public boolean isKnown();",
"interface Iface {\n void usedIface();\n}",
"public boolean implementsInterface(Class<?> ifType) {\n boolean result = false;\n\n if (ifList.contains(ifType)) {\n result = true;\n }\n return result;\n }",
"@Override\n public boolean isInterface() { return false; }",
"interface ExternalModuleChecker {\n\t/**\n\t * To check is external-module registered well\n\t *\n\t * @param module module to check\n\t * @return true if registered well\n\t */\n\tboolean isValidModule(ExternalModule module);\n}",
"public interface IsisInterface {\n\n /**\n * Returns interface index.\n *\n * @return interface index\n */\n int interfaceIndex();\n\n /**\n * Sets interface index.\n *\n * @param interfaceIndex interface index\n */\n void setInterfaceIndex(int interfaceIndex);\n\n /**\n * Returns the interface IP address.\n *\n * @return interface IP address\n */\n Ip4Address interfaceIpAddress();\n\n /**\n * Sets the interface IP address.\n *\n * @param interfaceIpAddress interface IP address interface IP address\n */\n void setInterfaceIpAddress(Ip4Address interfaceIpAddress);\n\n /**\n * Returns the network mask.\n *\n * @return network mask\n */\n byte[] networkMask();\n\n /**\n * Sets the network mask.\n *\n * @param networkMask network mask\n */\n void setNetworkMask(byte[] networkMask);\n\n /**\n * Sets the interface MAC address.\n *\n * @param interfaceMacAddress interface MAC address\n */\n void setInterfaceMacAddress(MacAddress interfaceMacAddress);\n\n /**\n * Returns the neighbors list.\n *\n * @return neighbors list\n */\n Set<MacAddress> neighbors();\n\n /**\n * Sets intermediate system name.\n *\n * @param intermediateSystemName intermediate system name\n */\n void setIntermediateSystemName(String intermediateSystemName);\n\n /**\n * Returns system ID.\n *\n * @return systemID system ID\n */\n String systemId();\n\n /**\n * Sets system ID.\n *\n * @param systemId system ID\n */\n void setSystemId(String systemId);\n\n /**\n * Returns LAN ID.\n *\n * @return LAN ID\n */\n String l1LanId();\n\n /**\n * Sets LAN ID.\n *\n * @param lanId LAN ID\n */\n void setL1LanId(String lanId);\n\n /**\n * Returns LAN ID.\n *\n * @return LAN ID\n */\n String l2LanId();\n\n /**\n * Sets LAN ID.\n *\n * @param lanId LAN ID\n */\n void setL2LanId(String lanId);\n\n /**\n * Sets ID length.\n *\n * @param idLength ID length\n */\n void setIdLength(int idLength);\n\n /**\n * Sets max area addresses.\n *\n * @param maxAreaAddresses max area addresses\n */\n void setMaxAreaAddresses(int maxAreaAddresses);\n\n /**\n * Returns reserved packet circuit type.\n *\n * @return reserved packet circuit type\n */\n int reservedPacketCircuitType();\n\n /**\n * Sets reserved packet circuit type.\n *\n * @param reservedPacketCircuitType reserved packet circuit type\n */\n void setReservedPacketCircuitType(int reservedPacketCircuitType);\n\n /**\n * Returns point to point or broadcast.\n *\n * @return 1 if point to point, 2 broadcast\n */\n IsisNetworkType networkType();\n\n /**\n * Sets point to point.\n *\n * @param networkType point to point\n */\n void setNetworkType(IsisNetworkType networkType);\n\n /**\n * Returns area address.\n *\n * @return area address\n */\n String areaAddress();\n\n /**\n * Sets area address.\n *\n * @param areaAddress area address\n */\n void setAreaAddress(String areaAddress);\n\n /**\n * Sets area length.\n *\n * @param areaLength area length\n */\n void setAreaLength(int areaLength);\n\n /**\n * Returns holding time.\n *\n * @return holding time\n */\n int holdingTime();\n\n /**\n * Sets holding time.\n *\n * @param holdingTime holding time\n */\n void setHoldingTime(int holdingTime);\n\n /**\n * Returns priority.\n *\n * @return priority\n */\n int priority();\n\n /**\n * Sets priority.\n *\n * @param priority priority\n */\n void setPriority(int priority);\n\n /**\n * Returns hello interval.\n *\n * @return hello interval\n */\n public int helloInterval();\n\n /**\n * Sets hello interval.\n *\n * @param helloInterval hello interval\n */\n void setHelloInterval(int helloInterval);\n\n /**\n * Starts the hello timer which sends hello packet every configured seconds.\n *\n * @param channel netty channel instance\n */\n void startHelloSender(Channel channel);\n\n /**\n * Stops the hello timer which sends hello packet every configured seconds.\n */\n void stopHelloSender();\n\n /**\n * Processes an ISIS message which is received on this interface.\n *\n * @param isisMessage ISIS message instance\n * @param isisLsdb ISIS LSDB instance\n * @param channel channel instance\n */\n void processIsisMessage(IsisMessage isisMessage, IsisLsdb isisLsdb, Channel channel);\n\n /**\n * Returns the interface state.\n *\n * @return interface state\n */\n IsisInterfaceState interfaceState();\n\n /**\n * Sets the interface state.\n *\n * @param interfaceState the interface state\n */\n void setInterfaceState(IsisInterfaceState interfaceState);\n\n /**\n * Returns the LSDB instance.\n *\n * @return LSDB instance\n */\n IsisLsdb isisLsdb();\n\n /**\n * Returns intermediate system name.\n *\n * @return intermediate system name\n */\n String intermediateSystemName();\n\n /**\n * Returns the ISIS neighbor instance if exists.\n *\n * @param isisNeighborMac mac address of the neighbor router\n * @return ISIS neighbor instance if exists else null\n */\n IsisNeighbor lookup(MacAddress isisNeighborMac);\n\n /**\n * Returns circuit ID.\n *\n * @return circuit ID\n */\n String circuitId();\n\n /**\n * Sets circuit ID.\n *\n * @param circuitId circuit ID\n */\n void setCircuitId(String circuitId);\n\n /**\n * Removes neighbor from the interface neighbor map.\n *\n * @param isisNeighbor ISIS neighbor instance\n */\n void removeNeighbor(IsisNeighbor isisNeighbor);\n\n /**\n * Removes all the neighbors.\n */\n void removeNeighbors();\n}",
"public interface MicroUSB {\n void isMicroUsb();\n}",
"protected static boolean meetsMechTypeRequirements(IType candidate){\n\t\tif(candidate == null){return false;}\n\t\t\n\t\ttry{\n\t\t\tString[] interfaces = candidate.getSuperInterfaceTypeSignatures();\n\t\t\t\n\t\t\tfor(String curInterface : interfaces){\n\t\t\t\tIType testing = ModelBuilderUtil.getJavaElement(candidate, \n\t\t\t\t\t\tcurInterface);\n\t\t\t\tif((testing != null)&&(testing.getFullyQualifiedName()\n\t\t\t\t\t\t.equalsIgnoreCase(ParseConstants.MECHANISM))){return true;}\n\t\t\t\tif(ModelBuilderUtil.isInterface(testing, \n\t\t\t\t\t\tParseConstants.MECHANISM)){return true;}\n\t\t\t}\n\t\t}catch(Exception e){return false;}\n\t\t\n\t\treturn false;\n\t}",
"boolean isInterfaceProxied(Class<?> intf);",
"boolean supportsImplementation(String implementationId);",
"public abstract boolean isUsable();",
"boolean isAvailable();",
"boolean isAvailable();",
"boolean isAvailable();",
"boolean isAvailable();",
"private boolean interfaceImplementsInterface(AClass ith) {\n\t\tEnumeration e = getImplements();\n\t\twhile (e.hasMoreElements()) {\n\t\t\tAClass i = ((Type) e.nextElement()).getRefType();\n\t\t\tif (i == ith) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\tif (i.interfaceImplementsInterface(ith)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"@Override public boolean isA(InterfaceId in_interfaceId)\n {\n return (in_interfaceId == INTERFACE_ID);\n }",
"@Test\n public void checkIfSupportedTest() {\n assertTrue(EngineController.checkIfSupported(\"getMaxRotateSpeed\"));\n assertTrue(EngineController.checkIfSupported(\"rotate 10 1\"));\n assertTrue(EngineController.checkIfSupported(\"orient\"));\n // check interface, that specific for engine\n assertTrue(EngineController.checkIfSupported(\"getMaxThrust\"));\n assertTrue(EngineController.checkIfSupported(\"getCurrentThrust\"));\n assertTrue(EngineController.checkIfSupported(\"setThrust 333\"));\n }",
"public boolean hasGLINTERFACE() {\n return fieldSetFlags()[13];\n }",
"Boolean isAvailable();",
"public interface PaySuccessMode {\n\n //IS_HAVE_PACKET\n void isHavePacket(String type, BaseNetActivity baseNetActivity);\n}",
"public interface ISetupManager {\n /**\n * Extract experimental id and URL from String on QR code\n *\n * @param qrCodeData String encoded in QR code\n */\n void parseQrCode(String qrCodeData);\n\n /**\n * Do the next step in the setup process(could be loadExperiment, loadParticipant etc)\n */\n void loadNext();\n\n /**\n * Load experimental design from parsed URL\n */\n void loadExperiment();\n\n /**\n * Load information about participant\n */\n void loadParticipant();\n\n /**\n * Check if apps are installed on device\n */\n void checkForApps();\n\n /**\n * Check if the StudyMate accessibility service is enabled\n */\n void checkForAccServices();\n\n /**\n * Add performed setupEvent to an internal list\n *\n * @param setupEvent performed setupEvent\n */\n void addSetupEvent(SetupEvent setupEvent);\n\n\n /**\n * Checks if the performed setup events match the required events\n *\n * @return whether all required setup events were performed\n */\n boolean isSetupDone();\n\n}",
"public interface IsNeedSubscribePIN\n {\n /**\n * need PIN\n */\n String NEED = \"1\";\n\n /**\n * not need PIN\n */\n String NEEDLESS = \"0\";\n }",
"public RemoteCall<Boolean> supportsInterface(byte[] interfaceId) {\n final Function function = new Function(FUNC_SUPPORTSINTERFACE,\n Arrays.<Type>asList(new org.web3j.abi.datatypes.generated.Bytes4(interfaceId)),\n Arrays.<TypeReference<?>>asList(new TypeReference<Bool>() {}));\n return executeRemoteCallSingleValueReturn(function, Boolean.class);\n }",
"boolean hasProtocol();",
"public boolean isWrapperFor(Class<?> iface) throws SQLException {\n System.out.println(\"com.core.common.ApplicationContextResource.isWrapperFor()\");\n return false;\n }",
"boolean isLayerPublished(Class<? extends LayerInterface> layerClass, String implName);",
"public Object _get_interface()\n {\n throw new NO_IMPLEMENT(reason);\n }",
"public interface ISystem extends INonFlowObject {\n\n}",
"public static boolean meetsRequirements(Object candidate){\n\t\tif(candidate == null){return false;}\n\t\t\n\t\tif(!(candidate instanceof IField)){return false;}\n\t\t\n\t\tIType typeToTest = ModelBuilderUtil.createIFieldType((IField)candidate);\n\t\t\n\t\tif(typeToTest == null){return false;}\n\t\t\n\t\ttry{\n\t\t\tString[] interfaces = typeToTest.getSuperInterfaceTypeSignatures();\n\t\t\t\n\t\t\tfor(String curInterface : interfaces){\n\t\t\t\tIType testing = ModelBuilderUtil.getJavaElement(typeToTest, \n\t\t\t\t\t\tcurInterface);\n\t\t\t\tif((testing != null)&&(testing.getFullyQualifiedName()\n\t\t\t\t\t\t.equalsIgnoreCase(ParseConstants.MECHANISM))){return true;}\n\t\t\t\tif(ModelBuilderUtil.isInterface(testing, \n\t\t\t\t\t\tParseConstants.MECHANISM)){return true;}\n\t\t\t}\n\t\t}catch(Exception e){return false;}\n\t\t\n\t\treturn false;\n\t}",
"private boolean implementsInterface(Class<?> cl, Class<?> iface) {\n if (cl == null)\n return false;\n Class<?>[] clInterfaces = cl.getInterfaces();\n for (int j = 0; j < clInterfaces.length; j++) {\n if (iface.isAssignableFrom(clInterfaces[j]))\n return true;\n }\n return implementsInterface(cl.getSuperclass(), iface);\n }",
"public abstract boolean isNetbeansKenaiRegistered();",
"public void checkOdlOpenflowInterface2(String x) throws SnmpStatusException;",
"public boolean isSetApplicationInterfaceId() {\n return this.applicationInterfaceId != null;\n }",
"public interface ISCExistsDB_Srv\n{\n\tpublic boolean Is_ScripExisting_DB(\n\t String scCode\n\t) throws EX_General;\n\t\n\tpublic EN_SC_GeneralQ Get_ScripExisting_DB(\n\t String scCode\n\t) throws EX_General;\n\t\n\tpublic boolean Is_ScripExisting_DB_DescSW(\n\t String scDesc\n\t) throws EX_General;\n\t\n\tpublic EN_SC_GeneralQ Get_ScripExisting_DB_DescSW(\n\t String scDesc\n\t) throws EX_General;\n\t\n}",
"boolean isValid(String interfaceName, String operationName) {\n\t\tif (this.nodeImpl != null) {\n\t\t\t\n\t\t\tfor (AbstractImplementationArtifact ia : this.nodeImpl.getImplementationArtifacts()) {\n\t\t\t\tif (ia.getInterfaceName() != interfaceName) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tif (ia.getOperationName() != null && ia.getOperationName() != operationName) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tboolean matched = false;\n\t\t\t\tfor (AbstractImplementationArtifact handledIa : this.ias) {\n\t\t\t\t\tif (ia.equals(handledIa)) {\n\t\t\t\t\t\tmatched = true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (!matched) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\treturn true;\n\t\t} else {\n\t\t\t\n\t\t\tfor (AbstractImplementationArtifact ia : this.relationImpl.getImplementationArtifacts()) {\n\t\t\t\tif (ia.getInterfaceName() != interfaceName) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tif (ia.getOperationName() != null && ia.getOperationName() != operationName) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tboolean matched = false;\n\t\t\t\tfor (AbstractImplementationArtifact handledIa : this.ias) {\n\t\t\t\t\tif (ia.equals(handledIa)) {\n\t\t\t\t\t\tmatched = true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (!matched) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\treturn true;\n\t\t}\n\t}",
"private void checkIfInterface(ArrayList<CompilationUnit> compilationUnits) {\n for(CompilationUnit cu : compilationUnits) {\n List<TypeDeclaration> typeDeclarations = cu.getTypes();\n\n // actually, we assume there's only one TypeDeclaration in one CompilationUnit\n for(TypeDeclaration td : typeDeclarations) {\n mapIfInterface.put(td.getName(), ((ClassOrInterfaceDeclaration) td).isInterface());\n }\n }\n }",
"boolean hasDeployedModel();",
"private boolean isVoipAvailable() {\n\t\tint IsInternetCallEnabled = android.provider.Settings.System.getInt(\n\t\t\t\tgetContentResolver(),\n\t\t\t\tandroid.provider.Settings.System.ENABLE_INTERNET_CALL, 0);\n\n\t\treturn (SipManager.isVoipSupported(getActivity()))\n\t\t\t\t&& (IsInternetCallEnabled != 0);\n\n\t}",
"public static boolean isImplementationAvailable() {\r\n if (implementationAvailable == null) {\r\n try {\r\n getJavaxBeanValidatorFactory();\r\n implementationAvailable = true;\r\n } catch (Exception e) {\r\n implementationAvailable = false;\r\n }\r\n }\r\n return implementationAvailable;\r\n }",
"Interface getInterface();",
"Interface getInterface();",
"private static boolean willGenerateExtensionFor(IInterfaceDefinition iDef,\n\t\t\tEnvironment base)\n\t{\n\t\tIInterfaceDefinition overtureEquivalent = base.lookUpType(iDef.getName().getName());\n\t\tboolean hasSameTag = overtureEquivalent == null ? false\n\t\t\t\t: iDef.getName().getTag().equals(overtureEquivalent.getName().getTag());\n\t\treturn hasSameTag && !isUtilityOrTemplateClass(iDef, base);\n\t}",
"public interface SystemFunctionalInterfaceRequirement extends Requirement {\n}",
"public IStatus canAddModule(IModule module);",
"public static boolean isInterface(int mod) {\n\t\treturn Modifier.isInterface(mod);\n\t}",
"Interface_decl getInterface();",
"public boolean hasAI ( ) {\n\t\t// TODO: backwards compatibility required\n\t\treturn extract ( handle -> handle.hasAI ( ) );\n\t}",
"public interface IConnectionService{\n boolean isConnectionAvailable();\n}",
"public boolean hasInterface(Class<?> aSourceClass, Class<?> aTestForClass) {\n\t\tClass<?> clazzes[] = this.getAllInterfaces(aSourceClass);\n\t\tfor (Class<?> clz : clazzes) {\n\t\t\tif (clz.getName().equals(aTestForClass.getName())) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"@Override\r\n\tpublic boolean canExecute(ICustomContext context) {\n\t\tboolean ret = false;\r\n\t\tPictogramElement[] pes = context.getPictogramElements();\r\n\t\tif (pes != null && pes.length == 1) {\r\n\t\t\tObject bo = getBusinessObjectForPictogramElement(pes[0]);\r\n\t\t\tif (bo instanceof Interface) {\r\n\t\t\t\tret = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn ret;\r\n\t}",
"boolean hasSoftware();",
"IsisInterfaceState interfaceState();",
"public interface AvailableIn extends Activated\n{\n boolean isAvailableIn(DateTime time);\n boolean isAvailableNow();\n\n}",
"public abstract Object getInterface(String strInterfaceName_p, Object oObject_p) throws Exception;",
"public boolean isWrapperFor(Class<?> iface) throws SQLException {\n\n debugCode(\"isWrapperFor\");\n throw Message.getUnsupportedException();\n }",
"public boolean hasAdapter(Object adaptable, String adapterTypeName);",
"String getInterfaces();",
"public interface TCNetworkManageInterface {\n\n public String serviceIdentifier();\n\n public String apiClassPath();\n\n public String apiMethodName();\n}",
"public interface IMachineGlasses \n{\n\t/**\n\t * Called on display ticks with the player to determine if the player can see complex machine interfaces. Return true to allow it.\n\t * @return True to allow the player to see complex machine interfaces.\n\t * @param player The player wearing the gear\n\t */\n\tpublic boolean isVisionary(EntityPlayer player);\n}",
"@Override\r\n\tpublic boolean isWrapperFor(Class<?> iface) throws SQLException {\n\t\treturn false;\r\n\t}",
"@Override\r\n\tpublic boolean isWrapperFor(Class<?> iface) throws SQLException {\n\t\treturn false;\r\n\t}",
"@Override\r\n\tpublic boolean isWrapperFor(Class<?> iface) throws SQLException {\n\t\treturn false;\r\n\t}",
"boolean condition(UserInterface userInterface, UserPreferences prefs);",
"boolean hasService();",
"boolean hasService();",
"boolean hasService();",
"boolean hasService();",
"boolean hasService();",
"public interface IWifiManager {\n\n\n\n\n /* *********************************************************************************************\n * WIFI\n * *********************************************************************************************\n */\n\n\n boolean isWifiConnected();\n\n String getSSID();\n\n String getBSSID();\n\n String getIpAddress();\n\n int getRSSI();\n\n int getFrequency();\n\n int getLinkSpeed();\n\n int getNetworkId();\n\n String getNetmask();\n\n String getServerAddress();\n\n String getDNS1();\n\n String getDNS2();\n\n\n /* *********************************************************************************************\n * CONNECTED DEVICES\n * *********************************************************************************************\n */\n\n\n boolean isReachable(InetAddress addr);\n\n String getMAC(InetAddress addr);\n\n String getName(InetAddress addr);\n\n String getBrand(InetAddress addr);\n\n\n\n}",
"public interface IPlatform \n{\n /**\n * Main function of the interface. Returns the boolean representing if the given actor\n * can stand on it.\n * \n * @param a The entity to query\n */\n boolean canSupportEntity(Entity a);\n \n boolean bottomIsCollidable();\n}",
"public Object _get_interface_def()\n {\n // First try to call the delegate implementation class's\n // \"Object get_interface_def(..)\" method (will work for JDK1.2\n // ORBs).\n // Else call the delegate implementation class's\n // \"InterfaceDef get_interface(..)\" method using reflection\n // (will work for pre-JDK1.2 ORBs).\n\n throw new NO_IMPLEMENT(reason);\n }",
"public boolean hasIdentificationAlgorithms() {\n\n \n return identificationAlgorithms != null;\n\n }",
"boolean supportsExternalTool();",
"boolean hasIsBinding();",
"boolean hasBase();",
"protected boolean isAvailable() {\r\n\t\treturn true;\r\n\t}",
"@Override\n\tpublic boolean isWrapperFor(Class<?> iface) throws SQLException {\n\t\treturn false;\n\t}",
"private boolean classImplementsInterface(Class theClass,\r\n\t\t\tClass theInterface) {\r\n\t\tHashMap mapInterfaces = new HashMap();\r\n\t\tString strKey = null;\r\n\t\t// pass in the map by reference since the method is recursive\r\n\t\tgetAllInterfaces(theClass, mapInterfaces);\r\n\t\tIterator iterInterfaces = mapInterfaces.keySet().iterator();\r\n\t\twhile (iterInterfaces.hasNext()) {\r\n\t\t\tstrKey = (String) iterInterfaces.next();\r\n\t\t\tif (mapInterfaces.get(strKey) == theInterface) {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false;\r\n\t}",
"boolean isInstalled();",
"public interface HasUiAttributes {\n}",
"boolean hasProvider();",
"private boolean removeIfaceInternal(IWifiIface iface) {\n String name = getName(iface);\n synchronized (this.mLock) {\n if (this.mWifi == null) {\n Log.e(TAG, \"removeIfaceInternal: null IWifi -- iface(name)=\" + name);\n return false;\n }\n IWifiChip chip = getChip(iface);\n if (chip == null) {\n Log.e(TAG, \"removeIfaceInternal: null IWifiChip -- iface(name)=\" + name);\n return false;\n } else if (name == null) {\n Log.e(TAG, \"removeIfaceInternal: can't get name\");\n return false;\n } else {\n int type = getType(iface);\n if (type == -1) {\n Log.e(TAG, \"removeIfaceInternal: can't get type -- iface(name)=\" + name);\n return false;\n }\n WifiStatus status = null;\n switch (type) {\n case 0:\n status = chip.removeStaIface(name);\n break;\n case 1:\n status = chip.removeApIface(name);\n break;\n case 2:\n status = chip.removeP2pIface(name);\n break;\n case 3:\n status = chip.removeNanIface(name);\n break;\n default:\n try {\n Log.wtf(TAG, \"removeIfaceInternal: invalid type=\" + type);\n return false;\n } catch (RemoteException e) {\n Log.e(TAG, \"IWifiChip.removeXxxIface exception: \" + e);\n break;\n }\n }\n dispatchDestroyedListeners(name);\n if (status == null || status.code != 0) {\n Log.e(TAG, \"IWifiChip.removeXxxIface failed: \" + statusString(status));\n return false;\n }\n return true;\n }\n }\n }",
"String getIsComponentInstanceOf();",
"boolean has(String capability);",
"public boolean isI_IsImported();",
"@Override\r\n\t\t\tpublic boolean isWrapperFor(Class<?> iface) throws SQLException {\n\t\t\t\treturn false;\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic boolean isWrapperFor(Class<?> iface) throws SQLException {\n\t\t\t\treturn false;\r\n\t\t\t}"
] | [
"0.73374116",
"0.7100991",
"0.6961121",
"0.65886915",
"0.6522431",
"0.6381913",
"0.6372652",
"0.634461",
"0.634461",
"0.6336163",
"0.6333689",
"0.6276069",
"0.6200878",
"0.61941046",
"0.6149386",
"0.6117174",
"0.61116534",
"0.6094618",
"0.607438",
"0.60453844",
"0.60447645",
"0.6039442",
"0.60352033",
"0.6021352",
"0.6021352",
"0.6021352",
"0.6021352",
"0.6004407",
"0.60006434",
"0.59545904",
"0.5925446",
"0.59110177",
"0.5873929",
"0.5870323",
"0.5859196",
"0.5828182",
"0.5813628",
"0.57969075",
"0.57917553",
"0.57874984",
"0.57820255",
"0.57792246",
"0.57785803",
"0.57709014",
"0.57582635",
"0.575662",
"0.5740857",
"0.57298046",
"0.57210046",
"0.5702669",
"0.5691059",
"0.5688388",
"0.5674219",
"0.5674219",
"0.56650966",
"0.5662476",
"0.56487054",
"0.5640022",
"0.5635764",
"0.562618",
"0.56238544",
"0.56198233",
"0.56043565",
"0.5592882",
"0.55874336",
"0.55798495",
"0.5579277",
"0.5579237",
"0.55619115",
"0.5561275",
"0.5558213",
"0.55574846",
"0.5550744",
"0.5550744",
"0.5550744",
"0.5549123",
"0.55423135",
"0.55423135",
"0.55423135",
"0.55423135",
"0.55423135",
"0.5538719",
"0.55353206",
"0.5533583",
"0.55244374",
"0.55213195",
"0.55180407",
"0.55148923",
"0.55143005",
"0.5513631",
"0.5501234",
"0.54944307",
"0.5491875",
"0.5489405",
"0.54858947",
"0.5467908",
"0.545956",
"0.5449557",
"0.5442124",
"0.5442124"
] | 0.74573463 | 0 |
=== Initialization initialize the network Adapter | public abstract void init(OwNetworkContext context_p, OwXMLUtil networkSettings_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public NetworkAdapter() {\n }",
"private void initializeAdapter() {\n }",
"protected void initializeNetwork() {\n logger.debug(\"Initialising ZWave controller\");\n\n // Create config parameters\n Map<String, String> config = new HashMap<String, String>();\n config.put(\"masterController\", isMaster.toString());\n config.put(\"sucNode\", sucNode.toString());\n config.put(\"secureInclusion\", secureInclusionMode.toString());\n config.put(\"networkKey\", networkKey);\n config.put(\"wakeupDefaultPeriod\", wakeupDefaultPeriod.toString());\n\n // TODO: Handle soft reset?\n controller = new ZWaveController(this, config);\n controller.addEventListener(this);\n\n // Start the discovery service\n discoveryService = new ZWaveDiscoveryService(this, searchTime);\n discoveryService.activate();\n\n // And register it as an OSGi service\n discoveryRegistration = bundleContext.registerService(DiscoveryService.class.getName(), discoveryService,\n new Hashtable<String, Object>());\n }",
"public void init(){\n taskClient.connect(\"127.0.0.1\", 9123);\n }",
"private void initialize(){\n\t\ttry\n\t\t{\n\t\t\tString[] packet = setPacket();\n\t\t\tif (validatePacket(packet))\n\t\t\t{\n\t\t\t\tsend(packet);\n\t\t\t}\n\t\t}\n\t\tcatch (Exception e)\n\t\t{\n\t\t\tSystem.out.println(e.getMessage());\n\t\t\tSystem.out.println(\"Something went wrong...\");\n\t\t\tresetClient();\n\t\t}\n\t}",
"private void init(String ip, int port, String name) {\n this.settings = new Settings(ip, port, name);\n this.network = new Network(this);\n this.clientGUI = new ClientGUI(this);\n //\n new Thread(network::start).start();\n }",
"public void init() {\r\n \tconnection = Connect.initConnexion();\r\n \tSystem.out.println(\"connexion :\"+connection);\r\n }",
"private void init() {\n\t\tinitProtocol();\n\t\tinitResultStorage();\n\t}",
"public void initializeNetwork(boolean isHost, String ip, int port) {\r\n if (isHost) {\r\n networkPlayer = new NetworkHost(this, ip, port);\r\n } else {\r\n networkPlayer = new NetworkClient(this, ip, port);\r\n }\r\n\r\n }",
"private void init(){\n if(!initializing) {\n Initializer init = new Initializer();\n InitializationDetails initializationDetails = new InitializationDetails(url, download, reset, deviceID, this);\n init.execute(initializationDetails);\n initializing = true;\n }\n }",
"@Override\n\tpublic void initialize() {\n\t\ttransportManager = newServerTransportManager();\n\t\ttransportServer = newTransportServer();\n\t\tserverStateMachine = newTransportServerStateMachine();\n\n\t\tserverStateMachine.setServerTransportComponentFactory(this);\n\t\ttransportManager.setServerTransportComponentFactory(this);\n\t\ttransportServer.setServerTransportComponentFactory(this);\n\t\ttransportServer.setServerHostConfig(getServerHostConfig());\n\n\t\tsetInitialized(true);\n\t}",
"public void initialize() {\n\t\tDynamoConfig config = new DynamoConfig();\n\t\tthis.setup(config);\n\t}",
"public ArtNet() {\n address = DEFAULT_ADDRESS;\n port = DEFAULT_PORT;\n operating = false;\n listeners = new ArrayList<ArtNetListener>();\n }",
"private void InitConnexion() {\n\t\n\t\n\t\ttry {\n\t\t\tannuaire = new LDAPConnection(adresseIP, 389, bindDN+\",\"+baseDN, pwd);\n\t\t\tinitialise = true;\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"Exception \" + e.getMessage() );\n\t\t}\n\t\n\t\t\t}",
"private void initializeNA(){\n name = \"N/A\";\n key = \"N/A\";\n serverIpString = \"N/A\";\n serverPort = 0;\n clientListenPort = 0;\n }",
"public Network () {\n buildNetwork();\n }",
"private void init() {\n myNodeDetails = new NodeDetails();\n try {\n //port will store value of port used for connection\n //eg: port = 5554*2 = 11108\n String port = String.valueOf(Integer.parseInt(getMyNodeId()) * 2);\n //nodeIdHash will store hash of nodeId =>\n // eg: nodeIdHash = hashgen(5554)\n String nodeIdHash = genHash(getMyNodeId());\n myNodeDetails.setPort(port);\n myNodeDetails.setNodeIdHash(nodeIdHash);\n myNodeDetails.setPredecessorPort(port);\n myNodeDetails.setSuccessorPort(port);\n myNodeDetails.setSuccessorNodeIdHash(nodeIdHash);\n myNodeDetails.setPredecessorNodeIdHash(nodeIdHash);\n myNodeDetails.setFirstNode(true);\n\n if (getMyNodeId().equalsIgnoreCase(masterPort)) {\n chordNodeList = new ArrayList<NodeDetails>();\n chordNodeList.add(myNodeDetails);\n }\n\n } catch (Exception e) {\n Log.e(TAG,\"**************************Exception in init()**********************\");\n e.printStackTrace();\n }\n }",
"private synchronized void initNetwork() {\n if (connectivityManager == null) {\n ConnectivityManager tryConnectivityManager =\n (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE);\n\n TelephonyManager tryTelephonyManager =\n (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE);\n\n // Assign to member vars only after all the get calls succeeded,\n // so that either all get assigned, or none get assigned.\n connectivityManager = tryConnectivityManager;\n telephonyManager = tryTelephonyManager;\n \n // Some interesting info to look at in the logs\n NetworkInfo[] infos = connectivityManager.getAllNetworkInfo();\n for (NetworkInfo networkInfo : infos) {\n Logger.i(\"Network: \" + networkInfo);\n }\n Logger.i(\"Phone type: \" + getTelephonyPhoneType() +\n \", Carrier: \" + getTelephonyCarrierName());\n }\n assert connectivityManager != null;\n assert telephonyManager != null;\n }",
"public void init() {\n configuration.init();\n \n //Connections connections = configuration.getBroker().getConnections(\"topic\");\n Connections connections = configuration.getBrokerPool().getBroker().getConnections(\"topic\");\n \n if (connections == null) {\n handleException(\"Couldn't find the connection factor: \" + \"topic\");\n }\n \n sensorCatalog = new SensorCatalog();\n clientCatalog = new ClientCatalog();\n \n nodeCatalog = new NodeCatalog();\n \n updateManager = new UpdateManager(configuration, sensorCatalog, this);\n updateManager.init();\n \n endpointAllocator = new EndpointAllocator(configuration, nodeCatalog);\n\n registry = new JCRRegistry(this);\n registry.init();\n\n // Initialize Public-End-Point\n if(!isPublicEndPointInit) {\n \tinitPublicEndpoint();\n }\n }",
"@Override\n public void init() {\n logger.info(\"Initializing Sample TAL adapter\");\n\n // In order to get ticket updates from Symphony adapter must subscribe to this explicitly here\n // After subscription is done, all updates will come to this adapter instance via calls to syncTalTicket method\n talProxy.subscribeUpdates(accountId, this);\n\n try {\n // obtain adapter configuration\n setConfig(talConfigService.retrieveTicketSystemConfig(accountId));\n } catch (Exception e) {\n throw new RuntimeException(\"SampleTalAdapterImpl was unable to retrieve \" +\n \"configuration from TalConfigService: \" + e.getMessage(), e);\n }\n\n // subscribe for getting adapter configuration updates\n talConfigService.subscribeForTicketSystemConfigUpdate(accountId,\n (ticketSystemConfig) -> setConfig(ticketSystemConfig));\n }",
"private void init() {\n\t\tsendPacket(new Packet01Login(\"[you have connected to \"+UPnPGateway.getMappedAddress()+\"]\", null));\n\t}",
"public void initialize() {\n // empty for now\n }",
"public void init(){\n\t\tmultiplexingClientServer = new MultiplexingClientServer(selectorCreator);\n\t}",
"public void initialize()\n {\n }",
"public void initialize() {\n this.loadDownloadList();\n }",
"protected void initialize() {\n drivebase.engageOmni();\n }",
"public void initialize()\n throws Exception\n {\n final DNAThreadPoolMonitor monitor = new DNAThreadPoolMonitor();\n ContainerUtil.enableLogging( monitor, m_logger );\n setMonitor( monitor );\n setup();\n }",
"public void autonomousInit() {\n \tNetworkCommAssembly.start();\n }",
"protected void initialize() {\n \t\n }",
"public void initDevice() {\r\n\t\t\r\n\t}",
"public void initialize() throws SocketException{\n defPortUsed = true;\n initializeReal(defPortNumber, defPacketSize);\n }",
"public void initialize() throws Exception {\n\t\tdataStore = new SimpleProcessImage();\r\n\t\tdataStore.addDigitalOut(new SimpleDigitalOut(true));\r\n\t\tdataStore.addDigitalOut(new SimpleDigitalOut(false));\r\n\t\tdataStore.addDigitalIn(new SimpleDigitalIn(false));\r\n\t\tdataStore.addDigitalIn(new SimpleDigitalIn(true));\r\n\t\tdataStore.addDigitalIn(new SimpleDigitalIn(false));\r\n\t\tdataStore.addDigitalIn(new SimpleDigitalIn(true));\r\n\r\n\t\tfor (int i = 0; i < num_registers; i++) {\r\n\t\t\tdataStore.addRegister(new SimpleRegister(0));\r\n\t\t}\t\t\r\n\r\n\t\t// 3. Set the image on the coupler\r\n\t\tModbusCoupler.getReference().setProcessImage(dataStore);\r\n\t\tModbusCoupler.getReference().setMaster(false);\r\n\t\tModbusCoupler.getReference().setUnitID(15);\r\n\r\n\t\tif(null != slaveListener && slaveListener.isListening()){\r\n\t\t\tslaveListener.stop();\r\n\t\t}\r\n\t\tslaveListener = new ModbusTCPListener(3);\r\n\t\tslaveListener.setPort(port);\r\n\t\tslaveListener.listen();\r\n\t}",
"public void init() {\r\n\t\tthis.initWebAndSocketServer();\r\n\r\n\t\t/*\r\n\t\t * Set/update server info\r\n\t\t */\r\n\t\ttry {\r\n\t\t\tServerInfo serverInfo = Info.getServerInfo();\r\n\t\t\tserverInfo.setPort(Integer.parseInt(SettingsManager.getStringValue(GeneralController.getInstance().getIdentifier(), GeneralController.Settings.NET_HTTP_PORT.get())));\r\n\t\t\tserverInfo.setName(SettingsManager.getStringValue(GeneralController.getInstance().getIdentifier(), GeneralController.Settings.SERVER_NAME.get(), \"Home server\"));\r\n\t\t\tserverInfo.setVersion(BuildConfig.VERSION);\r\n\t\t\tInfo.writeServerInfo(serverInfo);\r\n\t\t} catch (IOException | JSONException e1) {\r\n\t\t\tServer.log.error(\"Could not update server info. Designer might not work as expected: \" + e1.getMessage());\r\n\t\t}\r\n\r\n\t\tRuleManager.init();\r\n\t}",
"public NetworkSource() {\n }",
"void initialise() {\n this.sleep = false;\n this.owner = this;\n renewNeighbourClusters();\n recalLocalModularity();\n }",
"public void initialize() {\n // TODO\n }",
"public void init() {\n\t\ttry {\n\t\t\tthis.is = new ObjectInputStream(clientSocket.getInputStream());\n\t\t\tthis.os = new ObjectOutputStream(clientSocket.getOutputStream());\n\t\t\twhile (this.readCommand()) {}\n\t\t} \n\t\tcatch (IOException e) \n\t\t{\n\t\t\tSystem.out.println(\"XX. There was a problem with the Input/Output Communication:\");\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void init() {\n\t\t}",
"public static void init() {\r\n try {\r\n defaultImplementation = new LinkLayer_Impl_PC();\r\n } catch (IOException e) {\r\n Log.e(TAG, e, \"Failed in creating defaultImplementation!\");\r\n }\r\n }",
"public void initialize() {\r\n }",
"private void initialize() {\r\n // init hidden layers\r\n for (int i = 0; i < neurons.length; i++) {\r\n for (int j = 0; j < neurons[i].length; j++) {\r\n // create neuron\r\n Neuron n = new Neuron(i, bias, this);\r\n neurons[i][j] = n;\r\n Log.log(Log.DEBUG, \"Adding Layer \" + (i + 1) + \" Neuron \" + (j + 1));\r\n }\r\n }\r\n }",
"private MockClientNetworkModule() {\n\t\t// TODO complete this constructor\n\t}",
"public static void initialize()\n\t{\n\t\t// USB\n\t\tdriveJoystick = new EJoystick(getConstantAsInt(USB_DRIVE_STICK));\n\t\tcontrolGamepad = new EGamepad(getConstantAsInt(USB_CONTROL_GAMEPAD));\n\n\t\t// Power Panel\n\t\tpowerPanel = new PowerDistributionPanel();\n\n\t\t//Compressor\n\t\tcompressor = new Compressor(Constants.getConstantAsInt(Constants.PCM_CAN));\n\t\tcompressor.start();\n\t}",
"public NetworkData() {\n }",
"private void init() throws IOException {\n m_sock = new Socket(InetAddress.getByAddress(m_address), VIDEO_TO_PC_PORT);\n m_sock.setSoTimeout(READ_TIMEOUT_MS);\n m_sockistream = m_sock.getInputStream();\n m_daistream = new DataInputStream(m_sockistream);\n m_initialized = true;\n }",
"@Override\n public void init() {\n\n stevens_IMU = new AdafruitBNO055IMU(hardwareMap.i2cDeviceSynch.get(\"IMU\"));\n\n parameters = new BNO055IMU.Parameters();\n\n success = stevens_IMU.initialize(parameters);\n telemetry.addData(\"Success: \", success);\n\n doDaSleep(500);\n\n }",
"public NetworkMonitorAdapter( Adapter adapter )\r\n {\r\n super( adapter );\r\n }",
"public ServerConnecter() {\r\n\r\n\t}",
"public void init() {\n \n }",
"protected void initialize() {\r\n\r\n Robot.pneumatics.pneuOpen();\r\n }",
"@Override public void init()\n\t\t{\n\t\t}",
"private void initialize() {\n }",
"private void initialize() {\n\t}",
"public void initialize() {\n\t}",
"public void initialize() {\n\t}",
"private static void init() {\n\t\ttry {\n\t\t\tlocalAddr = InetAddress.getLocalHost();\n\t\t\tlogger.info(\"local IP:\" + localAddr.getHostAddress());\n\t\t} catch (UnknownHostException e) {\n\t\t\tlogger.info(\"try again\\n\");\n\t\t}\n\t\tif (localAddr != null) {\n\t\t\treturn;\n\t\t}\n\t\t// other way to get local IP\n\t\tEnumeration<InetAddress> localAddrs;\n\t\ttry {\n\t\t\t// modify your network interface name\n\t\t\tNetworkInterface ni = NetworkInterface.getByName(networkInterface);\n\t\t\tif (ni == null) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tlocalAddrs = ni.getInetAddresses();\n\t\t\tif (localAddrs == null || !localAddrs.hasMoreElements()) {\n\t\t\t\tlogger.error(\"choose NetworkInterface\\n\" + getNetworkInterface());\n\t\t\t\treturn;\n\t\t\t}\n\t\t\twhile (localAddrs.hasMoreElements()) {\n\t\t\t\tInetAddress tmp = localAddrs.nextElement();\n\t\t\t\tif (!tmp.isLoopbackAddress() && !tmp.isLinkLocalAddress() && !(tmp instanceof Inet6Address)) {\n\t\t\t\t\tlocalAddr = tmp;\n\t\t\t\t\tlogger.info(\"local IP:\" + localAddr.getHostAddress());\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tlogger.error(\"Failure when init ProxyUtil\", e);\n\t\t\tlogger.error(\"choose NetworkInterface\\n\" + getNetworkInterface());\n\t\t}\n\t}",
"public void init() throws PortletException{\r\n\t\tsuper.init();\r\n\t}",
"public void initialize() {\n }",
"public TCPAdapter() throws IOException {\n\t\tthis(9999);\n\t}",
"@Override\n public void init() {\n robot.init(hardwareMap);\n telemetry.addData(\"Status\", \"Initialized\");\n }",
"public void initializeNetwork() {\n if (DataHelper.isNull(searchDTO.getNetwork())) {\n //If no Network is set we have to see which network applies for this user\n this.searchDTO.setNetwork(obtainCurrentUserNetwork());\n }\n }",
"public TTL_CIL_Communicator()\n {\n }",
"private void initWirelessCommunication() {\n if (!getPackageManager().hasSystemFeature(PackageManager.FEATURE_BLUETOOTH_LE)) {\n showToast(\"BLE is not supported\");\n finish();\n } else {\n showToast(\"BLE is supported\");\n // Access Location is a \"dangerous\" permission\n int hasAccessLocation = ContextCompat.checkSelfPermission(this,\n Manifest.permission.ACCESS_COARSE_LOCATION);\n if (hasAccessLocation != PackageManager.PERMISSION_GRANTED) {\n // ask the user for permission\n ActivityCompat.requestPermissions(this,\n new String[]{Manifest.permission.ACCESS_COARSE_LOCATION},\n REQUEST_ACCESS_LOCATION);\n // the callback method onRequestPermissionsResult gets the result of this request\n }\n }\n // enable wireless communication alternative\n if (communicationAdapter == null || !communicationAdapter.isReadyToBeUsed()) {\n assert communicationAdapter != null;\n Intent enableWirelessCommunicationIntent = new Intent(communicationAdapter.actionRequestEnable());\n startActivityForResult(enableWirelessCommunicationIntent, REQUEST_ENABLE_BT);\n }\n }",
"public WifiProtocol(){\r\n// messages = new String[100];\r\n// index = 0;\r\n }",
"public void init() {\n \t\tif (initLock.start()) {\n \t\t\ttry {\n \t\t\t\tthis._init(this.config);\n \t\t\t} finally {\n \t\t\t\tinitLock.end();\n \t\t\t}\n \t\t}\n \t}",
"public void init() {\n log.info(\"initialization\");\n }",
"public DefaultCniNetworkInner() {\n }",
"public void init() {\r\n\r\n\t}",
"protected void initialize() {\r\n }",
"protected void initialize() {\r\n }",
"void init() {\n CometUtils.printCometSdkVersion();\n validateInitialParams();\n this.connection = ConnectionInitializer.initConnection(\n this.apiKey, this.baseUrl, this.maxAuthRetries, this.getLogger());\n this.restApiClient = new RestApiClient(this.connection);\n // mark as initialized\n this.alive = true;\n }",
"private void initConfig() {\n Path walletPath;\n Wallet wallet;\n\n // load a CCP\n Path networkConfigPath; \n \n try {\n \t\n \tif (!isLoadFile) {\n // Load a file system based wallet for managing identities.\n walletPath = Paths.get(\"wallet\");\n wallet = Wallet.createFileSystemWallet(walletPath);\n\n // load a CCP\n networkConfigPath = Paths.get(\"\", \"..\", \"basic-network\", configFile);\n \n builder = Gateway.createBuilder();\n \n \tbuilder.identity(wallet, userId).networkConfig(networkConfigPath).discovery(false);\n \t\n \tisLoadFile = true;\n \t}\n } catch (Exception e) {\n \te.printStackTrace();\n \tthrow new RuntimeException(e);\n }\n\t}",
"void init() throws CouldNotInitializeConnectionPoolException;",
"public NetworkManager() {\n okHttpClient = new OkHttpClientProvider().getClient();\n retrofit = new RetrofitInstanceProvider(new RelatedTopicTypeAdapterFactory(), okHttpClient).getRetrofitInstance();\n }",
"private void initialize() {\n\t\t\n\t}",
"private void initialize() {\n this.setLayout(new CardLayout());\n this.setName(Constant.messages.getString(\"ports.options.title\"));\n this.add(getPanelPortScan(), getPanelPortScan().getName());\n }",
"protected void initialize() { \n param1 = SmartDashboard.getNumber(\"param1\");\n param2 = SmartDashboard.getNumber(\"param2\");\n param3 = SmartDashboard.getNumber(\"param3\");\n param4 = SmartDashboard.getNumber(\"param4\");\n command = new C_DriveBasedOnEncoderWithTwist(param1, param2, param3);\n }",
"public void initializeConnections(){\n cc = new ConnectorContainer();\n cc.setLayout(null);\n cc.setAutoscrolls(true);\n connections = new LinkedList<JConnector>();\n agents = new LinkedList<JConnector>();\n }",
"protected void initialize()\n\t{\n\t}",
"public void init() {\n\n\t}",
"public void init() {\n\n\t}",
"public void init() {\n\n\t}",
"protected void initialize() {\n\n\t}",
"public void init() {\n }",
"public void init() {\n }",
"public void init() {\n }",
"public void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"public Network() {\n\t\t\n\t\t//Initialize new hashmap for nodes and neighbors\n\t\tnodes = new HashSet<Node>();\n\t\t\n\t\t//Initialize new arraylist for messages in network\n\t\tmessages = new ArrayList<Message>();\n\t\t\n\t\t//Set the network to open for accepting messages \n\t\tthis.open = true;\n\t\t\n\t}",
"public void init() {\n\t\n\t}",
"private void init() {\n AdvertisingRequest();// 广告列表请求线程\n setapiNoticeControllerList();\n }",
"private void initialise() {\n addHeaderSetting(new HeaderSettingInteger(Setting.VERSION.toString(),0,4,0x6));\n addHeaderSetting(new HeaderSettingInteger(Setting.TRAFFIC_CLASS.toString(),4,8,0));\n addHeaderSetting(new HeaderSettingLong(Setting.FLOW_LABEL.toString(),12,20,0));\n addHeaderSetting(new HeaderSettingLong(Setting.PAYLOAD_LENGTH.toString(),32,16,20));\n addHeaderSetting(new HeaderSettingInteger(Setting.NEXT_HEADER.toString(),48,8,253));\n addHeaderSetting(new HeaderSettingInteger(Setting.HOP_LIMIT.toString(),56,8,255));\n addHeaderSetting(new HeaderSettingHexString(Setting.SOURCE_ADDRESS.toString(),64,128,\"\"));\n addHeaderSetting(new HeaderSettingHexString(Setting.DESTINATION_ADDRESS.toString(),192,128,\"\"));\n }",
"@Override\n public void init() {\n robot.init(hardwareMap);\n\n // Send telemetry message to signify robot waiting;\n telemetry.addData(\"Status\", \"Initialized\"); //\n }",
"private void init() {\n }",
"private static void init() {\n System.setProperty(\"java.net.preferIPv4Stack\", \"true\");\r\n }",
"public static void init() {\n startTime = System.currentTimeMillis();\n if (clientExecutorEngine == null) {\n clientExecutorEngine = new ClientExecutorEngine();\n HzClient.initClient();\n }\n }",
"public void initialiseCRISTDiscovery() {\n\t}"
] | [
"0.7840709",
"0.7007534",
"0.67932874",
"0.6692352",
"0.6587188",
"0.6525738",
"0.65082145",
"0.650186",
"0.6489489",
"0.6464269",
"0.6463547",
"0.64346313",
"0.6431787",
"0.64122444",
"0.64115685",
"0.6356959",
"0.63480544",
"0.63444227",
"0.6339717",
"0.6332117",
"0.6306811",
"0.6299389",
"0.62738854",
"0.6272543",
"0.62587386",
"0.6225534",
"0.6211641",
"0.6178921",
"0.6168071",
"0.61585456",
"0.6155837",
"0.61199456",
"0.608972",
"0.60883325",
"0.6081733",
"0.6081099",
"0.6073618",
"0.60725766",
"0.6068526",
"0.6067093",
"0.60655487",
"0.6064934",
"0.60646164",
"0.6055377",
"0.6051126",
"0.6050354",
"0.60485893",
"0.6048153",
"0.60303324",
"0.60294014",
"0.60263115",
"0.6026125",
"0.601977",
"0.6000233",
"0.6000233",
"0.5992274",
"0.59911305",
"0.5988244",
"0.5985673",
"0.5984684",
"0.5976194",
"0.5975436",
"0.5974001",
"0.5965324",
"0.59585786",
"0.5958331",
"0.59555495",
"0.5953484",
"0.59524566",
"0.59524566",
"0.5940618",
"0.5939389",
"0.5937907",
"0.59304976",
"0.5930125",
"0.59284276",
"0.5925126",
"0.5917895",
"0.5910555",
"0.59099144",
"0.59099144",
"0.59099144",
"0.5907749",
"0.5903641",
"0.5903641",
"0.5903641",
"0.5903641",
"0.5903505",
"0.5903505",
"0.5903505",
"0.5903505",
"0.58995265",
"0.5893406",
"0.58931446",
"0.5879058",
"0.5877638",
"0.58751655",
"0.5869142",
"0.5869011",
"0.5863958"
] | 0.6431248 | 13 |
return the network context that was past during initialization | public OwNetworkContext getContext(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public cl_context getContext() {\r\n return context;\r\n }",
"public com.google.protobuf.ByteString getContext() {\n return context_;\n }",
"CTX_Context getContext();",
"public com.google.protobuf.ByteString getContext() {\n return context_;\n }",
"public IRuntimeContext getContext() {\n return fContext;\n }",
"Context getContext();",
"public IContextInformation getContextInformation()\n {\n return null;\n }",
"protected SSLContext getContext() throws Exception \n {\n try \n {\n SSLContext sslContext = SSLContext.getInstance(\"SSL\"); \n sslContext.init(null, getTrustManager(), new java.security.SecureRandom());\n \n return sslContext;\n } \n catch (Exception e)\n {\n throw new Exception(\"Error creating context for SSLSocket!\", e);\n }\n }",
"public Instruction loadContextNode() {\n/* 270 */ return loadCurrentNode();\n/* */ }",
"public static Context getContext() {\n\t\treturn context;\n\t}",
"public static Context getContext() {\n\t\treturn context;\n\t}",
"public CamelContext getXNetContext() {\n CamelContext cctx;\n Map<String, Object> xnetComp = getXNetComponent();\n if (xnetComp == null || xnetComp.isEmpty()) {\n Log.info(LifeCARDAdmin.class.getName() + \":getXNetContext()():No valid XNET routing handle found\");\n return null;\n }\n //+++ do not just return the context...\n //return this.camelContext;\n ActiveMQComponent amqComp = (ActiveMQComponent) xnetComp.get(\"ActiveMQComponent\");\n if (amqComp == null) {\n Log.info(LifeCARDAdmin.class.getName() + \":getXNetContext()():No valid XNET handle found (No AMQ component)\");\n return null;\n }\n //... get and check the context of the highest identified processing\n cctx = amqComp.getCamelContext();\n //TODO check connection... otherwise throw error \"XNetConnectionError\"\n if (cctx == null || cctx.isSuspended()) {\n Log.log(Level.WARNING, LifeCARDAdmin.class.getName() + \":getXNetContext():\" + (cctx == null ? \"XNET context not present (null)\" : \"XNET context suspended \" + cctx.isSuspended()));\n return null;\n }\n return cctx;\n }",
"public Context getContext() {\n\t\treturn context;\n\t}",
"public Context getContext() {\r\n\t\treturn context;\r\n\t}",
"public Context() {\n\t\tstates = new ObjectStack<>();\n\t}",
"private SSLContext getSSLContext() {\n if (this.sslcontext == null) {\n this.sslcontext = createSSLContext();\n }\n return this.sslcontext;\n }",
"com.google.protobuf.ByteString getContext();",
"protected RestContext getContext() {\n\t\tif (context.get() == null)\n\t\t\tthrow new InternalServerError(\"RestContext object not set on resource.\");\n\t\treturn context.get();\n\t}",
"public static Context getContext() {\n\t\treturn instance;\n\t}",
"public org.omg.CORBA.Context read_Context() {\n throw new org.omg.CORBA.NO_IMPLEMENT();\n }",
"Context context();",
"Context context();",
"protected final TranslationContext context() {\n\t\treturn context;\n\t}",
"static synchronized Context getContext() {\n checkState();\n return sInstance.mContext;\n }",
"public Context getContext() {\n if (context == null) {\n try {\n context = new InitialContext();\n } catch (NamingException exception) {\n }\n }\n return context;\n }",
"public Context getContext() {\n\t\treturn null;\n\t}",
"public Context getContext() {\n\t\treturn ctx;\n\t}",
"public ContextRequest getContext() {\n\t\treturn context;\n\t}",
"@java.lang.Override public POGOProtos.Rpc.QuestProto.Context getContext() {\n @SuppressWarnings(\"deprecation\")\n POGOProtos.Rpc.QuestProto.Context result = POGOProtos.Rpc.QuestProto.Context.valueOf(context_);\n return result == null ? POGOProtos.Rpc.QuestProto.Context.UNRECOGNIZED : result;\n }",
"public Object getContextObject() {\n return context;\n }",
"java.lang.String getLinkedContext();",
"public Context getContext() {\n return context;\n }",
"@java.lang.Override\n public POGOProtos.Rpc.QuestProto.Context getContext() {\n @SuppressWarnings(\"deprecation\")\n POGOProtos.Rpc.QuestProto.Context result = POGOProtos.Rpc.QuestProto.Context.valueOf(context_);\n return result == null ? POGOProtos.Rpc.QuestProto.Context.UNRECOGNIZED : result;\n }",
"public Context getContext() {\n return contextMain;\n }",
"private HazelcastMQContextHolder getHazelcastMQContextHolder() {\n return hazelcastMQContextHolder;\n }",
"@Override\r\n\tpublic Context getContext() {\r\n\t\treturn this.context;\r\n\t}",
"public String getContext() { return context; }",
"public Context getContext() {\n if (context == null) {\n context = Model.getSingleton().getSession().getContext(this.contextId);\n }\n return context;\n }",
"public String getContext() {\r\n\t\treturn context;\r\n\t}",
"private Context getContext() throws Exception {\n\t\tif (ctx != null)\n\t\t\treturn ctx;\n\n\t\tProperties props = new Properties();\n\t\tprops.put(Context.PROVIDER_URL, \"jnp://\" + endpoint);\n\t\tprops.put(Context.INITIAL_CONTEXT_FACTORY,\n\t\t\t\t\"org.jnp.interfaces.NamingContextFactory\");\n\t\tprops.put(Context.URL_PKG_PREFIXES,\n\t\t\t\t\"org.jboss.naming:org.jnp.interfaces\");\n\t\tctx = new InitialContext(props);\n\n\t\treturn ctx;\n\t}",
"public Object getConnectionContext() {\n return connectionContext;\n }",
"public String getContext() {\n\t\treturn context;\n\t}",
"Context createContext();",
"Context createContext();",
"com.google.protobuf.ByteString\n getContextBytes();",
"public ContextInstance getContextInstance() {\n\t\treturn token.getProcessInstance().getContextInstance();\r\n\t}",
"public org.apache.axis2.context.xsd.ConfigurationContext getConfigurationContext(){\n return localConfigurationContext;\n }",
"public abstract Context context();",
"public ConfigContext getConfigContext() {\n\n return (ConfigContext)getSource();\n\n }",
"public org.apache.axis2.context.xsd.ConfigurationContext getRootContext(){\n return localRootContext;\n }",
"public String getContext() {\n return context;\n }",
"public String getContext() {\n return context;\n }",
"public String getContext() {\n return context;\n }",
"ContextBucket getContext() {\n\treturn context;\n }",
"public final Object getContextInfo() {\n return this.info;\n }",
"private Context getThreadContext() throws NamingException {\n final ThreadContext threadContext = ThreadContext.getThreadContext();\n if (skipEjbContext(threadContext)) {\n return ContextBindings.getClassLoader();\n }\n final Context context = threadContext.getBeanContext().getJndiEnc();\n return context;\n }",
"public Context getContext() {\n return this;\n }",
"public Context(){\n\t\ttry {\n\t\t\tsocket = new Socket(\"localhost\", 9876);\n\t\t\tmodel = new SimpleCalculationModel();\n\t\t\ttheInputWindow = new SimpleCalculatorWindow();\n\t\t\tcurrentInput = \"\"; \n\t\t} catch (UnknownHostException e) {\n\t\t\t\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"The server local host port 9876 does not exist!\");\n\t\t}\n\t}",
"Map<String, Object> getContext();",
"public ModuleContext getContext() {\r\n return context;\r\n }",
"public PortletContext getPortletContext ()\n {\n \treturn config.getPortletContext();\n }",
"public Context getContext() {\n return (Context)this;\n }",
"@Nullable\n default String getContext() {\n String contextName =\n String.valueOf(execute(DriverCommand.GET_CURRENT_CONTEXT_HANDLE).getValue());\n return \"null\".equalsIgnoreCase(contextName) ? null : contextName;\n }",
"public NetworkInfo getActiveNetworkInfo() {\n\treturn null;\r\n}",
"public RuntimeContext getRuntimeContext() {\n return runtimeContext;\n }",
"public ImmutableContextSet getContext() {\n return new ImmutableContextSet(this.contextSet);\n }",
"public URI getCurrentContext();",
"@Override\r\n\tpublic Context getContext() {\n\t\treturn null;\r\n\t}",
"public static Context getInstance(){\n\t\treturn (Context) t.get();\n\t}",
"public abstract ApplicationLoader.Context context();",
"private DatabaseContext() {\r\n datastore = createDatastore();\r\n init();\r\n }",
"public abstract void init(OwNetworkContext context_p, OwXMLUtil networkSettings_p) throws Exception;",
"public java.lang.String getContext() {\n java.lang.Object ref = context_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n context_ = s;\n return s;\n }\n }",
"protected RuntimeContext getRuntimeContext() {\r\n return parentAction.getRuntimeContext();\r\n }",
"public static Context getResourceContext() {\n return context;\n }",
"public Map<String, Object> context() {\n return unmodifiableMap(context);\n }",
"com.google.protobuf.ByteString\n getLinkedContextBytes();",
"long getCurrentContext();",
"public final Node getRootContext() {\n return rootContext;\n }",
"public java.lang.String getContext() {\n java.lang.Object ref = context_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n context_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }",
"private GeoApiContext getGeoContext()\n {\n GeoApiContext geoApiContext = new GeoApiContext();\n return geoApiContext\n .setQueryRateLimit(3)\n .setApiKey(getString(R.string.google_maps_key))\n .setConnectTimeout(5, TimeUnit.SECONDS)\n .setReadTimeout(5, TimeUnit.SECONDS)\n .setWriteTimeout(5, TimeUnit.SECONDS);\n }",
"public final int getContextNode(){\n return this.getCurrentNode();\n }",
"private RequestContext() {\n\t\tencoding = DEFAULT_ENCODING;\n\t\tstatusCode = DEFAULT_STATUS_CODE;\n\t\tstatusText = DEFAULT_STATUS_TEXT;\n\t\tmimeType = DEFAULT_MIME_TYPE;\n\t\tcontentLength = DEFAULT_CONTENT_LENGHT;\n\t\theaderGenerated = DEFAULT_HEADER_GENERATED;\n\t\tcharset = Charset.forName(encoding);\n\t}",
"public NetworkManager getNetwork()\n {\n return network;\n }",
"public Context getContext() {\n return this.mService.mContext;\n }",
"public com.google.protobuf.ByteString\n getContextBytes() {\n java.lang.Object ref = context_;\n if (ref instanceof String) {\n com.google.protobuf.ByteString b = \n com.google.protobuf.ByteString.copyFromUtf8(\n (java.lang.String) ref);\n context_ = b;\n return b;\n } else {\n return (com.google.protobuf.ByteString) ref;\n }\n }",
"IContextNode wdGetContext();",
"public ContextNode getContextNode();",
"public static Context getContext(){\n return appContext;\n }",
"public java.lang.String[] getMessageContexts(){\n return localMessageContexts;\n }",
"public com.google.protobuf.ByteString\n getContextBytes() {\n java.lang.Object ref = context_;\n if (ref instanceof java.lang.String) {\n com.google.protobuf.ByteString b = \n com.google.protobuf.ByteString.copyFromUtf8(\n (java.lang.String) ref);\n context_ = b;\n return b;\n } else {\n return (com.google.protobuf.ByteString) ref;\n }\n }",
"public ComponentContext getContext()\n\t{\n\t\treturn context;\n\t}",
"public Context getThis()\r\n {\r\n return this.context;\r\n }",
"public Handle<GameAppContext> getParentContext();",
"public MessageContext getMessageContext() {\n return msgContext;\n }",
"public NamespaceContext getNamespaceContext() {\n LOGGER.entering(JsonXmlStreamReader.class.getName(), \"getNamespaceContext\");\n NamespaceContext result = new JsonNamespaceContext();\n LOGGER.exiting(JsonXmlStreamReader.class.getName(), \"getNamespaceContext\", result);\n return result;\n }",
"public abstract ContextNode getContextNode();",
"RenderingContext getContext();",
"protected SSLContext() {}",
"private Context getContext() {\n return mContext;\n }"
] | [
"0.64126647",
"0.63346684",
"0.6288993",
"0.62863094",
"0.6241376",
"0.62400866",
"0.6174457",
"0.61298764",
"0.60817313",
"0.6049375",
"0.6049375",
"0.6017015",
"0.6012597",
"0.60098773",
"0.6008936",
"0.5992937",
"0.59839696",
"0.5977796",
"0.5974981",
"0.5960313",
"0.5946513",
"0.5946513",
"0.5942141",
"0.5941219",
"0.5939136",
"0.5936039",
"0.5926626",
"0.5910405",
"0.59033674",
"0.58996546",
"0.58941287",
"0.5877998",
"0.58717626",
"0.5866429",
"0.5848414",
"0.58430934",
"0.584247",
"0.58327955",
"0.5806903",
"0.5801711",
"0.57945454",
"0.5790657",
"0.57860273",
"0.57860273",
"0.5780745",
"0.57801133",
"0.5776685",
"0.576683",
"0.57621527",
"0.57482564",
"0.5747845",
"0.5747845",
"0.5747845",
"0.57471997",
"0.5739133",
"0.57251954",
"0.5713637",
"0.56939983",
"0.5687406",
"0.56618005",
"0.5658106",
"0.56451744",
"0.5573283",
"0.5568072",
"0.5559405",
"0.5554432",
"0.55503976",
"0.554907",
"0.5526739",
"0.55103683",
"0.55080694",
"0.55060905",
"0.5503251",
"0.55017513",
"0.54838604",
"0.54832953",
"0.5481722",
"0.54744387",
"0.547354",
"0.54602313",
"0.5460016",
"0.5456635",
"0.5436148",
"0.54356736",
"0.5432052",
"0.5430049",
"0.54273266",
"0.5425207",
"0.542006",
"0.5406947",
"0.54030365",
"0.54017913",
"0.539061",
"0.5389655",
"0.53867334",
"0.53743005",
"0.5373668",
"0.5362989",
"0.53613",
"0.53610134"
] | 0.71672094 | 0 |
set the rolemanager to use | public abstract void setRoleManager(OwRoleManager roleManager_p); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void onRoboboManagerStarted(RoboboManager robobom) {\n robobo = robobom;\n\n //dismiss the wait dialog\n waitDialog.dismiss();\n\n //start the \"custom\" robobo application\n\n startRoboboApplication();\n\n }",
"public static void setResourceManager (final ResourceManager rm)\n {\n resourceManager = rm;\n }",
"private void setAlarmManager() {\n\t\tLog.d(CommonUtilities.TAG, \"Set alarm manager\");\n\n\t\tIntent i = new Intent(this, MatchimiAlarmReceiver.class);\n\t\tPendingIntent pi = PendingIntent.getBroadcast(this, 0, i, 0);\n\n\t\tCalendar calendar = Calendar.getInstance();\n\t\tcalendar.setTimeInMillis(System.currentTimeMillis());\n\t\tcalendar.add(Calendar.MINUTE, 1);\n\n\t\tAlarmManager am = (AlarmManager) getSystemService(ALARM_SERVICE);\n\t\tam.cancel(pi); // cancel any existing alarms\n\t\tam.setRepeating(AlarmManager.RTC_WAKEUP, calendar.getTimeInMillis(),\n\t\t\t\t1000 * 60 * 60, pi);\n\n\t\t// am.setInexactRepeating(AlarmManager.ELAPSED_REALTIME,\n\t\t// SystemClock.elapsedRealtime() +\n\t\t// AlarmManager.INTERVAL_FIFTEEN_MINUTES,\n\t\t// AlarmManager.INTERVAL_DAY, pi);\n\t}",
"@Override\n\tpublic void setMgr(Integer mgr) {\n\t\tsuper.setMgr(mgr);\n\t}",
"public void setManager(String manager)\r\n {\r\n m_manager = manager;\r\n }",
"protected final void replaceManager(final T manager) {\n this.writeLock.lock();\n try {\n final T old = this.getManager();\n if (!manager.isRunning()) {\n manager.startup();\n }\n this.manager = manager;\n old.close();\n } finally {\n this.writeLock.unlock();\n }\n }",
"public void setManager(String manager) {\n this.manager = manager;\n }",
"public void start() {\n System.out.println(\"OBRMAN started\");\n ApamManagers.addManager(this, 3);\n OBRMan.obr = new OBRManager(null, repoAdmin);\n obr.startWatchingRepository();\n }",
"public void setManager(ActivityManager manager) {\n this.manager = manager;\n }",
"public abstract void setViewManager(IViewManager viewManager, ITurnManager turnManager);",
"public void setManager(ActivityManager manager) {\r\n this.manager = manager;\r\n manager.add(this);\r\n }",
"public String getManagerName() {\n return \"r\";\n }",
"private void initializeRecallServiceManager() {\n\n }",
"protected void startRoboboApplication() {\n\n\n\n t.schedule(new startInterface(),(long)1000);\n\n try {\n robobo.getModuleInstance(IRemoteControlModule.class).suscribe(this);\n } catch (ModuleNotFoundException e) {\n e.printStackTrace();\n }\n\n\n// try {\n// interfaceModule.getRobInterface().resetPanTiltOffset();\n// } catch (InternalErrorException e) {\n// e.printStackTrace();\n// }\n\n\n }",
"private RoiManager getRoiManager(boolean enReset, boolean enShowNone) {\n Frame frame = WindowManager.getFrame(\"ROI Manager\");\n RoiManager rm = null;\n\n if(frame == null) {\n rm = new RoiManager();\n rm.setVisible(true);\n }\n else {\n rm = (RoiManager)frame;\n }\n\n if(enReset) {\n rm.reset();\n }\n\n if(enShowNone) {\n rm.runCommand(\"Show None\");\n }\n\n return rm;\n }",
"public void setGUIManager(GUIManager guiManager)\r\n {\r\n mGUIManager = guiManager;\r\n }",
"public void setEventManager(GameEventManager eventManager) {\n this.eventManager = eventManager;\n }",
"public void setOfficeManager(OfficeManager officeManager) {\n\t\tthis.officeManager = officeManager;\n\t}",
"public void setTimeManager(TimeManager timeManager) {\n\t\tassert (timeManager != null);\n\t\tthis.timeManager = timeManager;\n\t}",
"public void setObjectManager(ObjectManager objectManager) {\n\tthis.objectManager = (ClientObjectManager) objectManager;\n }",
"public static void setLockManagerActorRef(ActorRef lockManager) {\n\t\tglobalLockManagerActorRef = lockManager;\n\t}",
"public void setPowerManager(final PowerManager powerManager)\n {\n m_PowerManager = powerManager;\n }",
"public void setManager(OtmModelManager modelManager) {\n this.modelManager = modelManager;\n }",
"@Override\n protected void initialize() {\n ramper.reset();\n Robot.toteLifterSubsystem.setGateState(GateState.OPEN);\n }",
"@Reference(\n name = \"listener.manager.service\",\n service = org.apache.axis2.engine.ListenerManager.class,\n cardinality = ReferenceCardinality.OPTIONAL,\n policy = ReferencePolicy.DYNAMIC,\n unbind = \"unsetListenerManager\")\n protected void setListenerManager(ListenerManager listenerManager) {\n if (log.isDebugEnabled()) {\n log.debug(\"Listener manager bound to the API manager component\");\n }\n APIManagerConfigurationService service = ServiceReferenceHolder.getInstance().getAPIManagerConfigurationService();\n if (service != null) {\n service.getAPIManagerConfiguration().reloadSystemProperties();\n }\n }",
"public void initOmicron() {\r\n\t\t// Creates the OmicronAPI object. This is placed in init() since we want\r\n\t\t// to use fullscreen\r\n\t\tomicronManager = new OmicronAPI(this);\r\n\r\n\t\t// Removes the title bar for full screen mode (present mode will not\r\n\t\t// work on Cyber-commons wall)\r\n\t\tomicronManager.setFullscreen(true);\r\n\r\n\t\t// Make the connection to the tracker machine\r\n\t\tomicronManager.ConnectToTracker(7001, 7340, \"131.193.77.159\");\r\n\t\t// Create a listener to get events\r\n\t\ttouchListener = new TouchListener();\r\n\t\ttouchListener.setThings(this);\r\n\t\t// Register listener with OmicronAPI\r\n\t\tomicronManager.setTouchListener(touchListener);\r\n\t}",
"void initCameraManager(){\n\t\tcameraManager = new CameraManager(getApplication());\n\t}",
"public void setConfigManager(ConfigManager configManager) {\n\t\tthis.configManager = configManager;\n\t}",
"Manager getManager() {\n return Manager.getInstance();\n }",
"Manager getManager() {\n return Manager.getInstance();\n }",
"Manager getManager() {\n return Manager.getInstance();\n }",
"@objid (\"b2af5733-9ba2-4eee-b137-cec975f6ba46\")\n void setUserMngr(UserManager value) {\n this.userMngr = value;\n }",
"public synchronized String getManager()\r\n {\r\n return manager;\r\n }",
"static void overrideDefaultManager(InstallationManager manager) {\n INSTANCE = Objects.requireNonNull(manager, \"Given manager instance can't be null.\");\n }",
"public void setCallsManager(MXCallsManager callsManager) {\n checkIfAlive();\n mCallsManager = callsManager;\n }",
"public void initOmicron() {\r\n\t\t// Creates the OmicronAPI object. This is placed in init() since we want\r\n\t\t// to use fullscreen\r\n\t\tomicronManager = new OmicronAPI(this);\r\n\r\n\t\t// Removes the title bar for full screen mode (present mode will not\r\n\t\t// work on Cyber-commons wall)\r\n\t\tomicronManager.setFullscreen(true);\r\n\r\n\t\t// Make the connection to the tracker machine\r\n\t\tomicronManager.ConnectToTracker(7001, 7340, \"131.193.77.159\");\r\n\t\t// Create a listener to get events\r\n\t\ttouchListener = new TouchListener();\r\n\t\ttouchListener.setThings(this);\r\n\t\t// Register listener with OmicronAPI\r\n\t\tomicronManager.setTouchListener(touchListener);\r\n\t\tSystem.out.println(\"Omicron Initiated\");\r\n\t}",
"private void setAudioProfilModem() {\n int ringerMode = mAudioManager.getRingerModeInternal();\n ContentResolver mResolver = mContext.getContentResolver();\n Vibrator vibrator = (Vibrator) mContext\n .getSystemService(Context.VIBRATOR_SERVICE);\n boolean hasVibrator = vibrator == null ? false : vibrator.hasVibrator();\n if (AudioManager.RINGER_MODE_SILENT == ringerMode) {\n if (hasVibrator) {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 0);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_VIBRATE);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_VIBRATE);\n /* @} */\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_RINGER,\n AudioManager.VIBRATE_SETTING_ON);\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_NOTIFICATION,\n AudioManager.VIBRATE_SETTING_ON);\n } else {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 1);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_NORMAL);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_NORMAL);\n /* @} */\n }\n } else if (AudioManager.RINGER_MODE_VIBRATE == ringerMode) {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 1);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_NORMAL);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_OUTDOOR);\n /* @} */\n }else if (AudioManager.RINGER_MODE_OUTDOOR == ringerMode) {//add by wanglei for outdoor mode\n Settings.System.putInt(mResolver,Settings.System.SOUND_EFFECTS_ENABLED, 1);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_NORMAL);\n }else {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 0);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_SILENT);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_SILENT);\n /* @} */\n if (hasVibrator) {\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_RINGER,\n AudioManager.VIBRATE_SETTING_OFF);\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_NOTIFICATION,\n AudioManager.VIBRATE_SETTING_OFF);\n }\n }\n }",
"public void setManagerID(int managerID) { this.managerID = managerID; }",
"private void setReceiver() {\n broadcastReceiver = new BroadcastReceiver() {\n @Override\n public void onReceive(Context context, Intent intent) {\n Bundle bundle = intent.getExtras();\n update(bundle);\n }\n };\n IntentFilter filter = new IntentFilter();\n filter.addAction(RunningContract.progress);\n registerReceiver(broadcastReceiver, filter);\n }",
"public static void setOrePreferences() {\n // list of orePreferences, to be filled by the config\n }",
"private MenuManager() {\r\n\r\n\t\t\tmenubar = new Menu(shell, SWT.BAR);\r\n\t\t\tshell.setMenuBar(menubar);\r\n\t\t}",
"public void setDocumentManager( OntDocumentManager docMgr ) {\n m_docManager = docMgr;\n }",
"public GUIManager getManager(){\n\t\treturn manager;\n\t}",
"public GUIManager getManager(){\n\t\treturn manager;\n\t}",
"public void setManager(String manager) {\n\n if (manager.isEmpty()) {\n\n System.out.println(\"Manager must not be empty\");\n /**\n * If Owner manager is ever an empty String, a NullPointerException will be thrown when the\n * listings are loaded in from the JSON file. I believe this is because the JSON parser we're\n * using stores empty Strings as \"null\" in the .json file. TODO this fix is fine for now, but\n * I want to make it safer in the future.\n */\n this.manager = \" \";\n } else {\n\n this.manager = manager;\n }\n }",
"public IRosterManager getRosterManager() {\n \t\treturn null;\n \t}",
"@Override\r\n public GenericManager<LigneReponseDP, Long> getManager() {\r\n return manager;\r\n }",
"private void resetResources() {\n resourceManager.resetAllResources();\n resourceManager=ResourceManager.getInstance(getApplicationContext()); //need update resourceManager upon reset\n }",
"public void setRequestManager(RequestManager manage) {\n this.requestManager = manage;\n startScheduledTasks(false);\n }",
"public String getManager() {\n return manager;\n }",
"public static void initManager() {\n theManager = new LevelManager();\n lives = 3;\n }",
"private void setRecycleView(){\n\n RecyclerView recyclerView = findViewById(R.id.recycler_view);\n RecyclerView.LayoutManager mLayoutManager = new LinearLayoutManager(getApplicationContext());\n recyclerView.setLayoutManager(mLayoutManager);\n recyclerView.setItemAnimator(new DefaultItemAnimator());\n recyclerView.setAdapter(multiViewAdapter);\n }",
"public ResManager()\n {\n }",
"public void setJoinManager( JoinManager mgr ) {\n\t\tthis.mgr = mgr;\n\t}",
"public RetroStick() {\n eventBus = new EventBus();\n initComponents();\n }",
"public GameManager(Manager manager) {\n\t\tthis.manager = manager;\n\t\tloginValidator = new LoginValidator();\n\t\trv = new RegisterValidator();\n\t\tbool = new AtomicBoolean();\n\t}",
"public String getmanager() {\n\t\treturn _manager;\n\t}",
"public void setBrowserMgr (IBrowserManager theMgr) {\n this.theBrowserMgr = theMgr;\n }",
"private SettingsManager() {\r\n\t\tthis.loadSettings();\r\n\t}",
"public ResourceManager getResourceManager ()\n {\n return _rsrcmgr;\n }",
"@Override\n public void reconfigure()\n {\n }",
"private void initReceiver() {\n\t\tIntentFilter screenOnOffFilter = new IntentFilter(Intent.ACTION_SCREEN_OFF);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_SCREEN_ON);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_USER_PRESENT);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_PACKAGE_ADDED);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_PACKAGE_REMOVED);\n\t\tscreenOnOffFilter.addDataScheme(\"package\");\n\t\treceiver1 = new ScreenLockReceiver();\n\t\tmContext.registerReceiver(receiver1, screenOnOffFilter);\n\t}",
"public abstract void setEventManager(OwEventManager eventManager_p);",
"@Override\r\n\tpublic void setRobot(Robot r) {\r\n\t\t// TODO Auto-generated method stub\r\n\t\trobot = (BasicRobot) r;\r\n\t\t//robot.setMaze(this.mC);\r\n\t\t\r\n\t}",
"public void makeFormalBattleManagerForRecord() {\n BattleMenu.deleteBattleManagerAndMakeMap();\n BattleManager battleManager = new BattleManager(player1, player2, maxNumberOfFlags, maxTurnsOfHavingFlag, gameMode, false);\n BattleMenu.setBattleManager(battleManager);\n this.battleManager = battleManager;\n\n }",
"public void setRenderManager(RenderManager renderManager) {\r\n this.renderManager = renderManager;\r\n renderManager.getOnDemandRenderer(SessionRenderer.ALL_SESSIONS).add(this);\r\n }",
"public void setLockoutManager(@Nullable final AccountLockoutManager manager) {\n checkSetterPreconditions();\n lockoutManager = manager;\n }",
"public void setFileManager(TernFileManager<T> fileManager) {\r\n\t\tthis.fileManager = fileManager;\r\n\t}",
"void setUpLinearManager();",
"public void setUseDefaultRMMRules(boolean useDefaultRMMRules)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(USEDEFAULTRMMRULES$8, 0);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(USEDEFAULTRMMRULES$8);\n }\n target.setBooleanValue(useDefaultRMMRules);\n }\n }",
"private void initManagers() {\n\t\t// TODO Auto-generated method stub\n\t\tvenueManager = new VenueManager();\n\t\tadView = new AdView(this, AdSize.SMART_BANNER,\n\t\t\t\tConstants.AppConstants.ADDMOB);\n\t\tanimationSounds = new AnimationSounds(VenuesActivity.this);\n\n\t}",
"protected void beforeStartManager(Manager manager) {\n }",
"protected void initialize() {\n \t//Robot.getFlywheel().setRunning(!Robot.getFlywheel().running());\n \t//Robot.getElevator().setRunning(!Robot.getElevator().running());\n \tif (run == false)\n \t{\n \t\tRobot.getFlywheel().setRunning(false);\n \t\t//Robot.getIndexer().setRunning(false);\n \t\tRobot.getFlywheel().setSetpoint(0.0);\n \t\tRobot.getFlywheel().disable();\n \t\t//Robot.getIndexer().disable();\n \t\tSystem.out.println(\"not running\");\n \t}\n \telse\n \t{\n \t\tRobot.getFlywheel().initialize();\n \t\tRobot.getFlywheel().enable();\n \t\tRobot.getFlywheel().setRunning(true);\n \t\tdouble m_motorLevel;\n \t\t//m_rpms = SmartDashboard.getNumber(\"FlywheelVelocity\", 1850);\n \t//m_motorLevel = m_rpms / 6750 * 1.35;//6750 = max rpms\n \tm_motorLevel =( m_rpms + 1000) / 6750 *1.1;//6750 = max rpms\n \tRobot.getFlywheel().setSetpoint(m_rpms);\n \tRobot.getFlywheel().setExpectedMotorLevel(m_motorLevel);\n \tSmartDashboard.putNumber(\"FlywheelVelocity\", m_rpms);\n \tSystem.out.println(m_rpms + \" \" + m_motorLevel + \" setpoint: \" + Robot.getFlywheel().getSetpoint());\n \t}\n }",
"private void setUpMenu() {\n\t\trg = (RadioGroup) findViewById(R.id.rg);\n\t\trb1 = (RadioButton) findViewById(R.id.rb1);\n\t\trb2 = (RadioButton) findViewById(R.id.rb2);\n\t\trb3 = (RadioButton) findViewById(R.id.rb3);\n\t\trb4 = (RadioButton) findViewById(R.id.rb4);\n\t\trb5 = (RadioButton) findViewById(R.id.rb5);\n\t\trg.setOnCheckedChangeListener(this);\n\t\trb1.setChecked(true);\n\t\t// OnCheckedChangeListener listener = null;\n\t}",
"protected void initialize()\n\t{\n\t\tenable = SmartDashboard.getBoolean(RobotMap.EnableRespoolWinch);\n\t}",
"public void setRuler(Player ruler) {\r\n\t\tthis.ruler = ruler;\r\n\t}",
"@Override\n public void managerWillStop() {\n }",
"public DisplayManager(Object manager) {\n this.manager = manager;\n }",
"public String getManager() {\n\n return this.manager;\n }",
"public ClientManager(ResourceManager rManager) {\n super();\n this.automaticLogin = false;\n\n // 1 - We load the ProfileConfigList\n this.profileConfigList = ProfileConfigList.load();\n\n if (this.profileConfigList == null) {\n Debug.signal(Debug.NOTICE, this, \"no client's profile found : creating a new one...\");\n this.profileConfigList = new ProfileConfigList();\n } else {\n Debug.signal(Debug.NOTICE, null, \"Client Configs loaded with success !\");\n }\n\n if (!ClientManager.rememberPasswords) {\n this.profileConfigList.deletePasswords(); // make sure we don't save any password here\n this.profileConfigList.save();\n }\n\n // 2 - We load the ServerConfigManager\n this.serverConfigManager = new ServerConfigManager(rManager);\n this.serverConfigManager.setRemoteServerConfigHomeURL(ClientDirector.getRemoteServerConfigHomeURL());\n Debug.signal(Debug.NOTICE, null, \"Server config Manager started with success !\");\n\n // 3 - We get the font we are going to use...\n this.f = FontFactory.getDefaultFontFactory().getFont(\"Lucida Blackletter Regular\");\n }",
"private void setModeUI(){\n\n if (this.inManualMode == true){ this.enableRadioButtons(); } // manual mode\n else if (this.inManualMode == false){ this.disableRadioButtons(); } // automatic mode\n }",
"private void initDLManager() {\n //TODO poner estos datos en configuraciones\n final String botName = \"DL-MS+A\";\n final String directlinePrimaryKey =\n //\"5Cx8OLT2X98.cwA.1j4.FGE7LsMoVuBtww9vQYNuC6lwoVBWYrb-5DHGzBbOeO0\"; // J\n //\"sccvRjdQVbw.cwA.8tQ.3tw3MFQtgG9bcqYf5xxHgW-lUYKymaoSFNCoIzI-SJY\"; //MS+A\n //\"IWixc2S5WaU.cwA.DEw.DV8nbC-BijSw5TbtNimDJuvrp45GpsKCRW4wPTtqYeY\"; //MP-AURA DEV\n \"QyKjl6KL-XQ.cwA.UTM.puyqrjpLvO1Briz7TjM7q_VqqAOflJ3jN0ryBGvkEiU\";\n mDLManager =\n DLManager.getInstance(this, directlinePrimaryKey);\n }",
"public void setLoadGame() {\n this.loadeGame = true;\n }",
"@Override\n\tpublic void registerManager(ManagerAppInterface ma) throws RemoteException {\n\t\t\n\t\tthis.ma = ma;\n\t}",
"@Override\r\n public GenericManager<TraitSalaire, Long> getManager() {\r\n return manager;\r\n }",
"public void setDefaultSettings() {\n boolean shouldRecord = sharedPreferences.getBoolean(record,true);\n if (shouldRecord) {\n radioOption.check(R.id.radioRecord);\n radioOptionButton = (RadioButton)findViewById(R.id.radioRecord);\n radioOptionButton.setEnabled(true);\n } else {\n radioOption.check(R.id.radioRecognize);\n radioOptionButton = (RadioButton)findViewById(R.id.radioRecognize);\n radioOptionButton.setEnabled(true);\n }\n\n // Set timer to previous value set by user\n int minuteValue = sharedPreferences.getInt(minuteTime, 0)/60000;\n minutePicker.setValue(minuteValue);\n\n int secondValue = sharedPreferences.getInt(secondTime, 5000)/1000;\n secondPicker.setValue(secondValue);\n }",
"@Override\n public void init(TaskManager tm, Ui ui) {\n setResponse(ui.askEventName());\n setUtility(tm, ui);\n }",
"@Override\n public void onResume() {\n super.onResume();\n registerReceiver(manager, intentFilter);\n }",
"protected void initialize() {\n \t starttime = Timer.getFPGATimestamp();\n \tthis.startAngle = RobotMap.navx.getAngle();\n \tangleorientation.setSetPoint(RobotMap.navx.getAngle());\n \t\n \tRobotMap.motorLeftTwo.enableControl();\n \tRobotMap.motorRightTwo.enableControl();\n \tRobotMap.motorLeftTwo.enableControl();\n \tRobotMap.motorRightTwo.enableControl();\n \n //settting talon control mode\n \tRobotMap.motorLeftTwo.changeControlMode(TalonControlMode.MotionMagic);\t\t\n\t\tRobotMap.motorLeftOne.changeControlMode(TalonControlMode.Follower);\t\n\t\tRobotMap.motorRightTwo.changeControlMode(TalonControlMode.MotionMagic);\t\n\t\tRobotMap.motorRightOne.changeControlMode(TalonControlMode.Follower);\n\t\t//setting peak and nominal output voltage for the motors\n\t\tRobotMap.motorLeftTwo.configPeakOutputVoltage(+12.0f, -12.0f);\n\t\tRobotMap.motorLeftTwo.configNominalOutputVoltage(0.00f, 0.0f);\n\t\tRobotMap.motorRightTwo.configPeakOutputVoltage(+12.0f, -12.0f);\n\t\tRobotMap.motorRightTwo.configNominalOutputVoltage(0.0f, 0.0f);\n\t\t//setting who is following whom\n\t\tRobotMap.motorLeftOne.set(4);\n\t\tRobotMap.motorRightOne.set(3);\n\t\t//setting pid value for both sides\n\t//\tRobotMap.motorLeftTwo.setCloseLoopRampRate(1);\n\t\tRobotMap.motorLeftTwo.setProfile(0);\n\t RobotMap.motorLeftTwo.setP(0.000014f);\n \tRobotMap.motorLeftTwo.setI(0.00000001);\n\t\tRobotMap.motorLeftTwo.setIZone(0);//325);\n\t\tRobotMap.motorLeftTwo.setD(1.0f);\n\t\tRobotMap.motorLeftTwo.setF(this.fGainLeft+0.014);//0.3625884);\n\t\tRobotMap.motorLeftTwo.setAllowableClosedLoopErr(0);//300);\n\t\t\n\t RobotMap.motorRightTwo.setCloseLoopRampRate(1);\n\t RobotMap.motorRightTwo.setProfile(0);\n\t\tRobotMap.motorRightTwo.setP(0.000014f);\n\t\tRobotMap.motorRightTwo.setI(0.00000001);\n\t\tRobotMap.motorRightTwo.setIZone(0);//325);\n\t\tRobotMap.motorRightTwo.setD(1.0f);\n\t\tRobotMap.motorRightTwo.setF(this.fGainRight);// 0.3373206);\n\t\tRobotMap.motorRightTwo.setAllowableClosedLoopErr(0);//300);\n\t\t\n\t\t//setting Acceleration and velocity for the left\n\t\tRobotMap.motorLeftTwo.setMotionMagicAcceleration(125);\n\t\tRobotMap.motorLeftTwo.setMotionMagicCruiseVelocity(250);\n\t\t//setting Acceleration and velocity for the right\n\t\tRobotMap.motorRightTwo.setMotionMagicAcceleration(125);\n\t\tRobotMap.motorRightTwo.setMotionMagicCruiseVelocity(250);\n\t\t//resets encoder position to 0\t\t\n\t\tRobotMap.motorLeftTwo.setEncPosition(0);\n\t\tRobotMap.motorRightTwo.setEncPosition(0);\n\t //Set Allowable error for the loop\n\t\tRobotMap.motorLeftTwo.setAllowableClosedLoopErr(300);\n\t\tRobotMap.motorRightTwo.setAllowableClosedLoopErr(300);\n\t\t\n\t\t//sets desired endpoint for the motors\n RobotMap.motorLeftTwo.set(motionMagicEndPoint);\n RobotMap.motorRightTwo.set(-motionMagicEndPoint );\n \t\n }",
"public ConfigureRobot()\n {\n Scheduler.getInstance().removeAll(); //remove all running commands\n addSequential(new BrakeOpen(),2);\n addSequential(new WaitCommand(1));\n addSequential(new LiftToBottom(),3);\n }",
"public void teleopInit() {\n armTask.stop();\n driveTask.stop();\n armTask2.stop();\n getRobotDrive().stop();\n driveState = TELEOP;\n armState = TELEOP;\n\n }",
"public void setGeneralManagerName(String generalManagerName);",
"public void createManagerForUser(final String nameAgentManager,int userPerfilType,double userValue)\n\t\t{//TODO LOG\n\t\t\tPlatformController container=getContainerController();\n\t\t\ttry \n\t\t\t{\n\t\t\t\t//Xms128m\n\t\t\t\tObject [] argument;\n\t\t\t\targument= new Object[1];\n\t\t\t\targument[0]=\"Xms1024m\";\n\t\t\t\t\n\t\t\t\tAgentController agentController=container.createNewAgent(nameAgentManager, \"rcs.core.agents.Manager\",argument);\n\t\t\t\tagentController.start();\n\t\t\t\t\n\t\t\t} \n\t\t\tcatch (Exception e) \n\t\t\t{//TODO LOG\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\taddBehaviour(new Behaviour(creatorAgent) \n\t\t\t\t{\n\t\t\t\t\tprivate static final long serialVersionUID = 1L;\n\t\t\t\t\tboolean stopBehaviour=false;\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic boolean done() \n\t\t\t\t\t{\n\t\t\t\t\t\treturn stopBehaviour;\n\t\t\t\t\t}\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void action() \n\t\t\t\t\t{//TODO LOG\n\t\t\t\t\t\tACLMessage message=new ACLMessage(ACLMessage.INFORM);\n\t\t\t\t\t\tmessage.addReceiver(new AID(nameAgentManager,AID.ISLOCALNAME));\n\t\t\t\t\t\tmessage.setLanguage(ConversationsID.LANGUAGE);\n\t\t\t\t\t\tmessage.setOntology(ConversationsID.ONTOLOGY_CREATION);\n\t\t\t\t\t\tmessage.setConversationId(ConversationsID.CREATE_MANAGER);\n\t\t\t\t\t\tmessage.setContent(ConversationsID.CREATE_MANAGER);\n\t\t\t\t\t\t\n\t\t\t\t\t\tmyAgent.send(message); \n\t\t\t\t\t\ttry\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tACLMessage messages=myAgent.receive();\n\t\t\t\t\t\t\tif(messages!=null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif(message.getConversationId()==ConversationsID.CREATE_MANAGER)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tstopBehaviour=true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}else block();\n\t\t\t\t\t\t}catch (Exception e)\n\t\t\t\t\t\t{//TODO LOG\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\taddBehaviour(new OneShotBehaviour() \n\t\t\t\t{\n\t\t\t\t\tprivate static final long serialVersionUID = 1L;\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void action()\n\t\t\t\t\t{\n\t\t\t\t\t\ttry {//TODO LOG\n\t\t\t\t\t\t\tACLMessage message = new ACLMessage(ACLMessage.INFORM);\n\t\t\t\t\t\t\tmessage.addReceiver(new AID(nameAgentManager,AID.ISLOCALNAME));\n\t\t\t\t\t\t\tmessage.setLanguage(ConversationsID.LANGUAGE);\n\t\t\t\t\t\t\tmessage.setOntology(ConversationsID.ONTOLOGY_CREATION);\n\t\t\t\t\t\t\tmessage.setConversationId(ConversationsID.CREATE_EXPERTS);\n\t\t\t\t\t\t\tmessage.setContentObject(newOrderCreate);\n\t\t\t\t\t\t\tmyAgent.send(message);\n\t\t\t\t\t\t\n\t\t\t\t\t\t} catch (IOException e)\n\t\t\t\t\t\t{//TODO LOG\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t}",
"@Override\n protected void initialize() {\n //Robot.limelight.setLiveStream(0);\n Robot.limelight.setLEDMode(3);\n }",
"public Resister() {\n initComponents();\n }",
"public final T getManager() {\n return this.manager;\n }",
"public void setPluginManager(PluginManager pluginManager);",
"public void setReceiver (Receiver receiver) {\n\t\t_receiver = receiver;\n\t}",
"public void initialize()\n {\n \t// Luodaan manager-luokat\n EffectManager.getInstance();\n MessageManager.getInstance();\n CameraManager.getInstance();\n\n // Luodaan pelitilan eri osat\n backgroundManager = new BackgroundManager(wrapper);\n \tweaponManager = new WeaponManager();\n hud = new Hud(context, weaponManager);\n touchManager = new TouchManager(dm, surfaceView, context, hud, weaponManager);\n gameMode = new GameMode(gameActivity, this, dm, context, hud, weaponManager);\n \n // Järjestellään Wrapperin listat uudelleen\n wrapper.sortDrawables();\n wrapper.generateAiGroups();\n \n // Merkitään kaikki ladatuiksi\n allLoaded = true;\n }",
"public String getManager()\r\n {\r\n return (m_manager);\r\n }"
] | [
"0.64464986",
"0.6224552",
"0.59291494",
"0.58918214",
"0.5858403",
"0.5849482",
"0.5812978",
"0.577413",
"0.567098",
"0.5666411",
"0.5648839",
"0.55826104",
"0.55822",
"0.55668914",
"0.55251265",
"0.5493074",
"0.5450819",
"0.54025465",
"0.53942096",
"0.53872514",
"0.5385736",
"0.53847986",
"0.5344758",
"0.5320937",
"0.5304049",
"0.5290353",
"0.52586496",
"0.5254011",
"0.52519417",
"0.52519417",
"0.52519417",
"0.5220354",
"0.52157384",
"0.5208014",
"0.52077067",
"0.51988477",
"0.5196638",
"0.51934403",
"0.51887923",
"0.5187029",
"0.51651627",
"0.5147134",
"0.51412505",
"0.51412505",
"0.5135233",
"0.513319",
"0.5131283",
"0.5125069",
"0.5122733",
"0.510822",
"0.5104713",
"0.5096131",
"0.5092148",
"0.50854814",
"0.5076711",
"0.50699866",
"0.5048004",
"0.5046645",
"0.5044494",
"0.5024884",
"0.5014427",
"0.49990207",
"0.4995904",
"0.49943042",
"0.4980842",
"0.4980007",
"0.4978173",
"0.49726948",
"0.49694073",
"0.49516562",
"0.49462885",
"0.49374336",
"0.49328485",
"0.49326107",
"0.49301863",
"0.49279878",
"0.492779",
"0.49245596",
"0.49210188",
"0.49180022",
"0.4917685",
"0.4904058",
"0.49031356",
"0.49031258",
"0.49020678",
"0.48963994",
"0.48750016",
"0.48729357",
"0.486626",
"0.48607844",
"0.48595187",
"0.4858289",
"0.4846688",
"0.4841134",
"0.48379743",
"0.4837432",
"0.48355913",
"0.48343694",
"0.4831466",
"0.48308104"
] | 0.51293033 | 47 |
set the rolemanager to use | public abstract void setEventManager(OwEventManager eventManager_p); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void onRoboboManagerStarted(RoboboManager robobom) {\n robobo = robobom;\n\n //dismiss the wait dialog\n waitDialog.dismiss();\n\n //start the \"custom\" robobo application\n\n startRoboboApplication();\n\n }",
"public static void setResourceManager (final ResourceManager rm)\n {\n resourceManager = rm;\n }",
"private void setAlarmManager() {\n\t\tLog.d(CommonUtilities.TAG, \"Set alarm manager\");\n\n\t\tIntent i = new Intent(this, MatchimiAlarmReceiver.class);\n\t\tPendingIntent pi = PendingIntent.getBroadcast(this, 0, i, 0);\n\n\t\tCalendar calendar = Calendar.getInstance();\n\t\tcalendar.setTimeInMillis(System.currentTimeMillis());\n\t\tcalendar.add(Calendar.MINUTE, 1);\n\n\t\tAlarmManager am = (AlarmManager) getSystemService(ALARM_SERVICE);\n\t\tam.cancel(pi); // cancel any existing alarms\n\t\tam.setRepeating(AlarmManager.RTC_WAKEUP, calendar.getTimeInMillis(),\n\t\t\t\t1000 * 60 * 60, pi);\n\n\t\t// am.setInexactRepeating(AlarmManager.ELAPSED_REALTIME,\n\t\t// SystemClock.elapsedRealtime() +\n\t\t// AlarmManager.INTERVAL_FIFTEEN_MINUTES,\n\t\t// AlarmManager.INTERVAL_DAY, pi);\n\t}",
"@Override\n\tpublic void setMgr(Integer mgr) {\n\t\tsuper.setMgr(mgr);\n\t}",
"public void setManager(String manager)\r\n {\r\n m_manager = manager;\r\n }",
"protected final void replaceManager(final T manager) {\n this.writeLock.lock();\n try {\n final T old = this.getManager();\n if (!manager.isRunning()) {\n manager.startup();\n }\n this.manager = manager;\n old.close();\n } finally {\n this.writeLock.unlock();\n }\n }",
"public void setManager(String manager) {\n this.manager = manager;\n }",
"public void start() {\n System.out.println(\"OBRMAN started\");\n ApamManagers.addManager(this, 3);\n OBRMan.obr = new OBRManager(null, repoAdmin);\n obr.startWatchingRepository();\n }",
"public void setManager(ActivityManager manager) {\n this.manager = manager;\n }",
"public abstract void setViewManager(IViewManager viewManager, ITurnManager turnManager);",
"public void setManager(ActivityManager manager) {\r\n this.manager = manager;\r\n manager.add(this);\r\n }",
"public String getManagerName() {\n return \"r\";\n }",
"private void initializeRecallServiceManager() {\n\n }",
"protected void startRoboboApplication() {\n\n\n\n t.schedule(new startInterface(),(long)1000);\n\n try {\n robobo.getModuleInstance(IRemoteControlModule.class).suscribe(this);\n } catch (ModuleNotFoundException e) {\n e.printStackTrace();\n }\n\n\n// try {\n// interfaceModule.getRobInterface().resetPanTiltOffset();\n// } catch (InternalErrorException e) {\n// e.printStackTrace();\n// }\n\n\n }",
"private RoiManager getRoiManager(boolean enReset, boolean enShowNone) {\n Frame frame = WindowManager.getFrame(\"ROI Manager\");\n RoiManager rm = null;\n\n if(frame == null) {\n rm = new RoiManager();\n rm.setVisible(true);\n }\n else {\n rm = (RoiManager)frame;\n }\n\n if(enReset) {\n rm.reset();\n }\n\n if(enShowNone) {\n rm.runCommand(\"Show None\");\n }\n\n return rm;\n }",
"public void setGUIManager(GUIManager guiManager)\r\n {\r\n mGUIManager = guiManager;\r\n }",
"public void setEventManager(GameEventManager eventManager) {\n this.eventManager = eventManager;\n }",
"public void setOfficeManager(OfficeManager officeManager) {\n\t\tthis.officeManager = officeManager;\n\t}",
"public void setTimeManager(TimeManager timeManager) {\n\t\tassert (timeManager != null);\n\t\tthis.timeManager = timeManager;\n\t}",
"public void setObjectManager(ObjectManager objectManager) {\n\tthis.objectManager = (ClientObjectManager) objectManager;\n }",
"public static void setLockManagerActorRef(ActorRef lockManager) {\n\t\tglobalLockManagerActorRef = lockManager;\n\t}",
"public void setPowerManager(final PowerManager powerManager)\n {\n m_PowerManager = powerManager;\n }",
"public void setManager(OtmModelManager modelManager) {\n this.modelManager = modelManager;\n }",
"@Override\n protected void initialize() {\n ramper.reset();\n Robot.toteLifterSubsystem.setGateState(GateState.OPEN);\n }",
"@Reference(\n name = \"listener.manager.service\",\n service = org.apache.axis2.engine.ListenerManager.class,\n cardinality = ReferenceCardinality.OPTIONAL,\n policy = ReferencePolicy.DYNAMIC,\n unbind = \"unsetListenerManager\")\n protected void setListenerManager(ListenerManager listenerManager) {\n if (log.isDebugEnabled()) {\n log.debug(\"Listener manager bound to the API manager component\");\n }\n APIManagerConfigurationService service = ServiceReferenceHolder.getInstance().getAPIManagerConfigurationService();\n if (service != null) {\n service.getAPIManagerConfiguration().reloadSystemProperties();\n }\n }",
"public void initOmicron() {\r\n\t\t// Creates the OmicronAPI object. This is placed in init() since we want\r\n\t\t// to use fullscreen\r\n\t\tomicronManager = new OmicronAPI(this);\r\n\r\n\t\t// Removes the title bar for full screen mode (present mode will not\r\n\t\t// work on Cyber-commons wall)\r\n\t\tomicronManager.setFullscreen(true);\r\n\r\n\t\t// Make the connection to the tracker machine\r\n\t\tomicronManager.ConnectToTracker(7001, 7340, \"131.193.77.159\");\r\n\t\t// Create a listener to get events\r\n\t\ttouchListener = new TouchListener();\r\n\t\ttouchListener.setThings(this);\r\n\t\t// Register listener with OmicronAPI\r\n\t\tomicronManager.setTouchListener(touchListener);\r\n\t}",
"void initCameraManager(){\n\t\tcameraManager = new CameraManager(getApplication());\n\t}",
"public void setConfigManager(ConfigManager configManager) {\n\t\tthis.configManager = configManager;\n\t}",
"Manager getManager() {\n return Manager.getInstance();\n }",
"Manager getManager() {\n return Manager.getInstance();\n }",
"Manager getManager() {\n return Manager.getInstance();\n }",
"@objid (\"b2af5733-9ba2-4eee-b137-cec975f6ba46\")\n void setUserMngr(UserManager value) {\n this.userMngr = value;\n }",
"public synchronized String getManager()\r\n {\r\n return manager;\r\n }",
"static void overrideDefaultManager(InstallationManager manager) {\n INSTANCE = Objects.requireNonNull(manager, \"Given manager instance can't be null.\");\n }",
"public void setCallsManager(MXCallsManager callsManager) {\n checkIfAlive();\n mCallsManager = callsManager;\n }",
"public void initOmicron() {\r\n\t\t// Creates the OmicronAPI object. This is placed in init() since we want\r\n\t\t// to use fullscreen\r\n\t\tomicronManager = new OmicronAPI(this);\r\n\r\n\t\t// Removes the title bar for full screen mode (present mode will not\r\n\t\t// work on Cyber-commons wall)\r\n\t\tomicronManager.setFullscreen(true);\r\n\r\n\t\t// Make the connection to the tracker machine\r\n\t\tomicronManager.ConnectToTracker(7001, 7340, \"131.193.77.159\");\r\n\t\t// Create a listener to get events\r\n\t\ttouchListener = new TouchListener();\r\n\t\ttouchListener.setThings(this);\r\n\t\t// Register listener with OmicronAPI\r\n\t\tomicronManager.setTouchListener(touchListener);\r\n\t\tSystem.out.println(\"Omicron Initiated\");\r\n\t}",
"private void setAudioProfilModem() {\n int ringerMode = mAudioManager.getRingerModeInternal();\n ContentResolver mResolver = mContext.getContentResolver();\n Vibrator vibrator = (Vibrator) mContext\n .getSystemService(Context.VIBRATOR_SERVICE);\n boolean hasVibrator = vibrator == null ? false : vibrator.hasVibrator();\n if (AudioManager.RINGER_MODE_SILENT == ringerMode) {\n if (hasVibrator) {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 0);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_VIBRATE);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_VIBRATE);\n /* @} */\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_RINGER,\n AudioManager.VIBRATE_SETTING_ON);\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_NOTIFICATION,\n AudioManager.VIBRATE_SETTING_ON);\n } else {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 1);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_NORMAL);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_NORMAL);\n /* @} */\n }\n } else if (AudioManager.RINGER_MODE_VIBRATE == ringerMode) {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 1);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_NORMAL);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_OUTDOOR);\n /* @} */\n }else if (AudioManager.RINGER_MODE_OUTDOOR == ringerMode) {//add by wanglei for outdoor mode\n Settings.System.putInt(mResolver,Settings.System.SOUND_EFFECTS_ENABLED, 1);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_NORMAL);\n }else {\n Settings.System.putInt(mResolver,\n Settings.System.SOUND_EFFECTS_ENABLED, 0);\n /* SPRD: fixbug454214 The status bar scene mode button is not synchronized with the button set up the scene mode. @{ */\n //mAudioManager.setRingerMode(AudioManager.RINGER_MODE_SILENT);\n mAudioManager.setRingerModeInternal(AudioManager.RINGER_MODE_SILENT);\n /* @} */\n if (hasVibrator) {\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_RINGER,\n AudioManager.VIBRATE_SETTING_OFF);\n mAudioManager.setVibrateSetting(\n AudioManager.VIBRATE_TYPE_NOTIFICATION,\n AudioManager.VIBRATE_SETTING_OFF);\n }\n }\n }",
"public void setManagerID(int managerID) { this.managerID = managerID; }",
"private void setReceiver() {\n broadcastReceiver = new BroadcastReceiver() {\n @Override\n public void onReceive(Context context, Intent intent) {\n Bundle bundle = intent.getExtras();\n update(bundle);\n }\n };\n IntentFilter filter = new IntentFilter();\n filter.addAction(RunningContract.progress);\n registerReceiver(broadcastReceiver, filter);\n }",
"public static void setOrePreferences() {\n // list of orePreferences, to be filled by the config\n }",
"private MenuManager() {\r\n\r\n\t\t\tmenubar = new Menu(shell, SWT.BAR);\r\n\t\t\tshell.setMenuBar(menubar);\r\n\t\t}",
"public void setDocumentManager( OntDocumentManager docMgr ) {\n m_docManager = docMgr;\n }",
"public GUIManager getManager(){\n\t\treturn manager;\n\t}",
"public GUIManager getManager(){\n\t\treturn manager;\n\t}",
"public void setManager(String manager) {\n\n if (manager.isEmpty()) {\n\n System.out.println(\"Manager must not be empty\");\n /**\n * If Owner manager is ever an empty String, a NullPointerException will be thrown when the\n * listings are loaded in from the JSON file. I believe this is because the JSON parser we're\n * using stores empty Strings as \"null\" in the .json file. TODO this fix is fine for now, but\n * I want to make it safer in the future.\n */\n this.manager = \" \";\n } else {\n\n this.manager = manager;\n }\n }",
"public IRosterManager getRosterManager() {\n \t\treturn null;\n \t}",
"@Override\r\n public GenericManager<LigneReponseDP, Long> getManager() {\r\n return manager;\r\n }",
"public abstract void setRoleManager(OwRoleManager roleManager_p);",
"private void resetResources() {\n resourceManager.resetAllResources();\n resourceManager=ResourceManager.getInstance(getApplicationContext()); //need update resourceManager upon reset\n }",
"public void setRequestManager(RequestManager manage) {\n this.requestManager = manage;\n startScheduledTasks(false);\n }",
"public String getManager() {\n return manager;\n }",
"public static void initManager() {\n theManager = new LevelManager();\n lives = 3;\n }",
"private void setRecycleView(){\n\n RecyclerView recyclerView = findViewById(R.id.recycler_view);\n RecyclerView.LayoutManager mLayoutManager = new LinearLayoutManager(getApplicationContext());\n recyclerView.setLayoutManager(mLayoutManager);\n recyclerView.setItemAnimator(new DefaultItemAnimator());\n recyclerView.setAdapter(multiViewAdapter);\n }",
"public ResManager()\n {\n }",
"public void setJoinManager( JoinManager mgr ) {\n\t\tthis.mgr = mgr;\n\t}",
"public RetroStick() {\n eventBus = new EventBus();\n initComponents();\n }",
"public GameManager(Manager manager) {\n\t\tthis.manager = manager;\n\t\tloginValidator = new LoginValidator();\n\t\trv = new RegisterValidator();\n\t\tbool = new AtomicBoolean();\n\t}",
"public String getmanager() {\n\t\treturn _manager;\n\t}",
"public void setBrowserMgr (IBrowserManager theMgr) {\n this.theBrowserMgr = theMgr;\n }",
"private SettingsManager() {\r\n\t\tthis.loadSettings();\r\n\t}",
"public ResourceManager getResourceManager ()\n {\n return _rsrcmgr;\n }",
"@Override\n public void reconfigure()\n {\n }",
"private void initReceiver() {\n\t\tIntentFilter screenOnOffFilter = new IntentFilter(Intent.ACTION_SCREEN_OFF);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_SCREEN_ON);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_USER_PRESENT);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_PACKAGE_ADDED);\n\t\tscreenOnOffFilter.addAction(Intent.ACTION_PACKAGE_REMOVED);\n\t\tscreenOnOffFilter.addDataScheme(\"package\");\n\t\treceiver1 = new ScreenLockReceiver();\n\t\tmContext.registerReceiver(receiver1, screenOnOffFilter);\n\t}",
"@Override\r\n\tpublic void setRobot(Robot r) {\r\n\t\t// TODO Auto-generated method stub\r\n\t\trobot = (BasicRobot) r;\r\n\t\t//robot.setMaze(this.mC);\r\n\t\t\r\n\t}",
"public void makeFormalBattleManagerForRecord() {\n BattleMenu.deleteBattleManagerAndMakeMap();\n BattleManager battleManager = new BattleManager(player1, player2, maxNumberOfFlags, maxTurnsOfHavingFlag, gameMode, false);\n BattleMenu.setBattleManager(battleManager);\n this.battleManager = battleManager;\n\n }",
"public void setRenderManager(RenderManager renderManager) {\r\n this.renderManager = renderManager;\r\n renderManager.getOnDemandRenderer(SessionRenderer.ALL_SESSIONS).add(this);\r\n }",
"public void setLockoutManager(@Nullable final AccountLockoutManager manager) {\n checkSetterPreconditions();\n lockoutManager = manager;\n }",
"public void setFileManager(TernFileManager<T> fileManager) {\r\n\t\tthis.fileManager = fileManager;\r\n\t}",
"void setUpLinearManager();",
"public void setUseDefaultRMMRules(boolean useDefaultRMMRules)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(USEDEFAULTRMMRULES$8, 0);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(USEDEFAULTRMMRULES$8);\n }\n target.setBooleanValue(useDefaultRMMRules);\n }\n }",
"private void initManagers() {\n\t\t// TODO Auto-generated method stub\n\t\tvenueManager = new VenueManager();\n\t\tadView = new AdView(this, AdSize.SMART_BANNER,\n\t\t\t\tConstants.AppConstants.ADDMOB);\n\t\tanimationSounds = new AnimationSounds(VenuesActivity.this);\n\n\t}",
"protected void beforeStartManager(Manager manager) {\n }",
"protected void initialize() {\n \t//Robot.getFlywheel().setRunning(!Robot.getFlywheel().running());\n \t//Robot.getElevator().setRunning(!Robot.getElevator().running());\n \tif (run == false)\n \t{\n \t\tRobot.getFlywheel().setRunning(false);\n \t\t//Robot.getIndexer().setRunning(false);\n \t\tRobot.getFlywheel().setSetpoint(0.0);\n \t\tRobot.getFlywheel().disable();\n \t\t//Robot.getIndexer().disable();\n \t\tSystem.out.println(\"not running\");\n \t}\n \telse\n \t{\n \t\tRobot.getFlywheel().initialize();\n \t\tRobot.getFlywheel().enable();\n \t\tRobot.getFlywheel().setRunning(true);\n \t\tdouble m_motorLevel;\n \t\t//m_rpms = SmartDashboard.getNumber(\"FlywheelVelocity\", 1850);\n \t//m_motorLevel = m_rpms / 6750 * 1.35;//6750 = max rpms\n \tm_motorLevel =( m_rpms + 1000) / 6750 *1.1;//6750 = max rpms\n \tRobot.getFlywheel().setSetpoint(m_rpms);\n \tRobot.getFlywheel().setExpectedMotorLevel(m_motorLevel);\n \tSmartDashboard.putNumber(\"FlywheelVelocity\", m_rpms);\n \tSystem.out.println(m_rpms + \" \" + m_motorLevel + \" setpoint: \" + Robot.getFlywheel().getSetpoint());\n \t}\n }",
"private void setUpMenu() {\n\t\trg = (RadioGroup) findViewById(R.id.rg);\n\t\trb1 = (RadioButton) findViewById(R.id.rb1);\n\t\trb2 = (RadioButton) findViewById(R.id.rb2);\n\t\trb3 = (RadioButton) findViewById(R.id.rb3);\n\t\trb4 = (RadioButton) findViewById(R.id.rb4);\n\t\trb5 = (RadioButton) findViewById(R.id.rb5);\n\t\trg.setOnCheckedChangeListener(this);\n\t\trb1.setChecked(true);\n\t\t// OnCheckedChangeListener listener = null;\n\t}",
"protected void initialize()\n\t{\n\t\tenable = SmartDashboard.getBoolean(RobotMap.EnableRespoolWinch);\n\t}",
"public void setRuler(Player ruler) {\r\n\t\tthis.ruler = ruler;\r\n\t}",
"@Override\n public void managerWillStop() {\n }",
"public DisplayManager(Object manager) {\n this.manager = manager;\n }",
"public String getManager() {\n\n return this.manager;\n }",
"public ClientManager(ResourceManager rManager) {\n super();\n this.automaticLogin = false;\n\n // 1 - We load the ProfileConfigList\n this.profileConfigList = ProfileConfigList.load();\n\n if (this.profileConfigList == null) {\n Debug.signal(Debug.NOTICE, this, \"no client's profile found : creating a new one...\");\n this.profileConfigList = new ProfileConfigList();\n } else {\n Debug.signal(Debug.NOTICE, null, \"Client Configs loaded with success !\");\n }\n\n if (!ClientManager.rememberPasswords) {\n this.profileConfigList.deletePasswords(); // make sure we don't save any password here\n this.profileConfigList.save();\n }\n\n // 2 - We load the ServerConfigManager\n this.serverConfigManager = new ServerConfigManager(rManager);\n this.serverConfigManager.setRemoteServerConfigHomeURL(ClientDirector.getRemoteServerConfigHomeURL());\n Debug.signal(Debug.NOTICE, null, \"Server config Manager started with success !\");\n\n // 3 - We get the font we are going to use...\n this.f = FontFactory.getDefaultFontFactory().getFont(\"Lucida Blackletter Regular\");\n }",
"private void setModeUI(){\n\n if (this.inManualMode == true){ this.enableRadioButtons(); } // manual mode\n else if (this.inManualMode == false){ this.disableRadioButtons(); } // automatic mode\n }",
"private void initDLManager() {\n //TODO poner estos datos en configuraciones\n final String botName = \"DL-MS+A\";\n final String directlinePrimaryKey =\n //\"5Cx8OLT2X98.cwA.1j4.FGE7LsMoVuBtww9vQYNuC6lwoVBWYrb-5DHGzBbOeO0\"; // J\n //\"sccvRjdQVbw.cwA.8tQ.3tw3MFQtgG9bcqYf5xxHgW-lUYKymaoSFNCoIzI-SJY\"; //MS+A\n //\"IWixc2S5WaU.cwA.DEw.DV8nbC-BijSw5TbtNimDJuvrp45GpsKCRW4wPTtqYeY\"; //MP-AURA DEV\n \"QyKjl6KL-XQ.cwA.UTM.puyqrjpLvO1Briz7TjM7q_VqqAOflJ3jN0ryBGvkEiU\";\n mDLManager =\n DLManager.getInstance(this, directlinePrimaryKey);\n }",
"public void setLoadGame() {\n this.loadeGame = true;\n }",
"@Override\n\tpublic void registerManager(ManagerAppInterface ma) throws RemoteException {\n\t\t\n\t\tthis.ma = ma;\n\t}",
"@Override\r\n public GenericManager<TraitSalaire, Long> getManager() {\r\n return manager;\r\n }",
"public void setDefaultSettings() {\n boolean shouldRecord = sharedPreferences.getBoolean(record,true);\n if (shouldRecord) {\n radioOption.check(R.id.radioRecord);\n radioOptionButton = (RadioButton)findViewById(R.id.radioRecord);\n radioOptionButton.setEnabled(true);\n } else {\n radioOption.check(R.id.radioRecognize);\n radioOptionButton = (RadioButton)findViewById(R.id.radioRecognize);\n radioOptionButton.setEnabled(true);\n }\n\n // Set timer to previous value set by user\n int minuteValue = sharedPreferences.getInt(minuteTime, 0)/60000;\n minutePicker.setValue(minuteValue);\n\n int secondValue = sharedPreferences.getInt(secondTime, 5000)/1000;\n secondPicker.setValue(secondValue);\n }",
"@Override\n public void init(TaskManager tm, Ui ui) {\n setResponse(ui.askEventName());\n setUtility(tm, ui);\n }",
"@Override\n public void onResume() {\n super.onResume();\n registerReceiver(manager, intentFilter);\n }",
"protected void initialize() {\n \t starttime = Timer.getFPGATimestamp();\n \tthis.startAngle = RobotMap.navx.getAngle();\n \tangleorientation.setSetPoint(RobotMap.navx.getAngle());\n \t\n \tRobotMap.motorLeftTwo.enableControl();\n \tRobotMap.motorRightTwo.enableControl();\n \tRobotMap.motorLeftTwo.enableControl();\n \tRobotMap.motorRightTwo.enableControl();\n \n //settting talon control mode\n \tRobotMap.motorLeftTwo.changeControlMode(TalonControlMode.MotionMagic);\t\t\n\t\tRobotMap.motorLeftOne.changeControlMode(TalonControlMode.Follower);\t\n\t\tRobotMap.motorRightTwo.changeControlMode(TalonControlMode.MotionMagic);\t\n\t\tRobotMap.motorRightOne.changeControlMode(TalonControlMode.Follower);\n\t\t//setting peak and nominal output voltage for the motors\n\t\tRobotMap.motorLeftTwo.configPeakOutputVoltage(+12.0f, -12.0f);\n\t\tRobotMap.motorLeftTwo.configNominalOutputVoltage(0.00f, 0.0f);\n\t\tRobotMap.motorRightTwo.configPeakOutputVoltage(+12.0f, -12.0f);\n\t\tRobotMap.motorRightTwo.configNominalOutputVoltage(0.0f, 0.0f);\n\t\t//setting who is following whom\n\t\tRobotMap.motorLeftOne.set(4);\n\t\tRobotMap.motorRightOne.set(3);\n\t\t//setting pid value for both sides\n\t//\tRobotMap.motorLeftTwo.setCloseLoopRampRate(1);\n\t\tRobotMap.motorLeftTwo.setProfile(0);\n\t RobotMap.motorLeftTwo.setP(0.000014f);\n \tRobotMap.motorLeftTwo.setI(0.00000001);\n\t\tRobotMap.motorLeftTwo.setIZone(0);//325);\n\t\tRobotMap.motorLeftTwo.setD(1.0f);\n\t\tRobotMap.motorLeftTwo.setF(this.fGainLeft+0.014);//0.3625884);\n\t\tRobotMap.motorLeftTwo.setAllowableClosedLoopErr(0);//300);\n\t\t\n\t RobotMap.motorRightTwo.setCloseLoopRampRate(1);\n\t RobotMap.motorRightTwo.setProfile(0);\n\t\tRobotMap.motorRightTwo.setP(0.000014f);\n\t\tRobotMap.motorRightTwo.setI(0.00000001);\n\t\tRobotMap.motorRightTwo.setIZone(0);//325);\n\t\tRobotMap.motorRightTwo.setD(1.0f);\n\t\tRobotMap.motorRightTwo.setF(this.fGainRight);// 0.3373206);\n\t\tRobotMap.motorRightTwo.setAllowableClosedLoopErr(0);//300);\n\t\t\n\t\t//setting Acceleration and velocity for the left\n\t\tRobotMap.motorLeftTwo.setMotionMagicAcceleration(125);\n\t\tRobotMap.motorLeftTwo.setMotionMagicCruiseVelocity(250);\n\t\t//setting Acceleration and velocity for the right\n\t\tRobotMap.motorRightTwo.setMotionMagicAcceleration(125);\n\t\tRobotMap.motorRightTwo.setMotionMagicCruiseVelocity(250);\n\t\t//resets encoder position to 0\t\t\n\t\tRobotMap.motorLeftTwo.setEncPosition(0);\n\t\tRobotMap.motorRightTwo.setEncPosition(0);\n\t //Set Allowable error for the loop\n\t\tRobotMap.motorLeftTwo.setAllowableClosedLoopErr(300);\n\t\tRobotMap.motorRightTwo.setAllowableClosedLoopErr(300);\n\t\t\n\t\t//sets desired endpoint for the motors\n RobotMap.motorLeftTwo.set(motionMagicEndPoint);\n RobotMap.motorRightTwo.set(-motionMagicEndPoint );\n \t\n }",
"public ConfigureRobot()\n {\n Scheduler.getInstance().removeAll(); //remove all running commands\n addSequential(new BrakeOpen(),2);\n addSequential(new WaitCommand(1));\n addSequential(new LiftToBottom(),3);\n }",
"public void teleopInit() {\n armTask.stop();\n driveTask.stop();\n armTask2.stop();\n getRobotDrive().stop();\n driveState = TELEOP;\n armState = TELEOP;\n\n }",
"public void setGeneralManagerName(String generalManagerName);",
"public void createManagerForUser(final String nameAgentManager,int userPerfilType,double userValue)\n\t\t{//TODO LOG\n\t\t\tPlatformController container=getContainerController();\n\t\t\ttry \n\t\t\t{\n\t\t\t\t//Xms128m\n\t\t\t\tObject [] argument;\n\t\t\t\targument= new Object[1];\n\t\t\t\targument[0]=\"Xms1024m\";\n\t\t\t\t\n\t\t\t\tAgentController agentController=container.createNewAgent(nameAgentManager, \"rcs.core.agents.Manager\",argument);\n\t\t\t\tagentController.start();\n\t\t\t\t\n\t\t\t} \n\t\t\tcatch (Exception e) \n\t\t\t{//TODO LOG\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\taddBehaviour(new Behaviour(creatorAgent) \n\t\t\t\t{\n\t\t\t\t\tprivate static final long serialVersionUID = 1L;\n\t\t\t\t\tboolean stopBehaviour=false;\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic boolean done() \n\t\t\t\t\t{\n\t\t\t\t\t\treturn stopBehaviour;\n\t\t\t\t\t}\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void action() \n\t\t\t\t\t{//TODO LOG\n\t\t\t\t\t\tACLMessage message=new ACLMessage(ACLMessage.INFORM);\n\t\t\t\t\t\tmessage.addReceiver(new AID(nameAgentManager,AID.ISLOCALNAME));\n\t\t\t\t\t\tmessage.setLanguage(ConversationsID.LANGUAGE);\n\t\t\t\t\t\tmessage.setOntology(ConversationsID.ONTOLOGY_CREATION);\n\t\t\t\t\t\tmessage.setConversationId(ConversationsID.CREATE_MANAGER);\n\t\t\t\t\t\tmessage.setContent(ConversationsID.CREATE_MANAGER);\n\t\t\t\t\t\t\n\t\t\t\t\t\tmyAgent.send(message); \n\t\t\t\t\t\ttry\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tACLMessage messages=myAgent.receive();\n\t\t\t\t\t\t\tif(messages!=null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif(message.getConversationId()==ConversationsID.CREATE_MANAGER)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tstopBehaviour=true;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}else block();\n\t\t\t\t\t\t}catch (Exception e)\n\t\t\t\t\t\t{//TODO LOG\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\taddBehaviour(new OneShotBehaviour() \n\t\t\t\t{\n\t\t\t\t\tprivate static final long serialVersionUID = 1L;\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void action()\n\t\t\t\t\t{\n\t\t\t\t\t\ttry {//TODO LOG\n\t\t\t\t\t\t\tACLMessage message = new ACLMessage(ACLMessage.INFORM);\n\t\t\t\t\t\t\tmessage.addReceiver(new AID(nameAgentManager,AID.ISLOCALNAME));\n\t\t\t\t\t\t\tmessage.setLanguage(ConversationsID.LANGUAGE);\n\t\t\t\t\t\t\tmessage.setOntology(ConversationsID.ONTOLOGY_CREATION);\n\t\t\t\t\t\t\tmessage.setConversationId(ConversationsID.CREATE_EXPERTS);\n\t\t\t\t\t\t\tmessage.setContentObject(newOrderCreate);\n\t\t\t\t\t\t\tmyAgent.send(message);\n\t\t\t\t\t\t\n\t\t\t\t\t\t} catch (IOException e)\n\t\t\t\t\t\t{//TODO LOG\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t}",
"@Override\n protected void initialize() {\n //Robot.limelight.setLiveStream(0);\n Robot.limelight.setLEDMode(3);\n }",
"public Resister() {\n initComponents();\n }",
"public final T getManager() {\n return this.manager;\n }",
"public void setPluginManager(PluginManager pluginManager);",
"public void setReceiver (Receiver receiver) {\n\t\t_receiver = receiver;\n\t}",
"public void initialize()\n {\n \t// Luodaan manager-luokat\n EffectManager.getInstance();\n MessageManager.getInstance();\n CameraManager.getInstance();\n\n // Luodaan pelitilan eri osat\n backgroundManager = new BackgroundManager(wrapper);\n \tweaponManager = new WeaponManager();\n hud = new Hud(context, weaponManager);\n touchManager = new TouchManager(dm, surfaceView, context, hud, weaponManager);\n gameMode = new GameMode(gameActivity, this, dm, context, hud, weaponManager);\n \n // Järjestellään Wrapperin listat uudelleen\n wrapper.sortDrawables();\n wrapper.generateAiGroups();\n \n // Merkitään kaikki ladatuiksi\n allLoaded = true;\n }",
"public String getManager()\r\n {\r\n return (m_manager);\r\n }"
] | [
"0.64464986",
"0.6224552",
"0.59291494",
"0.58918214",
"0.5858403",
"0.5849482",
"0.5812978",
"0.577413",
"0.567098",
"0.5666411",
"0.5648839",
"0.55826104",
"0.55822",
"0.55668914",
"0.55251265",
"0.5493074",
"0.5450819",
"0.54025465",
"0.53942096",
"0.53872514",
"0.5385736",
"0.53847986",
"0.5344758",
"0.5320937",
"0.5304049",
"0.5290353",
"0.52586496",
"0.5254011",
"0.52519417",
"0.52519417",
"0.52519417",
"0.5220354",
"0.52157384",
"0.5208014",
"0.52077067",
"0.51988477",
"0.5196638",
"0.51934403",
"0.51887923",
"0.5187029",
"0.51651627",
"0.5147134",
"0.51412505",
"0.51412505",
"0.5135233",
"0.513319",
"0.5131283",
"0.51293033",
"0.5125069",
"0.5122733",
"0.510822",
"0.5104713",
"0.5096131",
"0.5092148",
"0.50854814",
"0.5076711",
"0.50699866",
"0.5048004",
"0.5046645",
"0.5044494",
"0.5024884",
"0.5014427",
"0.49990207",
"0.49943042",
"0.4980842",
"0.4980007",
"0.4978173",
"0.49726948",
"0.49694073",
"0.49516562",
"0.49462885",
"0.49374336",
"0.49328485",
"0.49326107",
"0.49301863",
"0.49279878",
"0.492779",
"0.49245596",
"0.49210188",
"0.49180022",
"0.4917685",
"0.4904058",
"0.49031356",
"0.49031258",
"0.49020678",
"0.48963994",
"0.48750016",
"0.48729357",
"0.486626",
"0.48607844",
"0.48595187",
"0.4858289",
"0.4846688",
"0.4841134",
"0.48379743",
"0.4837432",
"0.48355913",
"0.48343694",
"0.4831466",
"0.48308104"
] | 0.4995904 | 63 |
=== permission functions get an instance of the edit access rights UI submodule for editing document access rights Access rights are very specific to the ECM System and can not be handled generically | public abstract OwUIAccessRightsModul getEditAccessRightsSubModul(OwObject object_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract boolean canEditAccessRights(OwObject object_p) throws Exception;",
"Menu getMenuEdit();",
"public interface SecurityOptionIFace\n{\n /**\n * @return a unique name (without a security prefix) used by the security system, \n * doesn't need to be localized and is not intended to be human readable.\n */\n public abstract String getPermissionName();\n \n /**\n * @return the localized human readable title of the permission.\n */\n public abstract String getPermissionTitle();\n \n /**\n * @return a short localized description of the security option to help explain what it is.\n */\n public abstract String getShortDesc();\n \n /**\n * Return the icon that represents the task.\n * @param size use standard size (i.e. 32, 24, 20, 26)\n * @return the icon that represents the task\n */\n public abstract ImageIcon getIcon(int size);\n \n /**\n * @return a PermissionEditorIFace object that is used to set the permissions for the\n * the task.\n */\n public abstract PermissionEditorIFace getPermEditorPanel();\n \n /**\n * @return returns a permissions object\n */\n public abstract PermissionIFace getPermissions();\n \n /**\n * Sets a permission object.\n * @param permissions the object\n */\n public abstract void setPermissions(PermissionIFace permissions);\n \n /**\n * @return a list of addition Security options. These can be thought as 'sub-options'.\n */\n public abstract List<SecurityOptionIFace> getAdditionalSecurityOptions(); \n \n /**\n * @param userType the type of use, this value is implementation dependent, it can be null\n * @return the default permissions for a user type\n */\n public abstract PermissionIFace getDefaultPermissions(String userType);\n \n}",
"private MenuManager createEditMenu() {\n\t\tMenuManager menu = new MenuManager(\"&Edition\", Messages.getString(\"IU.Strings.40\")); //$NON-NLS-1$ //$NON-NLS-2$\n\t\tmenu.add(new GroupMarker(Messages.getString(\"IU.Strings.41\"))); //$NON-NLS-1$\n\n\t\tmenu.add(getAction(ActionFactory.UNDO.getId()));\n\t\tmenu.add(getAction(ActionFactory.REDO.getId()));;\n\n\t\tmenu.add(new GroupMarker(IWorkbenchActionConstants.UNDO_EXT));\n\t\tmenu.add(new Separator());\n\t\tmenu.add(getAction(ActionFactory.CUT.getId()));\n\t\tmenu.add(getAction(ActionFactory.COPY.getId()));\n\t\tmenu.add(getAction(ActionFactory.PASTE.getId()));\n\t\tmenu.add(new GroupMarker(IWorkbenchActionConstants.CUT_EXT));\n\t\tmenu.add(new Separator());\n\t\tmenu.add(getAction(ActionFactory.DELETE.getId()));\n\t\tmenu.add(getAction(ActionFactory.SELECT_ALL.getId()));\n\t\tmenu.add(getAction(ActionFactory.FIND.getId()));\n\t\tmenu.add(new Separator());\n\t\tmenu.add(getAction(ActionFactory.PREFERENCES.getId()));\n\t\treturn menu;\n\t}",
"private void setPermissions( String userId, ProposalDevelopmentDocument doc, Set<String> editModes ) {\n\t\tif ( editModes.contains( AuthorizationConstants.EditMode.FULL_ENTRY ) ) {\n\t\t\teditModes.add( \"modifyProposal\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.ADD_BUDGET ) ) {\n\t\t\teditModes.add( \"addBudget\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.OPEN_BUDGETS ) ) {\n\t\t\teditModes.add( \"openBudgets\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.MODIFY_BUDGET ) ) {\n\t\t\teditModes.add( \"modifyProposalBudget\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.MODIFY_PROPOSAL_ROLES ) ) {\n\t\t\teditModes.add( \"modifyPermissions\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.ADD_NARRATIVE ) ) {\n\t\t\teditModes.add( \"addNarratives\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.CERTIFY ) ) {\n\t\t\teditModes.add( \"certify\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.MODIFY_NARRATIVE_STATUS ) ) {\n\t\t\teditModes.add( \"modifyNarrativeStatus\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.PRINT_PROPOSAL ) ) {\n\t\t\teditModes.add( \"printProposal\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.ALTER_PROPOSAL_DATA ) ) {\n\t\t\teditModes.add( \"alterProposalData\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.SHOW_ALTER_PROPOSAL_DATA ) ) {\n\t\t\teditModes.add( \"showAlterProposalData\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.SUBMIT_TO_SPONSOR ) ) {\n\t\t\teditModes.add( \"submitToSponsor\" );\n\t\t}\n\t\tif ( canExecuteTask( userId, doc, TaskName.MAINTAIN_PROPOSAL_HIERARCHY ) ) {\n\t\t\teditModes.add( \"maintainProposalHierarchy\" );\n\t\t}\n\n\t\tif ( canExecuteTask( userId, doc, TaskName.REJECT_PROPOSAL ) ) {\n\t\t\teditModes.add( TaskName.REJECT_PROPOSAL );\n\t\t}\n\n\t\tsetNarrativePermissions( userId, doc, editModes );\n\t}",
"public interface ACSUIEditor {\n\n ACSUIEditable getEditable(SimpleRequestContext src);\n\n ACSUIEditable getEditable();\n\n ACSUIEditable updatetEditable(SimpleRequestContext src);\n\n ACSUIEditable insertEditable(SimpleRequestContext src);\n\n ACSUIEditable deleteEditable(SimpleRequestContext src);\n\n ACSUIEditable[] getEditables(SimpleRequestContext src);\n\n String[] getColNames();\n\n String getType();\n\n boolean[] checkInputData(ACSRequestContext ctx);\n\n String getManagmentLabel();\n\n String getAddLabel();\n\n String getUpdateLabel();\n\n}",
"public AccessibleRole getAccessibleRole()\n/* */ {\n/* 236 */ return AccessibleRole.POPUP_MENU;\n/* */ }",
"JApiModifier<AccessModifier> getAccessModifier();",
"abstract public void getPermission();",
"public Boolean getCanEdit() {\r\n return getAttributeAsBoolean(\"canEdit\");\r\n }",
"private void changePermissionsInUI(int position) {\n if (permissions.get(position).equals(\"Viewer\")) {\n permissions.set(position, \"Editor\");\n items.set(position, users.get(position) + \": Editor\");\n Toast.makeText(RoomSettingsActivity.this, users.get(position) + \" has been changed to an Editor\", Toast.LENGTH_SHORT).show();\n } else if (permissions.get(position).equals(\"Editor\")) {\n permissions.set(position, \"Viewer\");\n items.set(position, users.get(position) + \": Viewer\");\n Toast.makeText(RoomSettingsActivity.this, users.get(position) + \" has been changed to a Viewer\", Toast.LENGTH_SHORT).show();\n }\n }",
"public interface AccessManager {\n\n /**\n * predefined action constants\n */\n public String READ_ACTION = javax.jcr.Session.ACTION_READ;\n public String REMOVE_ACTION = javax.jcr.Session.ACTION_REMOVE;\n public String ADD_NODE_ACTION = javax.jcr.Session.ACTION_ADD_NODE;\n public String SET_PROPERTY_ACTION = javax.jcr.Session.ACTION_SET_PROPERTY;\n\n public String[] READ = new String[] {READ_ACTION};\n public String[] REMOVE = new String[] {REMOVE_ACTION};\n\n /**\n * Determines whether the specified <code>permissions</code> are granted\n * on the item with the specified path.\n *\n * @param parentState The node state of the next existing ancestor.\n * @param relPath The relative path pointing to the non-existing target item.\n * @param actions An array of actions that need to be checked.\n * @return <code>true</code> if the actions are granted; otherwise <code>false</code>\n * @throws ItemNotFoundException if the target item does not exist\n * @throws RepositoryException if another error occurs\n */\n boolean isGranted(NodeState parentState, Path relPath, String[] actions) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Determines whether the specified <code>permissions</code> are granted\n * on the item with the specified path.\n *\n * @param itemState\n * @param actions An array of actions that need to be checked.\n * @return <code>true</code> if the actions are granted; otherwise <code>false</code>\n * @throws ItemNotFoundException if the target item does not exist\n * @throws RepositoryException if another error occurs\n */\n boolean isGranted(ItemState itemState, String[] actions) throws ItemNotFoundException, RepositoryException;\n\n\n /**\n * Returns true if the existing item with the given <code>ItemId</code> can\n * be read.\n *\n * @param itemState\n * @return\n * @throws ItemNotFoundException\n * @throws RepositoryException\n */\n boolean canRead(ItemState itemState) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Returns true if the existing item state can be removed.\n *\n * @param itemState\n * @return\n * @throws ItemNotFoundException\n * @throws RepositoryException\n */\n boolean canRemove(ItemState itemState) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Determines whether the subject of the current context is granted access\n * to the given workspace.\n *\n * @param workspaceName name of workspace\n * @return <code>true</code> if the subject of the current context is\n * granted access to the given workspace; otherwise <code>false</code>.\n * @throws NoSuchWorkspaceException if a workspace with the given name does not exist.\n * @throws RepositoryException if another error occurs\n */\n boolean canAccess(String workspaceName) throws NoSuchWorkspaceException, RepositoryException;\n}",
"@Override\n\tprotected void createEditPolicies()\n\t{\n\t\t\n\t}",
"boolean openPageInEditMode();",
"private ContextMenu getElementSpecificContextMenu(){\n MenuItem menuItem_EditTLE = new MenuItem(\"Edit annotation\");\n menuItem_EditTLE.setOnAction(event -> handleEditTimeLineElementClick());\n\n\n MenuItem menuItem_DeleteTLE = new MenuItem(\"Delete annotation\");\n menuItem_DeleteTLE.setOnAction(event -> handleDeleteTimeLineElementClick());\n\n return new ContextMenu(menuItem_EditTLE, menuItem_DeleteTLE);\n }",
"public String loadMainEdit(){\r\n\t\treturn \"edit\";\r\n }",
"@ProvidedBy(ODocumentWrapperProvider.class)\n@EntityType(value = OSecurityShared.RESTRICTED_CLASSNAME)\npublic interface IORestricted extends IODocumentWrapper {\n\t\n\t@EntityProperty(\"_allow\")\n\tpublic Set<OIdentifiable> getAllowAll();\n\t@EntityProperty(\"_allow\")\n\tpublic IORestricted setAllowAll(Set<OIdentifiable> identifiables);\n\t\n\tpublic default IORestricted addToAllowAll(OIdentifiable identifiable) {\n\t\treturn setAllowAll(addSafely(getAllowAll(), identifiable));\n\t}\n\t\n\tpublic default IORestricted remoteFromAllowAll(OIdentifiable identifiable) {\n\t\treturn setAllowAll(removeSafely(getAllowAll(), identifiable));\n\t}\n\t\n\t@EntityProperty(\"_allowRead\")\n\tpublic Set<OIdentifiable> getAllowRead();\n\t@EntityProperty(\"_allowRead\")\n\tpublic IORestricted setAllowRead(Set<OIdentifiable> identifiables);\n\t\n\tpublic default IORestricted addToAllowRead(OIdentifiable identifiable) {\n\t\treturn setAllowRead(addSafely(getAllowRead(), identifiable));\n\t}\n\t\n\tpublic default IORestricted remoteFromAllowRead(OIdentifiable identifiable) {\n\t\treturn setAllowRead(removeSafely(getAllowRead(), identifiable));\n\t}\n\t\n\t@EntityProperty(\"_allowUpdate\")\n\tpublic Set<OIdentifiable> getAllowUpdate();\n\t@EntityProperty(\"_allowUpdate\")\n\tpublic IORestricted setAllowUpdate(Set<OIdentifiable> identifiables);\n\t\n\tpublic default IORestricted addToAllowUpdate(OIdentifiable identifiable) {\n\t\treturn setAllowUpdate(addSafely(getAllowUpdate(), identifiable));\n\t}\n\t\n\tpublic default IORestricted remoteFromAllowUpdate(OIdentifiable identifiable) {\n\t\treturn setAllowUpdate(removeSafely(getAllowUpdate(), identifiable));\n\t}\n\t\n\t@EntityProperty(\"_allowDelete\")\n\tpublic Set<OIdentifiable> getAllowDelete();\n\t@EntityProperty(\"_allowDelete\")\n\tpublic IORestricted setAllowDelete(Set<OIdentifiable> identifiables);\n\t\n\tpublic default IORestricted addToAllowDelete(OIdentifiable identifiable) {\n\t\treturn setAllowDelete(addSafely(getAllowDelete(), identifiable));\n\t}\n\t\n\tpublic default IORestricted remoteFromAllowDelete(OIdentifiable identifiable) {\n\t\treturn setAllowDelete(removeSafely(getAllowDelete(), identifiable));\n\t}\n\t\n\tpublic static Set<OIdentifiable> addSafely(Set<OIdentifiable> set, OIdentifiable identifiable) {\n\t\tif(set==null) set = new HashSet<OIdentifiable>();\n\t\tset.add(identifiable);\n\t\treturn set;\n\t}\n\t\n\tpublic static Set<OIdentifiable> removeSafely(Set<OIdentifiable> set, OIdentifiable identifiable) {\n\t\tif(set==null) return set;\n\t\tset.remove(identifiable);\n\t\treturn set;\n\t}\n}",
"private Intent m34056c(Context context) {\n Intent intent = new Intent(\"miui.intent.action.APP_PERM_EDITOR\");\n intent.putExtra(\"extra_pkgname\", context.getPackageName());\n if (m34054a(context, intent)) {\n return intent;\n }\n intent.setClassName(\"com.miui.securitycenter\", \"com.miui.permcenter.permissions.AppPermissionsEditorActivity\");\n if (m34054a(context, intent)) {\n return intent;\n }\n return m34053a(context);\n }",
"public AccessibleRole getAccessibleRole()\n/* */ {\n/* 129 */ return AccessibleRole.PANEL;\n/* */ }",
"@Override\n protected String requiredPutPermission() {\n return \"admin\";\n }",
"protected void addEditMenuItems (JMenu edit)\n {\n }",
"@Override\n\tprotected void createEditPolicies() {\n\t\tinstallEditPolicy(EditPolicy.LAYOUT_ROLE, new NoRCEditLayoutPolicy());\n\t\tinstallEditPolicy(EditPolicy.COMPONENT_ROLE, new NoRCDeletePolicy());\n\t\tinstallEditPolicy(EditPolicy.SELECTION_FEEDBACK_ROLE, new NoRCEditCodePolicy());\n\t\tinstallEditPolicy(EditPolicy.GRAPHICAL_NODE_ROLE, new NoRCNodePolicy());\n\t}",
"public String edit() {\n return \"edit\";\n }",
"ReadOnlyMenuManager getMenuManager(int index);",
"public void doFolder_permissions(RunData data, Context context)\n\t{\n\t\tSessionState state = ((JetspeedRunData)data).getPortletSessionState(((JetspeedRunData)data).getJs_peid());\n\t\tParameterParser params = data.getParameters();\n\n\t\t// cancel copy if there is one in progress\n\t\tif(! Boolean.FALSE.toString().equals(state.getAttribute (STATE_COPY_FLAG)))\n\t\t{\n\t\t\tinitCopyContext(state);\n\t\t}\n\n\t\t// cancel move if there is one in progress\n\t\tif(! Boolean.FALSE.toString().equals(state.getAttribute (STATE_MOVE_FLAG)))\n\t\t{\n\t\t\tinitMoveContext(state);\n\t\t}\n\n\t\t// get the current collection id and the related site\n\t\tString collectionId = params.getString(\"collectionId\"); //(String) state.getAttribute (STATE_COLLECTION_ID);\n\t\tString title = \"\";\n\t\ttry\n\t\t{\n\t\t\ttitle = ContentHostingService.getProperties(collectionId).getProperty(ResourceProperties.PROP_DISPLAY_NAME);\n\t\t}\n\t\tcatch (PermissionException e)\n\t\t{\n\t\t\taddAlert(state, rb.getString(\"notread\"));\n\t\t}\n\t\tcatch (IdUnusedException e)\n\t\t{\n\t\t\taddAlert(state, rb.getString(\"notfindfol\"));\n\t\t}\n\n\t\t// the folder to edit\n\t\tReference ref = EntityManager.newReference(ContentHostingService.getReference(collectionId));\n\t\tstate.setAttribute(PermissionsHelper.TARGET_REF, ref.getReference());\n\n\t\t// use the folder's context (as a site) for roles\n\t\tString siteRef = SiteService.siteReference(ref.getContext());\n\t\tstate.setAttribute(PermissionsHelper.ROLES_REF, siteRef);\n\n\t\t// ... with this description\n\t\tstate.setAttribute(PermissionsHelper.DESCRIPTION, rb.getString(\"setpermis\") + \" \" + title);\n\n\t\t// ... showing only locks that are prpefixed with this\n\t\tstate.setAttribute(PermissionsHelper.PREFIX, \"content.\");\n\n\t\t// get into helper mode with this helper tool\n\t\tstartHelper(data.getRequest(), \"sakai.permissions.helper\");\n\n\t}",
"public String updatePrivilege() {\r\n\r\n String elementID = this.getParam(\"idElement\");\r\n // If need to add to update list.\r\n boolean needToAdd = false;\r\n\r\n String optin = this.getParam(\"optin\");\r\n String optout = this.getParam(\"optout\");\r\n String view = this.getParam(\"view\");\r\n String read = this.getParam(\"read\");\r\n String update = this.getParam(\"update\");\r\n String administrate = this.getParam(\"administrate\");\r\n\r\n Subject updateSubject = (Subject) this.getAddedItem(elementID);\r\n\r\n if (updateSubject == null) {\r\n updateSubject = (Subject) this.updatedGroups.get(elementID);\r\n if (updateSubject == null) {\r\n Subject aux = (Subject) this.getItem(elementID);\r\n if (aux.getValueFormCol(\"canOptin\") == null) {\r\n aux.addMappingFieldCol(\"canOptin\", ESCOConstantes.FALSE);\r\n }\r\n if (aux.getValueFormCol(\"canOptout\") == null) {\r\n aux.addMappingFieldCol(\"canOptout\", ESCOConstantes.FALSE);\r\n }\r\n updateSubject = (Subject) aux.clone();\r\n this.originalGroups.put(elementID, aux);\r\n needToAdd = true;\r\n }\r\n }\r\n\r\n GroupPrivilegeEnum theRight = updateSubject.getSubjectRight();\r\n\r\n if (theRight == null) {\r\n theRight = GroupPrivilegeEnum.NONE;\r\n }\r\n\r\n if (optin != null) {\r\n // OptIn is true\r\n if (optin.equals(ESCOConstantes.TRUE)) {\r\n // Adding the VIEW privilege\r\n if (theRight.eq(GroupPrivilegeEnum.NONE)) {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.VIEW);\r\n }\r\n }\r\n // Adding the OptIn\r\n updateSubject.addMappingFieldCol(\"canOptin\", Boolean.valueOf(optin.equals(ESCOConstantes.TRUE))\r\n .toString());\r\n }\r\n\r\n if (optout != null) {\r\n // OptOut is true\r\n if (optout.equals(ESCOConstantes.TRUE)) {\r\n // Adding the VIEW privilege\r\n if (theRight.eq(GroupPrivilegeEnum.NONE)) {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.VIEW);\r\n }\r\n }\r\n updateSubject.addMappingFieldCol(\"canOptout\", Boolean.valueOf(optout.equals(ESCOConstantes.TRUE))\r\n .toString());\r\n }\r\n\r\n if (view != null) {\r\n if (view.equals(ESCOConstantes.TRUE)) {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.VIEW);\r\n } else {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.NONE);\r\n updateSubject.setOptin(false);\r\n updateSubject.setOptout(false);\r\n }\r\n }\r\n if (read != null) {\r\n if (read.equals(ESCOConstantes.TRUE)) {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.READ);\r\n } else {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.VIEW);\r\n }\r\n }\r\n if (update != null) {\r\n if (update.equals(ESCOConstantes.TRUE)) {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.UPDATE);\r\n } else {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.READ);\r\n }\r\n }\r\n if (administrate != null) {\r\n if (administrate.equals(ESCOConstantes.TRUE)) {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.ADMIN);\r\n } else {\r\n updateSubject.setSubjectRight(GroupPrivilegeEnum.UPDATE);\r\n }\r\n }\r\n\r\n // Only one group in the list of group of the members class because\r\n // we add it to convert group to subject.\r\n if (needToAdd) {\r\n this.updatedGroups.put(elementID, updateSubject);\r\n } else {\r\n Sortable theOrignGroup = this.originalGroups.get(elementID);\r\n if (theOrignGroup != null) {\r\n if (theOrignGroup.getValueFormCol(ESCOConstantes.USER_RIGHT_VALUE).toUpperCase().equals(\r\n updateSubject.getValueFormCol(ESCOConstantes.USER_RIGHT_VALUE).toUpperCase())) {\r\n if (theOrignGroup.getValueFormCol(\"canOptin\").toUpperCase().equals(\r\n updateSubject.getValueFormCol(\"canOptin\").toUpperCase())) {\r\n if (theOrignGroup.getValueFormCol(\"canOptout\").toUpperCase().equals(\r\n updateSubject.getValueFormCol(\"canOptout\").toUpperCase())) {\r\n // The updateGroup and origin is same.\r\n this.updatedGroups.remove(elementID);\r\n this.originalGroups.remove(elementID);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n // Create and return the XML status.\r\n XmlProducer producer = new XmlProducer();\r\n producer.setTarget(new Status(Boolean.TRUE));\r\n producer.setTypesOfTarget(Status.class);\r\n\r\n return this.xmlProducerWrapper.wrap(producer);\r\n }",
"public abstract void edit();",
"protected boolean isEdit(){\n\t\treturn getArguments().getBoolean(ARG_KEY_IS_EDIT);\n\t}",
"@Override\n protected void createEditPolicies() {\n if (!getEditor().isReadOnly()) {\n if (isLayoutEnabled()) {\n if (getEditPolicy(EditPolicy.CONTAINER_ROLE) == null && isColumnDragAndDropSupported()) {\n installEditPolicy(EditPolicy.CONTAINER_ROLE, new AttributeConnectionEditPolicy(this));\n installEditPolicy(EditPolicy.PRIMARY_DRAG_ROLE, new AttributeDragAndDropEditPolicy(this));\n }\n }\n getDiagram().getModelAdapter().installPartEditPolicies(this);\n }\n }",
"private void setearOpcionesMenuAdministracion()\r\n\t{\r\n\t\tArrayList<FormularioVO> lstFormsMenuAdmin = new ArrayList<FormularioVO>();\r\n\t\t\r\n\t\t/*Buscamos los Formulairos correspondientes a este TAB*/\r\n\t\tfor (FormularioVO formularioVO : this.permisos.getLstPermisos().values()) {\r\n\t\t\t\r\n\t\t\tif(formularioVO.getCodigo().equals(VariablesPermisos.FORMULARIO_USUARIO)\r\n\t\t\t\t|| formularioVO.getCodigo().equals(VariablesPermisos.FORMULARIO_GRUPO))\r\n\t\t\t{\r\n\t\t\t\tlstFormsMenuAdmin.add(formularioVO);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t/*Si hay formularios para el tab*/\r\n\t\tif(lstFormsMenuAdmin.size()> 0)\r\n\t\t{\r\n\t\t\t//TODO\r\n\t\t\t//this.tabAdministracion = new VerticalLayout();\r\n\t\t\t//this.tabAdministracion.setMargin(true);\r\n\t\t\t\r\n\t\t\tthis.lbAdministracion.setVisible(true);\r\n\t\t\tthis.layoutMenu.addComponent(this.lbAdministracion);\r\n\t\t\t\r\n\t\t\tfor (FormularioVO formularioVO : lstFormsMenuAdmin) {\r\n\t\t\t\t\r\n\t\t\t\tswitch(formularioVO.getCodigo())\r\n\t\t\t\t{\r\n\t\t\t\t\tcase VariablesPermisos.FORMULARIO_USUARIO : \r\n\t\t\t\t\t\tif(this.permisos.permisoEnFormulaior(VariablesPermisos.FORMULARIO_USUARIO, VariablesPermisos.OPERACION_LEER)){\r\n\t\t\t\t\t\t\tthis.habilitarUserButton();\r\n\t\t\t\t\t\t\tthis.layoutMenu.addComponent(this.userButton);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\tcase VariablesPermisos.FORMULARIO_GRUPO :\r\n\t\t\t\t\t\tif(this.permisos.permisoEnFormulaior(VariablesPermisos.FORMULARIO_GRUPO, VariablesPermisos.OPERACION_LEER)){\r\n\t\t\t\t\t\t\tthis.habilitarGrupoButton();\r\n\t\t\t\t\t\t\tthis.layoutMenu.addComponent(this.gruposButton);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//TODO\r\n\t\t\t//this.acordion.addTab(tabAdministracion, \"Administración\", null);\r\n\t\t\t\r\n\t\t}\r\n\t\t//TODO\r\n\t\t//acordion.setHeight(\"75%\"); /*Seteamos alto del accordion*/\r\n\t}",
"public String getFloodPerm() throws PermissionDeniedException;",
"String getEditore();",
"public void doPermissions(RunData data, Context context)\n\t{\n\t\tSessionState state = ((JetspeedRunData)data).getPortletSessionState(((JetspeedRunData)data).getJs_peid());\n\n\t\t// cancel copy if there is one in progress\n\t\tif(! Boolean.FALSE.toString().equals(state.getAttribute (STATE_COPY_FLAG)))\n\t\t{\n\t\t\tinitCopyContext(state);\n\t\t}\n\n\t\t// cancel move if there is one in progress\n\t\tif(! Boolean.FALSE.toString().equals(state.getAttribute (STATE_MOVE_FLAG)))\n\t\t{\n\t\t\tinitMoveContext(state);\n\t\t}\n\n\t\t// should we save here?\n\t\tstate.setAttribute(STATE_LIST_SELECTIONS, new TreeSet());\n\n\t\t// get the current home collection id and the related site\n\t\tString collectionId = (String) state.getAttribute (STATE_HOME_COLLECTION_ID);\n\t\tReference ref = EntityManager.newReference(ContentHostingService.getReference(collectionId));\n\t\tString siteRef = SiteService.siteReference(ref.getContext());\n\n\t\t// setup for editing the permissions of the site for this tool, using the roles of this site, too\n\t\tstate.setAttribute(PermissionsHelper.TARGET_REF, siteRef);\n\n\t\t// ... with this description\n\t\tstate.setAttribute(PermissionsHelper.DESCRIPTION, rb.getString(\"setpermis1\")\n\t\t\t\t+ SiteService.getSiteDisplay(ref.getContext()));\n\n\t\t// ... showing only locks that are prpefixed with this\n\t\tstate.setAttribute(PermissionsHelper.PREFIX, \"content.\");\n\n\t\t// get into helper mode with this helper tool\n\t\tstartHelper(data.getRequest(), \"sakai.permissions.helper\");\n\n\t}",
"ISModifyRequiredRole createISModifyRequiredRole();",
"public int getAddEditMenuText();",
"public java.util.ArrayList getEditRoles() {\n\tjava.util.ArrayList roles = new java.util.ArrayList();\n\troles.add(\"ArendaMainEconomist\");\n\troles.add(\"ArendaEconomist\");\n\troles.add(\"administrator\");\n\treturn roles;\n}",
"public java.awt.Component getControlledUI() \r\n {\r\n return grantsByPIForm;\r\n }",
"public java.util.ArrayList getEditRoles() {\n\t\tjava.util.ArrayList roles = new java.util.ArrayList();\n\t\troles.add(\"ArendaMainEconomist\");\n\t\troles.add(\"ArendaEconomist\");\n\t\troles.add(\"administrator\");\n\t\treturn roles;\n\t}",
"public Enumeration permissions();",
"private PermissionHelper() {}",
"java.lang.String getAdmin();",
"public EditAccess() {\n initComponents();\n \n \n\n }",
"public int getUserModificationPermission() {\n return permission;\n }",
"int getPermissionRead();",
"int getPermissionWrite();",
"private void initAccess() {\n\t\tif (!Users.doesCurrentUserHaveAccess(Users.ACCESS_CLASS_BEGINNING_DATA_ENTRY) &&\n\t\t\t\t!this.getParentEditor().getNewRecord() &&\n\t\t\t\t!referenceNewPatron) {\n\t\t\treadOnly = true;\n\t\t\tsetFormToReadOnly();\n\t\t\t//research purpose\n\t\t\taddResearchPurpose.setEnabled(false);\n\t\t\tremoveResearchPurpose.setEnabled(false);\n\t\t\t//subject buttons\n\t\t\taddSubject.setEnabled(false);\n\t\t\tremoveSubject.setEnabled(false);\n\t\t\t//name buttons\n\t\t\taddName.setEnabled(false);\n\t\t\tremoveName.setEnabled(false);\n\t\t\teditNameRelationshipButton.setEnabled(false);\n // resource button\n addResourceButton.setEnabled(false);\n removeResourceButton.setEnabled(false);\n\t\t}\n\t}",
"@Override\n public boolean userCanAccess(int id) {\n return true;\n }",
"public String ojTreeNode_edit_ADMINEXERCISE_ADMINEXAM_ADMINCONTEST_ROLES() throws IOException\n\t{\n\t\tif (ojTreeNode==null)\n\t\t{// Create a new contest\n\t\t\tojTreeNode = new OjTreeNode();\n\t\t\tojTreeNode.setPid(new Long(-1));\n\t\t\tojTreeNode.setOrderNum(999);\n\t\t\tString pid = getRequest().getParameter(\"pid\");\n\t\t\tif (pid != null && !\"\".equals(pid))\n\t\t\t{\n\t\t\t\tojTreeNodeParent = ojTreeNodeManager.get(new Long(pid));\n\t\t\t\tif (ojTreeNodeParent != null)\n\t\t\t\t{\n\t\t\t\t\tojTreeNode.setPid(new Long(pid));\n\t\t\t\t\tojTreeNode.setOrderNum(ojTreeNodeManager\n\t\t\t\t\t\t\t.getOrderNumberOfNewChild(new Long(pid)));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn SUCCESS();\n\t}",
"String getPermission();",
"public void editOperation() {\n\t\t\r\n\t}",
"public java.util.ArrayList getEditRoles() {\n\tjava.util.ArrayList roles = new java.util.ArrayList();\n\troles.add(\"administrator\");\n\troles.add(\"StorageManager\");\n\treturn roles;\n}",
"public EditPolicy() {\r\n super();\r\n }",
"public interface EditableProvider {\n\n Module getRootModule();\n\n /**\n * @return the type of the specified editable object, or null if it is not an editable object.\n */\n Type getTypeOfObject(Object objectInstance);\n\n}",
"public ViewResumePage clickonedit() throws Exception{\r\n\t\t\ttry {\r\n\t\t\t\telement = driver.findElement(edit);\r\n\t\t\t\tflag = element.isDisplayed() && element.isEnabled();\r\n\t\t\t\tAssert.assertTrue(flag, \"Edit button is not displayed\");\r\n\t\t\t\telement.click();\r\n\t\t\t\tdriver.manage().timeouts().implicitlyWait(30, TimeUnit.SECONDS);\r\n\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tthrow new Exception(\"Edit Button NOT FOUND:: \"+e.getLocalizedMessage());\r\n\t\t\t}\r\n\t\t\treturn new ViewResumePage(driver);\r\n\t\t\r\n\t}",
"private void init() {\r\n\t\t// administration\r\n\t\taddPrivilege(CharsetAction.class, User.ROLE_ADMINISTRATOR);\r\n\t\taddPrivilege(LanguageAction.class, User.ROLE_ADMINISTRATOR);\r\n\t\t\r\n\t\t// dictionary management\r\n\t\taddPrivilege(AddApplicationAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(AddDictLanguageAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(AddLabelAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(ChangeApplicationVersionAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(ChangeDictVersionAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(CreateApplicationAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(CreateApplicationBaseAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(CreateOrAddApplicationAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(CreateProductAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(CreateProductReleaseAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(DeleteLabelAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(DeliverAppDictAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(DeliverDictAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(DeliverUpdateDictAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(DeliverUpdateDictLanguageAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(DeliverUpdateLabelAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(RemoveApplicationAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(RemoveApplicationBaseAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(RemoveDictAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(RemoveDictLanguageAction.class, User.ROLE_APPLICATION_OWNER);\r\n\t\taddPrivilege(RemoveProductAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(RemoveProductBaseAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(UpdateDictAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(UpdateDictLanguageAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(UpdateLabelAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(UpdateLabelStatusAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(ImportTranslationDetailsAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\r\n\t\taddPrivilege(UpdateLabelRefAndTranslationsAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(GlossaryAction.class, User.ROLE_ADMINISTRATOR);\r\n\r\n\r\n\t\t// translation management\r\n\t\taddPrivilege(UpdateStatusAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(UpdateTranslationAction.class, User.ROLE_APPLICATION_OWNER | User.ROLE_TRANSLATION_MANAGER);\r\n\t\t\r\n\t\t// task management\r\n\t\taddPrivilege(ApplyTaskAction.class, User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(CloseTaskAction.class, User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(CreateTaskAction.class, User.ROLE_TRANSLATION_MANAGER);\r\n\t\taddPrivilege(ReceiveTaskFilesAction.class, User.ROLE_TRANSLATION_MANAGER);\r\n\t}",
"Object getPerm(String name, Object def);",
"@Override\n\tpublic boolean canEdit(IAccounterServerCore clientObject,\n\t\t\tboolean goingToBeEdit) throws AccounterException {\n\t\treturn true;\n\t}",
"public int getEditAuthUserType() {\n return editAuthUserType;\n }",
"public static void main(String[] args) {\n\t\n\tAccesingModifiers.hello();//heryerden accessable \n\tAccesingModifiers.hello1();\n\tAccesingModifiers.hello2();\n\t\n\t//AccesingModifiers.hello3(); not acceptable since permission is set to private\n\t\n}",
"public org.tempuri.GetUserAccessRightResponseGetUserAccessRightResult getUserAccessRight(java.lang.String msg, java.lang.String systemCode, java.lang.String companyCode) throws java.rmi.RemoteException;",
"public SetPermission() {\n initComponents();\n }",
"@CoreFunction\npublic interface ProjectAuthorisationMgt extends ProjectView {\n}",
"private void openPermissions(){\n WebDriverHelper.clickElement(seePermissionLvlButton);\n }",
"public void addEditorRoleToIndividualAcl(Individual i);",
"public IPermissionOwner getPermissionOwner(String fname);",
"@Override\n\tpublic void setDefinitionWidgetReadOnly(boolean isEditable){\n\t\t\n\t\tgetDefineNameTxtArea().setEnabled(isEditable);\n\t\tgetDefineAceEditor().setReadOnly(!isEditable);\n\t\tgetContextDefinePATRadioBtn().setEnabled(isEditable);\n\t\tgetContextDefinePOPRadioBtn().setEnabled(isEditable);\n\t\tSystem.out.println(\"in setDefinitionWidgetReadOnly: setting Ace Editor read only flag. read only = \" + !isEditable);\n\t\tgetDefineButtonBar().getSaveButton().setEnabled(isEditable);\n\t\tgetDefineButtonBar().getDeleteButton().setEnabled(isEditable);\n\t\tgetDefineButtonBar().getInsertButton().setEnabled(isEditable);\n\t\tgetDefineButtonBar().getTimingExpButton().setEnabled(isEditable);\n\t}",
"public static void ShowAdminPreferences() {\n if (Controller.permission.GetUserPermission(\"EditUser\")) {\n ToggleVisibility(UsersPage.adminWindow);\n } else {\n DialogWindow.NoAccessTo(\"Admin options\");\n }\n }",
"public String getAccess();",
"@Test(groups = \"wso2.ds.dashboard\", description = \"test for editor role\", dependsOnMethods = \"testAddDashboardAndAssignRolesBySetting\")\n public void testForEditorRole()\n throws MalformedURLException, XPathExpressionException {\n String dashboardId = dashboardTitle.toLowerCase();\n redirectToLocation(DS_HOME_CONTEXT, DS_DASHBOARDS_CONTEXT);\n WebElement dashboard = getDriver().findElement(By.id(dashboardId));\n assertEquals(DASHBOARD_TITLE, dashboard.findElement(By.id(\"ues-dashboard-title\")).getText());\n assertEquals(DASHBOARD_DESCRIPTION, dashboard.findElement(By.id(\"ues-dashboard-description\")).getText());\n assertTrue(getDriver().isElementPresent(By.cssSelector(\"#\" + dashboardId + \" .ues-view\")),\n \"view element is present in the current UI\");\n assertTrue(getDriver().isElementPresent(By.cssSelector(\"#\" + dashboardId + \" .ues-edit\")),\n \"design element is present in the current UI\");\n assertTrue(getDriver().isElementPresent(By.cssSelector(\"#\" + dashboardId + \" .ues-settings\")),\n \"settings element is present in the current UI\");\n dashboard.findElement(By.id(dashboardId)).findElement(By.id(\"ues-view\")).click();\n // Switch the driver to the new window and click on the edit/personalize link\n pushWindow();\n String bodyText = getDriver().findElement(By.tagName(\"body\")).getText();\n assertTrue(bodyText.contains(USERNAME_EDITOR), \"Expected Username is not matched\");\n getDriver().findElement(By.linkText(USERNAME_EDITOR)).click();\n assertEquals(\"Edit\", getDriver().findElement(By.cssSelector(\"i.ues-copy\")).getAttribute(\"title\"),\n \"Unable to find the edit button\");\n getDriver().close();\n popWindow();\n logout();\n }",
"public void setFieldReadAccess() {\n\n\t\tif (!AccessManager.canReadSmsPredefiniDescription())\n\t\t\ttypeFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.canReadSmsPredefiniDescription())\n\t\t\tobjetFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.canReadSmsPredefiniDescription())\n\t\t\tmessageFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.isAdmin())\n\t\t\tdeletedEntityBoxFilterBox.setVisible(false);\n\t}",
"boolean isEdit();",
"public interface MainView extends BaseView {\n\n /**\n * 初始化权限\n */\n void initPermission();\n}",
"private void edit() {\n\n\t}",
"public static View getPermissionItemView(Context context,\n CharSequence grpName, CharSequence description, boolean dangerous) {\n LayoutInflater inflater = (LayoutInflater)context.getSystemService(\n Context.LAYOUT_INFLATER_SERVICE);\n Drawable icon = context.getDrawable(dangerous\n ? R.drawable.ic_bullet_key_permission : R.drawable.ic_text_dot);\n return getPermissionItemViewOld(context, inflater, grpName,\n description, dangerous, icon);\n }",
"private void checkRights() {\n image.setEnabled(true);\n String user = fc.window.getUserName();\n \n for(IDataObject object : objects){\n ArrayList<IRights> rights = object.getRights();\n \n if(rights != null){\n boolean everybodyperm = false;\n \n for(IRights right : rights){\n String name = right.getName();\n \n //user found, therefore no other check necessary.\n if(name.equals(user)){\n if(!right.getOwner()){\n image.setEnabled(false);\n }else{\n image.setEnabled(true);\n }\n return;\n //if no user found, use everybody\n }else if(name.equals(BUNDLE.getString(\"Everybody\"))){\n everybodyperm = right.getOwner();\n }\n }\n image.setEnabled(everybodyperm);\n if(!everybodyperm){\n return;\n }\n }\n }\n }",
"private void getEditLinkPanel() {\n\t\ttry{\n\t\t\tEditLinkPanel editLinkPanel = new EditLinkPanel(newsItem, feedNewsPresenter);\n\t\t\toptionPanel.add(editLinkPanel);\n\t\t}catch(Exception e){\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t}",
"private void checkAdminOrModerator(HttpServletRequest request, String uri)\n throws ForbiddenAccessException, ResourceNotFoundException {\n if (isAdministrator(request)) {\n return;\n }\n\n ModeratedItem moderatedItem = getModeratedItem(uri);\n if (moderatedItem == null) {\n throw new ResourceNotFoundException(uri);\n }\n\n String loggedInUser = getLoggedInUserEmail(request);\n if (moderatedItem.isModerator(loggedInUser)) {\n return;\n }\n\n throw new ForbiddenAccessException(loggedInUser);\n }",
"protected void createEditPolicies() {\n installEditPolicy(EditPolicy.COMPONENT_ROLE, new RootComponentEditPolicy());\r\n // handles constraint changes (e.g. moving and/or resizing) of model elements\r\n // and creation of new model elements\r\n installEditPolicy(EditPolicy.LAYOUT_ROLE, new ShapesXYLayoutEditPolicy(this));\r\n installEditPolicy(EditPolicy.SELECTION_FEEDBACK_ROLE, null);\r\n }",
"public void edit() throws Exception {\n\t\topenPrimaryButtonDropdown();\n\t\tgetControl(\"editButton\").click();\n\t}",
"ISModifyComponent createISModifyComponent();",
"public CtrlEditGrupos() {\n edEsc = EditEscenario.getInstance();\n try {\n cd = CtrlDomain.getInstance();\n } catch (Exception e) {\n System.out.println(\"ERROR EN LA CARGA DEL CONTROLADOR DE DOMINIO\");\n }\n planEstudiosFinal = edEsc.getPlanEstudiosFinal();\n asignaturasFinal = edEsc.getAsignaturasFinal();\n restriccionesFinal = edEsc.getRestriccionesFinal();\n }",
"public OpenEditPolicy createOpenEditPolicy(final String viewID) {\n\t\treturn new OpenEditPolicy() {\n\t\t\t@Override\n\t\t\tprotected Command getOpenCommand(Request request) {\n\t\t\t\t// fjcano :: if the hosting figure has any diagram\n\t\t\t\t// associated, open one of them\n\t\t\t\tDiagram diagramToOpen = getDiagramToOpen();\n\t\t\t\tif (diagramToOpen != null) {\n\t\t\t\t\treturn new OpenDiagramCommand(diagramToOpen).toGEFCommand();\n\t\t\t\t}\n\t\t\t\t// fjcano :: if no diagram is available to open, check if a\n\t\t\t\t// new one can be created\n\t\t\t\tString diagramToCreate = getDiagramKindToCreate();\n\t\t\t\tif (diagramToCreate != null) {\n\t\t\t\t\tIGraphicalEditPart host = MDTUtil\n\t\t\t\t\t\t\t.getHostGraphicalEditPart(this);\n\t\t\t\t\treturn new OpenAsDiagramCommand(getGMFREsource(host), host\n\t\t\t\t\t\t\t.resolveSemanticElement(), diagramToCreate)\n\t\t\t\t\t\t\t.toGEFCommand();\n\t\t\t\t}\n\t\t\t\t// fjcano :: by default, open the properties view\n\t\t\t\tTransactionalEditingDomain domain = getEditingDomain();\n\t\t\t\tif (domain != null) {\n\t\t\t\t\treturn (new OpenViewCommand(domain, viewID)).toGEFCommand();\n\t\t\t\t}\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tprotected Resource getGMFREsource(IGraphicalEditPart editPart) {\n\t\t\t\tif (editPart != null) {\n\t\t\t\t\treturn editPart.getNotationView().eResource();\n\t\t\t\t}\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\t/**\n\t\t\t * Return true if an associated diagram was opened.\n\t\t\t * \n\t\t\t * @return\n\t\t\t */\n\t\t\tprotected Diagram getDiagramToOpen() {\n\t\t\t\tIGraphicalEditPart grahicalHostEditPart = (IGraphicalEditPart) getHost();\n\t\t\t\tEObject element = grahicalHostEditPart.resolveSemanticElement();\n\t\t\t\tList<Diagram> diagramL = MultiDiagramUtil\n\t\t\t\t\t\t.getDiagramsAssociatedToElement(element);\n\n\t\t\t\tif (diagramL.isEmpty()) {\n\t\t\t\t\treturn null;\n\t\t\t\t} else if (diagramL.size() == 1) {\n\t\t\t\t\treturn diagramL.get(0);\n\t\t\t\t}\n\n\t\t\t\tElementListSelectionDialog dialog = new ElementListSelectionDialog(\n\t\t\t\t\t\tPlatformUI.getWorkbench().getActiveWorkbenchWindow()\n\t\t\t\t\t\t\t\t.getShell(), new GeneralLabelProvider());\n\t\t\t\tdialog.setMessage(\"Select the diagram to be opened\");\n\t\t\t\tdialog.setTitle(\"Diagram selection\");\n\t\t\t\tdialog.setElements(diagramL.toArray());\n\t\t\t\tif (dialog.open() == Dialog.OK) {\n\t\t\t\t\treturn (Diagram) dialog.getFirstResult();\n\t\t\t\t}\n\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tprotected String getDiagramKindToCreate() {\n\t\t\t\tIGraphicalEditPart grahicalHostEditPart = (IGraphicalEditPart) getHost();\n\t\t\t\tList<String> diagramL = EClassToDiagramRegistry.getInstance()\n\t\t\t\t\t\t.getDiagramsForEditPart(grahicalHostEditPart);\n\n\t\t\t\tif (diagramL.isEmpty()) {\n\t\t\t\t\treturn null;\n\t\t\t\t} else if (diagramL.size() == 1) {\n\t\t\t\t\treturn diagramL.get(0);\n\t\t\t\t}\n\n\t\t\t\tElementListSelectionDialog dialog = new ElementListSelectionDialog(\n\t\t\t\t\t\tPlatformUI.getWorkbench().getActiveWorkbenchWindow()\n\t\t\t\t\t\t\t\t.getShell(), new GeneralLabelProvider());\n\t\t\t\tdialog.setMessage(\"Select the diagram to be created\");\n\t\t\t\tdialog.setTitle(\"Diagram selection\");\n\t\t\t\tdialog.setElements(diagramL.toArray());\n\t\t\t\tif (dialog.open() == Dialog.OK) {\n\t\t\t\t\treturn (String) dialog.getFirstResult();\n\t\t\t\t}\n\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tprotected TransactionalEditingDomain getEditingDomain() {\n\t\t\t\tif (getHost() instanceof IGraphicalEditPart) {\n\t\t\t\t\treturn ((IGraphicalEditPart) getHost()).getEditingDomain();\n\t\t\t\t}\n\t\t\t\treturn null;\n\t\t\t}\n\t\t};\n\n\t}",
"public String paginaEditCliente(){\n\t\t\r\n\t\treturn \"editcli\";\r\n\t}",
"public static com.tangosol.coherence.Component get_Instance()\n {\n return new com.tangosol.coherence.component.net.Security.CheckPermissionAction();\n }",
"public interface AccessControlListModalWidget extends IsWidget {\n /**\n * Show the sharing dialog.\n *\n * @param changeCallback\n */\n public void showSharing(Callback changeCallback);\n\n /**\n * The widget must be configured before showing the dialog.\n *\n * @param entity\n * @param canChangePermission\n */\n public void configure(Entity entity, boolean canChangePermission);\n}",
"UserEditForm getEditForm(User user);",
"public void permission_check() {\n //Usage Permission\n if (!isAccessGranted()) {\n new LovelyStandardDialog(MainActivity.this)\n .setTopColorRes(R.color.colorPrimaryDark)\n .setIcon(R.drawable.ic_perm_device_information_white_48dp)\n .setTitle(getString(R.string.permission_check_title))\n .setMessage(getString(R.string.permission_check_message))\n .setPositiveButton(android.R.string.ok, new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n Intent intent = new Intent(android.provider.Settings.ACTION_USAGE_ACCESS_SETTINGS);\n startActivity(intent);\n }\n })\n .setNegativeButton(android.R.string.no, null)\n .show();\n }\n }",
"public void setFieldReadAccess() {\n\n\t\tif (!AccessManager.canReadPersonnelIdentification())\n\t\t\tpersonnel_nomFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.canReadCentreDiagTraitDescription())\n\t\t\tcdt_nomFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.canReadCandidatureFormationRegionApprobation())\n\t\t\tapprouveeRegionFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.canReadCandidatureFormationGtcApprobation())\n\t\t\tapprouveeGTCFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.canReadDistrictSanteDescription())\n\t\t\tdistrictsante_nomFilterBox.setVisible(false);\n\n\t\tif (!AccessManager.isAdmin())\n\t\t\tdeletedEntityBoxFilterBox.setVisible(false);\n\t}",
"protected void initializeEditMenu() {\n\t\tfinal JMenu editMenu = new JMenu(\"Edit\");\n\t\tthis.add(editMenu);\n\t\t// History Mouse Mode\n\t\tfinal JMenu mouseModeSubMenu = new JMenu(\"History Mouse Mode\");\n\t\teditMenu.add(mouseModeSubMenu);\n\t\t// Transforming\n\t\tfinal JMenuItem transformingItem = new JMenuItem(\n\t\t\t\tthis.commands.findById(\"GUICmdGraphMouseMode.Transforming\"));\n\t\ttransformingItem.setAccelerator(KeyStroke.getKeyStroke('T',\n\t\t\t\tInputEvent.ALT_DOWN_MASK));\n\t\tmouseModeSubMenu.add(transformingItem);\n\t\t// Picking\n\t\tfinal JMenuItem pickingItem = new JMenuItem(\n\t\t\t\tthis.commands.findById(\"GUICmdGraphMouseMode.Picking\"));\n\t\tpickingItem.setAccelerator(KeyStroke.getKeyStroke('P',\n\t\t\t\tInputEvent.ALT_DOWN_MASK));\n\t\tmouseModeSubMenu.add(pickingItem);\n\t}",
"private void performDirectEdit() {\n\t}",
"private ActionForward showRights(ActionMapping mapping, ActionForm aform,\n HttpServletRequest request, HttpServletResponse response) throws Exception {\n String jpql = \" FROM TRight t\";\n pagination = new Pagination(request, response);\n\n pagination.setRecordCount(jpaDaoService.getEntityCount(\"SELECT count(t) \"+jpql, null));\n List rightlist=jpaDaoService.findEntities(\"SELECT t \"+jpql, null, false, pagination.getFirstResult(), pagination.getPageSize());\n\n request.setAttribute(\"rightlist\", rightlist);\n request.setAttribute(\"pagination\", pagination.toString());\n\n return mapping.findForward(SUCCESS);\n }",
"starnamed.x.wasm.v1beta1.Types.AccessConfig getInstantiatePermission();",
"String getAccess();",
"String getAccess();",
"public AccessibleRole getAccessibleRole() {\n/* 1492 */ return AccessibleRole.SCROLL_PANE;\n/* */ }",
"protected void doGetPermissions() throws TmplException {\r\n try {\r\n GlbPerm perm = (GlbPerm)TmplEJBLocater.getInstance().getEJBRemote(\"pt.inescporto.permissions.ejb.session.GlbPerm\");\r\n\r\n perms = perm.getFormPerms(MenuSingleton.getRole(), permFormId);\r\n }\r\n catch (java.rmi.RemoteException rex) {\r\n //can't get form perms\r\n TmplException tmplex = new TmplException(TmplMessages.NOT_DEFINED);\r\n tmplex.setDetail(rex);\r\n throw tmplex;\r\n }\r\n catch (javax.naming.NamingException nex) {\r\n //can't find GlbPerm\r\n TmplException tmplex = new TmplException(TmplMessages.NOT_DEFINED);\r\n tmplex.setDetail(nex);\r\n throw tmplex;\r\n }\r\n }",
"ISModifyProvidedRole createISModifyProvidedRole();",
"public abstract void checkEditing();",
"public AccessibleContext getAccessibleContext()\n/* */ {\n/* 207 */ if (this.accessibleContext == null) {\n/* 208 */ this.accessibleContext = new AccessibleAWTPopupMenu();\n/* */ }\n/* 210 */ return this.accessibleContext;\n/* */ }",
"@Override\n\tpublic void apply( final ApplyFn fn ) throws AccessDeniedException;"
] | [
"0.6503615",
"0.6368486",
"0.6114197",
"0.60719365",
"0.58714104",
"0.5753129",
"0.571736",
"0.571371",
"0.5675559",
"0.5674618",
"0.5668686",
"0.56318367",
"0.56135386",
"0.5603282",
"0.5603138",
"0.5571924",
"0.5531266",
"0.5498105",
"0.54822934",
"0.54801923",
"0.54544586",
"0.5442044",
"0.5438744",
"0.54331064",
"0.54324335",
"0.5427351",
"0.54197615",
"0.54185545",
"0.5391679",
"0.5367496",
"0.5327934",
"0.5312216",
"0.5310149",
"0.5309203",
"0.5302704",
"0.5300167",
"0.52940017",
"0.52909905",
"0.5287208",
"0.52734476",
"0.5271809",
"0.5261438",
"0.5256239",
"0.52493185",
"0.52468234",
"0.5244996",
"0.5237269",
"0.52365965",
"0.52354825",
"0.5232325",
"0.52301836",
"0.52273697",
"0.5227139",
"0.5223664",
"0.5223629",
"0.52211165",
"0.52201986",
"0.5212644",
"0.52033687",
"0.52003527",
"0.51862425",
"0.5172545",
"0.5172398",
"0.51593226",
"0.51347435",
"0.5133541",
"0.5132698",
"0.5129695",
"0.5126599",
"0.5120755",
"0.5116282",
"0.5110239",
"0.51082325",
"0.5107604",
"0.5102735",
"0.5100576",
"0.50956124",
"0.50946355",
"0.5092325",
"0.5089314",
"0.508391",
"0.5081791",
"0.5080191",
"0.5077578",
"0.507456",
"0.50697714",
"0.5069754",
"0.5066728",
"0.5057933",
"0.5053667",
"0.505331",
"0.50507075",
"0.50472283",
"0.50472283",
"0.50470865",
"0.50469",
"0.50463516",
"0.5046265",
"0.5045308",
"0.5043498"
] | 0.7521454 | 0 |
check if access rights can be edited on the Object. I.e. if a AccessRightsSubModul can be obtained | public abstract boolean canEditAccessRights(OwObject object_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean checkAccess(HasUuid object) {\n // Allow newly-instantiated objects\n if (!wasResolved(object)) {\n return true;\n }\n // Allow anything when there are no roles in use\n if (getRoles().isEmpty()) {\n return true;\n }\n Principal principal = getPrincipal();\n // Check for superusers\n if (!principalMapper.isAccessEnforced(principal, object)) {\n return true;\n }\n\n List<PropertyPath> paths = typeContext.getPrincipalPaths(object.getClass());\n PropertyPathChecker checker = checkers.get();\n for (PropertyPath path : paths) {\n path.evaluate(object, checker);\n if (checker.getResult()) {\n return true;\n }\n }\n addWarning(object, \"User %s does not have permission to edit this %s\", principal,\n typeContext.getPayloadName(object.getClass()));\n return false;\n }",
"public abstract OwUIAccessRightsModul getEditAccessRightsSubModul(OwObject object_p) throws Exception;",
"boolean isAccessible(Object dbobject, int rights) throws HsqlException {\n\n /*\n * The deep recusion is all done in getAllRoles(). This method\n * only recurses one level into isDirectlyAccessible().\n */\n if (isDirectlyAccessible(dbobject, rights)) {\n return true;\n }\n\n if (pubGrantee != null && pubGrantee.isAccessible(dbobject, rights)) {\n return true;\n }\n\n RoleManager rm = getRoleManager();\n Iterator it = getAllRoles().iterator();\n\n while (it.hasNext()) {\n if (((Grantee) rm.getGrantee(\n (String) it.next())).isDirectlyAccessible(\n dbobject, rights)) {\n return true;\n }\n }\n\n return false;\n }",
"void check(Object dbobject, int rights) throws HsqlException {\n Trace.check(isAccessible(dbobject, rights), Trace.ACCESS_IS_DENIED);\n }",
"private void checkRights() {\n image.setEnabled(true);\n String user = fc.window.getUserName();\n \n for(IDataObject object : objects){\n ArrayList<IRights> rights = object.getRights();\n \n if(rights != null){\n boolean everybodyperm = false;\n \n for(IRights right : rights){\n String name = right.getName();\n \n //user found, therefore no other check necessary.\n if(name.equals(user)){\n if(!right.getOwner()){\n image.setEnabled(false);\n }else{\n image.setEnabled(true);\n }\n return;\n //if no user found, use everybody\n }else if(name.equals(BUNDLE.getString(\"Everybody\"))){\n everybodyperm = right.getOwner();\n }\n }\n image.setEnabled(everybodyperm);\n if(!everybodyperm){\n return;\n }\n }\n }\n }",
"boolean isDirectlyAccessible(Object dbobject,\n int rights) throws HsqlException {\n\n if (isAdministrator) {\n return true;\n }\n\n if (dbobject instanceof String) {\n if (((String) dbobject).startsWith(\"org.hsqldb.Library\")\n || ((String) dbobject).startsWith(\"java.lang.Math\")) {\n return true;\n }\n }\n\n int n = rightsMap.get(dbobject, 0);\n\n if (n != 0) {\n return (n & rights) != 0;\n }\n\n return false;\n }",
"@objid (\"41b411f8-e0e5-49a4-a7fc-7eed29779401\")\n @Override\n public boolean canExecute() {\n if (!MTools.getAuthTool().canModify(this.layer.getRelatedElement())) {\n return false;\n }\n return true;\n }",
"@Override\n\tpublic boolean canEdit(IAccounterServerCore clientObject,\n\t\t\tboolean goingToBeEdit) throws AccounterException {\n\t\treturn true;\n\t}",
"public boolean canEditLevel(Division division) {\n return divisionRepository.countDivisionsWithParent(division) == 0;\n }",
"public boolean isUpdateRight() {\r\n if (getUser() != null) {\r\n return getUser().hasPermission(\"/vocabularies\", \"u\");\r\n }\r\n return false;\r\n }",
"boolean isWriteAccess();",
"boolean hasSetAcl();",
"public Boolean getCanEdit() {\r\n return getAttributeAsBoolean(\"canEdit\");\r\n }",
"boolean isReadAccess();",
"private boolean validateAccess(String permission) {\n\t\tif (\"READ\".equalsIgnoreCase(permission)) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"boolean isHasPermissions();",
"boolean isReadOnly();",
"boolean isReadOnly();",
"public static void checkAccess() throws SecurityException {\n if(isSystemThread.get()) {\n return;\n }\n //TODO: Add Admin Checking Code\n// if(getCurrentUser() != null && getCurrentUser().isAdmin()) {\n// return;\n// }\n throw new SecurityException(\"Invalid Permissions\");\n }",
"public boolean canEditAllRequiredFields() throws OculusException;",
"public boolean hasAccess(String accessId);",
"public boolean canReadWriteOnMyLatestView()\n {\n \t \treturn getAccessBit(2);\n }",
"@Override\n public boolean canEdit(Context context, Item item) throws java.sql.SQLException\n {\n // can this person write to the item?\n return authorizeService.authorizeActionBoolean(context, item, Constants.WRITE, true);\n }",
"@Override\n public boolean userCanAccess(int id) {\n return true;\n }",
"boolean isAccessible(Object dbobject) throws HsqlException {\n return isAccessible(dbobject, GranteeManager.ALL);\n }",
"boolean isWritePermissionGranted();",
"public boolean isSetAccession()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().count_elements(ACCESSION$2) != 0;\r\n }\r\n }",
"public boolean isWriteable();",
"public boolean canEdit() {\r\n\t\treturn !dslView.isContainsErrors();\r\n\t}",
"@Override\r\n\tpublic boolean canModify(Object arg0, String arg1) {\n\t\treturn true;\r\n\t}",
"public boolean canEdit() throws GTClientException\n {\n return isNewEntity();\n }",
"public static boolean isControlled(Object object)\n {\n if (!(object instanceof EObject)) return false;\n EObject eObject = (EObject)object;\n EObject container = eObject.eContainer();\n Resource resource = eObject.eResource();\n return resource != null && container != null && resource != container.eResource();\n }",
"private void checkPermission(User user, List sourceList, List targetList)\n throws AccessDeniedException\n {\n logger.debug(\"+\");\n if (isMove) {\n if (!SecurityGuard.canManage(user, sourceList.getContainerId()) ||\n !SecurityGuard.canContribute(user, targetList.getContainerId()))\n throw new AccessDeniedException(\"Forbidden\");\n }\n else {\n if (!SecurityGuard.canView(user, sourceList.getContainerId()) ||\n !SecurityGuard.canContribute(user, targetList.getContainerId()))\n throw new AccessDeniedException(\"Forbidden\");\n }\n logger.debug(\"-\");\n }",
"public boolean isReadOnly();",
"public boolean isReadOnly();",
"public boolean isReadOnly();",
"public AccessRights getAccessRights() {\r\n\t\treturn accessRights;\r\n\t}",
"public void checkPrivileges() {\n\t\tPrivileges privileges = this.mySession.getPrivileges();\n\t}",
"protected boolean checkVisiblePermission() {\r\n ClientSecurityManager manager = ApplicationManager.getClientSecurityManager();\r\n if (manager != null) {\r\n if (this.visiblePermission == null) {\r\n if ((this.buttonKey != null) && (this.parentForm != null)) {\r\n this.visiblePermission = new FormPermission(this.parentForm.getArchiveName(), \"visible\",\r\n this.buttonKey, true);\r\n }\r\n }\r\n try {\r\n // Checks to show\r\n if (this.visiblePermission != null) {\r\n manager.checkPermission(this.visiblePermission);\r\n }\r\n this.restricted = false;\r\n return true;\r\n } catch (Exception e) {\r\n this.restricted = true;\r\n if (e instanceof NullPointerException) {\r\n ToggleButton.logger.error(null, e);\r\n }\r\n if (ApplicationManager.DEBUG_SECURITY) {\r\n ToggleButton.logger.debug(this.getClass().toString() + \": \" + e.getMessage(), e);\r\n }\r\n return false;\r\n }\r\n } else {\r\n return true;\r\n }\r\n }",
"public interface AccessManager {\n\n /**\n * predefined action constants\n */\n public String READ_ACTION = javax.jcr.Session.ACTION_READ;\n public String REMOVE_ACTION = javax.jcr.Session.ACTION_REMOVE;\n public String ADD_NODE_ACTION = javax.jcr.Session.ACTION_ADD_NODE;\n public String SET_PROPERTY_ACTION = javax.jcr.Session.ACTION_SET_PROPERTY;\n\n public String[] READ = new String[] {READ_ACTION};\n public String[] REMOVE = new String[] {REMOVE_ACTION};\n\n /**\n * Determines whether the specified <code>permissions</code> are granted\n * on the item with the specified path.\n *\n * @param parentState The node state of the next existing ancestor.\n * @param relPath The relative path pointing to the non-existing target item.\n * @param actions An array of actions that need to be checked.\n * @return <code>true</code> if the actions are granted; otherwise <code>false</code>\n * @throws ItemNotFoundException if the target item does not exist\n * @throws RepositoryException if another error occurs\n */\n boolean isGranted(NodeState parentState, Path relPath, String[] actions) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Determines whether the specified <code>permissions</code> are granted\n * on the item with the specified path.\n *\n * @param itemState\n * @param actions An array of actions that need to be checked.\n * @return <code>true</code> if the actions are granted; otherwise <code>false</code>\n * @throws ItemNotFoundException if the target item does not exist\n * @throws RepositoryException if another error occurs\n */\n boolean isGranted(ItemState itemState, String[] actions) throws ItemNotFoundException, RepositoryException;\n\n\n /**\n * Returns true if the existing item with the given <code>ItemId</code> can\n * be read.\n *\n * @param itemState\n * @return\n * @throws ItemNotFoundException\n * @throws RepositoryException\n */\n boolean canRead(ItemState itemState) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Returns true if the existing item state can be removed.\n *\n * @param itemState\n * @return\n * @throws ItemNotFoundException\n * @throws RepositoryException\n */\n boolean canRemove(ItemState itemState) throws ItemNotFoundException, RepositoryException;\n\n /**\n * Determines whether the subject of the current context is granted access\n * to the given workspace.\n *\n * @param workspaceName name of workspace\n * @return <code>true</code> if the subject of the current context is\n * granted access to the given workspace; otherwise <code>false</code>.\n * @throws NoSuchWorkspaceException if a workspace with the given name does not exist.\n * @throws RepositoryException if another error occurs\n */\n boolean canAccess(String workspaceName) throws NoSuchWorkspaceException, RepositoryException;\n}",
"public boolean isAccessLevelPrivate() {\r\n String level = getOption(OPTION_ACCESS_LEVEL, ACCESS_LEVEL_PUBLIC);\r\n return ACCESS_LEVEL_PRIVATE.equals(level);\r\n }",
"@Override\n protected boolean isAuthorized(PipelineData pipelineData) throws Exception\n {\n \t// use data.getACL() \n \treturn true;\n }",
"public boolean accesspermission()\n {\n AppOpsManager appOps = (AppOpsManager) context.getSystemService(Context.APP_OPS_SERVICE);\n int mode = 0;\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {\n mode = appOps.checkOpNoThrow(AppOpsManager.OPSTR_GET_USAGE_STATS,\n Process.myUid(),context.getPackageName());\n }\n if (mode == AppOpsManager.MODE_ALLOWED) {\n\n return true;\n }\n return false;\n\n }",
"public boolean isAccessGranted() {\n try {\n PackageManager packageManager = getPackageManager();\n ApplicationInfo applicationInfo = packageManager.getApplicationInfo(getPackageName(), 0);\n AppOpsManager appOpsManager = (AppOpsManager) getSystemService(Context.APP_OPS_SERVICE);\n int mode;\n assert appOpsManager != null;\n mode = appOpsManager.checkOpNoThrow(AppOpsManager.OPSTR_GET_USAGE_STATS,\n applicationInfo.uid, applicationInfo.packageName);\n return (mode == AppOpsManager.MODE_ALLOWED);\n\n } catch (PackageManager.NameNotFoundException e) {\n return false;\n }\n }",
"boolean isExecuteAccess();",
"@Override\n\tprotected boolean isAccessAllowed(ServletRequest request, ServletResponse response, Object mappedValue)\n\t\t\tthrows Exception {\n\t\treturn false;\n\t}",
"public static boolean canAccessFieldsDirectly(){\n return false; //TODO codavaj!!\n }",
"private boolean permisos() {\n for(String permission : PERMISSION_REQUIRED) {\n if(ContextCompat.checkSelfPermission(getContext(), permission) != PackageManager.PERMISSION_GRANTED) {\n return false;\n }\n }\n return true;\n }",
"public boolean isViewable()\n {\n return this.isEditable() || this.viewable;\n }",
"@Test\n\tpublic void testUpdateActionIsPerformedWhenPermissionInheritedAndUserAuthenticatedAndAllowed()\n\t\t\tthrows Throwable {\n\t\tcheck(getAllowedUser(), HttpStatus.SC_OK);\n\t}",
"private void checkAdminOrModerator(HttpServletRequest request, String uri)\n throws ForbiddenAccessException, ResourceNotFoundException {\n if (isAdministrator(request)) {\n return;\n }\n\n ModeratedItem moderatedItem = getModeratedItem(uri);\n if (moderatedItem == null) {\n throw new ResourceNotFoundException(uri);\n }\n\n String loggedInUser = getLoggedInUserEmail(request);\n if (moderatedItem.isModerator(loggedInUser)) {\n return;\n }\n\n throw new ForbiddenAccessException(loggedInUser);\n }",
"public abstract boolean isRestricted();",
"public boolean hasReadAccessRight(String srname)\n {\n DataSource dataSource =null;\n\t\tboolean found=false;\n\n if(groupListHasReadAccessRight(srname)==true)\n {\n found=true; \n }\n else\n {\n found = DataSourceListHasReadAccessRight(srname);\n }\n\n\t\treturn found || ! DataSource.isVSManaged(srname);\n\t}",
"public boolean checkAccess(String s, String op, String obj){\n\t\t\n\t\t/*Integer object = values.get(5).get(obj);\n\t\tInteger operation = values.get(3).get(op);\n\t\tInteger session = values.get(4).get(s);*/\n\t\t\n\t\tHashMap<Integer,Integer> elements = new HashMap<Integer,Integer>();\n\t\telements.put(5, values.get(5).get(obj));\n\t\telements.put(3,values.get(3).get(op));\n\t\telements.put(4, values.get(4).get(s));\n\t\t\n\t\tif (authGraph.dfsWalkEdges(authGraph.getRoot(), elements)) return true;\n\t\telse return false;\n\t\t\n\t\t//CHECK ACCESS MUST HANDLE THE INHERITANCE PROPERLY.........\n\t\t//MEANING IF THERE IS A SPECIAL EDGE BETWEEN TWO ROLES THEN PASS IT WITHOUT CONSUMING THE PATH VALUES....\n\t}",
"public boolean canRead(Transaction.TransactionType t, Operation o) {\n if (!isActive || !variables.containsKey(o.getVariableId())) {\n return false;\n }\n if (!variables.get(o.getVariableId()).isReadable()) {\n return false;\n }\n if (Transaction.TransactionType.READ_WRITE.equals(t)) {\n return lockManagers.get(o.getVariableId()).canAcquireLock(o.getType(), o.getTransactionId());\n }\n return true;\n }",
"public boolean checkAccess(final Instance _instance, \n final AccessType _accessType) \n throws EFapsException {\n boolean bHasAccess = false;\n Context context = Context.getThreadContext();\n\n // create\n if (\"create\".equals(_accessType.getName()) || \"show\".equals(_accessType.getName()) || \"read\".equals(_accessType.getName()))\n {\n bHasAccess = true;\n }\n\n // delete\n if (!bHasAccess && \"delete\".equals(_accessType.getName()))\n {\n bHasAccess = isSubscriber(context, String.valueOf(_instance.getId()));\n }\n\n return bHasAccess;\n }",
"public abstract boolean isReadOnly();",
"void check(Permission permission, DBObject dBObject) throws T2DBException;",
"public boolean canReadAndWrite() {\n\t\t//We can read and write in any state that we can read.\n\t\treturn canWrite();\n\t}",
"public boolean isWritable() {\n return accessControl != null && accessControl.getOpenStatus().isOpen() && !sandboxed;\n }",
"public final boolean needsPermission() {\n return FileUtil.needsPermission(this.form, this.resolvedPath);\n }",
"private boolean checkReadWritePermission() {\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n if (checkSelfPermission(Manifest.permission.READ_EXTERNAL_STORAGE) == PackageManager.PERMISSION_GRANTED\n && checkSelfPermission(Manifest.permission.WRITE_EXTERNAL_STORAGE) == PackageManager.PERMISSION_GRANTED) {\n return true;\n } else {\n ActivityCompat.requestPermissions(PanAadharResultActivity.this, new String[]{Manifest.permission.READ_EXTERNAL_STORAGE, Manifest.permission.WRITE_EXTERNAL_STORAGE}, 111);\n return false;\n }\n }\n\n return false;\n }",
"public boolean isModifiable() {\n return modifiable.get();\n }",
"private boolean checkCanModifyStatus() {\r\n \r\n RequesterBean requesterBean = new RequesterBean();\r\n ResponderBean responderBean = new ResponderBean();\r\n try{\r\n requesterBean.setFunctionType('c');\r\n String connectTo = CoeusGuiConstants.CONNECTION_URL + \"/rolMntServlet\";\r\n AppletServletCommunicator ascomm = new AppletServletCommunicator(connectTo,requesterBean);\r\n ascomm.setRequest(requesterBean);\r\n ascomm.send();\r\n responderBean = ascomm.getResponse(); \r\n \r\n }catch(Exception e) {\r\n CoeusOptionPane.showErrorDialog(e.getMessage());\r\n }\r\n return (Boolean)responderBean.getDataObject();\r\n }",
"private void checkAccessRights(final String operation, final String id,\n final String username, final Profile myProfile,\n final String myUserId, final List<GroupElem> userGroups,\n final UserGroupRepository groupRepository) { Before we do anything check (for UserAdmin) that they are not trying\n // to add a user to any group outside of their own - if they are then\n // raise an exception - this shouldn't happen unless someone has\n // constructed their own malicious URL!\n //\n if (operation.equals(Params.Operation.NEWUSER)\n || operation.equals(Params.Operation.EDITINFO)\n || operation.equals(Params.Operation.FULLUPDATE)) {\n if (!(myUserId.equals(id)) && myProfile == Profile.UserAdmin) {\n final List<Integer> groupIds = groupRepository\n .findGroupIds(UserGroupSpecs.hasUserId(Integer\n .parseInt(myUserId)));\n for (GroupElem userGroup : userGroups) {\n boolean found = false;\n for (int myGroup : groupIds) {\n if (userGroup.getId() == myGroup) {\n found = true;\n }\n }\n if (!found) {\n throw new IllegalArgumentException(\n \"Tried to add group id \"\n + userGroup.getId()\n + \" to user \"\n + username\n + \" - not allowed \"\n + \"because you are not a member of that group!\");\n }\n }\n }\n }\n }",
"protected boolean isValid(AccessUser obj)\n {\n return obj != null && obj.username != null && !getMembers().contains(obj);\n }",
"public abstract boolean canHandle(ObjectInformation objectInformation);",
"private Boolean checkRuntimePermission() {\n List<String> permissionsNeeded = new ArrayList<String>();\n\n final List<String> permissionsList = new ArrayList<String>();\n if (!addPermission(permissionsList, Manifest.permission.READ_EXTERNAL_STORAGE))\n permissionsNeeded.add(\"Storage\");\n if (!addPermission(permissionsList, Manifest.permission.CAMERA))\n permissionsNeeded.add(\"Camera\");\n /* if (!addPermission(permissionsList, Manifest.permission.WRITE_CONTACTS))\n permissionsNeeded.add(\"Write Contacts\");*/\n\n if (permissionsList.size() > 0) {\n if (permissionsNeeded.size() > 0) {\n // Need Rationale\n String message = \"You need to grant access to \" + permissionsNeeded.get(0);\n for (int i = 1; i < permissionsNeeded.size(); i++)\n message = message + \", \" + permissionsNeeded.get(i);\n showMessageOKCancel(message,\n new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int which) {\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n requestPermissions(permissionsList.toArray(new String[permissionsList.size()]),\n REQUEST_CODE_ASK_MULTIPLE_PERMISSIONS);\n }\n }\n });\n return false;\n }\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n requestPermissions(permissionsList.toArray(new String[permissionsList.size()]),\n REQUEST_CODE_ASK_MULTIPLE_PERMISSIONS);\n }\n return false;\n }\n return true;\n }",
"public boolean isAllowed(BaseAction actionClass) {\r\n\t\tint role = getCurrentRole();\r\n\t\tif ((role & User.ROLE_ADMINISTRATOR) != 0) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\tInteger requiredRoles = privilegeDef.get(actionClass.getClass().getSimpleName());\r\n\t\treturn requiredRoles == null || (requiredRoles & role) != 0;\r\n\t}",
"public boolean validatePermissions()\r\n\t{\n\t\treturn true;\r\n\t}",
"protected void checkRights(String rightName, IEntity entity) {\n\t\tISecurityManager manager = DAOSystem.getSecurityManager();\n\t\tIUser user = manager.getCurrentUser();\n\n\t\tif (log.isDebugEnabled()) {\n\t\t\t// disabled.\n\t\t\t/*\n\t\t\t * StringBuffer logbuffer = new StringBuffer();\n\t\t\t * logbuffer.append(\"SECURITY CHECK: User: \").append(user != null ?\n\t\t\t * user.getName() : \"<no user: systemstart>\");\n\t\t\t * logbuffer.append(\" RECHT: \").append(rightName);\n\t\t\t * logbuffer.append(\"... Bei Entit�t: \"\n\t\t\t * ).append(getEntityClass().getName());\n\t\t\t * log.debug(logbuffer.toString());\n\t\t\t */\n\t\t}\n\t\tboolean result = entity == null ? manager.hasRight(getEntityClass().getName(), rightName) : hasRight(entity,\n\t\t\t\trightName);\n\n\t\tif (user != null && !result) {\n\t\t\tStringBuffer sb = new StringBuffer();\n\t\t\tsb.append(\"Missing right: \").append(rightName);\n\t\t\tsb.append(\"... for entity: \").append(getEntityClass().getName());\n\t\t\tlog.error(\"SECURITY EXCEPTION: \" + sb.toString());\n\t\t\tthrow new SecurityException(sb.toString());\n\t\t}\n\t}",
"boolean check(Permission permission, Surrogate surrogate, boolean permissionRequired) throws T2DBException;",
"protected boolean checkEnabledPermission() {\r\n ClientSecurityManager manager = ApplicationManager.getClientSecurityManager();\r\n if (manager != null) {\r\n if (this.enabledPermission == null) {\r\n if ((this.buttonKey != null) && (this.parentForm != null)) {\r\n this.enabledPermission = new FormPermission(this.parentForm.getArchiveName(), \"enabled\",\r\n this.buttonKey, true);\r\n }\r\n }\r\n try {\r\n // Checks to show\r\n if (this.enabledPermission != null) {\r\n manager.checkPermission(this.enabledPermission);\r\n }\r\n this.restricted = false;\r\n return true;\r\n } catch (Exception e) {\r\n this.restricted = true;\r\n if (e instanceof NullPointerException) {\r\n ToggleButton.logger.error(null, e);\r\n }\r\n if (ApplicationManager.DEBUG_SECURITY) {\r\n ToggleButton.logger.debug(this.getClass().toString() + \": \" + e.getMessage(), e);\r\n }\r\n return false;\r\n }\r\n } else {\r\n return true;\r\n }\r\n }",
"void checkAccessModifier(Method method);",
"boolean isAdmin() {\n\n if (isAdminDirect()) {\n return true;\n }\n\n RoleManager rm = getRoleManager();\n Iterator it = getAllRoles().iterator();\n\n while (it.hasNext()) {\n try {\n if (((Grantee) rm.getGrantee(\n (String) it.next())).isAdminDirect()) {\n return true;\n }\n } catch (HsqlException he) {\n throw Trace.runtimeError(Trace.RETRIEVE_NEST_ROLE_FAIL,\n he.getMessage());\n }\n }\n\n return false;\n }",
"public abstract boolean isEdible();",
"private boolean isReadStorageAllowed() {\n int result = ContextCompat.checkSelfPermission(this, Manifest.permission.READ_EXTERNAL_STORAGE);\n int write = ContextCompat.checkSelfPermission(this, Manifest.permission.WRITE_EXTERNAL_STORAGE);\n\n //If permission is granted returning true\n if (result == PackageManager.PERMISSION_GRANTED && write == PackageManager.PERMISSION_DENIED) {\n return true;\n } else {\n\n //If permission is not granted returning false\n return false;\n }\n }",
"public boolean canWrite(Transaction.TransactionType t, Operation o) {\n if (!isActive || Transaction.TransactionType.READ_ONLY.equals(t) ||\n !variables.containsKey(o.getVariableId())) {\n return false;\n }\n return lockManagers.get(o.getVariableId()).canAcquireLock(o.getType(), o.getTransactionId());\n }",
"boolean canWrite();",
"@Test\n public void test_access_to_modify_team_success() {\n try {\n Assert.assertTrue(authBO.hasAccessToModifyTeam(1, 1));\n } catch (Exception e) {\n e.printStackTrace();\n Assert.fail(e.getMessage());\n }\n }",
"@Schema(description = \"Operations the current user is able to perform on this object\")\n public Map<String, Boolean> getCan() {\n return can;\n }",
"public boolean checkPerms()\n {\n boolean perms = hasPerms();\n if (!perms) {\n ActivityCompat.requestPermissions(\n itsActivity, new String[] { itsPerm }, itsPermsRequestCode);\n }\n return perms;\n }",
"@Override\n public void checkPermission(Permission perm) {\n }",
"@Override\n protected boolean calculateEnabled() {\n if (!super.calculateEnabled())\n return false;\n // allows only the editing of non-readonly parts\n return EditPartUtil.isEditable(getSelectedObjects().get(0));\n }",
"public boolean isForceAccess() {\r\n \t\treturn forceAccess;\r\n \t}",
"@JsonIgnore\n public boolean isAccesible() {\n return isGateway();\n }",
"private boolean checkPermissions(HttpServletRequest request, RouteAction route) {\n\t\treturn true;\n\t}",
"public final boolean isReadOnly() {\n\t\treturn m_info.isReadOnly();\n\t}",
"public boolean hasPerms()\n {\n return ContextCompat.checkSelfPermission(itsActivity, itsPerm) ==\n PackageManager.PERMISSION_GRANTED;\n }",
"public boolean isReadOnly() {\n checkNotUnknown();\n return (flags & ATTR_READONLY_ANY) == ATTR_READONLY;\n }",
"@Override\n\tpublic boolean can(String permission)\n\t{\n\t\treturn this.auth() != null && this.auth().getRole() != null && this.auth().getRole().getPermissions().parallelStream().filter(p -> Pattern.compile(p.getName()).matcher(permission).groupCount() == 0).count() != 0;\n\t}",
"public boolean hasReadOnly() {\n checkNotUnknown();\n return (flags & ATTR_READONLY_ANY) != 0;\n }",
"public boolean hasSetAcl() {\n return ((bitField0_ & 0x04000000) == 0x04000000);\n }",
"private void checkPermissions(Stage... stages){\n if(readOnly){\n System.err.println(\"Attempted to write to a read only move.\");\n System.exit(-1);\n }\n if(readOnlyInputs){\n for(Stage s : stages){\n if(s == this.stage){\n System.err.println(\"Attempted to write to an input only field.\");\n System.exit(-1);\n }\n }\n }\n }",
"public static boolean canAccess (HttpServletRequest req, AccessRights requiredRights) {\n\t\tif (requiredRights.equals(AccessRights.PUBLIC)) {\n\t\t\treturn true;\n\t\t}\n\n\t\tif (req.getSession().getAttribute(SESS_IS_EMPLOYEE) != null) {\n\t\t\tif (requiredRights.equals(AccessRights.AUTHENTICATED) || requiredRights.equals(AccessRights.EMPLOYEE)) {\n\t\t\t\treturn true;\n\t\t\t}\n\n\t\t\treturn req.getSession().getAttribute(SESS_IS_ADMIN) != null && (boolean) req.getSession().getAttribute(SESS_IS_ADMIN);\n\t\t}\n\n\t\treturn false;\n\t}",
"public boolean canChangeRooms() {\n return this.canChangeRooms;\n }",
"private boolean checkPermission() {\r\n int result = ContextCompat.checkSelfPermission(getApplicationContext(), READ_CONTACTS);\r\n int result1 = ContextCompat.checkSelfPermission(getApplicationContext(), CAMERA);\r\n int result2 = ContextCompat.checkSelfPermission(getApplicationContext(), ACCESS_FINE_LOCATION);\r\n int result3 = ContextCompat.checkSelfPermission(getApplicationContext(), READ_EXTERNAL_STORAGE);\r\n int result4 = ContextCompat.checkSelfPermission(getApplicationContext(), WRITE_EXTERNAL_STORAGE);\r\n int result5 = ContextCompat.checkSelfPermission(getApplicationContext(), READ_PHONE_STATE);\r\n int result6 = ContextCompat.checkSelfPermission(getApplicationContext(), RECORD_AUDIO);\r\n int result7 = ContextCompat.checkSelfPermission(getApplicationContext(), SEND_SMS);\r\n //int result8 = ContextCompat.checkSelfPermission(getApplicationContext(), BLUETOOTH);\r\n\r\n return result == PackageManager.PERMISSION_GRANTED && result1 == PackageManager.PERMISSION_GRANTED && result2 == PackageManager.PERMISSION_GRANTED &&\r\n result3 == PackageManager.PERMISSION_GRANTED && result4 == PackageManager.PERMISSION_GRANTED && result5 == PackageManager.PERMISSION_GRANTED &&\r\n result6 == PackageManager.PERMISSION_GRANTED && result7 == PackageManager.PERMISSION_GRANTED/*&& result8== PackageManager.PERMISSION_GRANTED*/;\r\n }",
"@Override\n public boolean hasReadAccess() {\n return true;\n }",
"@Test\n public void getObjectAccessTest() throws ApiException {\n AccessRequest request = null;\n String scope = null;\n AccessResponse response = api.getObjectAccess(request, scope);\n\n // TODO: test validations\n }",
"public abstract boolean isAssignable();"
] | [
"0.74329054",
"0.72367394",
"0.6898852",
"0.6863531",
"0.66934544",
"0.66672117",
"0.6527757",
"0.63674235",
"0.63134944",
"0.6247393",
"0.62114805",
"0.6204891",
"0.61834425",
"0.61182636",
"0.6097959",
"0.6079239",
"0.60623085",
"0.60623085",
"0.6046055",
"0.60337865",
"0.6015398",
"0.6002493",
"0.6001508",
"0.598629",
"0.59820664",
"0.5968988",
"0.59616977",
"0.5932636",
"0.5926966",
"0.59113204",
"0.58772224",
"0.58725077",
"0.5855424",
"0.5839711",
"0.5839711",
"0.5839711",
"0.5837586",
"0.5830065",
"0.5826074",
"0.5822495",
"0.58190733",
"0.58164203",
"0.5808026",
"0.5798651",
"0.5791804",
"0.5784042",
"0.57744986",
"0.576227",
"0.5754345",
"0.5750335",
"0.574916",
"0.5748415",
"0.5733407",
"0.57304096",
"0.572213",
"0.57151955",
"0.571108",
"0.5693342",
"0.56854546",
"0.5680057",
"0.5670207",
"0.56647736",
"0.5660632",
"0.5659878",
"0.5654687",
"0.56530374",
"0.5650191",
"0.5649469",
"0.5615751",
"0.5599248",
"0.55967385",
"0.5589441",
"0.557067",
"0.5556129",
"0.5545742",
"0.5545722",
"0.5545111",
"0.55389994",
"0.55355036",
"0.5531658",
"0.55314213",
"0.5528129",
"0.5527265",
"0.55262554",
"0.5515527",
"0.5514152",
"0.5509984",
"0.5507873",
"0.55054516",
"0.55042446",
"0.54998434",
"0.54985964",
"0.5491202",
"0.5485363",
"0.5485005",
"0.54829675",
"0.5470248",
"0.546998",
"0.5464971",
"0.54630345"
] | 0.82381237 | 0 |
creates a new object on the ECM System using the given parameters | public abstract String createNewObject(OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p, OwObject parent_p, String strMimeType_p,
String strMimeParameter_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CMObject newInstance();",
"EisModel createEisModel();",
"public void create(){}",
"Elevage createElevage();",
"public ProductoCreable newInstance(int codigo, String nombre){\r\n \r\n }",
"public System(String implClassName, Params param) {\n\t\tSimLogger.log(Level.INFO, \"New System Created.\");\n\t\tthis.param = param;\n\t\tthis.param.system = this;\n\t\ttry {\n\t\t\tClass implClass = Class.forName(implClassName);\n\t\t\timpl = (Implementation) implClass.newInstance();\n\t\t\t// Set the implementation's system so init() can set it in workload!!!\n\t\t\timpl.sys = this;\n\t\t\timpl.init(param.starter.build());\n\t\t\tSimLogger.log(Level.FINE, \"Implementation \" + implClassName + \" was created successfully.\");\n\n\t\t\ttry {\n\t\t\t\tfor(String s : param.measures) {\n\t\t\t\t\tSimLogger.log(Level.FINE, \"Adding measure \" + s + \" to system.\");\n\t\t\t\t\tClass measureClass = Class.forName(s);\n\t\t\t\t\tMeasure measure = (Measure) measureClass.newInstance();\n\t\t\t\t\tmeasures.add(measure);\n\t\t\t\t}\n\t\t\t\tCollections.sort(measures);\n\t\t\t} catch(ClassNotFoundException e) {\n\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot find measure class with name = \" + implClassName);\n\t\t\t\tthrow new RuntimeException(e);\n\t\t\t} catch(InstantiationException e) {\n\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate measure class with name = \" + implClassName);\n\t\t\t\tthrow new RuntimeException(e);\n\t\t\t} catch(IllegalAccessException e) {\n\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate measure class with name = \" + implClassName);\n\t\t\t\tthrow new RuntimeException(e);\n\t\t\t}\n\n\t\t\t//init actors\n\t\t\tHashMap<String, Integer> actorMachineInstances = param.starter.buildActorMachine();\n\t\t\tfor(String aType : actorMachineInstances.keySet()) {\n\t\t\t\tint numActors = actorMachineInstances.get(aType);\n\t\t\t\tSimLogger.log(Level.FINE, \"Creating \" + numActors + \" many of actor type \" + aType);\n\t\t\t\tfor(int i = 0; i < numActors; i++) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tClass actorClass = Class.forName(aType);\n\t\t\t\t\t\tActorMachine am = (ActorMachine) actorClass.newInstance();\n\t\t\t\t\t\tString actorName = am.getPrefix() + i;\n\t\t\t\t\t\tam.actor = actorName;\n\t\t\t\t\t\tam.actorType = aType;\n\t\t\t\t\t\tam.sys = this;\n\t\t\t\t\t\tactors.put(actorName, am);\n\t\t\t\t\t} catch(ClassNotFoundException e) {\n\t\t\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot find actor machine class with name = \" + implClassName);\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t} catch(InstantiationException e) {\n\t\t\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate actor machine class with name = \" + implClassName);\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t} catch(IllegalAccessException e) {\n\t\t\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate actor machine class with name = \" + implClassName);\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tSimLogger.log(Level.FINE, \"Actors init was successful.\");\n\n\t\t} catch(ClassNotFoundException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Cannot find implementation class with name = \" + implClassName);\n\t\t\te.printStackTrace();\n\t\t} catch(InstantiationException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate implementation class with name = \" + implClassName);\n\t\t\te.printStackTrace();\n\t\t} catch(IllegalAccessException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate implementation class with name = \" + implClassName);\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"OBJECT createOBJECT();",
"OperacionColeccion createOperacionColeccion();",
"Vehicle createVehicle();",
"Vehicle createVehicle();",
"Entity createEntity();",
"public void create() {\n\t\t\n\t}",
"@Override\r\n\tpublic CMObject newInstance()\r\n\t{\r\n\t\ttry\r\n\t\t{\r\n\t\t\treturn this.getClass().getDeclaredConstructor().newInstance();\r\n\t\t}\r\n\t\tcatch(final Exception e)\r\n\t\t{\r\n\t\t\tLog.errOut(ID(),e);\r\n\t\t}\r\n\t\treturn new StdBehavior();\r\n\t}",
"public Device createObject(String brand, String model, Integer price, String photo, String date);",
"public Entity(String emailID,String name){ \n\t\tthis.emailID=emailID;\n\t\tthis.name=name;\n\t}",
"private Vehicle createNewVehicle() {\n\t\tString make = generateMake();\n\t\tString model = generateModel();\n\t\tdouble weight = generateWeight(model);\n\t\tdouble engineSize = generateEngineSize(model);\n\t\tint numberOfDoors = generateNumberOfDoors(model);\n\t\tboolean isImport = generateIsImport(make);\n\t\t\n\t\tVehicle vehicle = new Vehicle(make, model, weight, engineSize, numberOfDoors, isImport);\n\t\treturn vehicle;\t\t\n\t}",
"public HALeaseManagementModule() {\n\n }",
"<T> T newInstance(URI description) throws EnvironmentException;",
"SystemParamModel createSystemParamModel();",
"public PedometerEntity() {\n }",
"void create(E entity);",
"Operacion createOperacion();",
"ECNONet createECNONet();",
"public CourseRegInstance newInstance(String edma_name, SchoolInfo schoolInfo) throws IOException;",
"@Override\r\n\tpublic void create() {\n\t\t\r\n\t}",
"public abstract void create();",
"protected abstract ENTITY createEntity();",
"public CMN() {\n\t}",
"Oracion createOracion();",
"Instance createInstance();",
"public EnvEntityClient(float x, float y, float z, long time) {\n\t\tsuper(x,y,z,time);\n\t\tgenerate();\n\t}",
"public EsoFactoryImpl()\r\n {\r\n super();\r\n }",
"protected abstract void construct();",
"public EcoreFactoryImpl()\n {\n super();\n }",
"public ObjectFactory() {\n\t}",
"public CustomEntitiesTaskParameters() {}",
"public EmoticonBO()\n {}",
"public static Produit createEntity(EntityManager em) {\n Produit produit = new Produit()\n .designation(DEFAULT_DESIGNATION)\n .soldeInit(DEFAULT_SOLDE_INIT)\n .prixAchat(DEFAULT_PRIX_ACHAT)\n .prixVente(DEFAULT_PRIX_VENTE)\n .quantiteDispo(DEFAULT_QUANTITE_DISPO)\n .quantiteInit(DEFAULT_QUANTITE_INIT)\n .seuilReaprov(DEFAULT_SEUIL_REAPROV)\n .reference(DEFAULT_REFERENCE);\n return produit;\n }",
"public ObjectFactory() {\r\n\t}",
"@Override\n\tpublic void create() {\n\t\t\n\t}",
"@Override\n\tpublic void create() {\n\n\t}",
"EM createEM();",
"public Engine(){\n name = \"Basic Engine\";\n moveDeduction = 1;\n }",
"Parcelle createParcelle();",
"public EcoreFactoryImpl() {\r\n\t\tsuper();\r\n\t}",
"public static EmpCV createEntity(EntityManager em) {\n EmpCV empCV = new EmpCV()\n .title(DEFAULT_TITLE)\n .anneexperience(DEFAULT_ANNEEXPERIENCE)\n .permis(DEFAULT_PERMIS)\n .niveauScolaire(DEFAULT_NIVEAU_SCOLAIRE)\n .diplome(DEFAULT_DIPLOME);\n return empCV;\n }",
"private SceneGraphObject createNode( String className, Class[] parameterTypes, Object[] parameters ) {\n SceneGraphObject ret;\n Constructor constructor;\n\n try {\n Class state = Class.forName( className );\n constructor = state.getConstructor( parameterTypes );\n ret = (SceneGraphObject)constructor.newInstance( parameters );\n\t} catch(ClassNotFoundException e1) {\n if (control.useSuperClassIfNoChildClass())\n ret = createNodeFromSuper( className, parameterTypes, parameters );\n else\n throw new SGIORuntimeException( \"No State class for \"+\n\t\t\t\t\t\tclassName );\n\t} catch( IllegalAccessException e2 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName+\" - IllegalAccess\" );\n\t} catch( InstantiationException e3 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName );\n } catch( java.lang.reflect.InvocationTargetException e4 ) {\n\t throw new SGIORuntimeException( \"InvocationTargetException for \"+\n\t\t\t\t\t\tclassName );\n } catch( NoSuchMethodException e5 ) {\n for(int i=0; i<parameterTypes.length; i++)\n System.err.println( parameterTypes[i].getName() );\n System.err.println(\"------\");\n\t throw new SGIORuntimeException( \"Invalid constructor for \"+\n\t\t\t\t\t\tclassName );\n }\n\n return ret;\n }",
"public static IXccdfEngine createEngine(IPlugin plugin, SystemEnumeration... systems) {\r\n \treturn new OEMEngine(plugin, systems);\r\n }",
"public static InventoryProvider createEntity(EntityManager em) {\n InventoryProvider inventoryProvider = new InventoryProvider()\n .idInventoryProvider(DEFAULT_ID_INVENTORY_PROVIDER)\n .code(DEFAULT_CODE)\n .name(DEFAULT_NAME)\n .price(DEFAULT_PRICE)\n .cuantity(DEFAULT_CUANTITY);\n return inventoryProvider;\n }",
"public ExpertiseEntity() {\n }",
"public void create(T e);",
"Reproducible newInstance();",
"public Equipas() {\r\n\t\t\r\n\t}",
"public OVChipkaart() {\n\n }",
"Compuesta createCompuesta();",
"CsticModel createInstanceOfCsticModel();",
"public EcoreFactoryImpl() {\n super();\n }",
"private SceneGraphObject createNodeFromSuper( String className, Class[] parameterTypes, Object[] parameters ) {\n\tSceneGraphObject ret;\n\n String tmp = this.getClass().getName();\n String superClass = tmp.substring( tmp.indexOf(\"state\")+6, tmp.length()-5 );\n Constructor constructor;\n\n try {\n Class state = Class.forName( superClass );\n constructor = state.getConstructor( parameterTypes );\n ret = (SceneGraphObject)constructor.newInstance( parameters );\n\t} catch(ClassNotFoundException e1) {\n\t throw new SGIORuntimeException( \"No State class for \"+\n\t\t\t\t\t\tsuperClass );\n\t} catch( IllegalAccessException e2 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName+\" - IllegalAccess\" );\n\t} catch( InstantiationException e3 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName );\n } catch( java.lang.reflect.InvocationTargetException e4 ) {\n\t throw new SGIORuntimeException( \"InvocationTargetException for \"+\n\t\t\t\t\t\tclassName );\n } catch( NoSuchMethodException e5 ) {\n for(int i=0; i<parameterTypes.length; i++)\n System.err.println( parameterTypes[i].getName() );\n System.err.println(\"------\");\n\t throw new SGIORuntimeException( \"Invalid constructor for \"+\n\t\t\t\t\t\tclassName );\n }\n\n return ret;\n }",
"For createFor();",
"public BoxEnterprise() {\n super();\n }",
"public ObjectFactory() {}",
"public ObjectFactory() {}",
"public ObjectFactory() {}",
"T createEntity();",
"@Override\n\tpublic void create () {\n\n\t}",
"private EntityFactory() {}",
"@Override\r\n\tpublic void create() {\n\r\n\t}",
"public interface EcnonetsFactory extends EFactory {\r\n\t/**\r\n\t * The singleton instance of the factory.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @generated\r\n\t */\r\n\tEcnonetsFactory eINSTANCE = dk.dtu.imm.se.ecno.pn.ecnonets.impl.EcnonetsFactoryImpl.init();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>ECNO Net</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>ECNO Net</em>'.\r\n\t * @generated\r\n\t */\r\n\tECNONet createECNONet();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Transition</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Transition</em>'.\r\n\t * @generated\r\n\t */\r\n\tTransition createTransition();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Page</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Page</em>'.\r\n\t * @generated\r\n\t */\r\n\tPage createPage();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Condition</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Condition</em>'.\r\n\t * @generated\r\n\t */\r\n\tCondition createCondition();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Event Binding</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Event Binding</em>'.\r\n\t * @generated\r\n\t */\r\n\tEventBinding createEventBinding();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Action</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Action</em>'.\r\n\t * @generated\r\n\t */\r\n\tAction createAction();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Event Uses</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Event Uses</em>'.\r\n\t * @generated\r\n\t */\r\n\tEventUses createEventUses();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Event Use</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Event Use</em>'.\r\n\t * @generated\r\n\t */\r\n\tEventUse createEventUse();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Java Expression</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Java Expression</em>'.\r\n\t * @generated\r\n\t */\r\n\tJavaExpression createJavaExpression();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Java Statement</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Java Statement</em>'.\r\n\t * @generated\r\n\t */\r\n\tJavaStatement createJavaStatement();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Imports</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Imports</em>'.\r\n\t * @generated\r\n\t */\r\n\tImports createImports();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Attribute Declarations</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Attribute Declarations</em>'.\r\n\t * @generated\r\n\t */\r\n\tAttributeDeclarations createAttributeDeclarations();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Named Parameter</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Named Parameter</em>'.\r\n\t * @generated\r\n\t */\r\n\tNamedParameter createNamedParameter();\r\n\r\n\t/**\r\n\t * Returns the package supported by this factory.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return the package supported by this factory.\r\n\t * @generated\r\n\t */\r\n\tEcnonetsPackage getEcnonetsPackage();\r\n\r\n}",
"Active_Digital_Artifact createActive_Digital_Artifact();",
"Article createArticle();",
"public Commune() {\n\t\tsuper();\n\t\t// TODO Auto-generated constructor stub\n\t}",
"public Partage() {\n }",
"public Object createNew(String typename, Object... args) \n\t\tthrows \tIllegalAccessException, \n\t\t\tInstantiationException, \n\t\t\tClassNotFoundException,\n\t\t\tNoSuchMethodException,\n\t\t\tInvocationTargetException \n\t{\n\t\tswitch(args.length) \n\t\t{\n\t\tcase 1 : return Class.forName(typename).getConstructor(args[0].getClass()).newInstance(args[0]);\n\t\tcase 2 : return Class.forName(typename).getConstructor(args[0].getClass(), args[1].getClass()).\n\t\t\tnewInstance(args[0], args[1]);\n\t\t}\n\t\treturn null;\n\t}",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }"
] | [
"0.6984149",
"0.6304263",
"0.6121716",
"0.6092427",
"0.60386485",
"0.6023237",
"0.6002724",
"0.5926805",
"0.592658",
"0.592658",
"0.59063375",
"0.58964056",
"0.5893188",
"0.58812916",
"0.5857822",
"0.58544785",
"0.5848131",
"0.5840965",
"0.5831216",
"0.58140576",
"0.5803301",
"0.5799861",
"0.5745319",
"0.573741",
"0.57303035",
"0.57162625",
"0.57037884",
"0.5687564",
"0.5681805",
"0.5677193",
"0.56726754",
"0.567097",
"0.564508",
"0.56263417",
"0.56253284",
"0.56159353",
"0.56051886",
"0.5605015",
"0.5604048",
"0.55981356",
"0.55956215",
"0.55795646",
"0.55765784",
"0.5570896",
"0.5570859",
"0.5569138",
"0.5568786",
"0.55685747",
"0.5565386",
"0.55647045",
"0.55644727",
"0.5548779",
"0.5543852",
"0.5541537",
"0.55389977",
"0.5538719",
"0.5536906",
"0.55320764",
"0.5531822",
"0.55221474",
"0.55171484",
"0.55171484",
"0.55171484",
"0.5512617",
"0.550697",
"0.550103",
"0.5492673",
"0.5489575",
"0.5488724",
"0.5481695",
"0.5481155",
"0.5480411",
"0.54750586",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403",
"0.5454403"
] | 0.0 | -1 |
creates a new object on the ECM System using the given parameters has additional promote and checkin mode parameters for versionable objects | public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,
OwObject parent_p, String strMimeType_p, String strMimeParameter_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,\r\n OwObject parent_p, String strMimeType_p, String strMimeParameter_p, boolean fKeepCheckedOut_p) throws Exception;",
"public CMObject newInstance();",
"@Override\n public boolean create(Revue objet) {\n return false;\n }",
"EisModel createEisModel();",
"public abstract ArchECoreArchitecture newArchitecture(ArchEVersionVO version) throws ArchEException;",
"Operacion createOperacion();",
"WithCreate withHyperVGeneration(HyperVGeneration hyperVGeneration);",
"public abstract ArchECoreRequirementModel newRequirementModel(ArchEVersionVO version) throws ArchEException;",
"Version create(Identity nodeId);",
"public ProductoCreable newInstance(int codigo, String nombre){\r\n \r\n }",
"OperacionColeccion createOperacionColeccion();",
"ZenModel createZenModel();",
"public Device createObject(String brand, String model, Integer price, String photo, String date);",
"@Override\r\n\tpublic boolean create(Jeu obj) {\n\t\treturn false;\r\n\t}",
"public \n OfflineExtFactory\n (\n String workUser, \n TreeMap<String,TreeSet<VersionID>> versions\n ) \n {\n super(workUser, versions); \n }",
"private LCSRevisableEntity createEntries(String selectedId) {\n\t\t\n\t\tLCSRevisableEntity revEntity=null;\n\n\t\tLCSProduct product = null;\n\t\tLCSSKU lcsSku = null;\n\t\tString sizedefVR = \"\";\n\t\tString prodVR = \"\";\n\t\tString colorwayVR = \"\";\n\t\tString reventityVR = \"\";\n\t\t\n\t\tLCSLog.debug(\"****************Inside createEntries ***********************\");\n\t\t/*\n\t\t * is found in the request object.\n\t\t */\n\t\t// get division code from request.\n\t\tString divcode = this.requesttable.get(selectedId + \"_DIVISION_CODE\");\n\t\t// get material number from request\n\t\tString materialNumber = divcode\n\t\t\t\t+ this.requesttable.get(selectedId + \"_MATERIALNUMBER\");\n\t\t// get nrf code from request\n\t\tString nrfCode = \"\";\n\t\t// this.requesttable.get(selectedId + \"_NRF_CODE\");\n\t\t// get sourceVersion from request\n\t\tString sourceVersion = this.requesttable.get(selectedId + \"_SOURCE\");\n\t\t// get costsheetVersion from request\n\t\tString costsheetVersion = this.requesttable.get(selectedId + \"_COST\");\n\t\t\n\t\tString specVersion = this.requesttable.get(selectedId + \"_SPEC\");\n\t\t\n\t\tString bomRequestParam = this.requesttable.get(\"BOM\"+selectedId + \"_BOM\");\n\t\tLCSLog.debug(\"bomRequestParam = \"+bomRequestParam);\n\n\t\tString sourceName = \"\";\n\t\tString costName = \"\";\n\t\tString specName = \"\";\n\t\tString IBTINSTOREMONTH = \"\";\n\n\t\ttry {\n\t\t\t// get all the information from sourceVersion and costsheetVersion\n\t\t\tMap<String, String> map = LFIBTUtil.formatSourceOrCostsheetData(\n\t\t\t\t\tsourceVersion, costsheetVersion, specVersion);\n\t\t\t\n\t\t\t// source name\n\t\t\tsourceName = map.get(\"sourceNameKey\");\n\t\t\t// versionId\n\t\t\tsourceVersion = map.get(\"sourceVersionKey\"); \n\t\t\tLCSLog.debug(\"sourceName --- \" + sourceName);\n\t\t\t// costsheet name\n\t\t\tcostName = map.get(\"costNameKey\");\n\n\t\t\t// costsheetId\n\t\t\tcostsheetVersion = map.get(\"costsheetVersionKey\");\n\t\t\tLCSLog.debug(\"costName --- \" + costName);\n\t\t\t\n\t\t\tspecName = map.get(\"specNameKey\");\n\n\t\t\t// costsheetId\n\t\t\tspecVersion = map.get(\"specVersionKey\");\n\t\t\tLCSLog.debug(\"costName --- \" + costName);\t\t\t\n\n\t\t\tCollection<String> bomMOAStringColl = new ArrayList<String>();\n\t\t\tbomMOAStringColl = LFIBTUtil.formatBOMMultiChoiceValues(bomRequestParam);\n\t\t\t\n\t\t\tList<String> idList = LFIBTUtil.getObjects(selectedId);\n\n\t\t\t// parse and get all data\n\t\t\tMap<String, String> idMap = LFIBTUtil\n\t\t\t\t\t.createCustomMapFromList(idList);\n\t\t\t// get product ID\n\t\t\tprodVR = idMap.get(\"prodVR\");\n\n\t\t\tLCSLog.debug(\"prodVR : --\" + prodVR);\n\t\t\t// get the product object from productVR\n\t\t\tproduct = (LCSProduct) LCSProductQuery\n\t\t\t\t\t.findObjectById(\"VR:com.lcs.wc.product.LCSProduct:\"\n\t\t\t\t\t\t\t+ prodVR);\n\n\t\t\tLCSLog.debug(\"product : --\" + product);\n\n\t\t\t// size definition VR\n\t\t\tsizedefVR = idMap.get(\"sizedefVR\");\n\t\t\tLCSLog.debug(\"sizedefVR -- \" + sizedefVR);\n\n\t\t\t// colorway VR\n\t\t\tcolorwayVR = idMap.get(\"colorwayVR\");\n\t\t\tLCSLog.debug(\"colorwayVR : --\" + colorwayVR);\n\t\t\tlcsSku = (LCSSKU) LCSProductQuery\n\t\t\t\t\t.findObjectById(\"VR:com.lcs.wc.product.LCSSKU:\"\n\t\t\t\t\t\t\t+ colorwayVR);\n\n\t\t\t// NRF Code -- Build 5.16\n\t\t\tDouble d = 0.00;\n\t\t\td = (Double) lcsSku.getValue(\"lfNrfColorCode\");\n\t\t\tnrfCode = StringUtils.substringBeforeLast(Double.toString(d), \".\");\n\n\t\t\t/**\n\t\t\t * Build 5.16_3 -> START\n\t\t\t * Formatting NRF code to 3 digits before sending it to SAP\n\t\t\t */\n\t\t\t// getting length of code value\n\t\t\tint nrfCodeValueLength = nrfCode.length();\n\t\t\t// TRUE - if length is 1 or 2 digit\n\t\t\tif (nrfCodeValueLength == 2 || nrfCodeValueLength == 1) {\n\t\t\t\t// converting the value from double to integer\n\t\t\t\tint y = d.intValue();\n\t\t\t\t// formatting the value to be 3 digit always.\n\t\t\t\t// if not, append 0 to left\n\t\t\t\tnrfCode = (String.format(\"%03d\", y)).toString();\n\t\t\t}\n\t\t\t/**\n\t\t\t * Build 5.16_3 -> END\n\t\t\t */\n\n\t\t\t// get the revisable entity VR if applicable\n\t\t\treventityVR = idMap.get(\"reventityVR\");\n\n\t\t\t// Added for Build 6.14\n\t\t\t// ITC-START\n\t\t\tString materialDescription = this.requesttable.get(selectedId\n\t\t\t\t\t+ \"_MATERIALDESC\");\n\t\t\tIBTINSTOREMONTH = this.requesttable.get(selectedId + \"_INSTOREMONTH\");\n\t\t\tString styleNumber = this.requesttable.get(selectedId + \"_STYLE\");\n\t\t\t// ITC-END\n\t\t\t\n\t\t\t//MM : changes : Start ----\n\t\t\tif(!FormatHelper.hasContent(reventityVR))\n\t\t\t\treventityVR = LFIBTMaterialNumberValidator.getExistingMaterialRecords(materialNumber,false);\n\t\t\t//MM : changes : End ----\n\t\t\t/*\n\t\t\t * If the revisable entity VR exists then update the revisable\n\t\t\t * entity else create a new one.\n\t\t\t */\n\t\t\tif (reventityVR != null) \n\t\t\t{\n\t\t\t\tLCSLog.debug(\"sourceVersion -- \" + sourceVersion\n\t\t\t\t\t\t+ \" costsheetVersion - \" + costsheetVersion\n\t\t\t\t\t\t+ \" nrfCode -- \" + nrfCode\n\t\t\t\t\t\t+ \" materialDescription --\" + materialDescription\n\t\t\t\t\t\t+ \" IBTINSTOREMONTH--\" + IBTINSTOREMONTH\n\t\t\t\t\t\t+ \" style Number----\" + styleNumber);\n\n\t\t\t\t// API call to update the revisable entitity with new\n\t\t\t\t// source and cost details.\n\n\t\t\t\t// Updated for Build 6.14\n\t\t\t\tLCSLog.debug(CLASSNAME+\"createEntries()\"+\"calling updateRevisableEntry()\");\n\t\t\t\trevEntity=updateRevisableEntry(reventityVR, sourceVersion,\n\t\t\t\t\t\tcostsheetVersion,specVersion, nrfCode, materialDescription,\n\t\t\t\t\t\tsourceName, costName,specName, IBTINSTOREMONTH, styleNumber,bomMOAStringColl);\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"update revEntity---->\" +revEntity);\n\t\t\t}\n\t\t\telse {\n\t\t\t\t// API call to create fresh revisable entities.\n\n\t\t\t\t// Updated for Build 6.14\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"createEntries()\"+\"calling createRevisableEntry()\");\n\t\t\t\trevEntity=createRevisableEntry(product, lcsSku, materialNumber,\n\t\t\t\t\t\tsizedefVR, sourceVersion, costsheetVersion, specVersion, sourceName,\n\t\t\t\t\t\tcostName, specName, nrfCode, styleNumber, materialDescription,\n\t\t\t\t\t\tIBTINSTOREMONTH,bomMOAStringColl);\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"create revEntity---->\" +revEntity);\n\n\t\t\t}\n\t\t\t\n\n\t\t}\n\t\tcatch (WTException e) {\n\t\t\tLCSLog.error(\"WTException occurred!! \" + e.getMessage());\n\t\t}\n\t\tcatch (WTPropertyVetoException e) {\n\t\t\tLCSLog.error(\"WTPropertyVetoException occurred!! \" + e.getMessage());\n\t\t}\n\t\t\t\t\n\t\treturn revEntity;\n\n\t}",
"Parcelle createParcelle();",
"Elevage createElevage();",
"SystemParamModel createSystemParamModel();",
"@POST( CONTROLLER )\n VersionedObjectKey createObject( @Body CreateObjectRequest request );",
"Reproducible newInstance();",
"com.exacttarget.wsdl.partnerapi.ObjectDefinition addNewObjectDefinition();",
"public abstract String createNewObject(OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p, OwObject parent_p, String strMimeType_p,\r\n String strMimeParameter_p) throws Exception;",
"Entity createEntity();",
"Nexo createNexo();",
"OBJECT createOBJECT();",
"@Override\n\tpublic boolean create(Etape obj) {\n\t\treturn false;\n\t}",
"@Override\n\tprotected final void performCreateObjects( final ManagerEJB manager, Map params ) throws JaloBusinessException\n\t{\n\t\t// performCreateObjects\n\t\n\t\n\t\tcreateEnumerationValues(\n\t\t\t\"Complexion\",\n\t\t\tfalse,\n\t\t\tArrays.asList( new String[] {\n\t\t\t\n\t\t\t\t\"VeryFair\",\n\t\t\t\t\"Fair\",\n\t\t\t\t\"Wheatish\",\n\t\t\t\t\"DarkBrown\",\n\t\t\t\t\"Black\"\n\t\t\t} )\n\t\t);\n\t\n\t\tsingle_setRelAttributeProperties_Customer2ImageQualityRel_source();\n\t\n\t\tsingle_setRelAttributeProperties_Camera2PromotionsRel_source();\n\t\n\t\tsingle_setRelAttributeProperties_Customer2ImageQualityRel_target();\n\t\n\t\tsingle_setRelAttributeProperties_Camera2PromotionsRel_target();\n\t\n\t\tconnectRelation(\n\t\t\t\"Customer2ImageQualityRel\", \n\t\t\tfalse, \n\t\t\t\"customer\", \n\t\t\t\"Customer\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\t\"imageQuality\", \n\t\t\t\"ImageQuality\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.OPTIONAL_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\ttrue,\n\t\t\ttrue\n\t\t);\n\t\n\t\tconnectRelation(\n\t\t\t\"Camera2PromotionsRel\", \n\t\t\tfalse, \n\t\t\t\"camera\", \n\t\t\t\"CSRCustomerDetails\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.OPTIONAL_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\t\"promotions\", \n\t\t\t\"AbstractPromotion\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.OPTIONAL_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\ttrue,\n\t\t\ttrue\n\t\t);\n\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tchangeMetaType(\n\t\t\t\t\t\"Customer\",\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\tsingle_setAttributeProperties_Customer_age();\n\t\t\n\t\t\tsingle_setAttributeProperties_Customer_complexion();\n\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tsetItemTypeProperties(\n\t\t\t\t\t\"ImageQuality\",\n\t\t\t\t\tfalse,\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\tsingle_setAttributeProperties_ImageQuality_qualityScore();\n\t\t\n\t\t\tsingle_setAttributeProperties_ImageQuality_identityId();\n\t\t\n\t\t\tsingle_setAttributeProperties_ImageQuality_imagePath();\n\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tsetItemTypeProperties(\n\t\t\t\t\t\"FaceRecognitionComponent\",\n\t\t\t\t\tfalse,\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tchangeMetaType(\n\t\t\t\t\t\"CSRCustomerDetails\",\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_complexion();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_imageUrl();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_age();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_gender();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_devicetoken();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_cameraid();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_welcomeMessage();\n\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tsetItemTypeProperties(\n\t\t\t\t\t\"PersistCustomerImagesCronJob\",\n\t\t\t\t\tfalse,\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\t\tsetDefaultProperties(\n\t\t\t\t\t\"Complexion\",\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull\n\t\t\t\t);\n\t\t\t\n\t}",
"protected JvmOSMeta createJvmOSMetaNode(String paramString1, String paramString2, ObjectName paramObjectName, MBeanServer paramMBeanServer) {\n/* 217 */ return new JvmOSMeta(this, this.objectserver);\n/* */ }",
"SAProcessInstanceBuilder createNewInstance(SProcessInstance processInstance);",
"void create(Product product) throws IllegalArgumentException;",
"public XxGamMaApproverByEmployeeIdLovVORowImpl() {\n }",
"@Override\n\tprotected Entity createNewEntity(final Object baseObject) {\n\t\tProductAssociation productAssociation = getBean(ContextIdNames.PRODUCT_ASSOCIATION);\n\t\tproductAssociation.setGuid(new RandomGuidImpl().toString());\n\t\tproductAssociation.setCatalog(this.getImportJob().getCatalog());\n\t\treturn productAssociation;\n\t}",
"public XpeDccNewContractSetupROVORowImpl() {\n }",
"private SceneGraphObject createNodeFromSuper( String className, Class[] parameterTypes, Object[] parameters ) {\n\tSceneGraphObject ret;\n\n String tmp = this.getClass().getName();\n String superClass = tmp.substring( tmp.indexOf(\"state\")+6, tmp.length()-5 );\n Constructor constructor;\n\n try {\n Class state = Class.forName( superClass );\n constructor = state.getConstructor( parameterTypes );\n ret = (SceneGraphObject)constructor.newInstance( parameters );\n\t} catch(ClassNotFoundException e1) {\n\t throw new SGIORuntimeException( \"No State class for \"+\n\t\t\t\t\t\tsuperClass );\n\t} catch( IllegalAccessException e2 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName+\" - IllegalAccess\" );\n\t} catch( InstantiationException e3 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName );\n } catch( java.lang.reflect.InvocationTargetException e4 ) {\n\t throw new SGIORuntimeException( \"InvocationTargetException for \"+\n\t\t\t\t\t\tclassName );\n } catch( NoSuchMethodException e5 ) {\n for(int i=0; i<parameterTypes.length; i++)\n System.err.println( parameterTypes[i].getName() );\n System.err.println(\"------\");\n\t throw new SGIORuntimeException( \"Invalid constructor for \"+\n\t\t\t\t\t\tclassName );\n }\n\n return ret;\n }",
"ManagementLockObject create(Context context);",
"@Test\r\n public void testCreate() throws Exception {\r\n PodamFactory pf=new PodamFactoryImpl();\r\n MonitoriaEntity nuevaEntity=pf.manufacturePojo(MonitoriaEntity.class);\r\n MonitoriaEntity respuestaEntity=persistence.create(nuevaEntity);\r\n Assert.assertNotNull(respuestaEntity);\r\n Assert.assertEquals(respuestaEntity.getId(), nuevaEntity.getId());\r\n Assert.assertEquals(respuestaEntity.getIdMonitor(), nuevaEntity.getIdMonitor());\r\n Assert.assertEquals(respuestaEntity.getTipo(), nuevaEntity.getTipo());\r\n \r\n \r\n }",
"public VersionModel() {\n }",
"opmodelFactory getopmodelFactory();",
"private final BaseShelfItemVM m66540a(Context context, MarketShelfSkuInfo marketShelfSkuInfo, ModeProvider modeProvider, Size size, IDownloadHandlerService bVar, boolean z) {\n String str = marketShelfSkuInfo.propertyType;\n if (str != null && str.hashCode() == 96305358 && str.equals(C6969H.m41409d(\"G6C81DA15B4\"))) {\n return new ShelfEBookItemVM(context, marketShelfSkuInfo, modeProvider, size, z, bVar);\n }\n return new BaseShelfItemVM(context, marketShelfSkuInfo, modeProvider, size, z);\n }",
"public interface VersionFactory extends Marshaller<Version> {\n /**\n * Creates a new version object for the provided node ID.\n */\n Version create(Identity nodeId);\n}",
"Vehicle createVehicle();",
"Vehicle createVehicle();",
"private LCSRevisableEntity createRevisableEntry(LCSProduct product, LCSSKU lcsSKu,\n\t\t\tString materialNumber, String sizedefVR, String sourceVersion,\n\t\t\tString costsheetVersion, String specVersion, String sourceName, String costName,\n\t\t\tString specName, String nrfCode, String styleNumber, String materialDescription,\n\t\t\tString IBTINSTOREMONTH,Collection bomMOAStringColl) throws WTException , WTPropertyVetoException {\n\t\t\n\t\tLCSRevisableEntityLogic revisableEntityLogic = new LCSRevisableEntityLogic();\n\t\t\n\t\tLCSRevisableEntity createRevEntity=null;\n\n\t\tLCSLog.debug(CLASSNAME+\"createRevisableEntry(), this is a fresh entry\");\n\t\t\n\t\tFlexType IBTFlexType = FlexTypeCache\n\t\t.getFlexTypeFromPath(LFIBTConstants.ibtMaterialPath);\n\t\t\n\t\tLCSRevisableEntity ibtMaterialRevObj = LCSRevisableEntity.newLCSRevisableEntity();;\n\t\tString revId = \"\";\n\t\t// Create Blank Revisable Entity Object for the productId\n\t\t\n\t\t\n\t\t//revModel.load(FormatHelper.getObjectId(this.getRevObj()));\n\t\t// create a new model in order to create a new revisable entity.\n\t\t//LCSRevisableEntityClientModel ibtRevEntityModel = new LCSRevisableEntityClientModel();\n\t\t//ibtRevEntityModel.set\n\t\t//ibtRevEntityModel.load(FormatHelper.getObjectId(rev));\n\t\t// set the flextype to ibtRevEntityModel sub type\n\t\tibtMaterialRevObj.setFlexType(IBTFlexType);\n\t\t//System.out.println(\"****************Inside setFlexType ***********************\");\n\t\t//ibtMaterialRevObj.setRevisableEntityName(FormatHelper.format(materialNumber\n\t\t\t//\t+ dateFormat.format(Calendar.getInstance().getTime())));\n\t\t// set the product att in revisable entity child type\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTPRODUCT, product);\n\n\t\t//PLM-170 Adding product ID change\n\t\tString prodId = String.valueOf(((Double)product.getProductARevId()).intValue());\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTPRODUCTID, prodId);\n\t\t//PLM-170 Adding product ID change\n\n\t\t//System.out.println(\"****************Inside product ***********************\"+product);\n\n\t\t// setting the divison att for sap material. \n\t\t// This will drive the ACL functionality.\n\t\tString division = (String) season.getValue(divisionKey);\n\t\tLCSLog.debug(\"division -- \" + division);\n\t\t// setting division att in ibtRevEntityModel\n\t\tibtMaterialRevObj.setValue(\"lfDivision\", division);\n\n\t\t// set the colorway att in revisable entity child type\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTCOLORWAY, lcsSKu);\n\n\t\t// set the size definition version Id\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMASTERGRID, sizedefVR);\n\t\t// set the sourcing-config version\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSOURCINGCONFIG, sourceVersion);\n\t\t// set the cost-sheet version\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTCOSTSHEET, costsheetVersion);\n\t\t\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSPECIFICATION, specVersion);\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.STAGINSPECNAME, specName);\n\t\t// set the source name that is used in the staging area\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSTAGINGSOURCENAME, sourceName);\n\t\t// set the cost-sheet name to that is entered in staging area\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSTAGINGCOSTSHEETNAME, costName);\n\t\t//Added for 7.6\n\t\tif (FormatHelper.hasContent(LFIBTConstants.IBTMATERIALSTATUS)) {\n\t\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMATERIALSTATUS,\n\t\t\t\t\"Create\");\n\t\t}\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTCOSTSHEETSTATUS,\"Sent\");\n\t\t\n\t\t//Added for 7.6\n\t \t//Create BOM MOA Rows..\n\t\t//LFIBTUtil.setBOMMOARows(ibtRevEntityModel, \"lfIBTBOMDetails\", bomMOAStringColl,\"create\");\n\t\t// set the NRF code.\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTNRFCODE, nrfCode);\n\t\t// set style number\n\t\t// Build 6.14\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTSTYLENUMBER, styleNumber);\n\t\t// set material description\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMATERIALDESC,\n\t\t\t\tmaterialDescription);\n\n\t\t// set In strore Month\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTINSTOREMONTH, IBTINSTOREMONTH);\n\t\t// set SAP material number\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMATERIALNUMBER, materialNumber);\n\t\t// set the season att\n\t\tibtMaterialRevObj.setValue(LFIBTConstants.IBTMASTERSEASON, this.season);\n\n\t\t// set the boolean value to checked. This check is needed for the\n\t\t// plugin to pick up the revisable entity\n\t\t//ibtRevEntityModel.setValue(LFIBTConstants.IBTUPDATECHECK, Boolean.TRUE);\n\t\t// set the master object\n\t\tibtMaterialRevObj.setValue(\"lfIBTMaster\", this.masterRevEntity);\n\t\t\n\t//\tSystem.out.println(\"****************Inside 11111111 ***********************\");\n\n\t\t\n\t\t\n\t\tLCSRevisableEntity ibtMaterialRev = (LCSRevisableEntity)revisableEntityLogic.saveRevisableEntity(ibtMaterialRevObj);\n\t\t\n\t\t// masterModel.save();\n\t\t\n\t\t//createRevEntity=ibtRevEntityModel.getBusinessObject();\n\t\t//LCSLog.debug(\"slave created : -- \" + ibtMaterialRevObj);\n\t\t\n\t\tLCSLog.debug(CLASSNAME+\"createRevisableEntry(),Calling setBOMMOARows()\");\n\t\tLFIBTUtil.setBOMMOARows(ibtMaterialRev, \"lfIBTBOMDetails\", bomMOAStringColl, \"create\");\n\t\tLCSLog.debug(CLASSNAME+\"createRevisableEntry(),slave created : -- \" + ibtMaterialRev);\n return ibtMaterialRev;\n\t}",
"interface WithCreate extends DefinitionStages.WithNotes, DefinitionStages.WithOwners {\n /**\n * Executes the create request.\n *\n * @return the created resource.\n */\n ManagementLockObject create();\n\n /**\n * Executes the create request.\n *\n * @param context The context to associate with this operation.\n * @return the created resource.\n */\n ManagementLockObject create(Context context);\n }",
"Oracion createOracion();",
"VM createVM();",
"@Override\n\tpublic void agentSetup() {\n\n\t\t// load the class names of each object\n\t\tString os = dagent.getOfferingStrategy().getClassname();\n\t\tString as = dagent.getAcceptanceStrategy().getClassname();\n\t\tString om = dagent.getOpponentModel().getClassname();\n\t\tString oms = dagent.getOMStrategy().getClassname();\n\n\t\t// createFrom the actual objects using reflexion\n\n\t\tofferingStrategy = BOAagentRepository.getInstance().getOfferingStrategy(os);\n\t\tacceptConditions = BOAagentRepository.getInstance().getAcceptanceStrategy(as);\n\t\topponentModel = BOAagentRepository.getInstance().getOpponentModel(om);\n\t\tomStrategy = BOAagentRepository.getInstance().getOMStrategy(oms);\n\n\t\t// init the components.\n\t\ttry {\n\t\t\topponentModel.init(negotiationSession, dagent.getOpponentModel().getParameters());\n\t\t\topponentModel.setOpponentUtilitySpace(fNegotiation);\n\t\t\tomStrategy.init(negotiationSession, opponentModel, dagent.getOMStrategy().getParameters());\n\t\t\tofferingStrategy.init(negotiationSession, opponentModel, omStrategy,\n\t\t\t\t\tdagent.getOfferingStrategy().getParameters());\n\t\t\tacceptConditions.init(negotiationSession, offeringStrategy, opponentModel,\n\t\t\t\t\tdagent.getAcceptanceStrategy().getParameters());\n\t\t\tacceptConditions.setOpponentUtilitySpace(fNegotiation);\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t// remove the reference to the information object such that the garbage\n\t\t// collector can remove it.\n\t\tdagent = null;\n\t}",
"public ComputeInstanceVersion() {\n }",
"SpaceInvaderTest_test_VaisseauAvancePartiellement_DeplacerVaisseauVersLaDroite createSpaceInvaderTest_test_VaisseauAvancePartiellement_DeplacerVaisseauVersLaDroite();",
"Article createArticle();",
"protected abstract Object createObjectInternal(ObjectInformation objectInformation) throws FillingException;",
"abstract Object build();",
"@IID(\"{87B013CA-DE17-495F-B9D5-D8B7901FCB4D}\")\npublic interface IVersionedEntitiesFactory extends Com4jObject {\n // Methods:\n /**\n * <p>\n * For HP use. Returns the specified version of the item. Applies only to the Tests entity.\n * </p>\n * @param itemKey Mandatory java.lang.Object parameter.\n * @param versionNumber Mandatory int parameter.\n * @return Returns a value of type com4j.Com4jObject\n */\n\n @DISPID(1) //= 0x1. The runtime will prefer the VTID if present\n @VTID(7)\n @ReturnValue(type=NativeType.Dispatch)\n Com4jObject viewVersion(\n @MarshalAs(NativeType.VARIANT) Object itemKey,\n int versionNumber);\n\n\n /**\n * <p>\n * Returns the number of entities of the type managed by this factory that are checked out by the current user.\n * </p>\n * <p>\n * Getter method for the COM property \"CheckedOutEntitiesCount\"\n * </p>\n * @return Returns a value of type int\n */\n\n @DISPID(2) //= 0x2. The runtime will prefer the VTID if present\n @VTID(8)\n int checkedOutEntitiesCount();\n\n\n /**\n * <p>\n * For HP use. Multiple check-in of entities.\n * </p>\n * @param pList Mandatory DDDD.IList parameter.\n * @param comments Mandatory java.lang.String parameter.\n */\n\n @DISPID(3) //= 0x3. The runtime will prefer the VTID if present\n @VTID(9)\n void checkInEntities(\n IList pList,\n String comments);\n\n\n /**\n * <p>\n * For HP use. Multiple check out of entities.\n * </p>\n * @param pList Mandatory DDDD.IList parameter.\n * @param comments Mandatory java.lang.String parameter.\n */\n\n @DISPID(4) //= 0x4. The runtime will prefer the VTID if present\n @VTID(10)\n void checkOutEntities(\n IList pList,\n String comments);\n\n\n /**\n * <p>\n * For HP use. Multiple undo check out of entities.\n * </p>\n * @param pList Mandatory DDDD.IList parameter.\n */\n\n @DISPID(5) //= 0x5. The runtime will prefer the VTID if present\n @VTID(11)\n void undoCheckOutEntities(\n IList pList);\n\n\n // Properties:\n}",
"protected VendorCheck createVendorCheck() {\r\n VendorCheck vendorCheck = new VendorCheck();\r\n vendorCheck.setVendorCheckId(new Long(99999));\r\n return vendorCheck;\r\n }",
"public DetonationPdu(edu.nps.moves.jaxb.dis.DetonationPdu x)\n {\n super(x); // Call superclass constructor\n\n\n edu.nps.moves.dis.EntityID foo_0;\n if(x.getMunitionID() == null)\n foo_0 = new edu.nps.moves.dis.EntityID();\n else\n foo_0 = new edu.nps.moves.dis.EntityID(x.getMunitionID() );\n this.setMunitionID(foo_0);\n\n\n edu.nps.moves.dis.EventID foo_1;\n if(x.getEventID() == null)\n foo_1 = new edu.nps.moves.dis.EventID();\n else\n foo_1 = new edu.nps.moves.dis.EventID(x.getEventID() );\n this.setEventID(foo_1);\n\n\n edu.nps.moves.dis.Vector3Float foo_2;\n if(x.getVelocity() == null)\n foo_2 = new edu.nps.moves.dis.Vector3Float();\n else\n foo_2 = new edu.nps.moves.dis.Vector3Float(x.getVelocity() );\n this.setVelocity(foo_2);\n\n\n edu.nps.moves.dis.Vector3Double foo_3;\n if(x.getLocationInWorldCoordinates() == null)\n foo_3 = new edu.nps.moves.dis.Vector3Double();\n else\n foo_3 = new edu.nps.moves.dis.Vector3Double(x.getLocationInWorldCoordinates() );\n this.setLocationInWorldCoordinates(foo_3);\n\n\n edu.nps.moves.dis.BurstDescriptor foo_4;\n if(x.getBurstDescriptor() == null)\n foo_4 = new edu.nps.moves.dis.BurstDescriptor();\n else\n foo_4 = new edu.nps.moves.dis.BurstDescriptor(x.getBurstDescriptor() );\n this.setBurstDescriptor(foo_4);\n\n this.detonationResult = x.getDetonationResult();\n this.numberOfArticulationParameters = x.getNumberOfArticulationParameters();\n this.pad = x.getPad();\n this.articulationParameters = new ArrayList();\n for(int idx = 0; idx < x.getArticulationParameters().size(); idx++)\n {\n this.articulationParameters.add( new edu.nps.moves.dis.ArticulationParameter((edu.nps.moves.jaxb.dis.ArticulationParameter) x.getArticulationParameters().get(idx)));\n }\n }",
"SpaceInvaderTest_test_VaisseauAvance_DeplacerVaisseauVersLaDroite createSpaceInvaderTest_test_VaisseauAvance_DeplacerVaisseauVersLaDroite();",
"PriceCalculationModel createLease(Long customerId, DateTime leaseDate, List<MovieRentDetailsModel> movieRentDetailsModel, Long employeId);",
"protected CreateMachineNodeModel() {\r\n super(0,1);\r\n }",
"SpaceInvaderTest_VaisseauAvance_DeplacerVaisseauVersLaGauche createSpaceInvaderTest_VaisseauAvance_DeplacerVaisseauVersLaGauche();",
"public InternalDestinationEVO create(InternalDestinationEVO evo) throws Exception {\n\t internalDestinationEjb.ejbCreate(evo);\r\n\t InternalDestinationEVO newevo = internalDestinationEjb.getDetails(\"<UseLoadedEVOs>\");\r\n\t InternalDestinationPK pk = newevo.getPK();\r\n\t this.mLocals.put(pk, internalDestinationEjb);\r\n\t return newevo;\r\n }",
"SpaceInvaderTest_test_VaisseauImmobile_DeplacerVaisseauVersLaDroite createSpaceInvaderTest_test_VaisseauImmobile_DeplacerVaisseauVersLaDroite();",
"@SuppressWarnings(\"unchecked\")\n private void apply(LinkedEntityCreateParameters<BE, ME> params) {\n this.bukkitEntity = params.getBukkitEntity();\n this.chunk = bukkitEntity.getLocation().getChunk();\n final ME pMinecraftEntity = params.getMinecraftEntity();\n this.minecraftEntity = pMinecraftEntity == null ? (ME) NMSUtils.getMinecraftEntity(bukkitEntity)\n : pMinecraftEntity;\n }",
"Negacion createNegacion();",
"Active_Digital_Artifact createActive_Digital_Artifact();",
"@Override\n\tpublic void createRelease(Version version) {\n\n\t}",
"public MappedModelEVO create(MappedModelEVO evo) throws Exception {\n\t MappedModelPK local = this.server.ejbCreate(evo);\r\n MappedModelEVO newevo = this.server.getDetails(\"<UseLoadedEVOs>\");\r\n MappedModelPK pk = newevo.getPK();\r\n this.mLocals.put(pk, local);\r\n return newevo;\r\n }",
"public boolean create(ModelObject obj);",
"public static Edition createEntity(EntityManager em) {\n Edition edition = new Edition()\n .name(DEFAULT_NAME)\n .launchDate(DEFAULT_LAUNCH_DATE);\n return edition;\n }",
"public void createExpense(ExpenseBE expenseBE) {\n\n }",
"public void doExecute() {\n\t\tparent.requestChange(new ModelChangeRequest(this.getClass(), parent,\n\t\t\t\t\"create\") {\n\t\t\t@Override\n\t\t\tprotected void _execute() throws Exception {\n\t\t\t\ttry {\n\t\t\t\t\tCompositeEntity parentModel = (CompositeEntity) parent;\n\t\t\t\t\tString componentName = null;\n\t\t\t\t\tif (model == null) {\n\t\t\t\t\t\tcomponentName = ModelUtils.findUniqueName(parentModel,\n\t\t\t\t\t\t\t\t\t\t clazz,\n\t\t\t\t\t\t\t\t\t\t name.equalsIgnoreCase(\"INPUT\") ? DEFAULT_INPUT_PORT : DEFAULT_OUTPUT_PORT,\n\t\t\t\t\t\t\t\t\t\t name);\n\t\t\t\t\t\tcomponentName = ModelUtils.getLegalName(componentName);\n\t\t\t\t\t\tClass constructorClazz = CompositeEntity.class;\n\t\t\t\t\t\tif (clazz.getSimpleName().equals(\"TypedIOPort\")) {\n\t\t\t\t\t\t\tconstructorClazz = ComponentEntity.class;\n\t\t\t\t\t\t} else if (clazz.getSimpleName().equals(\n\t\t\t\t\t\t\t\t\"TextAttribute\")) {\n\t\t\t\t\t\t\tconstructorClazz = NamedObj.class;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (clazz.getSimpleName().equals(\"Vertex\")) {\n\t\t\t\t\t\t\tTypedIORelation rel = new TypedIORelation(\n\t\t\t\t\t\t\t\t\tparentModel, componentName);\n\t\t\t\t\t\t\tchild = new Vertex(rel, \"Vertex\");\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tConstructor constructor = clazz.getConstructor(\n\t\t\t\t\t\t\t\t\tconstructorClazz, String.class);\n\n\t\t\t\t\t\t\tchild = (NamedObj) constructor.newInstance(\n\t\t\t\t\t\t\t\t\tparentModel, componentName);\n\t\t\t\t\t\t\tif (child instanceof TypedIOPort) {\n\t\t\t\t\t\t\t\tboolean isInput = name\n\t\t\t\t\t\t\t\t\t\t.equalsIgnoreCase(\"INPUT\");\n\t\t\t\t\t\t\t\t((TypedIOPort) child).setInput(isInput);\n\t\t\t\t\t\t\t\t((TypedIOPort) child).setOutput(!isInput);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (model instanceof TypedIOPort) {\n\t\t\t\t\t\t\tname = ((TypedIOPort) model).isInput() ? DEFAULT_INPUT_PORT\n\t\t\t\t\t\t\t\t\t: DEFAULT_OUTPUT_PORT;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcomponentName = ModelUtils.findUniqueName(parentModel, model.getClass(), name, name);\n\t\t\t\t\t\tcomponentName = ModelUtils.getLegalName(componentName);\n\t\t\t\t\t\tif (model instanceof Vertex) {\n\t\t\t\t\t\t\tTypedIORelation rel = new TypedIORelation(\n\t\t\t\t\t\t\t\t\tparentModel, componentName);\n\t\t\t\t\t\t\tchild = new Vertex(rel, \"Vertex\");\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tchild = (NamedObj) model\n\t\t\t\t\t\t\t\t\t.clone(((CompositeEntity) parentModel)\n\t\t\t\t\t\t\t\t\t\t\t.workspace());\n\t\t\t\t\t\t\tchild.setName(componentName);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tComponentUtility.setContainer(child, parentModel);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tcreateDefaultValues(child);\n\t\t\t\t\t\n\t\t\t\t\tif (location != null) {\n\t\t\t\t\t\tModelUtils.setLocation(child, location);\n\t\t\t\t\t}\n\t\t\t\t\tsetChild(child);\n\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\tgetLogger().error(\"Unable to create component\", e);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t});\n\t}",
"LicenseUpdate create(LicenseUpdate newLicenseUpdate);",
"public JvnObject jvnCreateObject(Serializable o) throws jvn.JvnException { \n\t\t// to be completed \n\t\tJvnObject jObject = null;\n\t\ttry {\n\t\t\tjObject = new JvnObjectImpl(o, this.jRCoordonator.jvnGetObjectId());\n\t\t\tlistJObject.put(jObject.jvnGetObjectId(), jObject);\n\t\t\tSystem.out.println(\"jvnServerImpl - list Object Create: \" + listJObject.toString());\n\t\t} catch (RemoteException e) {\n\t\t\tSystem.out.println(\"Error creation object : \" + e.getMessage());\n\t\t}\n\t\treturn jObject;\n\t\t//return null; \n\t}",
"Instance createInstance();",
"public CustomEntitiesTaskParameters() {}",
"SpaceInvaderTest_initialisation createSpaceInvaderTest_initialisation();",
"SpaceInvaderTest_VaisseauImmobile_DeplacerVaisseauVersLaGauche createSpaceInvaderTest_VaisseauImmobile_DeplacerVaisseauVersLaGauche();",
"public M create(P model);",
"For createFor();",
"protected abstract T newObject(Handle<T> paramHandle);",
"public interface CreateProperty {\n /**\n * Give the list of properties in one kingdom for CalculatePropertyAttributes.feature and IdentifyProperties.feature without assigning it to any kingdom\n * @param kingdom the kingdom\n * @return the property list\n * @throws Exception null detection\n * @author AntonioShen\n */\n List<Property> givePropList(Kingdom kingdom) throws Exception;\n\n /**\n * Assign properties to one kingdom according to the property list for CalculatePropertyAttributes.feature and IdentifyProperties.feature\n * @param list the property list for the kingdom\n * @param kingdom the kingdom\n * @return true if succeed, false if failed\n * @throws Exception null detection\n * @author AntonioShen\n */\n boolean assignPropToKingdom(List<Property> list, Kingdom kingdom) throws Exception;\n}",
"@Override\r\n\tpublic boolean create(Moteur obj, Connection conn) throws SQLException {\n\t\treturn false;\r\n\t}",
"public Command create(Object... param);",
"public ExpertiseEntity() {\n }",
"VariantConditionModel createInstanceOfVariantConditionModel();",
"void create(Order order);",
"public MnjMfgFabinsProdLEOImpl() {\n }",
"CsticModel createInstanceOfCsticModel();",
"public MARealEstateBuildingVORowImpl() {\n }",
"public VersionManagementTest(String testName) throws IOException {\n \n super(testName);\n Logging.start(SetupUtils.DEBUG_LEVEL, SetupUtils.DEBUG_CATEGORIES);\n \n osdCfg = SetupUtils.createOSD1Config();\n capSecret = osdCfg.getCapabilitySecret();\n \n \n }",
"public void preMigration(Context context , String[]args) throws Exception\r\n {\r\n\t try {\r\n\t\t mqlLogRequiredInformationWriter(\"\\n\\n\");\r\n\t\t mqlLogRequiredInformationWriter(\"Inside PreMigration method to stamp the ids ----->\"+ \"\\n\");\r\n\t\t //loadResourceFile(context, \"emxConfigurationMigration\");\r\n\t\t mqlLogRequiredInformationWriter(\"Resource file loaded ------> emxConfigurationMigration.properties\");\r\n\t\t mqlLogRequiredInformationWriter(\"\\n\\n\");\r\n\r\n\t\t String strMqlCommandOff = \"trigger off\";\r\n\t\t MqlUtil.mqlCommand(context,strMqlCommandOff,true);\r\n\t\t mqlLogRequiredInformationWriter(\" 'trigger off' done at the start of preMigration \" + \"\\n\");\r\n\r\n\t\t IS_CONFLICT = false;\r\n\t\t StringBuffer sbRelPattern = new StringBuffer(50);\r\n\t\t sbRelPattern.append(ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_FROM);\r\n\t\t sbRelPattern.append(\",\");\r\n\t\t sbRelPattern.append(ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO);\r\n\t\t sbRelPattern.append(\",\");\r\n\t\t sbRelPattern.append(ConfigurationConstants.RELATIONSHIP_INACTIVE_FEATURE_LIST_FROM);\r\n\r\n\t\t StringBuffer sbTypePattern1 = new StringBuffer(50);\r\n\t\t sbTypePattern1.append(ConfigurationConstants.TYPE_FEATURES);\r\n\t\t sbTypePattern1.append(\",\");\r\n\t\t sbTypePattern1.append(ConfigurationConstants.TYPE_FEATURE_LIST);\r\n\t\t sbTypePattern1.append(\",\");\r\n\t\t sbTypePattern1.append(ConfigurationConstants.TYPE_PRODUCTS);\r\n\r\n\t\t emxVariantConfigurationIntermediateObjectMigration_mxJPO jpoInst= new emxVariantConfigurationIntermediateObjectMigration_mxJPO(context, new String[0]);\r\n\t\t StringList slDerivationChangedType1 = jpoInst.getDerivationChangedType(context,new String[0]);\r\n\t\t for(int i=0;i<slDerivationChangedType1.size();i++){\r\n\t\t\t sbTypePattern1.append(\",\");\r\n\t\t\t sbTypePattern1.append(slDerivationChangedType1.get(i));\r\n }\r\n\r\n\t\t StringList fsObjSelects = new StringList();\r\n\t\t fsObjSelects.addElement(SELECT_ID);\r\n\t\t fsObjSelects.addElement(SELECT_TYPE);\r\n\t\t fsObjSelects.addElement(SELECT_NAME);\r\n\t\t fsObjSelects.addElement(SELECT_REVISION);\r\n\t\t fsObjSelects.addElement(SELECT_LEVEL);\r\n\t\t fsObjSelects.addElement(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE + \"]\");\r\n\t\t fsObjSelects.addElement(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_SUBFEATURECOUNT + \"]\");\r\n\t\t fsObjSelects.addElement(\"from[\"+ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+\"].to.type\");\r\n\t\t fsObjSelects.addElement(\"from[\"+ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+\"].to.id\");\r\n\t\t fsObjSelects.addElement(\"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+ \"].from.attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE + \"]\");\r\n\r\n\t\t //Added to check for GBOM connection if any\r\n\t\t fsObjSelects.addElement(\"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\");\r\n\t\t fsObjSelects.addElement(\"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_TO+\"].to.id\");\r\n\r\n\r\n\t\t StringBuffer sbRelPattern1 = new StringBuffer(50);\r\n\t\t sbRelPattern1.append(ConfigurationConstants.RELATIONSHIP_GBOM);\r\n\t\t sbRelPattern1.append(\",\");\r\n\t\t sbRelPattern1.append(ConfigurationConstants.RELATIONSHIP_GBOM_FROM);\r\n\t\t sbRelPattern1.append(\",\");\r\n\t\t sbRelPattern1.append(ConfigurationConstants.RELATIONSHIP_INACTIVE_GBOM);\r\n\t\t sbRelPattern1.append(\",\");\r\n\t\t sbRelPattern1.append(ConfigurationConstants.RELATIONSHIP_CUSTOM_GBOM);\r\n\t\t sbRelPattern1.append(\",\");\r\n\t\t sbRelPattern1.append(ConfigurationConstants.RELATIONSHIP_VARIES_BY);\r\n\t\t sbRelPattern1.append(\",\");\r\n\t\t sbRelPattern1.append(ConfigurationConstants.RELATIONSHIP_INACTIVE_VARIES_BY);\r\n\t\t sbRelPattern1.append(\",\");\r\n\t\t sbRelPattern1.append(RELATIONSHIP_MANAGED_SERIES);\r\n\t\t sbRelPattern1.append(\",\");\r\n\t\t sbRelPattern1.append(ConfigurationConstants.RELATIONSHIP_QUANTITY_RULE);\r\n\r\n\t\t StringBuffer sbTypePattern2 = new StringBuffer(50);\r\n\t\t sbTypePattern2.append(ConfigurationConstants.TYPE_GBOM);\r\n\t\t sbTypePattern2.append(\",\");\r\n\t\t sbTypePattern2.append(ConfigurationConstants.TYPE_FEATURES);\r\n\t\t sbTypePattern2.append(\",\");\r\n\t\t sbTypePattern2.append(ConfigurationConstants.TYPE_QUANTITY_RULE);\r\n\t\t sbTypePattern2.append(\",\");\r\n\t\t sbTypePattern2.append(ConfigurationConstants.TYPE_MASTER_FEATURE);\r\n\r\n\r\n\t\t warningLog = new FileWriter(documentDirectory + \"migration.log\", true);\r\n\r\n\r\n\t\t documentDirectory = args[0];\r\n\t\t String fileSeparator = java.io.File.separator;\r\n\t\t if(documentDirectory != null && !documentDirectory.endsWith(fileSeparator)){\r\n\t\t\t documentDirectory = documentDirectory + fileSeparator;\r\n\t\t }\r\n\r\n\r\n\t\t if(args.length > 3){\r\n\r\n\t\t\t RESOLVE_CONFLICTS = args[3];\r\n\t\t\t mqlLogRequiredInformationWriter( \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"This step will also resolve the conflicts related \"\r\n \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"to 'Mixed Composition' and 'Malformed GBOM/Feature List' Object ids\"\r\n \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"at the end of the step, \"\r\n \t\t\t\t\t\t + \" if present.\"\r\n \t\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"NOTE : User has to resolve the conflicts related \"\r\n\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"to 'Mixed Usage' and 'Incorrect Mapping' related Object ids\"\r\n\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"at the end of the step, \"\r\n\t\t\t\t\t \t\t\t\t\t\t + \" if present.\"\r\n \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"\\n\");\r\n\r\n\t\t }else{\r\n\r\n\t\t\t mqlLogRequiredInformationWriter( \"\\n\"\r\n\t\t\t\t\t\t \t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t\t \t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t\t \t\t\t\t\t + \"This step will resolve the conflicts related \"\r\n \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"to 'Malformed GBOM/Feature List' Object ids\"\r\n \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"at the end of the step, \"\r\n \t\t\t\t\t\t + \" if present.\"\r\n \t\t\t\t\t\t + \"\\n\"\r\n \t\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t\t \t\t\t\t\t + \"NOTE : User has to resolve the conflicts related \"\r\n\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"to 'Mixed Composition','Mixed Usage' and 'Incorrect Mapping' related Object ids\"\r\n\t\t\t\t\t + \"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"at the end of the step, \"\r\n\t\t\t\t\t \t\t\t\t\t\t + \" if present.\"\r\n\t\t\t\t\t\t\t\t\t\t\t +\"\\n\"\r\n\t\t\t\t\t\t\t\t\t\t\t +\"\\n\"\r\n\t\t\t\t\t\t\t\t\t\t\t +\"\\n\");\r\n\t\t }\r\n\r\n\t\t\t String strMinRange = args[1].toString();\r\n\t\t\t minRange = Integer.parseInt(strMinRange);\r\n\t\t\t if (\"n\".equalsIgnoreCase(args[2])){\r\n\t\t\t\t maxRange = getTotalFilesInDirectory();\r\n\t\t\t } else {\r\n\t\t\t\t maxRange = Integer.parseInt(args[2]);\r\n\t\t\t }\r\n\r\n\t\t\t // Execute schema changes needed for migration\r\n\t\t\t //we should only call this once the first time the Find Objects Pre Migration is called.\r\n\t\t\t //If In process of PreMigration, do not call again\r\n\t\t\t int migrationStatus = getAdminMigrationStatus(context);\r\n\t\t\t mqlLogRequiredInformationWriter(\"If Migration Status is -------> 0 \"\r\n\t\t\t\t\t \t\t\t\t\t\t +\"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"'VariantConfigurationR212SchemaChangesForMigration.tcl' will be executed.\"+\"\\n\\n\");\r\n\r\n\t\t\t mqlLogRequiredInformationWriter(\"If Migration Status is ------->'PreMigrationInProcess' \"\r\n\t\t\t\t\t \t\t\t\t\t\t +\"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"'VariantConfigurationR212SchemaChangesForMigration.tcl' will not be executed\"\r\n\t\t\t \t\t\t\t\t\t\t\t +\"\\n\"\r\n\t\t\t \t\t\t\t\t\t\t\t + \"as this TCL is already executed\"+\"\\n\\n\");\r\n\r\n\t\t\t mqlLogRequiredInformationWriter(\"If Migration Status is ------->'PreMigrationComplete' \"\r\n\t\t\t\t\t \t\t\t\t\t\t +\"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"Pre Migration step is done.\"\r\n\t\t\t\t\t \t\t\t\t\t\t +\"\\n\"\r\n\t\t\t\t\t \t\t\t\t\t\t + \"Please execute the next step to continue with Migration.\"\r\n\t\t\t\t\t \t\t\t\t\t\t +\"\\n\\n\");\r\n\r\n\t\t\t mqlLogRequiredInformationWriter(\"Now the Migration Status is \"+ migrationStatus +\"\\n\\n\");\r\n\r\n\t\t\t if(migrationStatus == 0){\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"'VariantConfigurationR212SchemaChangesForMigration.tcl' execution started...\" + \"\\n\\n\");\r\n\t\t\t\t String cmdString = \"execute program VariantConfigurationR212SchemaChangesForMigration.tcl\";\r\n\t\t\t\t ContextUtil.pushContext(context);\r\n\t\t\t\t MqlUtil.mqlCommand(context, cmdString);\r\n\r\n\t\t\t\t //${CLASS:emxAdminCache}.reloadSymbolicName(context, \"type_ConfigurationFeature\");\r\n\r\n\t\t\t\t TYPE_CONFIGURATION_FEATURE = getSchemaProperty(context, \"type_ConfigurationFeature\");\r\n\r\n\t\t\t\t ContextUtil.popContext(context);\r\n\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"\\n\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"'VariantConfigurationR212SchemaChangesForMigration.tcl' execution is done...\"+ \"\\n\");\r\n\t\t\t }\r\n\t\t\t //------------------------------------------------\r\n\t\t\t //Now to read the files\r\n\t\t\t //------------------------------------------------\r\n\t\t\t int m = 0;\r\n\t\t\t for( m = minRange;m <= maxRange; m++){\r\n\t\t\t\t StringList objectList = new StringList();\r\n\t\t\t\t try{\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\"\\n\");\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\"Pre-migration in process for objects in objectids_\"+ m +\".txt file. \\n\\n\");\r\n\r\n\t\t\t\t\t //setting admin property MigrationR212VariantConfiguration in eServiceSystemInformation.tcl\r\n\t\t\t\t\t setAdminMigrationStatus(context,\"PreMigrationInProcess\");\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\"Migration Status set to value ----->\"+ \"'PreMigrationInProcess'\" +\"\\n\\n\");\r\n\r\n\t\t\t\t\t objectList = readFiles(m);\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\"objectids_\"+ m +\".txt file traversal started \" + \"\\n\\n\");\r\n\t\t\t\t\t for(int iCntObjList=0 ;iCntObjList<objectList.size();iCntObjList++){\r\n\t\t\t\t\t\t String topLevelObjectId = (String)objectList.get(iCntObjList);\r\n\r\n\t\t\t\t\t\t String topLevelObjectType =\"\";\r\n\t\t\t\t\t\t DomainObject domTopLevelObject = DomainObject.newInstance(context, topLevelObjectId);\r\n\r\n\t\t\t\t\t\t //mqlLogRequiredInformationWriter(\"topLevelObjectType------------\"+ topLevelObjectType + \"\\n\");\r\n\t\t\t\t\t\t //topLevelObjectType = domTopLevelObject.getInfo(context, ConfigurationConstants.SELECT_TYPE);\r\n\t\t\t\t\t\t Map htTopLevelObjData = (Map) domTopLevelObject.getInfo(context, fsObjSelects);\r\n\t\t\t\t\t\t topLevelObjectType = (String)htTopLevelObjData.get(ConfigurationConstants.SELECT_TYPE);\r\n\t\t\t\t\t\t String topLevelObjectName= (String)htTopLevelObjData.get(ConfigurationConstants.SELECT_NAME);\r\n\t\t\t\t\t\t String topLevelObjectRevision = (String)htTopLevelObjData.get(ConfigurationConstants.SELECT_REVISION);\r\n\t\t\t\t\t\t Integer iCnt;\r\n\t\t\t\t\t\t iCnt= iCntObjList+1;\r\n\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"------------------------------------------------------------------------------------------------------------------------\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Stamping of objects for below Top level object's structure started----->\"+\" --- \"+now()+\"\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Object Count in text file ----->\"+iCnt+\"\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Top level object Id ----------->\"+topLevelObjectId+\"\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Top level object Type --------->\"+topLevelObjectType+\"\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Top level object Name --------->\"+topLevelObjectName+\"\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Top level object Revision ----->\"+topLevelObjectRevision+\"\\n\");\r\n\r\n\t\t\t\t\t\t //mqlLogRequiredInformationWriter(\"------------------------------------------------------------\\n\");\r\n\t\t\t\t\t\t //Check if \"GBOM\" object is connected to Configuration Feature or Configuration Option\r\n\t\t\t\t\t\t //DomainObject domFeatObj = new DomainObject(strFeatureId);\r\n\t\t\t\t\t\t StringList TopLevelfeatureObjSelects = new StringList();\r\n\t\t\t\t\t\t TopLevelfeatureObjSelects.addElement(SELECT_TYPE);\r\n\t\t\t\t\t\t TopLevelfeatureObjSelects.addElement(SELECT_NAME);\r\n\t\t\t\t\t\t TopLevelfeatureObjSelects.addElement(SELECT_REVISION);\r\n\t\t\t\t\t\t TopLevelfeatureObjSelects.addElement(\"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\");\r\n\r\n\t\t\t\t\t\t DomainConstants.MULTI_VALUE_LIST.add(\"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\");\r\n\t\t\t\t\t\t DomainConstants.MULTI_VALUE_LIST.remove(\"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\");\r\n\r\n\t\t\t\t\t\t //topLevelObjectType = domTopLevelObject.getInfo(context, ConfigurationConstants.SELECT_TYPE);\r\n\t\t\t\t\t\t topLevelObjectType = (String)htTopLevelObjData.get(SELECT_TYPE);\r\n\r\n\t\t\t\t\t\t\t StringList sLTopLevelGBOMIds = new StringList();\r\n\r\n\t\t\t\t\t\t\t String TopLevelGBOMSelect = \"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\";\r\n\t\t\t\t\t\t\t Object objTopLevelGBOMId = htTopLevelObjData.get(TopLevelGBOMSelect);\r\n\r\n\t\t\t\t\t\t\t if (objTopLevelGBOMId instanceof StringList) {\r\n\t\t\t\t\t\t\t\t sLTopLevelGBOMIds = (StringList) htTopLevelObjData.get(TopLevelGBOMSelect);\r\n\t\t\t\t\t\t\t } else if (objTopLevelGBOMId instanceof String) {\r\n\t\t\t\t\t\t\t\t sLTopLevelGBOMIds.addElement((String) htTopLevelObjData.get(TopLevelGBOMSelect));\r\n\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t emxVariantConfigurationIntermediateObjectMigration_mxJPO VariantConfigInterObjMigrationInst= new emxVariantConfigurationIntermediateObjectMigration_mxJPO(context, new String[0]);\r\n\t\t\t\t\t\t StringList slDerivationChangedType = VariantConfigInterObjMigrationInst.getDerivationChangedType(context,new String[0]);\r\n\r\n\r\n\t StringBuffer sbWhereClause = new StringBuffer(50);\r\n\t\tsbWhereClause.append(\"((\");\r\n\t\tsbWhereClause.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_FROM+ \"].from.type.kindof != \\\"\" + ConfigurationConstants.TYPE_PRODUCTS + \"\\\"\");\r\n\t\tsbWhereClause.append(\")||(\");\r\n\t\tsbWhereClause.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_INACTIVE_FEATURE_LIST_FROM+ \"].from.type.kindof != \\\"\" + ConfigurationConstants.TYPE_PRODUCTS + \"\\\"\");\r\n\t\tsbWhereClause.append(\"))||\");\r\n\t\tsbWhereClause.append(\"((\");\r\n\t\tsbWhereClause.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_FROM+ \"].from.type.kindof == \\\"\" + ConfigurationConstants.TYPE_PRODUCTS + \"\\\"\");\r\n\t\tsbWhereClause.append(\"&&\");\r\n\t\tsbWhereClause.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_FROM+ \"].from.id == \"+topLevelObjectId +\"\");\r\n\t\tsbWhereClause.append(\")||(\");\r\n\t\tsbWhereClause.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_INACTIVE_FEATURE_LIST_FROM+ \"].from.type.kindof == \\\"\" + ConfigurationConstants.TYPE_PRODUCTS + \"\\\"\");\r\n\t\tsbWhereClause.append(\"&&\");\r\n\t\tsbWhereClause.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_INACTIVE_FEATURE_LIST_FROM+ \"].from.id == \"+topLevelObjectId +\"\");\r\n\t\tsbWhereClause.append(\")\");\r\n\t\tsbWhereClause.append(\")\");\r\n\r\n\t\t\t\t\t\t\tStringBuffer sbObjWhere = new StringBuffer(50);\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"(\");\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"type.kindof == \\\"\" + ConfigurationConstants.TYPE_FEATURES + \"\\\"\");\r\n\t\t\t\t\t\t\tfor(int i=0;i<slDerivationChangedType.size();i++){\r\n\t\t\t\t\t\t\t\tsbObjWhere.append(\"||\");\r\n\t\t\t\t \t\t\tsbObjWhere.append(\"type == \\\"\" + slDerivationChangedType.get(i).toString() + \"\\\"\");\r\n\t\t\t\t }\r\n\t\t\t\t\t\t\tsbObjWhere.append(\")\");\r\n\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"||\");\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"type.kindof == \\\"\" + ConfigurationConstants.TYPE_PRODUCTS + \"\\\"\");\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"||\");\r\n\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"(\");\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"type == \\\"\" + ConfigurationConstants.TYPE_FEATURE_LIST + \"\\\"\");\r\n\t\t\t\t\t\t\tsbObjWhere.append(\"&&\");\r\n\t\t\t\t\t\t\tsbObjWhere.append(sbWhereClause);\r\n\t\t\t\t\t\t\tsbObjWhere.append(\")\");\r\n\r\n\r\n\t\t\t\t\t\t\tDomainConstants.MULTI_VALUE_LIST.add(\"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\");\r\n\r\n\t\t\t\t\t\t //mqlLogRequiredInformationWriter(\"------------------------------------------------------------\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Query to get the Top level object structure started ------------>\"+\" --- \"+ now() +\"\\n\");\r\n\r\n\t\t\t\t\t\t MapList featureStructureList = domTopLevelObject.getRelatedObjects(context,\r\n\t\t\t\t\t\t\t\t sbRelPattern.toString(), // relationshipPattern\r\n\t\t\t\t\t\t\t\t sbTypePattern1.toString(), // typePattern\r\n\t\t\t\t\t\t\t\t fsObjSelects, // objectSelects\r\n\t\t\t\t\t\t\t\t null, // relationshipSelects\r\n\t\t\t\t\t\t\t\t false, // getTo\r\n\t\t\t\t\t\t\t\t true, // getFrom\r\n\t\t\t\t\t\t\t\t (short) 0, // recurseToLevel\r\n\t\t\t\t\t\t\t\t sbObjWhere.toString(), // objectWhere,\r\n\t\t\t\t\t\t\t\t null, // relationshipWhere\r\n\t\t\t\t\t\t\t\t (int)0); // limit\r\n\r\n\t\t\t\t\t\t DomainConstants.MULTI_VALUE_LIST.remove(\"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Query to get the Top level object structure ended ------------>\"+\" --- \"+ now() +\"\\n\");\r\n\t\t\t\t\t\t //mqlLogRequiredInformationWriter(\"------------------------------------------------------------\\n\\n\\n\");\r\n\r\n\t\t\t\t\t\t String strNewFeatureType = \"\";\r\n\t\t\t\t\t\t String strResolvedNewFeatureType= \"\";\r\n\r\n\t\t\t\t\t\t // use case for standalone features\r\n\t\t\t\t\t\t if (featureStructureList.size() == 0){\r\n\r\n\t\t\t\t\t\t //mqlLogRequiredInformationWriter(\"------------------------------------------------------------\\n\");\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\" This Top level object structure doesn't have 'Feature List From' and 'Feature List To' connections \"+\"\\n\");\r\n\t\t\t\t\t //mqlLogRequiredInformationWriter(\" Check if this feature has 'Design Variants'or 'GBOM' or 'Managed Series' or 'Quantity Rules' connected \"+\"\\n\");\r\n\t\t\t\t\t //mqlLogRequiredInformationWriter(\" If 'Yes' then stamp this Feature as 'type_LogicalFeature'\"+\"\\n\");\r\n\t\t\t\t\t //mqlLogRequiredInformationWriter(\" If 'No' then check for the property setting for this Feature \"+\"\\n\");\r\n\t\t\t\t\t //mqlLogRequiredInformationWriter(\" If property setting not found for the given type..Check for Parent Type and then set the Type \"+\"\\n\\n\\n\");\r\n\r\n\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\"Query to check for 'Design Variants' or 'GBOM' or 'Managed Series' or 'Quantity Rules' connections started ------------>\"+\" --- \"+ now() +\"\\n\");\r\n\t\t\t\t\t\t MapList LF_RelatedList = domTopLevelObject.getRelatedObjects(context,\r\n\t\t\t\t\t\t\t\t\t sbRelPattern1.toString(), // relationshipPattern\r\n\t\t\t\t\t\t\t\t\t sbTypePattern2.toString(), // typePattern\r\n\t\t\t\t\t\t\t\t\t null, // objectSelects\r\n\t\t\t\t\t\t\t\t\t null, // relationshipSelects\r\n\t\t\t\t\t\t\t\t\t true, // getTo\r\n\t\t\t\t\t\t\t\t\t true, // getFrom\r\n\t\t\t\t\t\t\t\t\t (short) 1, // recurseToLevel\r\n\t\t\t\t\t\t\t\t\t null, // objectWhere,\r\n\t\t\t\t\t\t\t\t\t null, // relationshipWhere\r\n\t\t\t\t\t\t\t\t\t (int) 0); // limit\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Query to check for 'Design Variants' or 'GBOM' or 'Managed Series' or 'Quantity Rules' connections ended ------------>\"+\" --- \"+ now() +\"\\n\");\r\n\r\n\r\n\t\t\t\t\t\t\t // if feature has DVs or GBOM or Managed Series or Quantity Rules, it should be stamped as Logical\r\n\t\t\t\t\t\t\t if (!LF_RelatedList.isEmpty()) {\r\n\r\n\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"This Top level object has 'Design Variants' or 'GBOM' or 'Managed Series' or 'Quantity Rules' connections'\"+\"\\n\");\r\n\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Hence stamp this Feature as attribute ---> NewFeatureType=type_LogicalFeature \"+\"\\n\");\r\n\t\t\t\t\t\t\t\t //strNewFeatureType = getResourceProperty(context,\"emxConfiguration.Migration.TechnicalFeatureType\");\r\n\t\t\t\t\t\t\t\t strNewFeatureType = EnoviaResourceBundle.getProperty(context, \"emxConfigurationMigration\", Locale.US, \"emxConfiguration.Migration.TechnicalFeatureType\");\r\n\t\t\t\t\t\t\t\t stampFeature(context,topLevelObjectId,strNewFeatureType,\"\",EMPTY_STRINGLIST);\r\n\r\n\t\t\t\t\t\t\t } else {\r\n\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"This Top level object doesn't have the 'Design Variants' or 'GBOM' or 'Managed Series' or 'Quantity Rules' connections'\"+\"\\n\");\r\n\t\t\t\t\t\t\t\t if(topLevelObjectType!=null\r\n\t\t\t\t\t\t\t\t\t\t && !topLevelObjectType.equalsIgnoreCase(ConfigurationConstants.TYPE_PRODUCT_LINE)\r\n\t\t\t\t\t\t\t\t\t\t && !topLevelObjectType.equalsIgnoreCase(ConfigurationConstants.TYPE_GBOM)\r\n\t\t\t\t\t\t\t\t\t\t && !mxType.isOfParentType(context, topLevelObjectType,ConfigurationConstants.TYPE_PRODUCTS)){\r\n\t\t\t\t\t\t\t\t\t\t //&& !isOfDerivationChangedType(context,topLevelObjectType)){\r\n\r\n\t\t\t\t\t\t\t\t\t String strSymbolicType = FrameworkUtil.getAliasForAdmin(context,DomainConstants.SELECT_TYPE, topLevelObjectType, true);\r\n\t\t\t\t\t\t\t\t\t try{\r\n\t\t\t\t\t\t\t\t\t\t //strNewFeatureType = getResourceProperty(context,\"emxConfiguration.Migration.\"+strSymbolicType);\r\n\t\t\t\t\t\t\t\t\t\t strNewFeatureType = EnoviaResourceBundle.getProperty(context, \"emxConfigurationMigration\", Locale.US, \"emxConfiguration.Migration.\"+strSymbolicType);\r\n\t\t\t\t\t\t\t\t\t }catch (Exception e){\r\n\t\t\t\t\t\t\t\t\t\t //If property setting not found for the given type..Check for Parent Type and then set the Type\r\n\t\t\t\t\t\t\t\t\t\t String strParentType = UICache.getParentTypeName(context,topLevelObjectType);\r\n\t\t\t\t\t\t\t\t\t\t String strParSymbolicType = FrameworkUtil.getAliasForAdmin(context,DomainConstants.SELECT_TYPE, strParentType, true);\r\n\t\t\t\t\t\t\t\t\t\t //strNewFeatureType = getResourceProperty(context,\"emxConfiguration.Migration.\"+strParSymbolicType);\r\n\t\t\t\t\t\t\t\t\t\t strNewFeatureType = EnoviaResourceBundle.getProperty(context, \"emxConfigurationMigration\", Locale.US, \"emxConfiguration.Migration.\"+strParSymbolicType);\r\n\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t // stamping the features\r\n\t\t\t\t\t\t\t\t\t stampFeature(context,topLevelObjectId,strNewFeatureType,\"\",EMPTY_STRINGLIST);\r\n\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t }else{ // usecase for structures\r\n\r\n\t\t\t\t\t\t\t boolean isMixedUsage = false;\r\n\t\t\t\t\t\t\t boolean isMixedComposition = false;\r\n\t\t\t\t\t\t\t String referenceContextUsage=\"\";\r\n\r\n\t\t\t\t\t\t\t StringList featureTypesList = new StringList();\r\n\t\t\t\t\t\t\t // if toplevelobject is feature\r\n\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Top level object is of Type :: \"+ topLevelObjectType +\"\\n\");\r\n\r\n\t\t\t\t\t\t\t if (mxType.isOfParentType(context, topLevelObjectType,ConfigurationConstants.TYPE_FEATURES)\r\n\t\t\t\t\t\t\t\t\t || isOfDerivationChangedType(context, topLevelObjectType)){\r\n\t\t\t\t\t\t\t\t // check for mixed usage\r\n\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tCode to check Mixed Usage starts \"+ \"\\n\");\r\n\r\n\t\t\t\t\t\t\t\t StringList allFeatureTypesList = new StringList();\r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tList of Features where this Toplevel Object is used. \"+ featureStructureList.size() +\"\\n\");\r\n\t\t\t\t\t\t\t\t outer: for (int j = 0; j < featureStructureList.size(); j++){\r\n\r\n\t\t\t\t\t\t\t\t\t Map fsMap = new HashMap();\r\n\r\n\t\t\t\t\t\t\t\t\t fsMap = (Map) featureStructureList.get(j);\r\n\r\n\t\t\t\t\t\t\t\t\t String strObjectType = (String) fsMap.get(SELECT_TYPE);\r\n\t\t\t\t\t\t\t\t\t referenceContextUsage = (String) fsMap.get(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\");\r\n\r\n\t\t\t\t\t\t\t\t\t if(mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_FEATURES)\r\n\t\t\t\t\t\t\t\t\t\t\t || mxType.isOfParentType(context,strObjectType, ConfigurationConstants.TYPE_PRODUCTS)\r\n\t\t\t\t\t\t\t\t\t\t\t || isOfDerivationChangedType(context, strObjectType)){\r\n\r\n\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tObject Type. \"+ strObjectType +\"\\n\");\r\n\r\n\t\t\t\t\t\t\t\t\t\t String featureTypeSelect = \"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+ \"].from.attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\";\r\n\t\t\t\t\t\t\t\t\t\t Object objFeatureTypes = fsMap.get(featureTypeSelect);\r\n\t\t\t\t\t\t\t\t\t\t featureTypesList.clear();\r\n\r\n\t\t\t\t\t\t\t\t\t\t if (objFeatureTypes instanceof StringList) {\r\n\t\t\t\t\t\t\t\t\t\t\t featureTypesList = (StringList) fsMap.get(featureTypeSelect);\r\n\t\t\t\t\t\t\t\t\t\t } else if (objFeatureTypes instanceof String) {\r\n\t\t\t\t\t\t\t\t\t\t\t featureTypesList.addElement((String) fsMap.get(featureTypeSelect));\r\n\t\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tList of 'Feature Type' attribute values of connected 'Feature List' objects. \"+ featureTypesList +\"\\n\");\r\n\r\n\t\t\t\t\t\t\t\t\t\t if (featureTypesList.size() > 0){\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t for (int k = 0; k < featureTypesList.size(); k++){\r\n\t\t\t\t\t\t\t\t\t\t\t\t String strFeatureType = (String) featureTypesList.get(k);\r\n\t\t\t\t\t\t\t\t\t\t\t\t if (!strFeatureType.equals((String) featureTypesList.get(0))){\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"As the above list is not consisitent Feature will be marked as 'MixedUsage'.\"+\"\\n\");\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t isMixedUsage = true;\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"MixedUsage\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t break outer;\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tCode to check Mixed Usage ends \"+ \"\\n\\n\");\r\n\r\n\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tCode to check Mixed Composition starts \"+ \"\\n\");\r\n\r\n\t\t\t\t\t\t\t\t\t // check for mixed composition\r\n\t\t\t\t\t\t\t\t\t if (!isMixedUsage) {\r\n\t\t\t\t\t\t\t\t\t\t if (mxType.isOfParentType(context,strObjectType, ConfigurationConstants.TYPE_FEATURE_LIST)) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t String strFeatureType = (String) fsMap.get(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\");\r\n\t\t\t\t\t\t\t\t\t\t\t allFeatureTypesList.addElement(strFeatureType);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\t\tList of 'Feature Type' attribute values of connected 'Feature List' objects. \"+ allFeatureTypesList +\"\\n\");\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t if(!strFeatureType.equals(allFeatureTypesList.get(0))) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"As the above list is not consisitent Feature will be marked as 'MixedComposition'.\"+\"\\n\");\r\n\t\t\t\t\t\t\t\t\t\t\t\t isMixedComposition = true;\r\n\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"MixedComposition\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t break outer;\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tCode to check Mixed Composition ends \"+ \"\\n\\n\");\r\n\r\n\t\t\t\t\t\t\t\t\t //Code to check the \"Feature List\" attribute \"Feature Type\" is correctly mapped against the Type\r\n\t\t\t\t\t\t\t\t\t //Check for incorrect mapping\r\n\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\tCode to check Incorrect Mapping starts \"+ \"\\n\");\r\n\t\t\t\t\t\t\t\t\t\tif (!isMixedUsage\r\n\t\t\t\t\t\t\t\t\t\t\t\t&& !isMixedComposition\r\n\t\t\t\t\t\t\t\t\t\t\t\t&& !mxType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.isOfParentType(\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcontext,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrObjectType,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tConfigurationConstants.TYPE_FEATURES)\r\n\t\t\t\t\t\t\t\t\t\t\t\t&& !mxType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.isOfParentType(\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcontext,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrObjectType,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tConfigurationConstants.TYPE_FEATURE_LIST)\r\n\t\t\t\t\t\t\t\t\t\t\t\t&& !mxType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.isOfParentType(\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcontext,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrObjectType,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tConfigurationConstants.TYPE_PRODUCTS)) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t //Check for incorrect mapping\r\n\t\t\t\t\t\t\t\t\t\t String strFeatureType = (String) fsMap.get(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\");\r\n\t\t\t\t\t\t\t\t\t\t if (strFeatureType.equalsIgnoreCase(ConfigurationConstants.RANGE_VALUE_TECHNICAL)) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t if(!mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_LOGICAL_STRUCTURES)){\r\n\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"IncorrectMapping\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t break outer;\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t\t }else if(strFeatureType.equalsIgnoreCase(ConfigurationConstants.RANGE_VALUE_MARKETING)) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t if(!mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_CONFIGURATION_FEATURES)){\r\n\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"IncorrectMapping\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t break outer;\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t\tmqlLogRequiredInformationWriter(\"\tCode to check Incorrect Mapping ends \"+ \"\\n\\n\");\r\n\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t // stamp the structure including topLevelObject.\r\n\r\n\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Stamp starts \"+ \"\\n\");\r\n\r\n\t\t\t\t\t\t\t\t for (int j = 0; j < featureStructureList.size(); j++) {\r\n\t\t\t\t\t\t\t\t\t Map fsMap = (Map) featureStructureList.get(j);\r\n\r\n\t\t\t\t\t\t\t\t\t StringList sLGBOMIds = new StringList();\r\n\r\n\t\t\t\t\t\t\t\t\t String GBOMSelect = \"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\";\r\n\t\t\t\t\t\t\t\t\t Object objGBOMType = fsMap.get(GBOMSelect);\r\n\r\n\t\t\t\t\t\t\t\t\t if (objGBOMType instanceof StringList) {\r\n\t\t\t\t\t\t\t\t\t\t sLGBOMIds = (StringList) fsMap.get(GBOMSelect);\r\n\t\t\t\t\t\t\t\t\t } else if (objGBOMType instanceof String) {\r\n\t\t\t\t\t\t\t\t\t\t sLGBOMIds.addElement((String) fsMap.get(GBOMSelect));\r\n\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t String strObjectId = (String) fsMap.get(SELECT_ID);\r\n\t\t\t\t\t\t\t\t\t String strObjectType = (String) fsMap.get(SELECT_TYPE);\r\n\t\t\t\t\t\t\t\t\t boolean isLeafLevel = false;\r\n\r\n\t\t\t\t\t\t\t\t\t if(mxType.isOfParentType(context,strObjectType,ConfigurationConstants.TYPE_FEATURES)){\r\n\t\t\t\t\t\t\t\t\t\t int subFeatureCount = Integer.parseInt((String) fsMap.get(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_SUBFEATURECOUNT + \"]\"));\r\n\t\t\t\t\t\t\t\t\t\t if(subFeatureCount==0)\r\n\t\t\t\t\t\t\t\t\t\t\t isLeafLevel = true;\r\n\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t if(!isMixedUsage && !isMixedComposition){\r\n\t\t\t\t\t\t\t\t\t\t //strNewFeatureType = getNewFeatureType(context,(String)featureTypesList.get(0),isLeafLevel,strObjectType);\r\n\t\t\t\t\t\t\t\t\t\t strNewFeatureType = getNewFeatureType(context,(String)allFeatureTypesList.get(0),isLeafLevel,strObjectType);\r\n\t\t\t\t\t\t\t\t\t }else if(isMixedComposition){\r\n\t\t\t\t\t\t\t\t\t\t //Need to get the NewResolvedFeatureType\r\n\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Top Level Feature Type..\"+referenceContextUsage);\r\n\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Is this feature LeafLevel..\"+isLeafLevel);\r\n\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Type of Object..\"+strObjectType);\r\n\r\n\t\t\t\t\t\t\t\t\t\t strResolvedNewFeatureType = getNewFeatureType(context,referenceContextUsage,isLeafLevel,strObjectType);\r\n\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t if (mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_FEATURES) ||\r\n\t\t\t\t\t\t\t\t\t\t\t mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_PRODUCTS)||\r\n\t\t\t\t\t\t\t\t\t\t\t isOfDerivationChangedType(context, strObjectType)){\r\n\r\n\t\t\t\t\t\t\t\t\t\t stampFeature(context,strObjectId,strNewFeatureType,strResolvedNewFeatureType,sLGBOMIds);\r\n\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t //toplevel object stamping\r\n\t\t\t\t\t\t\t\t //strNewFeatureType = getNewFeatureType(context,(String)featureTypesList.get(0),false,topLevelObjectType);\r\n\t\t\t\t\t\t\t\t strNewFeatureType = getNewFeatureType(context,(String)allFeatureTypesList.get(0),false,topLevelObjectType);\r\n\t\t\t\t\t\t\t\t stampFeature(context,topLevelObjectId,strNewFeatureType,strResolvedNewFeatureType,sLTopLevelGBOMIds);\r\n mqlLogRequiredInformationWriter(\"Stamp ends \"+ \"\\n\");\r\n\r\n\t\t\t\t\t\t\t }//end if toplevelobject is feature\r\n\t\t\t\t\t\t\t // if top level object is Product or ProductLine\r\n\t\t\t\t\t\t\t if (mxType.isOfParentType(context, topLevelObjectType,ConfigurationConstants.TYPE_PRODUCTS)\r\n\t\t\t\t\t\t\t\t\t || mxType.isOfParentType(context,topLevelObjectType, ConfigurationConstants.TYPE_PRODUCT_LINE)) {\r\n\r\n\t\t\t\t\t\t\t\t Map fsMap=new HashMap();\r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\t\t for (int j = 0; j < featureStructureList.size(); j++) {\r\n\r\n\t\t\t\t\t\t\t\t\t fsMap= (Map) featureStructureList.get(j);\r\n\r\n\t\t\t\t\t\t\t\t\t int level = Integer.parseInt((String) fsMap.get(SELECT_LEVEL));\r\n\t\t\t\t\t\t\t\t\t if (level == 1) {\r\n\t\t\t\t\t\t\t\t\t\t String referenceContextUsage2 = (String)fsMap.get(\"attribute[\"+ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\");\r\n\r\n\t\t\t\t\t\t\t\t\t\t // check for substructure mixed usage\r\n\t\t\t\t\t\t\t\t\t\t StringList allFeatureTypesList = new StringList();\r\n\t\t\t\t\t\t\t\t\t\t outer2:for (int k = j; k < featureStructureList.size(); k++) {\r\n\t\t\t\t\t\t\t\t\t\t\t Map subFSMap = (Map) featureStructureList.get(k);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t String strObjectType = (String) subFSMap.get(SELECT_TYPE);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t int currentLevel = Integer.parseInt((String) subFSMap.get(SELECT_LEVEL));\r\n\t\t\t\t\t\t\t\t\t\t\t if (currentLevel == 1 && k > j) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t break;\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t featureTypesList.clear();\r\n\t\t\t\t\t\t\t\t\t\t\t if (mxType.isOfParentType(context,strObjectType, ConfigurationConstants.TYPE_FEATURES)\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t || mxType.isOfParentType(context,strObjectType,ConfigurationConstants.TYPE_PRODUCTS)\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t ||isOfDerivationChangedType(context, strObjectType)) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t String featureTypeSelect = \"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+ \"].from.attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t Object objFeatureTypes = subFSMap.get(featureTypeSelect);\r\n\t\t\t\t\t\t\t\t\t\t\t\t if (objFeatureTypes instanceof StringList) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t featureTypesList = (StringList) subFSMap.get(featureTypeSelect);\r\n\t\t\t\t\t\t\t\t\t\t\t\t } else if (objFeatureTypes instanceof String) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t featureTypesList.addElement((String) subFSMap.get(featureTypeSelect));\r\n\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t\t objFeatureTypes=null;\r\n\t\t\t\t\t\t\t\t\t\t\t\t if (featureTypesList.size() > 0) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t for (int l = 0; l < featureTypesList.size(); l++) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t String strFeatureType = (String) featureTypesList.get(l);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t if (!strFeatureType.equals((String) featureTypesList.get(0))) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t isMixedUsage = true;\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"MixedUsage\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t break outer2;\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t if(!isMixedUsage){\r\n\t\t\t\t\t\t\t\t\t\t\t\t if (mxType.isOfParentType(context,strObjectType,ConfigurationConstants.TYPE_FEATURE_LIST)) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t String strFeatureType = (String) subFSMap.get(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\");\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t allFeatureTypesList.addElement(strFeatureType);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t if (!strFeatureType.equals(allFeatureTypesList.get(0))) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t isMixedComposition = true;\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"MixedComposition\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t break;\r\n\t\t\t\t\t\t\t\t\t\t\t\t }\r\n \t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t subFSMap=null;\r\n\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t allFeatureTypesList=null;\r\n\t\t\t\t\t\t\t\t\t\t // stamp\r\n\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\\nstamp started -----> \"+now()+\"\\n\\n\");\r\n\t\t\t\t\t\t\t\t\t\t String strObjectType=\"\";\r\n\t\t\t\t\t\t\t\t\t\t String strObjectId =\"\";\r\n\r\n\t\t\t\t\t\t\t\t\t\t for (int k = j + 1; k < featureStructureList.size(); k++) {\r\n\t\t\t\t\t\t\t\t\t\t\t Map subFSMap= (Map) featureStructureList.get(k);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t strObjectType = (String) subFSMap.get(SELECT_TYPE);\r\n\t\t\t\t\t\t\t\t\t\t\t strObjectId = (String) subFSMap.get(SELECT_ID);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t StringList sLGBOMIds = new StringList();\r\n\t\t\t\t\t\t\t\t\t\t\t String GBOMSelect = \"from[\"+ConfigurationConstants.RELATIONSHIP_GBOM_FROM+\"].to.id\";\r\n\t\t\t\t\t\t\t\t\t\t\t Object objGBOMType = subFSMap.get(GBOMSelect);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t if (objGBOMType instanceof StringList) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t sLGBOMIds = (StringList) subFSMap.get(GBOMSelect);\r\n\t\t\t\t\t\t\t\t\t\t\t } else if (objGBOMType instanceof String) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t sLGBOMIds.addElement((String) subFSMap.get(GBOMSelect));\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t int currentLevel = Integer.parseInt((String) subFSMap.get(SELECT_LEVEL));\r\n\t\t\t\t\t\t\t\t\t\t\t if (currentLevel == 1) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t //mqlLogRequiredInformationWriter(\"\\ncurrentLevel == 1\\n\");\r\n\t\t\t\t\t\t\t\t\t\t\t\t //j=k;\r\n\t\t\t\t\t\t\t\t\t\t\t\t break;\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t if ((mxType.isOfParentType(context,strObjectType, ConfigurationConstants.TYPE_FEATURES)\r\n \t\t\t\t\t\t\t\t\t\t || mxType.isOfParentType(context,strObjectType, ConfigurationConstants.TYPE_PRODUCTS)\r\n\t\t\t\t\t\t\t\t\t\t || isOfDerivationChangedType(context, strObjectType)))\r\n\t\t\t\t\t\t\t\t\t\t\t //)&&\r\n \t\t\t\t\t\t\t\t\t\t\t//!isOfDerivationChangedType(context, strObjectType)) {\r\n \t\t\t\t\t\t\t\t\t\t {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t boolean isLeafLevel = false;\r\n\t\t\t\t\t\t\t\t\t\t\t\t if(mxType.isOfParentType(context,strObjectType,ConfigurationConstants.TYPE_FEATURES)\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t && currentLevel != 2){\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t int subFeatureCount = Integer.parseInt((String) subFSMap.get(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_SUBFEATURECOUNT + \"]\"));\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t if(subFeatureCount==0)\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t isLeafLevel = true;\r\n\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t\t if(!isMixedUsage && !isMixedComposition &&\r\n\t\t\t\t\t\t\t\t\t\t\t\t !mxType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.isOfParentType(\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcontext,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrObjectType,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tConfigurationConstants.TYPE_FEATURES)\r\n\t\t\t\t\t\t\t\t\t\t\t\t&& !mxType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.isOfParentType(\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcontext,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrObjectType,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tConfigurationConstants.TYPE_FEATURE_LIST)\r\n\t\t\t\t\t\t\t\t\t\t\t\t&& !mxType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.isOfParentType(\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcontext,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstrObjectType,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tConfigurationConstants.TYPE_PRODUCTS)){\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t //Code to check the \"Feature List\" attribute \"Feature Type\" is correctly mapped against the Type\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t //Check for incorrect mapping\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t String strFeatureType = (String) fsMap.get(\"attribute[\"+ ConfigurationConstants.ATTRIBUTE_FEATURE_TYPE+ \"]\");\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t if (strFeatureType.equalsIgnoreCase(ConfigurationConstants.RANGE_VALUE_TECHNICAL)) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t if(!(mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_LOGICAL_STRUCTURES)||\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_PRODUCTS))){\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"IncorrectMapping\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t }else{\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = getNewFeatureType(context,referenceContextUsage2,isLeafLevel,strObjectType);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t }else if(strFeatureType.equalsIgnoreCase(ConfigurationConstants.RANGE_VALUE_MARKETING)) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t if(!mxType.isOfParentType(context, strObjectType,ConfigurationConstants.TYPE_CONFIGURATION_FEATURES)){\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = \"IncorrectMapping\";\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t }else{\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = getNewFeatureType(context,referenceContextUsage2,isLeafLevel,strObjectType);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t\t }else if(!isMixedUsage && !isMixedComposition && (mxType.isOfParentType(context,strObjectType,ConfigurationConstants.TYPE_FEATURES)\r\n\t\t\t\t\t\t\t\t\t\t\t\t ||mxType.isOfParentType(context,strObjectType,ConfigurationConstants.TYPE_PRODUCTS))){\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t strNewFeatureType = getNewFeatureType(context,referenceContextUsage2,isLeafLevel,strObjectType);\r\n\t\t\t\t\t\t\t\t\t\t\t\t }else if(isMixedComposition){\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t //Need to get the NewResolvedFeatureType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t//Need to get the NewResolvedFeatureType\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Top Level Feature Type..\"+referenceContextUsage);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Is this feature LeafLevel..\"+isLeafLevel);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Type of Object..\"+strObjectType);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t strResolvedNewFeatureType = getNewFeatureType(context,referenceContextUsage2,isLeafLevel,strObjectType);\r\n\t\t\t\t\t\t\t\t\t\t\t\t }\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\t stampFeature(context,strObjectId,strNewFeatureType,strResolvedNewFeatureType,sLGBOMIds);\r\n\t\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t subFSMap=null;\r\n\t\t\t\t\t\t\t\t\t\t\t strObjectType=null;\r\n\t\t\t\t\t\t\t\t\t\t\t strObjectId=null;\r\n\t\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t //System.gc();\r\n\t\t\t\t\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"\\nstamp END -----> \"+now()+\"\\n\");\r\n\t\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t featureTypesList=null;\r\n\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t }\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"------------------------------------------------------------\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Object Count in text file DONE ----->\"+ iCnt + \"\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"Toplevel id.DONE ----->\"+ topLevelObjectId +\"--\"+now()+\"\\n\");\r\n\t\t\t\t\t\t mqlLogRequiredInformationWriter(\"------------------------------------------------------------\\n\");\r\n\t\t\t\t\t\t domTopLevelObject=null;\r\n\t\t\t\t\t\t topLevelObjectId=null;\r\n\t\t\t\t\t\t //System.gc();\r\n\t\t\t\t\t }\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\"Pre-migration done for \"+objectList.size()+\" objects in objectids_\"+m+\".txt file. \\n\");\r\n\t\t\t\t\t mqlLogRequiredInformationWriter(\"\\n\");\r\n\t\t\t\t }catch(FileNotFoundException fnfExp){\r\n\t\t\t\t\t // throw exception if file does not exists\r\n\t\t\t\t\t throw fnfExp;\r\n\t\t\t\t }\r\n\t\t\t }\r\n\r\n\t\t\t // Getting top level objects (this includes Feature,Products and ProductLines and also standalone features\r\n\t\t\t StringBuffer sbTypePattern = new StringBuffer(50);\r\n\t\t\t sbTypePattern.append(ConfigurationConstants.TYPE_FEATURES);\r\n\t\t\t sbTypePattern.append(\",\");\r\n\t\t\t sbTypePattern.append(ConfigurationConstants.TYPE_PRODUCTS);\r\n\t\t\t sbTypePattern.append(\",\");\r\n\t\t\t sbTypePattern.append(ConfigurationConstants.TYPE_PRODUCT_LINE);\r\n\r\n\t\t\t StringBuffer sbObjWhere = new StringBuffer(50);\r\n\t\t\t sbObjWhere.append(\"(\");\r\n\t\t\t sbObjWhere.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+ \"]==False\");\r\n\t\t\t sbObjWhere.append(\"&&\");\r\n\t\t\t sbObjWhere.append(\"type.kindof == \\\"\" + ConfigurationConstants.TYPE_FEATURES + \"\\\"\");\r\n\t\t\t sbObjWhere.append(\")\");\r\n\t\t\t sbObjWhere.append(\"||\");\r\n\t\t\t sbObjWhere.append(\"(\");\r\n\t\t\t sbObjWhere.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+ \"]==False\");\r\n\t\t\t sbObjWhere.append(\"&&\");\r\n\t\t\t sbObjWhere.append(\"from[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_FROM+ \"]==True\");\r\n\t\t\t sbObjWhere.append(\"&&\");\r\n\t\t\t sbObjWhere.append(\"(\");\r\n\t\t\t sbObjWhere.append(\"type.kindof == \\\"\" + ConfigurationConstants.TYPE_PRODUCTS + \"\\\"\");\r\n\t\t\t sbObjWhere.append(\"||\");\r\n\t\t\t sbObjWhere.append(\"type.kindof == \\\"\" + ConfigurationConstants.TYPE_PRODUCT_LINE + \"\\\"\");\r\n\t\t\t sbObjWhere.append(\")\");\r\n\t\t\t sbObjWhere.append(\")\");\r\n\r\n\t\t\t StringList objSelects = new StringList();\r\n\t\t\t objSelects.addElement(SELECT_ID);\r\n\t\t\t objSelects.addElement(SELECT_TYPE);\r\n\t\t\t objSelects.addElement(SELECT_NAME);\r\n\r\n\r\n\t\t\t //finding if any Feature objects in database or Product objects which have FLT relationship are not stamped\r\n\t\t\t StringBuffer unStampedTypePattern = new StringBuffer(50);\r\n\t\t\t unStampedTypePattern.append(ConfigurationConstants.TYPE_FEATURES);\r\n\t\t\t unStampedTypePattern.append(\",\");\r\n\t\t\t unStampedTypePattern.append(ConfigurationConstants.TYPE_PRODUCTS);\r\n\r\n\t\t\t emxVariantConfigurationIntermediateObjectMigration_mxJPO VariantConfigInterObjMigrationInst= new emxVariantConfigurationIntermediateObjectMigration_mxJPO(context, new String[0]);\r\n\t\t\t StringList slDerivationChangedType = VariantConfigInterObjMigrationInst.getDerivationChangedType(context,new String[0]);\r\n\r\n\t\t\t\tStringBuffer sbWhereClause = new StringBuffer(50);\r\n\t\t\t\tsbWhereClause.append(\"(\");\r\n\t\t\t\tsbWhereClause.append(\"type.kindof == \\\"\" + ConfigurationConstants.TYPE_FEATURES + \"\\\"\");\r\n\r\n\t\t for(int i=0;i<slDerivationChangedType.size();i++){\r\n\t\t \tunStampedTypePattern.append(\",\");\r\n\t\t \tunStampedTypePattern.append(slDerivationChangedType.get(i));\r\n\t \t\t\tsbWhereClause.append(\"||\");\r\n\t \t\t\tsbWhereClause.append(\"type.kindof == \\\"\" + slDerivationChangedType.get(i).toString() + \"\\\"\");\r\n\t\t }\r\n\t\t sbWhereClause.append(\")\");\r\n\r\n StringBuffer unStampedObjWhere = new StringBuffer(100);\r\n unStampedObjWhere.append(\"(\");\r\n unStampedObjWhere.append(sbWhereClause);\r\n unStampedObjWhere.append(\"&&\");\r\n\t\t\t unStampedObjWhere.append(\"interface[\"+ INTERFACE_FTRIntermediateObjectMigration +\"]==FALSE\");\r\n\t\t\t unStampedObjWhere.append(\")\");\r\n\t\t\t /*unStampedObjWhere.append(\"||\");\r\n\t\t\t unStampedObjWhere.append(\"(\");\r\n\t\t\t unStampedObjWhere.append(\"type.kindof == \\\"\" + ConfigurationConstants.TYPE_PRODUCTS + \"\\\"\");\r\n\t\t\t unStampedObjWhere.append(\"&&\");\r\n\t\t\t unStampedObjWhere.append(\"to[\"+ ConfigurationConstants.RELATIONSHIP_FEATURE_LIST_TO+ \"]==True\");\r\n\t\t\t unStampedObjWhere.append(\"&&\");\r\n\t\t\t unStampedObjWhere.append(\"interface[\"+ INTERFACE_FTRIntermediateObjectMigration +\"]==FALSE\");\r\n\t\t\t unStampedObjWhere.append(\")\");*/\r\n\r\n\t\t\t StringList sLobjSelects = new StringList();\r\n\t\t\t sLobjSelects.addElement(SELECT_NAME);\r\n\t\t\t sLobjSelects.addElement(SELECT_TYPE);\r\n\t\t\t sLobjSelects.addElement(SELECT_ID);\r\n\r\n\t\t\t mqlLogRequiredInformationWriter(\"Check for unStamped Objects starts \"+\"\\n\");\r\n\r\n\t\t\t List unStampedObjectsList = DomainObject.findObjects(\r\n\t\t\t\t\t context,\r\n\t\t\t\t\t unStampedTypePattern.toString(),\r\n\t\t\t\t\t DomainConstants.QUERY_WILDCARD,\r\n\t\t\t\t\t unStampedObjWhere.toString(),\r\n\t\t\t\t\t sLobjSelects);\r\n\t\t\t mqlLogRequiredInformationWriter(\"Check for unStamped Objects ends \"+\"\\n\");\r\n\r\n\t\t\t //setting premigration status\r\n\t\t\t if(unStampedObjectsList.size()==0)\r\n\t\t\t {\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"Unstamped object list size is 0.\\n\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"Pre-migration is complete.\\n\");\r\n\t\t\t\t setAdminMigrationStatus(context,\"PreMigrationComplete\");\r\n\t\t\t }\r\n\t\t\t else\r\n\t {\r\n\t \tMap unStampedObjMap = new HashMap();\r\n\t \tfor(int i=0;i<unStampedObjectsList.size();i++){\r\n\r\n\t \t\tunStampedObjMap= (Map)unStampedObjectsList.get(i);\r\n\t \t\tString strUnStampId =(String)unStampedObjMap.get(SELECT_ID);\r\n\t \t\twriteOIDToTextFile(strUnStampId,\"unStampedOIDs\");\r\n\t \t}\r\n\r\n\t mqlLogRequiredInformationWriter(\"Pre-migration is not complete.\\n\");\r\n\t mqlLogRequiredInformationWriter(\"WARNING: Some Feature objects are not stamped.\\n\");\r\n\t mqlLogRequiredInformationWriter(\"Please refer unStampedOIDs.txt for details.\\n\");\r\n\t mqlLogRequiredInformationWriter(\"\\n\");\r\n\r\n\t }\r\n\r\n\t\t\t if(IS_CONFLICT){\r\n\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"WARNING: Conflict MixedUsage/MixedComposition/MarketingGBOM exist.\" + \"\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"Please view file 'Conflict.txt'for a list of these objects\" + \"\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"These objects need to be deleted or fixed in order to proceed with the next step of migration..\" + \"\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"\\n\");\r\n\t\t\t\t mqlLogRequiredInformationWriter(\"\\n\");\r\n\t\t\t }\r\n\r\n\r\n\t\t\t String strMqlCommandOn = \"trigger on\";\r\n\t\t\t MqlUtil.mqlCommand(context,strMqlCommandOn,true);\r\n\t\t\t mqlLogRequiredInformationWriter(\"End of preMigration 'trigger on' done\" + \"\\n\");\r\n\r\n\t }catch (Exception e) {\r\n \t\t\te.printStackTrace();\r\n \t\t\tmqlLogRequiredInformationWriter(\"Pre-migration failed. \\n\"+e.getMessage() + \"\\n\");\r\n \t\t}\r\n \t}",
"public interface EncoreFactory extends EFactory {\n\t/**\n\t * The singleton instance of the factory.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @generated\n\t */\n\tEncoreFactory eINSTANCE = Encore.impl.EncoreFactoryImpl.init();\n\n\t/**\n\t * Returns a new object of class '<em>Concierto</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Concierto</em>'.\n\t * @generated\n\t */\n\tConcierto createConcierto();\n\n\t/**\n\t * Returns a new object of class '<em>Cancion</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Cancion</em>'.\n\t * @generated\n\t */\n\tCancion createCancion();\n\n\t/**\n\t * Returns a new object of class '<em>Secuencia</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Secuencia</em>'.\n\t * @generated\n\t */\n\tSecuencia createSecuencia();\n\n\t/**\n\t * Returns a new object of class '<em>Foco</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Foco</em>'.\n\t * @generated\n\t */\n\tFoco createFoco();\n\n\t/**\n\t * Returns a new object of class '<em>Strobo</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Strobo</em>'.\n\t * @generated\n\t */\n\tStrobo createStrobo();\n\n\t/**\n\t * Returns a new object of class '<em>Union Cancion Secuencia</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Union Cancion Secuencia</em>'.\n\t * @generated\n\t */\n\tUnionCancionSecuencia createUnionCancionSecuencia();\n\n\t/**\n\t * Returns a new object of class '<em>Union Secuencia Luz</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Union Secuencia Luz</em>'.\n\t * @generated\n\t */\n\tUnionSecuenciaLuz createUnionSecuenciaLuz();\n\n\t/**\n\t * Returns the package supported by this factory.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return the package supported by this factory.\n\t * @generated\n\t */\n\tEncorePackage getEncorePackage();\n\n}",
"void create(E entity);",
"TestEntity buildEntity () {\n TestEntity testEntity = new TestEntity();\n testEntity.setName(\"Test name\");\n testEntity.setCheck(true);\n testEntity.setDateCreated(new Date(System.currentTimeMillis()));\n testEntity.setDescription(\"description\");\n\n Specialization specialization = new Specialization();\n specialization.setName(\"Frontend\");\n specialization.setLevel(\"Senior\");\n specialization.setYears(10);\n\n testEntity.setSpecialization(specialization);\n\n return testEntity;\n }",
"WithCreate withCreationData(CreationData creationData);",
"public interface MissionFactory extends EFactory {\r\n\t/**\r\n\t * The singleton instance of the factory.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @generated\r\n\t */\r\n\tMissionFactory eINSTANCE = it.univaq.flyaq.mission.impl.MissionFactoryImpl.init();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Mission</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Mission</em>'.\r\n\t * @generated\r\n\t */\r\n\tMission createMission();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Swarm</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Swarm</em>'.\r\n\t * @generated\r\n\t */\r\n\tSwarm createSwarm();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Drone</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Drone</em>'.\r\n\t * @generated\r\n\t */\r\n\tDrone createDrone();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Fork</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Fork</em>'.\r\n\t * @generated\r\n\t */\r\n\tFork createFork();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Join</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Join</em>'.\r\n\t * @generated\r\n\t */\r\n\tJoin createJoin();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Task Dependency</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Task Dependency</em>'.\r\n\t * @generated\r\n\t */\r\n\tTaskDependency createTaskDependency();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Coordinate</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Coordinate</em>'.\r\n\t * @generated\r\n\t */\r\n\tCoordinate createCoordinate();\r\n\r\n\t/**\r\n\t * Returns the package supported by this factory.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return the package supported by this factory.\r\n\t * @generated\r\n\t */\r\n\tMissionPackage getMissionPackage();\r\n\r\n}",
"public Product(Long idIn, String nameIn, String productClassIn, Boolean freeIn, Boolean baseIn) {\n id = idIn;\n name = nameIn;\n productClass = productClassIn;\n free = freeIn;\n base = baseIn;\n }",
"public static Flipkart createFlipkart()throws Exception {\r\n\t\t //create target class obj\r\n\t\t Flipkart fpkt=new Flipkart();\r\n\t\t \r\n\t\t // Load Dependent class \r\n\t\t Class c=Class.forName(props.getProperty(\"dependent.comp\"));\r\n\t\t //create object using refflection object\r\n\t\t Constructor cons[]=c.getDeclaredConstructors();\r\n\t\t //create object\r\n\t\t Courier courier=(Courier) cons[0].newInstance();\r\n\t\t //set Dependent class object to target class obj\r\n\t\t fpkt.setCourier(courier);\r\n\t return fpkt;\r\n }",
"public static Produit createEntity(EntityManager em) {\n Produit produit = new Produit()\n .designation(DEFAULT_DESIGNATION)\n .soldeInit(DEFAULT_SOLDE_INIT)\n .prixAchat(DEFAULT_PRIX_ACHAT)\n .prixVente(DEFAULT_PRIX_VENTE)\n .quantiteDispo(DEFAULT_QUANTITE_DISPO)\n .quantiteInit(DEFAULT_QUANTITE_INIT)\n .seuilReaprov(DEFAULT_SEUIL_REAPROV)\n .reference(DEFAULT_REFERENCE);\n return produit;\n }",
"public static void main(String[] args) {\n\t\tExtraTerestru ext = new ExtraTerestru();\r\n\t\tExtraTerestru.IntraTerestru ext1 = ext.new IntraTerestru();\r\n\t\t\r\n\t\t// instantiere clasa inner dintr o clasa care extinde clasa mama\r\n\t\tExtraTerestru2 ext2 = new ExtraTerestru2();\r\n\t\tExtraTerestru2.IntraTerestru ext3 = ext2.new IntraTerestru();\r\n\t\t\r\n\t\t// instantiere clasa inner ver. 2\r\n\t\tExtraTerestru.IntraTerestru ext4 = new ExtraTerestru().new IntraTerestru();\r\n\t}"
] | [
"0.61710495",
"0.5843043",
"0.5557812",
"0.55413216",
"0.5532543",
"0.5283002",
"0.526302",
"0.51821357",
"0.5170096",
"0.5131497",
"0.5120654",
"0.509395",
"0.5087524",
"0.5079915",
"0.506433",
"0.5041386",
"0.5037549",
"0.50343275",
"0.5029635",
"0.50225925",
"0.5018296",
"0.49881205",
"0.49640906",
"0.4958681",
"0.49565005",
"0.49377573",
"0.49292716",
"0.4914809",
"0.49112764",
"0.4896871",
"0.48399097",
"0.48347628",
"0.4833991",
"0.48191687",
"0.48123804",
"0.48042795",
"0.48004323",
"0.480024",
"0.47971952",
"0.4797019",
"0.47967446",
"0.47912592",
"0.47912592",
"0.47857332",
"0.4783671",
"0.4778003",
"0.47738734",
"0.47588688",
"0.47578755",
"0.47548184",
"0.47545838",
"0.47516024",
"0.47416222",
"0.47358355",
"0.47323406",
"0.4730351",
"0.47300828",
"0.47295582",
"0.47194222",
"0.471809",
"0.47138375",
"0.47129628",
"0.4712291",
"0.47080228",
"0.4700828",
"0.46927026",
"0.4692306",
"0.46885797",
"0.4681036",
"0.46657524",
"0.4664802",
"0.4662926",
"0.46596667",
"0.46596646",
"0.46596095",
"0.46587354",
"0.4658253",
"0.4658207",
"0.46540654",
"0.46491656",
"0.4648956",
"0.46488822",
"0.46434262",
"0.46433705",
"0.46396765",
"0.46377504",
"0.46362486",
"0.46356282",
"0.4635023",
"0.4631806",
"0.46314818",
"0.4628344",
"0.46263477",
"0.462424",
"0.4623652",
"0.46169707",
"0.46131223",
"0.4611677",
"0.46092394",
"0.4608938"
] | 0.6098469 | 1 |
Creates a new object on the ECM System using the given parameters. Has additional promote and checkin mode parameters for versionable objects and the extra parameter fKeepCheckedOut_p to control whether the new objects are checked in automatically or not. ATTENTION: If keepCheckedOut is true, the promote flag (major/minor versioning) is ignored. | public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,
OwObject parent_p, String strMimeType_p, String strMimeParameter_p, boolean fKeepCheckedOut_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,\r\n OwObject parent_p, String strMimeType_p, String strMimeParameter_p) throws Exception;",
"public CMObject newInstance();",
"public abstract ArchECoreArchitecture newArchitecture(ArchEVersionVO version) throws ArchEException;",
"public abstract String createNewObject(OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p, OwObject parent_p, String strMimeType_p,\r\n String strMimeParameter_p) throws Exception;",
"@Override\n public boolean create(Revue objet) {\n return false;\n }",
"@Override\r\n\tpublic boolean create(Jeu obj) {\n\t\treturn false;\r\n\t}",
"protected abstract T newObject(Handle<T> paramHandle);",
"@DISPID(1611005952) //= 0x60060000. The runtime will prefer the VTID if present\n @VTID(28)\n void newWithAxisSystem(\n boolean oAxisSystemCreated);",
"Version create(Identity nodeId);",
"@Override\r\n\tpublic int create(Object value) throws Exception {\r\n\t\t\t\t\t\r\n\t\t//Default error\r\n\t\tint result = Errors.NO_ERROR;\r\n\t\t\t\t\t\t\r\n\t\t//Verify class\t\t\r\n\t\tif (value.getClass()!=CentroVO.class) \r\n\t\t\tthrow (new Exception(\"Not valid class\")); \r\n\t\t\t\t\t\r\n\t\tCentroVO center = (CentroVO)value;\r\n\t\t\t\t\r\n\t\t// Verify used licenses\r\n\t\tLOG.info(\"Verifying licenses\");\r\n\t\t\r\n\t\t//Verificamos que existan suficientes licencias disponibles para \r\n\t\t//la solicitud realizada\t\t\r\n\t\tif (licenseService.getEnabledLicensesCenter(Constants.NOT_CREATED)<center.getLicencias()) {\r\n\t\t\tresult = Errors.MAX_LICENSES;\r\n\t\t}\t\t\r\n\t\t\r\n\t\tif (result >=0){\r\n\t\t\tLOG.debug(\"Calling create center\");\r\n\t \r\n\t //Calling service\r\n\t result = service.insertCentro(center);\r\n\t\t}\r\n\t\t\t\t \t\t\t\t\t\t\t\t\r\n\t\treturn result;\t\t\t\t\t\t\t\t\r\n\t}",
"private SceneGraphObject createNodeFromSuper( String className, Class[] parameterTypes, Object[] parameters ) {\n\tSceneGraphObject ret;\n\n String tmp = this.getClass().getName();\n String superClass = tmp.substring( tmp.indexOf(\"state\")+6, tmp.length()-5 );\n Constructor constructor;\n\n try {\n Class state = Class.forName( superClass );\n constructor = state.getConstructor( parameterTypes );\n ret = (SceneGraphObject)constructor.newInstance( parameters );\n\t} catch(ClassNotFoundException e1) {\n\t throw new SGIORuntimeException( \"No State class for \"+\n\t\t\t\t\t\tsuperClass );\n\t} catch( IllegalAccessException e2 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName+\" - IllegalAccess\" );\n\t} catch( InstantiationException e3 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName );\n } catch( java.lang.reflect.InvocationTargetException e4 ) {\n\t throw new SGIORuntimeException( \"InvocationTargetException for \"+\n\t\t\t\t\t\tclassName );\n } catch( NoSuchMethodException e5 ) {\n for(int i=0; i<parameterTypes.length; i++)\n System.err.println( parameterTypes[i].getName() );\n System.err.println(\"------\");\n\t throw new SGIORuntimeException( \"Invalid constructor for \"+\n\t\t\t\t\t\tclassName );\n }\n\n return ret;\n }",
"@Override\n\tpublic boolean create(Etape obj) {\n\t\treturn false;\n\t}",
"OBJECT createOBJECT();",
"@DISPID(1611005964) //= 0x6006000c. The runtime will prefer the VTID if present\n @VTID(40)\n void newWith3DSupport(\n boolean o3DSupportCreated);",
"private SceneGraphObject createNode( String className, Class[] parameterTypes, Object[] parameters ) {\n SceneGraphObject ret;\n Constructor constructor;\n\n try {\n Class state = Class.forName( className );\n constructor = state.getConstructor( parameterTypes );\n ret = (SceneGraphObject)constructor.newInstance( parameters );\n\t} catch(ClassNotFoundException e1) {\n if (control.useSuperClassIfNoChildClass())\n ret = createNodeFromSuper( className, parameterTypes, parameters );\n else\n throw new SGIORuntimeException( \"No State class for \"+\n\t\t\t\t\t\tclassName );\n\t} catch( IllegalAccessException e2 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName+\" - IllegalAccess\" );\n\t} catch( InstantiationException e3 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tclassName );\n } catch( java.lang.reflect.InvocationTargetException e4 ) {\n\t throw new SGIORuntimeException( \"InvocationTargetException for \"+\n\t\t\t\t\t\tclassName );\n } catch( NoSuchMethodException e5 ) {\n for(int i=0; i<parameterTypes.length; i++)\n System.err.println( parameterTypes[i].getName() );\n System.err.println(\"------\");\n\t throw new SGIORuntimeException( \"Invalid constructor for \"+\n\t\t\t\t\t\tclassName );\n }\n\n return ret;\n }",
"protected JvmOSMeta createJvmOSMetaNode(String paramString1, String paramString2, ObjectName paramObjectName, MBeanServer paramMBeanServer) {\n/* 217 */ return new JvmOSMeta(this, this.objectserver);\n/* */ }",
"void create(Product product) throws IllegalArgumentException;",
"Operacion createOperacion();",
"public Device createObject(String brand, String model, Integer price, String photo, String date);",
"public abstract boolean create(T newInstance);",
"com.exacttarget.wsdl.partnerapi.ObjectDefinition addNewObjectDefinition();",
"public static synchronized void constructInstance()\n {\n SmartDashboard.putBoolean( TelemetryNames.Elbow.status, false );\n\n if ( ourInstance != null )\n {\n throw new IllegalStateException( myName + \" Already Constructed\" );\n }\n ourInstance = new ElbowSubsystem();\n\n SmartDashboard.putBoolean( TelemetryNames.Elbow.status, true );\n }",
"public abstract ArchECoreRequirementModel newRequirementModel(ArchEVersionVO version) throws ArchEException;",
"public M create(P model);",
"public void doExecute() {\n\t\tparent.requestChange(new ModelChangeRequest(this.getClass(), parent,\n\t\t\t\t\"create\") {\n\t\t\t@Override\n\t\t\tprotected void _execute() throws Exception {\n\t\t\t\ttry {\n\t\t\t\t\tCompositeEntity parentModel = (CompositeEntity) parent;\n\t\t\t\t\tString componentName = null;\n\t\t\t\t\tif (model == null) {\n\t\t\t\t\t\tcomponentName = ModelUtils.findUniqueName(parentModel,\n\t\t\t\t\t\t\t\t\t\t clazz,\n\t\t\t\t\t\t\t\t\t\t name.equalsIgnoreCase(\"INPUT\") ? DEFAULT_INPUT_PORT : DEFAULT_OUTPUT_PORT,\n\t\t\t\t\t\t\t\t\t\t name);\n\t\t\t\t\t\tcomponentName = ModelUtils.getLegalName(componentName);\n\t\t\t\t\t\tClass constructorClazz = CompositeEntity.class;\n\t\t\t\t\t\tif (clazz.getSimpleName().equals(\"TypedIOPort\")) {\n\t\t\t\t\t\t\tconstructorClazz = ComponentEntity.class;\n\t\t\t\t\t\t} else if (clazz.getSimpleName().equals(\n\t\t\t\t\t\t\t\t\"TextAttribute\")) {\n\t\t\t\t\t\t\tconstructorClazz = NamedObj.class;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (clazz.getSimpleName().equals(\"Vertex\")) {\n\t\t\t\t\t\t\tTypedIORelation rel = new TypedIORelation(\n\t\t\t\t\t\t\t\t\tparentModel, componentName);\n\t\t\t\t\t\t\tchild = new Vertex(rel, \"Vertex\");\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tConstructor constructor = clazz.getConstructor(\n\t\t\t\t\t\t\t\t\tconstructorClazz, String.class);\n\n\t\t\t\t\t\t\tchild = (NamedObj) constructor.newInstance(\n\t\t\t\t\t\t\t\t\tparentModel, componentName);\n\t\t\t\t\t\t\tif (child instanceof TypedIOPort) {\n\t\t\t\t\t\t\t\tboolean isInput = name\n\t\t\t\t\t\t\t\t\t\t.equalsIgnoreCase(\"INPUT\");\n\t\t\t\t\t\t\t\t((TypedIOPort) child).setInput(isInput);\n\t\t\t\t\t\t\t\t((TypedIOPort) child).setOutput(!isInput);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (model instanceof TypedIOPort) {\n\t\t\t\t\t\t\tname = ((TypedIOPort) model).isInput() ? DEFAULT_INPUT_PORT\n\t\t\t\t\t\t\t\t\t: DEFAULT_OUTPUT_PORT;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcomponentName = ModelUtils.findUniqueName(parentModel, model.getClass(), name, name);\n\t\t\t\t\t\tcomponentName = ModelUtils.getLegalName(componentName);\n\t\t\t\t\t\tif (model instanceof Vertex) {\n\t\t\t\t\t\t\tTypedIORelation rel = new TypedIORelation(\n\t\t\t\t\t\t\t\t\tparentModel, componentName);\n\t\t\t\t\t\t\tchild = new Vertex(rel, \"Vertex\");\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tchild = (NamedObj) model\n\t\t\t\t\t\t\t\t\t.clone(((CompositeEntity) parentModel)\n\t\t\t\t\t\t\t\t\t\t\t.workspace());\n\t\t\t\t\t\t\tchild.setName(componentName);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tComponentUtility.setContainer(child, parentModel);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tcreateDefaultValues(child);\n\t\t\t\t\t\n\t\t\t\t\tif (location != null) {\n\t\t\t\t\t\tModelUtils.setLocation(child, location);\n\t\t\t\t\t}\n\t\t\t\t\tsetChild(child);\n\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\tgetLogger().error(\"Unable to create component\", e);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t});\n\t}",
"OperacionColeccion createOperacionColeccion();",
"Object build();",
"EisModel createEisModel();",
"protected VendorCheck createVendorCheck() {\r\n VendorCheck vendorCheck = new VendorCheck();\r\n vendorCheck.setVendorCheckId(new Long(99999));\r\n return vendorCheck;\r\n }",
"@POST( CONTROLLER )\n VersionedObjectKey createObject( @Body CreateObjectRequest request );",
"WithCreate withHyperVGeneration(HyperVGeneration hyperVGeneration);",
"@SuppressWarnings(\"unchecked\")\n private void apply(LinkedEntityCreateParameters<BE, ME> params) {\n this.bukkitEntity = params.getBukkitEntity();\n this.chunk = bukkitEntity.getLocation().getChunk();\n final ME pMinecraftEntity = params.getMinecraftEntity();\n this.minecraftEntity = pMinecraftEntity == null ? (ME) NMSUtils.getMinecraftEntity(bukkitEntity)\n : pMinecraftEntity;\n }",
"abstract Object build();",
"public CreateNewVersionResultDTO createNewVersion(String contentTypeName, String branch, String config,\n\t MultipartFile uploadedFile) {\n\t\t// TODO impl\n\t\treturn null;\n\t}",
"public InternalDestinationEVO create(InternalDestinationEVO evo) throws Exception {\n\t internalDestinationEjb.ejbCreate(evo);\r\n\t InternalDestinationEVO newevo = internalDestinationEjb.getDetails(\"<UseLoadedEVOs>\");\r\n\t InternalDestinationPK pk = newevo.getPK();\r\n\t this.mLocals.put(pk, internalDestinationEjb);\r\n\t return newevo;\r\n }",
"@SuppressWarnings({\"rawtypes\", \"unchecked\"})\n public <T> T createModel(T referenceModel, boolean withPolicies) throws CreateModelException {\n Erector erector = erectors.get(referenceModel.getClass());\n\n if (erector == null) {\n throw new CreateModelException(\"Unregistered class: \" + referenceModel.getClass());\n }\n\n return createModel(erector, referenceModel, withPolicies);\n }",
"WithCreate withOsType(OperatingSystemTypes osType);",
"public boolean create(ModelObject obj);",
"SAProcessInstanceBuilder createNewInstance(SProcessInstance processInstance);",
"public JvnObject jvnCreateObject(Serializable o) throws jvn.JvnException { \n\t\t// to be completed \n\t\tJvnObject jObject = null;\n\t\ttry {\n\t\t\tjObject = new JvnObjectImpl(o, this.jRCoordonator.jvnGetObjectId());\n\t\t\tlistJObject.put(jObject.jvnGetObjectId(), jObject);\n\t\t\tSystem.out.println(\"jvnServerImpl - list Object Create: \" + listJObject.toString());\n\t\t} catch (RemoteException e) {\n\t\t\tSystem.out.println(\"Error creation object : \" + e.getMessage());\n\t\t}\n\t\treturn jObject;\n\t\t//return null; \n\t}",
"public Integer create(Caseresultparameters newInstance) throws ServiceException;",
"public boolean createBuild(Build build);",
"protected SceneGraphObject createNode( Class j3dClass, Class[] parameterTypes, Object[] parameters ) {\n SceneGraphObject ret;\n Constructor constructor;\n\n try {\n constructor = j3dClass.getConstructor( parameterTypes );\n ret = (SceneGraphObject)constructor.newInstance( parameters );\n\t} catch( IllegalAccessException e2 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tj3dClass.getClass().getName()+\" - IllegalAccess\" );\n\t} catch( InstantiationException e3 ) {\n\t throw new SGIORuntimeException( \"Broken State class for \"+\n\t\t\t\t\t\tj3dClass.getClass().getName() );\n } catch( java.lang.reflect.InvocationTargetException e4 ) {\n\t throw new SGIORuntimeException( \"InvocationTargetException for \"+\n\t\t\t\t\t\tj3dClass.getClass().getName() );\n } catch( NoSuchMethodException e5 ) {\n for(int i=0; i<parameterTypes.length; i++)\n System.err.println( parameterTypes[i].getName() );\n System.err.println(\"------\");\n\t throw new SGIORuntimeException( \"Invalid constructor for \"+\n\t\t\t\t\t\tj3dClass.getClass().getName() );\n }\n\n return ret;\n }",
"Compleja createCompleja();",
"@Test\n public void Constructor_ObjectValues_InstanceCreated() {\n\t\ttry {\n Position position = make_PositionWithIntegerPoints(xCoordinate, yCoordinate, direction);\n Surface surface = make_SurfaceWithGivenDimensions(xDimension, yDimension);\n\t\t\tRover rover = make_RoverWithObjectValues(position, surface);\n\t\t}\n\t\tcatch (AssertionError assErr) {\n\t\t\t// Test passed.\n\t\t\treturn;\n\t\t}\n }",
"Entity createEntity();",
"public FMISComLocal create() throws javax.ejb.CreateException;",
"public void create (Object o) \n throws NoPeerException, SQLException\n {\n PersistentPeer peer = getPeer(o);\n peer.setPersistentEngine (this);\n peer.create (o);\n }",
"protected abstract Object createObjectInternal(ObjectInformation objectInformation) throws FillingException;",
"Make createMake();",
"Nexo createNexo();",
"public interface ParkingFactory extends EFactory {\n\t/**\n\t * The singleton instance of the factory.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @generated\n\t */\n\tParkingFactory eINSTANCE = com.tum.vsms.Parking.Parking.impl.ParkingFactoryImpl.init();\n\n\t/**\n\t * Returns a new object of class '<em>Parking</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Parking</em>'.\n\t * @generated\n\t */\n\tParking createParking();\n\n\t/**\n\t * Returns a new object of class '<em>Vehicle</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Vehicle</em>'.\n\t * @generated\n\t */\n\tVehicle createVehicle();\n\n\t/**\n\t * Returns a new object of class '<em>Customer</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Customer</em>'.\n\t * @generated\n\t */\n\tCustomer createCustomer();\n\n\t/**\n\t * Returns a new object of class '<em>Location</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Location</em>'.\n\t * @generated\n\t */\n\tLocation createLocation();\n\n\t/**\n\t * Returns a new object of class '<em>Traditional</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Traditional</em>'.\n\t * @generated\n\t */\n\tTraditional createTraditional();\n\n\t/**\n\t * Returns a new object of class '<em>Charging Station</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Charging Station</em>'.\n\t * @generated\n\t */\n\tChargingStation createChargingStation();\n\n\t/**\n\t * Returns a new object of class '<em>Fueling Station</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Fueling Station</em>'.\n\t * @generated\n\t */\n\tFuelingStation createFuelingStation();\n\n\t/**\n\t * Returns a new object of class '<em>Anywhere</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Anywhere</em>'.\n\t * @generated\n\t */\n\tAnywhere createAnywhere();\n\n\t/**\n\t * Returns the package supported by this factory.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return the package supported by this factory.\n\t * @generated\n\t */\n\tParkingPackage getParkingPackage();\n\n}",
"@SuppressWarnings(\"unchecked\")\n\tpublic boolean makeNewSale() throws PreconditionException {\n\t\t/* check precondition */\n\t\tif (true) \n\t\t{ \n\t\t\t/* Logic here */\n\t\t\t//return primitive type\t\n\t\t\tSale s = null;\n\t\t\ts = (Sale) EntityManager.createObject(\"Sale\");\n\t\t\ts.setBelongedCashDesk(currentCashDesk);\n\t\t\tcurrentCashDesk.addContainedSales(s);\n\t\t\ts.setIsComplete(false);\n\t\t\ts.setIsReadytoPay(false);\n\t\t\tthis.setCurrentSale(s);\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tthrow new PreconditionException();\t\t\t\t\n\t\t}\n\t\t//all relevant vars : s this\n\t\t//all relevant entities : Sale \n\t}",
"public Command create(Object... param);",
"public abstract Object build();",
"protected Product(Parcel in) {\r\n quantity = in.readInt();\r\n name = in.readString();\r\n checked = in.readByte() != 0;\r\n }",
"SystemParamModel createSystemParamModel();",
"@Override\r\n\tpublic CMObject newInstance()\r\n\t{\r\n\t\ttry\r\n\t\t{\r\n\t\t\treturn this.getClass().getDeclaredConstructor().newInstance();\r\n\t\t}\r\n\t\tcatch(final Exception e)\r\n\t\t{\r\n\t\t\tLog.errOut(ID(),e);\r\n\t\t}\r\n\t\treturn new StdBehavior();\r\n\t}",
"public static native int OpenMM_AmoebaVdwForce_addParticle(PointerByReference target, int parentIndex, double sigma, double epsilon, double reductionFactor, int isAlchemical);",
"public Object buildNewInstance() throws DescriptorException {\n if (this.isUsingDefaultConstructor()) {\n return this.buildNewInstanceUsingDefaultConstructor();\n } else {\n return this.buildNewInstanceUsingFactory();\n }\n }",
"public System(String implClassName, Params param) {\n\t\tSimLogger.log(Level.INFO, \"New System Created.\");\n\t\tthis.param = param;\n\t\tthis.param.system = this;\n\t\ttry {\n\t\t\tClass implClass = Class.forName(implClassName);\n\t\t\timpl = (Implementation) implClass.newInstance();\n\t\t\t// Set the implementation's system so init() can set it in workload!!!\n\t\t\timpl.sys = this;\n\t\t\timpl.init(param.starter.build());\n\t\t\tSimLogger.log(Level.FINE, \"Implementation \" + implClassName + \" was created successfully.\");\n\n\t\t\ttry {\n\t\t\t\tfor(String s : param.measures) {\n\t\t\t\t\tSimLogger.log(Level.FINE, \"Adding measure \" + s + \" to system.\");\n\t\t\t\t\tClass measureClass = Class.forName(s);\n\t\t\t\t\tMeasure measure = (Measure) measureClass.newInstance();\n\t\t\t\t\tmeasures.add(measure);\n\t\t\t\t}\n\t\t\t\tCollections.sort(measures);\n\t\t\t} catch(ClassNotFoundException e) {\n\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot find measure class with name = \" + implClassName);\n\t\t\t\tthrow new RuntimeException(e);\n\t\t\t} catch(InstantiationException e) {\n\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate measure class with name = \" + implClassName);\n\t\t\t\tthrow new RuntimeException(e);\n\t\t\t} catch(IllegalAccessException e) {\n\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate measure class with name = \" + implClassName);\n\t\t\t\tthrow new RuntimeException(e);\n\t\t\t}\n\n\t\t\t//init actors\n\t\t\tHashMap<String, Integer> actorMachineInstances = param.starter.buildActorMachine();\n\t\t\tfor(String aType : actorMachineInstances.keySet()) {\n\t\t\t\tint numActors = actorMachineInstances.get(aType);\n\t\t\t\tSimLogger.log(Level.FINE, \"Creating \" + numActors + \" many of actor type \" + aType);\n\t\t\t\tfor(int i = 0; i < numActors; i++) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tClass actorClass = Class.forName(aType);\n\t\t\t\t\t\tActorMachine am = (ActorMachine) actorClass.newInstance();\n\t\t\t\t\t\tString actorName = am.getPrefix() + i;\n\t\t\t\t\t\tam.actor = actorName;\n\t\t\t\t\t\tam.actorType = aType;\n\t\t\t\t\t\tam.sys = this;\n\t\t\t\t\t\tactors.put(actorName, am);\n\t\t\t\t\t} catch(ClassNotFoundException e) {\n\t\t\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot find actor machine class with name = \" + implClassName);\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t} catch(InstantiationException e) {\n\t\t\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate actor machine class with name = \" + implClassName);\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t} catch(IllegalAccessException e) {\n\t\t\t\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate actor machine class with name = \" + implClassName);\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tSimLogger.log(Level.FINE, \"Actors init was successful.\");\n\n\t\t} catch(ClassNotFoundException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Cannot find implementation class with name = \" + implClassName);\n\t\t\te.printStackTrace();\n\t\t} catch(InstantiationException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate implementation class with name = \" + implClassName);\n\t\t\te.printStackTrace();\n\t\t} catch(IllegalAccessException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Cannot instantiate implementation class with name = \" + implClassName);\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"Elevage createElevage();",
"SpaceInvaderTest_VaisseauImmobile_DeplacerVaisseauVersLaGauche createSpaceInvaderTest_VaisseauImmobile_DeplacerVaisseauVersLaGauche();",
"public ProductoCreable newInstance(int codigo, String nombre){\r\n \r\n }",
"Parcelle createParcelle();",
"public static EObject create(TransactionalEditingDomain domain, EClass eClass,\n\t\t\tboolean sendEvents) {\n\n\t\tEObject eObject = eClass.getEPackage().getEFactoryInstance().create(\n\t\t\teClass);\n\n\t\tif (domain != null) {\n\t\t\t// this object is to be managed by this editing domain\n\t\t\teObject.eAdapters().add(\n\t\t\t\t((InternalTransactionalEditingDomain) domain).getChangeRecorder());\n\t\t\t\n\t\t\teObject.eAdapters().add(\n\t\t\t\tCrossReferenceAdapter.getCrossReferenceAdapter(domain.getResourceSet()));\n\n\t\t\tif (sendEvents) {\n\t\t\t\tsendCreateEvent(domain, eObject);\n\t\t\t}\n\t\t}\n\n\t\treturn eObject;\n\t}",
"public Entity build();",
"Reproducible newInstance();",
"@Test\n public void testVersioningInitialState() {\n\n String id = objService.createDocument(repositoryId, createBaseDocumentProperties(\"newdoc2\", \"cmis:document\"),\n rootFolderId, null, VersioningState.MAJOR, null, null, null, null);\n ObjectData ob = getObject(id);\n\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_LABEL, \"1.0\", ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, null, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob); // ...\n\n // copy from checked in source as checked out\n\n id = objService.createDocumentFromSource(repositoryId, id, null, rootFolderId, VersioningState.CHECKEDOUT, null,\n null, null, null);\n ob = getObject(id);\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_LABEL, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, id, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, USERNAME, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob);\n\n // creation as minor version\n\n id = objService.createDocument(repositoryId, createBaseDocumentProperties(\"newdoc2\", \"cmis:document\"),\n rootFolderId, null, VersioningState.MINOR, null, null, null, null);\n ob = getObject(id);\n\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_LABEL, \"0.1\", ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, null, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob); // ...\n\n // creation checked out\n\n id = objService.createDocument(repositoryId, createBaseDocumentProperties(\"newdoc3\", \"cmis:document\"),\n rootFolderId, null, VersioningState.CHECKEDOUT, null, null, null, null);\n ob = getObject(id);\n\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_LABEL, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, id, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, USERNAME, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob);\n\n // copy from checked out source as checked in\n\n id = objService.createDocumentFromSource(repositoryId, id, null, rootFolderId, VersioningState.MAJOR, null,\n null, null, null);\n ob = getObject(id);\n checkValue(PropertyIds.IS_LATEST_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.IS_LATEST_MAJOR_VERSION, Boolean.TRUE, ob);\n checkValue(PropertyIds.VERSION_LABEL, \"1.0\", ob);\n checkValue(PropertyIds.VERSION_SERIES_ID, NOT_NULL, ob);\n checkValue(PropertyIds.IS_VERSION_SERIES_CHECKED_OUT, Boolean.FALSE, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_ID, null, ob);\n checkValue(PropertyIds.VERSION_SERIES_CHECKED_OUT_BY, null, ob);\n checkValue(PropertyIds.CHECKIN_COMMENT, null, ob);\n checkValue(NuxeoTypeHelper.NX_ISVERSION, Boolean.FALSE, ob); // ...\n }",
"LicenseUpdate create(LicenseUpdate newLicenseUpdate);",
"public static Entity addInstance(Vector3 gridCoordinates, boolean artificial) {\n Entity entity = new Entity();\n entity.setUp(gridCoordinates, artificial);\n return entity;\n }",
"public static Flipkart createFlipkart()throws Exception {\r\n\t\t //create target class obj\r\n\t\t Flipkart fpkt=new Flipkart();\r\n\t\t \r\n\t\t // Load Dependent class \r\n\t\t Class c=Class.forName(props.getProperty(\"dependent.comp\"));\r\n\t\t //create object using refflection object\r\n\t\t Constructor cons[]=c.getDeclaredConstructors();\r\n\t\t //create object\r\n\t\t Courier courier=(Courier) cons[0].newInstance();\r\n\t\t //set Dependent class object to target class obj\r\n\t\t fpkt.setCourier(courier);\r\n\t return fpkt;\r\n }",
"private static void createNewClothing(int aArticle, int aSource, int aTarget, int... components) {\n/* 3446 */ AdvancedCreationEntry article = createAdvancedEntry(10016, aSource, aTarget, aArticle, false, false, 0.0F, true, false, 0, 10.0D, CreationCategories.CLOTHES);\n/* */ \n/* 3448 */ article.setColouringCreation(true);\n/* 3449 */ article.setFinalMaterial((byte)17);\n/* 3450 */ article.setUseTemplateWeight(true);\n/* 3451 */ int x = 1;\n/* 3452 */ for (int component : components)\n/* */ {\n/* 3454 */ article.addRequirement(new CreationRequirement(x++, component, 1, true));\n/* */ }\n/* */ }",
"ManagementLockObject create(Context context);",
"public void saveNew() {\r\n String name, compName;\r\n double price;\r\n int id, inv, max, min, machId;\r\n //Gets the ID of the last part in the inventory and adds 1 to it \r\n id = Inventory.getAllParts().get(Inventory.getAllParts().size() - 1).getId() + 1;\r\n name = nameField.getText();\r\n inv = Integer.parseInt(invField.getText());\r\n price = Double.parseDouble(priceField.getText());\r\n max = Integer.parseInt(maxField.getText());\r\n min = Integer.parseInt(minField.getText());\r\n\r\n if (inHouseSelected) {\r\n machId = Integer.parseInt(machineOrCompanyField.getText());\r\n Part newPart = new InHouse(id, name, price, inv, min, max, machId);\r\n Inventory.addPart(newPart);\r\n } else {\r\n compName = machineOrCompanyField.getText();\r\n Part newPart = new Outsourced(id, name, price, inv, min, max, compName);\r\n Inventory.addPart(newPart);\r\n }\r\n\r\n }",
"public Product build() {\n Product product = new Product();\n product.product_id = this.product_id;\n product.product_name = this.product_name;\n product.price = this.price;\n product.in_stock = this.in_stock;\n product.amount = this.amount;\n product.ordered_amount = this.ordered_amount;\n product.order_price = this.order_price;\n\n return product;\n }",
"@Override\n\tprotected final void performCreateObjects( final ManagerEJB manager, Map params ) throws JaloBusinessException\n\t{\n\t\t// performCreateObjects\n\t\n\t\n\t\tcreateEnumerationValues(\n\t\t\t\"Complexion\",\n\t\t\tfalse,\n\t\t\tArrays.asList( new String[] {\n\t\t\t\n\t\t\t\t\"VeryFair\",\n\t\t\t\t\"Fair\",\n\t\t\t\t\"Wheatish\",\n\t\t\t\t\"DarkBrown\",\n\t\t\t\t\"Black\"\n\t\t\t} )\n\t\t);\n\t\n\t\tsingle_setRelAttributeProperties_Customer2ImageQualityRel_source();\n\t\n\t\tsingle_setRelAttributeProperties_Camera2PromotionsRel_source();\n\t\n\t\tsingle_setRelAttributeProperties_Customer2ImageQualityRel_target();\n\t\n\t\tsingle_setRelAttributeProperties_Camera2PromotionsRel_target();\n\t\n\t\tconnectRelation(\n\t\t\t\"Customer2ImageQualityRel\", \n\t\t\tfalse, \n\t\t\t\"customer\", \n\t\t\t\"Customer\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\t\"imageQuality\", \n\t\t\t\"ImageQuality\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.OPTIONAL_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\ttrue,\n\t\t\ttrue\n\t\t);\n\t\n\t\tconnectRelation(\n\t\t\t\"Camera2PromotionsRel\", \n\t\t\tfalse, \n\t\t\t\"camera\", \n\t\t\t\"CSRCustomerDetails\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.OPTIONAL_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\t\"promotions\", \n\t\t\t\"AbstractPromotion\", \n\t\t\ttrue,\n\t\t\tde.hybris.platform.jalo.type.AttributeDescriptor.READ_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.WRITE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.OPTIONAL_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.REMOVE_FLAG|de.hybris.platform.jalo.type.AttributeDescriptor.SEARCH_FLAG, \n\t\t\ttrue,\n\t\t\ttrue\n\t\t);\n\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tchangeMetaType(\n\t\t\t\t\t\"Customer\",\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\tsingle_setAttributeProperties_Customer_age();\n\t\t\n\t\t\tsingle_setAttributeProperties_Customer_complexion();\n\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tsetItemTypeProperties(\n\t\t\t\t\t\"ImageQuality\",\n\t\t\t\t\tfalse,\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\tsingle_setAttributeProperties_ImageQuality_qualityScore();\n\t\t\n\t\t\tsingle_setAttributeProperties_ImageQuality_identityId();\n\t\t\n\t\t\tsingle_setAttributeProperties_ImageQuality_imagePath();\n\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tsetItemTypeProperties(\n\t\t\t\t\t\"FaceRecognitionComponent\",\n\t\t\t\t\tfalse,\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tchangeMetaType(\n\t\t\t\t\t\"CSRCustomerDetails\",\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_complexion();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_imageUrl();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_age();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_gender();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_devicetoken();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_cameraid();\n\t\t\n\t\t\tsingle_setAttributeProperties_CSRCustomerDetails_welcomeMessage();\n\t\t\n\t\t\t\t{\n\t\t\t\tMap customPropsMap = new HashMap();\n\t\t\t\t\n\t\t\t\tsetItemTypeProperties(\n\t\t\t\t\t\"PersistCustomerImagesCronJob\",\n\t\t\t\t\tfalse,\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull,\n\t\t\t\t\tcustomPropsMap\n\t\t\t\t);\n\t\t\t\t}\n\t\t\t\n\t\t\t\tsetDefaultProperties(\n\t\t\t\t\t\"Complexion\",\n\t\t\t\t\ttrue,\n\t\t\t\t\ttrue,\n\t\t\t\t\tnull\n\t\t\t\t);\n\t\t\t\n\t}",
"private LCSRevisableEntity createEntries(String selectedId) {\n\t\t\n\t\tLCSRevisableEntity revEntity=null;\n\n\t\tLCSProduct product = null;\n\t\tLCSSKU lcsSku = null;\n\t\tString sizedefVR = \"\";\n\t\tString prodVR = \"\";\n\t\tString colorwayVR = \"\";\n\t\tString reventityVR = \"\";\n\t\t\n\t\tLCSLog.debug(\"****************Inside createEntries ***********************\");\n\t\t/*\n\t\t * is found in the request object.\n\t\t */\n\t\t// get division code from request.\n\t\tString divcode = this.requesttable.get(selectedId + \"_DIVISION_CODE\");\n\t\t// get material number from request\n\t\tString materialNumber = divcode\n\t\t\t\t+ this.requesttable.get(selectedId + \"_MATERIALNUMBER\");\n\t\t// get nrf code from request\n\t\tString nrfCode = \"\";\n\t\t// this.requesttable.get(selectedId + \"_NRF_CODE\");\n\t\t// get sourceVersion from request\n\t\tString sourceVersion = this.requesttable.get(selectedId + \"_SOURCE\");\n\t\t// get costsheetVersion from request\n\t\tString costsheetVersion = this.requesttable.get(selectedId + \"_COST\");\n\t\t\n\t\tString specVersion = this.requesttable.get(selectedId + \"_SPEC\");\n\t\t\n\t\tString bomRequestParam = this.requesttable.get(\"BOM\"+selectedId + \"_BOM\");\n\t\tLCSLog.debug(\"bomRequestParam = \"+bomRequestParam);\n\n\t\tString sourceName = \"\";\n\t\tString costName = \"\";\n\t\tString specName = \"\";\n\t\tString IBTINSTOREMONTH = \"\";\n\n\t\ttry {\n\t\t\t// get all the information from sourceVersion and costsheetVersion\n\t\t\tMap<String, String> map = LFIBTUtil.formatSourceOrCostsheetData(\n\t\t\t\t\tsourceVersion, costsheetVersion, specVersion);\n\t\t\t\n\t\t\t// source name\n\t\t\tsourceName = map.get(\"sourceNameKey\");\n\t\t\t// versionId\n\t\t\tsourceVersion = map.get(\"sourceVersionKey\"); \n\t\t\tLCSLog.debug(\"sourceName --- \" + sourceName);\n\t\t\t// costsheet name\n\t\t\tcostName = map.get(\"costNameKey\");\n\n\t\t\t// costsheetId\n\t\t\tcostsheetVersion = map.get(\"costsheetVersionKey\");\n\t\t\tLCSLog.debug(\"costName --- \" + costName);\n\t\t\t\n\t\t\tspecName = map.get(\"specNameKey\");\n\n\t\t\t// costsheetId\n\t\t\tspecVersion = map.get(\"specVersionKey\");\n\t\t\tLCSLog.debug(\"costName --- \" + costName);\t\t\t\n\n\t\t\tCollection<String> bomMOAStringColl = new ArrayList<String>();\n\t\t\tbomMOAStringColl = LFIBTUtil.formatBOMMultiChoiceValues(bomRequestParam);\n\t\t\t\n\t\t\tList<String> idList = LFIBTUtil.getObjects(selectedId);\n\n\t\t\t// parse and get all data\n\t\t\tMap<String, String> idMap = LFIBTUtil\n\t\t\t\t\t.createCustomMapFromList(idList);\n\t\t\t// get product ID\n\t\t\tprodVR = idMap.get(\"prodVR\");\n\n\t\t\tLCSLog.debug(\"prodVR : --\" + prodVR);\n\t\t\t// get the product object from productVR\n\t\t\tproduct = (LCSProduct) LCSProductQuery\n\t\t\t\t\t.findObjectById(\"VR:com.lcs.wc.product.LCSProduct:\"\n\t\t\t\t\t\t\t+ prodVR);\n\n\t\t\tLCSLog.debug(\"product : --\" + product);\n\n\t\t\t// size definition VR\n\t\t\tsizedefVR = idMap.get(\"sizedefVR\");\n\t\t\tLCSLog.debug(\"sizedefVR -- \" + sizedefVR);\n\n\t\t\t// colorway VR\n\t\t\tcolorwayVR = idMap.get(\"colorwayVR\");\n\t\t\tLCSLog.debug(\"colorwayVR : --\" + colorwayVR);\n\t\t\tlcsSku = (LCSSKU) LCSProductQuery\n\t\t\t\t\t.findObjectById(\"VR:com.lcs.wc.product.LCSSKU:\"\n\t\t\t\t\t\t\t+ colorwayVR);\n\n\t\t\t// NRF Code -- Build 5.16\n\t\t\tDouble d = 0.00;\n\t\t\td = (Double) lcsSku.getValue(\"lfNrfColorCode\");\n\t\t\tnrfCode = StringUtils.substringBeforeLast(Double.toString(d), \".\");\n\n\t\t\t/**\n\t\t\t * Build 5.16_3 -> START\n\t\t\t * Formatting NRF code to 3 digits before sending it to SAP\n\t\t\t */\n\t\t\t// getting length of code value\n\t\t\tint nrfCodeValueLength = nrfCode.length();\n\t\t\t// TRUE - if length is 1 or 2 digit\n\t\t\tif (nrfCodeValueLength == 2 || nrfCodeValueLength == 1) {\n\t\t\t\t// converting the value from double to integer\n\t\t\t\tint y = d.intValue();\n\t\t\t\t// formatting the value to be 3 digit always.\n\t\t\t\t// if not, append 0 to left\n\t\t\t\tnrfCode = (String.format(\"%03d\", y)).toString();\n\t\t\t}\n\t\t\t/**\n\t\t\t * Build 5.16_3 -> END\n\t\t\t */\n\n\t\t\t// get the revisable entity VR if applicable\n\t\t\treventityVR = idMap.get(\"reventityVR\");\n\n\t\t\t// Added for Build 6.14\n\t\t\t// ITC-START\n\t\t\tString materialDescription = this.requesttable.get(selectedId\n\t\t\t\t\t+ \"_MATERIALDESC\");\n\t\t\tIBTINSTOREMONTH = this.requesttable.get(selectedId + \"_INSTOREMONTH\");\n\t\t\tString styleNumber = this.requesttable.get(selectedId + \"_STYLE\");\n\t\t\t// ITC-END\n\t\t\t\n\t\t\t//MM : changes : Start ----\n\t\t\tif(!FormatHelper.hasContent(reventityVR))\n\t\t\t\treventityVR = LFIBTMaterialNumberValidator.getExistingMaterialRecords(materialNumber,false);\n\t\t\t//MM : changes : End ----\n\t\t\t/*\n\t\t\t * If the revisable entity VR exists then update the revisable\n\t\t\t * entity else create a new one.\n\t\t\t */\n\t\t\tif (reventityVR != null) \n\t\t\t{\n\t\t\t\tLCSLog.debug(\"sourceVersion -- \" + sourceVersion\n\t\t\t\t\t\t+ \" costsheetVersion - \" + costsheetVersion\n\t\t\t\t\t\t+ \" nrfCode -- \" + nrfCode\n\t\t\t\t\t\t+ \" materialDescription --\" + materialDescription\n\t\t\t\t\t\t+ \" IBTINSTOREMONTH--\" + IBTINSTOREMONTH\n\t\t\t\t\t\t+ \" style Number----\" + styleNumber);\n\n\t\t\t\t// API call to update the revisable entitity with new\n\t\t\t\t// source and cost details.\n\n\t\t\t\t// Updated for Build 6.14\n\t\t\t\tLCSLog.debug(CLASSNAME+\"createEntries()\"+\"calling updateRevisableEntry()\");\n\t\t\t\trevEntity=updateRevisableEntry(reventityVR, sourceVersion,\n\t\t\t\t\t\tcostsheetVersion,specVersion, nrfCode, materialDescription,\n\t\t\t\t\t\tsourceName, costName,specName, IBTINSTOREMONTH, styleNumber,bomMOAStringColl);\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"update revEntity---->\" +revEntity);\n\t\t\t}\n\t\t\telse {\n\t\t\t\t// API call to create fresh revisable entities.\n\n\t\t\t\t// Updated for Build 6.14\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"createEntries()\"+\"calling createRevisableEntry()\");\n\t\t\t\trevEntity=createRevisableEntry(product, lcsSku, materialNumber,\n\t\t\t\t\t\tsizedefVR, sourceVersion, costsheetVersion, specVersion, sourceName,\n\t\t\t\t\t\tcostName, specName, nrfCode, styleNumber, materialDescription,\n\t\t\t\t\t\tIBTINSTOREMONTH,bomMOAStringColl);\n\t\t\t\t\n\t\t\t\tLCSLog.debug(CLASSNAME+\"create revEntity---->\" +revEntity);\n\n\t\t\t}\n\t\t\t\n\n\t\t}\n\t\tcatch (WTException e) {\n\t\t\tLCSLog.error(\"WTException occurred!! \" + e.getMessage());\n\t\t}\n\t\tcatch (WTPropertyVetoException e) {\n\t\t\tLCSLog.error(\"WTPropertyVetoException occurred!! \" + e.getMessage());\n\t\t}\n\t\t\t\t\n\t\treturn revEntity;\n\n\t}",
"public Arguments create() throws IOException {\r\n Arguments args = new Arguments();\r\n ArrayList vmArgs = new ArrayList();\r\n \r\n // Start empty framework\r\n if (clean) {\r\n // Remove bundle directories\r\n File[] children = workDir.listFiles();\r\n for (int i=0; i<children.length; i++) {\r\n if (children[i].isDirectory() && children[i].getName().startsWith(\"bundle\")) {\r\n deleteDir(children[i]);\r\n }\r\n }\r\n }\r\n \r\n // Create system properties file\r\n File systemPropertiesFile = new File(workDir, \"system.properties\");\r\n Path path = new Path(systemPropertiesFile.getAbsolutePath());\r\n vmArgs.add(\"-Doscar.system.properties=\"+path.toString());\r\n \r\n // Set bundle cache dir\r\n writeProperty(systemPropertiesFile, PROPERTY_CACHE_DIR, new Path(workDir.getAbsolutePath()).toString(), false);\r\n \r\n // Set start level\r\n writeProperty(systemPropertiesFile, PROPERTY_STARTLEVEL, Integer.toString(startLevel), true);\r\n \r\n // System properties\r\n if (systemProperties != null) {\r\n for(Iterator i=systemProperties.entrySet().iterator();i.hasNext();) {\r\n Map.Entry entry = (Map.Entry) i.next();\r\n writeProperty(systemPropertiesFile, (String) entry.getKey(), (String) entry.getValue(), true);\r\n }\r\n }\r\n\r\n // Add bundle\r\n StringBuffer autoStart = new StringBuffer(\"\");\r\n StringBuffer autoInstall = new StringBuffer(\"\");\r\n for (Iterator i=bundles.entrySet().iterator();i.hasNext();) {\r\n Map.Entry entry = (Map.Entry) i.next();\r\n Integer level = (Integer) entry.getKey();\r\n \r\n // Add bundle install entries for this start level\r\n ArrayList l = (ArrayList) entry.getValue();\r\n autoStart.setLength(0);\r\n autoInstall.setLength(0);\r\n for (Iterator j = l.iterator() ; j.hasNext() ;) {\r\n BundleElement e = (BundleElement) j.next();\r\n if (e.getLaunchInfo().getMode() == BundleLaunchInfo.MODE_START) {\r\n if (autoStart.length()>0) {\r\n autoStart.append(\" \");\r\n }\r\n autoStart.append(\"file:\");\r\n autoStart.append(new Path(e.getBundle().getPath()).toString());\r\n } else {\r\n if (autoInstall.length()>0) {\r\n autoInstall.append(\" \");\r\n }\r\n autoInstall.append(\"file:\");\r\n autoInstall.append(new Path(e.getBundle().getPath()).toString());\r\n }\r\n }\r\n if (autoInstall.length()>0) {\r\n writeProperty(systemPropertiesFile, PROPERTY_AUTO_INSTALL+level, autoInstall.toString(), true);\r\n }\r\n if (autoStart.length()>0) {\r\n writeProperty(systemPropertiesFile, PROPERTY_AUTO_START+level, autoStart.toString(), true);\r\n }\r\n }\r\n \r\n args.setVMArguments((String[]) vmArgs.toArray(new String[vmArgs.size()]));\r\n return args;\r\n }",
"Active_Digital_Artifact createActive_Digital_Artifact();",
"public CreateElectionParametersOptions(final File publish, final String name, final boolean noTellers, final int numberOfTellers, final int thresholdTellers,\n final int dsaL, final int dsaN, final int primeCertainty) {\n this.publish = publish;\n this.name = name;\n this.noTellers = noTellers;\n this.numberOfTellers = numberOfTellers;\n this.thresholdTellers = thresholdTellers;\n this.dsaL = dsaL;\n this.dsaN = dsaN;\n this.primeCertainty = primeCertainty;\n }",
"@Override\n\tpublic boolean create(Langues obj) {\n\t\treturn false;\n\t}",
"@Override\n public Order createOrder(int stockId, int partyId, int userId, boolean isBuy, BigDecimal price, int size) throws\n InvalidEntityException,\n MissingEntityException,\n IOException {\n Stock stock = stockDao.getStockById(stockId).get();\n User user = userDao.getUserById(userId).get();\n Party party = partyDao.getPartyById(partyId).get();\n LocalDateTime versionTime = LocalDateTime.now();\n Order order = new Order(user, party, stock, price, size, isBuy, PENDING, versionTime);\n order = orderDao.createOrder(order);\n auditDao.writeMessage(\"Add Order: \" + order.getId() + \" to Repository, userId: \" + userId);\n // sets status\n matchOrder(order);\n if (order.getStatus() == PENDING) {\n order.setStatus(ACTIVE);\n orderDao.editOrder(order);\n }\n return order;\n }",
"Article createArticle();",
"@IID(\"{87B013CA-DE17-495F-B9D5-D8B7901FCB4D}\")\npublic interface IVersionedEntitiesFactory extends Com4jObject {\n // Methods:\n /**\n * <p>\n * For HP use. Returns the specified version of the item. Applies only to the Tests entity.\n * </p>\n * @param itemKey Mandatory java.lang.Object parameter.\n * @param versionNumber Mandatory int parameter.\n * @return Returns a value of type com4j.Com4jObject\n */\n\n @DISPID(1) //= 0x1. The runtime will prefer the VTID if present\n @VTID(7)\n @ReturnValue(type=NativeType.Dispatch)\n Com4jObject viewVersion(\n @MarshalAs(NativeType.VARIANT) Object itemKey,\n int versionNumber);\n\n\n /**\n * <p>\n * Returns the number of entities of the type managed by this factory that are checked out by the current user.\n * </p>\n * <p>\n * Getter method for the COM property \"CheckedOutEntitiesCount\"\n * </p>\n * @return Returns a value of type int\n */\n\n @DISPID(2) //= 0x2. The runtime will prefer the VTID if present\n @VTID(8)\n int checkedOutEntitiesCount();\n\n\n /**\n * <p>\n * For HP use. Multiple check-in of entities.\n * </p>\n * @param pList Mandatory DDDD.IList parameter.\n * @param comments Mandatory java.lang.String parameter.\n */\n\n @DISPID(3) //= 0x3. The runtime will prefer the VTID if present\n @VTID(9)\n void checkInEntities(\n IList pList,\n String comments);\n\n\n /**\n * <p>\n * For HP use. Multiple check out of entities.\n * </p>\n * @param pList Mandatory DDDD.IList parameter.\n * @param comments Mandatory java.lang.String parameter.\n */\n\n @DISPID(4) //= 0x4. The runtime will prefer the VTID if present\n @VTID(10)\n void checkOutEntities(\n IList pList,\n String comments);\n\n\n /**\n * <p>\n * For HP use. Multiple undo check out of entities.\n * </p>\n * @param pList Mandatory DDDD.IList parameter.\n */\n\n @DISPID(5) //= 0x5. The runtime will prefer the VTID if present\n @VTID(11)\n void undoCheckOutEntities(\n IList pList);\n\n\n // Properties:\n}",
"public interface MissionFactory extends EFactory {\r\n\t/**\r\n\t * The singleton instance of the factory.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @generated\r\n\t */\r\n\tMissionFactory eINSTANCE = it.univaq.flyaq.mission.impl.MissionFactoryImpl.init();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Mission</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Mission</em>'.\r\n\t * @generated\r\n\t */\r\n\tMission createMission();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Swarm</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Swarm</em>'.\r\n\t * @generated\r\n\t */\r\n\tSwarm createSwarm();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Drone</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Drone</em>'.\r\n\t * @generated\r\n\t */\r\n\tDrone createDrone();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Fork</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Fork</em>'.\r\n\t * @generated\r\n\t */\r\n\tFork createFork();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Join</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Join</em>'.\r\n\t * @generated\r\n\t */\r\n\tJoin createJoin();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Task Dependency</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Task Dependency</em>'.\r\n\t * @generated\r\n\t */\r\n\tTaskDependency createTaskDependency();\r\n\r\n\t/**\r\n\t * Returns a new object of class '<em>Coordinate</em>'.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return a new object of class '<em>Coordinate</em>'.\r\n\t * @generated\r\n\t */\r\n\tCoordinate createCoordinate();\r\n\r\n\t/**\r\n\t * Returns the package supported by this factory.\r\n\t * <!-- begin-user-doc -->\r\n\t * <!-- end-user-doc -->\r\n\t * @return the package supported by this factory.\r\n\t * @generated\r\n\t */\r\n\tMissionPackage getMissionPackage();\r\n\r\n}",
"public static Potion buildFromFullData(SceneObjectSaveData data) \n {\n \n Potion consumable = new Potion();\n \n return consumable;\n }",
"public void create(){}",
"private void processNewObject(SystemMetadata mnSystemMetadata) throws SynchronizationFailed, \n RetryableException, UnrecoverableException {\n\n // TODO: should new objects from replica nodes process or throw SyncFailed?\n // as per V1 logic (TransferObjectTask), this class currently does not check\n // the authoritativeMN field and allows the object to sync.\n logger.debug(task.taskLabel() + \" entering processNewObject...\");\n \n \n try {\n \tvalidateSeriesId(mnSystemMetadata, null); \n } catch (NotAuthorized e) {\n logger.error(buildStandardLogMessage(e, \"NotAuthorized to claim the seriesId\"), e);\n throw SyncFailedTask.createSynchronizationFailed(mnSystemMetadata.getIdentifier().getValue(),\n \"NotAuthorized to claim the seriesId\", e);\n }\n \n try {\n\n // make sure the pid is not reserved by anyone else\n // not going through TLS, so need to build a Session, and will use the submitter\n // in the systemMetadata, since they should have access to their own reservation(?)\n Session verifySubmitter = new Session();\n verifySubmitter.setSubject(mnSystemMetadata.getSubmitter());\n identifierReservationService.hasReservation(verifySubmitter, mnSystemMetadata.getSubmitter(), mnSystemMetadata.getIdentifier());\n logger.debug(task.taskLabel() + \" Pid is reserved by this object's submitter.\");\n\n } catch (NotFound e) {\n logger.debug(task.taskLabel() + \" Pid is not reserved by anyone.\");\n // ok to continue...\n \n } catch (NotAuthorized | InvalidRequest e) {\n throw new UnrecoverableException(task.getPid() + \" - from hasReservation\",e);\n \n } catch (ServiceFailure e) {\n extractRetryableException(e);\n throw new UnrecoverableException(task.getPid() + \" - from hasReservation\",e);\n }\n\n mnSystemMetadata = populateInitialReplicaList(mnSystemMetadata);\n mnSystemMetadata.setSerialVersion(BigInteger.ONE);\n try {\n SystemMetadataValidator.validateCNRequiredNonNullFields(mnSystemMetadata);\n\n createObject(mnSystemMetadata);\n } catch (InvalidSystemMetadata e) {\n throw SyncFailedTask.createSynchronizationFailed(task.getPid(), null, e);\n }\n finally{};\n }",
"Motivo create(Motivo motivo);",
"SpaceInvaderTest_VaisseauAvance_DeplacerVaisseauVersLaGauche createSpaceInvaderTest_VaisseauAvance_DeplacerVaisseauVersLaGauche();",
"public interface VmFactory extends EFactory {\n\t/**\n\t * The singleton instance of the factory.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @generated\n\t */\n\tVmFactory eINSTANCE = fr.inria.sed.logo.vm.model.vm.impl.VmFactoryImpl.init();\n\n\t/**\n\t * Returns a new object of class '<em>Interpreter Runtime Context</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Interpreter Runtime Context</em>'.\n\t * @generated\n\t */\n\tInterpreterRuntimeContext createInterpreterRuntimeContext();\n\n\t/**\n\t * Returns a new object of class '<em>Turtle</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Turtle</em>'.\n\t * @generated\n\t */\n\tTurtle createTurtle();\n\n\t/**\n\t * Returns a new object of class '<em>Point</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Point</em>'.\n\t * @generated\n\t */\n\tPoint createPoint();\n\n\t/**\n\t * Returns a new object of class '<em>Segment</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Segment</em>'.\n\t * @generated\n\t */\n\tSegment createSegment();\n\n\t/**\n\t * Returns a new object of class '<em>Param Map Entry</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Param Map Entry</em>'.\n\t * @generated\n\t */\n\tParamMapEntry createParamMapEntry();\n\n\t/**\n\t * Returns a new object of class '<em>Param Map</em>'.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return a new object of class '<em>Param Map</em>'.\n\t * @generated\n\t */\n\tParamMap createParamMap();\n\n\t/**\n\t * Returns the package supported by this factory.\n\t * <!-- begin-user-doc -->\n\t * <!-- end-user-doc -->\n\t * @return the package supported by this factory.\n\t * @generated\n\t */\n\tVmPackage getVmPackage();\n\n}",
"void create(Order order);",
"public MappedModelEVO create(MappedModelEVO evo) throws Exception {\n\t MappedModelPK local = this.server.ejbCreate(evo);\r\n MappedModelEVO newevo = this.server.getDetails(\"<UseLoadedEVOs>\");\r\n MappedModelPK pk = newevo.getPK();\r\n this.mLocals.put(pk, local);\r\n return newevo;\r\n }",
"@Test\r\n public void testCreate() throws Exception {\r\n PodamFactory pf=new PodamFactoryImpl();\r\n MonitoriaEntity nuevaEntity=pf.manufacturePojo(MonitoriaEntity.class);\r\n MonitoriaEntity respuestaEntity=persistence.create(nuevaEntity);\r\n Assert.assertNotNull(respuestaEntity);\r\n Assert.assertEquals(respuestaEntity.getId(), nuevaEntity.getId());\r\n Assert.assertEquals(respuestaEntity.getIdMonitor(), nuevaEntity.getIdMonitor());\r\n Assert.assertEquals(respuestaEntity.getTipo(), nuevaEntity.getTipo());\r\n \r\n \r\n }",
"public Version saveVersion(CreateVersionRequest createVersionRequest) {\n return saveVersion(Version.fromRequest(createVersionRequest));\n }",
"public static native void OpenMM_AmoebaVdwForce_setParticleParameters(PointerByReference target, int particleIndex, int parentIndex, double sigma, double epsilon, double reductionFactor, int isAlchemical);",
"@Test(dependsOnMethods = \"checkSiteVersion\")\n public void createNewOrder() {\n actions.openRandomProduct();\n\n // save product parameters\n actions.saveProductParameters();\n\n // add product to Cart and validate product information in the Cart\n actions.addToCart();\n actions.goToCart();\n actions.validateProductInfo();\n\n // proceed to order creation, fill required information\n actions.proceedToOrderCreation();\n\n // place new order and validate order summary\n\n // check updated In Stock value\n }",
"public VcmsArticleType create(\n\t\tvn.gov.hoabinh.service.persistence.VcmsArticleTypePK vcmsArticleTypePK);",
"TestEntity buildEntity () {\n TestEntity testEntity = new TestEntity();\n testEntity.setName(\"Test name\");\n testEntity.setCheck(true);\n testEntity.setDateCreated(new Date(System.currentTimeMillis()));\n testEntity.setDescription(\"description\");\n\n Specialization specialization = new Specialization();\n specialization.setName(\"Frontend\");\n specialization.setLevel(\"Senior\");\n specialization.setYears(10);\n\n testEntity.setSpecialization(specialization);\n\n return testEntity;\n }"
] | [
"0.58581316",
"0.5355499",
"0.4871697",
"0.47949374",
"0.47017917",
"0.46562758",
"0.46145195",
"0.45564097",
"0.45446816",
"0.4501527",
"0.44848543",
"0.44790742",
"0.44635114",
"0.44631967",
"0.4455026",
"0.44400018",
"0.4432092",
"0.44299987",
"0.442183",
"0.44192076",
"0.43881032",
"0.43735185",
"0.43685555",
"0.4359653",
"0.43574795",
"0.4350909",
"0.43505827",
"0.4348951",
"0.43299684",
"0.43258563",
"0.43146175",
"0.43121976",
"0.42884395",
"0.42829818",
"0.4280861",
"0.42749643",
"0.42723152",
"0.42668402",
"0.42585784",
"0.4257985",
"0.42570984",
"0.4252274",
"0.42511317",
"0.42482322",
"0.42465755",
"0.42422426",
"0.42388797",
"0.42342335",
"0.42244512",
"0.42186043",
"0.4216831",
"0.4215737",
"0.42087594",
"0.4207683",
"0.42001882",
"0.4200071",
"0.41992104",
"0.4198307",
"0.419788",
"0.41801205",
"0.4177469",
"0.41727966",
"0.41666567",
"0.41627732",
"0.4158741",
"0.41516727",
"0.4151376",
"0.41492257",
"0.41480744",
"0.4146845",
"0.41465858",
"0.41440544",
"0.41382295",
"0.4134682",
"0.41283476",
"0.41116977",
"0.41068664",
"0.41014624",
"0.40979967",
"0.4096216",
"0.40944654",
"0.4090482",
"0.40903845",
"0.40872574",
"0.40767938",
"0.4075899",
"0.40748838",
"0.40717834",
"0.40701395",
"0.40700105",
"0.40672004",
"0.40671334",
"0.4064942",
"0.40632",
"0.40601042",
"0.4058274",
"0.4057706",
"0.4056233",
"0.40562055",
"0.40560845"
] | 0.6381631 | 0 |
creates a new empty object which can be used to set properties and then submitted to the createNewObject function | public abstract OwObjectSkeleton createObjectSkeleton(OwObjectClass objectclass_p, OwResource resource_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"OBJECT createOBJECT();",
"public void create(){}",
"private SingleObject(){}",
"private SingleObject()\r\n {\r\n }",
"public ObjectFactory() {}",
"public ObjectFactory() {}",
"public ObjectFactory() {}",
"public ObjectFactory() {\r\n\t}",
"@Override\r\n\tpublic boolean create(Jeu obj) {\n\t\treturn false;\r\n\t}",
"public ObjectFactory() {\n\t}",
"@Test\n public void Constructor_ObjectValues_InstanceCreated() {\n\t\ttry {\n Position position = make_PositionWithIntegerPoints(xCoordinate, yCoordinate, direction);\n Surface surface = make_SurfaceWithGivenDimensions(xDimension, yDimension);\n\t\t\tRover rover = make_RoverWithObjectValues(position, surface);\n\t\t}\n\t\tcatch (AssertionError assErr) {\n\t\t\t// Test passed.\n\t\t\treturn;\n\t\t}\n }",
"public void create() {\n\t\t\n\t}",
"public abstract T create(T obj);",
"public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,\r\n OwObject parent_p, String strMimeType_p, String strMimeParameter_p, boolean fKeepCheckedOut_p) throws Exception;",
"public DBObject createNew() {\n DBObjectImpl obj = (DBObjectImpl) getNewObject();\n obj.DELETE_STMT_STR = DELETE_STMT_STR;\n obj.INSERT_STMT_STR = INSERT_STMT_STR;\n obj.UPDATE_STMT_STR = UPDATE_STMT_STR;\n obj.QUERY_STMT_STR = QUERY_STMT_STR;\n\n return obj;\n }",
"public abstract String createNewObject(boolean fPromote_p, Object mode_p, OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p,\r\n OwObject parent_p, String strMimeType_p, String strMimeParameter_p) throws Exception;",
"public abstract String createNewObject(OwResource resource_p, String strObjectClassName_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwContentCollection content_p, OwObject parent_p, String strMimeType_p,\r\n String strMimeParameter_p) throws Exception;",
"private SingleObject(){\n }",
"public ObjectFactory() {\n super(grammarInfo);\n }",
"private void createObject(JSONObject delivery) {\n\t\t//TODO: create the Object\n\t}",
"@Override\r\n\tpublic void create() {\n\t\t\r\n\t}",
"RentalObject createRentalObject();",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"public ObjectFactory() {\r\n }",
"Object create(Object source);",
"public LocalObject() {}",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }",
"public ObjectFactory() {\n }"
] | [
"0.68846124",
"0.6564999",
"0.65323025",
"0.6491341",
"0.6351126",
"0.6351126",
"0.6351126",
"0.6319165",
"0.63125306",
"0.6280197",
"0.627463",
"0.62363005",
"0.62218916",
"0.6196228",
"0.6186515",
"0.61478055",
"0.61267835",
"0.6118459",
"0.6099918",
"0.6099479",
"0.6086609",
"0.60623527",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6040902",
"0.6037393",
"0.60369563",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481",
"0.6032481"
] | 0.0 | -1 |
creates a cloned object with new properties on the ECM system copies the content as well | public abstract String createObjectCopy(OwObject obj_p, OwPropertyCollection properties_p, OwPermissionCollection permissions_p, OwObject parent_p, int[] childTypes_p) throws Exception; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CMObject copyOf();",
"Object clone();",
"Object clone();",
"public DescriptiveFramework clone();",
"public void testCopyConstructor() throws EdmException {\n entity = new EdmEntity(\"example.edl\");\n EdmAttribute a1 = setupAttribute(val1);\n EdmAttribute a2 = setupAttribute(val2);\n entity.addAttribute(id1, a1);\n entity.addAttribute(id2, a2);\n // add subEntity\n EdmEntity subE = new EdmEntity(\"SUBexample.edl\");\n EdmAttribute a3 = setupAttribute(val3);\n subE.addAttribute(id3, a3);\n entity.addSubEntity(subE);\n\n assertEquals(\"example.edl\", entity.getType());\n assertEquals(2, entity.getAttributeCount());\n assertEquals(a1, entity.getAttribute(id1));\n assertEquals(a2, entity.getAttribute(id2));\n\n assertEquals(1, entity.getSubEntityCount());\n assertEquals(\"SUBexample.edl\", entity.getSubEntity(0).getType());\n assertEquals(1, entity.getSubEntity(0).getAttributeCount());\n assertEquals(0, entity.getSubEntity(0).getSubEntityCount());\n assertEquals(a3, entity.getSubEntity(0).getAttribute(id3));\n\n\n EdmEntity copy = new EdmEntity(entity);\n\n assertEquals(entity.getType(), copy.getType());\n assertEquals(entity.getAttributeCount(), copy.getAttributeCount());\n for (String key : copy.getAttributeIdSet())\n assertEquals(entity.getAttribute(key), copy.getAttribute(key));\n\n assertEquals(entity.getSubEntityCount(), copy.getSubEntityCount());\n for (int i = 0; i < copy.getSubEntityCount(); i++) {\n assertEquals(entity.getSubEntity(i).getType(), copy.getSubEntity(i).getType());\n assertEquals(entity.getSubEntity(i).getAttributeCount(),\n copy.getSubEntity(i).getAttributeCount());\n for (String key : copy.getSubEntity(i).getAttributeIdSet())\n assertEquals(entity.getSubEntity(i).getAttribute(key),\n copy.getSubEntity(i).getAttribute(key));\n }\n }",
"@Override\n public Object clone() {\n return super.clone();\n }",
"Component deepClone();",
"public Scm clone()\n {\n try\n {\n Scm copy = (Scm) super.clone();\n\n if ( copy.locations != null )\n {\n copy.locations = new java.util.LinkedHashMap( copy.locations );\n }\n\n return copy;\n }\n catch ( java.lang.Exception ex )\n {\n throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName()\n + \" does not support clone()\" ).initCause( ex );\n }\n }",
"public Object clone()\n {\n PSRelation copy = new PSRelation(new PSCollection(m_keyNames.iterator()),\n new PSCollection(m_keyValues.iterator()));\n \n copy.m_componentState = m_componentState;\n copy.m_databaseComponentId = m_databaseComponentId;\n copy.m_id = m_id;\n\n return copy;\n }",
"public Object clone() {\n // No problems cloning here since private variables are immutable\n return super.clone();\n }",
"@NoProxy\n public void copyTo(final BwEvent ev) {\n super.copyTo(ev);\n ev.setEntityType(getEntityType());\n ev.setName(getName());\n ev.setClassification(getClassification());\n ev.setDtstart(getDtstart());\n ev.setDtend(getDtend());\n ev.setEndType(getEndType());\n ev.setDuration(getDuration());\n ev.setNoStart(getNoStart());\n\n ev.setLink(getLink());\n ev.setGeo(getGeo());\n ev.setDeleted(getDeleted());\n ev.setStatus(getStatus());\n ev.setCost(getCost());\n\n BwOrganizer org = getOrganizer();\n if (org != null) {\n org = (BwOrganizer)org.clone();\n }\n ev.setOrganizer(org);\n\n ev.setDtstamp(getDtstamp());\n ev.setLastmod(getLastmod());\n ev.setCreated(getCreated());\n ev.setStag(getStag());\n ev.setPriority(getPriority());\n ev.setSequence(getSequence());\n\n ev.setLocation(getLocation());\n\n ev.setUid(getUid());\n ev.setTransparency(getTransparency());\n ev.setPercentComplete(getPercentComplete());\n ev.setCompleted(getCompleted());\n\n ev.setCategories(copyCategories());\n\n ev.setContacts(copyContacts());\n\n ev.setAttendees(cloneAttendees());\n ev.setCtoken(getCtoken());\n\n ev.setRecurrenceId(getRecurrenceId());\n ev.setRecurring(getRecurring());\n if (ev.isRecurringEntity()) {\n ev.setRrules(clone(getRrules()));\n ev.setExrules(clone(getExrules()));\n ev.setRdates(clone(getRdates()));\n ev.setExdates(clone(getExdates()));\n }\n\n ev.setScheduleMethod(getScheduleMethod());\n ev.setOriginator(getOriginator());\n\n /* Don't copy these - we always set them anyway\n if (getNumRecipients() > 0) {\n ev.setRecipients(new TreeSet<String>());\n\n for (String s: getRecipients()) {\n ev.addRecipient(s);\n }\n }*/\n\n if (getNumComments() > 0) {\n ev.setComments(null);\n\n for (final BwString str: getComments()) {\n ev.addComment((BwString)str.clone());\n }\n }\n\n if (getNumSummaries() > 0) {\n ev.setSummaries(null);\n\n for (final BwString str: getSummaries()) {\n ev.addSummary((BwString)str.clone());\n }\n }\n\n if (getNumDescriptions() > 0) {\n ev.setDescriptions(null);\n\n for (final BwLongString str: getDescriptions()) {\n ev.addDescription((BwLongString)str.clone());\n }\n }\n\n if (getNumResources() > 0) {\n ev.setResources(null);\n\n for (final BwString str: getResources()) {\n ev.addResource((BwString)str.clone());\n }\n }\n\n if (getNumXproperties() > 0) {\n ev.setXproperties(null);\n\n for (final BwXproperty x: getXproperties()) {\n ev.addXproperty((BwXproperty)x.clone());\n }\n }\n\n ev.setScheduleState(getScheduleState());\n\n //ev.setRequestStatuses(clone(getRequestStatuses()));\n\n final BwRelatedTo rt = getRelatedTo();\n if (rt != null) {\n ev.setRelatedTo((BwRelatedTo)rt.clone());\n }\n\n /* These are in x-props in 3.10\n ev.setPollMode(getPollMode());\n ev.setPollProperties(getPollProperties());\n ev.setPollAcceptResponse(getPollAcceptResponse());\n\n ev.setPollItemId(getPollItemId());\n if (!Util.isEmpty(getPollItems())) {\n for (final String s: getPollItems()) {\n ev.addPollItem(s);\n }\n }\n */\n\n ev.setPollCandidate(getPollCandidate());\n }",
"public static void main(String[] args) throws CloneNotSupportedException\n {\n ArrayList<String> companies = new ArrayList<String>();\n companies.add(\"Baidu\");\n companies.add(\"Tencent\");\n companies.add(\"Ali\");\n WorkExprience workExprience = new WorkExprience(companies);\n String nameString = new String(\"Tom\");\n String genderString = new String(\"male\");\n Resume resume = new Resume(nameString, 23, genderString, workExprience);\n System.out.println(\"Source Resume\");\n resume.printResum();\n \n ArrayList<String> companies1 = new ArrayList<String>();\n companies1.add(\"Google\");\n companies1.add(\"Microsoft\");\n companies1.add(\"Oracle\");\n Resume copyResume = (Resume)resume.clone();\n String nameString1 = new String(\"Jerry\");\n String genderString1 = new String(\"Fmale\");\n copyResume.setName(nameString1);\n copyResume.setAge(20);\n copyResume.setGender(genderString1);\n copyResume.getWorkExprience().setCompanyArrayList(companies1);\n System.out.println();\n System.out.println(\"Source Resume\");\n resume.printResum();\n System.out.println();\n System.out.println(\"Copy Resume\");\n copyResume.printResum();\n }",
"public Cliente clone(){\r\n return new Cliente(this.nome, this.email, this.endereco, this.id);\r\n }",
"@Override\r\n\tprotected Object clone() throws CloneNotSupportedException { // semi-copy\r\n\t\tthrow new CloneNotSupportedException();\r\n\t}",
"public Object clone();",
"public Object clone();",
"public Object clone();",
"public Object clone();",
"public abstract Object clone() ;",
"public abstract Object clone();",
"@Override\n public MetaContainer clone() {\n return clone(false);\n }",
"public Object clone(){ \r\n\t\tBaseballCard cloned = new BaseballCard();\r\n\t\tcloned.name = this.getName();\r\n\t\tcloned.manufacturer=this.getManufacturer();\r\n\t\tcloned.year = this.getYear();\r\n\t\tcloned.price = this.getPrice();\r\n\t\tcloned.size[0]= this.getSizeX();\r\n\t\tcloned.size[1]= this.getSizeY();\r\n\t\treturn cloned;\r\n\t}",
"@Override\n public FieldEntity copy()\n {\n return state.copy();\n }",
"public MobileEntity getclone(MobileEntity ws){\n return ws.MakeCopy();\n }",
"protected T copy() {\n\n // Initialize.\n T copy = null;\n\n try {\n\n // Create an instance of this entity class.\n copy = this.entityClass.newInstance();\n\n // Create a copy.\n copy.setCreateTime(this.getCreateTime());\n copy.setId(this.getId());\n copy.setModifyTime(this.getModifyTime());\n }\n catch (IllegalAccessException e) {\n // Ignore.\n }\n catch (InstantiationException e) {\n // Ignore.\n }\n\n return copy;\n }",
"public Object clone() {\n \n\tQuerynotyfyaddressbol obj = new Querynotyfyaddressbol(getObjectsDatastore());\n\n\tobj.iNotifyaddress = iNotifyaddress; \n\n\treturn obj;\n }",
"public Object clone() {\n SIPMessage retval = null;\n try {\n retval = (SIPMessage) this.getClass().newInstance();\n } catch ( IllegalAccessException ex) {\n InternalErrorHandler.handleException(ex);\n } catch (InstantiationException ex) {\n InternalErrorHandler.handleException(ex);\n }\n ListIterator li = headers.listIterator();\n while(li.hasNext()) {\n SIPHeader sipHeader = (SIPHeader)((SIPHeader) li.next()).clone();\n retval.attachHeader(sipHeader);\n }\n if (retval instanceof SIPRequest) {\n SIPRequest thisRequest = (SIPRequest) this;\n RequestLine rl = (RequestLine)\n (thisRequest.getRequestLine()).clone();\n ((SIPRequest) retval).setRequestLine(rl);\n } else {\n SIPResponse thisResponse = (SIPResponse) this;\n StatusLine sl = (StatusLine)\n (thisResponse.getStatusLine()).clone();\n ((SIPResponse) retval).setStatusLine(sl);\n }\n \n if (this.getContent() != null) {\n try {\n\t\tObject newContent ;\n\t\tObject currentContent = this.getContent();\n\t\t// Check the type of the returned content.\n\t\tif (currentContent instanceof String ) {\n\t\t // If it is a string allocate a new string for the body\n\t\t newContent = new String\n\t\t\t\t(currentContent.toString());\n\t\t} else if ( currentContent instanceof byte[] ) {\n\t\t // If it is raw bytes allocate a new array of bytes\n\t\t // and copy over the content.\n\t\t int cl = ((byte[])currentContent).length;\n\t\t byte[] nc = new byte[cl];\n\t\t System.arraycopy((byte[])currentContent,0,nc,0,cl);\n\t\t newContent = nc;\n\t\t} else {\n\t\t // See if the object has a clone method that is public\n\t\t // If so invoke the clone method for the new content.\n\t\t Class cl = currentContent.getClass();\n\t\t try {\n\t\t Method meth = cl.getMethod(\"clone\",null);\n\t\t if (Modifier.isPublic(meth.getModifiers())) {\n\t\t\t newContent = meth.invoke(currentContent,null);\n\t\t } else {\n\t\t\t newContent = currentContent;\n\t\t }\n\t\t } catch (Exception ex) {\n\t\t\tnewContent = currentContent;\n\t\t }\n\t\t}\n retval.setContent\n (newContent,this.getContentTypeHeader());\n } catch (ParseException ex) { /** Ignore **/ }\n }\n \n return retval;\n }",
"public abstract Pessoa clone();",
"public Object clone()\n/* */ {\n/* 835 */ return super.clone();\n/* */ }",
"public Mapping clone(IRSession session){\n \tMapping mapping = new Mapping(session);\n \tmapping.entities = entities;\n \tmapping.multiple = multiple;\n \tmapping.requests = requests;\n \tmapping.entityinfo = entityinfo;\n \tmapping.entitystack = entitystack;\n \tmapping.setattributes = setattributes;\n \tmapping.attribute2listPairs = attribute2listPairs;\n \tmapping.dataObjects = dataObjects;\n \tmapping.initialize();\n \treturn mapping;\n }",
"public VCalendar clone() {\n\t\treturn new VCalendar(this.content, this.collectionId, this.resourceId, this.earliestStart, this.latestEnd, null);\n\t}",
"IGLProperty clone();",
"@Override\r\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\r\n\t}",
"@Override\r\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\r\n\t}",
"@Override\r\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\r\n\t}",
"@Override\n protected Object clone() throws CloneNotSupportedException {\n\n return super.clone();\n }",
"public DatabaseEditorConfig clone(){\n\t\t\n\t\tDatabaseEditorConfig clonedObject = new DatabaseEditorConfig();\n\t\tRGB bg = null;\n\t\tif (backGround != null) {\n\t\t\tbg = new RGB(backGround.red, backGround.green, backGround.blue);\n\t\t}\n\t\tclonedObject.setBackGround(bg);\n\t\tclonedObject.setDatabaseComment(databaseComment);\n\t\t\n\t\treturn clonedObject;\n\t}",
"@Override\n public AbstractRelic makeCopy() {\n return new Compendium();\n }",
"public MovableObject lightClone()\n\t\t{\n\t\t\tfinal MovableObject clone = new MovableObject();\n\t\t\tclone.assCount = this.assCount;\n\t\t\tclone.associatable = this.associatable;\n\t\t\tclone.bound = this.bound;\n\t\t\tclone.coords = new int[this.coords.length];\n\t\t\tfor(int i=0; i < this.coords.length; i++)\n\t\t\t\tclone.coords[i] = this.coords[i];\n\t\t\tclone.highlighted = this.highlighted;\n\t\t\tclone.hotSpotLabel = this.hotSpotLabel;\n\t\t\tclone.keyCode = this.keyCode;\n\t\t\tclone.label = this.label;\n\t\t\tclone.maxAssociations = this.maxAssociations;\n\t\t\tif(shape.equals(\"rect\"))\n\t\t\t{\n\t\t\t\tclone.obj = new Rectangle(coords[0]-3,coords[1]-3,coords[2]+6,coords[3]+6);\n\t\t\t}\n\t\t\tif(shape.equals(\"circle\"))\n\t\t\t{\n\t\t\t\tclone.obj = new Ellipse2D.Double((coords[0]-coords[2])-4,(coords[1]-coords[2])-4,(coords[2]+2)*2,(coords[2]+2)*2);\n\t\t\t}\n\t\t\tif(shape.equals(\"ellipse\"))\n\t\t\t{\n\t\t\t\tclone.obj = new Ellipse2D.Double((coords[0]-coords[2])-4,(coords[1]-coords[2])-4,(coords[2]+2)*2,(coords[3]+2)*2);\n\t\t\t}\n\t\t\tif(shape.equals(\"poly\"))\n\t\t\t{\n\t\t\t\tfinal int xArr[] = new int[coords.length/2];\n\t\t\t\tfinal int yArr[] = new int[coords.length/2];\n\t\t\t\tint xCount = 0;\n\t\t\t\tint yCount = 0;\n\t\t\t\tfor(int i=0; i < coords.length; i++)\n\t\t\t\t{\n\t\t\t\t\tif((i%2) == 0)\n\t\t\t\t\t{\n\t\t\t\t\t\txArr[xCount] = coords[i];\n\t\t\t\t\t\txCount++;\n\t\t\t\t\t}else\n\t\t\t\t\t{\n\t\t\t\t\t\tyArr[yCount] = coords[i];\n\t\t\t\t\t\tyCount++;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t//TODO calculate the centre of mass\n\n\t\t\t\tclone.obj = new Polygon(xArr,yArr,xArr.length);\n\t\t\t}\n\t\t\tclone.pos = new Point(this.pos.x,this.pos.y);\n\t\t\tclone.shape = this.shape;\n\t\t\tclone.startPos = this.startPos;\n\t\t\tclone.value = this.value;\n\n\t\t\treturn clone;\n\t\t}",
"public Hello dup (Hello self)\n {\n if (self == null)\n return null;\n\n Hello copy = new Hello ();\n if (self.getIdentity () != null)\n copy.setAddress (self.getIdentity ());\n copy.ipaddress = self.ipaddress;\n copy.mailbox = self.mailbox;\n copy.groups = new ArrayList <String> (self.groups);\n copy.status = self.status;\n copy.headers = new VersionedMap (self.headers);\n return copy;\n }",
"private Inventory clone_inv(Inventory inv_original, String title) {\n // Copy name, size and other stuff\n Inventory inv = createInventory(this, inv_original.getSize(), title);\n inv.setContents(inv_original.getContents());\n\n return inv;\n }",
"public Function clone();",
"@Override\n protected Message cloneMsgSpecificData()\n {\n WorldBeliefMsg clone = new WorldBeliefMsg(belief);\n return clone;\n }",
"public Object clone() {\n return this.copy();\n }",
"@Override\r\n\tpublic Object clone() throws CloneNotSupportedException {\n\t\t\r\n\t\treturn super.clone();\r\n\t}",
"public Object clone() {\n FileTransfer ft = new FileTransfer();\n ft.mLogicalFile = new String(this.mLogicalFile);\n ft.mFlags = (BitSet) this.mFlags.clone();\n ft.mTransferFlag = this.mTransferFlag;\n ft.mSize = this.mSize;\n ft.mType = this.mType;\n ft.mJob = new String(this.mJob);\n ft.mPriority = this.mPriority;\n ft.mURLForRegistrationOnDestination = this.mURLForRegistrationOnDestination;\n ft.mMetadata = (Metadata) this.mMetadata.clone();\n ft.mVerifySymlinkSource = this.mVerifySymlinkSource;\n // the maps are not cloned underneath\n\n return ft;\n }",
"public Card makeCopy(){\n return new Card(vimage);\n }",
"@Test\n\tpublic void test_TCM__Object_clone() {\n TCM__Object_clone__default();\n\n TCM__Object_clone__attributeType(Attribute.UNDECLARED_TYPE);\n TCM__Object_clone__attributeType(Attribute.CDATA_TYPE);\n TCM__Object_clone__attributeType(Attribute.ID_TYPE);\n TCM__Object_clone__attributeType(Attribute.IDREF_TYPE);\n TCM__Object_clone__attributeType(Attribute.IDREFS_TYPE);\n TCM__Object_clone__attributeType(Attribute.ENTITY_TYPE);\n TCM__Object_clone__attributeType(Attribute.ENTITIES_TYPE);\n TCM__Object_clone__attributeType(Attribute.NMTOKEN_TYPE);\n TCM__Object_clone__attributeType(Attribute.NMTOKENS_TYPE);\n TCM__Object_clone__attributeType(Attribute.NOTATION_TYPE);\n TCM__Object_clone__attributeType(Attribute.ENUMERATED_TYPE);\n\n\n TCM__Object_clone__Namespace_default();\n\n TCM__Object_clone__Namespace_attributeType(Attribute.UNDECLARED_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.CDATA_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.ID_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.IDREF_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.IDREFS_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.ENTITY_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.ENTITIES_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.NMTOKEN_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.NMTOKENS_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.NOTATION_TYPE);\n TCM__Object_clone__Namespace_attributeType(Attribute.ENUMERATED_TYPE);\n\t}",
"public Object clone(){\n \t\n \treturn this;\n \t\n }",
"@Override\r\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\tthrow new CloneNotSupportedException();\r\n\t}",
"public Object clone()\n {\n try {\n Object newObj = super.clone();\n ((LDAPUrl)newObj).url = (com.github.terefang.jldap.ldap.LDAPUrl)this.url.clone();\n return newObj;\n } catch( CloneNotSupportedException ce) {\n throw new RuntimeException(\"Internal error, cannot create clone\");\n }\n }",
"Prototype makeCopy();",
"public Complex makeDeepCopy() {\r\n Complex complex2 = new Complex(this.getReal(), this.getImaginary());\r\n return complex2;\r\n }",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\n\tprotected Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\n\t}",
"@Override\r\n\tpublic ComputerPart clone() {\n\t\treturn null;\r\n\t}",
"public Object clone()\n {\n Object o = null;\n try\n {\n o = super.clone();\n }\n catch (CloneNotSupportedException e)\n {\n e.printStackTrace();\n }\n return o;\n}",
"private Object deepCopy(Object oldObj) throws MareException {\n UtilidadesLog.info(\"MONVariablesVentaBean.deepCopy(Object oldObj):Entrada\");\n ObjectOutputStream oos = null;\n ObjectInputStream ois = null;\n \n try {\n ByteArrayOutputStream bos = new ByteArrayOutputStream();\n oos = new ObjectOutputStream(bos);\n \n oos.writeObject(oldObj);\n oos.flush();\n ByteArrayInputStream bin = new ByteArrayInputStream(bos.toByteArray());\n ois = new ObjectInputStream(bin);\n UtilidadesLog.info(\"MONVariablesVentaBean.deepCopy(Object oldObj):Salida\");\n return ois.readObject();\n } catch(Exception e) {\n UtilidadesLog.error(\"ERROR \", e);\n UtilidadesLog.debug(\"Exception en deepCopy = \" + e);\n throw new MareException(e);\n } finally {\n try {\n oos.close();\n ois.close();\n } catch(Exception ex) {\n UtilidadesLog.error(\"ERROR \", ex);\n UtilidadesLog.debug(\"Exception en deepCopy = \" + ex);\n throw new MareException(ex);\n }\n }\n }",
"protected Factorization copy(){\n Factorization newFactor = new Factorization(this.mdc);\n //shallow copy\n newFactor.setRecipes(recipes);\n newFactor.setIngredients(ingredients);\n newFactor.setUserMap(userMap);\n newFactor.setUserMapReversed(userMap_r);\n newFactor.setRecipeMap(recipeMap);\n newFactor.setRecipeMapReversed(recipeMap_r);\n newFactor.setIngredientMap(ingredientMap);\n newFactor.setIngredientMapReversed(ingredientMap_r);\n \n //deep copy\n List<User> userCopy = new ArrayList<User>();\n for(User curr: this.users){\n userCopy.add(new User(curr.getId()));\n }\n newFactor.setUsers(userCopy);\n newFactor.setDataset(dataset.copy());\n newFactor.updateInitialSpace();\n return newFactor;\n }",
"Model copy();",
"public DessertVO clone() {\r\n return (DessertVO) super.clone();\r\n }",
"private Shop deepCopy() {\n BookShop obj = null;\n try {\n obj = (BookShop) super.clone();\n List<Book> books = new ArrayList<>();\n Iterator<Book> iterator = this.getBooks().iterator();\n while(iterator.hasNext()){\n\n books.add((Book) iterator.next().clone());\n }\n obj.setBooks(books);\n } catch (CloneNotSupportedException exc) {\n exc.printStackTrace();\n }\n return obj;\n }",
"@Override\n public Object clone() throws CloneNotSupportedException{\n return super.clone();\n }",
"public IVenda clone ();",
"public void copy() {\n\n\t}",
"public Object clone() {\n DsSipEventHeaderBase clone = (DsSipEventHeaderBase) super.clone();\n // clone.m_strPackage = m_strPackage;\n if (m_subPackages != null) {\n clone.m_subPackages = (LinkedList) m_subPackages.clone();\n }\n\n return clone;\n }",
"@Override\n public Object clone() {\n try {\n return super.clone();\n } catch (CloneNotSupportedException e) {\n throw new AssertionError(e);\n }\n }",
"public Object clone() throws CloneNotSupportedException { return super.clone(); }",
"public ParticleRenderData copy()\n\t{\n\t\tRenderData copy = super.copy();\n\t\tParticleRenderData pcopy = new ParticleRenderData(new Vector3f(), new Euler(), new Vector3f());\n\t\tpcopy.transform = copy.transform;\n\t\tpcopy.postStage = this.postStage;\n\t\tpcopy.currStage = this.currStage;\n\t\tpcopy.particleColor = this.particleColor;\n\t\treturn pcopy;\n\t}",
"public void copy(DataRequest original){\n\t\t//potential problems with object sharing\n\t\tfilters = \toriginal.get_filters();\n\t\tsort_by = \toriginal.get_sort_by();\n\t\tcount = \toriginal.get_count();\n\t\tstart = \toriginal.get_start();\n\t\tsource = \toriginal.get_source();\n\t\tfieldset =\toriginal.get_fieldset();\n\t\trelation = \toriginal.get_relation();\n\t}",
"public ProcessedDynamicData deepCopy( ) {\r\n\r\n ProcessedDynamicData copy = new ProcessedDynamicData( this.channelId );\r\n\r\n copy.channelId = this.channelId;\r\n copy.dateTimeStamp = new java.util.Date( this.dateTimeStamp.getTime() );\r\n copy.samplingRate = this.samplingRate;\r\n copy.eu = this.eu;\r\n\r\n copy.min = this.min;\r\n copy.max = this.max;\r\n\r\n copy.measurementType = this.measurementType;\r\n copy.measurementUnit = this.measurementUnit;\r\n\r\n // data and labels\r\n List<Double> dataCopy = new Vector<Double>();\r\n for( int i = 0; i < this.data.size(); i++ ) {\r\n dataCopy.add( new Double( this.data.get( i ) ) );\r\n }\r\n copy.setData( dataCopy );\r\n\r\n List<Double> dataLabels = new Vector<Double>();\r\n for( int i = 0; i < this.dataLabels.size(); i++ ) {\r\n dataLabels.add( new Double( this.dataLabels.get( i ) ) );\r\n }\r\n copy.setDataLabels( dataLabels );\r\n\r\n // create a deep copy of overalls\r\n if( overalls != null ) {\r\n copy.overalls = new OverallLevels( this.overalls.getChannelId() );\r\n copy.overalls.setDateTimeStampMillis( this.getDateTimeStampMillis() );\r\n Vector<String> overallKeys = this.overalls.getKeys();\r\n for( int i = 0; i < overallKeys.size(); i++ ) {\r\n copy.overalls.addOverall( new String( overallKeys.elementAt( i ) ),\r\n new Double( this.overalls.getOverall( overallKeys.elementAt( i ) ) ) );\r\n }\r\n }\r\n\r\n copy.xEUnit = this.xEUnit;\r\n copy.yEUnit = this.yEUnit;\r\n\r\n copy.xSymbol = this.xSymbol;\r\n copy.ySymbol = this.ySymbol;\r\n copy.xPhysDomain = this.xPhysDomain;\r\n copy.yPhysDomain = this.yPhysDomain;\r\n \r\n copy.noOfAppendedZeros = this.noOfAppendedZeros;\r\n\r\n return copy;\r\n }",
"@Override \n public Object clone() {\n try {\n Resource2Builder result = (Resource2Builder)super.clone();\n result.self = result;\n return result;\n } catch (CloneNotSupportedException e) {\n throw new InternalError(e.getMessage());\n }\n }",
"public BinaryContent createClone(BinaryContent t)\r\n\t{\n\t\treturn null;\r\n\t}",
"@Override\r\n\tpublic Object clone() throws CloneNotSupportedException {\n\t\treturn super.clone();\r\n\t}",
"@Override\n\tpublic Object clone() throws CloneNotSupportedException {\n\treturn super.clone();\n\t}",
"public d clone() {\n ArrayList arrayList = this.e;\n int size = this.e.size();\n c[] cVarArr = new c[size];\n for (int i = 0; i < size; i++) {\n cVarArr[i] = ((c) arrayList.get(i)).clone();\n }\n return new d(cVarArr);\n }",
"public INodo copy(){\n INodo copia = new FuncionMultiplicacion(getRaiz(), getNHijos());\n copia.setEtiqueta(getEtiqueta());\n for (INodo aux : getDescendientes()){\n copia.incluirDescendiente(aux.copy());\n }\n return copia;\n }",
"@Override\n public Object clone() throws CloneNotSupportedException {\n throw new CloneNotSupportedException();\n }",
"public Payment clone() {\n\t\tPayment clonedPayment = new Payment();\n\t\tclonedPayment.setIsReceivedPayment(this.isReceivedPayment);\n\t\tclonedPayment.setPaymentType(this.paymentType);\n\t\tclonedPayment.setPaymentCategory(this.paymentCategory);\n\t\tclonedPayment.setDescription(this.description);\n\t\tclonedPayment.setCurrencyCode(this.currencyCode);\n\t\tclonedPayment.setTotalAmount(this.totalAmount);\n\t\tclonedPayment.setPaymentMethodType(this.paymentMethodType);\n\t\tclonedPayment.setPayerPaymentMethodId(this.payerPaymentMethodId);\n\t\tclonedPayment.setPayeePaymentReceiveMethodId(this.payeePaymentReceiveMethodId);\n\t\tclonedPayment.setCheckNumber(this.checkNumber);\n\t\tclonedPayment.setPayerAccountId(this.payerAccountId);\n\t\tclonedPayment.setPayerAccountName(this.payerAccountName);\n\t\tclonedPayment.setPayerContactId(this.payerContactId);\n\t\tclonedPayment.setPayerContactName(this.payerContactName);\n\t\tclonedPayment.setPayerBillingAddressId(this.payerBillingAddressId);\n\t\tclonedPayment.setPayeeAccountId(this.payeeAccountId);\n\t\tclonedPayment.setPayeeAccountName(this.payeeAccountName);\n\t\tclonedPayment.setPayeeContactId(this.payeeContactId);\n\t\tclonedPayment.setPayeeContactName(this.payeeContactName);\n\t\tclonedPayment.setPayeeBillingAddressId(this.payeeBillingAddressId);\n\t\tclonedPayment.setDepartmentId(this.departmentId);\n\t\tclonedPayment.setCostCenterNumber(this.costCenterNumber);\n\t\tclonedPayment.setPrimaryPaymentReceiverEmpId(this.primaryPaymentReceiverEmpId);\n\t\tclonedPayment.setSecondaryPaymentReceiverEmpId(this.secondaryPaymentReceiverEmpId);\n\t\tclonedPayment.setPrimaryPaymentPayerEmpId(this.primaryPaymentPayerEmpId);\n\t\tclonedPayment.setSecondaryPaymentPayerEmpId(this.secondaryPaymentPayerEmpId);\n\t\tclonedPayment.setNotes(this.notes);\n\t\treturn clonedPayment;\n\t}",
"@SuppressWarnings(\"unchecked\")\n \tprivate <T extends Entity<T>> T _clone(Entity<T> obj) throws RaplaException {\n \t\tEntity<T> deepClone = ((Mementable<T>) obj).deepClone();\n \t\tT clone = deepClone.cast();\n \n \t\tRaplaType raplaType = clone.getRaplaType();\n \t\tif (raplaType == Appointment.TYPE) {\n \t\t\t// Hack for 1.6 compiler compatibility\n \t\t\tObject temp = clone;\n \t\t\t((AppointmentImpl) temp).removeParent();\n \t\t}\n \t\tif (raplaType == Category.TYPE) {\n \t\t\t// Hack for 1.6 compiler compatibility\n \t\t\tObject temp = clone;\n \t\t\t((CategoryImpl) temp).removeParent();\n \t\t}\n \n \t\tsetNew((RefEntity<T>) clone, this.workingUser);\n \t\treturn clone;\n \t}",
"@Override\n protected Currency clone() {\n final Currency currency = new Currency();\n if (data != null) {\n currency.data = data.clone();\n }\n return currency;\n\n }",
"protected void copyProperties(AbstractContext context) {\n\t\tcontext.description = this.description;\n\t\tcontext.batchSize = this.batchSize;\n\t\tcontext.injectBeans = this.injectBeans;\n\t\tcontext.commitImmediately = this.isCommitImmediately();\n\t\tcontext.script = this.script;\n\t}",
"public Object clone()\r\n {\r\n OSPF_Area new_ = new OSPF_Area(area_id);\r\n new_.default_cost = default_cost;\r\n new_.auth_type = auth_type;\r\n new_.external_routing = external_routing;\r\n new_.no_summary = no_summary;\r\n new_.shortcut_configured = shortcut_configured;\r\n new_.shortcut_capability = shortcut_capability;\r\n new_.transit = transit;\r\n return new_;\r\n }",
"public Entity clone() {\n try {\n return (Entity) super.clone();\n } catch (CloneNotSupportedException e) {\n e.printStackTrace();\n return null;\n }\n }",
"public Client copy() {\n\t\tClient clone = new Client(ID, Email, PostalAddress);\n\t\treturn(clone);\n\t}",
"public Object clone(){\r\n\t\tSampleData obj = new SampleData(letter,getWidth(),getHeight());\r\n\t\tfor ( int y=0;y<getHeight();y++ )\r\n\t\t\tfor ( int x=0;x<getWidth();x++ )\r\n\t\t\t\tobj.setData(x,y,getData(x,y));\r\n\t\treturn obj;\r\n\t}",
"public Object clone ()\n\t{\n\t\ttry \n\t\t{\n\t\t\treturn super.clone();\n\t\t}\n\t\tcatch (CloneNotSupportedException e) \n\t\t{\n throw new InternalError(e.toString());\n\t\t}\n\t}",
"@Override \n public Door clone()\n {\n try\n {\n Door copy = (Door)super.clone();\n \n //a copy of the location class\n copy.room = room.clone(); \n \n return copy;\n }\n catch(CloneNotSupportedException e)\n {\n throw new InternalError();\n }\n }",
"public MossClone() {\n super();\n }",
"public ComplexConfigDTO flatCopy() {\n \t\tfinal ComplexConfigDTO config = new ComplexConfigDTO();\n \t\tconfig.setPropertyType(getPropertyType());\n \t\tconfig.setPropertyName(getPropertyName());\n \t\tconfig.setDefiningScopePath(getDefiningScopePath());\n \t\tconfig.setPolymorph(isPolymorph());\n \t\tconfig.setVersion(getVersion());\n \t\tconfig.setParentVersion(getParentVersion());\n \t\tconfig.setParentScopeName(getParentScopeName());\n \t\tconfig.setClassVersion(getClassVersion());\n \t\tconfig.setNulled(isNulled());\n \t\treturn config;\n \t}",
"@Override\n\tpublic Object clone() {\n\t\treturn null;\n\t}",
"public java.util.Hashtable _copyFromEJB() {\n com.ibm.ivj.ejb.runtime.AccessBeanHashtable h = new com.ibm.ivj.ejb.runtime.AccessBeanHashtable();\n\n h.put(\"createdby\", getCreatedby());\n h.put(\"documentDate\", getDocumentDate());\n h.put(\"documentNumber\", getDocumentNumber());\n h.put(\"leaseDocument\", new Integer(getLeaseDocument()));\n h.put(\"created\", getCreated());\n h.put(\"modifiedby\", getModifiedby());\n h.put(\"operator\", getOperator());\n h.put(\"regionid\", new Integer(getRegionid()));\n h.put(\"modified\", getModified());\n h.put(\"__Key\", getEntityContext().getPrimaryKey());\n\n return h;\n\n}",
"public Object clone() {\n try {\n return super.clone();\n } catch (Exception exception) {\n throw new InternalError(\"Clone failed\");\n }\n }"
] | [
"0.645238",
"0.6440294",
"0.6440294",
"0.64251417",
"0.63749284",
"0.62971777",
"0.6253004",
"0.6193353",
"0.61618036",
"0.6124606",
"0.61226285",
"0.61054873",
"0.6093112",
"0.60703164",
"0.60539407",
"0.60539407",
"0.60539407",
"0.60539407",
"0.6025663",
"0.6017801",
"0.60077006",
"0.60051924",
"0.5989691",
"0.59892476",
"0.5975671",
"0.5968301",
"0.5953227",
"0.59481615",
"0.59461147",
"0.5924424",
"0.5915555",
"0.5908098",
"0.5901415",
"0.5901415",
"0.5901415",
"0.59001356",
"0.5897759",
"0.58950543",
"0.5894489",
"0.58916366",
"0.5880463",
"0.5874613",
"0.58696645",
"0.5861756",
"0.58596796",
"0.5857759",
"0.5851533",
"0.58431786",
"0.58429253",
"0.5840904",
"0.5816112",
"0.5808869",
"0.58031017",
"0.5793364",
"0.5793364",
"0.5793364",
"0.5793364",
"0.5793364",
"0.5793364",
"0.5793364",
"0.5793364",
"0.5793364",
"0.5790211",
"0.5787704",
"0.5782403",
"0.5779036",
"0.5772393",
"0.5764896",
"0.5763476",
"0.57633626",
"0.5755102",
"0.575117",
"0.574646",
"0.57415825",
"0.5736274",
"0.57320917",
"0.57238835",
"0.5723084",
"0.57197136",
"0.57185847",
"0.5714124",
"0.5710374",
"0.57075137",
"0.5701982",
"0.56992114",
"0.5698685",
"0.5697915",
"0.56974536",
"0.568807",
"0.56842375",
"0.56832516",
"0.56731385",
"0.5672244",
"0.5671203",
"0.56639737",
"0.56607085",
"0.5657898",
"0.5647192",
"0.56434083",
"0.5627916"
] | 0.5874424 | 42 |
Header Instances created on page creation Construction | public ImportExcelData (ASPManager mgr, String page_path)
{
super(mgr,page_path);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"PageHeader getPageHeader();",
"PageHeader getPageHeader();",
"public HeaderSettingsPage()\n {\n initialize();\n }",
"Header createHeader();",
"private void validatedHeader() {\n\t\tif(loginView != null){\n\t\t\tLabel greeting = new Label(T.get(\"LABEL_TOP_BAR_GREETING\") + T.get(\"LABEL_GUEST_USER\"));\n\t\t\tLanguageSelector languageSelector = new LanguageSelector(loginView);\n\t\t\tThemeSelector themeSelector = new ThemeSelector();\n\t\t\tbuildHeader(greeting ,null, languageSelector, themeSelector);\n\t\t}\n\t\telse if(registerView != null){\n\t\t\tLabel greeting = new Label(T.get(\"LABEL_TOP_BAR_GREETING\") + T.get(\"LABEL_GUEST_USER\"));\n\t\t\tLanguageSelector languageSelector = new LanguageSelector(registerView);\n\t\t\tThemeSelector themeSelector = new ThemeSelector();\n\t\t\tbuildHeader(greeting ,null, languageSelector, themeSelector);\n\t\t}\n\t\telse if(mainView != null){\n\t\t\tString username = UI.getCurrent().getSession().getAttribute(T.system(\"SESSION_NAME\")).toString();\n\t\t\tLabel greeting = new Label(T.get(\"LABEL_TOP_BAR_GREETING\") + username);\n\t\t\tLanguageSelector languageSelector = new LanguageSelector(mainView);\n\t\t\tThemeSelector themeSelector = new ThemeSelector();\n\t\t\tLogoutButton logout = new LogoutButton();\n\t\t\tbuildHeader(greeting ,logout, languageSelector, themeSelector);\n\t\t}\n\t\tsetStyleName(T.system(\"STYLE_VIEW_TOP_BAR\"));\n\t}",
"void setPageHeader(PageHeader pageHeader);",
"void setPageHeader(PageHeader pageHeader);",
"public void createHeader() {\n\t\tHBox box = new HBox();\n\t\tButton printBtn = new Button(\"Print\");\n\t\tprintBtn.getStyleClass().addAll(\"btn\", \"btn-primary\");\n\t\tButton printAllBtn = new Button(\"Print allemaal\");\n\t\tprintAllBtn.getStyleClass().addAll(\"btn\", \"btn-primary\");\n\t\tButton cancelBtn = new Button(\"Annuleer\");\n\t\tcancelBtn.getStyleClass().addAll(\"btn\", \"btn-danger\");\n\t\tbox.getChildren().addAll(createTitle(), printBtn, printAllBtn, cancelBtn);\n\t\t\n\t\tprintBtn.setOnAction(e -> {\n\t\t\ttry {\n\t\t\t\tprintController.printSelected(debiteuren);\n\t\t\t} catch (Exception e1) {\n\t\t\t\te1.printStackTrace();\n\t\t\t\tSystem.out.println(\"Nothing selected mate\");\n\t\t\t}\n\t\t});\n\t\t\n\t\tprintAllBtn.setOnAction(e -> {\n\t\t\ttry {\n\t\t\t\tprintController.printAll(debiteuren);\n\t\t\t} catch (Exception e1) {\n\t\t\t\te1.printStackTrace();\n\t\t\t\tSystem.out.println(\"Nothing selected mate\");\n\t\t\t}\n\t\t});\n\t\t\n\t\tcancelBtn.setOnAction(e -> {\n\t\t\tprintController.cancel();\n\t\t});\n\t\t\n\t\tsetTop(box);\n\t}",
"public void setupHistoTableHeader() {\r\n\t\tif (this.histoTableTabItem != null && !this.histoTableTabItem.isDisposed()) this.histoTableTabItem.setHeader();\r\n\t}",
"private void initialiseHeader()\n\t{\n\t ListHead head = null;\n\n\t head = super.getListHead();\n\n\t //init only once\n\t if (head != null)\n\t {\n\t \treturn;\n\t }\n\n\t head = new ListHead();\n\n\t // render list head\n\t if (this.getItemRenderer() instanceof WListItemRenderer)\n\t {\n\t \t((WListItemRenderer)this.getItemRenderer()).renderListHead(head);\n\t }\n\t else\n\t {\n\t \tthrow new ApplicationException(\"Rendering of the ListHead is unsupported for \"\n\t \t\t\t+ this.getItemRenderer().getClass().getSimpleName());\n\t }\n\n\t //attach the listhead\n\t head.setParent(this);\n\n\t return;\n\t}",
"private org.gwtbootstrap3.client.ui.PageHeader get_f_PageHeader3() {\n return build_f_PageHeader3();\n }",
"private static UINode _createGlobalHeaders()\n {\n MarlinBean globalHeaders = new MarlinBean(FLOW_LAYOUT_NAME);\n\n //\n // add the client header\n //\n globalHeaders.addIndexedChild(\n ContextPoppingUINode.getUINode(NAVIGATION2_CHILD));\n\n //\n // create and add the default header\n //\n MarlinBean defaultHeader = new MarlinBean(GLOBAL_HEADER_NAME);\n\n defaultHeader.setAttributeValue(\n RENDERED_ATTR,\n new NotBoundValue(\n PdaHtmlLafUtils.createIsRenderedBoundValue(NAVIGATION2_CHILD)));\n\n globalHeaders.addIndexedChild(defaultHeader);\n\n return globalHeaders;\n }",
"H1 createH1();",
"public HeaderFragment() {}",
"abstract public void header();",
"private void manageHeaderView() {\n PickupBoyDashboard.getInstance().manageHeaderVisibitlity(false);\n HeaderViewManager.getInstance().InitializeHeaderView(null, view, manageHeaderClick());\n HeaderViewManager.getInstance().setHeading(true, mActivity.getResources().getString(R.string.bokings));\n HeaderViewManager.getInstance().setLeftSideHeaderView(true, R.drawable.left_arrow);\n HeaderViewManager.getInstance().setRightSideHeaderView(false, R.drawable.left_arrow);\n HeaderViewManager.getInstance().setLogoView(false);\n HeaderViewManager.getInstance().setProgressLoader(false, false);\n\n }",
"private void setupUIElements() {\n setBadgeDrawable(ContextCompat.getDrawable(getActivity(), R.drawable.company_logo));\n //setTitle(getString(R.string.browse_title));\n\n setHeadersState(HEADERS_ENABLED);\n setHeadersTransitionOnBackEnabled(true);\n\n // Set headers and rows background color\n setBrandColor(ContextCompat.getColor(getActivity(), R.color.browse_headers_bar));\n mBackgroundManager.setColor(ContextCompat.getColor(getActivity(),\n R.color.browse_background_color));\n\n // Disables the scaling of rows when Headers bar is in open state.\n enableRowScaling(false);\n\n // Here is where a header presenter can be set to customize the look\n // of the headers list.\n setHeaderPresenterSelector(new PresenterSelector() {\n @Override\n public Presenter getPresenter(Object o) {\n\n return new RowHeaderPresenter();\n }\n });\n }",
"private void createMainMenuHeaderComposite() {\n\n\t\tGridData gridData8 = new GridData();\n\t\tgridData8.grabExcessHorizontalSpace = true;\n\t\tgridData8.horizontalAlignment = GridData.FILL;\n\t\tgridData8.verticalAlignment = GridData.BEGINNING;\n\t\tgridData8.grabExcessVerticalSpace = true;\n\t\tGridData gridData7 = new GridData();\n\t\tgridData7.grabExcessHorizontalSpace = true;\n\t\tgridData7.horizontalAlignment = GridData.FILL;\n\t\tgridData7.verticalAlignment = GridData.END;\n\t\tgridData7.grabExcessVerticalSpace = true;\n\t\tGridData gridData21 = new GridData();\n\t\tgridData21.horizontalAlignment = GridData.FILL;\n\t\tgridData21.grabExcessHorizontalSpace = true;\n\t\tgridData21.grabExcessVerticalSpace = false;\n\t\tgridData21.heightHint = 150;\n\t\tgridData21.verticalAlignment = GridData.BEGINNING;\n\t\tGridLayout gridLayout = new GridLayout();\n\t\tgridLayout.horizontalSpacing = 50;\n\t\tgridLayout.marginWidth = 20;\n\t\tgridLayout.marginHeight = 0;\n\t\tgridLayout.verticalSpacing = 35;\n\t\tmainMenuHeaderComposite = new Composite(this, SWT.NONE);\n\t\tmainMenuHeaderComposite.setBackground(new Color(Display.getCurrent(),\n\t\t\t\t255, 255, 255));\n\t\tmainMenuHeaderComposite.setLayoutData(gridData21);\n\t\tmainMenuHeaderComposite.setLayout(gridLayout);\n\n\t\tlblTitle1 = new CbctlLabel(mainMenuHeaderComposite, SWT.CENTER);\n\t\tlblTitle1\n\t\t\t\t.setText(LabelLoader\n\t\t\t\t\t\t.getLabelValue(LabelKeyConstants.WELCOME_NOTE_ON_TOUCH_SCREEN_HOMEPAGE));\n\t\tlblTitle1\n\t\t\t\t.setFont(SDSControlFactory.getStandardTouchScreenFont());\n\t\tlblTitle1.setLayoutData(gridData7);\n\n\t\tlblTitle2 = new CbctlLabel(mainMenuHeaderComposite, SWT.CENTER);\n\t\tlblTitle2\n\t\t\t\t.setText(LabelLoader\n\t\t\t\t\t\t.getLabelValue(LabelKeyConstants.SELECT_NOTE_ON_TOUCH_SCREEN_HOMEPAGE));\n\t\tlblTitle2\n\t\t\t\t.setFont(SDSControlFactory.getStandardTouchScreenFont());\n\t\tlblTitle2.setLayoutData(gridData8);\n\t}",
"@Override\n\tprotected void createCompHeader() {\n\t\tString headerTxt = \"Add a New Pharmacy\";\n\t\tiDartImage icoImage = iDartImage.PHARMACYUSER;\n\t\tbuildCompHeader(headerTxt, icoImage);\n\t}",
"protected abstract ITitleAndSearchPanelFilter instantiateHeaderAndSearchFilter ( ) ;",
"private void createHeaderPanel()\n\t{\n\t\theaderPanel.setLayout (new GridLayout(2,1));\n\t\theaderPanel.add(textPanel);\n\t\theaderPanel.add(functionPanel);\n\t\t\t\t\t\n\t}",
"@Override\n\tprotected void createCompHeader() {\n\t\tString headerTxt = \"Cohorts Report\";\n\t\tiDartImage icoImage = iDartImage.PAVAS;\n\t\tbuildCompdHeader(headerTxt, icoImage);\n\t}",
"public void setPageHeader(String header)\n {\n // ignore\n }",
"CommunityProfileEventHeader()\n {\n /*\n * Nothing to do.\n */\n }",
"private HeaderUtil() {}",
"private HorizontalLayout getHeader() {\n HorizontalLayout header = new HorizontalLayout();\n header.setWidth(\"100%\");\n header.setHeight(\"100px\");\n // TODO move this into a separate HeaderView class\n header.addComponent(new Label(\"Patient Management System Team Green\"));\n return header;\n }",
"private void init()\n\t{\n\t\tResourceReference css = getCSS();\n\t\tif (css != null)\n\t\t{\n\t\t\tadd(HeaderContributor.forCss(css.getScope(), css.getName()));\n\t\t}\n\t}",
"public HomePage(){\n\t\t\tPageFactory.initElements(driver, this); \n\t\t}",
"public void initComponetNavHeader() {\n\n navigationView.setNavigationItemSelectedListener(this);\n View headerView = navigationView.getHeaderView(0);\n imageViewProfil = headerView.findViewById(R.id.imageViewProfil);\n tvName = headerView.findViewById(R.id.tvName);\n tvEmail = headerView.findViewById(R.id.tvEmail);\n\n tvName.setText(name);\n tvEmail.setText(email);\n\n imageViewProfil.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n startActivity(new Intent(SettingActivity.this, ProfilActivity.class).\n addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_NEW_TASK));\n }\n });\n\n }",
"private void loadNavHeader() {\n\t\t// name, Email\n\t\ttxtName.setText(\"Tester\");\n\t\ttxtEmail.setText(\"Tester@gmail.com\");\n\t}",
"@Override\r\n\tpublic void loadHeader() {\n\r\n\t}",
"private void setUpHeader() {\n header = new JPanel();\n header.setLayout(new BorderLayout());\n header.setBackground(Color.darkGray);\n highscoreTitle = new JLabel();\n highscoreTitle.setText(\"Highscores:\");\n highscoreTitle.setForeground(Color.white);\n highscoreTitle.setHorizontalAlignment(JLabel.CENTER);\n highscoreTitle.setFont(new Font(\"Arial Black\", Font.BOLD, 24));\n header.add(highscoreTitle, BorderLayout.CENTER);\n setUpSortingBtn();\n\n rootPanel.add(header, BorderLayout.NORTH);\n }",
"public HomePage(){\r\n\t\tPageFactory.initElements(driver, this);\r\n\r\n\r\n\t}",
"public HomePage() { \n\t\t\tPageFactory.initElements(driver, this);\n\t\t}",
"protected String getPageHeader()\n {\n if (this.pageHeader == null) {\n String title = (this.privateLabel != null)? this.privateLabel.getPageTitle() : \"\";\n StringBuffer sb = new StringBuffer();\n sb.append(\"<center>\");\n sb.append(\"<span style='font-size:14pt;'><b>\" + title + \"</b></span>\");\n sb.append(\"<hr>\");\n sb.append(\"</center>\");\n this.pageHeader = sb.toString();\n }\n return this.pageHeader;\n }",
"public HomePage(){\r\n\tPageFactory.initElements(driver, this);\t\r\n\t}",
"@Override\n public void addHeader(Div headerDiv)\n {\n getHeaders().add(headerDiv);\n headerDiv.addClass(JQLayoutCSSThemeBlockNames.UI_Layout_Header.toString());\n //getChildren().add(headers.size() - 1, headerDiv);\n }",
"private void loadNavHeader() {\n // name, website\n txtName.setText(\"Ashish Jain\");\n txtWebsite.setText(\"www.ashish.jain@gmail.com\");\n\n navigationView.getMenu().getItem(3).setActionView(R.layout.menu_dot);\n }",
"public HomePageActions() {\n\t\tPageFactory.initElements(driver,HomePageObjects.class);\n\t}",
"private void addHeader(Section catPart) throws BadElementException, IOException{\r\n PdfPTable header = new PdfPTable(1);\r\n PdfPCell c = new PdfPCell(Image.getInstance(\"res/brandogredninglogo.png\"));\r\n c.setBackgroundColor(COLOR_BLUE);\r\n //c.setBorderColor(BaseColor.RED);\r\n header.setHeaderRows(0);\r\n header.addCell(c);\r\n header.setWidthPercentage(100.0f);\r\n \r\n catPart.add(header);\r\n }",
"public HomePage(){\n\t\tPageFactory.initElements(driver, this);\n\t}",
"private void buildHeader(Label greeting, LogoutButton logout, LanguageSelector languageSelector, ThemeSelector themeSelector) {\n\n//\t\tAdd a style name for the greeting label\n\t\tgreeting.setStyleName(T.system(\"STYLE_LABEL_GREETING\"));\n\t\t\n//\t\tAdd components to the layout\n\t\taddComponent(greeting);\n\t\tif(logout != null){\n\t\t\taddComponent(logout);\n\t\t}\n\t\taddComponent(languageSelector);\n\t\taddComponent(themeSelector);\n\t\t\n\t\tsetIds(greeting, logout, languageSelector, themeSelector);\n\t}",
"private void loadNavHeader() {\n // name, website\n txtName.setText(StoreData.LoadString(Constants.NAME,\"Anonymous\",getApplicationContext()));\n txtWebsite.setText(StoreData.LoadString(Constants.EMAIL,\"anonymous\",getApplicationContext()));\n urlProfileImg = StoreData.LoadString(Constants.IMGURL,\"\",getApplicationContext());\n // loading header background image\n Glide.with(this).load(urlNavHeaderBg)\n .crossFade()\n .diskCacheStrategy(DiskCacheStrategy.ALL)\n .into(imgNavHeaderBg);\n\n // Loading profile image\n Glide.with(this).load(urlProfileImg)\n .crossFade()\n .placeholder(R.drawable.anonymous_profile_pic)\n .error(R.drawable.anonymous_profile_pic)\n .thumbnail(0.5f)\n .bitmapTransform(new CircleTransform(this))\n .diskCacheStrategy(DiskCacheStrategy.ALL)\n .into(imgProfile);\n\n // showing dot next to notifications label\n navigationView.getMenu().getItem(3).setActionView(R.layout.menu_dot);\n }",
"private static void setUpNavigationHeader() {\n View navigationHeader = navigationView.getHeaderView(0);\n TextView userName = navigationHeader.findViewById(R.id.lblUserName);\n TextView userEmail = navigationHeader.findViewById(R.id.lblUserEmail);\n CircularImageView circularImageView = navigationHeader.findViewById(R.id.imgUser);\n\n userName.setText(user.getUsername());\n userEmail.setText(user.getEmail());\n\n if (user.getUserProfileImage() == null) {\n circularImageView.setDrawable(resources.getDrawable(R.drawable.user_icon_sample));\n } else {\n Drawable imgUser = new BitmapDrawable(resources, user.getUserProfileImage());\n circularImageView.setDrawable(imgUser);\n }\n }",
"private void initializeAnimalHeader() {\r\n\t\t//initialize text\r\n\t\tTextProperties textProps = new TextProperties();\r\n\t\ttextProps.set(AnimationPropertiesKeys.FONT_PROPERTY, new Font(\"SansSerif\", Font.BOLD, 24));\r\n\t\ttextProps.set(AnimationPropertiesKeys.DEPTH_PROPERTY, 1);\r\n\t\tlang.newText(new Coordinates(20, 30), \"ShiftRows\", \"header\", null, textProps);\r\n\t\t//initialize rectangle\r\n\t\tRectProperties hRectProps = new RectProperties();\r\n\t\thRectProps.set(AnimationPropertiesKeys.DEPTH_PROPERTY, 2);\r\n\t\tlang.newRect(new Offset(-5, -5, \"header\", AnimalScript.DIRECTION_NW), new Offset(5, 5, \"header\", AnimalScript.DIRECTION_SE), \"hRect\", null, hRectProps);\r\n\t}",
"public Header(String t) {\n this.title=t;\n }",
"public Header() {\n\t\tsuper(tag(Header.class)); \n\t}",
"public HomePage(){\n PageFactory.initElements(driver, this);\n }",
"private void init() {\n CardHeader header = new CardHeader(getContext());\n header.setButtonOverflowVisible(true);\n header.setTitle(TestBook.getTitle());\n header.setPopupMenu(R.menu.card_menu_main, new CardHeader.OnClickCardHeaderPopupMenuListener() {\n @Override\n public void onMenuItemClick(BaseCard card, MenuItem item) {\n Toast.makeText(getContext(), item.getTitle(), Toast.LENGTH_SHORT).show();\n }\n });\n\n addCardHeader(header);\n\n BookCardThumb bookthumbnail = new BookCardThumb(getContext());\n bookthumbnail.setDrawableResource(R.drawable.pngbook_cover);\n addCardThumbnail(bookthumbnail);\n\n }",
"protected void initializeHeader() throws PiaRuntimeException, IOException{\n try{\n super.initializeHeader();\n if( firstLineOk && headersObj == null ){\n\t// someone just give us the first line\n\theadersObj = new Headers();\n }\n }catch(PiaRuntimeException e){\n throw e;\n }catch(IOException ioe){\n throw ioe;\n }\n }",
"HeaderSettingsPage(SettingsContainer container)\n {\n super(container);\n initialize();\n }",
"public HomePage() {\n \t\tPageFactory.initElements(driver, this);\n \t}",
"public HomePage() \r\n\t{\r\n\t\tPageFactory.initElements(driver, this);\r\n\t\t\r\n\t}",
"public void setupDataTableHeader() {\r\n\t\tif (this.dataTableTabItem != null && !this.dataTableTabItem.isDisposed()) this.dataTableTabItem.setHeader();\r\n\t}",
"public HomePage() {\n\t\t\tPageFactory.initElements(driver, this);\n\t\t}",
"public HomePage() {\n\t\tPageFactory.initElements(driver, this);\n\t\t\n\t}",
"@Override\n protected void init(VaadinRequest request) {\n\n // html <title> attribute\n getPage().setTitle(\"Patient Management System\");\n\n // instantiate a full screen layout and add it\n VerticalLayout layout = new VerticalLayout();\n layout.setSizeFull();\n setContent(layout);\n\n // header row\n layout.addComponent(getHeader());\n\n // main container\n HorizontalLayout main = getMainContainer();\n layout.addComponent(main);\n layout.setExpandRatio(main, 1.0f); // make main container use all available space\n main.addComponent(getNavigation());\n VerticalLayout canvas = getCanvas();\n main.addComponent(canvas);\n\n // tell the navigation to use\n navigator = new Navigator(this, canvas);\n\n // Assembles all presenters/views and adds them to the navigator\n initializeClasses();\n\n // Navigates to the startpage\n navigator.navigateTo(JournalView.NAME);\n\n }",
"private void createHeaders(WritableSheet sheet)\r\n\t\t\tthrows WriteException {\n\t\taddHeader(sheet, 0, 0, reportProperties.getProperty(\"header1\"));\r\n\t\taddHeader(sheet, 1, 0, reportProperties.getProperty(\"header2\"));\r\n\t\taddHeader(sheet, 2, 0, reportProperties.getProperty(\"header3\"));\r\n\t\taddHeader(sheet, 3, 0, reportProperties.getProperty(\"header4\"));\r\n\t\t\r\n\r\n\t}",
"private void initializeKnownHeaders() {\r\n needParceHeader = true;\r\n \r\n addMainHeader(\"city\", getPossibleHeaders(DataLoadPreferences.NH_CITY));\r\n addMainHeader(\"msc\", getPossibleHeaders(DataLoadPreferences.NH_MSC));\r\n addMainHeader(\"bsc\", getPossibleHeaders(DataLoadPreferences.NH_BSC));\r\n addMainIdentityHeader(\"site\", getPossibleHeaders(DataLoadPreferences.NH_SITE));\r\n addMainIdentityHeader(\"sector\", getPossibleHeaders(DataLoadPreferences.NH_SECTOR));\r\n addMainHeader(INeoConstants.PROPERTY_SECTOR_CI, getPossibleHeaders(DataLoadPreferences.NH_SECTOR_CI));\r\n addMainHeader(INeoConstants.PROPERTY_SECTOR_LAC, getPossibleHeaders(DataLoadPreferences.NH_SECTOR_LAC));\r\n addMainHeader(INeoConstants.PROPERTY_LAT_NAME, getPossibleHeaders(DataLoadPreferences.NH_LATITUDE));\r\n addMainHeader(INeoConstants.PROPERTY_LON_NAME, getPossibleHeaders(DataLoadPreferences.NH_LONGITUDE));\r\n // Stop statistics collection for properties we will not save to the sector\r\n addNonDataHeaders(1, mainHeaders);\r\n \r\n // force String types on some risky headers (sometimes these look like integers)\r\n useMapper(1, \"site\", new StringMapper());\r\n useMapper(1, \"sector\", new StringMapper());\r\n \r\n // Known headers that are sector data properties\r\n addKnownHeader(1, \"beamwidth\", getPossibleHeaders(DataLoadPreferences.NH_BEAMWIDTH), false);\r\n addKnownHeader(1, \"azimuth\", getPossibleHeaders(DataLoadPreferences.NH_AZIMUTH), false);\r\n }",
"private ULCContainer getHeaderPane() {\n if (headerPane == null) {\n headerPane = RichDialogPanelFactory.create(TabHeaderBarPanel.class);\n headerPane.setName(\"headerPane\");\n }\n return headerPane;\n }",
"private void setUpHeader(){\n JButton newList = new JButton(\"Add new list +\");\n newList.addActionListener(e -> this.addList());\n clearPanel(header);\n if(numberOfLists > 0) {\n footer.setVisible(true);\n header.setLayout(new GridLayout(1, 4));\n JButton editListButton= new JButton(\"Edit\");\n editListButton.addActionListener(e->editList());\n JButton deleteListButton = new JButton(\"X\");\n deleteListButton.addActionListener(e -> deleteList());\n comboBox.setSelectedIndex(0);\n currentList = agenda.getConnector().getItem(agenda.getUsername(),\"list\",comboBox.getSelectedItem().toString());\n comboBox.addActionListener(e -> {\n if (comboBox.getSelectedIndex() < numberOfLists) {\n if(comboBox.getItemCount() > 0) {\n currentList = agenda.getConnector().getItem(agenda.getUsername(), \"list\", comboBox.getSelectedItem().toString());\n }\n if(!setup.get(comboBox.getSelectedItem().toString())){\n for(Component c:window.getComponents()){\n if(c.getName().equals(comboBox.getSelectedItem().toString())){\n setUpList((JPanel)c);\n setup.replace(c.getName(),true);\n break;\n }\n }\n }\n ColorPicker picker = ((ColorPicker)this.footer.getComponent(7));\n if(currentList != null) {\n picker.setColor(currentList.getColor());\n }\n this.showPanel(comboBox.getSelectedItem().toString());\n }\n });\n header.add(newList);\n header.add(comboBox);\n header.add(editListButton);\n header.add(deleteListButton);\n }else {\n header.setLayout(new GridLayout(1, 1));\n header.add(newList);\n footer.setVisible(false);\n }\n this.updateComponent(header);\n }",
"@Override\n public void initPane(final MainView parent) {\n this.parent = parent;\n headerAnchorPane.getChildren().setAll(PaneFactory.initHeader());\n\n }",
"public HomePage() {\r\n\t\tPageFactory.initElements(driver, this);\r\n\t}",
"public HomePage() {\n\t\tPageFactory.initElements(driver, this);\n\t}",
"public HomePage() {\n\t\tPageFactory.initElements(driver, this);\n\t}",
"public HomePage() {\n\t\tPageFactory.initElements(driver, this);\n\t}",
"public HomePage() {\n\t\tPageFactory.initElements(driver, this);\n\t}",
"public GridPane simulationHeader() {\r\n\t\t// Create Title\r\n\t\tHBox title = simulationTitle();\r\n\t\t\r\n\t\t// Create Slider Title\r\n\t\tHBox sliderTitle = simulationControlTitle();\r\n\t\t\r\n\t\t// Create Slider\r\n\t\tHBox slider = simulationControl();\r\n\t\t\r\n\t\t// Create Tick Counter\r\n\t\tHBox tickCount = simulationTicks();\r\n\t\t\r\n\t\t// Create Error Placeholder\r\n\t\tHBox errorMessage = errorMessage();\r\n\t\t\r\n\t\t// Setup Grid\r\n\t\tGridPane header = new GridPane();\r\n\t\theader.setMinSize(800, 200); \r\n\t\theader.setVgap(10); \r\n\t\theader.setHgap(10); \r\n\t\theader.setAlignment(Pos.CENTER); \r\n\t\t\r\n\t\t// Add Components To Grid\r\n\t\theader.add(title, 0, 0); \r\n\t\theader.add(sliderTitle, 0, 1);\r\n\t\theader.add(slider, 0, 2); \r\n\t\theader.add(tickCount, 0, 3); \r\n\t\theader.add(errorMessage, 0, 4);\r\n\t\t\r\n\t\treturn header;\r\n\t}",
"private void prepare()\r\n {\r\n MenuButton menubutton = new MenuButton();\r\n addObject(menubutton, 268, 406);\r\n Tittle tittle2 = new Tittle();\r\n addObject(tittle2, 544, 422);\r\n Exit exit2 = new Exit();\r\n addObject(exit2, 863, 427);\r\n tittle2.setLocation(545, 401);\r\n exit2.setLocation(848, 414);\r\n tittle2.setLocation(545, 411);\r\n }",
"void setHeaderInfo(float rFree, float rWork, float resolution, String title, String depositionDate, \n\t\t\tString releaseDate, String[] experimnetalMethods);",
"private void buildHeader(Layout parent) {\n\n }",
"private void initHeader() {\r\n\r\n Typeface friendNameTypeface = UIUtils.getFontTypeface(this,\r\n UIUtils.Fonts.ROBOTO_CONDENSED);\r\n contactNameTextView.setTypeface(friendNameTypeface);\r\n contactNameTextView.setText(friendFeed.getContact().toString());\r\n\r\n Typeface lastMessageSentDateTypeface = UIUtils.getFontTypeface(\r\n this, UIUtils.Fonts.ROBOTO_LIGHT);\r\n lastMessageSentDateTextView.setTypeface(lastMessageSentDateTypeface);\r\n lastMessageSentDateTextView.setText(StringUtils\r\n .normalizeDifferenceDate(friendFeed.getLastMessageTime()));\r\n\r\n typingStatusTextView.setTypeface(lastMessageSentDateTypeface);\r\n\r\n ImageLoaderManager imageLoaderManager = new ImageLoaderManager(getApplicationContext());\r\n imageLoaderManager.loadContactAvatarImage(contactImageView, friendFeed.getContact(), false);\r\n }",
"public LandingPage doCheckHeaderMenu() {\n if (EXPECTED_HEADER.length != HEADER_MENU.size()) {\n System.out.println(\"Not all headers were found on the page\");\n }\n for (int i = 0; i < HEADER_MENU.toArray().length; i++) {\n HEADER_MENU.get(i).click();\n final String headerName = HEADER_MENU.get(i).getText();\n if (headerName.equals(EXPECTED_HEADER[i])) {\n // exit\n } else {\n // exit\n }\n }\n return this;\n }",
"@Test\n\tvoid withHeaderItemsWithWicketHeadNoDuplicates()\n\t{\n\t\ttester.startPage(SubPageWithHeaderItemsAndWicketHead.class);\n\t\tString responseAsString = tester.getLastResponseAsString();\n\n\t\t{\n\t\t\tint idxMetaPanelWicketHead = responseAsString\n\t\t\t\t.indexOf(\"meta name=\\\"panel-wicket-head\\\"\");\n\t\t\tint lastIdxMetaPanelWicketHead = responseAsString\n\t\t\t\t.lastIndexOf(\"meta name=\\\"panel-wicket-head\\\"\");\n\t\t\tassertEquals(idxMetaPanelWicketHead, lastIdxMetaPanelWicketHead);\n\t\t}\n\n\t\t{\n\t\t\tint idxWicketAjaxJs = responseAsString.indexOf(\"wicket-ajax-jquery.js\");\n\t\t\tint lastIdxWicketAjaxJs = responseAsString.lastIndexOf(\"wicket-ajax-jquery.js\");\n\t\t\tassertEquals(idxWicketAjaxJs, lastIdxWicketAjaxJs);\n\t\t}\n\n\t\t{\n\t\t\tint idxTitleElement = responseAsString\n\t\t\t\t.indexOf(\"<title>Apache Wicket Quickstart</title>\");\n\t\t\tint lastIdxTitleElement = responseAsString\n\t\t\t\t.lastIndexOf(\"<title>Apache Wicket Quickstart</title>\");\n\t\t\tassertEquals(idxTitleElement, lastIdxTitleElement);\n\t\t}\n\n\t\t{\n\t\t\tint idxMetaFromBasePage = responseAsString\n\t\t\t\t.indexOf(\"<meta name='fromBasePage' content='1'\");\n\t\t\tint lastIdxMetaFromBasePage = responseAsString\n\t\t\t\t.lastIndexOf(\"<meta name='fromBasePage' content='1'\");\n\t\t\tassertEquals(idxMetaFromBasePage, lastIdxMetaFromBasePage);\n\t\t}\n\n\t\t{\n\t\t\tint idxMetaFromSubPage = responseAsString\n\t\t\t\t.indexOf(\"<meta name=\\\"SubPageWithHeaderItemsAndWicketHead\\\"\");\n\t\t\tint lastIdxMetaFromSubPage = responseAsString\n\t\t\t\t.lastIndexOf(\"<meta name=\\\"SubPageWithHeaderItemsAndWicketHead\\\"\");\n\t\t\tassertEquals(idxMetaFromSubPage, lastIdxMetaFromSubPage);\n\t\t}\n\t}",
"public void setHeader() {\n tvHeader.setText(getResources().getString(R.string.text_skill));\n tvDots.setVisibility(View.INVISIBLE);\n }",
"private void initHorPageTitle() {\n\t\tLabel pageTitle = new Label(\"Reports\");\n\t\tpageTitle.setSizeFull();\n\t\tpageTitle.setWidth(\"800px\");\n\t\tpageTitle.setHeight(\"45px\");\n\t\tpageTitle.addStyleName(\"posPageTitle\");\n\t\thorPageTitle.addComponent(pageTitle);\n\t\troot.addComponent(horPageTitle);\n\t\troot.setComponentAlignment(horPageTitle, Alignment.TOP_CENTER);\n\t}",
"protected void addDynamicHeaders() {\n }",
"private PageId getHeaderPage(RelationInfo relInfo) {\n\t\treturn new PageId(0, relInfo.getFileIdx());\n\t}",
"private void init() {\n headerViewLeftView = findViewById(R.id.headerViewLeftView);\n ivHeaderViewLeft = findViewById(R.id.ivHeaderViewLeft);\n tvHeaderViewLeft = findViewById(R.id.tvHeaderViewLeft);\n\n headerViewRightView = findViewById(R.id.headerViewRightView);\n ivHeaderViewRight = findViewById(R.id.ivHeaderViewRight);\n tvHeaderViewRight = findViewById(R.id.tvHeaderViewRight);\n\n tvHeaderViewTitle = findViewById(R.id.tvHeaderViewTitle);\n headerViewLineAtBottom = findViewById(R.id.headerViewLineAtBottom);\n\n headerViewLeftView.setOnClickListener(new OnClickListener() {\n @Override\n public void onClick(View v) {\n MKeyboardUtil.hideKeyboard(v);\n HActivity.finishActivity(getContext());\n }\n });\n// addView(headerView);\n }",
"protected void createHeadingsAnnotations() {\n\t\tString source = \"https://tabatkins.github.io/bikeshed/headings\";\n\t\taddAnnotation\n\t\t (this,\n\t\t source,\n\t\t new String[] {\n\t\t\t \"Elements\", \"\",\n\t\t\t \"Literals\", \"\",\n\t\t\t \"Vocabularies\", \"\",\n\t\t\t \"Types\", \"\",\n\t\t\t \"Properties\", \"\",\n\t\t\t \"Relations\", \"\",\n\t\t\t \"Predicates\", \"\",\n\t\t\t \"Axioms\", \"\",\n\t\t\t \"Descriptions\", \"\",\n\t\t\t \"Instances\", \"\",\n\t\t\t \"Assertions\", \"\",\n\t\t\t \"Enumerations\", \"\"\n\t\t });\n\t}",
"public interface HanIHeaderViewPagerFragment extends HanIViewPagerFragment {\n int getHeaderLayout();\n\n ViewGroup createTabView();\n}",
"public abstract String header();",
"public interface HeaderRenderer {\n\n\tpublic abstract Component getHeaderRenderer(HeaderPanel headerpanel, Object obj, boolean flag, boolean flag1);\n}",
"public void preDefine()\n\t{\n\t\tASPManager mgr = getASPManager();\n\n\t\theadblk = mgr.newASPBlock(\"HEAD\");\n\n\t\theadblk.disableDocMan();\n\n\t\theadblk.addField(\"OBJID\").\n setHidden();\n\n headblk.addField(\"OBJVERSION\").\n setHidden();\n \n headblk.addField(\"OBJSTATE\").\n setHidden();\n \n headblk.addField(\"OBJEVENTS\").\n setHidden();\n\n\t\theadblk.addField(\"LU_NAME\").\n\t\tsetMandatory().\n\t\tsetMaxLength(8).\n\t\tsetReadOnly().\n\t\tsetHidden();\n\n\t\theadblk.addField(\"KEY_REF\").\n\t\tsetMandatory().\n\t\tsetMaxLength(600).\n\t\tsetReadOnly().\n\t\tsetHidden();\n\n\t\theadblk.addField(\"VIEW_NAME\").\n\t\tsetHidden().\n\t\tsetFunction(\"''\");\n\n\t\theadblk.addField(\"DOC_COUNT\").\n\t\tsetHidden();\n\n\t\theadblk.addField(\"SLUDESC\").\n\t\tsetSize(20).\n\t\tsetMaxLength(2000).\n\t\tsetReadOnly().\n\t\tsetFunction(\"OBJECT_CONNECTION_SYS.GET_LOGICAL_UNIT_DESCRIPTION(:LU_NAME)\").\n\t\tsetLabel(\"DOCMAWDOCREFERENCESLUDESCRIPTION: Object\");\n\n\t\theadblk.addField(\"SINSTANCEDESC\").\n\t\tsetSize(20).\n\t\tsetMaxLength(2000).\n\t\tsetReadOnly().\n\t\tsetFunction(\"OBJECT_CONNECTION_SYS.GET_INSTANCE_DESCRIPTION(:LU_NAME,'',:KEY_REF)\").\n\t\tsetLabel(\"DOCMAWDOCREFERENCESINSTANCEDESC: Object Key\");\n\n\t\theadblk.addField(\"DOC_OBJECT_DESC\").\n\t\tsetReadOnly().\n\t\tsetMaxLength(200).\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDOCOBJECTDESC: Object Desc\");\n\n\t\theadblk.addField(\"STATE\").\n setReadOnly().\n setSize(10).\n setLabel(\"DOCMAWDOCREFERENCESTATE: State\");\n\t\t\n\t\theadblk.addField(\"INFO\").\n\t\tsetHidden().\n\t\tsetFunction(\"''\");\n\n\t\theadblk.addField(\"ATTRHEAD\").\n\t\tsetHidden().\n\t\tsetFunction(\"''\");\n\n\t\theadblk.addField(\"ACTION\").\n\t\tsetHidden().\n\t\tsetFunction(\"''\");\n\n\t\theadblk.setView(\"DOC_REFERENCE\");\n\t\theadblk.defineCommand(\"DOC_REFERENCE_API\",\"New__,Modify__,Remove__,Set_Lock__,Set_Unlock__\");\n\n\t\theadset = headblk.getASPRowSet();\n\n\t\theadbar = mgr.newASPCommandBar(headblk);\n\t\theadbar.disableCommand(headbar.FIND);\n\t\theadbar.disableCommand(headbar.DUPLICATEROW);\n\t\theadbar.disableCommand(headbar.NEWROW);\n\t\theadbar.disableCommand(headbar.EDITROW);\n\t\theadbar.disableCommand(headbar.DELETE);\n\t\theadbar.disableCommand(headbar.BACK);\n\n headbar.addSecureCustomCommand(\"SetLock\", \"DOCMAWDOCREFERENCESETLOCK: Lock\", \"DOC_REFERENCE_API.Set_Lock__\");\n headbar.addSecureCustomCommand(\"SetUnlock\", \"DOCMAWDOCREFERENCESETUNLOCK: Unlock\", \"DOC_REFERENCE_API.Set_Unlock__\");\n\n headbar.addCommandValidConditions(\"SetLock\", \"OBJSTATE\", \"Enable\", \"Unlocked\");\n headbar.addCommandValidConditions(\"SetUnlock\", \"OBJSTATE\", \"Enable\", \"Locked\");\n \n\t\theadtbl = mgr.newASPTable(headblk);\n\t\theadtbl.setTitle(mgr.translate(\"DOCMAWDOCREFERENCECONDOCU: Connected Documents\"));\n\n\n\t\theadlay = headblk.getASPBlockLayout();\n\t\theadlay.setDialogColumns(2);\n\t\theadlay.setDefaultLayoutMode(headlay.SINGLE_LAYOUT);\n\n\n\t\t//\n\t\t// Connected documents\n\t\t//\n\n\t\titemblk = mgr.newASPBlock(\"ITEM\");\n\n\t\titemblk.disableDocMan();\n\n\t\titemblk.addField(\"ITEM_OBJID\").\n\t\tsetHidden().\n\t\tsetDbName(\"OBJID\");\n\n\t\titemblk.addField(\"ITEM_OBJVERSION\").\n\t\tsetHidden().\n\t\tsetDbName(\"OBJVERSION\");\n\n\t\titemblk.addField(\"ITEM_LU_NAME\").\n\t\tsetMandatory().\n\t\tsetHidden().\n\t\tsetDbName(\"LU_NAME\");\n\n\t\titemblk.addField(\"ITEM_KEY_REF\").\n\t\tsetMandatory().\n\t\tsetHidden().\n\t\tsetDbName(\"KEY_REF\");\n\t\t\n\t\titemblk.addField(\"VIEW_FILE\").\n setFunction(\"''\").\n setReadOnly().\n unsetQueryable().\n setLabel(\"DOCMAWDOCREFERENCEVIEWFILE: View File\").\n setHyperlink(\"../docmaw/EdmMacro.page?PROCESS_DB=VIEW&DOC_TYPE=ORIGINAL\", \"DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV\", \"NEWWIN\").\n setAsImageField();\n\t\t\n\t\titemblk.addField(\"CHECK_IN_FILE\").\n setFunction(\"''\").\n setReadOnly().\n unsetQueryable().\n setLabel(\"DOCMAWDOCREFERENCECHECKINFILE: Check In File\").\n setHyperlink(\"../docmaw/EdmMacro.page?PROCESS_DB=CHECKIN&DOC_TYPE=ORIGINAL\", \"DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV\", \"NEWWIN\").\n setAsImageField();\n\n\t\titemblk.addField(\"DOC_CLASS\").\n\t\tsetSize(10).\n\t\tsetMaxLength(12).\n\t\tsetMandatory().\n\t\tsetUpperCase().\n\t\tsetReadOnly().\n\t\tsetDynamicLOV(\"DOC_CLASS\").\n\t\tsetLOVProperty(\"TITLE\",mgr.translate(\"DOCMAWDOCREFERENCEDOCCLASS1: List of Document Class\")).\n\t\tsetCustomValidation(\"DOC_CLASS\",\"SDOCCLASSNAME,KEEP_LAST_DOC_REV,KEEP_LAST_DOC_REV_DB\").//Bug Id 85361\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDOCCLASS: Doc Class\");\n\n\t\titemblk.addField(\"SDOCCLASSNAME\").\n\t\tsetDbName(\"DOC_NAME\").\n\t\tsetSize(10).\n\t\tsetReadOnly().\n\t\tsetLabel(\"DOCMAWDOCREFERENCESDOCCLASSNAME: Doc Class Desc\");\n\t\t\n\t\titemblk.addField(\"SUB_CLASS\").\n setSize(10).\n setReadOnly().\n setHidden().\n setDynamicLOV(\"DOC_SUB_CLASS\",\"DOC_CLASS\").\n setLabel(\"DOCMAWDOCREFERENCESSUBCLASS: Sub Class\");\n\t\t\n\t\titemblk.addField(\"SUB_CLASS_NAME\").\n setSize(10).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCESSUBCLASSNAME: Sub Class Name\");\n\n\t\titemblk.addField(\"DOC_CODE\").\n setSize(20).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCESDOCCODE: Doc Code\");\n\t\t\n\t\titemblk.addField(\"INNER_DOC_CODE\").\n setSize(20).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCESINNERDOCCODE: Inner Doc Code\");\n\t\t\n\t\titemblk.addField(\"SDOCTITLE\").\n\t\tsetDbName(\"DOC_TITLE\").\n\t\tsetSize(40).\n\t\tsetReadOnly().\n\t\tsetFieldHyperlink(\"DocIssue.page\", \"PAGE_URL\", \"DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV\").\n\t\tsetLabel(\"DOCMAWDOCREFERENCESDOCTITLE: Title\");\n\n\t\titemblk.addField(\"DOC_REV\").\n\t\tsetSize(20).\n\t\tsetMandatory().\n\t\tsetUpperCase().\n\t\tsetReadOnly().\n\t\tsetDynamicLOV(\"DOC_ISSUE\",\"DOC_CLASS,DOC_NO,DOC_SHEET\").\n\t\tsetLOVProperty(\"TITLE\",mgr.translate(\"DOCMAWDOCREFERENCEDOCREV1: List of Document Revision\")).\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDOCREV: Doc Rev\");\n\t\t\n\t\titemblk.addField(\"DOC_STATE\").\n setSize(10).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCESDOCSTATE: Doc State\");\n\t\t\n\t\titemblk.addField(\"CONNECTED_PERSON\").\n setSize(10).\n setReadOnly().\n setDynamicLOV(\"PERSON_INFO_LOV\").\n setLabel(\"DOCMAWDOCREFERENCECONNECTEDPERSON: Connected Person\");\n\t\t\n\t\titemblk.addField(\"CONNECTED_PERSON_NAME\").\n setSize(10).\n setReadOnly().\n setFunction(\"Person_Info_API.Get_Name(:CONNECTED_PERSON)\").\n setLabel(\"DOCMAWDOCREFERENCECONNECTEDPERSONNAME: Connected Person Name\");\n\t\tmgr.getASPField(\"CONNECTED_PERSON\").setValidation(\"CONNECTED_PERSON_NAME\");\n\t\t\n\t\titemblk.addField(\"CONNECTED_DATE\", \"Date\").\n setSize(10).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCECONNECTEDDATE: Connected Date\");\n\t\t\n\t\titemblk.addField(\"SEND_UNIT_NAME\").\n setSize(20).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCESSENDUNITNAME: Send Unit Name\");\n\t\t\n\t\titemblk.addField(\"SIGN_PERSON\").\n setSize(10).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCESSIGNPERSON: Sign Person\");\n\t\t\n\t\titemblk.addField(\"COMPLETE_DATE\", \"Date\").\n setSize(10).\n setReadOnly().\n setLabel(\"DOCMAWDOCREFERENCESCOMPLETEDATE: Complete Date\");\n\n\t\titemblk.addField(\"DOCTSATUS\").\n\t\tsetSize(20).\n\t\tsetReadOnly().\n\t\tsetFunction(\"substr(DOC_ISSUE_API.Get_State(DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV),1,200)\").\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDOCTSATUS: Status\");\n\n\t\t//\n\t\t// Hidden Fields\n\t\t//\n\t\t\n\t\titemblk.addField(\"DOC_NO\").\n setSize(20).\n setMaxLength(120).\n setMandatory().\n setUpperCase().\n setHidden().\n setLOV(\"DocNumLov.page\",\"DOC_CLASS\").\n setCustomValidation(\"DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV\",\"SDOCTITLE,DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV,SDOCCLASSNAME,KEEP_LAST_DOC_REV,KEEP_LAST_DOC_REV_DB\").//Bug Id 85361\n setLOVProperty(\"TITLE\",mgr.translate(\"DOCMAWDOCREFERENCEDOCNO1: List of Document No\")).\n setLabel(\"DOCMAWDOCREFERENCEDOCNO: Doc No\");\n\t\t\n\t\titemblk.addField(\"DOC_SHEET\").\n setSize(20).\n //Bug 61028, Start\n setMaxLength(10).\n //Bug 61028, End\n setMandatory().\n setUpperCase().\n setHidden().\n setDynamicLOV(\"DOC_ISSUE_LOV1\",\"DOC_CLASS,DOC_NO,DOC_REV\").\n setLOVProperty(\"TITLE\", mgr.translate(\"DOCMAWDOCREFERENCEDOCSHEET1: List of Doc Sheets\")).\n setLabel(\"DOCMAWDOCREFERENCEDOCSHEET: Doc Sheet\");\n\t\t\n\t\titemblk.addField(\"CATEGORY\").\n setSize(20).\n setMaxLength(5).\n setUpperCase().\n setHidden().\n setDynamicLOV(\"DOC_REFERENCE_CATEGORY\").\n setLOVProperty(\"TITLE\",mgr.translate(\"DOCMAWDOCREFERENCEDOCAT: List of Document Category\")).\n setLabel(\"DOCMAWDOCREFERENCECATEGORY: Association Category\");\n\n itemblk.addField(\"COPY_FLAG\").\n setSize(20).\n setMandatory().\n setSelectBox().\n setHidden().\n enumerateValues(\"Doc_Reference_Copy_Status_API\").\n setLabel(\"DOCMAWDOCREFERENCECOPYFLAG: Copy Status\");\n\n itemblk.addField(\"KEEP_LAST_DOC_REV\").\n setSize(20).\n setMaxLength(100).\n setMandatory().\n setSelectBox().\n setHidden().\n unsetSearchOnDbColumn().\n enumerateValues(\"Always_Last_Doc_Rev_API\").\n setCustomValidation(\"KEEP_LAST_DOC_REV,DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV\",\"DOC_REV,KEEP_LAST_DOC_REV_DB\").//Bug Id 85361\n setLabel(\"DOCMAWDOCREFERENCEKEEPLASTDOCREV: Update Revision\");\n\n //Bug Id 85361. Start\n itemblk.addField(\"KEEP_LAST_DOC_REV_DB\").\n setHidden().\n unsetSearchOnDbColumn().\n setFunction(\"Always_Last_Doc_Rev_API.Encode(:KEEP_LAST_DOC_REV)\");\n //Bug Id 85361. End\n\n itemblk.addField(\"SURVEY_LOCKED_FLAG\").\n setSize(20).\n setMandatory().\n setSelectBox().\n setHidden().\n enumerateValues(\"LOCK_DOCUMENT_SURVEY_API\").\n unsetSearchOnDbColumn().\n //Bug 57719, Start\n setCustomValidation(\"SURVEY_LOCKED_FLAG\",\"SURVEY_LOCKED_FLAG_DB\").\n //Bug 57719, End\n setLabel(\"DOCMAWDOCREFERENCESURVEYLOCKEDFLAG: Doc Connection Status\");\n\t\t\n\t\titemblk.addField(\"SURVEY_LOCKED_FLAG_DB\").\n setHidden().\n unsetSearchOnDbColumn().\n setFunction(\"Lock_Document_Survey_Api.Encode(:SURVEY_LOCKED_FLAG)\");\n\t\t\n\t\titemblk.addField(\"FILE_TYPE\").\n\t\tsetHidden().\n\t\tsetFunction(\"EDM_FILE_API.GET_FILE_TYPE(DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV,'ORIGINAL')\");\n\n\t\t//Bug Id 67336, start\n\t\titemblk.addField(\"STRUCTURE\").\n\t\tsetHidden().\n\t\tsetFunction(\"DOC_TITLE_API.Get_Structure_(DOC_CLASS,DOC_NO)\");\n\t\t//Bug Id 67336, end\n\n\t\t// Bug Id 89939, start\n\t\titemblk.addField(\"CAN_ADD_TO_BC\").\n\t\tsetHidden().\n\t\tsetFunction(\"DOC_ISSUE_API.can_add_to_bc(DOC_CLASS, DOC_NO, DOC_SHEET, DOC_REV)\");\n\t\t\n\t\titemblk.addField(\"BRIEFCASE_NO\"). \n\t\tsetHidden().\n\t\tsetDynamicLOV(\"DOC_BC_LOV1\").\n\t\tsetFunction(\"DOC_BRIEFCASE_ISSUE_API.GET_BRIEFCASE_NO(DOC_CLASS,DOC_NO,DOC_SHEET,DOC_REV)\");\n\t\t\n\t\titemblk.addField(\"EDMSTATUS\").\n\t\tsetHidden().\n\t\tsetFunction(\"EDM_FILE_API.GET_DOC_STATE_NO_USER(DOC_CLASS, DOC_NO, DOC_SHEET, DOC_REV, 'ORIGINAL')\");\n\t\t\n\t\titemblk.addField(\"IS_ELE_DOC\").\n setCheckBox(\"FALSE,TRUE\").\n setFunction(\"EDM_FILE_API.Have_Edm_File(:DOC_CLASS,:DOC_NO,:DOC_SHEET,:DOC_REV)\").\n setReadOnly().\n setHidden().\n setLabel(\"DOCMAWDOCREFERENCEISELEDOC: Is Ele Doc\").\n setSize(5);\n\t\t\n\t\titemblk.addField(\"PAGE_URL\").\n setFunction(\"Doc_Issue_API.Get_Page_Url(:DOC_CLASS,:DOC_NO,:DOC_SHEET,:DOC_REV)\").\n setReadOnly().\n setHidden();\n\t\t\n\t\titemblk.addField(\"TEMP_EDIT_ACCESS\").\n\t\tsetFunction(\"NVL(Doc_Class_API.Get_Temp_Doc(:DOC_CLASS), 'FALSE') || NVL(Doc_Issue_API.Get_Edit_Access_For_Rep_(:DOC_CLASS,:DOC_NO,:DOC_SHEET,:DOC_REV), 'FALSE')\").\n\t\tsetHidden();\n\t\t\n\t\titemblk.addField(\"COMP_DOC\").\n setFunction(\"NVL(Doc_Class_API.Get_Comp_Doc(:DOC_CLASS), 'FALSE')\").\n setHidden();\n\t\t\n\t\titemblk.addField(\"TEMP_DOC\").\n setFunction(\"NVL(Doc_Class_API.Get_Temp_Doc(:DOC_CLASS), 'FALSE')\").\n setHidden();\n\t\t\n\t\titemblk.addField(\"DOC_OBJSTATE\").\n setFunction(\"DOC_ISSUE_API.Get_Objstate__(:DOC_CLASS,:DOC_NO,:DOC_SHEET,:DOC_REV)\").\n setHidden().\n setLabel(\"DOCMAWDOCISSUESTATE: Doc Status\");\n\t\t\n\t\titemblk.addField(\"CHECK_CONNECTED_PERSON\").\n\t\tsetFunction(\"DECODE(connected_person, Person_Info_API.Get_Id_For_User(Fnd_Session_API.Get_Fnd_User), 'TRUE', 'FALSE')\").\n\t\tsetReadOnly().\n\t\tsetLabel(\"DOCMAWDOCREFERENCECHECKCONNECTEDPERSON: Check Connected Person\").\n setHidden();\n\t\t\n\t\titemblk.addField(\"TRANSFERED\").\n\t\tsetCheckBox(\"FALSE,TRUE\").\n\t\tsetReadOnly().\n setHidden();\n\t\t// Bug Id 89939, end\n\n\t\titemblk.setView(\"DOC_REFERENCE_OBJECT\");\n\t\titemblk.defineCommand(\"DOC_REFERENCE_OBJECT_API\",\"New__,Modify__,Remove__\");\n\t\titemblk.setMasterBlock(headblk);\n\t\titemset = itemblk.getASPRowSet();\n\t\titembar = mgr.newASPCommandBar(itemblk);\n\t\titembar.enableCommand(itembar.FIND);\n\t\titembar.disableCommand(itembar.NEWROW);\n\t\titembar.disableCommand(itembar.DUPLICATEROW);\n\t\titembar.disableCommand(itembar.OVERVIEWEDIT);\n\t\titembar.disableCommand(itembar.DELETE);\n\t\titembar.disableCommand(itembar.EDITROW);\n\t\t\n\t\t//Bug 57719, Start, Added check on function checkLocked()\n\t\titembar.defineCommand(itembar.SAVERETURN,\"saveReturnITEM\",\"checkLocked()\");\n\t\t//Bug 57719, End\n\t\titembar.defineCommand(itembar.OKFIND, \"okFindITEMWithErrorMsg\");\n\t\titembar.defineCommand(itembar.COUNTFIND,\"countFindITEM\");\n\t\titembar.defineCommand(itembar.NEWROW, \"newRowITEM\");\n\t\titembar.defineCommand(itembar.SAVENEW, \"saveNewITEM\");\n\t\titembar.defineCommand(itembar.DELETE, \"deleteITEM\");\n\t\t\n\t\t//Bug Id 85487, Start\n\t\titembar.addCustomCommand(\"createNewDoc\", mgr.translate(\"DOCMAWDOCREFERENCECREATEDOC: Create New Document\"));\n\t\titembar.addSecureCustomCommand(\"createConnectDefDoc\", mgr.translate(\"DOCMAWDOCREFERENCECREATECONNDEFDOC: Create And Connect Document...\"), \"DOC_REFERENCE_OBJECT_API.New__\", \"../common/images/toolbar/\" + mgr.getLanguageCode() + \"/createConnectDefDoc.gif\", true);\n\t\t// itembar.setCmdConfirmMsg(\"createConnectDefDoc\", \"DOCMAWDOCREFERENCECREATECONNDEFDOCMSG: Confirm create and connect document?\");\n\t\titembar.addSecureCustomCommand(\"insertExistingDoc\",mgr.translate(\"DOCMAWDOCREFERENCEINEXISTDOC: Insert Existing Document...\"), \"DOC_REFERENCE_OBJECT_API.New__\", \"../common/images/toolbar/\" + mgr.getLanguageCode() + \"/addDocument.gif\", true);\n\t\titembar.addCustomCommandSeparator();\n\t\titembar.forceEnableMultiActionCommand(\"createNewDoc\");\n\t\titembar.forceEnableMultiActionCommand(\"createConnectDefDoc\");\n\t\titembar.forceEnableMultiActionCommand(\"insertExistingDoc\");\n\t\titembar.removeFromRowActions(\"insertExistingDoc\");\n\t\titembar.removeFromRowActions(\"createNewDoc\");\n\t\titembar.removeFromRowActions(\"createConnectDefDoc\");\n\t\t//Bug Id 85487, End\n\n\t\t//Bug Id 89939, start\n\t\t// itembar.addSecureCustomCommand(\"startAddingToBriefcase\",\"DOCMAWDOCREFERENCEADDTOBC: Add to Briefcase...\",\"DOC_BRIEFCASE_ISSUE_API.Add_To_Briefcase\"); \n\t\t// itembar.addCustomCommand(\"goToBriefcase\",\"DOCMAWDOCREFERENCEGOTOBC: Go to Briefcase\"); \n\t\t// itembar.addCommandValidConditions(\"goToBriefcase\",\"BRIEFCASE_NO\",\"Disable\",null);\n\t\t//Bug Id 89939, end\n\n\t\t// File Operations\n\t\t// itembar.addSecureCustomCommand(\"editDocument\",mgr.translate(\"DOCMAWDOCREFERENCEEDITDOC: Edit Document\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\titembar.addSecureCustomCommand(\"deleteDoc\",mgr.translate(\"DOCMAWDOCREFERENCEDELETEDOC: Delete\"),\"DOC_REFERENCE_OBJECT_API.Remove__\"); //Bug Id 70286\n\t\titembar.setCmdConfirmMsg(\"deleteDoc\", \"DOCMAWDOCREFERENCEDELETEDOCCONFIRM: Confirm delete document(s)?\");\n\t\titembar.addCustomCommandSeparator();\n\t\titembar.addSecureCustomCommand(\"viewOriginal\",mgr.translate(\"DOCMAWDOCREFERENCEVIEVOR: View Document\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\titembar.addSecureCustomCommand(\"checkInDocument\",mgr.translate(\"DOCMAWDOCREFERENCECHECKINDOC: Check In Document\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\t// itembar.addSecureCustomCommand(\"undoCheckOut\",mgr.translate(\"DOCMAWDOCREFERENCEUNDOCHECKOUT: Undo Check Out Document\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\t// itembar.addSecureCustomCommand(\"viewOriginalWithExternalViewer\",mgr.translate(\"DOCMAWDOCREFERENCEVIEWOREXTVIEWER: View Document with Ext. App\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\t// itembar.addSecureCustomCommand(\"viewCopy\",mgr.translate(\"DOCMAWDOCREFERENCEVIEWCO: View Copy\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\t// itembar.addSecureCustomCommand(\"printDocument\",mgr.translate(\"DOCMAWDOCREFERENCEPRINTDOC: Print Document\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\t// itembar.addSecureCustomCommand(\"copyFileTo\",mgr.translate(\"DOCMAWDOCISSUECOPYFILETO: Copy File To...\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\t// itembar.addSecureCustomCommand(\"sendToMailRecipient\",mgr.translate(\"DOCMAWDOCREFERENCEWSENDMAIL: Send by E-mail...\"),\"DOCUMENT_ISSUE_ACCESS_API.Get_Document_Access\"); //Bug Id 70286\n\t\titembar.addCustomCommand(\"documentInfo\",mgr.translate(\"DOCMAWDOCREFERENCEDOCINFO: Document Info...\"));\n\n\t\titembar.addCommandValidConditions(\"checkInDocument\", \"TEMP_EDIT_ACCESS\", \"Enable\", \"TRUETRUE\");\n\t\titembar.addCommandValidConditions(\"checkInDocument\", \"CHECK_CONNECTED_PERSON\", \"Disable\", \"FALSE\");\n\t\titembar.addCommandValidConditions(\"checkInDocument\", \"TRANSFERED\", \"Disable\", \"TRUE\");\n\t\titembar.addCommandValidConditions(\"checkInDocument\", \"SURVEY_LOCKED_FLAG_DB\", \"Disable\", \"1\");\n\t\t\n\t\titembar.addCommandValidConditions(\"deleteDoc\", \"TEMP_EDIT_ACCESS\", \"Disable\", \"TRUEFALSE\");\n\t\titembar.addCommandValidConditions(\"deleteDoc\", \"CHECK_CONNECTED_PERSON\", \"Disable\", \"FALSE\");\n\t\titembar.addCommandValidConditions(\"deleteDoc\", \"TRANSFERED\", \"Disable\", \"TRUE\");\n\t\titembar.addCommandValidConditions(\"deleteDoc\", \"SURVEY_LOCKED_FLAG_DB\", \"Disable\", \"1\");\n\t\t\n\t\t// Add operations to comand groups\n\t\t// itembar.addCustomCommandGroup(\"FILE\", mgr.translate(\"DOCMAWDOCREFERENCEFILECMDGROUP: File Operations\"));\n\t\t// itembar.setCustomCommandGroup(\"editDocument\", \"FILE\");\n\t\t// itembar.setCustomCommandGroup(\"checkInDocument\", \"FILE\");\n\t\t// itembar.setCustomCommandGroup(\"undoCheckOut\", \"FILE\");\n\t\t// itembar.setCustomCommandGroup(\"viewOriginal\", \"FILE\");\n\t\t// itembar.setCustomCommandGroup(\"viewOriginalWithExternalViewer\", \"FILE\");\n\t\t// itembar.setCustomCommandGroup(\"viewCopy\", \"FILE\");\n\t\t// itembar.setCustomCommandGroup(\"printDocument\", \"FILE\");\n\t\t// itembar.setCustomCommandGroup(\"copyFileTo\", \"FILE\");\n\n\n\t\titembar.enableMultirowAction();\n\t\t// itembar.removeFromMultirowAction(\"viewOriginalWithExternalViewer\");\n\t\t// itembar.removeFromMultirowAction(\"undoCheckOut\");\n\n\n\t\titemtbl = mgr.newASPTable(itemblk);\n\t\titemtbl.setTitle(mgr.translate(\"DOCMAWDOCREFERENCEDOCUCC: Documents\"));\n\t\titemtbl.enableRowSelect();\n\n\t\titemlay = itemblk.getASPBlockLayout();\n\t\titemlay.setDialogColumns(2);\n\t\titemlay.setDefaultLayoutMode(itemlay.MULTIROW_LAYOUT);\n\n\t\titemlay.setSimple(\"CONNECTED_PERSON_NAME\");\n\t\t\n\t\t//\n\t\t// Create and connect documents\n\t\t//\n\n\t\tdlgblk = mgr.newASPBlock(\"DLG\");\n\n\t\tdlgblk.addField(\"DLG_DOC_CLASS\").\n\t\tsetSize(20).\n\t\tsetDynamicLOV(\"DOC_CLASS\").\n\t\tsetMandatory().\n\t\tsetUpperCase().\n\t\tsetCustomValidation(\"DLG_DOC_CLASS\",\"DLG_DOC_REV,FIRST_SHEET_NO,NUMBER_GENERATOR,NUM_GEN_TRANSLATED,ID1,ID2\").\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDLGDOCCLASS: Doc Class\");\n\n\t\tdlgblk.addField(\"DLG_DOC_NO\").\n\t\tsetSize(20).\n\t\tsetMandatory().\n\t\tsetUpperCase().\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDLGDOCNO: No\");\n\n\t\tdlgblk.addField(\"FIRST_SHEET_NO\").\n\t\tsetSize(20).\n\t\tsetMandatory().\n\t\tsetUpperCase().\n\t\tsetLabel(\"DOCMAWDOCREFERENCEFIRSTSHEETNO: First Sheet No\");\n\n\t\tdlgblk.addField(\"DLG_DOC_REV\").\n\t\tsetSize(20).\n\t\tsetMandatory().\n\t\tsetUpperCase().\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDLGDOCTITLE: Revision\");\n\n\t\tdlgblk.addField(\"DLG_DOC_TITLE\").\n\t\tsetSize(20).\n\t\tsetMandatory().\n\t\tsetLabel(\"DOCMAWDOCREFERENCEDLGDOCREV: Title\");\n\n\t\t// Configurable doc no\n\n\t\tdlgblk.addField(\"NUMBER_GENERATOR\").\n\t\tsetHidden().\n\t\tsetFunction(\"''\");\n\n\t\tdlgblk.addField(\"NUM_GEN_TRANSLATED\").\n\t\tsetReadOnly().\n\t\tsetUpperCase().\n\t\tsetFunction(\"''\").\n\t\tsetLabel(\"DOCREFERENCENUMBERGENERATOR: Number Generator\");\n\n\n\t\tdlgblk.addField(\"ID1\").\n\t\tsetReadOnly().\n\t\tsetFunction(\"''\").\n\t\tsetUpperCase().\n\t\tsetLOV(\"Id1Lov.page\").\n\t\tsetLabel(\"DOCREFERENCENUMBERCOUNTERID1: Number Counter ID1\");\n\n\t\tdlgblk.addField(\"ID2\").\n\t\tsetSize(20).\n\t\tsetUpperCase().\n\t\tsetMaxLength(30).\n\t\tsetFunction(\"''\").\n\t\tsetLOV(\"Id2Lov.page\",\"ID1\").\n\t\tsetLabel(\"DOCREFERENCENUMBERCOUNTERID2: Number Counter ID2\");\n\n\t\tdlgblk.addField(\"BOOKING_LIST\").\n\t\tsetSize(20).\n\t\tsetMaxLength(30).\n\t\tsetUpperCase().\n\t\tsetFunction(\"''\").\n\t\tsetLOV(\"BookListLov.page\", \"ID1,ID2\").//Bug Id 73606\n\t\tsetLabel(\"DOCREFERENCEBOOKINGLIST: Booking List\");\n\n\t\tdlgblk.setTitle(mgr.translate(\"DOCMAWDOCREFERENCECREANDCONNDOC: Create and Connect New Document\"));\n\n\t\tdlgset = dlgblk.getASPRowSet();\n\t\tdlgbar = mgr.newASPCommandBar(dlgblk);\n\t\tdlgbar.enableCommand(dlgbar.OKFIND);\n\t\tdlgbar.defineCommand(dlgbar.OKFIND,\"dlgOk\");\n\t\tdlgbar.enableCommand(dlgbar.CANCELFIND);\n\t\tdlgbar.defineCommand(dlgbar.CANCELFIND,\"dlgCancel\");\n\n\t\tdlglay = dlgblk.getASPBlockLayout();\n\t\tdlglay.setDialogColumns(2);\n\t\tdlglay.setDefaultLayoutMode(dlglay.CUSTOM_LAYOUT);\n\t\tdlglay.setEditable();\n\n\n\t\t//\n\t\t// dummy block\n\t\t//\n\n\t\tdummyblk = mgr.newASPBlock(\"DUMMY\");\n\n\t\tdummyblk.addField(\"DOC_TYPE\");\n\t\tdummyblk.addField(\"RETURN\");\n\t\tdummyblk.addField(\"ATTR\");\n\t\tdummyblk.addField(\"TEMP1\");\n\t\tdummyblk.addField(\"TEMP2\");\n\t\tdummyblk.addField(\"TEMP3\");\n\t\tdummyblk.addField(\"DUMMY\");\n\t\tdummyblk.addField(\"DUMMY_TYPE\");\n\t\tdummyblk.addField(\"DUMMY1\");\n\t\tdummyblk.addField(\"DUMMY2\");\n\t\tdummyblk.addField(\"DUMMY3\");\n\t\tdummyblk.addField(\"DUMMY4\");\n\t\tdummyblk.addField(\"DUMMY5\");\n\t\tdummyblk.addField(\"DUMMY6\");\n\t\tdummyblk.addField(\"LOGUSER\");\n\t\tdummyblk.addField(\"OUT_1\");\n\t}",
"Page createPage();",
"public Headline() {\n }",
"public HomePageAustria() {\n\t\tPageFactory.initElements(driver, this);\n\t}",
"private static void outputHeaderMainPage(SimpleWriter out) {\n out.print(\"<html>\\n\" + \"<head>\\n\" + \"\\t<title>\" + \"Index\" + \"</title>\\n\"\n + \"<font size = '10' >\" + \"Glossary Homepage\" + \"</font>\"\n + \"</head>\\n\" + \"<body>\\n\" + \"<head>\\n\" + \"\\t<h1>\\n\"\n + \"<font size = '6' >\" + \"Index\" + \"</font>\" + \"\\t</h1>\\n\"\n + \"</head>\\n\" + \"</body>\\n\" + \"</html>\");\n }",
"private void initializeGUITableHeaders(){\n TableColumn<HeapData, Integer> addressColumn = new TableColumn<>(\"Address\");\n addressColumn.setCellValueFactory(new PropertyValueFactory<>(\"address\"));\n TableColumn<HeapData, String> valueColumn = new TableColumn<>(\"Value\");\n valueColumn.setCellValueFactory(new PropertyValueFactory<>(\"value\"));\n valueColumn.setMinWidth(100);\n this.heapTableList.getColumns().addAll(addressColumn, valueColumn);\n\n TableColumn<SymbolData, String> variableNameColumn = new TableColumn<>(\"Variable Name\");\n variableNameColumn.setCellValueFactory(new PropertyValueFactory<>(\"variableName\"));\n variableNameColumn.setMinWidth(100);\n TableColumn<SymbolData, String> valColumn = new TableColumn<>(\"Value\");\n valColumn.setCellValueFactory(new PropertyValueFactory<>(\"value\"));\n symbolTableList.getColumns().addAll(variableNameColumn, valColumn);\n\n TableColumn<SemaphoreData,String> indexColumn = new TableColumn<>(\"Index\");\n indexColumn.setCellValueFactory(new PropertyValueFactory<>(\"index\"));\n TableColumn<SemaphoreData,Integer> valueColumnSem = new TableColumn<>(\"Value\");\n valueColumnSem.setCellValueFactory(new PropertyValueFactory<>(\"value\"));\n TableColumn<SemaphoreData,ArrayList<Integer>>valuesColumn = new TableColumn<>(\"Values\");\n valuesColumn.setCellValueFactory(new PropertyValueFactory<>(\"values\"));\n this.semaphoreTable.getColumns().addAll(indexColumn,valueColumnSem,valuesColumn);\n\n }",
"public MedicineHeadlineFragment() {\n\n }",
"private void buildHeader(boolean compact, Bundle savedInstanceState) {\n accountHeader = new AccountHeaderBuilder()\n .withActivity(this)\n .withHeaderBackground(R.drawable.header_green)\n .withCompactStyle(compact)\n .withProfiles(\n getUserProfilesAndItems() //gets user profiles and other drawer items\n )\n .withOnAccountHeaderListener(new AccountHeader.OnAccountHeaderListener() {\n @Override\n public boolean onProfileChanged(View view, IProfile profile, boolean current) {\n //sample usage of the onProfileChanged listener\n //if the clicked item has the identifier ADD_ACCOUNT add a new profile\n Intent intent = null;\n if (profile instanceof IDrawerItem && ((IDrawerItem) profile).getIdentifier() == IDENTIFIER_HEADER_ADD_ACCOUNT) {\n intent = new Intent(MainActivity.this, AddAccountActivity.class);\n //TODO: Save profile\n //TODO: Create profile drawer item from saved profile and show it in UI\n /*\n IProfile profileNew = new ProfileDrawerItem()\n .withNameShown(true)\n .withName(\"New Profile\")\n .withEmail(\"new@gmail.com\")\n .withIcon(getResources().getDrawable(R.drawable.profile_new));\n\n if (accountHeader.getProfiles() != null) {\n //we know that there are 2 setting elements. set the new profile above them\n accountHeader.addProfile(profileNew, accountHeader.getProfiles().size() - 2);\n } else {\n accountHeader.addProfiles(profileNew);\n }\n */\n } else if (profile instanceof IDrawerItem && ((IDrawerItem) profile).getIdentifier() == IDENTIFIER_HEADER_MANAGE_ACCOUNT) {\n intent = new Intent(MainActivity.this, ManageAccountActivity.class);\n //TODO: update the UI\n }else if(profile instanceof IDrawerItem && ((IDrawerItem) profile).getIdentifier() == IDENTIFIER_USER) {\n Toast.makeText(sApplicationContext, \"The User\", Toast.LENGTH_SHORT).show();\n SharedPreferences sp = sApplicationContext.getSharedPreferences(PREF_NAME, MODE_PRIVATE);\n String currentUserUUIDString = sp.getString(PREF_CURRENT_USER_UUID, null);\n if(((UserProfile)profile).getId().toString().equalsIgnoreCase(currentUserUUIDString)){\n Toast.makeText(sApplicationContext, \"SAME User\", Toast.LENGTH_SHORT).show();\n //TODO:\n }else{\n Toast.makeText(sApplicationContext, \"Different User\", Toast.LENGTH_SHORT).show();\n //TODO:\n SharedPreferences.Editor spe = sp.edit();\n spe.putString(PREF_CURRENT_USER_UUID, ((UserProfile)profile).getId().toString());\n spe.commit();\n\n UpdateContentUI();\n }\n }\n\n if(intent != null){\n MainActivity.this.startActivity(intent);\n }\n\n //false if you have not consumed the event And it should close the drawer\n return false;\n }\n })\n .withSavedInstance(savedInstanceState)\n .build();\n }",
"@Test \n\tpublic void homePageHeaderTest() {\n\t\tHomePage homePage = new HomePage(driver);\n\t\thomePage.OpenPage();\n\n\t\t// Validate page header \n\t\tString header = homePage.getHeader();\n\t\tAssert.assertTrue(header.equals(\"\"));\n\n\t\t// Fetch latin quote: \n\t\tString latinQuote = homePage.getQuote(\"latin\");\n\t\tAssert.assertEquals(\"\\\"Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit...\\\"\", latinQuote);\n\n\t\t// Fetch english quote, which is: \n\t\tString englishQuote = homePage.getQuote(\"english\"); \n\t\tAssert.assertEquals(\"\\\"There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain...\\\"\",englishQuote); \n\t}",
"public StateHeader() { // for externalization\r\n }",
"public void addKieHeaders() {\n\t\tHeaderManager headerManager = new HeaderManager();\n\t\theaderManager.add(new Header(\"content-type\", \"application/json\"));\n\t\theaderManager.add(new Header(\"accept\", \"application/json\"));\n\t\theaderManager.add(new Header(\"X-KIE-ContentType\", \"JSON\"));\n\t\theaderManager.setName(\"HTTP Header Manager\");\n\t\theaderManager.setProperty(TestElement.TEST_CLASS, HeaderManager.class.getName());\n\t\theaderManager.setProperty(TestElement.GUI_CLASS, HeaderPanel.class.getName());\n\t\tthis.testPlanHashTree.add(headerManager);\n\t}",
"@Override\n\tpublic void renderHead(IHeaderResponse response)\n\t{\n\t\tfinal JavaScriptResourceReference topJsReference = new JavaScriptResourceReference(\n\t\t\tFilteredHeaderPage.class, \"top.js\");\n\t\tresponse.render(new FilteredHeaderItem(JavaScriptHeaderItem.forReference(topJsReference),\n\t\t\tFilteringHeaderResponse.DEFAULT_HEADER_FILTER_NAME));\n\n\t\t// rendered at the bottom of the body bucket\n\t\tJQueryPluginResourceReference bottomJs = new JQueryPluginResourceReference(\n\t\t\tFilteredHeaderPage.class, \"bottom.js\")\n\t\t{\n\t\t\tprivate static final long serialVersionUID = 1L;\n\n\t\t\t@Override\n\t\t\tpublic List<HeaderItem> getDependencies()\n\t\t\t{\n\t\t\t\tList<HeaderItem> dependencies = super.getDependencies();\n\n\t\t\t\t// WICKET-4566 : depend on a resource which is rendered in a different bucket\n\t\t\t\tdependencies.add(JavaScriptHeaderItem.forReference(topJsReference));\n\t\t\t\treturn dependencies;\n\t\t\t}\n\t\t};\n\t\tresponse.render(JavaScriptHeaderItem.forReference(bottomJs));\n\t}",
"protected void createContents() {\r\n\t\tsetText(Messages.getString(\"HMS.PatientManagementShell.title\"));\r\n\t\tsetSize(900, 700);\r\n\r\n\t}",
"private void loadNavHeader() {\n SharedPreferences prefs = getSharedPreferences(LOG_IN_PREFS_NAME, MODE_PRIVATE);\n userName = prefs.getString(\"userName\", \"No token generated\");\n userEmail = prefs.getString(\"email\", \"No token generated\");\n userAvatarName = prefs.getInt(\"userAvatar\", 0);\n\n // name, email, profileImage\n navHeaderUserName.setText(userName);\n navHeaderUserEmail.setText(userEmail);\n imgNavHeaderProfile.setImageResource(ProfileImageAssets.getProfileImages().get(userAvatarName));\n\n }",
"public ProcessPage() {\n\t\tPageFactory.initElements(driver, this);\n\t\t \n\n\t}",
"public PersonalPage() {\n\t\tPageFactory.initElements(driver, this);\n\t}",
"TH createTH();",
"public void addHeaders() {\n TableLayout tl = findViewById(R.id.table);\n TableRow tr = new TableRow(this);\n tr.setLayoutParams(getLayoutParams());\n if (!haverford) {\n tr.addView(getTextView(0, \"Leave Bryn Mawr\", Color.WHITE, Typeface.BOLD, Color.BLUE));\n tr.addView(getTextView(0, \"Arrive Haverford\", Color.WHITE, Typeface.BOLD, Color.BLUE));\n } else {\n tr.addView(getTextView(0, \"Leave Haverford\", Color.WHITE, Typeface.BOLD, Color.BLUE));\n tr.addView(getTextView(0, \"Arrive Bryn Mawr\", Color.WHITE, Typeface.BOLD, Color.BLUE));\n }\n tl.addView(tr, getTblLayoutParams());\n }"
] | [
"0.68295175",
"0.68295175",
"0.6771846",
"0.66233134",
"0.66206056",
"0.6529737",
"0.6529737",
"0.64588755",
"0.64485836",
"0.6417534",
"0.640949",
"0.63558775",
"0.634535",
"0.6284494",
"0.625108",
"0.6217664",
"0.62160856",
"0.6215937",
"0.61718786",
"0.6137949",
"0.6131472",
"0.6101797",
"0.6100416",
"0.6069239",
"0.6050053",
"0.60496247",
"0.60433704",
"0.6009717",
"0.60071266",
"0.600671",
"0.6002413",
"0.59820586",
"0.5972849",
"0.59588146",
"0.59500635",
"0.5938404",
"0.59354925",
"0.5926229",
"0.5914315",
"0.5898448",
"0.5884065",
"0.58827776",
"0.587998",
"0.5874675",
"0.58518225",
"0.5851108",
"0.5840349",
"0.58327377",
"0.58306813",
"0.5805397",
"0.5783126",
"0.577135",
"0.57626516",
"0.576157",
"0.57611877",
"0.5752794",
"0.57343876",
"0.5734297",
"0.57301533",
"0.5719994",
"0.56991",
"0.5697089",
"0.5683536",
"0.5681412",
"0.5681412",
"0.5681412",
"0.5681412",
"0.5678521",
"0.5668824",
"0.56667835",
"0.566313",
"0.5652631",
"0.56462103",
"0.56432176",
"0.5641115",
"0.5620623",
"0.5609741",
"0.55993116",
"0.5592637",
"0.55913985",
"0.5584996",
"0.5576472",
"0.5573104",
"0.5571702",
"0.5568956",
"0.5566578",
"0.5565533",
"0.5558269",
"0.55517906",
"0.5550111",
"0.55493987",
"0.5546788",
"0.5545395",
"0.55395526",
"0.5525627",
"0.55222493",
"0.5504619",
"0.5503576",
"0.5497899",
"0.5495347",
"0.5464207"
] | 0.0 | -1 |
Adds a file to a tar archive: Tar.addFile(filePath, fileName, tarFile); | public static void addFile(String filePath, String fileName, org.apache.tools.tar.TarOutputStream tarFile) throws IOException {
// change to the path
// File f = new File(filePath + ".");
// Create a buffer for reading the files
byte[] buf = new byte[2048];
// Compress the file
FileInputStream in = new FileInputStream(filePath + fileName);
// Add tar entry to output stream.
File f = new File(filePath + fileName);
TarEntry entry = new TarEntry(f);
entry.setName(f.getName());
//tarFile.writeEntry(entry, false);
//tarFile.writeEntry(entry, false);
tarFile.putNextEntry(entry);
// Transfer bytes from the file to the tar file
int len;
while ((len = in.read(buf)) > -1) {
//log.debug("len: " + len + " buf: " + buf.toString());
tarFile.write(buf, 0, len);
}
// Complete the entry
tarFile.closeEntry();
in.close();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void addFile(final String file);",
"private void addToTarFile(File tableFile,TarArchiveOutputStream tarOutput) throws IOException {\n try (FileInputStream fileInput = new FileInputStream(tableFile)) {\n TarArchiveEntry tarEntry = new TarArchiveEntry(tableFile);\n tarEntry.setName(tableFile.getName());\n tarOutput.putArchiveEntry(tarEntry);\n\n int count;\n byte[] buf = new byte[1024];\n while ((count = fileInput.read(buf, 0, 1024)) != -1) {\n tarOutput.write(buf, 0, count);\n }\n tarOutput.closeArchiveEntry();\n } catch (IOException e) {\n log.error(\"failed to add table backup file {} to tar file\", tableFile.getName());\n throw e;\n }\n }",
"public void addFile(String fileName) throws FileNotFoundException,\r\n\t\t\tIOException {\r\n\t\tFileInputStream fis = new FileInputStream(fileName);\r\n\t\tint size = 0;\r\n\t\tbyte[] buffer = new byte[2048];\r\n\r\n\t\t// Ajouter une entree à l'archive zip\r\n\t\tFile file = new File(fileName);\r\n\t\tZipEntry zipEntry = new ZipEntry(file.getName());\r\n\t\tthis.zos.putNextEntry(zipEntry);\r\n\r\n\t\t// copier et compresser les données\r\n\t\twhile ((size = fis.read(buffer, 0, buffer.length)) > 0) {\r\n\t\t\tthis.zos.write(buffer, 0, size);\r\n\t\t}\r\n\r\n\t\tthis.zos.closeEntry();\r\n\t\tfis.close();\r\n\t}",
"public void add(File file) {\n\t\tfiles.add(file);\n\t}",
"public static void addFile(File f) throws IOException {\n addURL(f.toURI().toURL());\n }",
"public void addFile(String file) {\n files.add(file);\n }",
"TarEntry CreateEntryFromFile(String fileName);",
"public void addFile(FileDiffFile file) {\n \t\tfiles.add(file);\n \t}",
"private void addFileToTarGz(TarArchiveOutputStream tOut, String path, String base) throws IOException {\n File f = new File(path);\n String entryName = base + f.getName();\n TarArchiveEntry tarEntry = new TarArchiveEntry(f, entryName);\n tOut.putArchiveEntry(tarEntry);\n Platform.runLater(() -> fileLabel.setText(\"Processing \" + f.getPath()));\n\n if (f.isFile()) {\n FileInputStream fin = new FileInputStream(f);\n IOUtils.copy(fin, tOut);\n fin.close();\n tOut.closeArchiveEntry();\n } else {\n tOut.closeArchiveEntry();\n File[] children = f.listFiles();\n if (children != null) {\n for (File child : children) {\n addFileToTarGz(tOut, child.getAbsolutePath(), entryName + \"/\");\n }\n }\n }\n }",
"public void addFile(File fileName){\n files.add(fileName);\n }",
"@NonNull\n\t\tBuilder addFile(@NonNull Path path);",
"public void addFile(File inFile) throws IOException {\n write(org.apache.commons.io.FileUtils.readFileToString(inFile, Charset.defaultCharset()));\n }",
"@NonNull\n\t\tBuilder addFile(@NonNull String path);",
"@NonNull\n\t\tBuilder addFile(@NonNull File file);",
"public TarFile(File file) {\n this.file = file;\n }",
"public void addFile(String fieldName, String fileName, byte[] buffer) {\n files.put(fieldName, new AbstractMap.SimpleEntry<String, byte[]>(fileName, buffer));\n }",
"public void addFile (File f) {\n Arquivo arquivo = new Arquivo(this, f);\n arquivo.setVisible(true);\n\n panFiles.add(arquivo);\n }",
"public void addArffFileContentToTargetFile(String targetFilePath, String arffFilePath, boolean addHeader) throws Exception {\n targetFilePath += \".arff\";\n BufferedReader br = new BufferedReader(new FileReader(arffFilePath));\n BufferedWriter bw = new BufferedWriter(new FileWriter(targetFilePath, !addHeader));\n String line;\n boolean foundData = false;\n while ((line = br.readLine()) != null) {\n if (addHeader) {\n bw.write(line + \"\\n\");\n }\n else {\n if (!foundData && line.toLowerCase().contains(\"@data\")) {\n foundData = true;\n line = br.readLine();\n }\n if (foundData) {\n bw.write(line + \"\\n\");\n }\n }\n }\n bw.flush();\n bw.close();\n }",
"public void addFile(Path inputFile) throws IOException {\n\t\taddFile(inputFile, this.index);\n\t}",
"public void addAddFile( String addfile ) {\n if ( addfile == null ) {\n return ;\n }\n addfiles .addElement( addfile );\n }",
"public void addFile(File aResourceFile) {\n\t\tif (!aResourceFile.exists()) {\n\t\t\tignoredReferences.put(aResourceFile.getPath(), \"does not exists\");\n\t\t\treturn;\n\t\t}\n\t\tif (!aResourceFile.isFile()) {\n\t\t\tignoredReferences.put(aResourceFile.getPath(), \"is no file\");\n\t\t\treturn;\n\t\t}\n\t\tif (!aResourceFile.getAbsolutePath().endsWith(\".integrity\")) {\n\t\t\tignoredReferences.put(aResourceFile.getPath(), \"is no integrity file (*.integrity)\");\n\t\t\treturn;\n\t\t}\n\t\tresourceFiles.add(aResourceFile.getAbsolutePath());\n\t}",
"public void addFile(MultipartFile multipartFile, String username) throws IOException {\n InputStream fis = multipartFile.getInputStream();\n // create an output buffer\n ByteArrayOutputStream buffer = new ByteArrayOutputStream();\n // write data to the output buffer\n int nRead;\n byte[] data = new byte[1024];\n while ((nRead = fis.read(data, 0, data.length)) != -1) {\n buffer.write(data, 0, nRead);\n }\n buffer.flush();\n\n Integer userID = usersMapper.getUser(username).getUserID();\n String fileName = multipartFile.getOriginalFilename();\n Integer fileID = 0;\n String contentType = multipartFile.getContentType();\n String fileSize = String.valueOf(multipartFile.getSize());\n byte[] fileData = buffer.toByteArray();\n\n Files file = new Files(fileID, fileName, contentType,\n fileSize, userID, fileData);\n filesMapper.insertFile(file);\n }",
"public AddFileToZip add(final File source) {\n\t\treturn new AddFileToZip(source);\n\t}",
"public static void addFile(String s) throws IOException {\n File f = new File(s);\n addFile(f);\n }",
"public void add(FileSystemEntry entry);",
"public void addFile(String source, String dest) throws IOException {\n\t\tConfiguration conf = this.getConfig();\r\n\r\n\t\tFileSystem fileSystem = FileSystem.get(conf);\r\n\t\t// Get the filename out of the file path\r\n\t\tString filename = source.substring(source.lastIndexOf('/') + 1,\r\n\t\t\t\tsource.length());\r\n\t\t// Create the destination path including the filename.\r\n\t\tif (dest.charAt(dest.length() - 1) != '/') {\r\n\t\t\tdest = dest + \"/\" + filename;\r\n\t\t}\r\n\t\telse {\r\n\t\t\tdest = dest + filename;\r\n\t\t}\r\n\t\t// Check if the file already exists\r\n\t\tPath path = new Path(dest);\r\n\t\tif (fileSystem.exists(path)) {\r\n\t\t\tSystem.out.println(\"File \" + dest + \" already exists\");\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t// Create a new file and write data to it.\r\n\t\tFSDataOutputStream out = fileSystem.create(path);\r\n\t\tInputStream in = new BufferedInputStream(new FileInputStream(\r\n\t\t\t\tnew File(source)));\r\n\t\tbyte[] bytes = new byte[1024];\r\n\t\tint numBytes = 0;\r\n\t\twhile ((numBytes = in.read(bytes)) > 0) {\r\n\t\t\tout.write(bytes, 0, numBytes);\r\n\t\t}\r\n\r\n\t\t// Close all the file descripters\r\n\t\tin.close();\r\n\t\tout.close();\r\n\t\tfileSystem.close();\r\n\t}",
"void addFileToZip(File file, Zipper z, SynchronizationRequest req) \n throws IOException {\n\n if (file.isFile()) {\n z.setBaseDirectory(req.getTargetDirectory());\n z.addFileToZip(file, _out);\n } else if (file.isDirectory()) {\n z.setBaseDirectory(req.getTargetDirectory());\n z.addDirectoryToZip(file, _out);\n } else {\n assert false;\n }\n }",
"private static void addFile(File filedir) throws Exception {\n String fileName = getFileNameInput();\n File newFile = new File(filedir.toString() + \"\\\\\" + fileName);\n boolean fileAlreadyExists = newFile.exists();\n if (fileAlreadyExists) {\n throw new FileAlreadyExistsException(\"File already exists in current directory.\");\n } else {\n try {\n if (newFile.createNewFile()) {\n System.out.println(\"File created successfully\");\n } else {\n System.out.println(\"Something went wrong, please try again.\");\n }\n } catch (IOException e) {\n throw new IOException(e.getMessage());\n }\n }\n }",
"public void addFile(FileWithFaultLocations faultLocationsFile) throws UnsupportedOperationException;",
"private void addFile( ZipOutputStream output, File file, String prefix, boolean compress) throws IOException {\n //Make sure file exists\n long checksum = 0;\n if ( ! file .exists() ) {\n return ;\n }\n ZipEntry entry = new ZipEntry( getEntryName( file, prefix ) );\n entry .setTime( file .lastModified() );\n entry .setSize( file .length() );\n if (! compress){\n entry.setCrc(calcChecksum(file));\n }\n FileInputStream input = new FileInputStream( file );\n addToOutputStream(output, input, entry);\n }",
"public void addToJar(String name, File file, IProgressMonitor monitor) throws JarException\n\t{\n\t\ttry\n\t\t{\n\t\t\tInputStream content = new FileInputStream(file);\n\t\t\ttry\n\t\t\t{\n\t\t\t\taddToJar(name, content, monitor);\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tcontent.close();\n\t\t\t\t}\n\t\t\t\tcatch (IOException e)\n\t\t\t\t{\n\t\t\t\t\tthrow (JarException) new JarException().initCause(e);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (FileNotFoundException e)\n\t\t{\n\t\t\tthrow (JarException) new JarException().initCause(e);\n\t\t}\n\t}",
"@Override\n public void addSingleFile(FileInfo file) {\n }",
"private void uploadFileTos3bucket(String fileName, File file) {\n s3Client.putObject(new PutObjectRequest(bucketName, fileName, file)\n .withCannedAcl(CannedAccessControlList.PublicRead));\n }",
"public static void addToZip(String path, ZipOutputStream myZip, File f) throws FileNotFoundException, IOException{\n\t\tif(f.isDirectory()){\n\t\t\tfor(File subF : f.listFiles()){\n\t\t\t\taddToZip(path + File.separator + f.getName() , myZip, subF);\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tZipEntry e = new ZipEntry(path + File.separator + f.getName());\n\t\t\tmyZip.putNextEntry(e);\n\t\t\ttry (InputStream is = new FileInputStream(f.getAbsolutePath())) {\n\t\t\t\tIOUtils.copyLarge(is, myZip);\n\t\t\t}\n\t\t}\n\t}",
"public void add(FileName fn) {\n if (size() == 0) {\n fileNameList.add(this);\n }\n fileNameList.add(fn);\n }",
"public void addFileWithContent(String filePath, String content) {\n\t\t// get the path\n\t\tString path = filePath.substring(0, filePath.lastIndexOf(\"/\"));\n\t\t// get the file names\n\t\tString name = filePath.substring(filePath.lastIndexOf(\"/\") + 1);\n\t\t// add content to the file's location with the name provided\n\t\tgetDirectory(path, directory).getFiles().add(new FileObjects(name, content));\n\t}",
"public String addFile(String fn)\n\t{\n\t\tString intfn= sysdir + File.separator + fn;\n\t\tsynchronized( syncFiles ) // get Intermediate-Data access for the key \n\t\t{\n\t\t\twhile( syncFileswait )\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tsyncFiles.wait();\n\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t\tsyncFileswait= true;\n\t\t\t\n\t\t\tfiles.put(fn, intfn);\n\t\t\t\n\t\t\tsyncFileswait= false;\n\t\t\tsyncFiles.notifyAll();\n\t\t}\n\t\t\n\t\treturn intfn;\n\t}",
"private void addToZipStream(Path file, ZipOutputStream zipStream, String dirName)\r\n throws Exception {\r\n String inputFileName = file.toFile().getPath();\r\n try (FileInputStream inputStream = new FileInputStream(inputFileName)) {\r\n\r\n // create a new ZipEntry, which is basically another file\r\n // within the archive. We omit the path from the filename\r\n Path directory = Paths.get(dirName);\r\n ZipEntry entry = new ZipEntry(directory.relativize(file).toString());\r\n\r\n zipStream.putNextEntry(entry);\r\n\r\n // Now we copy the existing file into the zip archive. To do\r\n // this we write into the zip stream, the call to putNextEntry\r\n // above prepared the stream, we now write the bytes for this\r\n // entry. For another source such as an in memory array, you'd\r\n // just change where you read the information from.\r\n byte[] readBuffer = new byte[2048];\r\n int amountRead;\r\n int written = 0;\r\n\r\n while ((amountRead = inputStream.read(readBuffer)) > 0) {\r\n zipStream.write(readBuffer, 0, amountRead);\r\n written += amountRead;\r\n }\r\n } catch (IOException e) {\r\n throw new Exception(\"Unable to process \" + inputFileName, e);\r\n }\r\n }",
"public void addEarconFile(String earcon, String filename) {\n mSelf.addEarcon(earcon, filename);\n }",
"public void add(File file) {\n\t\tthis.content.add(file);\n\t\tif(file.getParent() != null) {\n\t\t\tfile.getParent().content.remove(file);\n\t\t}\n\t\tfile.setParent(this);\n\t}",
"public void addFile( File file, EnumMap<FileState, Set<File>> result )\n {\n Set<File> fileSet = result.get( this );\n if ( fileSet == null )\n {\n fileSet = new HashSet<File>();\n result.put( this, fileSet );\n }\n fileSet.add( file );\n }",
"public void addFileSet(final FileSet _fileSet) {\n this.fileSets.add(_fileSet);\n }",
"@Override\n\t\tpublic void add(File explodedAar) {\n if (!isShared(explodedAar))\n files.addAll(getJars(explodedAar));\n\t\t}",
"public void put(String key, File file) throws FileNotFoundException {\n put(key, file, null);\n }",
"TarEntry CreateEntry(String name);",
"@Test\n public void addShoppingCartConnectionFileTest() throws ApiException {\n Integer shoppingCartConnectionId = null;\n String fileName = null;\n api.addShoppingCartConnectionFile(shoppingCartConnectionId, fileName);\n\n // TODO: test validations\n }",
"public void addToJar(String name, IFile file, IProgressMonitor monitor) throws JarException\n\t{\n\t\ttry\n\t\t{\n\t\t\tInputStream content = file.getContents();\n\t\t\ttry\n\t\t\t{\n\t\t\t\taddToJar(name, content, monitor);\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tcontent.close();\n\t\t\t\t}\n\t\t\t\tcatch (IOException e)\n\t\t\t\t{\n\t\t\t\t\tthrow (JarException) new JarException().initCause(e);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (CoreException e)\n\t\t{\n\t\t\tthrow (JarException) new JarException().initCause(e);\n\t\t}\n\t}",
"public ImageFile addImageFile(ImageFile f) {\n imageFiles.add(f);\n return f;\n }",
"private void addToZip(File directoryToZip, File file, ZipOutputStream zos) throws IOException {\r\n final int BUFFER_SIZE = 1024;\r\n FileInputStream fis = new FileInputStream(file);\r\n // we want the zipEntry's path to be a relative path that is relative\r\n // to the directory being zipped, so chop off the rest of the path\r\n String zipFilePath = file.getCanonicalPath().substring(\r\n (directoryToZip.getCanonicalPath().length() - directoryToZip.getName().length()),\r\n file.getCanonicalPath().length());\r\n ZipEntry zipEntry = new ZipEntry(zipFilePath);\r\n zos.putNextEntry(zipEntry);\r\n byte[] bytes = new byte[BUFFER_SIZE];\r\n int length;\r\n while ((length = fis.read(bytes)) >= 0) {\r\n zos.write(bytes, 0, length);\r\n }\r\n zos.closeEntry();\r\n fis.close();\r\n }",
"public final TarEntry CreateEntryFromFile(String fileName)\n\t\t{\n\t\t\treturn TarEntry.CreateEntryFromFile(fileName);\n\t\t}",
"public void addSpectrumFilePath(String spectrumFilePath) {\n \n String fileName = IoUtil.getFileName(spectrumFilePath);\n spectrumFiles.put(IoUtil.removeExtension(fileName), spectrumFilePath);\n }",
"private File createTar(Map<String, ByteString> fileContents) throws IOException {\n File tarFile = folder.newFile(\"coverage.tar\");\n try (TarArchiveOutputStream out =\n new TarArchiveOutputStream(new FileOutputStream(tarFile))) {\n for (Map.Entry<String, ByteString> file : fileContents.entrySet()) {\n TarArchiveEntry entry = new TarArchiveEntry(file.getKey());\n entry.setSize(file.getValue().size());\n\n out.putArchiveEntry(entry);\n file.getValue().writeTo(out);\n out.closeArchiveEntry();\n }\n }\n return tarFile;\n }",
"protected void add(String path) throws IOException {\n String[] command = {SVN, ADD, path};\n run(command, null, null, null);\n }",
"private void addLibrary(ZipOutputStream out, File file) throws IOException\n\t{\n\t\tString groupId = DEFAULT_LIBRARY_GROUPID; // FIXME\n\t\tString version = DEFAULT_LIBRARY_VERSION; // FIXME\n\t\tString artifactId = file.getName().substring(0, file.getName().lastIndexOf(\".\")); // remove file extension\n\t\t\n\t\tString fileName = \"/localrepo/\" + groupId + \"/\" + artifactId + \"/\" + version + \"/\" + artifactId + \"-\" + version + \".jar\";\n\n\t\tcreateZipEntry(out, fileName, Files.readAllBytes(Paths.get(file.getAbsolutePath())));\n\t}",
"public void addToFiles(Path pathDir) {\n this.files.add(pathDir);\n }",
"public void appendFileTo(String sourceFilename, String targetFilename)\r\n\tthrows FileNotFoundException, IOException {\r\n\t\tString theFileContent = readStringFromFile(sourceFilename);\r\n\t\tappendStringToFile(theFileContent, targetFilename);\r\n\t}",
"public void add(File file) throws IOException {\n File realFile = new File(Main.CWD, file.getName());\n File rmStage = new File(REMOVAL, file.getName());\n if (rmStage.exists()) {\n rmStage.delete();\n }\n if (realFile.exists()) {\n if (curAndCWDIdentical(file, realFile)) {\n File stagingFile = new File(INDEX, file.getName());\n if (stagingFile.exists()) {\n stagingFile.delete();\n }\n } else {\n File resultingFile = new File(INDEX, file.getName());\n if (!resultingFile.exists()) {\n resultingFile.createNewFile();\n }\n String content = Utils.readContentsAsString(realFile);\n Utils.writeContents(resultingFile, content);\n }\n }\n }",
"public void addFile(String name, IDirectory parent) {\r\n // Create a new file\r\n File newFile = new File(name, (Directory) parent);\r\n ((Directory) parent).addItem(newFile);\r\n }",
"public boolean addFile(File sourceFile) {\n String filename = sourceFile.getName();\n File destFile = null;\n String codeExtension = null;\n boolean replacement = false;\n\n // if the file appears to be code related, drop it\n // into the code folder, instead of the data folder\n if (filename.toLowerCase().endsWith(\".o\") ||\n filename.toLowerCase().endsWith(\".a\") ||\n filename.toLowerCase().endsWith(\".so\")) {\n\n //if (!codeFolder.exists()) codeFolder.mkdirs();\n prepareCodeFolder();\n destFile = new File(codeFolder, filename);\n\n } else {\n for (String extension : getExtensions()) {\n String lower = filename.toLowerCase();\n if (lower.endsWith(\".\" + extension)) {\n destFile = new File(this.folder, filename);\n codeExtension = extension;\n }\n }\n if (codeExtension == null) {\n prepareDataFolder();\n destFile = new File(dataFolder, filename);\n }\n }\n\n // check whether this file already exists\n if (destFile.exists()) {\n Object[] options = { _(\"OK\"), _(\"Cancel\") };\n String prompt = I18n.format(_(\"Replace the existing version of {0}?\"), filename);\n int result = JOptionPane.showOptionDialog(editor,\n prompt,\n _(\"Replace\"),\n JOptionPane.YES_NO_OPTION,\n JOptionPane.QUESTION_MESSAGE,\n null,\n options,\n options[0]);\n if (result == JOptionPane.YES_OPTION) {\n replacement = true;\n } else {\n return false;\n }\n }\n\n // If it's a replacement, delete the old file first,\n // otherwise case changes will not be preserved.\n // http://dev.processing.org/bugs/show_bug.cgi?id=969\n if (replacement) {\n boolean muchSuccess = destFile.delete();\n if (!muchSuccess) {\n Base.showWarning(_(\"Error adding file\"),\n I18n.format(_(\"Could not delete the existing ''{0}'' file.\"), filename),\n\t\t\t null);\n return false;\n }\n }\n\n // make sure they aren't the same file\n if ((codeExtension == null) && sourceFile.equals(destFile)) {\n Base.showWarning(_(\"You can't fool me\"),\n _(\"This file has already been copied to the\\n\" +\n \"location from which where you're trying to add it.\\n\" +\n \"I ain't not doin nuthin'.\"), null);\n return false;\n }\n\n // in case the user is \"adding\" the code in an attempt\n // to update the sketch's tabs\n if (!sourceFile.equals(destFile)) {\n try {\n Base.copyFile(sourceFile, destFile);\n\n } catch (IOException e) {\n Base.showWarning(_(\"Error adding file\"),\n I18n.format(_(\"Could not add ''{0}'' to the sketch.\"), filename),\n\t\t\t e);\n return false;\n }\n }\n\n if (codeExtension != null) {\n SketchCode newCode = new SketchCode(destFile, codeExtension);\n\n if (replacement) {\n replaceCode(newCode);\n\n } else {\n insertCode(newCode);\n sortCode();\n }\n setCurrentCode(filename);\n editor.header.repaint();\n if (editor.untitled) { // TODO probably not necessary? problematic?\n // Mark the new code as modified so that the sketch is saved\n current.setModified(true);\n }\n\n } else {\n if (editor.untitled) { // TODO probably not necessary? problematic?\n // If a file has been added, mark the main code as modified so\n // that the sketch is properly saved.\n code[0].setModified(true);\n }\n }\n return true;\n }",
"TarEntry CreateEntry(byte[] headerBuffer);",
"void putFile(String filename, byte[] file) throws FileAlreadyExistsException;",
"private static void recurseFiles(File file)\r\n throws IOException, FileNotFoundException\r\n {\r\n if (file.isDirectory()) {\r\n //Create an array with all of the files and subdirectories \r\n //of the current directory.\r\nString[] fileNames = file.list();\r\n if (fileNames != null) {\r\n //Recursively add each array entry to make sure that we get\r\n //subdirectories as well as normal files in the directory.\r\n for (int i=0; i<fileNames.length; i++){ \r\n \trecurseFiles(new File(file, fileNames[i]));\r\n }\r\n }\r\n }\r\n //Otherwise, a file so add it as an entry to the Zip file. \r\nelse {\r\n byte[] buf = new byte[1024];\r\n int len;\r\n //Create a new Zip entry with the file's name. \r\n\r\n\r\nZipEntry zipEntry = new ZipEntry(file.toString());\r\n //Create a buffered input stream out of the file \r\n\r\n\r\n//we're trying to add into the Zip archive. \r\n\r\n\r\nFileInputStream fin = new FileInputStream(file);\r\n BufferedInputStream in = new BufferedInputStream(fin);\r\n zos.putNextEntry(zipEntry);\r\n //Read bytes from the file and write into the Zip archive. \r\n\r\n\r\nwhile ((len = in.read(buf)) >= 0) {\r\n zos.write(buf, 0, len);\r\n }\r\n //Close the input stream. \r\n\r\n\r\n in.close();\r\n //Close this entry in the Zip stream. \r\n\r\n\r\n zos.closeEntry();\r\n }\r\n }",
"private void addFileToNode(DefaultMutableTreeNode node, FileInfo givenFile){\r\n\t\t//check that there are files in this folder\r\n\t\t// replace existing file if one is present with the same name\r\n\t\tif(!node.isLeaf()){\r\n\t\t\tFileInfo index = (FileInfo) node.getFirstChild();\r\n\t\t\t//look through all the files\r\n\t\t\twhile(index != null){\r\n\t\t\t\t//if it's already there\r\n\t\t\t\tif((index.toString()).equals(givenFile.toString())){\r\n\t\t\t\t\t//FileInfo temp = (FileInfo)index.getPreviousSibling();\r\n\t\t\t\t\t//remove the old file\t\r\n\t\t\t\t\tindex.removeFromParent();\r\n\t\t\t\t\t//index = temp;\r\n\t\t\t\t}\r\n\t\t\t\t//move on to the next index\r\n\t\t\t\tindex = (FileInfo) index.getNextSibling();\r\n\t\t\t}\r\n\t\t}\r\n\t\t//add it to the node\r\n\t\tnode.add(givenFile);\r\n\t\tif(parentTree != null)\r\n\t\t\tparentTree.nodeStructureChanged(node);\r\n\t}",
"public void addCachedFile(String fileURI, File localFile) {\t\n\t\tcache.setProperty(fileURI, localFile.getName());\n\t}",
"public IJBoss7DeploymentResult addDeployment(IAS7ManagementDetails details, String deploymentName,\n\t\t\tFile file, IProgressMonitor monitor) throws JBoss7ManangerException {\n\t\tcheckDelegate();\n\t\treturn getDelegateService().addDeployment(details, deploymentName, file, monitor);\n\t}",
"protected void attachFile(final File source, final String name) {\n try {\n final ZipEntry ze = new ZipEntry(name);\n _zip.putNextEntry(ze);\n final byte[] buffer = new byte[4096];\n try (FileInputStream in = new FileInputStream(source)) {\n int bytes;\n while ((bytes = in.read(buffer)) > 0) {\n _zip.write(buffer, 0, bytes);\n }\n }\n _zip.closeEntry();\n } catch (final IOException e) {\n throw new OpenGammaRuntimeException(\"Couldn't write \" + name + \" to ZIP file\", e);\n }\n }",
"public void add(String name) {\n File f = new File(name);\n if (!f.exists()) {\n Utils.message(\"File does not exist.\");\n throw new GitletException();\n }\n Blob blob = new Blob(f);\n untracked.remove(name);\n HashMap<String, Blob> files = head.getContents();\n if (files.containsKey(name)\n && files.get(name).getContent().equals(blob.getContent())) {\n return;\n } else if (!(files.containsKey(name) && files.get(name).equals(blob))) {\n stagingarea.put(blob.getName(), blob);\n File stagefile = Utils.join(staging, blob.getHash());\n Utils.writeObject(stagefile, blob);\n }\n\n }",
"public void handleAddFile() {\n // make sure the user didn't hide the sketch folder\n ensureExistence();\n\n // if read-only, give an error\n if (isReadOnly()) {\n // if the files are read-only, need to first do a \"save as\".\n Base.showMessage(_(\"Sketch is Read-Only\"),\n _(\"Some files are marked \\\"read-only\\\", so you'll\\n\" +\n \"need to re-save the sketch in another location,\\n\" +\n \"and try again.\"));\n return;\n }\n\n // get a dialog, select a file to add to the sketch\n String prompt =\n _(\"Select an image or other data file to copy to your sketch\");\n //FileDialog fd = new FileDialog(new Frame(), prompt, FileDialog.LOAD);\n FileDialog fd = new FileDialog(editor, prompt, FileDialog.LOAD);\n fd.setVisible(true);\n\n String directory = fd.getDirectory();\n String filename = fd.getFile();\n if (filename == null) return;\n\n // copy the file into the folder. if people would rather\n // it move instead of copy, they can do it by hand\n File sourceFile = new File(directory, filename);\n\n // now do the work of adding the file\n boolean result = addFile(sourceFile);\n\n if (result) {\n editor.statusNotice(_(\"One file added to the sketch.\"));\n }\n }",
"public ArchiveEntry addEntry (File toInsert, String targetName, URI format)\n\t\tthrows IOException\n\t{\n\t\treturn addEntry (toInsert, targetName, format, false);\n\t}",
"public void addFromFile(File file) throws CoreException {\n\tInputStream stream = null;\n\n\ttry {\n\t stream = new FileInputStream(file);\n\t addFromStream(stream);\n\n\t} catch (IOException e) {\n\t throwReadException(e);\n\n\t} finally {\n\t try {\n\t\tif (stream != null)\n\t\t stream.close();\n\t } catch (IOException e) {\n\t }\n\t}\n }",
"public FileObject add(String path){\r\n FileObject fileObject = order.add(path);\r\n if (fileObject != null) {\r\n calendar = new DateControll();\r\n }\r\n return fileObject;\r\n }",
"private void generateTarFile() throws IOException {\n File folder = new File(backupTempDirPath);\n File[] srcFiles = folder.listFiles();\n if (srcFiles == null) {\n log.debug(\"no backup file found under directory {}\", backupTempDirPath);\n return;\n }\n\n try (FileOutputStream fileOutput = new FileOutputStream(filePath);\n TarArchiveOutputStream tarOutput = new TarArchiveOutputStream(fileOutput)) {\n // truncate file names if too long\n tarOutput.setLongFileMode(TarArchiveOutputStream.LONGFILE_TRUNCATE);\n for (File srcFile : srcFiles) {\n addToTarFile(srcFile, tarOutput);\n }\n } catch (IOException e) {\n log.error(\"failed to generate a backup tar file {}\", filePath);\n throw e;\n }\n\n log.info(\"backup tar file is generated at {}\", filePath);\n }",
"public void addCompilationUnit(String targetPath, CompilationUnit compilationUnit) {\n checkTargetPath(targetPath);\n this.compilationUnits.put(targetPath, compilationUnit);\n }",
"public void addFileToMonitor(String pFile) {\n LOGGER.info(\"Adding file '{}' to monitoring\", pFile);\n mFileList.add(pFile);\n }",
"public void touchOne(File inFile)\n {\n mFiles.add(inFile);\n }",
"public void addDir(File dirObj, ZipOutputStream out) throws IOException {\n\t\t File[] files = dirObj.listFiles();\n\t\t byte[] tmpBuf = new byte[1024];\n\t\t for (int i = 0; i < files.length; i++) {\n\t\t if (files[i].isDirectory()) {\n\t\t addDir(files[i], out);\n\t\t continue;\n\t\t }\n\t \t FileInputStream in = new FileInputStream(files[i].getAbsolutePath());\n\t\t System.out.println(\" Adding: \" + files[i].getAbsolutePath());\n\t\t out.putNextEntry(new ZipEntry(files[i].getAbsolutePath()));\n\t\t int len;\n\t\t while ((len = in.read(tmpBuf)) > 0) { out.write(tmpBuf, 0, len); }\n\t\t out.closeEntry();\n\t\t in.close();\n\t\t }\n\t\t }",
"@Test\n public void addItemSubCategoryFileTest() throws ApiException {\n Integer itemSubCategoryId = null;\n String fileName = null;\n api.addItemSubCategoryFile(itemSubCategoryId, fileName);\n\n // TODO: test validations\n }",
"public void addPath(Path aPath) {\n _thePaths.add(aPath);\n }",
"public void addfile() {\n\t\tString name;\r\n\t\tSystem.out.println(\"Enter the file name you want to add\");\r\n Scanner sc = new Scanner(System.in);\r\n name = sc.nextLine();\r\n try {\r\n \t\tFile file = new File(\"g:\\\\LockedMe\\\\\"+name);\r\n \t\tif(file.createNewFile()) {\r\n \t\t\tSystem.out.println(\"New file created\");\r\n \t\t}\r\n \t\telse {\r\n \t\t\tif(file.exists())\r\n \t\t\t{\r\n \t\t\t\tSystem.out.println(\"file already exists\");\r\n \t\t\t}\r\n \t\t\telse\r\n \t\t\t{\r\n \t\t\t\tSystem.out.println(\"file does not exist\");\r\n \t\t\t}\r\n \t\t}\r\n }\r\n catch(Exception e)\r\n {\r\n \t e.printStackTrace();\r\n }\r\n\t}",
"public void add(String path, String url) throws IOException, IllegalArgumentException {\n if (url == null || url.length() == 0 || path == null || path.length() == 0) {\n throw new IllegalArgumentException(\"Zero length path or url\");\n }\n connect();\n writeHeader();\n _dos.writeBytes(\"ADD\\0\");\n _dos.writeInt(url.length() + path.length() + 10);\n _dos.writeInt(path.length() + 1);\n _dos.writeInt(url.length() + 1);\n _dos.writeBytes(path + \"\\0\");\n _dos.writeBytes(url + \"\\0\");\n _baos.writeTo(_out);\n readReply();\n switch(_reply_com) {\n case PushCacheProtocol.OK:\n break;\n case PushCacheProtocol.ERR:\n serverError();\n break;\n default:\n unexpectedReply();\n }\n }",
"@Override\r\n\tpublic void addFile(String type, String given_name, \r\n\t\t\tString localDesc, String globalDesc){\r\n\t\t\r\n\t\t//check the conditions\r\n\t\tif(globalDesc == null)\r\n\t\t\tglobalDesc = \"\";\r\n\t\tif(localDesc == null)\r\n\t\t\tlocalDesc = \"\";\r\n\t\tif(given_name == null)\r\n\t\t\treturn;\r\n\t\t\r\n\t\t//add the file to the appropriate node\r\n\t\tif(type.equals(INFILE_KEY)){\r\n\t\t\taddFileToNode(input, new FileInfo(given_name, localDesc, globalDesc));\r\n\t\t}\r\n\t\tif(type.equals(OUTFILE_KEY)){\r\n\t\t\taddFileToNode(output, new FileInfo(given_name, localDesc, globalDesc));\r\n\t\t}\r\n\t}",
"void addFile(RebaseJavaFile jf)\n{\n if (file_nodes.contains(jf)) return;\n\n file_nodes.add(jf);\n jf.setRoot(this);\n}",
"public void addActor(String path) throws IOException {\r\n\t\tactors.add(ImageIO.read(new File(path)));\r\n\t}",
"public File addResource(String id, File f) {\n\t\trks.add(id);\n\t\trvs.add(f);\n\t\treturn f;\n\t}",
"public AddFileToZip path(final String path) {\n\t\t\tthis.path = path;\n\t\t\treturn this;\n\t\t}",
"public long addFile(String file_name, String file_type,\n\t\t\tString file_create_date, String hash_sum) {\n\n\t\tif (m_db == null)\n\t\t\treturn -1;\n\n\t\t//\n\t\t// construct content values\n\t\t//\n\t\tContentValues values = new ContentValues();\n\n\t\t//\n\t\t// add filename\n\t\t//\n\t\tvalues.put(FILE_FIELD_PATH, file_name);\n\n\t\t//\n\t\t// add file type\n\t\t//\n\t\tvalues.put(FILE_FIELD_TYPE, file_type);\n\n\t\t//\n\t\t// add create date\n\t\t//\n\t\tvalues.put(FILE_FIELD_CREATE_DATE, file_create_date);\n\n\t\t//\n\t\t// add file hash sum\n\t\t//\n\t\tvalues.put(FILE_FIELD_HASH_SUM, hash_sum);\n\n\t\t//\n\t\t// now execute the insert\n\t\t//\n\t\tlong rows_affected = m_db.insert(FILE_TABLE_NAME, null, values);\n\n\t\t//\n\t\t// informal debug message\n\t\t//\n\t\tLogger.i(\"DBManager::addFile> rows_affected: \" + rows_affected);\n\n\t\t//\n\t\t// return row id\n\t\t//\n\t\treturn rows_affected;\n\t}",
"public static void add(Gitlet currCommit, String[] args) {\n if (args.length != 2) {\n System.out.println(\"Specify which file to add.\");\n return;\n }\n FileManip fileToAdd = new FileManip(args[1]);\n FileManip prevFile = new FileManip(\".gitlet/\"\n + currCommit.tree.getCommit() + \"/\" + args[1]);\n if (!fileToAdd.exists()) {\n System.out.println(\"File does not exist.\");\n } else if (!prevFile.exists()) {\n currCommit.status.addToStatus(args[1]);\n addSerializeFile(currCommit);\n } else if (fileToAdd.isSame(prevFile.getPath())) {\n System.out.println(\"File has not been modified since the last commit.\");\n } else {\n currCommit.status.addToStatus(args[1]);\n addSerializeFile(currCommit);\n }\n }",
"public static void appendFile(final String contents, final String name) {\n writeFile(contents, name, true);\n }",
"public String putFile(String path, File file){\n final FileDataBodyPart filePart = new FileDataBodyPart( \"file\", file );\n final FormDataMultiPart multipart = (FormDataMultiPart) new FormDataMultiPart()\n .bodyPart( filePart );\n return target.path( path ).request()\n .post( Entity.entity( multipart, multipart.getMediaType() ), String.class );\n }",
"public void putNextEntry( TarEntry entry ) throws IOException {\n\t\tStringBuffer name = entry.getHeader().name;\n\t\tif ( ( entry.isUnixTarFormat() && name.length() > TarHeader.NAMELEN ) || ( ! entry.isUnixTarFormat()\n && name.length() > (TarHeader.NAMELEN + TarHeader.PREFIXLEN) )) { // Formata gore isim boyutu kontrolu yapar\n\t\t\tthrow new InvalidHeaderException( \"file name '\" + name + \"' is too long ( \" + name.length() + \" > \"\n + ( entry.isUnixTarFormat() ? TarHeader.NAMELEN : (TarHeader.NAMELEN + TarHeader.PREFIXLEN) ) + \" bytes )\" );\n\t\t\t}\n\t\tentry.writeEntryHeader( this.recordBuf ); // Basligi yazar\n\t\tthis.buffer.writeRecord( this.recordBuf ); // Kayiti yazar\n\t\tthis.currBytes = 0;\n\t\tif ( entry.isDirectory() )\n\t\t\tthis.currSize = 0;\n\t\telse\n\t\t\tthis.currSize = entry.getSize();\n\t\t}",
"public void addMergeFile( String mergefile ) {\n if ( mergefile == null ) {\n return ;\n }\n mergefiles .addElement( mergefile );\n }",
"public static JarResourceCenter addJarFile(JarFile jarFile, FlexoResourceCenterService rcService) throws IOException {\n\t\tJarResourceCenterImpl.logger.info(\"Try to create a resource center from a jar file : \" + jarFile.getName());\n\t\t// JarResourceCenter rc = new JarResourceCenter(jarFile, rcService);\n\t\tJarResourceCenter rc = instanciateNewJarResourceCenter(jarFile, rcService);\n\t\trc.setDefaultBaseURI(jarFile.getName());\n\t\trcService.addToResourceCenters(rc);\n\t\trcService.storeDirectoryResourceCenterLocations();\n\t\treturn rc;\n\t}",
"public static void archiveProcessedFiles(Session session, String sourceDir,\r\n\t\t\tString targetDir, String fileName) throws Exception {\r\n\t\tChannelSftp sftpChannel = null;\r\n\t\ttry {\r\n\t\t\tChannel channel = session.openChannel(\"sftp\");\r\n\t\t\tchannel.connect();\r\n\t\t\tsftpChannel = (ChannelSftp) channel;\r\n\t\t\tsftpChannel.cd(targetDir);\r\n\r\n\t\t\tDateFormat df = new SimpleDateFormat(\"MM.dd.yyyy_HHmmss\");\r\n\t\t\tDate today = Calendar.getInstance().getTime();\r\n\t\t\tString archiveDate = df.format(today);\r\n\r\n\t\t\tsftpChannel.mkdir(targetDir + archiveDate);\r\n\t\t\tsftpChannel.rename(sourceDir + fileName, targetDir + archiveDate\r\n\t\t\t\t\t+ \"/\" + fileName);\r\n\t\t\tlogger.info(\"File -> \\\"\" + fileName\r\n\t\t\t\t\t+ \"\\\": archived successfully to \" + targetDir + archiveDate);\r\n\t\t} catch (Exception e) {\r\n\t\t\te.getMessage();\r\n\t\t\tthrow e;\r\n\t\t} finally {\r\n\t\t\tif (sftpChannel != null) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tsftpChannel.exit();\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\te.getMessage();\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\t\t\tif (session != null) {\r\n\t\t\t\tsession.disconnect();\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"public synchronized void addPeer(String filename, PeerConnection peer) {\n\t\tSet<PeerConnection> filePeers = this.peerRecord.get(filename);\n\t\tfilePeers.add(peer);\n\t}",
"void addTariffType(String tariffType) throws ServiceException;",
"public ArchiveEntry addEntry (File baseDir, File file, URI format,\n\t\tboolean mainEntry) throws IOException\n\t{\n\t\tif (!file.exists ())\n\t\t\tthrow new IOException (\"file does not exist.\");\n\t\t\n\t\tif (!file.getAbsolutePath ().contains (baseDir.getAbsolutePath ()))\n\t\t\tthrow new IOException (\"file must be in basedir.\");\n\t\t\n\t\tString localName = file.getAbsolutePath ()\n\t\t\t.replace (baseDir.getAbsolutePath (), \"\");\n\t\t\n\t\treturn addEntry (file, localName, format, mainEntry);\n\t}",
"public ArchiveEntry addEntry (File baseDir, File file, URI format)\n\t\tthrows IOException\n\t{\n\t\tif (!file.exists ())\n\t\t\tthrow new IOException (\"file does not exist.\");\n\t\t\n\t\tif (!file.getAbsolutePath ().contains (baseDir.getAbsolutePath ()))\n\t\t\tthrow new IOException (\"file must be in basedir.\");\n\t\t\n\t\tString localName = file.getAbsolutePath ()\n\t\t\t.replace (baseDir.getAbsolutePath (), \"\");\n\t\t\n\t\treturn addEntry (file, localName, format, false);\n\t}",
"public void addSpeechFile(String text, String filename) {\n mSelf.addSpeech(text, filename);\n }",
"public synchronized static void addIndex(File fileName, TreeMap<String, TreeSet<Integer>> index) {\n if (!fileIndices.containsKey(fileName)) {\n fileIndices.put(fileName, index);\n } else {\n System.out.println(\"There exist files with the same name in the input location.\");\n }\n }",
"public void addExternalFilesCP(File f) { externalFilesCP.add(f); }"
] | [
"0.7110923",
"0.67008054",
"0.6610463",
"0.65217745",
"0.64660424",
"0.63589877",
"0.6212223",
"0.61856264",
"0.6134955",
"0.61235154",
"0.6081185",
"0.6040432",
"0.60146713",
"0.6013233",
"0.58362216",
"0.5693441",
"0.567684",
"0.56514484",
"0.5624661",
"0.5618075",
"0.5576966",
"0.55040765",
"0.5457062",
"0.5401467",
"0.538413",
"0.535665",
"0.5328731",
"0.53136176",
"0.5310741",
"0.53052187",
"0.53045887",
"0.527445",
"0.5261393",
"0.5253441",
"0.5219847",
"0.51954114",
"0.51866937",
"0.51712716",
"0.5154577",
"0.51410425",
"0.51093507",
"0.51074064",
"0.51056594",
"0.50805414",
"0.5067366",
"0.5056042",
"0.50404334",
"0.5029565",
"0.50133604",
"0.50121737",
"0.5001238",
"0.49989673",
"0.49980164",
"0.4989821",
"0.4985507",
"0.49428895",
"0.49202955",
"0.49160358",
"0.49047363",
"0.48944715",
"0.4894353",
"0.48861986",
"0.48705453",
"0.48654515",
"0.4862116",
"0.48541018",
"0.48210824",
"0.48063248",
"0.48032677",
"0.47896123",
"0.47783965",
"0.47619012",
"0.47572434",
"0.47497535",
"0.4749519",
"0.47201616",
"0.47109193",
"0.47064346",
"0.4706332",
"0.46986893",
"0.46973884",
"0.46964",
"0.46910453",
"0.4674703",
"0.46740496",
"0.46496874",
"0.4644289",
"0.46411476",
"0.4629737",
"0.46236235",
"0.46216652",
"0.46160862",
"0.45911807",
"0.4585458",
"0.4582381",
"0.4578846",
"0.45718673",
"0.4534206",
"0.45340556",
"0.45309463"
] | 0.87853616 | 0 |
2_Les constructeurs 2_Les constructeurs Constructeur vide | public ClientSoapMBean() {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private ControleurAcceuil(){ }",
"public AntrianPasien() {\r\n\r\n }",
"public Pasien() {\r\n }",
"public Caso_de_uso () {\n }",
"public Regla2(){ /*ESTE ES EL CONSTRUCTOR POR DEFECTO */\r\n\r\n /* TODAS LAS CLASES TIENE EL CONSTRUCTOR POR DEFECTO, A VECES SE CREAN AUTOMATICAMENTE, PERO\r\n PODEMOS CREARLOS NOSOTROS TAMBIEN SI NO SE HUBIERAN CREADO AUTOMATICAMENTE\r\n */\r\n \r\n }",
"private UsineJoueur() {}",
"public Cgg_jur_anticipo(){}",
"@Test\n\tpublic void testConstructeur() {\n\t\tassertEquals(\"La liste de matiere devrait etre initialise\", 0, f.getMatiere().size());\n\t\tassertEquals(\"L'id de formation devrait etre 1\", 1, f.getId());\n\t}",
"Compleja createCompleja();",
"public Final_parametre() {\r\n\t}",
"public CarteCaisseCommunaute() {\n super();\n }",
"public prueba()\r\n {\r\n }",
"Vaisseau_ordonneeLaPlusBasse createVaisseau_ordonneeLaPlusBasse();",
"Compuesta createCompuesta();",
"public CrearQuedadaVista() {\n }",
"public static void main(String[] args) {\n\r\n ContaEspecial contaEspecial1 = new ContaEspecial(\"\", \"\");\r\n // ContaEspecial contaEspecial2 = new ContaEspecial();\r\n }",
"public Chauffeur() {\r\n\t}",
"public Funcionario() {\r\n\t\t\r\n\t}",
"public Vehiculo() {\r\n }",
"public Kullanici() {}",
"Vaisseau_estAbscisseCouverte createVaisseau_estAbscisseCouverte();",
"public Clade() {}",
"protected Asignatura()\r\n\t{}",
"public cola_de_un_banco(){// se crea nuestro metodo costructor \r\n primero=null;//se crea el tipo de indicaciones con valor a null\r\n ultimo=null;\r\n}",
"public MorteSubita() {\n }",
"public NhanVien()\n {\n }",
"Petunia() {\r\n\t\t}",
"public Jeu(){\n Saisie.Initialiser();\n this.premierJoueur = CreationDePersonnage(\"joueur1\");\n this.secondJoueur = CreationDePersonnage(\"joueur2\");\n Combat();\n Saisie.Terminer();\n }",
"public Test(){\n calcula = new Calculadora();\n estaBien = \"ERROR\";\n funciona = \"SI\";\n lista = new ArrayList<String>();\n }",
"public Candidatura (){\n \n }",
"Vaisseau_estOrdonneeCouverte createVaisseau_estOrdonneeCouverte();",
"public Alojamiento() {\r\n\t}",
"public Perro() {\n// super(\"No define\", \"NN\", 0); en caso el constructor de animal tenga parametros\n this.pelaje = \"corto\";\n }",
"public Erreur() {\n\t}",
"public Prova() {}",
"private GrupoCuenta(String nombre, int operacion)\r\n/* 11: */ {\r\n/* 12:31 */ this.nombre = nombre;\r\n/* 13:32 */ this.operacion = operacion;\r\n/* 14: */ }",
"public ContaBancaria() {\n }",
"public Joueur(int id, int pa)\r\n/* */ {\r\n/* 34 */ this.id_joueur = id;\r\n/* 35 */ this.points_action = pa;\r\n/* */ }",
"public SlanjePoruke() {\n }",
"Vaisseau_positionner createVaisseau_positionner();",
"public Classe() {\r\n }",
"Position_ordonnee createPosition_ordonnee();",
"public QLNhanVien(){\n \n }",
"public EnsembleLettre() {\n\t\t\n\t}",
"public Lanceur() {\n\t}",
"public TebakNusantara()\n {\n }",
"public VotacaoSegundoDia() {\n\n\t}",
"public Pitonyak_09_02() {\r\n }",
"private IOferta buildOfertaEjemplo4() {\n\t\tPredicate<Compra> condicion = Predicates.alwaysTrue();\n\t\tFunction<Compra, Float> descuento = new DescuentoLlevaXPagaY(\"11-111-1111\", 3, 2);\n\t\treturn new OfertaDinero(\"Lleva 3 paga 2 en Coca-Cola\", condicion,\n\t\t\t\tdescuento);\n\t}",
"Vaisseau_longueur createVaisseau_longueur();",
"Vaisseau createVaisseau();",
"public AfiliadoVista() {\r\n }",
"public void crearAutomovil(){\r\n automovil = new Vehiculo();\r\n automovil.setMarca(\"BMW\");\r\n automovil.setModelo(2010);\r\n automovil.setPlaca(\"TWS435\");\r\n }",
"public Corso() {\n\n }",
"@Override\r\n\tpublic void crearVehiculo() {\n\t\t\r\n\t}",
"Vaisseau_Vaisseau createVaisseau_Vaisseau();",
"Vaisseau_Vaisseau createVaisseau_Vaisseau();",
"Vaisseau_Vaisseau createVaisseau_Vaisseau();",
"Vaisseau_Vaisseau createVaisseau_Vaisseau();",
"public Sobre() {\n\t\tsuper();\n\t\tinitialize();\n\t}",
"public YonetimliNesne() {\n }",
"public Anschrift() {\r\n }",
"public Civilisation(int id, String nameNullForRandom, Case firstCase, Color couleur, Ideologie ideologie, Regime regime, PolTerritoriale polT) {\r\n\t\t\r\n\t\tthis.id = id;\r\n\t\tthis.culture = new Basique();\r\n\t\tthis.ideologie = ideologie;\r\n\t\tthis.regimePolitique = regime;\r\n\t\tthis.couleur = new Color(couleur.getRed(), couleur.getGreen(), couleur.getBlue(), 150);\r\n\t\t//this.couleur = new Color(couleur.getRed(), couleur.getGreen(), couleur.getBlue());\r\n\t\tnom = (nameNullForRandom != null) ? nameNullForRandom : noms[(int)(Math.random()*noms.length)];\r\n\t\tpopulation = 10;\r\n\t\tpopulationColoniale = 0;\r\n\t\tproduction = 0;\r\n\t\teconomie = 0;\r\n\t\tinfluence = 0;\r\n\t\tarmee = 0;\r\n\t\tscienceLvl = 1;\r\n\t\tscience = 10; //decrementation de la science pour passer au lvl supp\r\n\t\tnourriture = 50;\r\n\t\tcaseOwned = new ArrayList<>();\r\n\t\tressourcesStrat = new ArrayList<>();\r\n\t\tressourcesAnimal = new ArrayList<>();\r\n\t\taggresiveWar = new ArrayList<>();\r\n\t\tdefensiveWar = new ArrayList<>();\r\n\t\tvoisins = checkVoisins();\r\n\t\tenFamine = false;\r\n\t\ttauxEducation = 0;\r\n\t\ttauxCroissance = 0.02; // =1x taux mondiale IRL\r\n\t\ttauxAccroissementScience = 1.2;\r\n\t\tbaseScience = 10;\r\n\t\tbaseBonheur = 10;\r\n\t\tbaseEfficaciteArmee = 1;\r\n\t\tnoteMinimale = firstCase.note();\r\n\t\taddCase(firstCase);\r\n\t\tfor(Case c : firstCase.getVoisinesLibres()) addCase(c);\r\n\t\timpactRegime();\r\n\t\tthis.politiqueTerritoriale = polT;\r\n\t\tcalculerBonheur();\r\n\t\tcalculerEffiArmee();\r\n\t\t\r\n\t}",
"@Override\n\tpublic void initialisation_type_exercice() {\n\t\tthis.setEnnonce_exo(\"Ecrire un algorithme qui demande deux nombres à l’utilisateur et l’informe ensuite si le produit est négatif ou positif (on inclut cette fois le traitement du cas où le produit peut être nul). Attention toutefois, on ne doit pas calculer le produit !\");\n\n\t}",
"public EtatInitialisation(Controleur controleur) {\n super(controleur);\n super.rendControleur().lancerEcranDemarrage();\n }",
"public CCuenta()\n {\n }",
"public CampoModelo(String valor, String etiqueta, Integer longitud)\n/* 10: */ {\n/* 11:17 */ this.valor = valor;\n/* 12:18 */ this.etiqueta = etiqueta;\n/* 13:19 */ this.longitud = longitud;\n/* 14: */ }",
"ClaseColas() { // Constructor que inicializa el frente y el final de la Cola\r\n frente=0; fin=0;\r\n System.out.println(\"Cola inicializada !!!\");\r\n }",
"private TIPO_REPORTE(String nombre)\r\n/* 55: */ {\r\n/* 56: 58 */ this.nombre = nombre;\r\n/* 57: */ }",
"public Oveja() {\r\n this.nombreOveja = \"Oveja\";\r\n }",
"public ejercicio1() {\n this.cadena = \"\";\n this.buscar = \"\";\n }",
"public Funcionaria(){\n\n }",
"public nomina()\n {\n deducidoClase = new deducido();\n devengadoClase = new devengado();\n }",
"public Veiculo() {\r\n\r\n }",
"public Valvula(){}",
"public Supercar() {\r\n\t\t\r\n\t}",
"public Exercicio(){\n \n }",
"Vaisseau_abscisseLaPlusAGauche createVaisseau_abscisseLaPlusAGauche();",
"public Methods() { // ini adalah sebuah construktor kosong tidak ada parameternya\n System.out.println(\"Ini adalah Sebuah construktor \");\n }",
"public TelaSobre() {\n initComponents();\n }",
"public Commande() {\n }",
"@Test\n\t@Category(TesteUrgente.class)\n\tpublic void testConstructorLista() {\n\t\tGrupa grupa=new Grupa(1076);\n\t\tassertNotNull(grupa.getStudenti());\n\t}",
"public abstract Anuncio creaAnuncioGeneral();",
"public Contribuinte()\n {\n this.nif = \"\";\n this.nome = \"\";\n this.morada = \"\"; \n }",
"public MusiqueFiducial(){\n\t\tinitialisation();\n\t}",
"public ValorVariavel() {\r\n }",
"public Achterbahn() {\n }",
"public Estudiante(String nom) // Constructor 1: Se le asigna un valor al atributo nombre cuando se cree el objeto.\r\n {\r\n this.nombre = nom;\r\n }",
"public Destruir() {\r\n }",
"public Constructor(){\n\t\t\n\t}",
"public Coche() {\n super();\n }",
"public static void main(String[] args) {\n ArrayList<String> tab = new ArrayList<>();\n tab.add(\"First\");\n tab.add(\"Hello\");\n tab.add(\"Last\");\n //Creation du modele\n LeModele leModele = new LeModele(tab);\n\n //Creation du controleur\n LeControleur leControleur = new LeControleur(leModele);\n\n //Creation de la vue\n LaVue laVue = new LaVue(leControleur);\n\n\n //Test\n\n\n }",
"public Busca(){\n }",
"public contrustor(){\r\n\t}",
"public RptPotonganGaji() {\n }",
"public CadastroComplemento() {\n initComponents();\n \n }",
"public RuimteFiguur() {\n kleur = \"zwart\";\n }",
"public Carrera(){\n }",
"public Fruitore()\r\n\t{\r\n\t\tthis.nomeUtente = Costanti.STRINGA_VUOTA;\r\n\t}",
"Vaisseau_seDeplacerVersLaGauche createVaisseau_seDeplacerVersLaGauche();",
"public FiltroMicrorregiao() {\r\n }"
] | [
"0.73397887",
"0.7310296",
"0.72801805",
"0.7230036",
"0.7197753",
"0.7154796",
"0.7139862",
"0.7088856",
"0.70835304",
"0.70245486",
"0.6904713",
"0.68948936",
"0.6878655",
"0.68758327",
"0.6863235",
"0.68055445",
"0.6776962",
"0.6772298",
"0.6765706",
"0.6732786",
"0.67098886",
"0.6704634",
"0.6694166",
"0.6682644",
"0.6675736",
"0.66515166",
"0.6640381",
"0.6629643",
"0.66252196",
"0.66217494",
"0.6611396",
"0.65716165",
"0.6559653",
"0.6546546",
"0.6542067",
"0.6522275",
"0.6519861",
"0.6509632",
"0.6499366",
"0.64648145",
"0.64495957",
"0.6449576",
"0.6445508",
"0.6424302",
"0.6423738",
"0.64232206",
"0.6422665",
"0.64121693",
"0.64092",
"0.6393673",
"0.6391185",
"0.6386923",
"0.63841087",
"0.63797843",
"0.6364667",
"0.6362391",
"0.6362391",
"0.6362391",
"0.6362391",
"0.63543916",
"0.63504463",
"0.6349109",
"0.63473994",
"0.6347236",
"0.6346472",
"0.63449395",
"0.6317052",
"0.6313157",
"0.6312972",
"0.63094884",
"0.63072836",
"0.6307153",
"0.63067853",
"0.6302633",
"0.6300931",
"0.62886053",
"0.6288082",
"0.6267906",
"0.6267495",
"0.62669295",
"0.62635964",
"0.62594837",
"0.6253877",
"0.624698",
"0.62405396",
"0.6239433",
"0.62378997",
"0.62361413",
"0.62354916",
"0.6235034",
"0.6233753",
"0.6226872",
"0.622241",
"0.62200564",
"0.6218309",
"0.6212245",
"0.6207959",
"0.62071323",
"0.62056315",
"0.6191507",
"0.6180544"
] | 0.0 | -1 |
3_Les Getters et Setters 3_Les Getters et Setters | public BarChartModel getBarModel() {
return barModel;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setdat()\n {\n }",
"protected abstract Set method_1559();",
"public void setEnqueteur(Enqueteur enqueteur)\r\n/* */ {\r\n/* 65 */ this.enqueteur = enqueteur;\r\n/* */ }",
"public void setNombre(String nombre) {this.nombre = nombre;}",
"public void setNombre(String nombre){\n this.nombre =nombre;\n }",
"public void setValor(String valor)\n/* 22: */ {\n/* 23:34 */ this.valor = valor;\n/* 24: */ }",
"public void asetaTeksti(){\n }",
"public void setEmpresa(Empresa empresa)\r\n/* 89: */ {\r\n/* 90:141 */ this.empresa = empresa;\r\n/* 91: */ }",
"public void setNombre(String nombre) {\r\n\tthis.nombre = nombre;\r\n}",
"public void setNombre(String nombre)\r\n/* 65: */ {\r\n/* 66: 76 */ this.nombre = nombre;\r\n/* 67: */ }",
"String setValue();",
"@Override\n public void saveValues() {\n \n }",
"private void assignment() {\n\n\t\t\t}",
"public abstract void setNombre(java.lang.String newNombre);",
"private void setData() {\n\n }",
"public void setNombre(String nombre)\r\n/* 118: */ {\r\n/* 119:214 */ this.nombre = nombre;\r\n/* 120: */ }",
"public void setM_Locator_ID (int M_Locator_ID)\n{\nset_Value (\"M_Locator_ID\", new Integer(M_Locator_ID));\n}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"public void setOrigen(java.lang.String param){\n \n this.localOrigen=param;\n \n\n }",
"public void setAge(int age) { this.age = age; }",
"public void setC_UOM_ID (int C_UOM_ID)\n{\nset_Value (\"C_UOM_ID\", new Integer(C_UOM_ID));\n}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Test\n public void testSetNombre() {\n System.out.println(\"setNombre\");\n String nombre = \"T-3\";\n DboEdificio instance = new DboEdificio(1, \"T-3\");\n instance.setNombre(nombre);\n \n }",
"@Override\n\tpublic void setData() {\n\n\t}",
"public void setLongitud(Integer longitud)\n/* 42: */ {\n/* 43:62 */ this.longitud = longitud;\n/* 44: */ }",
"public void setTelefono(String telefono) {\r\n\tthis.telefono = telefono;\r\n}",
"public void setM_Product_ID (int M_Product_ID)\n{\nset_Value (\"M_Product_ID\", new Integer(M_Product_ID));\n}",
"public void setU(String f){\n u = f;\n}",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Test\n public void testSongGettersSetters() {\n Integer id = 4;\n String title=\"title\",uri = \"uri\";\n\n Song song = new Song();\n song.setId(id);\n song.setTitle(title);\n song.setUri(uri);\n\n assertEquals(\"Problem with id\",id, song.getId());\n assertEquals(\"Problem with title\",title, song.getTitle());\n assertEquals(\"Problem with uri\",uri, song.getUri());\n }",
"@Override\npublic void setAttributes() {\n\t\n}",
"@Override\n public void memoria() {\n \n }",
"@Override\r\n protected void setFieldValues (Object ... fields)\r\n {\n \r\n }",
"@Override\n\t\tpublic void set(E arg0) {\n\t\t\t\n\t\t}",
"public abstract void set(DataType x, DataType y, DataType z);",
"public void setC_Conversion_UOM_ID (int C_Conversion_UOM_ID)\n{\nset_Value (\"C_Conversion_UOM_ID\", new Integer(C_Conversion_UOM_ID));\n}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void initializeValues() {\n\n\t}",
"void setNama(String nama){\n this.nama = nama;\n }",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Test\n public void testSetLugarNac() {\n System.out.println(\"setLugarNac\");\n String lugarNac = \"\";\n Paciente instance = new Paciente();\n instance.setLugarNac(lugarNac);\n \n }",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"void setParameters() {\n\t\t\n\t}",
"public void setId_joueur(int id_joueur)\r\n/* */ {\r\n/* 50 */ this.id_joueur = id_joueur;\r\n/* */ }",
"private void setUserData(){\n }",
"public void Ordenamiento() {\n\n\t}",
"@Override\n\tpublic void alterar() {\n\t\t\n\t}",
"@Test\r\n public void testSetValor() {\r\n \r\n }",
"@Override\r\n\tprotected void initVentajas() {\n\r\n\t}",
"@Test\n\tpublic void testSet() {\n\t}",
"@Test\n public void testSetId_edificio() {\n System.out.println(\"setId_edificio\");\n int id_edificio = 1;\n DboEdificio instance = new DboEdificio(1, \"T-3\");\n instance.setId_edificio(id_edificio);\n \n }",
"@Override // Métodos que fazem a anulação\n\tpublic void vota() {\n\t\t\n\t}",
"@Test\r\n public void testSetOrigen() {\r\n String expResult = \"pruebaorigen\";\r\n articuloPrueba.setOrigen(expResult);\r\n assertEquals(expResult, articuloPrueba.getOrigen());\r\n }",
"@Override\r\n\tpublic void get() {\n\t\t\r\n\t}",
"public void setM_Warehouse_ID (int M_Warehouse_ID)\n{\nset_Value (\"M_Warehouse_ID\", new Integer(M_Warehouse_ID));\n}",
"@Test\n public void testSetValue ()\n {\n System.out.println (\"setValue\");\n String name = \"\";\n QueryDatas instance = new QueryDatas (\"nom\", \"value\");\n instance.setValue (name);\n }",
"@Test\n public void testSetNombre() {\n System.out.println(\"setNombre\");\n Receta instance = new Receta();\n instance.setNombre(\"nom1\");\n String expResult = \"nom1\";\n String result = instance.getNombre();\n assertEquals(expResult, result);\n }",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void setName(String name){this.name=name;}",
"public void setAutorizacion(String autorizacion)\r\n/* 139: */ {\r\n/* 140:236 */ this.autorizacion = autorizacion;\r\n/* 141: */ }",
"public cola_de_un_banco(){// se crea nuestro metodo costructor \r\n primero=null;//se crea el tipo de indicaciones con valor a null\r\n ultimo=null;\r\n}",
"public abstract void setCod_tecnico(java.lang.String newCod_tecnico);",
"public void setCodigo(java.lang.String param){\n \n this.localCodigo=param;\n \n\n }",
"public void setNumero(int numero)\r\n/* 195: */ {\r\n/* 196:206 */ this.numero = numero;\r\n/* 197: */ }",
"@Override\n public void onSetSuccess() {\n }",
"@Override\n public void onSetSuccess() {\n }",
"@Override\n\tpublic void set(T e) {\n\t\t\n\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Test\r\n public void testSetNombre() {\r\n String nombre = \"Prueba\";\r\n articuloPrueba.setNombre(nombre);\r\n assertEquals(nombre, articuloPrueba.getNombre());\r\n }",
"public void setPrice(double price){this.price=price;}",
"public abstract void setAcma_cierre(java.lang.String newAcma_cierre);",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"@Test\n public void testGetSets() {\n ref.setKey(\"test23\");\n assertEquals(\"test23\", ref.getKey());\n ref.setAuthor(\"test23\");\n assertEquals(\"test23\", ref.getAuthor());\n ref.setEditor(\"test23\");\n assertEquals(\"test23\", ref.getEditor());\n ref.setTitle(\"test23\");\n assertEquals(\"test23\", ref.getTitle());\n ref.setBooktitle(\"test23\");\n assertEquals(\"test23\", ref.getBooktitle());\n ref.setYear(\"1839\");\n assertEquals(\"1839\", ref.getYear());\n ref.setPublisher(\"Otava\");\n assertEquals(\"Otava\", ref.getPublisher());\n ref.setJournal(\"test23\");\n assertEquals(\"test23\", ref.getJournal());\n ref.setVolume(\"3\");\n assertEquals(\"3\", ref.getVolume());\n ref.setNumber(\"123\");\n assertEquals(\"123\", ref.getNumber());\n ref.setSeries(\"test23\");\n assertEquals(\"test23\", ref.getSeries());\n ref.setEdition(\"3rd\");\n assertEquals(\"3rd\", ref.getEdition());\n ref.setPages(\"12-35\");\n assertEquals(\"12-35\", ref.getPages());\n ref.setMonth(\"May\");\n assertEquals(\"May\", ref.getMonth());\n ref.setNote(\"test23\");\n assertEquals(\"test23\", ref.getNote());\n }",
"public void setGender(Gender_Tp gender) { this.gender = gender; }",
"void setDataIntoSuppBusObj() {\r\n supplierBusObj.setValue(txtSuppId.getText(),txtSuppName.getText(), txtAbbreName.getText(),\r\n txtContactName.getText(),txtContactPhone.getText());\r\n }",
"public void setPuntoDeVenta(PuntoDeVenta puntoDeVenta)\r\n/* 145: */ {\r\n/* 146:166 */ this.puntoDeVenta = puntoDeVenta;\r\n/* 147: */ }",
"public void setEmpleado(Empleado empleado)\r\n/* 188: */ {\r\n/* 189:347 */ this.empleado = empleado;\r\n/* 190: */ }",
"public void modifier(){\r\n try {\r\n //affectation des valeur \r\n echeance_etudiant.setIdEcheanceEtu(getViewEtudiantInscripEcheance().getIdEcheanceEtu()); \r\n \r\n echeance_etudiant.setAnneeaca(getViewEtudiantInscripEcheance().getAnneeaca());\r\n echeance_etudiant.setNumetu(getViewEtudiantInscripEcheance().getNumetu());\r\n echeance_etudiant.setMatricule(getViewEtudiantInscripEcheance().getMatricule());\r\n echeance_etudiant.setCodeCycle(getViewEtudiantInscripEcheance().getCodeCycle());\r\n echeance_etudiant.setCodeNiveau(getViewEtudiantInscripEcheance().getCodeNiveau());\r\n echeance_etudiant.setCodeClasse(getViewEtudiantInscripEcheance().getCodeClasse());\r\n echeance_etudiant.setCodeRegime(getViewEtudiantInscripEcheance().getCodeRegime());\r\n echeance_etudiant.setDrtinscri(getViewEtudiantInscripEcheance().getInscriptionAPaye());\r\n echeance_etudiant.setDrtforma(getViewEtudiantInscripEcheance().getFormationAPaye()); \r\n \r\n echeance_etudiant.setVers1(getViewEtudiantInscripEcheance().getVers1());\r\n echeance_etudiant.setVers2(getViewEtudiantInscripEcheance().getVers2());\r\n echeance_etudiant.setVers3(getViewEtudiantInscripEcheance().getVers3());\r\n echeance_etudiant.setVers4(getViewEtudiantInscripEcheance().getVers4());\r\n echeance_etudiant.setVers5(getViewEtudiantInscripEcheance().getVers5());\r\n echeance_etudiant.setVers6(getViewEtudiantInscripEcheance().getVers6()); \r\n \r\n //modification de l'utilisateur\r\n echeance_etudiantFacadeL.edit(echeance_etudiant); \r\n } catch (Exception e) {\r\n System.err.println(\"Erreur de modification capturée : \"+e);\r\n } \r\n }",
"public interface Poulet {\n /*DEFINIT le nombre de like effectué par ce poulet */\n public void setnombreLike(int nombre_like);\n\n /*DEFINIT le nombre de match de ce poulet */\n public void setnombreMatch(int nombre_match);\n\n}",
"public Final_parametre() {\r\n\t}",
"@Test\n public void testSetTipoSangre() {\n System.out.println(\"setTipoSangre\");\n String tipoSangre = \"\";\n Paciente instance = new Paciente();\n instance.setTipoSangre(tipoSangre);\n \n }",
"@Override\n protected void updateProperties() {\n }",
"@Override\r\n\tprotected void init() {\n\t\tupdateValues();\r\n\t}",
"public void setItems(){\n }",
"@Test\r\n public void testSetMicentro() {\r\n System.out.println(\"setMicentro\");\r\n CentroEcu_Observado micentro = new CentroEcu_Observado();\r\n micentro.setCiudad(\"Loja\");\r\n Servicio_CentroEcu instance = new Servicio_CentroEcu();\r\n instance.setMicentro(micentro);\r\n assertEquals(instance.getMicentro().ciudad, \"Loja\");\r\n }",
"public void setEtiqueta(String etiqueta)\n/* 32: */ {\n/* 33:48 */ this.etiqueta = etiqueta;\n/* 34: */ }",
"public void setModified();",
"@Test\r\n\tpublic void gettersSettersTest() {\r\n\t\tItem item = new Item();\r\n\t\titem.setCount(NUMBER);\r\n\t\tassertEquals(item.getCount(), NUMBER);\r\n\t\titem.setDescription(\"word\");\r\n\t\tassertEquals(item.getDescription(), \"word\");\r\n\t\titem.setId(NUMBER);\r\n\t\tassertEquals(item.getId(), NUMBER);\r\n\t\titem.setName(\"word\");\r\n\t\tassertEquals(item.getName(), \"word\");\r\n\t\titem.setPicture(\"picture\");\r\n\t\tassertEquals(item.getPicture(), \"picture\");\r\n\t\titem.setPrice(FLOATNUMBER);\r\n\t\tassertEquals(item.getPrice(), FLOATNUMBER, 0);\r\n\t\titem.setType(\"word\");\r\n\t\tassertEquals(item.getType(), \"word\");\r\n\t\titem.setSellerId(NUMBER);\r\n\t\tassertEquals(item.getSellerId(), NUMBER);\r\n\t\titem.setDeleted(false);\r\n\t\tassertEquals(item.isDeleted(), false);\r\n\t\titem.setDeleted(true);\r\n\t\tassertEquals(item.isDeleted(), true);\t\t\r\n\t}",
"public void setObservacion(java.lang.String param){\n \n this.localObservacion=param;\n \n\n }",
"public abstract void setLibelle(String unLibelle);",
"@Test\r\n\tpublic void testGettersSetters()\r\n\t{\r\n\t\tPerson p = new Person(42);\r\n\t\tp.setDisplayName(\"Fred\");\r\n\t\tassertEquals(\"Fred\", p.getFullname());\r\n\t\tp.setPassword(\"hunter2\");\r\n\t\tassertEquals(\"hunter2\", p.getPassword());\r\n\t\tassertEquals(42, p.getID());\r\n\t}",
"@Override\n\tpublic void setValue(String arg0, String arg1) {\n\t\t\n\t}",
"public void set() {\r\n\t\tage = 19;\r\n\t\tname = \"ΎΛ·»\";\r\n\t\theight = 161;\r\n\t\tsetWeight(50);\r\n\t\tSystem.out.println(getWeight());\r\n\t}",
"public abstract void setAcma_valor(java.lang.String newAcma_valor);",
"@Override\r\n\t\tpublic void set(E arg0) {\n\r\n\t\t}",
"private SetProperty(Builder builder) {\n super(builder);\n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void set() {\n\t\tSystem.out.println(\"A==========set\");\n\t}",
"@Override\n public void setField(int id, int value) {\n \n }"
] | [
"0.6815128",
"0.6772174",
"0.6462276",
"0.6460035",
"0.6400728",
"0.6355441",
"0.6342186",
"0.633869",
"0.6331871",
"0.63049614",
"0.62339693",
"0.6156957",
"0.6150489",
"0.6150142",
"0.6102513",
"0.6100548",
"0.6099166",
"0.6091646",
"0.60783434",
"0.60650957",
"0.60594887",
"0.6058043",
"0.60376346",
"0.6031723",
"0.60277814",
"0.60252833",
"0.6015688",
"0.60128236",
"0.60023046",
"0.59987444",
"0.59930784",
"0.59856796",
"0.5984285",
"0.5967797",
"0.59577835",
"0.595298",
"0.5941115",
"0.59404194",
"0.5938955",
"0.5937835",
"0.5927231",
"0.5915229",
"0.59144187",
"0.5909639",
"0.59072983",
"0.5899903",
"0.5889764",
"0.5885607",
"0.5883916",
"0.588097",
"0.58777225",
"0.58765274",
"0.58762556",
"0.58751565",
"0.587448",
"0.5871001",
"0.5867469",
"0.5866472",
"0.5858177",
"0.5851685",
"0.5850462",
"0.58467567",
"0.58457077",
"0.5844266",
"0.5842082",
"0.5836169",
"0.5836169",
"0.5834411",
"0.58327585",
"0.58281255",
"0.5821825",
"0.58184063",
"0.58163756",
"0.58117217",
"0.579959",
"0.57969624",
"0.5796773",
"0.57964903",
"0.5794958",
"0.57942235",
"0.57941765",
"0.57896745",
"0.57891",
"0.5787085",
"0.57856417",
"0.5780732",
"0.57802814",
"0.5777945",
"0.5775492",
"0.5774603",
"0.57744664",
"0.5771676",
"0.5765722",
"0.57639825",
"0.5762066",
"0.5760885",
"0.5748584",
"0.5745849",
"0.57456934",
"0.5745572",
"0.57441825"
] | 0.0 | -1 |
specifies text file and word document | public static void main(String[] args) {
File text = new File("Quote.txt");
File doc = new File("Quote.docx");
// makes sure both files exist
if (text.exists() && doc.exists()) {
// calculates word document length to text document length ratio
long ratio = doc.length() / text.length();
// outputs text file size
System.out.println("Quote.txt size: " + text.length() + " bytes.");
// outputs word document size
System.out.println("Quote.docx size: " + doc.length() + " bytes.");
// outputs word-to-text ratio
System.out.println("Ratio: The word document is " + ratio + " times the size of the text file.");
}
// displays error if either file cannot be found
else {
System.out.println("Text file and/or word document not found.");
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void ach_doc_type_txt_test () {\n\t\t\n\t}",
"public abstract TextDocument getTextDocumentFromFile(String path) throws FileNotFoundException, IOException;",
"private void createDocWords() {\n\t\tArrayList<DocWords> docList=new ArrayList<>();\n\t\ttry {\n\t\t\tBufferedReader in = new BufferedReader(new FileReader(\"E:\\\\graduate\\\\cloud\\\\project\\\\data\\\\docWords.txt\"));\n\t\t\tString line = \"\";\n\t\t\twhile ((line = in.readLine()) != null) {\n\t\t\t\tString parts[] = line.split(\" \");\n\t\t\t\tDocWords docWords=new DocWords();\n\t\t\t\tdocWords.setDocName(parts[0].replace(\".txt\", \"\"));\n\t\t\t\tdocWords.setCount(Float.parseFloat(parts[1]));\n\t\t\t\tdocList.add(docWords);\n\t\t\t}\n\t\t\tin.close();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\tDBUtil.insertDocWords(docList);\n\t}",
"boolean hasTextDocument();",
"public interface WordInte {\n\n /**\n *\n * Se crea este metodo para realizar la escritura de un archivo en word,\n * apartir de un formato o plantilla existente en formato DOT.\n *\n * @param pathPlan ruta de la plantilla\n * @param pathDeex ruta destino donde se va almacenar resultado de la \n * plantilla.\n * @param pathFida ruta del archivo de datos que se van agregar en la \n * plantilla.\n * @param separato separador que se usa para identificar las columnas en el\n * archivo de datos\n *\n * @throws Exception indica que el metodo genera excepciones que deben ser\n * capturadas para identificar cuando la misma no funcione bien.\n */\n public void writDOT(String pathPlan, String pathDeex, String pathFida, String separato) throws Exception; \n \n /***\n * Metodo para realizar la compresion de un directorio que se pase por parametro.\n * @param pathDire ruta del directorio\n * @throws Exception genera la excepcion.\n */\n public void compDire(String pathDire) throws Exception; \n \n \n}",
"private void createDocs() {\n\t\t\n\t\tArrayList<Document> docs=new ArrayList<>();\n\t\tString foldername=\"E:\\\\graduate\\\\cloud\\\\project\\\\data\\\\input\";\n\t\tFile folder=new File(foldername);\n\t\tFile[] listOfFiles = folder.listFiles();\n\t\tfor (File file : listOfFiles) {\n\t\t\ttry {\n\t\t\t\tFileInputStream fisTargetFile = new FileInputStream(new File(foldername+\"\\\\\"+file.getName()));\n\t\t\t\tString fileContents = IOUtils.toString(fisTargetFile, \"UTF-8\");\n\t\t\t\tString[] text=fileContents.split(\"ParseText::\");\n\t\t\t\tif(text.length>1){\n\t\t\t\t\tString snippet=text[1].trim().length()>100 ? text[1].trim().substring(0, 100): text[1].trim();\n\t\t\t\t\tDocument doc=new Document();\n\t\t\t\t\tdoc.setFileName(file.getName().replace(\".txt\", \"\"));\n\t\t\t\t\tdoc.setUrl(text[0].split(\"URL::\")[1].trim());\n\t\t\t\t\tdoc.setText(snippet+\"...\");\n\t\t\t\t\tdocs.add(doc);\n\t\t\t\t}\n\t\t\t}catch(IOException e){\n\t\t\t\te.printStackTrace();\n\t\t\t}\t\n\t\t}\t\n\t\tDBUtil.insertDocs(docs);\n\t}",
"static void allDocumentAnalyzer() throws IOException {\n\t\tFile allFiles = new File(\".\"); // current directory\n\t\tFile[] files = allFiles.listFiles(); // file array\n\n\t\t// recurse through all documents\n\t\tfor (File doc : files) {\n\t\t\t// other files we don't need\n\t\t\tif (doc.getName().contains(\".java\") || doc.getName().contains(\"words\") || doc.getName().contains(\"names\")\n\t\t\t\t\t|| doc.getName().contains(\"phrases\") || doc.getName().contains(\".class\")\n\t\t\t\t\t|| doc.getName().contains(\"Data\") || doc.getName().contains(\".sh\") || doc.isDirectory()\n\t\t\t\t\t|| !doc.getName().contains(\".txt\")) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tString name = doc.getName();\n\t\t\tSystem.out.println(name);\n\t\t\tname = name.substring(0, name.length() - 11);\n\t\t\tSystem.out.println(name);\n\n\t\t\tif (!names.contains(name)) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// make readers\n\t\t\tFileReader fr = new FileReader(doc);\n\t\t\tBufferedReader br = new BufferedReader(fr);\n\n\t\t\t// phrase list\n\t\t\tArrayList<String> words = new ArrayList<String>();\n\n\t\t\t// retrieve all text, trim, refine and add to phrase list\n\t\t\tString nextLine = br.readLine();\n\t\t\twhile (nextLine != null) {\n\t\t\t\tnextLine = nextLine.replace(\"\\n\", \" \");\n\t\t\t\tnextLine = nextLine.trim();\n\n\t\t\t\tif (nextLine.contains(\"no experience listed\")) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\tString[] lineArray = nextLine.split(\"\\\\s+\");\n\n\t\t\t\t// recurse through every word to find phrases\n\t\t\t\tfor (int i = 0; i < lineArray.length - 1; i++) {\n\t\t\t\t\t// get the current word and refine\n\t\t\t\t\tString currentWord = lineArray[i];\n\n\t\t\t\t\tcurrentWord = currentWord.trim();\n\t\t\t\t\tcurrentWord = refineWord(currentWord);\n\n\t\t\t\t\tif (currentWord.equals(\"\") || currentWord.isEmpty()) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\twords.add(currentWord);\n\t\t\t\t}\n\t\t\t\tnextLine = br.readLine();\n\t\t\t}\n\n\t\t\tbr.close();\n\n\t\t\t// continue if empty\n\t\t\tif (words.size() == 0) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// otherwise, increment number of files in corpus\n\t\t\tsize++;\n\n\t\t\t// updating the phrase count map for tf\n\t\t\tString fileName = doc.getName();\n\t\t\tphraseCountMap.put(fileName, words.size());\n\n\t\t\t// recurse through every word\n\t\t\tfor (String word : words) {\n\t\t\t\t// get map from string to freq\n\t\t\t\tHashMap<String, Integer> textFreqMap = wordFreqMap.get(fileName);\n\n\t\t\t\t// if it's null, make one\n\t\t\t\tif (textFreqMap == null) {\n\t\t\t\t\ttextFreqMap = new HashMap<String, Integer>();\n\t\t\t\t\t// make freq as 1\n\t\t\t\t\ttextFreqMap.put(word, 1);\n\t\t\t\t\t// put that in wordFreq\n\t\t\t\t\twordFreqMap.put(fileName, textFreqMap);\n\t\t\t\t} else {\n\t\t\t\t\t// otherwise, get the current num\n\t\t\t\t\tInteger currentFreq = textFreqMap.get(word);\n\n\t\t\t\t\t// if it's null,\n\t\t\t\t\tif (currentFreq == null) {\n\t\t\t\t\t\t// the frequency is just 0\n\t\t\t\t\t\tcurrentFreq = 0;\n\t\t\t\t\t}\n\n\t\t\t\t\t// increment the frequency\n\t\t\t\t\tcurrentFreq++;\n\n\t\t\t\t\t// put it in the textFreqMap\n\t\t\t\t\ttextFreqMap.put(word, currentFreq);\n\n\t\t\t\t\t// put that in the wordFreqMap\n\t\t\t\t\twordFreqMap.put(fileName, textFreqMap);\n\t\t\t\t}\n\n\t\t\t\t// add this to record (map from phrases to docs with that\n\t\t\t\t// phrase)\n\t\t\t\tinvertedMap.addValue(word, doc);\n\t\t\t}\n\t\t}\n\t}",
"public boolean checkDocument(String fileName) throws IOException;",
"public abstract Iterable<String> addDocument(TextDocument doc) throws IOException;",
"public void writeDocumentForA(String filename, String path) throws Exception\r\n\t{\n\t\tFile folder = new File(path);\r\n\t\tFile[] listOfFiles = folder.listFiles();\r\n\t \r\n\t \r\n\t \tFileWriter fwText;\r\n\t\tBufferedWriter bwText;\r\n\t\t\r\n\t\tfwText = new FileWriter(\"C:/Users/jipeng/Desktop/Qiang/updateSum/TAC2008/Parag/\"+ filename+\"/\" +\"A.txt\");\r\n\t\tbwText = new BufferedWriter(fwText);\r\n\t\t\r\n\t \tfor ( int i=0; i<listOfFiles.length; i++) {\r\n\t \t\t//String name = listOfFiles[i].getName();\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tString text = readText(listOfFiles[i].getAbsolutePath());\r\n\t\t\t\r\n\t\t\tFileWriter fwWI = new FileWriter(\"C:/pun.txt\");\r\n\t\t\tBufferedWriter bwWI = new BufferedWriter(fwWI);\r\n\t\t\t\r\n\t\t\tbwWI.write(text);\r\n\t\t\t\r\n\t\t\tbwWI.close();\r\n\t\t\tfwWI.close();\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tList<List<HasWord>> sentences = MaxentTagger.tokenizeText(new BufferedReader(new FileReader(\"C:/pun.txt\")));\r\n\t\t\t\r\n\t\t\t//System.out.println(text);\r\n\t\t\tArrayList<Integer> textList = new ArrayList<Integer>();\r\n\t\t\t\r\n\t\t\tfor (List<HasWord> sentence : sentences)\r\n\t\t\t {\r\n\t\t\t ArrayList<TaggedWord> tSentence = tagger.tagSentence(sentence);\r\n\t\t\t \r\n\t\t\t for(int j=0; j<tSentence.size(); j++)\r\n\t\t\t {\r\n\t\t\t \t \tString word = tSentence.get(j).value();\r\n\t\t\t \t \t\r\n\t\t\t \t \tString token = word.toLowerCase();\r\n\t\t\t \t \r\n\t\t\t \t \tif(token.length()>2 )\r\n\t\t\t\t \t{\r\n\t\t\t \t\t\t if (!m_EnStopwords.isStopword(token)) \r\n\t\t\t \t\t\t {\r\n\t\t\t \t\t\t\t\r\n\t\t\t\t\t\t\t\t if (word2IdHash.get(token)==null)\r\n\t\t\t\t\t\t\t\t {\r\n\t\t\t\t\t\t\t\t\t textList.add(id);\r\n\t\t\t\t\t\t\t\t\t // bwText.write(String.valueOf(id)+ \" \");\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t word2IdHash.put(token, id);\r\n\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\t\t\t allWordsArr.add(token);\r\n\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\t\t\t id++;\r\n\t\t\t\t\t\t\t\t } else\r\n\t\t\t\t\t\t\t\t {\r\n\t\t\t\t\t\t\t\t \tint wid=(Integer)word2IdHash.get(token);\r\n\t\t\t\t\t\t\t\t \tif(!textList.contains(wid))\r\n\t\t\t\t\t\t\t\t \t\ttextList.add(wid);\r\n\t\t\t\t\t\t\t\t \t//bwText.write(String.valueOf(wid)+ \" \");\r\n\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t \t\r\n\t\t\t\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t \t}\r\n\t\t\t \t }\r\n\t\t\t }\r\n\t\t\tCollections.sort(textList);\r\n\t\t \r\n\t\t\tString text2 = valueFromList(textList);\r\n\t\t bwText.write(text2);\r\n\t\t //System.out.println(text2);\r\n\t\t bwText.newLine();\r\n\t\t textList.clear();\r\n\t\t \r\n\t \t}\r\n\t \tbwText.close();\r\n\t fwText.close();\r\n\t}",
"private void tbsOpenFile(){\n String path = Environment.getExternalStorageDirectory().getPath() + \"/\" + \"android面试题及答案.docx\";\n File file=new File(path);\n if (file.exists()){\n\n\n Bundle bundle=new Bundle();\n bundle.putString(\"filePath\", file.getPath());\n bundle.putString(\"tempPath\", Environment.getExternalStorageDirectory().getPath());\n boolean result = mTbsReaderView.preOpen(\"doc\", false);//Word类型的是“doc” 、 PDF的类型是“pdf”\n\n mTbsReaderView.openFile(bundle);\n\n }else {\n Toast.makeText(this,\"文件不存在\",Toast.LENGTH_SHORT).show();\n }\n\n }",
"public abstract WordAudioDocument convertToAudioDocument(TextDocument doc) throws IOException;",
"public void read() {\n\t\tSystem.out.println(\"word document\");\r\n\t}",
"public boolean writeWordFile() throws Exception {\n\n InputStream is = null;\n FileOutputStream fos = null;\n\n // 1 Cannot find source file, return false\n File inputFile = new File(this.inputPath);\n if (!inputFile.exists()) {\n return false;\n }\n\n File outputFile = new File(this.outputPath);\n // 2 If the target path does not exist, create a new path\n if (!outputFile.getParentFile().exists()) {\n outputFile.getParentFile().mkdirs();\n }\n\n try {\n\n // 3 Write html file content to doc file\n is = new FileInputStream(inputFile);\n POIFSFileSystem poifs = new POIFSFileSystem();\n DirectoryEntry directory = poifs.getRoot();\n directory.createDocument(\n \"WordDocument\", is);\n\n fos = new FileOutputStream(this.outputPath);\n poifs.writeFilesystem(fos);\n\n System.out.println(\"Conversion of word files is complete!\");\n\n return true;\n } catch (IOException e) {\n e.printStackTrace();\n } finally {\n if (fos != null) {\n fos.close();\n }\n if (is != null) {\n is.close();\n }\n }\n\n return false;\n }",
"public static void readDatafiles() throws FileNotFoundException {\n int docNumber = 0;\n\n while(docNumber<totaldocument) { // loop will run until all 0 - 55 speech data is read\n String tempBuffer = \"\";\n\n Scanner sc_obj = new Scanner(new File(\"./inputFiles/speech_\"+docNumber+\".txt\"));\n sc_obj.nextLine(); //skip the first line of every document\n\n while(sc_obj.hasNext()) {\n tempBuffer = sc_obj.next();\n tempBuffer = tempBuffer.replaceAll(\"[^a-zA-Z]+\",\" \");\n\n String[] wordTerm = tempBuffer.split(\" |//.\"); // the read data will convert into single word from whole stream of characters\n // it will split according to white spaces . - , like special characters\n\n for (int i=0; i < wordTerm.length; i++) {\n\n String term = wordTerm[i].toLowerCase();\t\t//each splitted word will be converted into lower case\n term = RemoveSpecialCharacter(term);\t\t\t// it will remove all the characters apart from the english letters\n term = removeStopWords(term);\t\t\t\t\t// it will remove the stopWords and final version of the term in the form of tokens will form\n\n if(!term.equalsIgnoreCase(\"\") && term.length()>1) {\n term = Lemmatize(term);\t\t\t\t\t//all the words in the form of tokens will be lemmatized\n //increment frequency of word if it is already present in dictionary\n if(dictionary.containsKey(term)) {\t\t//all the lemmatized words will be placed in HashMap dictionary\n List<Integer> presentList = dictionary.get(term);\n int wordFrequency = presentList.get(docNumber);\n wordFrequency++;\n presentList.set(docNumber, wordFrequency);\t\t//frequency of all the lemmatized words in dictionary is maintained \t\t\t\t\t\t\t\t\t//i.e: Word <2.0,1.0,3.0,0.0 ...> here hashmap<String,List<Double> is used\n }\t\t\t\t\t\t\t\t\t\t//the 0th index shows the word appared 2 times in doc 0 and 1 times in doc 1 and so forth..\n else { // if word was not in the dictionary then it will be added\n // if word was found in 5 doc so from 0 to 4 index representing doc 0 to doc 4 (0.0) will be placed\n List<Integer>newList = new ArrayList<>();\n for(int j=0; j<57; j++) {\n if(j != docNumber)\n newList.add(0);\n else\n newList.add(1);\n }\n dictionary.put(term, newList);\n }\n }\n }\n\n }\n docNumber++;\n }\n }",
"public void readDocument() throws FileNotFoundException{\r\n\t\t// Initialize 2 empty read document collections, one without duplicate words.\r\n\t\treadDocument = new LinkedBag<String>();\r\n\t\treadDocumentNoDuplicates = new LinkedSet<String>();\r\n\t\t\r\n\t\t// Prompt user for name of read document file.\r\n\t\tScanner input = new Scanner(System.in);\r\n\t\tSystem.out.print(\"Enter the file you would like checked with extension: \");\r\n\t\tString readDocFileName = input.nextLine();\r\n\t\t\r\n\t\t// If exists, open file specified by user. Then add words to both collections.\r\n\t\ttry {\r\n\t\t\tFile file = new File(readDocFileName);\r\n\t\t\tScanner scanner = new Scanner(file);\r\n\t\t\twhile (scanner.hasNextLine()) {\r\n\t\t\t\tString word = scanner.next();\r\n\t\t\t\treadDocument.add(word.replaceFirst(\"^[^a-zA-Z]+\",\"\").replaceAll(\"[^a-zA-Z]+$\", \"\"));\r\n\t\t\t\treadDocumentNoDuplicates.add(word.replaceFirst(\"^[^a-zA-Z]+\",\"\").replaceAll(\"[^a-zA-Z]+$\", \"\"));\r\n\t\t\t}\r\n\t\t\tscanner.close();\r\n\t\t\tSystem.out.println(\"Document read\");\r\n\r\n\t\t\t// Get initial list of incorrect words.\r\n\t\t\tincorrectWords = readDocumentNoDuplicates.difference(dictionary);\r\n\t\t\t\r\n\t\t\t// Display message showing how many words were in the read document.\r\n\t\t\tSystem.out.println(\"This document contains \" + readDocument.size() + \" words.\");\r\n\t\t}\r\n\t\tcatch (FileNotFoundException e) {\r\n\t\t\treadDocument = null;\r\n\t\t\treadDocumentNoDuplicates = null;\r\n\t\t\tSystem.out.println(\"Error: File '\" + readDocFileName + \"' not found. Please try again.\");\r\n\t\t}\r\n\t}",
"@Override\n public String getDescription() {\n return \"Text documents (*.xml)\";\n }",
"public void generateWordDocument(String directory, String nameOfTheDocument) throws Exception{\n\t\t\n\t\t//Create empty document (instance of Document classe from Apose.Words)\n\t\tDocument doc = new Document();\n\t\t\n\t\t//Every word document have section, so now we are creating section\n\t\tSection section = new Section(doc);\n\t\tdoc.appendChild(section);\n\t\t\n\t\tsection.getPageSetup().setPaperSize(PaperSize.A4);\n\t\tsection.getPageSetup().setHeaderDistance (35.4); // 1.25 cm\n\t\tsection.getPageSetup().setFooterDistance (35.4); // 1.25 cm\n\t\t\n\t\t//Crating the body of section\n\t\tBody body = new Body(doc);\n\t\tsection.appendChild(body);\n\t\t\n\t\t//Crating paragraph\n\t\tParagraph paragraph = new Paragraph(doc);\n\t\t\n\t\tparagraph.getParagraphFormat().setStyleName(\"Heading 1\");\n\t\tparagraph.getParagraphFormat().setAlignment(ParagraphAlignment.CENTER);\n\t\t//Crating styles\n\t\tStyle style = doc.getStyles().add(StyleType.PARAGRAPH, \"Style1\");\n\t\tstyle.getFont().setSize(24);\n\t\tstyle.getFont().setBold(true);\n\t\tstyle.getFont().setColor(Color.RED);\n\t\t//paragraph.getParagraphFormat().setStyle(style);\n\t\tbody.appendChild(paragraph);\n\t\t\n\t\tStyle styleForIntroduction = doc.getStyles().add(StyleType.PARAGRAPH, \"Style2\");\n\t\tstyle.getFont().setSize(40);\n\t\tstyle.getFont().setBold(false);\n\t\tstyle.getFont().setItalic(true);\n\t\tstyle.getFont().setColor(Color.CYAN);\n\t\t\n\t\tStyle styleForText = doc.getStyles().add(StyleType.PARAGRAPH, \"Style3\");\n\t\tstyle.getFont().setSize(15);\n\t\tstyle.getFont().setBold(false);\n\t\tstyle.getFont().setItalic(false);\n\t\tstyle.getFont().setColor(Color.BLACK);\n\t\t\n\t\t//Crating run of text\n\t\tRun textRunHeadin1 = new Run(doc);\n\t\ttry {\n\t\t\ttextRunHeadin1.setText(\"Probni test fajl\" + \"\\r\\r\");\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\tparagraph.appendChild(textRunHeadin1);\n\t\t\n\t\t\n\t\t//Creating paragraph1 for every question in list\n\t\tfor (Question question : questions) {\n\t\t\t\n\t\t\t\n\t\t\t\t//Paragraph for Instruction Question\n\t\t\t\tParagraph paragraphForInstruction = new Paragraph(doc);\n\t\t\t\tparagraphForInstruction.getParagraphFormat().setStyleName(\"Heading 1\");\n\t\t\t\tparagraphForInstruction.getParagraphFormat().setAlignment(ParagraphAlignment.LEFT);\n\t\t\t\tparagraphForInstruction.getParagraphFormat().setStyle(styleForIntroduction);\n\t\t\t\tparagraphForInstruction.getParagraphFormat().setStyleName(\"Heading 3\");\n\t\t\t\t\n\t\t\t\tRun runIntroduction = new Run(doc);\n\t\t\t\t\n\t\t\t\trunIntroduction.getFont().setColor(Color.BLUE);\n\t\t\t\ttry {\n\t\t\t\t\trunIntroduction.setText(((Question)question).getTextInstructionForQuestion()+\"\\r\");\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\tparagraphForInstruction.appendChild(runIntroduction);\n\t\t\t\tbody.appendChild(paragraphForInstruction);\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t//Paragraph for Question\n\t\t\t\tParagraph paragraphForQuestion = new Paragraph(doc);\n\t\t\t\tparagraphForQuestion.getParagraphFormat().setStyleName(\"Heading 1\");\n\t\t\t\tparagraphForQuestion.getParagraphFormat().setAlignment(ParagraphAlignment.LEFT);\n\t\t\t\tparagraphForQuestion.getParagraphFormat().setStyle(styleForText);\n\t\t\t\tparagraphForQuestion.getParagraphFormat().setStyleName(\"Normal\");\n\t\t\t\t\n\t\t\t\tRun runText = new Run(doc);\n\t\t\t\tif(question instanceof QuestionBasic){\n\t\t\t\t\t\n\t\t\t\t\ttry {\n\t\t\t\t\t\trunText.setText(((QuestionBasic)question).toStringForDocument()+\"\\r\");\n\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\t\n\t\t\t\t\n\t\t\t\tif(question instanceof QuestionFillTheBlank){\n\t\t\t\t\t\n\t\t\t\t\ttry {\n\t\t\t\t\t\trunText.setText(((QuestionFillTheBlank)question).toStringForDocument());\n\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\t\n\t\t\t\t\n\t\t\t\tif(question instanceof QuestionMatching){\n\t\t\t\t\t\n\t\t\t\t\ttry {\n\t\t\t\t\t\trunText.setText(((QuestionMatching)question).toStringForDocument());\n\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\t\n\t\t\t\t\n\t\t\t\tif(question instanceof QuestionTrueOrFalse){\n\t\t\t\t\t\n\t\t\t\t\ttry {\n\t\t\t\t\t\trunText.setText(((QuestionTrueOrFalse)question).toStringForDocument());\n\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\t\n\t\t\t\t\n\t\t\t\tparagraphForQuestion.appendChild(runText);\n\t\t\t\tbody.appendChild(paragraphForQuestion);\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\tdoc.save(directory + nameOfTheDocument +\".doc\");\n\t}",
"public interface WordService {\n boolean updateFile(String keyword,String FileId);\n String selectFile(String keyword);\n boolean saveFile(String keyword,String fileId);\n\n}",
"private void handleDocument(String name,InputStream ins)\n{\n Map<String,Integer> words = new HashMap<>();\n Map<String,Integer> kgrams = new HashMap<>();\n \n try {\n String cnts = IvyFile.loadFile(ins);\n CompilationUnit cu = JcompAst.parseSourceFile(cnts);\n words = handleDocumentText(cnts);\n kgrams = buildKgramCounts(cnts,cu);\n }\n catch (IOException e) {\n IvyLog.logI(\"Problem reading document file \" + name + \": \" + e);\n }\n \n if (words.size() > 0) {\n ++total_documents;\n for (String s : words.keySet()) {\n Integer v = document_counts.get(s);\n if (v == null) document_counts.put(s,1);\n else document_counts.put(s,v+1);\n }\n }\n if (kgrams.size() > 0) {\n ++total_kdocuments;\n for (String s : kgrams.keySet()) {\n Integer v = kgram_counts.get(s);\n if (v == null) kgram_counts.put(s,1);\n else kgram_counts.put(s,v+1);\n }\n }\n}",
"@Override\r\n\tpublic void handleFile(String inFilename, String outFilename) \r\n\t{\n\r\n\r\n\t\tString s = slurpFile(inFilename);\r\n\t\tDocument teiDocument = parsePlainText(s);\r\n\t\ttry \r\n\t\t{\r\n\t\t\tPrintStream pout = new PrintStream(new FileOutputStream(outFilename));\r\n\t\t\tpout.print(XML.documentToString(teiDocument));\r\n\t\t\tpout.close();\r\n\t\t} catch (FileNotFoundException e) \r\n\t\t{\r\n\t\t\te.printStackTrace\r\n\t\t\t();\r\n\r\n\t\t}\t\r\n\t}",
"public void IndexADocument(String docno, String content) throws IOException {\n\t\tdocid++;\n\t\tdoc2docid.put(docno, docid);\n\t\tdocid2doc.put(docid, docno);\n\n\t\t// Insert every term in this doc into docid2map\n\t\tString[] terms = content.trim().split(\" \");\n\t\tMap<Integer, Integer> docTerm = new HashMap<>();\n\t\tint thisTermid;\n\t\tfor(String term: terms){\n\t\t\t// get termid\n\t\t\tif(term2termid.get(term)!=null) thisTermid = term2termid.get(term);\n\t\t\telse{\n\t\t\t\tthisTermid = ++termid;\n\t\t\t\tterm2termid.put(term, thisTermid);\n\t\t\t}\n\t\t\tdocTerm.put(thisTermid, docTerm.getOrDefault(thisTermid, 0)+1);\n\t\t\t// Merge this term's information into termid2map\n\t\t\tMap<Integer, Integer> temp = termid2map.getOrDefault(thisTermid, new HashMap());\n\t\t\ttemp.put(docid, temp.getOrDefault(docid, 0)+1);\n\t\t\ttermid2map.put(thisTermid, temp);\n\t\t\ttermid2fre.put(thisTermid, termid2fre.getOrDefault(thisTermid, 0)+1);\n\t\t}\n\t\tdocid2map.put(docid, docTerm);\n\n//\t\t// Merge all the terms' information into termid2map\n//\t\tfor(Long tid: docTerm.keySet()){\n//\t\t\tMap<Long, Long> temp = termid2map.getOrDefault(tid, new HashMap());\n//\t\t\ttemp.put(docid,docTerm.get(tid));\n//\t\t\ttermid2map.put(tid, temp);\n//\t\t\t// update this term's frequency\n//\t\t\ttermid2fre.put(tid, termid2fre.getOrDefault(tid,0L)+docTerm.get(tid));\n//\t\t}\n\n\t\t// When termid2map and docid2map is big enough, put it into disk\n\t\tif(docid%blockSize==0){\n\t\t\tWritePostingFile();\n\t\t\tWriteDocFile();\n\t\t}\n\t}",
"public static void main(String[] args) throws Exception \n\t{\n\t\tList<String> stopWords = new ArrayList<String>();\n\t\tstopWords = stopWordsCreation();\n\n\n\t\t\n\t\tHashMap<Integer, String> hmap = new HashMap<Integer, String>();\t//Used in tittle, all terms are unique, and any dups become \" \"\n\t\n\t\t\n\t\tList<String> uniqueTerms = new ArrayList<String>();\n\t\tList<String> allTerms = new ArrayList<String>();\n\t\t\t\t\n\t\t\n\t\tHashMap<Integer, String> hmap2 = new HashMap<Integer, String>();\n\t\tHashMap<Integer, String> allValues = new HashMap<Integer, String>();\n\t\tHashMap<Integer, Double> docNorms = new HashMap<Integer, Double>();\n\t\t\n\t\t\n\t\t\n\t\t\n\t\tMap<Integer, List<String>> postingsFileListAllWords = new HashMap<>();\t\t\n\t\tMap<Integer, List<String>> postingsFileList = new HashMap<>();\n\t\t\n\t\tMap<Integer, List<StringBuilder>> docAndTitles = new HashMap<>();\n\t\tMap<Integer, List<StringBuilder>> docAndAbstract = new HashMap<>();\n\t\tMap<Integer, List<StringBuilder>> docAndAuthors = new HashMap<>();\n\t\t\n\t\t\n\t\tMap<Integer, List<Double>> termWeights = new HashMap<>();\n\t\t\n\t\tList<Integer> docTermCountList = new ArrayList<Integer>();\n\t\t\n\t\tBufferedReader br = null;\n\t\tFileReader fr = null;\n\t\tString sCurrentLine;\n\n\t\tint documentCount = 0;\n\t\tint documentFound = 0;\n\t\tint articleNew = 0;\n\t\tint docTermCount = 0;\n\t\t\n\t\t\n\t\tboolean abstractReached = false;\n\n\t\ttry {\n\t\t\tfr = new FileReader(FILENAME);\n\t\t\tbr = new BufferedReader(fr);\n\n\t\t\t// Continues to get 1 line from document until it reaches the end of EVERY doc\n\t\t\twhile ((sCurrentLine = br.readLine()) != null) \n\t\t\t{\n\t\t\t\t// sCurrentLine now contains the 1 line from the document\n\n\t\t\t\t// Take line and split each word and place them into array\n\t\t\t\tString[] arr = sCurrentLine.split(\" \");\n\n\n\t\t\t\t//Go through the entire array\n\t\t\t\tfor (String ss : arr) \n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t\t/*\n\t\t\t\t\t * This section takes the array and checks to see if it has reached a new\n\t\t\t\t\t * document or not. If the current line begins with an .I, then it knows that a\n\t\t\t\t\t * document has just started. If it incounters another .I, then it knows that a\n\t\t\t\t\t * new document has started.\n\t\t\t\t\t */\n\t\t\t\t\t//System.out.println(\"Before anything: \"+sCurrentLine);\n\t\t\t\t\tif (arr[0].equals(\".I\")) \n\t\t\t\t\t{\t\t\t\t\t\t\n\t\t\t\t\t\tif (articleNew == 0) \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tarticleNew = 1;\n\t\t\t\t\t\t\tdocumentFound = Integer.parseInt(arr[1]);\n\t\t\t\t\t\t} \n\t\t\t\t\t\telse if (articleNew == 1) \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tarticleNew = 0;\n\t\t\t\t\t\t\tdocumentFound = Integer.parseInt(arr[1]);\n\t\t\t\t\t\t}\t\t\t\n\t\t\t\t\t\t//System.out.println(documentFound);\n\t\t\t\t\t\t//count++;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t/* This section detects that after a document has entered,\n\t\t\t\t\t * it has to gather all the words contained in the title \n\t\t\t\t\t * section.\n\t\t\t\t\t */\n\t\t\t\t\tif (arr[0].equals(\".T\") ) \n\t\t\t\t\t{\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t// Go to line UNDER .T since that is where tittle is located\n\t\t\t\t\t\t//sCurrentLine = br.readLine();\n\t\t\t\t\t\tdocAndTitles.put(documentFound, new ArrayList<StringBuilder>());\n\t\t\t\t\t\t//System.out.println(\"docAndTitles.get(documentCount+1): \" +docAndTitles.get(documentFound));\n\t\t\t\t\t\t//System.out.println(\"Docs and titles: \"+docAndTitles);\n\t\t\t\t\t\tStringBuilder title = new StringBuilder();\n\t\t\t\t\t\t\n\t\t\t\t\t\twhile ( !(sCurrentLine = br.readLine()).matches(\".B|.A|.N|.X|.K|.C\") )\n\t\t\t\t\t\t{\t\t\t\t\n\t\t\t\t\t\t\t/* In this section, there are 2 lists being made. One list\n\t\t\t\t\t\t\t * is for all the unique words in every title in the document (hmap).\n\t\t\t\t\t\t\t * Hmap contains all unique words, and anytime a duplicate word is \n\t\t\t\t\t\t\t * found, it is replaced with an empty space in the map.\n\t\t\t\t\t\t\t * All Values \n\t\t\t\t\t\t\t * \n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//postingsFileList.put(documentFound - 1, new ArrayList<String>());\n\t\t\t\t\t\t\t//postingsFileList.get(documentFound - 1).add(term2);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//System.out.println(\"current line: \"+sCurrentLine);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tString[] tittle = sCurrentLine.split(\" \");\n\t\t\t\t\t\t\tif (tittle[0].equals(\".W\") )\n\t\t\t\t\t\t\t{\t\t\n\t\t\t\t\t\t\t\tabstractReached = true;\n\t\t\t\t\t\t\t\tbreak;\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttitle.append(sCurrentLine);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfor (String tittleWords : tittle)\n\t\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\ttittleWords = tittleWords.toLowerCase();\n\t\t\t\t\t\t\t\ttittleWords = tittleWords.replaceAll(\"[-&^%'{}*|$+\\\\/\\\\?!<>=.,;_:()\\\\[\\\\]\\\"\\\\d]\", \"\");\n\t\t\t\t\t\t\t\ttittleWords = tittleWords.replaceAll(\"[-&^%'*{}|$+\\\\/\\\\?!<>=.,;_:()\\\\[\\\\]\\\"\\\\d]\", \"\");\n\t\t\t\t\t\t\t\ttittleWords = tittleWords.replaceAll(\"[-&^%'{}*|$+\\\\/\\\\?!<>=.,;_:()\\\\[\\\\]\\\"\\\\d]\", \"\");\n\t\t\t\t\t\t\t\t//System.out.println(tittleWords);\n\t\t\t\t\t\t\t\tif (hmap.containsValue(tittleWords)) \n\t\t\t\t\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\thmap.put(documentCount, \" \");\n\t\t\t\t\t\t\t\t\tallValues.put(documentCount, tittleWords);\n\t\t\t\t\t\t\t\t\tallTerms.add(tittleWords);\n\t\t\t\t\t\t\t\t\tdocumentCount++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tallTerms.add(tittleWords);\n\t\t\t\t\t\t\t\t\tallValues.put(documentCount, tittleWords);\n\t\t\t\t\t\t\t\t\thmap.put(documentCount, tittleWords);\n\t\t\t\t\t\t\t\t\tif (!(uniqueTerms.contains(tittleWords)))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif ((stopWordsSetting && !(stopWords.contains(tittleWords))))\n\t\t\t\t\t\t\t\t\t\t\tuniqueTerms.add(tittleWords);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tdocumentCount++;\n\t\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//docAndTitles.get(documentCount).add(\" \");\n\t\t\t\t\t\t\ttitle.append(\"\\n\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//System.out.println(\"Title: \"+title);\n\t\t\t\t\t\t//System.out.println(\"docAndTitles.get(documentCount+1): \" +docAndTitles.get(documentFound));\n\t\t\t\t\t\tdocAndTitles.get(documentFound).add(title);\n\t\t\t\t\t\t//System.out.println(\"Done!: \"+ docAndTitles);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tif (arr[0].equals(\".A\") ) \n\t\t\t\t\t{\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t// Go to line UNDER .T since that is where tittle is located\n\t\t\t\t\t\t//sCurrentLine = br.readLine();\n\t\t\t\t\t\tdocAndAuthors.put(documentFound, new ArrayList<StringBuilder>());\n\t\t\t\t\t\t//System.out.println(\"docAndTitles.get(documentCount+1): \" +docAndTitles.get(documentFound));\n\t\t\t\t\t\t//System.out.println(\"Docs and titles: \"+docAndTitles);\n\t\t\t\t\t\tStringBuilder author = new StringBuilder();\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\twhile ( !(sCurrentLine = br.readLine()).matches(\".N|.X|.K|.C\") )\n\t\t\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t/* In this section, there are 2 lists being made. One list\n\t\t\t\t\t\t\t * is for all the unique words in every title in the document (hmap).\n\t\t\t\t\t\t\t * Hmap contains all unique words, and anytime a duplicate word is \n\t\t\t\t\t\t\t * found, it is replaced with an empty space in the map.\n\t\t\t\t\t\t\t * All Values \n\t\t\t\t\t\t\t * \n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//postingsFileList.put(documentFound - 1, new ArrayList<String>());\n\t\t\t\t\t\t\t//postingsFileList.get(documentFound - 1).add(term2);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//System.out.println(\"current line: \"+sCurrentLine);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tString[] tittle = sCurrentLine.split(\" \");\n\t\t\t\t\t\t\tif (tittle[0].equals(\".W\") )\n\t\t\t\t\t\t\t{\t\t\n\t\t\t\t\t\t\t\tabstractReached = true;\n\t\t\t\t\t\t\t\tbreak;\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tauthor.append(sCurrentLine);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//docAndTitles.get(documentCount).add(\" \");\n\t\t\t\t\t\t\tauthor.append(\"\\n\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//System.out.println(\"Title: \"+title);\n\t\t\t\t\t\t//System.out.println(\"docAndTitles.get(documentCount+1): \" +docAndTitles.get(documentFound));\n\t\t\t\t\t\tdocAndAuthors.get(documentFound).add(author);\n\t\t\t\t\t\t//System.out.println(\"Done!: \"+ docAndTitles);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t/* Since there may or may not be an asbtract after\n\t\t\t\t\t * the title, we need to check what the next section\n\t\t\t\t\t * is. We know that every doc has a publication date,\n\t\t\t\t\t * so it can end there, but if there is no abstract,\n\t\t\t\t\t * then it will keep scanning until it reaches the publication\n\t\t\t\t\t * date. If abstract is empty (in tests), it will also finish instantly\n\t\t\t\t\t * since it's blank and goes straight to .B (the publishing date).\n\t\t\t\t\t * Works EXACTLY like Title \t\t \n\t\t\t\t\t */\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tif (abstractReached) \n\t\t\t\t\t{\t\n\t\t\t\t\t\t//System.out.println(\"\\n\");\n\t\t\t\t\t\t//System.out.println(\"REACHED ABSTRACT and current line is: \" +sCurrentLine);\n\t\t\t\t\t\tdocAndAbstract.put(documentFound, new ArrayList<StringBuilder>());\n\t\t\t\t\t\tStringBuilder totalAbstract = new StringBuilder();\n\t\t\t\t\t\t\n\t\t\t\t\t\twhile ( !(sCurrentLine = br.readLine()).matches(\".T|.I|.A|.N|.X|.K|.C\") )\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\tString[] abstaract = sCurrentLine.split(\" \");\n\t\t\t\t\t\t\tif (abstaract[0].equals(\".B\") )\n\t\t\t\t\t\t\t{\t\t\t\n\t\t\t\t\t\t\t\tabstractReached = false;\n\t\t\t\t\t\t\t\tbreak;\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\ttotalAbstract.append(sCurrentLine);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tString[] misc = sCurrentLine.split(\" \");\n\t\t\t\t\t\t\tfor (String miscWords : misc) \n\t\t\t\t\t\t\t{\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tmiscWords = miscWords.toLowerCase(); \n\t\t\t\t\t\t\t\tmiscWords = miscWords.replaceAll(\"[-&^%'*$+|{}?!\\\\/<\\\\>=.,;_:()\\\\[\\\\]\\\"\\\\d]\", \"\");\n\t\t\t\t\t\t\t\tmiscWords = miscWords.replaceAll(\"[-&^%'*$+|?{}!\\\\/<\\\\>=.,;_:()\\\\[\\\\]\\\"\\\\d]\", \"\");\t\t\n\t\t\t\t\t\t\t\tmiscWords = miscWords.replaceAll(\"[-&^%'*$+|{}?!\\\\/<\\\\>=.,;_:()\\\\[\\\\]\\\"\\\\d]\", \"\");\t\t\n\t\t\t\t\t\t\t\t//System.out.println(miscWords);\n\t\t\t\t\t\t\t\tif (hmap.containsValue(miscWords)) \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\thmap.put(documentCount, \" \");\n\t\t\t\t\t\t\t\t\tallValues.put(documentCount, miscWords);\n\t\t\t\t\t\t\t\t\tallTerms.add(miscWords);\n\t\t\t\t\t\t\t\t\tdocumentCount++;\n\t\n\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t\telse \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tallTerms.add(miscWords);\n\t\t\t\t\t\t\t\t\thmap.put(documentCount, miscWords);\n\t\t\t\t\t\t\t\t\tallValues.put(documentCount, miscWords);\n\t\t\t\t\t\t\t\t\tif (!(uniqueTerms.contains(miscWords)))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif ((stopWordsSetting && !(stopWords.contains(miscWords))))\n\t\t\t\t\t\t\t\t\t\t\tuniqueTerms.add(miscWords);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tdocumentCount++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\t\n\t\t\t\t\t\t\ttotalAbstract.append(\"\\n\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\tdocAndAbstract.get(documentFound).add(totalAbstract);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t}\t\n\t\t\t\t\n\t\t\t\t//Once article is found, we enter all of of it's title and abstract terms \n\t\t\t\tif (articleNew == 0) \n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t\tdocumentFound = documentFound - 1;\n\t\t\t\t\t//System.out.println(\"Words found in Doc: \" + documentFound);\n\t\t\t\t\t//System.out.println(\"Map is\" +allValues);\n\t\t\t\t\tSet set = hmap.entrySet();\n\t\t\t\t\tIterator iterator = set.iterator();\n\n\t\t\t\t\tSet set2 = allValues.entrySet();\n\t\t\t\t\tIterator iterator2 = set2.iterator();\n\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tpostingsFileList.put(documentFound - 1, new ArrayList<String>());\n\t\t\t\t\tpostingsFileListAllWords.put(documentFound - 1, new ArrayList<String>());\n\t\t\t\t\twhile (iterator.hasNext()) {\n\t\t\t\t\t\tMap.Entry mentry = (Map.Entry) iterator.next();\n\t\t\t\t\t\t// (\"key is: \"+ mentry.getKey() + \" & Value is: \" + mentry.getValue());\n\t\t\t\t\t\t// (\"Value is: \" + mentry.getValue());\n\t\t\t\t\t\t// );\n\t\t\t\t\t\tString term = mentry.getValue().toString();\n\t\t\t\t\t\t// //\"This is going to be put in doc3: \"+ (documentFound-1));\n\t\t\t\t\t\tpostingsFileList.get(documentFound - 1).add(term);\n\t\t\t\t\t\t// if ( !((mentry.getValue()).equals(\" \")) )\n\t\t\t\t\t\tdocTermCount++;\n\t\t\t\t\t}\n\t\t\t\t\t// \"BEFORE its put in, this is what it looks like\" + hmap);\n\t\t\t\t\thmap2.putAll(hmap);\n\t\t\t\t\thmap.clear();\n\t\t\t\t\tarticleNew = 1;\n\n\t\t\t\t\tdocTermCountList.add(docTermCount);\n\t\t\t\t\tdocTermCount = 0;\n\n\t\t\t\t\twhile (iterator2.hasNext()) {\n\t\t\t\t\t\tMap.Entry mentry2 = (Map.Entry) iterator2.next();\n\t\t\t\t\t\t// (\"key is: \"+ mentry.getKey() + \" & Value is: \" + mentry.getValue());\n\t\t\t\t\t\t// (\"Value2 is: \" + mentry2.getValue());\n\t\t\t\t\t\t// );\n\t\t\t\t\t\tString term = mentry2.getValue().toString();\n\t\t\t\t\t\t// //\"This is going to be put in doc3: \"+ (documentFound-1));\n\t\t\t\t\t\tpostingsFileListAllWords.get(documentFound - 1).add(term);\n\t\t\t\t\t\t// if ( !((mentry.getValue()).equals(\" \")) )\n\t\t\t\t\t\t// docTermCount++;\n\t\t\t\t\t}\n\n\t\t\t\t\tallValues.clear();\t\t\t\t\t\n\t\t\t\t\tdocumentFound = Integer.parseInt(arr[1]);\n\n\t\t\t\t\t// \"MEANWHILE THESE ARE ALL VALUES\" + postingsFileListAllWords);\n\n\t\t\t\t}\t\t\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t//System.out.println(\"Looking at final doc!\");\n\t\t\t//Final loop for last sets\n\t\t\tSet set = hmap.entrySet();\n\t\t\tIterator iterator = set.iterator();\n\n\t\t\tSet setA = allValues.entrySet();\n\t\t\tIterator iteratorA = setA.iterator();\n\t\t\tpostingsFileList.put(documentFound - 1, new ArrayList<String>());\n\t\t\tpostingsFileListAllWords.put(documentFound - 1, new ArrayList<String>());\n\t\t\twhile (iterator.hasNext()) {\n\t\t\t\tMap.Entry mentry = (Map.Entry) iterator.next();\n\t\t\t\t// (\"key is: \"+ mentry.getKey() + \" & Value is: \" + mentry.getValue());\n\t\t\t\t// (\"Value is: \" + mentry.getValue());\n\t\t\t\t// //);\n\t\t\t\t// if ( !((mentry.getValue()).equals(\" \")) )\n\t\t\t\tString term2 = mentry.getValue().toString();\n\t\t\t\tpostingsFileList.get(documentFound - 1).add(term2);\n\n\t\t\t\tdocTermCount++;\n\t\t\t}\n\t\t\t//System.out.println(\"Done looking at final doc!\");\n\t\t\t\n\t\t\t\n\t\t\t//System.out.println(\"Sorting time!\");\n\t\t\twhile (iteratorA.hasNext()) {\n\t\t\t\tMap.Entry mentry2 = (Map.Entry) iteratorA.next();\n\t\t\t\t// (\"key is: \"+ mentry.getKey() + \" & Value is: \" + mentry.getValue());\n\t\t\t\t// (\"Value2 is: \" + mentry2.getValue());\n\t\t\t\t// //);\n\t\t\t\tString term = mentry2.getValue().toString();\n\t\t\t\t// //\"This is going to be put in doc3: \"+ (documentFound-1));\n\t\t\t\tpostingsFileListAllWords.get(documentFound - 1).add(term);\n\t\t\t\t// if ( !((mentry.getValue()).equals(\" \")) )\n\t\t\t\t// docTermCount++;\n\t\t\t}\n\n\t\t\thmap2.putAll(hmap);\n\t\t\thmap.clear();\n\t\t\tdocTermCountList.add(docTermCount);\n\t\t\tdocTermCount = 0;\n\n\n\t\t\t\n\t\t\n\t\t\t// END OF LOOKING AT ALL DOCS\n\t\t\t\n\t\t\t//System.out.println(\"Docs and titles: \"+docAndTitles);\n\t\t\t\n\t\t\t//System.out.println(\"All terms\" +allTerms);\n\t\t\tString[] sortedArray = allTerms.toArray(new String[0]);\n\t\t\tString[] sortedArrayUnique = uniqueTerms.toArray(new String[0]);\n\t\t\t//System.out.println(Arrays.toString(sortedArray));\n\t\t\t\n\t\t\tArrays.sort(sortedArray);\n\t\t\tArrays.sort(sortedArrayUnique);\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t//Sortings \n\t\t\tSet set3 = hmap2.entrySet();\n\t\t\tIterator iterator3 = set3.iterator();\n\n\t\t\t// Sorting the map\n\t\t\t//System.out.println(\"Before sorting \" +hmap2);\t\t\t\n\t\t\tMap<Integer, String> map = sortByValues(hmap2);\n\t\t\t//System.out.println(\"after sorting \" +map);\n\t\t\t// //\"After Sorting:\");\n\t\t\tSet set2 = map.entrySet();\n\t\t\tIterator iterator2 = set2.iterator();\n\t\t\tint docCount = 1;\n\t\t\twhile (iterator2.hasNext()) {\n\t\t\t\tMap.Entry me2 = (Map.Entry) iterator2.next();\n\t\t\t\t// (me2.getKey() + \": \");\n\t\t\t\t// //me2.getValue());\n\t\t\t}\n\t\t\t\n\t\t\t//System.out.println(\"Done sorting!\");\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t//System.out.println(\"Posting starts \");\n\t\t\t//\"THIS IS START OF DICTIONARTY\" \n\t\t\tBufferedWriter bw = null;\n\t\t\tFileWriter fw = null;\n\t\t\t\n\t\t\t\n\t\t\t//System.out.println(\"Start making an array thats big as every doc total \");\n\t\t\tfor (int z = 1; z < documentFound+1; z++)\n\t\t\t{\n\t\t\t\ttermWeights.put(z, new ArrayList<Double>());\n\t\t\t}\n\t\t\t//System.out.println(\"Done making that large array Doc \");\n\t\t\t\n\t\t\t//System.out.println(\"Current Weights: \"+termWeights);\n\t\t\t\n\t\t\t//System.out.println(\"All terms\" +allTerms)\n\t\t\t//System.out.println(Arrays.toString(sortedArray));\n\t\t\t//System.out.println(Arrays.toString(sortedArrayUnique));\n\t\t\t//System.out.println(uniqueTerms);\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t//\tSystem.out.println(\"Posting starts \");\n\t\t\t// \tPOSTING FILE STARTS \n\t\t\ttry {\n\t\t\t\t// Posting File\n\t\t\t\t//System.out.println(\"postingsFileListAllWords: \"+postingsFileListAllWords); //Contains every word including Dups, seperated per doc\n\t\t\t\t//System.out.println(\"postingsFileList: \"+postingsFileList); \t\t //Contains unique words, dups are \" \", seperated per doc\n\t\t\t\t//System.out.println(\"postingsFileListAllWords.size(): \" +postingsFileListAllWords.size()); //Total # of docs \n\t\t\t\t//System.out.println(\"Array size: \"+sortedArrayUnique.length);\n\n\t\t\t\tfw = new FileWriter(POSTING);\n\t\t\t\tbw = new BufferedWriter(fw);\n\t\t\t\tString temp = \" \";\n\t\t\t\tDouble termFreq = 0.0;\n\t\t\t\t// //postingsFileListAllWords);\n\t\t\t\tList<String> finalTermList = new ArrayList<String>();\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\t\t// //postingsFileList.get(i).size());\n\t\t\t\t\tfor (int j = 0; j < sortedArrayUnique.length; ++j)\t\t\t\t\t // go thru each word, CURRENT TERM\n\t\t\t\t\t{\n\t\t\t\t\t\t//System.out.println(\"Term is: \" + sortedArrayUnique[j]);\n\t\t\t\t\t\ttemp = sortedArrayUnique[j];\t\t\t\t\t\n\t\t\t\t\t\tif ((stopWordsSetting && stopWords.contains(temp))) \n\t\t\t\t\t\t{\t\t\t\t\t\t\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (!(finalTermList.contains(temp))) \n\t\t\t\t\t\t{\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//PART TO FIND DOCUMENT FREQ\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tint docCountIDF = 0;\n\t\t\t\t\t\t\t//Start here for dictionary \n\t\t\t\t\t\t\tfor (int totalWords = 0; totalWords < sortedArray.length; totalWords++) \t\t\n\t\t\t\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (temp.compareTo(\" \") == 0 || (stopWordsSetting && stopWords.contains(temp))) \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t//EITHER BLANK OR STOPWORD \n\t\t\t\t\t\t\t\t\t//System.out.println(\"fOUND STOP WORD\");\n\t\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tString temp2 = sortedArray[totalWords];\n\t\t\t\t\t\t\t\t\t//System.out.println(\"Compare: \"+temp+ \" with \" +temp2);\n\t\t\t\t\t\t\t\t\tif (temp.compareTo(temp2) == 0) {\n\t\t\t\t\t\t\t\t\t\t// (temp2+\" \");\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tdocCountIDF++;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//System.out.println(\"Total Number: \" +docCountIDF);\n\t\t\t\t\t\t\t//System.out.println(\"documentFound: \" +documentFound);\n\t\t\t\t\t\t\t//System.out.println(\"So its \" + documentFound + \" dividied by \" +docCountIDF);\n\t\t\t\t\t\t\t//docCountIDF = 1;\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tdouble idf = (Math.log10(((double)documentFound/(double)docCountIDF)));\n\t\t\t\t\t\t\t//System.out.println(\"Calculated IDF: \"+idf);\n\t\t\t\t\t\t\tif (idf < 0.0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tidf = 0.0;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//System.out.println(\"IDF is: \" +idf);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//System.out.println(\"Size of doc words: \" + postingsFileListAllWords.size());\n\t\t\t\t\t\t\tfor (int k = 0; k < postingsFileListAllWords.size(); k++) \t\t//Go thru each doc. Since only looking at 1 term, it does it once per doc\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t//System.out.println(\"Current Doc: \" +(k+1));\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\ttermFreq = 1 + (Math.log10(Collections.frequency(postingsFileListAllWords.get(k), temp)));\t\t\t\n\t\t\t\t\t\t\t\t\t//System.out.println(\"Freq is: \" +Collections.frequency(postingsFileListAllWords.get(k), temp));\n\t\t\t\t\t\t\t\t\t//System.out.println(termFreq + \": \" + termFreq.isInfinite());\n\t\t\t\t\t\t\t\t\tif (termFreq.isInfinite() || termFreq <= 0)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\ttermFreq = 0.0;\n\t\t\t\t\t\t\t\t\t}\t\t\t\t\n\t\t\t\t\t\t\t\t\t//System.out.println(\"termFreq :\" +termFreq); \n\t\t\t\t\t\t\t\t\t//System.out.println(\"idf: \" +idf);\n\t\t\t\t\t\t\t\t\ttermWeights.get(k+1).add( (idf*termFreq) );\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//System.out.println(\"\");\n\t\t\t\t\t\t\tfinalTermList.add(temp);\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\t\n\t\t\t\t\t\t//System.out.println(\"Current Weights: \"+termWeights);\n\t\t\t\t\t\t\n\t\t\t\t\t\t//FINALCOUNTER\n\t\t\t\t\t\t//System.out.println(\"Done looking at word: \" +j);\n\t\t\t\t\t\t//System.out.println(\"\");\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t//System.out.println(\"Current Weights: \"+termWeights);\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\twhile (true)\n\t\t\t\t {\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\tSystem.out.println(\"Enter a query: \");\n\t\t\t\t\t\n\t \tScanner scanner = new Scanner(System.in);\n\t \tString enterQuery = scanner.nextLine();\n\t \t\n\t \t\n\t\t\t\t\tList<Double> queryWeights = new ArrayList<Double>();\n\t\t\t\t\t\n\t\t\t\t\t// Query turn\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\tenterQuery = enterQuery.toLowerCase();\t\t\n\t\t\t\t\tenterQuery = enterQuery.replaceAll(\"[-&^%'*$+|{}?!\\\\/<\\\\>=.,;_:()\\\\[\\\\]\\\"]\", \"\");\n\t\t\t\t\t//System.out.println(\"Query is: \" + enterQuery);\n\t\t\t\t\t\n\t\t\t\t\tif (enterQuery.equals(\"exit\"))\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tString[] queryArray = enterQuery.split(\" \");\n\t\t\t\t\tArrays.sort(queryArray);\n\t\t\t\t\t\n\t\t\t\t\t//Find the query weights for each term in vocab\n\t\t\t\t\tfor (int j = 0; j < sortedArrayUnique.length; ++j)\t\t\t\t\t // go thru each word, CURRENT TERM\n\t\t\t\t\t{\n\t\t\t\t\t\t//System.out.println(\"Term is: \" + sortedArrayUnique[j]);\n\t\t\t\t\t\ttemp = sortedArrayUnique[j];\t\t\t\t\t\n\t\t\t\t\t\tif ((stopWordsSetting && stopWords.contains(temp))) \n\t\t\t\t\t\t{\t\t\t\t\t\t\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\tint docCountDF = 0;\n\t\t\t\t\t\t//Start here for dictionary \n\t\t\t\t\t\tfor (int totalWords = 0; totalWords < queryArray.length; totalWords++) \t\t\n\t\t\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (temp.compareTo(\" \") == 0 || (stopWordsSetting && stopWords.contains(temp))) \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t//EITHER BLANK OR STOPWORD\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tString temp2 = queryArray[totalWords];\n\t\t\t\t\t\t\t\t//System.out.println(\"Compare: \"+temp+ \" with \" +temp2);\n\t\t\t\t\t\t\t\tif (temp.compareTo(temp2) == 0) {\n\t\t\t\t\t\t\t\t\t// (temp2+\" \");\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tdocCountDF++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tDouble queryWeight = 1 + (Math.log10(docCountDF));\n\t\t\t\t\t\tif (queryWeight.isInfinite())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tqueryWeight = 0.0;\n\t\t\t\t\t\t}\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tqueryWeights.add(queryWeight);\n\t\t\t\t\t}\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t//System.out.println(\"Query WEights is: \"+queryWeights);\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t// Finding the norms for DOCS\t\t\t\t\t\n\t\t\t\t\tfor (int norms = 1; norms < documentFound+1; norms++)\n\t\t\t\t\t{\n\t\t\t\t\t\tdouble currentTotal = 0.0;\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (int weightsPerDoc = 0; weightsPerDoc < termWeights.get(norms).size(); weightsPerDoc++)\n\t\t\t\t\t\t{\t\t\t\t\t\t\n\t\t\t\t\t\t\tdouble square = Math.pow(termWeights.get(norms).get(weightsPerDoc), 2);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//System.out.println(\"Current square: \" + termWeights.get(norms).get(weightsPerDoc));\n\t\t\t\t\t\t\tcurrentTotal = currentTotal + square;\n\t\t\t\t\t\t\t//System.out.println(\"Current total: \" + currentTotal);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//System.out.println(\"About to square root this: \" +currentTotal);\n\t\t\t\t\t\tdouble root = Math.sqrt(currentTotal);\n\t\t\t\t\t\tdocNorms.put(norms, root);\n\t\t\t\t\t}\n\t\t\t\t\t//System.out.println(\"All of the docs norms: \"+docNorms);\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t//Finding the norm for the query\n\t\t\t\t\tdouble currentTotal = 0.0;\t\t\t\t\t\n\t\t\t\t\tfor (int weightsPerDoc = 0; weightsPerDoc < queryWeights.size(); weightsPerDoc++)\n\t\t\t\t\t{\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tdouble square = Math.pow(queryWeights.get(weightsPerDoc), 2);\n\t\t\t\t\t\tcurrentTotal = currentTotal + square;\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\tdouble root = Math.sqrt(currentTotal);\n\t\t\t\t\tdouble queryNorm = root; \t\t\t\t\t\t\n\t\t\t\t\t//System.out.println(\"Query norm \" + queryNorm);\n\t\t\t\t\t\n\t\t\t\t\t//Finding the cosine sim\n\t\t\t\t\t//System.out.println(\"Term Weights \" + termWeights);\n\t\t\t\t\tHashMap<Integer, Double> cosineScore = new HashMap<Integer, Double>();\n\t\t\t\t\tfor (int cosineSim = 1; cosineSim < documentFound+1; cosineSim++)\n\t\t\t\t\t{\n\t\t\t\t\t\tdouble total = 0.0;\n\t\t\t\t\t\tfor (int docTerms = 0; docTerms < termWeights.get(cosineSim).size(); docTerms++)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tdouble docTermWeight = termWeights.get(cosineSim).get(docTerms);\n\t\t\t\t\t\t\tdouble queryTermWeight = queryWeights.get(docTerms);\n\t\t\t\t\t\t\t//System.out.println(\"queryTermWeight \" + queryTermWeight);\n\t\t\t\t\t\t\t//System.out.println(\"docTermWeight \" + docTermWeight);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttotal = total + (docTermWeight*queryTermWeight);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\tdouble cosineSimScore = 0.0;\n\t\t\t\t\t\tif (!(total == 0.0 || (docNorms.get(cosineSim) * queryNorm) == 0))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcosineSimScore = total / (docNorms.get(cosineSim) * queryNorm);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcosineSimScore = 0.0;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tcosineScore.put(cosineSim, cosineSimScore);\n\t\t\t\t\t}\n\t\t\t\t\tcosineScore = sortByValues2(cosineScore);\t\t\t\t\t\n\t\t\t\t\t//System.out.println(\"This is the cosineScores: \" +cosineScore);\n\t\t\t\t\t\n\t\t\t\t\t//System.out.println(\"docAndTitles: \"+ docAndTitles);\n\t\t\t\t\tint topK = 0;\n\t\t\t\t\tint noValue = 0;\n\t\t\t\t\tfor (Integer name: cosineScore.keySet())\n\t\t\t\t\t{\n\t\t\t\t\t\tif (topK < 50)\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\t\n\t\t\t\t String key =name.toString();\n\t\t\t\t //String value = cosineScore.get(name).toString(); \n\t\t\t\t if (!(cosineScore.get(name) <= 0))\n\t\t\t\t {\n\t\t\t\t \tSystem.out.println(\"Doc: \"+key);\t\t\t\t \t\t\t\t\t \t\t\t\t\t \t\n\t\t\t\t \t\n\t\t\t\t \tStringBuilder builder = new StringBuilder();\n\t\t\t\t \tfor (StringBuilder value : docAndTitles.get(name)) {\n\t\t\t\t \t builder.append(value);\n\t\t\t\t \t}\n\t\t\t\t \tString text = builder.toString();\t\t\t\t \t\n\t\t\t\t \t//System.out.println(\"Title:\\n\" +docAndTitles.get(name));\n\t\t\t\t \tSystem.out.println(\"Title: \" +text);\n\t\t\t\t \t\n\t\t\t\t \t\n\t\t\t\t \t\n\t\t\t\t \t\n\t\t\t\t \t\n\t\t\t\t \t//System.out.println(\"Authors:\\n\" +docAndAuthors.get(name));\n\t\t\t\t \t\n\t\t\t\t \tif (docAndAuthors.get(name) == null || docAndAuthors.get(name).toString().equals(\"\"))\n\t\t\t\t \t{\n\t\t\t\t \t\tSystem.out.println(\"Authors: N\\\\A\\n\");\n\t\t\t\t \t}\n\t\t\t\t \telse \n\t\t\t\t \t{\t\t\t\t \t\t\t\t\t\t \t\n\t\t\t\t\t \tStringBuilder builder2 = new StringBuilder();\n\t\t\t\t\t \tfor (StringBuilder value : docAndAuthors.get(name)) {\n\t\t\t\t\t \t builder2.append(value);\n\t\t\t\t\t \t}\n\t\t\t\t\t \tString text2 = builder2.toString();\t\t\t\t \t\n\t\t\t\t\t \t\n\t\t\t\t\t \tSystem.out.println(\"Authors found: \" +text2);\n\t\t\t\t \t}\t\n\t\t\t\t \t\n\t\t\t\t \t\n\t\t\t\t \t/* ABSTRACT \n\t\t\t\t \tif (docAndAbstract.get(name) == null)\n\t\t\t\t \t{\n\t\t\t\t \t\tSystem.out.println(\"Abstract: N\\\\A\\n\");\n\t\t\t\t \t}\n\t\t\t\t \telse \n\t\t\t\t \t{\t\t\t\t \t\t\t\t\t\t \t\n\t\t\t\t\t \tStringBuilder builder2 = new StringBuilder();\n\t\t\t\t\t \tfor (StringBuilder value : docAndAbstract.get(name)) {\n\t\t\t\t\t \t builder2.append(value);\n\t\t\t\t\t \t}\n\t\t\t\t\t \tString text2 = builder2.toString();\t\t\t\t \t\n\t\t\t\t\t \t\n\t\t\t\t\t \tSystem.out.println(\"Abstract: \" +text2);\n\t\t\t\t \t}\t\n\t\t\t\t \t*/\n\t\t\t\t \t\n\t\t\t\t \tSystem.out.println(\"\");\n\t\t\t\t }\n\t\t\t\t else {\n\t\t\t\t \tnoValue++;\n\t\t\t\t }\n\t\t\t\t topK++;\n\t\t\t\t \n\t\t\t\t\t\t}\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (noValue == documentFound)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSystem.out.println(\"No documents contain query!\");\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t\ttopK=0;\n\t\t\t\t\tnoValue = 0;\n\t\t\t\t }\n\t\t\t\t\n\t\t\t} finally {\n\t\t\t\ttry {\n\t\t\t\t\tif (bw != null)\n\t\t\t\t\t\tbw.close();\n\n\t\t\t\t\tif (fw != null)\n\t\t\t\t\t\tfw.close();\n\n\t\t\t\t} catch (IOException ex) {\n\n\t\t\t\t\tex.printStackTrace();\n\n\t\t\t\t}\n\n\t\t\t}\n\t\t\t\n\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\tif (br != null)\n\t\t\t\t\tbr.close();\n\n\t\t\t\tif (fr != null)\n\t\t\t\t\tfr.close();\n\n\t\t\t} catch (IOException ex) {\n\n\t\t\t\tex.printStackTrace();\n\n\t\t\t}\n\n\t\t}\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\n\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\tint itemCount = uniqueTerms.size();\n\t\t\t//System.out.println(allValues);\n\t\t\tSystem.out.println(\"Total Terms BEFORE STEMING: \" +itemCount);\n\t\t\tSystem.out.println(\"Total Documents \" + documentFound);\n\t\t\t\t\t\t\n\t\t \n\t\t\t \n\t\t\t \n\t\t\t//END OF MAIN\n\t\t}",
"public static void main(String[] args) {\n PdfFile pdfFile=new PdfFile(\"PDF File\");\n pdfFile.open();\n pdfFile.close();\n pdfFile.edit();\n WordFile wordFile=new WordFile(\"Word File\");\n wordFile.open();\n wordFile.close();\n wordFile.edit();\n JavaFile javaFile=new JavaFile(\"Java File\");\n javaFile.open();\n javaFile.close();\n javaFile.edit();\n\n }",
"public void readFromFile(String doc) {\n\t\tString newline = \"\\n\";\n\t\tString doc_text = \"\";\n\t\tint count = 0;\n\t\tString line=\"\";\n\t\t\n\t\t//for random button\n\t\tint buttoncount = 0;\n\t\tArrayList<JButton> list = new ArrayList<JButton>();\n\t\t\n\t\ttry{\n\t\t\t//input stream for reading special characters in German\t\n\t\t\t//documents from folder textfiles\n \tBufferedReader rd = new BufferedReader(new InputStreamReader(new FileInputStream(\"textfiles/\" + doc),StandardCharsets.UTF_8));\n \twhile ((line=rd.readLine()) != null) {\n \t\t//question text\n \t\tif (count == 0) {\n \t\t\t\n \t\t\tswitch(bg) {\n \t\t\t\tcase(1):\n \t\t\t\tdoc_text = \"Dein Charakter lässt sich durch 4 Merkmale beschreiben.\\r\\n\" + \n \t\t\t\t\t\t\"Wähle als 1. dein Persönlichkeitsmerkmal:\" + newline;\n \t\t\t\t\tcount++;\n \t\t\t\tbreak;\n \t\t\tcase(2):\n \t\t\t\tdoc_text = \"Wähle das 2. Merkmal ein Ideal:\" + newline;\n \t\t\t\tcount++;\n \t\t\t\tbreak;\n \t\t\tcase(3):\n \t\t\t\tdoc_text = \"Entscheide dich als nächstes für eine Bindung:\"+ newline;\n \t\t\t\tcount++;\n \t\t\t\tbreak;\n \t\t\tcase(4):\n \t\t\t\tdoc_text = \"Deine letzte Frage. Im Anschluss wird dein Charakter generiert.\\r\\n\" + \n \t\t\t\t\t\t\"Wähle ein Makel der dich beschreibt:\"+ newline;\n \t\t\t\tcount++;\n \t\t\t\tbreak;\n \t\t\tdefault:\n \t\t\t\tdoc_text = doc_text + line + newline;\n \t\t\t\tbreak;\n \t\t\t}\n \t\t\ttxt.setText(doc_text);\n \t\t\tif(randomButton == true) {\n\t\t \t\ttxt.setVisible(false);\n \t\t\t\t}\n \t\t\tpanelA.add(txt);\n \t\t}\n \t\t\n \t\t//buttonname;next document(;information)\n \t\tif (count == 1) {\n \t\t\tString[] tokens = line.split(\";\");\n \t\t\tJButton button = new JButton (tokens[0]);\n \t\t\t\tbutton.setFont(new Font(\"Rockwell\", Font.PLAIN, 24));\n \t\t\t//for random button: add buttons to a list and count them\n \t\t\tlist.add(button);\n \t\t\tbuttoncount++;\n \t\t\t\tif(randomButton == true) {\n \t\t\t\t\tbutton.setVisible(false);\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\tpanelB.add(button);\n\t\t\t\t\tbutton.addActionListener( new ActionListener() {\n\t\t\t\t\t\tpublic void actionPerformed(ActionEvent ae) {\n\t\t\t\t\t\t\tif(ae.getSource() == button) {\n\t\t\t\t\t\t\t\tif (tokens.length == 1) {\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tclearPanel();\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//if race is already set but class not yet, than read question for class\n\t\t\t\t\t\t\t\t\tif(baseRace == true && baseClass == false) {\n \t\t\t\t\t\t\t\t\tspecific_race = tokens[0];\n \t\t\t\t\t\t\t\t\treadFromFile(\"/question_class/question_class_\" + attribute + \".txt\");\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//if race and class is already set -> open question for background\n\t\t\t\t\t\t\t\t\telse if(baseRace == true && baseClass == true) {\n\t\t\t \t\t\t\t\tspecific_class = tokens[0];\n \t\t\t\t\t\t\t\t\treadFromFile(\"question_backgrounds\" + \".txt\");\n\t\t\t \t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (tokens.length > 1) {\n\t\t\t\t\t\t\t\t\t//Buttonname/tokens[0];[tokens[1];tokens[2] \n\t\t\t\t\t\t\t\t\tif (tokens.length>2) {\n\t\t\t\t\t\t\t\t\t\tif (baseRace == false && baseClass == false) {\n\t\t\t \t\t\t\t\t\tbase_race.setRace(tokens[2]);\n\t\t\t \t\t\t\t\t\tbaseRace = true;\n\t\t\t \t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse if (baseRace == true && baseClass == false) {\n\t\t\t \t\t\t\t\t\tbase_class.setClass(tokens[2]);\n\t\t\t \t\t\t\t\t\tbaseClass = true;\n\n\t\t\t \t\t\t\t\t} \t\t\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//random button\n\t\t\t\t\t\t\t\t\tif (tokens[0].equals(\"Zufallscharakter erstellen\")) {\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\trandomButton = true;\n\t\t\t\t\t\t\t\t\t\tclearPanel();\n\t\t\t\t\t\t\t\t\t\treadFromFile(tokens[1] + \".txt\");\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//choose main attribute for race and class\n\t\t\t\t\t\t\t\t\telse if(doc.equals(\"question_1.txt\")) {\n\t\t\t \t\t\t\t\tString attribute_tokens [] = tokens[1].split(\"_\");\n\t\t\t \t\t\t\t\tattribute = attribute_tokens[3];\n\t\t\t \t\t\t\t\tclearPanel();\n\t\t\t\t\t\t\t\t\t\treadFromFile(tokens[1]+\".txt\");\t\n\t\t\t \t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//choose background personality\n\t\t\t\t\t\t\t\t\telse if(doc.equals(\"question_backgrounds.txt\")) {\n\t\t\t\t\t\t\t\t\t\tpersonality = tokens[1];\n\t\t\t \t \t\tbase_personality.setPersonality(tokens[0]);\n\t\t\t \t \t\tclearPanel();\n\t\t\t \t \t\tbg++;\n\t\t\t \t \t\treadFromFile(\"question_personalities/\" + personality + \"/question_personality_\" + personality + \".txt\");\n\t\t\t \t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//background\n\t\t\t\t\t\t\t\t\telse if (bg == 1) {\t\n\t\t\t\t\t\t\t\t\t\tbg++;\n\t \t\t\t\t\t\t\t\tbase_personality.setPersonalityTrait(tokens[1]);\n\t \t\t\t\t\t\t\t\tclearPanel();\n\t \t\t\t\t\t\t\t\treadFromFile(\"/question_personalities/\" + personality + \"/question_ideal_\" + personality + \".txt\");\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\telse if (bg == 2) {\n\t\t\t\t\t\t\t\t\t\tbg++;\n\t\t\t\t\t\t\t\t\t\tbase_personality.setIdeal(tokens[1]);\n\t\t\t\t\t\t\t\t\t\tclearPanel();\n\t \t\t \t\t\t\treadFromFile(\"/question_personalities/\" + personality + \"/question_bond_\" + personality + \".txt\");\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\telse if (bg == 3) {\t\n\t\t\t\t\t\t\t\t\t\tbg++;\n\t \t\t\t\t\t\t\t\tbase_personality.setBond(tokens[1]);\n\t \t\t\t\t\t\t\t\tclearPanel();\n\t \t\t \t\t\t\treadFromFile(\"/question_personalities/\" + personality + \"/question_flaw_\" + personality + \".txt\");\t \t\t \t\t\t \t\t\t\t\n\t\t\t\t \t\t\t} \t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\telse if (bg == 4) {\n\t\t\t\t\t\t\t\t\t\tbg = 0;\n\t \t\t\t\t\t\t\t\tbase_personality.setFlaw(tokens[1]);\n\t \t\t\t\t\t\t\t\tsetAttributes();\n\t \t\t \t\tshowResults();\n\t \t\t \t\t\n\t\t\t\t \t\t\t}\n\t\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t\tclearPanel();\n\t\t\t\t\t\t\t\t\t\treadFromFile(tokens[1]+\".txt\");\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t \t \t\t\t\t\n \t\t\t}); //actionlistener close \n \t\t\t\n \t\t} //if count == 1 end\n\n \t\t//empty line\n\t\t if (line.length() == 0) {\n\t\t \tcount++;\n\t\t \ttxt.setText(doc_text);\n\t\t \tif(randomButton == true) {\n\t\t \t\ttxt.setVisible(false);\n \t\t\t\t}\n\t\t \tpanelA.add(txt);\n\t\t }\n\t\t \n \t} // while end\n \t\n\t\t\t\n \trd.close();\n \t\n } //try\n\t\tcatch(Exception e){\n\t\t\te.printStackTrace();\n\t\t}\n\t\tsetFrameContent();\n\t\tif(randomButton == true) {\n\t\t\trandomInt = rdm.nextInt(buttoncount);\t\n\t\t\tlist.get(randomInt).doClick();\n\t\t}\n\t}",
"String prepareLegalDocuments();",
"void readAPFdocument (Document apfDoc, String fileText) {\n\t\tNodeList sourceFileElements = apfDoc.getElementsByTagName(\"source_file\");\n\t\tElement sourceFileElement = (Element) sourceFileElements.item(0);\n\t\tsourceFile = sourceFileElement.getAttribute(\"URI\");\n\t\tsourceType = sourceFileElement.getAttribute(\"SOURCE\");\n\n\t\tNodeList documentElements = apfDoc.getElementsByTagName(\"document\");\n\t\tElement documentElement = (Element) documentElements.item(0);\n\t\tdocID = documentElement.getAttribute(\"DOCID\");\n\n\t\tif (Ace.perfectMentions & !Ace.perfectEntities) {\n\t\t\treadPerfectMentions (apfDoc, fileText);\n\t\t\treturn;\n\t\t}\n\n\t\tNodeList entityElements = apfDoc.getElementsByTagName(\"entity\");\n\t\tfor (int i=0; i<entityElements.getLength(); i++) {\n\t\t\tElement entityElement = (Element) entityElements.item(i);\n\t\t\tAceEntity entity = new AceEntity (entityElement, fileText);\n\t\t\taddEntity(entity);\n\t\t}\n\t\tNodeList valueElements = apfDoc.getElementsByTagName(\"value\");\n\t\tfor (int i=0; i<valueElements.getLength(); i++) {\n\t\t\tElement valueElement = (Element) valueElements.item(i);\n\t\t\tAceValue value = new AceValue (valueElement, fileText);\n\t\t\taddValue(value);\n\t\t}\n\t\tNodeList timexElements = apfDoc.getElementsByTagName(\"timex2\");\n\t\tfor (int i=0; i<timexElements.getLength(); i++) {\n\t\t\tElement timexElement = (Element) timexElements.item(i);\n\t\t\tAceTimex timex = new AceTimex (timexElement, fileText);\n\t\t\taddTimeExpression(timex);\n\t\t}\n\t\tNodeList relationElements = apfDoc.getElementsByTagName(\"relation\");\n\t\tfor (int i=0; i<relationElements.getLength(); i++) {\n\t\t\tElement relationElement = (Element) relationElements.item(i);\n\t\t\tAceRelation relation = new AceRelation (relationElement, this, fileText);\n\t\t\taddRelation(relation);\n\t\t}\n\t\tNodeList eventElements = apfDoc.getElementsByTagName(\"event\");\n\t\tfor (int i=0; i<eventElements.getLength(); i++) {\n\t\t\tElement eventElement = (Element) eventElements.item(i);\n\t\t\tAceEvent event = new AceEvent (eventElement, this, fileText);\n\t\t\taddEvent(event);\n\t\t}\n\t}",
"public void fileOpened(OpenDefinitionsDocument doc) { }",
"public void fileOpened(OpenDefinitionsDocument doc) { }",
"void getNextWord () \n\t\t\tthrows IOException, FileNotFoundException {\n \n\t\tcontext.word.setLength(0);\n \n // Build the next entity\n while ((context.entityCharCount > 0)\n && (! atEnd)) {\n getNextCharacter();\n }\n \n // See if the word starts with white space\n boolean startingWhiteSpaceForWord\n = (htmlChar.whiteSpace \n && (context.fieldType == HTMLContext.TEXT)\n && (! context.preformatted));\n \n // Capture leading whitespace if appropriate\n if (htmlChar.whiteSpace\n && context.fieldType == HTMLContext.TEXT\n && (context.field.length() > 0\n || context.preformatted)) {\n context.word.append (htmlChar.character);\n }\n \n // If we're dealing with preformatted text, \n // then capture all leading white space\n if (context.preformatted && context.fieldType == HTMLContext.TEXT) {\n while (htmlChar.whiteSpace && (! atEnd)) {\n context.word.append (htmlChar.character);\n getNextCharacter();\n }\n }\n \n // Now skip any remaining white space\n while (((htmlChar.whiteSpace) \n || context.entityCharCount > 0)\n && (! atEnd)) {\n getNextCharacter();\n }\n \n // See if we've got got a quoted attribute value\n\t\tif (context.fieldType == HTMLContext.ATTRIBUTE_VALUE\n && (! htmlChar.translatedEntity)) {\n if (htmlChar.character == GlobalConstants.DOUBLE_QUOTE) {\n context.quoted = true;\n context.startQuoteChar = GlobalConstants.DOUBLE_QUOTE;\n }\n else\n if (htmlChar.character == GlobalConstants.SINGLE_QUOTE) {\n context.quoted = true;\n context.startQuoteChar = GlobalConstants.SINGLE_QUOTE;\n }\n\t\t}\n \n // Now capture the word's content\n\t\twhile (! htmlChar.endsWord) {\n\t\t\tcontext.word.append (htmlChar.character);\n\t\t\tdo {\n getNextCharacter();\n } while ((context.entityCharCount > 0) && (! atEnd));\n\t\t}\n \n\t\tif (context.quoted\n && (! htmlChar.translatedEntity)\n\t\t\t\t&& htmlChar.character == context.startQuoteChar) {\n\t\t\tcontext.word.append (htmlChar.character);\n context.quoted = false;\n\t\t\tdo {\n getNextCharacter();\n } while ((context.entityCharCount > 0) && (! atEnd));\n\t\t}\n if (startingWhiteSpaceForWord\n && context.fieldType == HTMLContext.TEXT\n && context.word.length() > 0\n && (! Character.isWhitespace (context.word.charAt (0)))) {\n context.word.insert (0, ' ');\n }\n\t}",
"public TextMetaData parse(IFileHandler file) {\n\n\t\tTextMetaData metaData = new TextMetaData();\n\t\tStringBuilder bldWord = new StringBuilder();\n\n\t\t// the caret position holds the current position in the text stream\n\t\t// and is used to store the position of the words that have been found\n\t\t// which is useful information to highlight the words later on\n\t\tlong caretPosition = 0;\n\t\t\n\t\twhile (file.hasNext()) {\n\n\t\t\t// we iterate over the file content (which is obviously text based)\n\t\t\tString filePart = file.next();\n\t\t\t\n\t\t\tfor (int i = 0; i < filePart.length(); ++i) {\n\n\t\t\t\tchar c = filePart.charAt(i);\n\t\t\t\tboolean isWordFinisihed = false;\n\n\t\t\t\tint type = Character.getType(c);\n\n\t\t\t\t// check for a punctuation character\n\t\t\t\tswitch (type) {\n\t\t\t\t\n\t\t\t\tcase Character.START_PUNCTUATION:\n\t\t\t\tcase Character.INITIAL_QUOTE_PUNCTUATION:\n\t\t\t\tcase Character.FINAL_QUOTE_PUNCTUATION:\n\t\t\t\tcase Character.END_PUNCTUATION:\n\t\t\t\tcase Character.DASH_PUNCTUATION:\n\t\t\t\tcase Character.CONNECTOR_PUNCTUATION:\n\t\t\t\tcase Character.SPACE_SEPARATOR:\n\t\t\t\tcase Character.LINE_SEPARATOR:\n\t\t\t\tcase Character.PARAGRAPH_SEPARATOR:\n\t\t\t\tcase Character.CONTROL:\n\t\t\t\t\t\n\t\t\t\t\tisWordFinisihed = true;\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase Character.OTHER_PUNCTUATION:\n\n\t\t\t\t\t// if we found a punctuation between a letter or digit\n\t\t\t\t\t// aka 1.2.3 or V.1.2 or something like this\n\t\t\t\t\t// we will see this as a single word\n\t\t\t\t\tif ((i > 0)\n\t\t\t\t\t\t\t&& (i != filePart.length() - 1)\n\t\t\t\t\t\t\t&& Character\n\t\t\t\t\t\t\t\t\t.isLetterOrDigit(filePart.charAt(i - 1))\n\t\t\t\t\t\t\t&& Character\n\t\t\t\t\t\t\t\t\t.isLetterOrDigit(filePart.charAt(i + 1))) {\n\n\t\t\t\t\t\tisWordFinisihed = false;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t\n\t\t\t\t\t\tisWordFinisihed = true;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\n\t\t\t\t\tisWordFinisihed = false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\t// if we figured out that we have finished one word\n\t\t\t\tif (isWordFinisihed) {\n\n\t\t\t\t\tif (bldWord.length() > 0) {\n\n\t\t\t\t\t\t// we have to store this information in the meta data\n\t\t\t\t\t\tString newWord = bldWord.toString();\n\t\t\t\t\t\t\n\t\t\t\t\t\tWordPosition pos = new WordPosition(caretPosition + i - newWord.length(), newWord);\n\t\t\t\t\t\t\n\t\t\t\t\t\tmetaData.addWord(newWord, pos);\n\n\t\t\t\t\t\t// and inform the UI about the process update\n\t\t\t\t\t\tint percentage = (int) (pos.getEndPosition() * 100 / file.getFileLength());\n\t\t\t\t\t\t\n\t\t\t\t\t\tString message = String.format(\"Wort \\\"%s\\\" gefunden\",\n\t\t\t\t\t\t\t\tnewWord);\n\n\t\t\t\t\t\tnotifyTextProcessStatusUpdate(new TextProcessStatusEvent(\n\t\t\t\t\t\t\t\tthis, percentage, message));\n\n\t\t\t\t\t\tbldWord = new StringBuilder();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// when the word is finished, we have examined a valid punctuation character before\n\t\t\t\t\t// which is the signal to the text processing strategy that the word is finished\n\t\t\t\t\tmetaData.addPunctuation(c);\n\t\t\t\t\t\n\t\t\t\t} else {\n\n\t\t\t\t\t// otherwise we are still in-between the word and have to build it \n\t\t\t\t\t// char-by-char\n\t\t\t\t\tbldWord.append(c);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tcaretPosition += filePart.length();\n\t\t}\n\n\t\t// notify that we will have to sort the list of examined words\n\t\t// based on their frequency, which might take a while\n\t\tnotifyTextProcessStatusUpdate(new TextProcessStatusEvent(this, -1,\n\t\t\t\t\"Sortiere Wortliste...\"));\n\n\t\tmetaData.sortWordsByFrequency();\n\n\t\t// after all the process is finished, so refresh the UI here\n\t\tnotifyTextProcessStatusFinish(new TextProcessFinishEvent(this,\n\t\t\t\tfile.getPlainText(), metaData));\n\t\t\n\t\treturn metaData;\n\t}",
"private void indexDocument(File f) throws IOException {\n\n\t\tHashMap<String, StringBuilder> fm;\n\t\tif (!f.getName().equals(\".DS_Store\")) {\n\n\t\t\tBufferedReader br = new BufferedReader(new FileReader(f));\n\n\t\t\tString s = \"\";\n\t\t\twhile ((s = br.readLine()) != null) {\n\n\t\t\t\tString temp = \"\";\n\n\t\t\t\tif (s.contains(\"<DOC>\")) {\n\n\t\t\t\t\ts = br.readLine();\n\n\t\t\t\t\twhile (!s.contains(\"</DOC>\")) {\n\n\t\t\t\t\t\ttemp += s + \" \";\n\n\t\t\t\t\t\ts = br.readLine();\n\t\t\t\t\t}\n\n\t\t\t\t\tfm = parseTags(temp);\n\t\t\t\t\tindexDocumentHelper(fm);\n\t\t\t\t}\n\n\t\t\t}\n\t\t\tbr.close();\n\t\t}\n\n\t}",
"IDocument getDocument(File file);",
"private void inToTrinhv3(HttpServletRequest request, HttpServletResponse reponse, GiaHanForm giaHanForm, ApplicationContext appConText) throws Exception {\r\n\r\n\t\tString fileIn = request.getRealPath(\"/docin\") + \"\\\\TTNB10.doc\";\r\n\t\tString fileOut = request.getRealPath(\"/docout\") + \"\\\\TTNB10_Out\" + System.currentTimeMillis() + request.getSession().getId() + \".doc\";\r\n\r\n\t\tString fileTemplate = null;\r\n\t\tfileTemplate = \"ttnb10\"; // (ngon, chuan)\r\n\t\tString idCuocTtkt = giaHanForm.getIdCuocTtKt();\r\n\t\tTtktKhCuocTtkt cuocTtkt = CuocTtktService.getCuocTtktWithoutNoiDung(appConText, idCuocTtkt);\r\n\r\n\t\tTtktCbQd cbQd = TtktService.getQuyetDinh(idCuocTtkt, appConText);\r\n\t\tString hinhThuc = (cuocTtkt.getHinhThuc().booleanValue()) ? \"ki\\u1EC3m tra\" : \"thanh tra\";\r\n\t\tStringBuffer sb = new StringBuffer(hinhThuc);\r\n\r\n\t\tMsWordUtils word = new MsWordUtils(fileIn, fileOut);\r\n\t\ttry {\r\n\t\t\tword.put(\"[ten_cqt]\", KtnbUtil.getTenCqtCapTrenTt(appConText).toUpperCase());\r\n\t\t\t// hinh thuc thanh tra kiem tra\r\n\t\t\tif (Formater.isNull(giaHanForm.getSoQd())) {\r\n\t\t\t\tsb.append(\" Q\\u0110 S\\u1ED0......\");\r\n\t\t\t} else {\r\n\t\t\t\tsb.append(\" Q\\u0110 S\\u1ED0 \" + giaHanForm.getSoQd());\r\n\t\t\t}\r\n\t\t\tword.put(\"[doan_ttkt_so]\", sb.toString().toUpperCase());\r\n\r\n\t\t\tword.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[dv_dc_ttkt]\", cuocTtkt.getTenDonViBi());\r\n\t\t\tword.put(\"[thu_truong_cqt_ra_qd]\", KtnbUtil.getTenThuTruongCqtForMauin(appConText).toUpperCase());\r\n\t\t\tword.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tif (Formater.isNull(cbQd.getSoQuyetDinh())) {\r\n\t\t\t\tword.put(\"[qd_so]\", \"............\");\r\n\t\t\t} else {\r\n\t\t\t\tword.put(\"[qd_so]\", cbQd.getSoQuyetDinh());\r\n\t\t\t}\r\n\r\n\t\t\tString ngayxet = Formater.date2str(cbQd.getNgayRaQuyetDnh());\r\n\t\t\tString[] arrngayxet = ngayxet.split(\"/\");\r\n\t\t\tword.put(\"[ngay_qd]\", \"ng\\u00E0y \" + arrngayxet[0] + \" th\\u00E1ng \" + arrngayxet[1] + \" n\\u0103m \" + arrngayxet[2]);\r\n\t\t\tword.put(\"[thu_truong_cqt]\", KtnbUtil.getTenThuTruongCqtForMauin(appConText));\r\n\t\t\tword.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[dv_dc_ttkt]\", cuocTtkt.getTenDonViBi());\r\n\r\n\t\t\tword.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[dv_dc_ttkt]\", cuocTtkt.getTenDonViBi().toString());\r\n\t\t\tword.put(\"[ngay_lv]\", giaHanForm.getSoNgayRaHan());\r\n\t\t\tString tungay = giaHanForm.getRaHanTuNgay();\r\n\t\t\tString[] arrtungay = tungay.split(\"/\");\r\n\t\t\tword.put(\"[tu_ngay]\", \"ng\\u00E0y \" + arrtungay[0] + \" th\\u00E1ng \" + arrtungay[1] + \" n\\u0103m \" + arrtungay[2]);\r\n\t\t\t// den ngay\r\n\t\t\tString denngay = giaHanForm.getRaHanDenNgay();\r\n\t\t\tString[] arrdenngay = denngay.split(\"/\");\r\n\t\t\tword.put(\"[den_ngay]\", \"ng\\u00E0y \" + arrdenngay[0] + \" th\\u00E1ng \" + arrdenngay[1] + \" n\\u0103m \" + arrdenngay[2]);\r\n\t\t\tword.put(\"[ly_do]\", giaHanForm.getLyDoRaHan());\r\n\t\t\tword.put(\"[thu_truong_cqt_ra_qd]\", KtnbUtil.getTenThuTruongCqtForMauin(appConText).toUpperCase());\r\n\t\t\tword.put(\"[noi_duyet]\", giaHanForm.getNoiPheDuyet());\r\n\t\t\t// ngay duyet\r\n\t\t\tString ngayduyet = giaHanForm.getNgayPheDuyet();\r\n\t\t\tString[] arrngayduyet = ngayduyet.split(\"/\");\r\n\t\t\tif (arrngayduyet.length >= 2) {\r\n\t\t\t\tword.put(\"[ngay_duyet]\", \"ng\\u00E0y \" + arrngayduyet[0] + \" th\\u00E1ng \" + arrngayduyet[1] + \" n\\u0103m \" + arrngayduyet[2]);\r\n\t\t\t}\r\n\t\t\tword.put(\"[noi_lap]\", giaHanForm.getNoiTrinh());\r\n\t\t\t// ngay lap to trinh\r\n\t\t\tString ngaylaptotrinh = giaHanForm.getNgayTrinh();\r\n\t\t\tString[] arrngaylaptotrinh = ngaylaptotrinh.split(\"/\");\r\n\t\t\tif (arrngaylaptotrinh.length >= 2) {\r\n\t\t\t\tword.put(\"[ngay_lap_to_trinh]\", \"ng\\u00E0y \" + arrngaylaptotrinh[0] + \" th\\u00E1ng \" + arrngaylaptotrinh[1] + \" n\\u0103m \" + arrngaylaptotrinh[2]);\r\n\t\t\t}\r\n\t\t\tword.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[y_kien_phe_duyet]\", giaHanForm.getKienPheDuyet());\r\n\t\t\tword.put(\"[ten_truong_doan]\", cuocTtkt.getTenTruongDoan());\r\n\t\t\tword.put(\"[chuc_danh_thu_truong]\", KtnbUtil.getChucVuThuTruongByMaCqt(appConText.getMaCqt()).toUpperCase());\r\n\t\t\t// if (Formater.isNull(appConText.getTenThuTruong())) {\r\n\t\t\t// word.put(\"[ten_thu_truong]\", \"\");\r\n\t\t\t// } else {\r\n\t\t\t// word.put(\"[ten_thu_truong]\", appConText.getTenThuTruong());\r\n\t\t\t// }\r\n\t\t\tword.saveAndClose();\r\n\t\t\tword.downloadFile(fileOut, \"Mau TTNB10\", \".doc\", reponse);\r\n\t\t} catch (Exception ex) {\r\n\t\t\t// ex.printStackTrace();\r\n\t\t\tSystem.out.println(\"Download Error: \" + ex.getMessage());\r\n\t\t} finally {\r\n\t\t\ttry {\r\n\t\t\t\tword.saveAndClose();\r\n\t\t\t} catch (Exception e) {\r\n\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"PsiFile[] findFilesWithPlainTextWords( String word);",
"public void makeWord(String inputText,String pageId,createIndex createindex,String contentType)\n {\n int length,i;\n char c;\n boolean linkFound=false;\n int count1,count2,count3,count4,count5,count6,count7,count8,count9;\n\n\n\n StringBuilder word=new StringBuilder();\n // String finalWord=null,stemmedWord=null;\n docId=Integer.parseInt(pageId.trim());\n\n ci=createindex;\n // Stemmer st=new Stemmer();\n //createIndex createindex=new createIndex();\n\n length=inputText.length();\n\n for(i=0;i<length;i++)\n {\n c=inputText.charAt(i);\n if(c<123 && c>96)\n {\n word.append(c);\n }\n\n else if(c=='{')\n {\n if ( i+9 < length && inputText.substring(i+1,i+9).equals(\"{infobox\") )\n {\n\n StringBuilder infoboxString = new StringBuilder();\n\n count1 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n infoboxString.append(c);\n if ( c == '{') {\n count1++;\n }\n else if ( c == '}') {\n count1--;\n }\n if ( count1 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n if ( c == '=' ) {infoboxString.deleteCharAt(infoboxString.length()-1);}\n break;\n }\n }\n\n processInfobox(infoboxString);\n\n }\n\n else if ( i+8 < length && inputText.substring(i+1,i+8).equals(\"{geobox\") )\n {\n\n StringBuilder geoboxString = new StringBuilder();\n\n count2 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n geoboxString.append(c);\n if ( c == '{') {\n count2++;\n }\n else if ( c == '}') {\n count2--;\n }\n if ( count2 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n if ( c == '=' ) {geoboxString.deleteCharAt(geoboxString.length()-1);}\n break;\n }\n }\n\n // processGeobox(geoboxString);\n }\n\n else if ( i+6 < length && inputText.substring(i+1,i+6).equals(\"{cite\") )\n {\n\n /*\n * Citations are to be removed.\n */\n\n count3 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n if ( c == '{') {\n count3++;\n }\n else if ( c == '}') {\n count3--;\n }\n if ( count3 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n break;\n }\n }\n\n }\n\n else if ( i+4 < length && inputText.substring(i+1,i+4).equals(\"{gr\") )\n {\n\n /*\n * {{GR .. to be removed\n */\n\n count4 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n if ( c == '{') {\n count4++;\n }\n else if ( c == '}') {\n count4--;\n }\n if ( count4 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n break;\n }\n }\n\n }\n else if ( i+7 < length && inputText.substring(i+1,i+7).equals(\"{coord\") )\n {\n\n /**\n * Coords to be removed\n */\n\n count5 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n\n if ( c == '{') {\n count5++;\n }\n else if ( c == '}') {\n count5--;\n }\n if ( count5 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n break;\n }\n }\n\n }\n\n //System.out.println(\"process infobox\");\n }\n else if(c=='[')\n {\n // System.out.println(\"process square brace\");\n\n if ( i+11 < length && inputText.substring(i+1,i+11).equalsIgnoreCase(\"[category:\"))\n {\n\n StringBuilder categoryString = new StringBuilder();\n\n count6 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n categoryString.append(c);\n if ( c == '[') {\n count6++;\n }\n else if ( c == ']') {\n count6--;\n }\n if ( count6 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n if ( c == '=' ) {categoryString.deleteCharAt(categoryString.length()-1);}\n break;\n }\n }\n\n // System.out.println(\"category string=\"+categoryString.toString());\n processCategories(categoryString);\n\n }\n else if ( i+8 < length && inputText.substring(i+1,i+8).equalsIgnoreCase(\"[image:\") ) {\n\n /**\n * Images to be removed\n */\n\n count7 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n if ( c == '[') {\n count7++;\n }\n else if ( c == ']') {\n count7--;\n }\n if ( count7 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n break;\n }\n }\n\n }\n else if ( i+7 < length && inputText.substring(i+1,i+7).equalsIgnoreCase(\"[file:\") ) {\n\n /**\n * File to be removed\n */\n\n count8 = 0;\n for ( ; i < length ; i++ ) {\n\n c = inputText.charAt(i);\n\n if ( c == '[') {\n count8++;\n }\n else if ( c == ']') {\n count8--;\n }\n if ( count8 == 0 || (c == '=' && i+1 < length && inputText.charAt(i+1) == '=')) {\n break;\n }\n }\n\n }\n\n }\n else if(c=='<')\n {\n //System.out.println(\"Process < >\");\n\n if ( i+4 < length && inputText.substring(i+1,i+4).equalsIgnoreCase(\"!--\") ) {\n\n /**\n * Comments to be removed\n */\n\n int locationClose = inputText.indexOf(\"-->\" , i+1);\n if ( locationClose == -1 || locationClose+2 > length ) {\n i = length-1;\n }\n else {\n i = locationClose+2;\n }\n\n }\n else if ( i+5 < length && inputText.substring(i+1,i+5).equalsIgnoreCase(\"ref>\") ) {\n\n /**\n * References to be removed\n */\n int locationClose = inputText.indexOf(\"</ref>\" , i+1);\n if ( locationClose == -1 || locationClose+5 > length ) {\n i = length-1;\n }\n else {\n i = locationClose+5;\n }\n\n }\n else if ( i+8 < length && inputText.substring(i+1,i+8).equalsIgnoreCase(\"gallery\") ) {\n\n /**\n * Gallery to be removed\n */\n int locationClose = inputText.indexOf(\"</gallery>\" , i+1);\n if ( locationClose == -1 || locationClose+9 > length) {\n i = length-1;\n }\n else {\n i = locationClose+9;\n }\n }\n\n }\n else if ( c == '=' && i+1 < length && inputText.charAt(i+1) == '=')\n {\n\n linkFound = false;\n i+=2;\n while ( i < length && ((c = inputText.charAt(i)) == ' ' || (c = inputText.charAt(i)) == '\\t') )\n {\n i++;\n }\n\n if ( i+14 < length && inputText.substring(i , i+14 ).equals(\"external links\") )\n {\n //System.out.println(\"External link found\");\n linkFound = true;\n i+= 14;\n }\n\n }\n else if ( c == '*' && linkFound == true )\n {\n\n //System.out.println(\"Link found\");\n count9 = 0;\n boolean spaceParsed = false;\n StringBuilder link = new StringBuilder();\n while ( count9 != 2 && i < length )\n {\n c = inputText.charAt(i);\n if ( c == '[' || c == ']' )\n {\n count9++;\n }\n if ( count9 == 1 && spaceParsed == true)\n {\n link.append(c);\n }\n else if ( count9 != 0 && spaceParsed == false && c == ' ')\n {\n spaceParsed = true;\n }\n i++;\n }\n\n StringBuilder linkWord = new StringBuilder();\n for ( int j = 0 ; j < link.length() ; j++ )\n {\n char currentCharTemp = link.charAt(j);\n if ( (int)currentCharTemp >= 'a' && (int)currentCharTemp <= 'z' )\n {\n linkWord.append(currentCharTemp);\n }\n else\n {\n\n // System.out.println(\"link : \" + linkWord.toString());\n processLink(linkWord);\n linkWord.setLength(0);\n }\n }\n if ( linkWord.length() > 1 )\n {\n //System.out.println(\"link : \" + linkWord.toString());\n processLink(linkWord);\n linkWord.setLength(0);\n }\n\n }\n else\n {\n if(word.length()>1)\n filterAndAddWord(word,contentType);\n\n word.setLength(0);\n }\n }\n\n\n if(word.length()>1)\n filterAndAddWord(word,contentType);\n\n word.setLength(0);\n /*\n if(word.length()>0)\n {\n finalWord=new String(word);\n if(!(checkStopword(finalWord)))\n {\n st.add(finalWord.toCharArray(),finalWord.length());\n stemmedWord=st.stem();\n\n createindex.addToTreeSet(stemmedWord,docId);\n\n }\n\n word.delete(0, word.length());\n } */\n\n }",
"public void xuLyLuuHoaHoaDon(){\n JFileChooser fileChooser = new JFileChooser();\n fileChooser.setFileFilter(new FileFilter() {\n @Override\n public boolean accept(File file) {\n return file.getAbsolutePath().endsWith(\".txt\");\n }\n\n @Override\n public String getDescription() {\n return \".txt\";\n }\n });\n fileChooser.setFileFilter(new FileFilter() {\n @Override\n public boolean accept(File file) {\n return file.getAbsolutePath().endsWith(\".doc\");\n }\n\n @Override\n public String getDescription() {\n return \".doc\";\n }\n });\n int flag = fileChooser.showSaveDialog(null);\n if(flag == JFileChooser.APPROVE_OPTION){\n File file = fileChooser.getSelectedFile();\n try {\n OutputStreamWriter outputStreamWriter = new OutputStreamWriter(new FileOutputStream(file), Charset.forName(\"UTF-8\"));\n PrintWriter printWriter = new PrintWriter(outputStreamWriter);\n String lineTieuDe1 = \"----------------Phiếu Thanh Toán-----------------------\";\n String lineMaPTT = \"+Mã Phiếu Thanh Toán: \" + txtMaPTT.getText();\n String lineMaPDK = \"+Mã Phiếu Đăng Ký: \" + cbbMaPDK.getSelectedItem().toString();\n String lineSoThang = \"+Số Tháng: \" + txtSoThang.getText()+\"|\";\n String lineNgayTT = \"+Ngày Thanh Toán: \" + txtNgayTT.getText();\n String lineTienPhong = \"+Tiền Phòng: \" + txtTongTien.getText();\n String lineTienDV = \"+Tiền Dịch Vụ: \"+txtThanhToanTongCong.getText();\n String lineTieuDe2 = \"--------------------------------------------------------\";\n String lineTienPhaiTra =\"+Tiền Phải Trả: \" + txtTienPhaiTra.getText()+\" \";\n String lineTieuDe3 = \"--------------------------------------------------------\";\n \n printWriter.println(lineTieuDe1);\n printWriter.println(lineMaPTT);\n printWriter.println(lineMaPDK);\n printWriter.println(lineSoThang);\n printWriter.println(lineNgayTT);\n printWriter.println(lineTienPhong);\n printWriter.println(lineTienDV);\n printWriter.println(lineTieuDe2);\n printWriter.println(lineTienPhaiTra);\n printWriter.println(lineTieuDe3);\n \n printWriter.close();\n outputStreamWriter.close();\n \n } catch (Exception e) {\n e.printStackTrace();\n }\n JOptionPane.showMessageDialog(null, \"Đã lưu\");\n }\n \n }",
"public static void main(String[] args) {\r\n int argc = args.length;\r\n\r\n // Given only the words file\r\n if(argc == 2 && args[0].charAt(0) == '-' && args[0].charAt(1) == 'i'){\r\n String fileName = args[1];\r\n int size = 1;\r\n ArrayList<String> wordList = new ArrayList<String>();\r\n\r\n // Get data from file\r\n ArrayList<String> dataList = new ArrayList<String>();\t\r\n try {\r\n File myObj = new File(fileName);\r\n Scanner myReader = new Scanner(myObj);\r\n while (myReader.hasNextLine()) {\r\n String data = myReader.nextLine(); \r\n dataList.add(data);\r\n }\r\n myReader.close();\r\n } catch (FileNotFoundException e) {\r\n System.out.println(\"An error occurred.\");\r\n e.printStackTrace();\r\n }\r\n\r\n // Get words from data \r\n for(int s = 0 ; s < dataList.size() ; s++) {\r\n String[] arrOfStr = dataList.get(s).split(\"[,\\\\;\\\\ ]\");\t// check same line words\r\n for(int i = 0 ; i < arrOfStr.length ; i++) {\r\n if(arrOfStr[i].equals(arrOfStr[i].toUpperCase())){\r\n System.out.println(\"Words not only in lowercase or mixed\");\r\n //termina o programa\r\n return;\r\n }\r\n if(!(arrOfStr[i].matches(\"[a-zA-Z]+\"))){\r\n System.out.println(\"Words have non alpha values\");\r\n //termina o programa\r\n return;\r\n }\r\n if(arrOfStr[i].length() > size) size = arrOfStr[i].length();\r\n wordList.add(arrOfStr[i].toUpperCase());\t// add words discovered and turn upper case\r\n }\r\n }\r\n if(wordList.size() > size) size = wordList.size();\r\n char[][] wordSoup = wsGen( wordList, size + 2);\r\n saveData(dataList,wordSoup);\r\n return;\r\n }\r\n\r\n // Given all args\r\n if(argc == 4 && args[0].charAt(0) == '-' && args[0].charAt(1) == 'i' && args[2].charAt(0) == '-' && args[2].charAt(1) == 's'){\r\n String fileName = args[1];\r\n int size = Integer.parseInt(args[3]);\r\n // Check max size\r\n if(size > 40){\r\n System.out.print(\"Max size 40\");\r\n return;\r\n }\r\n\r\n ArrayList<String> wordList = new ArrayList<String>();\r\n\r\n // Get data from file\r\n ArrayList<String> dataList = new ArrayList<String>();\t\r\n try {\r\n File myObj = new File(fileName);\r\n Scanner myReader = new Scanner(myObj);\r\n while (myReader.hasNextLine()) {\r\n String data = myReader.nextLine(); \r\n dataList.add(data);\r\n }\r\n myReader.close();\r\n } catch (FileNotFoundException e) {\r\n System.out.println(\"An error occurred.\");\r\n e.printStackTrace();\r\n }\r\n\r\n // Get words from data \r\n for(int s = 0 ; s < dataList.size() ; s++) {\r\n String[] arrOfStr = dataList.get(s).split(\"[,\\\\;\\\\ ]\");\t// check same line words\r\n for(int i = 0 ; i < arrOfStr.length ; i++) {\r\n if(arrOfStr[i].equals(arrOfStr[i].toUpperCase())){\r\n System.out.println(\"Words not only in lowercase or mixed\");\r\n //termina o programa\r\n return;\r\n }\r\n if(!(arrOfStr[i].matches(\"[a-zA-Z]+\"))){\r\n System.out.println(\"Words have non alpha values\");\r\n //termina o programa\r\n return;\r\n }\r\n if(arrOfStr[i].length() > size){\r\n System.out.println(\"At least one word given doesn't fit in the size provided.\");\r\n return;\r\n }\r\n wordList.add(arrOfStr[i].toUpperCase());\t// add words discovered and turn upper case\r\n }\r\n }\r\n char[][] wordSoup = wsGen( wordList, size);\r\n saveData(dataList,wordSoup);\r\n return;\r\n }\r\n // Help message\r\n System.out.println(\"usage: -i file # gives file with word soup words\");\r\n System.out.println(\" -s size # gives size for the word soup\");\r\n return;\r\n }",
"public static void openTextFile() {\n\t\ttry {\n\t\t\tin1 = new Scanner(new File(file1));\n\t\t\tin2 = new Scanner(new File(file2));\n\t\t} catch(FileNotFoundException ex) {\n\t\t\tSystem.err.println(\"Error opening file\" + ex);\n\t\t\tSystem.exit(1);\n\t\t}\n\t}",
"public void analyzeDocument(String text) {\n\t\tString[] tokens = m_tokenizer.tokenize(text.toLowerCase());\n\t\tfor (int j = 0; j < tokens.length; j++)\n\t\t\ttokens[j] = SnowballStemmingDemo(NormalizationDemo(tokens[j]));\n\t\tHashMap<String, Integer> document_tf = new HashMap<String, Integer>();\n\t\tfor (String token : tokens) {\n\t\t\tif (!document_tf.containsKey(token))\n\t\t\t\tdocument_tf.put(token, 1);\n\t\t\telse\n\t\t\t\tdocument_tf.put(token, document_tf.get(token) + 1);\n\t\t\tif (!df.containsKey(token))\n\t\t\t\tdf.put(token, 1);\n\t\t\telse\n\t\t\t\tdf.put(token, df.get(token) + 1);\n\t\t}\n\t\ttf.add(document_tf);\n\t\t/*\n\t\t * for(String token : document_tf.keySet()) { if(!df.containsKey(token))\n\t\t * df.put(token, 1); else df.put(token, df.get(token) + 1); if(!) }\n\t\t */\n\t\tm_reviews.add(text);\n\t}",
"public void fileSaved(OpenDefinitionsDocument doc) { }",
"public void fileSaved(OpenDefinitionsDocument doc) { }",
"@Test\n\tpublic void probandoConParser() {\n\t\tString dBoxUrl = \"/home/julio/Dropbox/julio_box/educacion/maestria_explotacion_datos_uba/materias/cuat_4_text_mining/material/tp3/\";\n\t\tString modelUrl = dBoxUrl + \"NER/models/es-ner-person.bin\";\n\t\tString filesUrl = dBoxUrl + \"NER/archivoPrueba\";\n\t\tString sampleFile = filesUrl + \"/viernes-23-05-14-alan-fitzpatrick-gala-cordoba.html\";\n\t\tList<String> docs = getMyDocsFromSomewhere(filesUrl);\n\n\t\ttry {\n\t\t\t// detecting the file type\n\t\t\tBodyContentHandler handler = new BodyContentHandler();\n\t\t\tMetadata metadata = new Metadata();\n\t\t\tFileInputStream inputstream = new FileInputStream(new File(sampleFile));\n\t\t\tParseContext pcontext = new ParseContext();\n\n\t\t\t// Html parser\n\t\t\tHtmlParser htmlparser = new HtmlParser();\n\t\t\thtmlparser.parse(inputstream, handler, metadata, pcontext);\n\t\t\tSystem.out.println(\"Contents of the document:\" + handler.toString());\n\t\t\tSystem.out.println(\"Metadata of the document:\");\n\t\t\tString[] metadataNames = metadata.names();\n\n\t\t\tfor (String name : metadataNames) {\n\t\t\t\tSystem.out.println(name + \": \" + metadata.get(name));\n\t\t\t}\n\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t\tAssert.fail();\n\t\t}\n\n\t}",
"public void newFileCreated(OpenDefinitionsDocument doc) { }",
"public void newFileCreated(OpenDefinitionsDocument doc) { }",
"public static void main(String[] args) throws IOException {\n TxtToDocX z = new TxtToDocX();\r\n Sala x = new Sala();\r\n z.catchNameFiles();\r\n\r\n for (int i = 0; i < nomeArquivos.length; i++) {\r\n z.LoadTxt(nomeArquivos[i]);\r\n }\r\n z.replaces();\r\n \r\n \r\n for (int i = 0; i < nomeArquivos.length; i++) {\r\n System.out.println(nomeArquivos[i]);\r\n }\r\n // z.replaces();\r\n for (int j = 0; j < salas2.size(); j++) {\r\n System.out.println(\"Turma: \" + salas2.get(j).getNome());\r\n for (int i = 0; i < salas2.get(j).getDadosalas().size(); i++) {\r\n if (salas2.get(j).getDadosalas().get(i).getSerie().equals(salas2.get(j).getNome())) {\r\n\r\n System.out.println(\"Matricula:\" + salas2.get(j).getDadosalas().get(i).getMatricula()\r\n + \" Nome:\" + salas2.get(j).getDadosalas().get(i).getNome()\r\n + \" Senha:\" + salas2.get(j).getDadosalas().get(i).getSenha() + \"\\n\");\r\n }\r\n }\r\n }\r\n \r\n z.WriteDocx();\r\n }",
"public static interface TextExtractor {\n\n\t\t/**\n\t\t * Extract the full-text from an MS Office document.\n\t\t * \n\t\t * @param fileSystem The POIFSFileSystem providing structural access to the MS Office document.\n\t\t * @return A String containing the full-text of the document.\n\t\t * @throws IOException whenever access to the POIFSFileSystem caused an IOException.\n\t\t */\n\t\tpublic String getText(POIFSFileSystem fileSystem) throws IOException;\n\t}",
"void addWordToDoc(int doc,VocabWord word);",
"private static void ReadText(String path) {\n\t\t//reads the file, throws an error if there is no file to open\n\t\ttry {\n\t\t\tinput = new Scanner(new File(path));\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"Error opening file...\");\n\t\t\tSystem.exit(1);\n\t\t}\n\t\tString line; //stores the string of text from the .txt file\n\t\tString parsedWord; //Stores the word of the parsed word\n\t\tint wordLength; //Stores the length of the word\n\t\tint lineNum = 1; //Stores the number of line\n\t\ttry {\n\t\t\t//loops while there is still a new line in the .txt file\n\t\t\twhile ((line = input.nextLine()) != null) {\n\t\t\t\t//separates the lines by words\n\t\t\t\tStringTokenizer st = new StringTokenizer(line);\n\t\t\t\t//loops while there are still more words in the line\n\t\t\t\twhile (st.hasMoreTokens()) {\n\t\t\t\t\tparsedWord = st.nextToken();\n\t\t\t\t\twordLength = parsedWord.length();\n\t\t\t\t\t//Regex gets rid of all punctuation\n\t\t\t\t\tif (parsedWord.matches(\".*\\\\p{Punct}\")) {\n\t\t\t\t\t\tparsedWord = parsedWord.substring(0, wordLength - 1);\n\t\t\t\t\t}\n\t\t\t\t\t//add the word to the list\n\t\t\t\t\twordList.add(parsedWord);\n\t\t\t\t\tlineList.add(lineNum);\n\t\t\t\t}\n\t\t\t\tlineNum++;\n\t\t\t}\n\t\t} catch (NoSuchElementException e) {\n\t\t\t//Do nothing\n\t\t}\n\t\tinput.close();\n\t}",
"public static void main(String[] args) throws IOException{\n\t\tint termIndex = 1;\n\t\t\n\t\t// startOffset holds the start offset for each term in\n\t\t// the corpus.\n\t\tlong startOffset = 0;\n\t\t\t\n\t\t// unique_terms is true if there are atleast one more\n\t\t// unique term in corpus.\n\t\tboolean unique_terms = true;\n\t\t\n\t\t\n\t\t//load the stopwords from the HDD\n\t\tString stopwords = getStopWords();\n\t\t\n\t\t// allTokenHash contains all the terms and its termid\n\t\tHashMap<String, Integer> allTermHash = new HashMap<String, Integer>();\n\t\t\n\t\t// catalogHash contains the term and its position in\n\t\t// the inverted list present in the HDD.\n\t\tHashMap<Integer, Multimap> catalogHash = new HashMap<Integer, Multimap>();\n\t\t\n\t\t// finalCatalogHash contains the catalogHash for the invertedIndexHash\n\t\t// present in the HDD.\n\t\tHashMap<Integer, String> finalCatalogHash = new HashMap<Integer, String>();\n\t\t\n\t\t// token1000Hash contains the term and Dblocks for the first 1000\n\t\tHashMap<Integer, Multimap> token1000DocHash = new HashMap<Integer, Multimap>();\n\t\t\n\t\t// documentHash contains the doclength of all the documents in the corpus\n\t\tHashMap<String, String> documentHash = new HashMap<String, String>();\t\n\t\t\n\t\t// id holds the document id corresponding to the docNumber.\n\t\tint id = 1;\n\t\t\n\t\t// until all unique terms are exhausted\n\t\t// pass through the documents and index the terms.\n\t\t//while(unique_terms){\n\t\t\t\n\t\t\tFile folder = new File(\"C:/Naveen/CCS/IR/AP89_DATA/AP_DATA/ap89_collection\");\n\t\t\t//File folder = new File(\"C:/Users/Naveen/Desktop/TestFolder\");\n\t\t\tFile[] listOfFiles = folder.listFiles();\n\t\t\t\n\t\t\t//for each file in the folder \n\t\t\tfor (File file : listOfFiles) {\n\t\t\t if (file.isFile()) {\n\t\t\t \t\n\t\t\t \tString str = file.getPath().replace(\"\\\\\",\"//\");\n\t\t\t \t\n\t\t\t \t\n\t\t\t\t\t//Document doc = new Document();\n\t\t\t //System.out.println(\"\"+str);\n\t\t\t\t\t//variables to keep parse document.\n\t\t\t\t\tint docCount = 0;\n\t\t\t\t\tint docNumber = 0;\n\t\t\t\t\tint endDoc = 0;\n\t\t\t\t\tint textCount = 0;\n\t\t\t\t\tint noText = 0;\n\t\t\t\t\tPath path = Paths.get(str);\n\t\t\t\t\t\n\t\t\t\t\t//Document id and text\n\t\t\t\t\tString docID = null;\n\t\t\t\t\tString docTEXT = null;\n\t\t\t\t\t\n\t\t\t\t\t//Stringbuffer to hold the text of each document\n\t\t\t\t\tStringBuffer text = new StringBuffer();\n\t\t\t\t\t\n\t\t\t\t\tScanner scanner = new Scanner(path);\n\t\t\t\t\twhile(scanner.hasNext()){\n\t\t\t\t\t\tString line = scanner.nextLine();\n\t\t\t\t\t\tif(line.contains(\"<DOC>\")){\n\t\t\t\t\t\t\t++docCount;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if(line.contains(\"</DOC>\")){\n\t\t\t\t\t\t\t++endDoc;\n\t\t\t\t\t\t\tdocTEXT = text.toString();\n\t\t\t\t\t\t\t//docTEXT = docTEXT.replaceAll(\"[\\\\n]\",\" \");\n\t\t\t\t\t\t\tSystem.out.println(\"ID: \"+id);\n\t\t\t\t\t\t\t//System.out.println(\"TEXT: \"+docTEXT);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// text with stop words removed\n\t\t\t\t\t\t\tPattern pattern1 = Pattern.compile(\"\\\\b(?:\"+stopwords+\")\\\\b\\\\s*\", Pattern.CASE_INSENSITIVE);\n\t\t\t\t\t\t\tMatcher matcher1 = pattern1.matcher(docTEXT);\n\t\t\t\t\t\t\tdocTEXT = matcher1.replaceAll(\"\");\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// text with stemming\n\t\t\t\t\t\t\t//docTEXT = stemmer(docTEXT);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tint docLength = 1;\n\t\t\t\t\t\t\t// regex to build the tokens from the document text\n\t\t\t\t\t\t\tPattern pattern = Pattern.compile(\"\\\\w+(\\\\.?\\\\w+)*\");\n\t\t\t\t\t\t\tMatcher matcher = pattern.matcher(docTEXT.toLowerCase());\n\t\t\t\t\t\t\twhile (matcher.find()) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tfor (int i = 0; i < matcher.groupCount(); i++) {\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t// alltermHash contains term and term id\n\t\t\t\t\t\t\t\t\t// if term is present in the alltermHash\n\t\t\t\t\t\t\t\t\tif(allTermHash.containsKey(matcher.group(i))){\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tint termId = allTermHash.get(matcher.group(i));\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t//if term is present in the token1000Hash\n\t\t\t\t\t\t\t\t\t\t//then update the dblock of the term.\n\t\t\t\t\t\t\t\t\t\tif(token1000DocHash.containsKey(termId)){\n\t\t\t\t\t\t\t\t\t\t\tMultimap<String, String> dBlockUpdate = token1000DocHash.get(termId);\n\t\t\t\t\t\t\t\t\t\t\t//Multimap<Integer, Integer> dBlockUpdate = token1000DocHash.get(matcher.group(i));\n\t\t\t\t\t\t\t\t\t\t\tif(dBlockUpdate.containsKey(id)){\n\t\t\t\t\t\t\t\t\t\t\t\tdBlockUpdate.put(String.valueOf(id), String.valueOf(matcher.start()));\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\telse{\n\t\t\t\t\t\t\t\t\t\t\t\tdBlockUpdate.put(String.valueOf(id), String.valueOf(matcher.start()));\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t//if term is not present in the token1000hash\n\t\t\t\t\t\t\t\t\t\t//then add the token with its dBlock\n\t\t\t\t\t\t\t\t\t\telse{\n\t\t\t\t\t\t\t\t\t\t\tMultimap<String, String> dBlockInsert = ArrayListMultimap.create();\n\t\t\t\t\t\t\t\t\t\t\tdBlockInsert.put(String.valueOf(id), String.valueOf(matcher.start()));\n\t\t\t\t\t\t\t\t\t\t\ttoken1000DocHash.put(termId, dBlockInsert);\t\n\t\t\t\t\t\t\t\t\t\t}\t\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t// if the term is not present I will put the term into allTermHash\n\t\t\t\t\t\t\t\t\t// put corresponding value into the token1000DocHash and increment\n\t\t\t\t\t\t\t\t\t// termIndex\n\t\t\t\t\t\t\t\t\telse{\n\t\t\t\t\t\t\t\t\t\tallTermHash.put(matcher.group(i),termIndex);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tMultimap<String, String> dBlockInsert = ArrayListMultimap.create();\n\t\t\t\t\t\t\t\t\t\tdBlockInsert.put(String.valueOf(id), String.valueOf(matcher.start()));\n\t\t\t\t\t\t\t\t\t\ttoken1000DocHash.put(termIndex, dBlockInsert);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\ttermIndex++;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tdocLength++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif(id%1000 == 0){\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t// then dump index file to HDD\n\t\t\t\t\t\t\t\t\twriteInvertedIndex(token1000DocHash,\"token1000DocHash\");\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t// update catalog file\n\t\t\t\t\t\t\t\t\t// to populate catalogHash with the offset\n\t\t\t\t\t\t\t\t\tfor(Entry<Integer, Multimap> entry : token1000DocHash.entrySet()){\n\t\t\t\t\t\t\t\t\t\tif(catalogHash.containsKey(entry.getKey())){\n\t\t\t\t\t\t\t\t\t\t\tint len = (entry.getKey()+\":\"+entry.getValue()).length();\n\t\t\t\t\t\t\t\t\t\t\t//String offset = String.valueOf(startOffset)+\":\"+String.valueOf(len);\n\t\t\t\t\t\t\t\t\t\t\tMultimap<String, String> catUpdate = catalogHash.get(entry.getKey());\n\t\t\t\t\t\t\t\t\t\t\tcatUpdate.put(String.valueOf(startOffset), String.valueOf(len));\n\t\t\t\t\t\t\t\t\t\t\tcatalogHash.put(entry.getKey(), catUpdate);\n\t\t\t\t\t\t\t\t\t\t\tstartOffset += len+2;\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse{\n\t\t\t\t\t\t\t\t\t\t\tint len = (entry.getKey()+\":\"+entry.getValue()).length();\n\t\t\t\t\t\t\t\t\t\t\t//String offset = String.valueOf(startOffset)+\":\"+String.valueOf(len);\n\t\t\t\t\t\t\t\t\t\t\tMultimap<String, String> catInsert = ArrayListMultimap.create();\n\t\t\t\t\t\t\t\t\t\t\tcatInsert.put(String.valueOf(startOffset), String.valueOf(len));\n\t\t\t\t\t\t\t\t\t\t\tcatalogHash.put(entry.getKey(), catInsert);//entry.getValue());\n\t\t\t\t\t\t\t\t\t\t\tstartOffset += len+2;\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//clear the token1000DocHash\n\t\t\t\t\t\t\t\t\ttoken1000DocHash.clear();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tdocumentHash.put(docID, \"\"+id+\":\"+docLength);\n\t\t\t\t\t\t\tid++;\n\t\t\t\t\t\t\ttext = new StringBuffer();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if(line.contains(\"<DOCNO>\")){\n\t\t\t\t\t\t\t++docNumber;\n\t\t\t\t\t\t\tdocID = line.substring(8, 21);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if(line.contains(\"<TEXT>\")){\n\t\t\t\t\t\t\t++textCount;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if((line.contains(\"<DOC>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"</DOC>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<DOCNO>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<FILEID>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<FIRST>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<SECOND>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<HEAD>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"</HEAD>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<BYLINE>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"</BYLINE>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<UNK>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"</UNK>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<DATELINE>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<NOTE>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"</NOTE>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"</TEXT>\"))||\n\t\t\t\t\t\t\t\t(line.contains(\"<TEXT>\"))){\n\t\t\t\t\t\t\t ++noText;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if(endDoc == docCount - 1){\n\t\t\t\t\t\t\ttext.append(line);\n\t\t\t\t\t\t\ttext.append(\" \");\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t \t\n\t\t\t }//end of if - to check if this is a file and parse.\n\t\t\t \n\t\t\t}//end of for loop to load each file\n\t\t\t\n\t\t//}//end of while loop \n\t\t\n\t// write catalogfile to the hdd to check.\n\t\t\t\n\t\t\t// then dump index file to HDD\n\t\t\twriteInvertedIndex(token1000DocHash,\"token1000DocHash\");\n\t\t\t\n\t\t\t// update catalog file\n\t\t\t// to populate catalogHash with the offset\n\t\t\tfor(Entry<Integer, Multimap> entry : token1000DocHash.entrySet()){\n\t\t\t\tif(catalogHash.containsKey(entry.getKey())){\n\t\t\t\t\tint len = (entry.getKey()+\":\"+entry.getValue()).length();\n\t\t\t\t\t//String offset = String.valueOf(startOffset)+\":\"+String.valueOf(len);\n\t\t\t\t\tMultimap<String, String> catUpdate = catalogHash.get(entry.getKey());\n\t\t\t\t\tcatUpdate.put(String.valueOf(startOffset), String.valueOf(len));\n\t\t\t\t\tcatalogHash.put(entry.getKey(), catUpdate);\n\t\t\t\t\tstartOffset += len+2;\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tint len = (entry.getKey()+\":\"+entry.getValue()).length();\n\t\t\t\t\t//String offset = String.valueOf(startOffset)+\":\"+String.valueOf(len);\n\t\t\t\t\tMultimap<String, String> catInsert = ArrayListMultimap.create();\n\t\t\t\t\tcatInsert.put(String.valueOf(startOffset), String.valueOf(len));\n\t\t\t\t\tcatalogHash.put(entry.getKey(), catInsert);//entry.getValue());\n\t\t\t\t\tstartOffset += len+2;\n\t\t\t\t\t\n\t\t\t\t}\t\t\t\t\t\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\twriteInvertedIndex(catalogHash,\"catalogHash\");\n\t\t\tprintHashMapSI(allTermHash);\n\t\t\tprintHashMapSS(documentHash);\n\t\t\t\n\t\t\tlong InvIndstartOffset = 0;\n\t\t\t\n\t\t\t//write it to file\n \n\t\t\t//change the finalcatalogHash to the form termid:startoffset:length\n\t\t\tfor (Integer name: catalogHash.keySet()){\n\t String key = name.toString();\n\t String value = catalogHash.get(name).toString(); \n\t //System.out.println(key + \" \" + value); \n\t String finalTermIndex = genInvertedIndex(key, value);\n\t finalTermIndex = key+\":\"+finalTermIndex;\n\t int indexLength = finalTermIndex.length();\n\t \n\t \n\t PrintWriter writer = new PrintWriter(new BufferedWriter\n\t \t\t(new FileWriter(\"C:/Users/Naveen/Desktop/TestRuns/LastRun/InvertedIndex\", true)));\n\t writer.println(finalTermIndex);\n\t writer.close();\n\t \n\t //update the finalcatalogHash\n\t //Multimap<String, String> catInsert = ArrayListMultimap.create();\n\t\t\t\t//catInsert.put(String.valueOf(InvIndstartOffset), String.valueOf(indexLength));\n\t\t\t\tfinalCatalogHash.put(name, String.valueOf(InvIndstartOffset)+\":\"+String.valueOf(indexLength));//entry.getValue());\n\t\t\t\tInvIndstartOffset += indexLength+2;\n\t \n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\tprintHashMapIS(finalCatalogHash);\n\t\t\t\n\t}",
"boolean saveDocument(String path, String documentContent, Charset charset, List <String> moduleList);",
"public static List<String> parseDocument(Path file) throws IOException {\n List<String> words = new ArrayList<>();\n try (BufferedReader br = Files.newBufferedReader(file)) {\n String line;\n while ((line = br.readLine()) != null) {\n char[] characters = line.trim().toCharArray();\n int startPosition = -1;\n for (int i = 0; i < characters.length; i++) {\n char c = characters[i];\n if (!Character.isAlphabetic(c)) {\n if (startPosition == -1) {\n continue;\n }\n words.add(new String(characters, startPosition, i - startPosition).toLowerCase());\n startPosition = -1;\n } else if (Character.isAlphabetic(c) && startPosition == -1) {\n startPosition = i;\n }\n }\n if (startPosition != -1) {\n words.add(new String(characters, startPosition, characters.length - startPosition).toLowerCase());\n }\n }\n }\n return words;\n }",
"void addWordsToDoc(int doc,List<VocabWord> words);",
"@Test\n public void testNullStylesInODTFooter() throws Exception {\n Parser parser = new OpenDocumentParser();\n try (InputStream input = getResourceAsStream(\"/test-documents/testODT-TIKA-6000.odt\")) {\n Metadata metadata = new Metadata();\n ContentHandler handler = new BodyContentHandler();\n parser.parse(input, handler, metadata, getNonRecursingParseContext());\n\n assertEquals(\"application/vnd.oasis.opendocument.text\",\n metadata.get(Metadata.CONTENT_TYPE));\n\n String content = handler.toString();\n\n assertContains(\"Utilisation de ce document\", content);\n assertContains(\"Copyright and License\", content);\n assertContains(\"Changer la langue\", content);\n assertContains(\"La page d’accueil permet de faire une recherche simple\", content);\n }\n }",
"private int addDoc(IndexWriter w, String url, File file) throws IOException, IllegalArgumentException {\n\t\t\n\t\t//TODO: needs to be able to parse HTML pages here\n\t\t//File parsing\n\t\torg.jsoup.nodes.Document html = Jsoup.parse(String.join(\"\",Files.readAllLines(file.toPath())));\n\t\t\n\t\t//If we cant parse the html\n\t\tif(html == null)\n\t\t\treturn -1;\n\t\t\n\t\t\n\t\tif(PRINT_CONTENT_STRING)\n\t\t\tSystem.out.println(\"***This is the body***\\n\" + String.join(\"\",Files.readAllLines(file.toPath())));\n\t\t\n\t\tif(PRINT_CONTENT_BODY)\n\t\t\tSystem.out.println(\"***This is the body***\\n\" + html.body());\n\t\t\n\t\tString content = null;\n\t\tElement body = html.body();\n\t\t\n\t\t//Get the rest of the text in the body\n\t\tif(body != null)\n\t\t\tcontent = body.text();\n\t\t\n\t\tif(PRINT_CONTENT_TEXT)\n\t\t\tSystem.out.println(\"***This is the BODY text***\\n\" + content);\n\n\t\tString title = null;\n\t\tElement head = html.head();\n\t\tif(head != null)\n\t\t\ttitle = head.text();\n\t\t\n\t\tif(PRINT_CONTENT_TEXT)\n\t\t\tSystem.out.println(\"***This is the TITLE***\\n\" + title);\n\t\t\t\t\n\t\t//Document Creation\n\t\tDocument doc = new Document();\n\t\tField field = null;\n\t\tFieldType type = new FieldType();\n\t\ttype.setIndexOptions(IndexOptions.DOCS_AND_FREQS_AND_POSITIONS);\n\t\ttype.setStored(true); \n\t\ttype.setStoreTermVectors(true);\n\t\ttype.setTokenized(true);\n\t\t\n\t\t//If there is text in the head, it is probably a title\n\t\tif(title != null && !title.isEmpty()){\n\t\t\tfield = new Field(\"title\", title, type);\n\t\t\tfield.setBoost(15); //Set weight for the field when query matches to string in field here\n\t\t\tdoc.add(field);\n\t\t}\n\t\t\n\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\tSystem.out.println(\"This is title: \" + title);\n\n\t\t//Grab the important text tags\n\t\tElements importantTags = body.select(\"b, strong, em\");\n\n\t\tif(importantTags != null && !importantTags.isEmpty())\n\t\t{\n\t\t\tfield = new Field(\"important\", importantTags.html(), type);\n\t\t\t\n\t\t\t//Setting the bold tag boost\n\t\t\tfield.setBoost(1); \n\t\t\tdoc.add(field);\n\t\t\t\n\t\t\t//We remove any content in these tags so there is no duplicate counting\n\t\t\timportantTags.remove();\n\t\t}\n\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\tSystem.out.println(\"This is Bolding: \" + importantTags.text());\n\n\t\t\n\t\t//Grab all heading tags\n\t\tElements headingTags = body.select(\"h1, h2, h3, h4, h5, h6\");\n\n\t\tfor(int headingNum = 0; headingNum < 6; headingNum++)\n\t\t{\n\t\t\t//Attempt to index all the heading tags\n\t\t\tElements hTags = headingTags.select(\"h\" + (headingNum + 1));\n\t\t\tif(hTags != null && !hTags.isEmpty())\n\t\t\t{\n\t\t\t\tfield = new Field(\"heading\" + headingNum, hTags.html(), type);\n\t\t\t\t\n\t\t\t\t//Setting the heading tag boost\n\t\t\t\tfield.setBoost(5); \n\t\t\t\tdoc.add(field);\n\t\t\t\t\n\t\t\t\t//We remove any content in these tags so there is no duplicate counting\n\t\t\t\thTags.remove();\n\t\t\t}\n\t\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\t\tSystem.out.println(\"This is heading: \" + headingNum + \" - \" + hTags.text());\n\n\t\t}\n\t\t\n\t\t//Need to parse the remaining content after all the important tags have been deleted \n\t\tif(content != null && !content.isEmpty()){\n\t\t\tfield = new Field(\"content\", content, type);\n\t\t\t\n\t\t\t//Setting the default boost\n\t\t\tfield.setBoost(1); \n\t\t\tdoc.add(field);\n\t\t}\n\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\tSystem.out.println(\"This is content: \" + content);\n\n\t\t//Need to make sure we have content before attempting to add a link to a document\n\t\tif(doc.getFields().size() > 0)\n\t\t{\n\t\t\t//fileID field should not be used for finding terms within document, only for uniquely identifying this doc amongst others in index\n\t\t\ttype = new FieldType();\n\t\t\ttype.setStored(true);\n\t\t\ttype.setTokenized(false);\n\t\t\ttype.setStoreTermVectors(false);\n\t\t\tdoc.add(new Field(\"url\", url, type));\n\t\t\t\n\t\t\tw.addDocument(doc);\n\t\t\t\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\treturn -1;\n\t}",
"@Override\n\tpublic void openDocument(String path, String name) {\n\t\t\n\t}",
"private boolean fileIsInTextFormat(byte[] fileBytesToVerify) {\r\n\r\n\t\tboolean isOk = false;\r\n\t\tTika tka = new Tika();\r\n\t\t\r\n\t\tisOk = tka.detect(fileBytesToVerify).equalsIgnoreCase(\"text/html\");\r\n\r\n\t\tif (this.debug) {\r\n\t\t\tprintln(isOk + \" found in fileIsInTextFormat in TextToAudioFile\");\r\n\t\t\tprintln(\"Contents of text file returned...\");\r\n\t\t\ttry {\r\n\t\t\t\tprintln(new String(fileBytesToVerify, \"UTF-8\"));\r\n\t\t\t} catch (UnsupportedEncodingException e) {\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn isOk;\r\n\t}",
"@SuppressWarnings(\"static-access\")\n\tpublic void detection(Request text) {\n\t\t//Fichiertxt fichier;\n\t\ttry {\t\t\t\t\t\n\t\t\t//enregistrement et affichage de la langue dans une variable lang\n\t\t\ttext.setLang(identifyLanguage(text.getCorpText()));\n\t\t\t//Ajoute le fichier traité dans la Base\n\t\t\tajouterTexte(text);\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"fichier texte non trouvé\");\n\t e.printStackTrace();\n\t\t}\n\t}",
"public void crearReporte() {\r\n\t\tJFileChooser chooser = new JFileChooser(\"reporte.doc\");\r\n\t\tchooser.addChoosableFileFilter(new FileFilter() {\r\n\t\t\t\r\n\t\t\t@Override\r\n\t\t\tpublic String getDescription() {\r\n\t\t\t\treturn \"*.doc\";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t@Override\r\n\t\t\tpublic boolean accept(File f) {\r\n\t\t\t\t if (f.isDirectory())\r\n\t\t {\r\n\t\t return false;\r\n\t\t }\r\n\r\n\t\t String s = f.getName();\r\n\r\n\t\t return s.endsWith(\".doc\");\r\n\t\t\t}\r\n\t\t});\r\n\t\tint res = chooser.showSaveDialog(this);\r\n\t\tif(res == JFileChooser.APPROVE_OPTION)\r\n\t\t{\r\n\t\t\tFile file = chooser.getSelectedFile();\r\n\t\t\t\r\n\t\t\t@SuppressWarnings(\"unused\")\r\n\t\t\tJava2Word word = new Java2Word(this, file);\r\n\t\t}\r\n\t\t\r\n\t}",
"private void browseTemplateActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_browseTemplateActionPerformed\n JFileChooser chooser = new JFileChooser();\n FileNameExtensionFilter filter = new FileNameExtensionFilter(\"Word document\", new String[]{\"doc\", \"docx\"});\n chooser.setFileFilter(filter);\n chooser.setCurrentDirectory(new java.io.File(\".\"));\n chooser.setDialogTitle(\"Select a file\");\n chooser.setFileSelectionMode(JFileChooser.FILES_AND_DIRECTORIES);\n chooser.setAcceptAllFileFilterUsed(false);\n\n if (chooser.showOpenDialog(null) == JFileChooser.APPROVE_OPTION) {\n templateDoc.setText(chooser.getSelectedFile().getPath());\n }\n }",
"public void read(String filename) throws IOException {\n // open the file\n BufferedReader r = new BufferedReader(new FileReader(filename));\n\n // load the number of terms\n int size = Integer.parseInt(r.readLine());\n\n // must divide by load factor (0.75) to not need to rehash\n index = new HashMap((int) (size / .75) + 1);\n\n // temporary variables\n String line;\n StringTokenizer tokens;\n String word;\n HashMap docList;\n String docid;\n int[] fArray;\n int lineNumber = 1;\n\n // while there are more lines in the document\n while ((line = r.readLine()) != null) {\n // increment the line number\n lineNumber++;\n\n // the word is the only thing on the line\n word = line;\n\n // load all documents containign this term\n docList = new HashMap();\n index.put(word, docList);\n\n line = r.readLine();\n while (line != null && !line.equals(\"\")) {\n fArray = new int[1];\n\n docid = line;\n fArray[0] = Integer.parseInt(r.readLine());\n\n docList.put(docid, fArray);\n line = r.readLine();\n }\n }\n\n // close the file\n r.close();\n }",
"public static void main(String[] args) throws IOException {\r\n\t\tInputStreamReader isr = null;\r\n\t\tBufferedReader br = null;\r\n\t\tInputStream is = new ByteArrayInputStream(\"C:\\\\Users\\\\Amit\\\\Desktop\\\\AMIT KUMAR PRADHAN.docx\".getBytes());\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\tString content;\r\n\t\ttry {\r\n\t\t\tisr = new InputStreamReader(is);\r\n\t\t\tbr = new BufferedReader(isr);\r\n\t\t\twhile ((content = br.readLine()) != null) {\r\n\t\t\t\tsb.append(content);\r\n\t\t\t}\r\n\t\t} catch (IOException ioe) {\r\n\t\t\tSystem.out.println(\"IO Exception occurred\");\r\n\t\t\tioe.printStackTrace();\r\n\t\t} finally {\r\n\t\t\tisr.close();\r\n\t\t\tbr.close();\r\n\t\t}\r\n\t\tString mystring = sb.toString();\r\n\t\tSystem.out.println(mystring);\r\n\t}",
"protected boolean isTextFile(File pathname) {\n\t\treturn false;\n\t}",
"public void processDocument() {\n\n\t\t// compact concepts\n\t\tprocessConcepts(concepts);\n\t}",
"public String getDescription() {\n return \"Text file (.text)\";\n }",
"public void configureWord() {\n }",
"protocol.VersionedTextDocumentIdentifier getTextDocument();",
"@Override\n public void textFileLoaded(File file, int wc, String contents)\n {\n cur_file = file;\n this.action_panel.setWordCount(wc);\n \n new Thread(new MarkdownProcessor(file, this)).start();\n }",
"abstract public TermDocs termDocs(Term t) throws IOException;",
"public static void main(String args[]) throws Exception {\n\t String filePath = \"test.pdf\";\r\n\t \r\n\t String pdfText = FileReader.getFile(filePath, 581, 584); \r\n\t text_position.position(580, 584);\r\n\t \r\n//\t String pdfText = FileReader.getFile(filePath, 396, 407); \r\n//\t text_position.position(395, 407);\r\n\r\n\t txtCreate.creatTxtFile(\"test\");\r\n\t txtCreate.writeTxtFile(pdfText);\r\n\t xmlCreater.getXML(\"test.txt\");\r\n }",
"public static void main(String[] args)\r\n\t{\n\t\tacceptConfig();\r\n\t\treadDictionary();\r\n\t\t//Then, it reads the input file and it prints the word (if contained on the file) or the suggestions\r\n\t\t//(if not contained) in the output file. These files are given by command line arguments\r\n\t\tprocessFile(args[0], args[1]);\r\n\t\t\r\n\t}",
"public static void TextFromFile(JTextPane tp)\n \t {\n try{\n //the file path\n String path = \"readMe.md\";\n File file = new File(path);\n FileReader fr = new FileReader(file);\n while(fr.read() != -1){\n tp.read(fr,null);\n }\n fr.close();\n } catch(Exception ex){\n ex.printStackTrace();\n }\n }",
"@RequestMapping(value = \"/search-in-doc/{id}\", \n\t\t\t\t\tmethod = RequestMethod.GET)\n\tpublic ResponseEntity<?> searchInDoc(@PathVariable(\"id\") String id, \n\t\t\t\t\t\t\t\t\t\t\t @RequestParam(value = \"word\", required = true) String word) throws IOException {\n\n\t\tboolean foundFile = false; // denota si el archivo fue encontrado\n\t\t\n\t\tString pageToken = null;\n\t\tdo { // proceso de busqueda\n\t\t\tFileList result = DriveConnection.driveService.files().list() \n\t\t\t\t .setSpaces(\"drive\")\n\t\t\t .setFields(\"nextPageToken, files(id)\") \n\t\t\t .setPageToken(pageToken)\n\t\t\t .execute();\n\t\t\n\t\t\t\t for (File file : result.getFiles()) { \n\t\t\t\t\t if (file.getId().equals(id)) {\n\t\t\t\t\t\t\tfoundFile = true;\n\t\t\t\t\t }\n\t\t\t\t }\n\t\t\t\t \n\t\t\t pageToken = result.getNextPageToken();\n\t\t} while (pageToken != null);\n\t\t\n\t\tif (foundFile) {\n\t\t\t\n\t\t\tFile content = DriveConnection.driveService.files().get(id).execute();\t\n\t\t\tcontent.toString().contains(word);\t\n\t\t\treturn new ResponseEntity<>(\"Found\", HttpStatus.OK); // mostramos rpta en consola\n\t\t\t\t\n\t\t} else {\t\n\t\t\t\n\t\t\treturn new ResponseEntity<>(\"Not found\", HttpStatus.NOT_FOUND); // mostramos rpta en consola\n\t\t\t\n\t\t}\n\t\n\t}",
"public void docDataPreProcess(String xmlFileDir) throws Exception {\n XmlFileCollection corpus = new XmlFileCollection(xmlFileDir);\n\n // Load stopword list and initiate the StopWordRemover and WordNormalizer\n StopwordRemover stopwordRemover = new StopwordRemover();\n WordNormalizer wordNormalizer = new WordNormalizer();\n\n // initiate the BufferedWriter to output result\n FilePathGenerator fpg = new FilePathGenerator(\"result.txt\");\n String path = fpg.getPath();\n\n FileWriter fileWriter = new FileWriter(path, true); // Path.ResultAssignment1\n Map<String, String> curr_docs = corpus.nextDoc(); // doc_id:doc_content pairs\n Set<String> doc_ids = curr_docs.keySet();\n for (String doc_id : doc_ids){\n // load doc content\n char[] content = curr_docs.get(doc_id).toCharArray();\n // write doc_id into the result file\n fileWriter.append(doc_id + \"\\n\");\n\n // initiate a word object to hold a word\n char[] word = null;\n\n // initiate the WordTokenizer\n WordTokenizer tokenizer = new WordTokenizer(content);\n\n // process the doc word by word iteratively\n while ((word = tokenizer.nextWord()) != null){\n word = wordNormalizer.lowercase(word);\n// if (word.length == 1 && Character.isAlphabetic(word[0])){\n// continue;\n// }\n String wordStr = String.valueOf(word);\n // write only non-stopword into result file\n if (!stopwordRemover.isStopword(wordStr)){\n// fileWriter.append(wordNormalizer.toStem(word) + \" \");\n fileWriter.append(wordStr).append(\" \");\n }\n }\n fileWriter.append(\"\\n\");\n }\n fileWriter.close();\n }",
"public static boolean isTextFile(String file) {\r\n return true;\r\n }",
"protected void checkText(ParserResult result, String text) {\n\t\tif (text == null)\n\t\t\treturn;\n\t\tfor (Map<String, List<Object>> map : result.documents)\n\t\t\tif (checkText(map, text))\n\t\t\t\treturn;\n\t\tif (checkText(result.metas, text))\n\t\t\treturn;\n\t\tlogger.severe(\"Text \" + text + \" not found\");\n\t\tassert (false);\n\t}",
"private void createDOCDocument(String from, File file) throws Exception {\n\t\tPOIFSFileSystem fs = new POIFSFileSystem(Thread.currentThread().getClass().getResourceAsStream(\"/poi/template.doc\"));\n\t\tHWPFDocument doc = new HWPFDocument(fs);\n\t\n\t\tRange range = doc.getRange();\n\t\tParagraph par1 = range.getParagraph(0);\n\t\n\t\tCharacterRun run1 = par1.insertBefore(from, new CharacterProperties());\n\t\trun1.setFontSize(11);\n\t\tdoc.write(new FileOutputStream(file));\n\t}",
"public static void openDocument(Context context, String strFilePath, String strFileType) {\n try {\n File file = new File(strFilePath);\n Intent intent = new Intent(Intent.ACTION_VIEW);\n /* if (strFileType.equals(\"pdf\")) {\n intent.setDataAndType(Uri.fromFile(file), \"application/pdf\");\n } else if (strFileType.equals(\"doc\") || strFileType.equals(\"docx\")) {\n MimeTypeMap myMime = MimeTypeMap.getSingleton();\n String mimeType = myMime.getMimeTypeFromExtension(strFilePath);\n intent.setDataAndType(Uri.fromFile(file), mimeType);\n } else {\n intent.setDataAndType(Uri.fromFile(file), \"application/*\");\n }*/\n intent.setDataAndType(Uri.fromFile(file), \"application/*\");\n intent.setFlags(Intent.FLAG_ACTIVITY_NO_HISTORY);\n context.startActivity(intent);\n } catch (ActivityNotFoundException activityNotFoundException) {\n activityNotFoundException.printStackTrace();\n throw activityNotFoundException;\n } catch (Exception otherException) {\n otherException.printStackTrace();\n throw otherException;\n }\n }",
"@Override\r\n protected void parseDocuments()\r\n {\n\r\n }",
"public static void main(String[] args) {\n\n\t\tString docBody = null;\n\t\t\n\t\ttry {\n\t\t\tdocBody = new String(Files.readAllBytes(Paths.get(\"examples/doc1.txt\")), StandardCharsets.UTF_8);\n\t\t} catch (IOException e1) {\n\t\t\tSystem.exit(1);\n\t\t}\n\n\t\tSmartScriptParser parser = null;\n\t\t\n\t\ttry {\n\t\t\tparser = new SmartScriptParser(docBody);\n\t\t} catch (SmartScriptParserException e) {\n\t\t\tSystem.out.println(\"Unable to parse document!\");\n\t\t\tSystem.exit(-1);\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"If this line ever executes, you have failed this class!\");\n\t\t\tSystem.exit(-1);\n\t\t}\n\t\t\n\t\tDocumentNode document = parser.getDocumentNode();\n\t\tString originalDocumentBody = createOriginalDocumentBody(document);\n\t\tSystem.out.println(originalDocumentBody); \n\t\t\n\t\tSystem.out.println(\"==============\");\n\t\t\n\t\tSmartScriptParser parser2 = new SmartScriptParser(originalDocumentBody);\n\t\tDocumentNode document2 = parser2.getDocumentNode();\n\t\tString originalDocumentBody2 = createOriginalDocumentBody(document2);\n\t\tSystem.out.println(originalDocumentBody2);\n\t\t\n\t\tSystem.out.println(\"==============\");\n\t\t\n\t\tSystem.out.println(\"Documents are equal: \" + originalDocumentBody.equals(originalDocumentBody2));\n\n\t}",
"public static void main(String[] args) {\n\t\tif (args.length != 1) {\n\t\t\tSystem.out.println(\"Broj argumenata naredbenog retka mora biti 1.\");\n\t\t\tSystem.exit(-1);\n\t\t}\n\t\t\n\t\tString filepath = args[0];\n\t\tString docBody = \"\";\n\t\t\n\t\ttry {\n\t\t\tdocBody = new String(Files.readAllBytes(Paths.get(filepath)), StandardCharsets.UTF_8);\n\t\t} catch (IOException e1) {\n\t\t\te1.printStackTrace();\n\t\t\tSystem.exit(-1);\n\t\t}\n\t\t\n\t\tSmartScriptParser parser = null;\n\t\t\n\t\ttry {\n\t\t\tparser = new SmartScriptParser(docBody);\n\t\t} catch(SmartScriptParserException e) {\n\t\t\tSystem.out.println(\"Unable to parse document!\");\n\t\t\tSystem.exit(-1);\n\t\t} catch(Exception e) {\n\t\t\tSystem.out.println(\"If this line ever executes, you have failed this class!\");\n\t\t\tSystem.exit(-1);\n\t\t}\n\t\t\n\t\tDocumentNode document = parser.getDocumentNode();\n\t\tString originalDocumentBody = createOriginalDocumentBody(document);\n\t\tSystem.out.println(originalDocumentBody);\n\t\t\n\t\tSmartScriptParser parser2 = new SmartScriptParser(originalDocumentBody);\n\t\tDocumentNode document2 = parser2.getDocumentNode();\n\t\tString originalDocumentBodySecond = createOriginalDocumentBody(document2);\n\t\t\n\t\tif (originalDocumentBody.equals(originalDocumentBodySecond)) {\n\t\t\tSystem.out.println(\"Identični\");\n\t\t}\n\t}",
"public static void main(String[] args) throws ParseException {\n String text;\n\n File file;\n\n /* pdfStripper = null;\n pdDoc = null;\n cosDoc = null;\n */ String parsed = parseWithTika();\n file = new File(filePath);\n try {\n /* parser = new PDFParser(new FileInputStream(file)); // update for PDFBox V 2.0\n parser.parse();\n cosDoc = parser.getDocument();\n pdfStripper = new PDFTextStripper();\n pdDoc = new PDDocument(cosDoc);\n pdDoc.getNumberOfPages();\n */ //pdfStripper.setStartPage(1);\n //pdfStripper.setEndPage(10);\n /* text = pdfStripper.getText(pdDoc);\n String resultString = text.replaceAll(\"\\\\p{C}|\\\\p{Sm}|\\\\p{Sk}|\\\\p{So}\", \" \");\n */\n\n //testDictionary();\n testOpenNlp(parsed);\n testOpenNlp(\"anas al bassit\");\n testOpenNlp(\"Anas Al Bassit\");\n testOpenNlp(\"barack obama\");\n testOpenNlp(\"Barack Obama\");\n\n\n System.out.println();\n } catch (IOException e) {\n e.printStackTrace();\n }\n// catch (ParseException e) {\n// e.printStackTrace();\n// }\n }",
"public void addText(IText text) {\n var name = \"Text\"; // TODO should texts have a name? E.g. the filename etc.?\n var textIndividual = ontologyConnector.addIndividualToClass(name, textClass);\n var uuid = ontologyConnector.getLocalName(textIndividual);\n ontologyConnector.addPropertyToIndividual(textIndividual, uuidProperty, uuid);\n\n ImmutableList<IWord> words = text.getWords();\n\n // first add all word individuals\n var wordIndividuals = new ArrayList<Individual>();\n var wordsToIndividuals = new HashMap<IWord, Individual>();\n for (var word : words) {\n var wordIndividual = addWord(word);\n wordIndividuals.add(wordIndividual);\n wordsToIndividuals.put(word, wordIndividual);\n }\n\n // add dependencies to words.\n // We only add outgoing dependencies as ingoing are the same (but viewed from another perspective)\n for (var word : words) {\n var wordIndividual = wordsToIndividuals.get(word);\n for (var dependencyType : DependencyTag.values()) {\n var outDependencies = word.getWordsThatAreDependencyOfThis(dependencyType);\n for (var outDep : outDependencies) {\n var outWordIndividual = wordsToIndividuals.get(outDep);\n addDependencyBetweenWords(wordIndividual, dependencyType, outWordIndividual);\n }\n }\n }\n\n // create the list that is used for the words property\n var olo = ontologyConnector.addList(\"WordsOf\" + name, wordIndividuals);\n var listIndividual = olo.getListIndividual();\n ontologyConnector.addPropertyToIndividual(textIndividual, wordsProperty, listIndividual);\n\n // add coref stuff\n var corefClusters = text.getCorefClusters();\n for (var corefCluster : corefClusters) {\n var representativeMention = corefCluster.getRepresentativeMention();\n var corefClusterIndividual = ontologyConnector.addIndividualToClass(representativeMention, corefClusterClass);\n ontologyConnector.addPropertyToIndividual(corefClusterIndividual, uuidProperty, \"\" + corefCluster.getId());\n ontologyConnector.addPropertyToIndividual(corefClusterIndividual, representativeMentionProperty, representativeMention);\n ontologyConnector.addPropertyToIndividual(textIndividual, hasCorefClusterProperty, corefClusterIndividual);\n\n var counter = 0;\n for (var mention : corefCluster.getMentions()) {\n var id = corefCluster.getId() + \"_\" + counter;\n counter += 1;\n var label = ICorefCluster.getTextForMention(mention);\n\n var mentionIndividual = ontologyConnector.addIndividualToClass(label, corefMentionClass);\n ontologyConnector.addPropertyToIndividual(mentionIndividual, uuidProperty, id);\n ontologyConnector.addPropertyToIndividual(corefClusterIndividual, mentionProperty, mentionIndividual);\n\n var mentionWordsIndividuals = getMentionWordIndividuals(mention, wordsToIndividuals);\n var mentionOlo = ontologyConnector.addList(\"WordsOf Mention \" + id, mentionWordsIndividuals);\n ontologyConnector.addPropertyToIndividual(mentionIndividual, wordsProperty, mentionOlo.getListIndividual());\n }\n }\n\n }",
"public void testGetSimpleText() throws Exception {\n \t\tnew XWPFWordExtractor(xmlA);\n \t\tnew XWPFWordExtractor(POIXMLDocument.openPackage(fileA.toString()));\n \t\t\n \t\tXWPFWordExtractor extractor = \n \t\t\tnew XWPFWordExtractor(xmlA);\n \t\textractor.getText();\n \t\t\n \t\tString text = extractor.getText();\n \t\tassertTrue(text.length() > 0);\n \t\t\n \t\t// Check contents\n \t\tassertTrue(text.startsWith(\n \t\t\t\t\"Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nunc at risus vel erat tempus posuere. Aenean non ante. Suspendisse vehicula dolor sit amet odio.\"\n \t\t));\n \t\tassertTrue(text.endsWith(\n \t\t\t\t\"Phasellus ultricies mi nec leo. Sed tempus. In sit amet lorem at velit faucibus vestibulum.\\n\"\n \t\t));\n \t\t\n \t\t// Check number of paragraphs\n \t\tint ps = 0;\n \t\tchar[] t = text.toCharArray();\n \t\tfor (int i = 0; i < t.length; i++) {\n \t\t\tif(t[i] == '\\n') { ps++; }\n \t\t}\n \t\tassertEquals(3, ps);\n \t}",
"public HotWordsAnalyzer (String hotWordsFileName, String docFileName){\r\n //Setting the filenames to the variables to make them easier to type\r\n doc = docFileName;\r\n hw = hotWordsFileName;\r\n \r\n //If opening of the file fails, an ioException will be thrown\r\n\t\ttry{\r\n hotword = new Scanner(Paths.get(hw));\r\n }\r\n catch (IOException ioException){\r\n System.err.println(\"Error opening file. Terminating.\");\r\n System.exit(1);\r\n }\r\n \r\n try{\r\n \r\n docs = new Scanner(Paths.get(doc));\r\n }\r\n catch (IOException ioException){\r\n System.err.println(\"Error opening file. Terminating.\");\r\n System.exit(1);\r\n }\r\n \r\n //Above opens both files\r\n \r\n //Goes through hotwords file and takes each word and pushes them to \r\n //the map words so they can be used to locate the hotwords in the document\r\n\t\ttry{\r\n while(hotword.hasNext()){\r\n String y;\r\n String x = hotword.next();\r\n y = x.toLowerCase();\r\n //sets hotword as key and 0 for the count of that hotword in the document\r\n words.put(y, 0);\r\n }\r\n }\r\n //The element doesn't exist- file must not be a file\r\n catch(NoSuchElementException elementException){\r\n System.err.println(\"Improper file. Terminating.\");\r\n System.exit(1);\r\n }\r\n //The file may not be readable or corrupt\r\n catch(IllegalStateException stateException){\r\n System.err.println(\"Error reading from file. Terminating.\");\r\n System.exit(1);\r\n }\r\n \r\n //Above gets words and puts them into the words map\r\n try{\r\n //reads the document and when it finds a hotword it increments the count in words\r\n while(docs.hasNext()){\r\n //gets next word\r\n String x = docs.next();\r\n String y = x.toLowerCase();\r\n //Gets rid of the commas and periods\r\n y = y.replace(\",\", \"\");\r\n y = y.replace(\".\", \"\");\r\n //If the word y is in the hotwords list\r\n if(words.containsKey(y)){\r\n //Adds to words map and increments count\r\n consec.add(y);\r\n int z;\r\n z = words.get(y);\r\n z++;\r\n words.put(y, z);\r\n }\r\n }\r\n }\r\n catch(NoSuchElementException elementException){\r\n System.err.println(\"Improper file. Terminating.\");\r\n System.exit(1);\r\n }\r\n catch(IllegalStateException stateException){\r\n System.err.println(\"Error reading from file. Terminating.\");\r\n System.exit(1);\r\n }\r\n \r\n \r\n\t\t\r\n\t}",
"private static interface DefDocumentProcessor\n\t{\n\t\t/**\n\t\t * Called for every element found during processing of the s.t.\n\t\t * path.\n\t\t * @param documentPath an abstract pathname of the document\n\t\t * @throws XMLFormatException if document appears to be corrupted\n\t\t */\n\t\tvoid processElement(File documentPath) \n\t\t\tthrows XMLFormatException;\n\t}",
"void tokenize(TextDocument document, TokenFactory tokens) throws IOException;",
"public void leerDeFichero() {\n try\n {\n Scanner sc = new Scanner(new File(\"texto.txt\"));\n while (sc.hasNextLine() && !textoCompleto())\n addFrase(sc.nextLine());\n sc.close();\n }\n catch (IOException e)\n {\n e.printStackTrace();\n }\n }",
"public static void main(final String[] args)\r\n {\r\n // Set the path to the data files\r\n Dictionary.initialize(\"c:/Program Files/WordNet/2.1/dict\");\r\n \r\n // Get an instance of the Dictionary object\r\n Dictionary dict = Dictionary.getInstance();\r\n \r\n // Declare a filter for all terms starting with \"car\", ignoring case\r\n TermFilter filter = new WildcardFilter(\"car*\", true);\r\n \r\n // Get an iterator to the list of nouns\r\n Iterator<IndexTerm> iter = \r\n dict.getIndexTermIterator(PartOfSpeech.NOUN, 1, filter);\r\n \r\n // Go over the list items\r\n while (iter.hasNext())\r\n {\r\n // Get the next object\r\n IndexTerm term = iter.next();\r\n \r\n // Write out the object\r\n System.out.println(term.toString());\r\n \r\n // Write out the unique pointers for this term\r\n int nNumPtrs = term.getPointerCount();\r\n if (nNumPtrs > 0)\r\n {\r\n // Print out the number of pointers\r\n System.out.println(\"\\nThis term has \" + Integer.toString(nNumPtrs) +\r\n \" pointers\");\r\n \r\n // Print out all of the pointers\r\n String[] ptrs = term.getPointers();\r\n for (int i = 0; i < nNumPtrs; ++i)\r\n {\r\n String p = Pointer.getPointerDescription(term.getPartOfSpeech(), ptrs[i]);\r\n System.out.println(ptrs[i] + \": \" + p);\r\n }\r\n }\r\n \r\n // Get the definitions for this term\r\n int nNumSynsets = term.getSynsetCount();\r\n if (nNumSynsets > 0)\r\n {\r\n // Print out the number of synsets\r\n System.out.println(\"\\nThis term has \" + Integer.toString(nNumSynsets) +\r\n \" synsets\");\r\n \r\n // Print out all of the synsets\r\n Synset[] synsets = term.getSynsets();\r\n for (int i = 0; i < nNumSynsets; ++i)\r\n {\r\n System.out.println(synsets[i].toString());\r\n }\r\n }\r\n }\r\n \r\n System.out.println(\"Demo processing finished.\");\r\n }",
"public boolean addDocument(File srcFile) {\n File destFile = new File(Main.mainObj.projectObj.projectPath + \"/\" + srcFile.getName());\r\n try {\r\n FileUtils.copyFile(srcFile, destFile);\r\n Main.mainObj.projectObj.textFiles.add(new Document(this.projectPath, srcFile.getName()));\r\n } catch (FileNotFoundException ex) {\r\n System.out.println(\"File Not found exception when initializing project\\n\" + ex);\r\n } catch (IOException exept) {\r\n System.out.println(\"IO Exception when initializing a previousl created project\\n\" + exept);\r\n }\r\n return true;\r\n\r\n }",
"private static void ProcessFile(File fileEntry) throws FileNotFoundException {\n \n\t wordCount(fileEntry) ;\n\t\t\n countVowels(fileEntry);\n\t\n\t\t\n}",
"private void loadText() {\n\t\ttext1 = app.loadStrings(\"./data/imports/TXT 1.txt\");\n\t\ttext2 = app.loadStrings(\"./data/imports/TXT 2.txt\");\n\t}",
"public static Document parse(String filename) throws ParserException {\n\t\t// TODO YOU MUST IMPLEMENT THIS\n\t\t// girish - All the code below is mine\n\t\t\t\n\t\t// Creating the object for the new Document\n\t\t\n\t\t\n\t\tif (filename == null){\n\t\t\tthrow new ParserException();\n\t\t}\n\t\t\n\t\t// Variable indexPos to track the current pointer location in the String Array\n\t\tint indexPos = 0;\n\t\t\n\t\t// Creating an instance of the document class to store the parsed content\n\t\tDocument d = new Document();\n\t\t\n\t\t// to store the result sent from the regexAuthor method and regexPlaceDate method\n\t\tObject[] resultAuthor = {null, null, null};\n\t\tObject[] resultPlaceDate = {null, null, null};\n\t\tStringBuilder news = new StringBuilder();\n\t\t\n\t\t// Next 4 lines contains the code to get the fileID and Category metadata\n\t\tString[] fileCat = new String[2];\n\t\t\n\t\tfileCat = regexFileIDCat(\"/((?:[a-z]|-)+)/([0-9]{7})\", filename);\n\t\t// System.out.println(filename);\n\t\t// throw an exception if the file is blank, junk or null\n\t\tif (fileCat[0] == null){\n\t\t\tthrow new ParserException();\n\t\t}\n\t\td.setField(FieldNames.CATEGORY, fileCat[0]);\n\t\td.setField(FieldNames.FILEID, fileCat[1]);\n\t\t\n\t\t\n\t\t// Now , parsing the file\n\t\tFile fileConnection = new File(filename);\n\t\t\n\t\t// newscollated - it will store the parsed file content on a line by line basis\n\t\tArrayList<String> newscollated = new ArrayList<String>();\n\t\t\n\t\t// String that stores the content obtained from the . readline() operation\n\t\tString temp = null;\n\t\t\n\t\ttry\n\t\t{\n\t\t\t\n\t\t\tBufferedReader getInfo = new BufferedReader(new FileReader(fileConnection));\n\t\t\twhile ((temp = getInfo.readLine()) != null)\n\t\t\t{\n\t\t\t\tif(temp.equals(\"\"))\n\t\t\t\t{\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\t\n\t\t\t\t\ttemp = temp + \" \";\n\t\t\t\t\tnewscollated.add(temp);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t\tgetInfo.close();\n\t\t\t\n\t\t\t//-- deprecated (REMOVE THIS IF OTHER WORKS)\n\t\t\t// setting the title using the arraylist's 0th index element\n\t\t\t//d.setField(FieldNames.TITLE, newscollated.get(0));\n\t\t\t\n\t\t\t// Appending the lines into one big string using StringBuilder\n\t\t\t\n\t\t\tfor (String n: newscollated)\n\t\t\t{\n\t\t\t\tnews.append(n);\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t// Obtaining the TITLE of the file\n\t\t\tObject[] titleInfo = new Object[2];\n\t\t\t\n\t\t\ttitleInfo = regexTITLE(\"([^a-z]+)\\\\s{2,}\", news.toString());\n\t\t\td.setField(FieldNames.TITLE, titleInfo[0].toString().trim());\n\t\t\tindexPos = (Integer) titleInfo[1];\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t// Getting the Author and Author Org\n\t\t\tresultAuthor = regexAuthor(\"<AUTHOR>(.*)</AUTHOR>\", news.toString());\n\t\t\t\n\t\t\tif (resultAuthor[0] != null)\n\t\t\t{\n\t\t\t\td.setField(FieldNames.AUTHOR, resultAuthor[0].toString());\n\t\t\t}\n\t\t\t\n\t\t\tif (resultAuthor[1] != null)\n\t\t\t{\n\t\t\t\td.setField(FieldNames.AUTHORORG, resultAuthor[1].toString());\n\t\t\t}\n\t\t \n\t\t \n\t\t \n\t\t if ((Integer) resultAuthor[2] != 0)\n\t\t {\n\t\t \tindexPos = (Integer) resultAuthor[2];\n\t\t }\n\t\t\t\n\t\t \n\t\t \n\t\t // Getting the Place and Date\n \t\t\tresultPlaceDate = regexPlaceDate(\"\\\\s{2,}(.+),\\\\s(?:([A-Z][a-z]+\\\\s[0-9]{1,})\\\\s{1,}-)\", news.toString());\n \t\t\t\n \t\t\tif (resultPlaceDate[0] != null)\n \t\t\t{\n \t\t\t\td.setField(FieldNames.PLACE, resultPlaceDate[0].toString().trim());\n \t\t\t}\n \t\t \n \t\t\tif (resultPlaceDate[1] != null)\n \t\t\t{\n \t\t\t\td.setField(FieldNames.NEWSDATE, resultPlaceDate[1].toString().trim());\n \t\t\t}\n \t\t\t\n \t\t // getting the content\n \t\t \n \t\t if ((Integer) resultPlaceDate[2] != 0)\n\t\t {\n\t\t \tindexPos = (Integer) resultPlaceDate[2];\n\t\t }\n \t\t \n \t\t \n \t\t d.setField(FieldNames.CONTENT, news.substring(indexPos + 1));\n \t\t \n \t\t return d;\n \t\t \n\t\t \n\t\t \n\t\t\t\n\t\t\t\n\t\t}\n\t\tcatch(FileNotFoundException e){\n\t\t\tthrow new ParserException();\n\t\t\t\n\t\t}\n\n\t\tcatch(IOException e){\n\t\t\tthrow new ParserException();\n\t\t}\n\t\t\n\t\tcatch(Exception e){\n\t\t\te.printStackTrace();\n\t\t\t\n\t\t}\n\t\treturn d;\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t}",
"private void inToTrinhv4(HttpServletRequest request, HttpServletResponse reponse, GiaHanForm giaHanForm, ApplicationContext appConText) throws Exception {\r\n\r\n\t\tString fileIn = request.getRealPath(\"/docin/v4\") + \"\\\\TTNB10.doc\";\r\n\t\tString fileOut = request.getRealPath(\"/docout\") + \"\\\\TTNB10_Out\" + System.currentTimeMillis() + request.getSession().getId() + \".doc\";\r\n\r\n\t\tString fileTemplate = null;\r\n\t\tfileTemplate = \"ttnb10\"; // (ngon, chuan)\r\n\t\tString idCuocTtkt = giaHanForm.getIdCuocTtKt();\r\n\t\tTtktKhCuocTtkt cuocTtkt = CuocTtktService.getCuocTtktWithoutNoiDung(appConText, idCuocTtkt);\r\n\r\n\t\tTtktCbQd cbQd = TtktService.getQuyetDinh(idCuocTtkt, appConText);\r\n\t\tString hinhThuc = (cuocTtkt.getHinhThuc().booleanValue()) ? \"ki\\u1EC3m tra\" : \"thanh tra\";\r\n\t\tString hinhthuc_in = (cuocTtkt.getHinhThuc().booleanValue()) ? \"KI\\u1EC2M TRA\" : \"THANH TRA\";\r\n\t\tString hinhthuc_inT = (cuocTtkt.getHinhThuc().booleanValue()) ? \"KT\" : \"TT\";\r\n\t\t//StringBuffer sb = new StringBuffer(\"\\u0110OA\\u0300N\");\r\n\t\t//sb.append(hinhthuc);\r\n\t\tMsWordUtils word = new MsWordUtils(fileIn, fileOut);\r\n\t\ttry {\r\n\t\t\tword.put(\"[ten_cqt]\", KtnbUtil.getTenCqtCapTrenTt(appConText).toUpperCase());\r\n\t\t\t// hinh thuc thanh tra kiem tra\r\n\t\t\tStringBuffer sb = new StringBuffer(\"\\u0110OA\\u0300N \");\r\n\t\t\tsb.append(hinhthuc_inT);\r\n\t\t\t\r\n\t\t\tif (Formater.isNull(giaHanForm.getSoQd())) {\r\n\t\t\t\tsb.append(\" Q\\u0110 S\\u1ED0......\");\r\n\t\t\t} else {\r\n\t\t\t\tsb.append(\" Q\\u0110 S\\u1ED0 \" + giaHanForm.getSoQd());\r\n\t\t\t}\r\n\t\t\tword.put(\"[doan_ttkt_so]\", sb.toString().toUpperCase());\r\n\r\n\t\t\t//word.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[dv_dc_ttkt]\", cuocTtkt.getTenDonViBi());\r\n\t\t\tword.put(\"[thu_truong_cqt_ra_qd]\", KtnbUtil.getTenThuTruongCqtForMauin(appConText).toUpperCase());\r\n\t\t\t//word.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[quyet_dinh_so]\", giaHanForm.getCanCuQd());\r\n\t\t\t\r\n\t\t\tif (Formater.isNull(cbQd.getSoQuyetDinh())) {\r\n\t\t\t\tword.put(\"[qd_so]\", \"............\");\r\n\t\t\t} else {\r\n\t\t\t\tword.put(\"[qd_so]\", cbQd.getSoQuyetDinh());\r\n\t\t\t}\r\n\r\n\t\t\tString ngayxet = Formater.date2str(cbQd.getNgayRaQuyetDnh());\r\n\t\t\tString[] arrngayxet = ngayxet.split(\"/\");\r\n\t\t\tword.put(\"[ngay_qd]\", \"ng\\u00E0y \" + arrngayxet[0] + \" th\\u00E1ng \" + arrngayxet[1] + \" n\\u0103m \" + arrngayxet[2]);\r\n\t\t\tword.put(\"[thu_truong_cqt]\", KtnbUtil.getTenThuTruongCqtForMauin(appConText));\r\n\t\t\t//word.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[dv_dc_ttkt]\", cuocTtkt.getTenDonViBi());\r\n\r\n\t\t\t//word.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[dv_dc_ttkt]\", cuocTtkt.getTenDonViBi().toString());\r\n\t\t\tword.put(\"[ngay_lv]\", giaHanForm.getSoNgayRaHan());\r\n\t\t\tString tungay = giaHanForm.getRaHanTuNgay();\r\n\t\t\tString[] arrtungay = tungay.split(\"/\");\r\n\t\t\tword.put(\"[tu_ngay]\", \"ng\\u00E0y \" + arrtungay[0] + \" th\\u00E1ng \" + arrtungay[1] + \" n\\u0103m \" + arrtungay[2]);\r\n\t\t\t// den ngay\r\n\t\t\tString denngay = giaHanForm.getRaHanDenNgay();\r\n\t\t\tString[] arrdenngay = denngay.split(\"/\");\r\n\t\t\tword.put(\"[den_ngay]\", \"ng\\u00E0y \" + arrdenngay[0] + \" th\\u00E1ng \" + arrdenngay[1] + \" n\\u0103m \" + arrdenngay[2]);\r\n\t\t\tword.put(\"[ly_do]\", giaHanForm.getLyDoRaHan());\r\n\t\t\tword.put(\"[thu_truong_cqt_ra_qd]\", KtnbUtil.getTenThuTruongCqtForMauin(appConText).toLowerCase());\r\n\t\t\tword.put(\"[noi_duyet]\", giaHanForm.getNoiPheDuyet());\r\n\t\t\t// ngay duyet\r\n\t\t\tString ngayduyet = giaHanForm.getNgayPheDuyet();\r\n\t\t\tString[] arrngayduyet = ngayduyet.split(\"/\");\r\n\t\t\tif (arrngayduyet.length >= 2) {\r\n\t\t\t\tword.put(\"[ngay_duyet]\", \"ng\\u00E0y \" + arrngayduyet[0] + \" th\\u00E1ng \" + arrngayduyet[1] + \" n\\u0103m \" + arrngayduyet[2]);\r\n\t\t\t}\r\n\t\t\tword.put(\"[noi_lap]\", giaHanForm.getNoiTrinh());\r\n\t\t\t// ngay lap to trinh\r\n\t\t\tString ngaylaptotrinh = giaHanForm.getNgayTrinh();\r\n\t\t\tString[] arrngaylaptotrinh = ngaylaptotrinh.split(\"/\");\r\n\t\t\tif (arrngaylaptotrinh.length >= 2) {\r\n\t\t\t\tword.put(\"[ngay_lap_to_trinh]\", \"ng\\u00E0y \" + arrngaylaptotrinh[0] + \" th\\u00E1ng \" + arrngaylaptotrinh[1] + \" n\\u0103m \" + arrngaylaptotrinh[2]);\r\n\t\t\t}\r\n\t\t\t//word.put(\"[ttkt]\", hinhThuc);\r\n\t\t\tword.put(\"[y_kien_phe_duyet]\", giaHanForm.getKienPheDuyet());\r\n\t\t\tword.put(\"[ten_truong_doan]\", cuocTtkt.getTenTruongDoan());\r\n\t\t\t//word.put(\"[chuc_danh_thu_truong]\", \"ABC\");\r\n\t\t\t//word.put(\"[chuc_danh_thu_truong]\", KtnbUtil.getChucVuThuTruongByMaCqt(appConText.getMaCqt()).toUpperCase());\r\n\t\t\t// if (Formater.isNull(appConText.getTenThuTruong())) {\r\n\t\t\t// word.put(\"[ten_thu_truong]\", \"\");\r\n\t\t\t// } else {\r\n\t\t\t// word.put(\"[ten_thu_truong]\", appConText.getTenThuTruong());\r\n\t\t\t// }\r\n\t\t\tword.saveAndClose();\r\n\t\t\tword.downloadFile(fileOut, \"Mau TTNB10\", \".doc\", reponse);\r\n\t\t} catch (Exception ex) {\r\n\t\t\t// ex.printStackTrace();\r\n\t\t\tSystem.out.println(\"Download Error: \" + ex.getMessage());\r\n\t\t} finally {\r\n\t\t\ttry {\r\n\t\t\t\tword.saveAndClose();\r\n\t\t\t} catch (Exception e) {\r\n\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"@Test\n\tpublic void testReadTxtFile() throws FileNotFoundException {\n\t\tFileParser fp = new FileParser();\n\t\tArrayList<String> parsedLines = fp.readTxtFile(\"test.txt\");\n\t\tassertEquals(\"This is a test file\", parsedLines.get(0));\n\t\tassertEquals(\"University of Virginia\", parsedLines.get(1));\n\n\t\tArrayList<String> parsedWords = fp.readTxtFile(\"test1.txt\");\n\t\tassertEquals(\"test\", parsedWords.get(0));\n\t\tassertEquals(\"file\", parsedWords.get(1));\n\t}",
"public static CV parseDocx(String nom, String prenom, String mail, String tel,File file) throws IOException{\n CV moncv=null;\n try {\n FileInputStream fis = new FileInputStream(file);\n XWPFDocument xdoc = new XWPFDocument(OPCPackage.open(fis));\n XWPFWordExtractor extractor = new XWPFWordExtractor(xdoc);\n String text = extractor.getText();\n if(text.trim().equals(\"\")) {\n throw new IOException(\"Format non valide\");\n //System.out.println(\"VIDE\");\n }\n\n String[] l = text.split(\"\\\\s\");\n Arrays.stream(l).forEach(System.out::println);\n //On récupère tous les mots clées et competences du PDF\n ArrayList<String> competences= getCompetences(l);\n ArrayList<String> allkeyword = getCompetences(l);\n\n //Creation du CV\n moncv= new CV(String.valueOf(cpt++),\n prenom,\n nom,\n getAge(l),\n mail,\n tel,\n competences,\n allkeyword);\n\n fis.close();\n\n } catch (InvalidFormatException e) {\n e.printStackTrace();\n }\n\n return moncv;\n\n\n }",
"public Word(String text) {\n\t\tsuper();\n\t\tthis.text = text;\n\t}",
"public static boolean isTextFile(Path path) {\n\t\tString name = path.toString().toLowerCase();\n\t\treturn name.endsWith(\".txt\") || name.endsWith(\".text\");\n\t}",
"private void ReadTextFile(String FilePath) {\n\t\t\n\t\t\n\t}",
"String readDocument(String path, Charset charset);"
] | [
"0.708026",
"0.67316586",
"0.64542687",
"0.630097",
"0.62286735",
"0.6222728",
"0.61278856",
"0.6092442",
"0.60883826",
"0.60757387",
"0.60711753",
"0.6055379",
"0.60548645",
"0.60103524",
"0.6008929",
"0.59392637",
"0.59362566",
"0.591027",
"0.59079987",
"0.5886511",
"0.5849019",
"0.58091205",
"0.5790976",
"0.575257",
"0.57393664",
"0.56778055",
"0.5663583",
"0.5626191",
"0.5626191",
"0.5625717",
"0.5612516",
"0.5602374",
"0.5597896",
"0.55802757",
"0.5575254",
"0.5547085",
"0.5535019",
"0.5530779",
"0.5521483",
"0.5519038",
"0.5500933",
"0.5500933",
"0.5499147",
"0.54855394",
"0.54855394",
"0.54841983",
"0.54616266",
"0.5460204",
"0.5459391",
"0.5457748",
"0.54558814",
"0.54539084",
"0.54525495",
"0.54480994",
"0.54407793",
"0.5428903",
"0.5417067",
"0.5409127",
"0.5408268",
"0.53950757",
"0.5394151",
"0.539172",
"0.53785396",
"0.5373837",
"0.5366695",
"0.53645504",
"0.5360925",
"0.5357561",
"0.5356734",
"0.53493655",
"0.53431344",
"0.5340378",
"0.53353536",
"0.5334421",
"0.5330334",
"0.53213805",
"0.5317295",
"0.5304413",
"0.52983576",
"0.52814066",
"0.52804303",
"0.5269175",
"0.5265885",
"0.5263377",
"0.5259572",
"0.52481526",
"0.524603",
"0.5245248",
"0.5233547",
"0.5232471",
"0.52311295",
"0.5220668",
"0.5214434",
"0.5212893",
"0.5211354",
"0.5192693",
"0.518732",
"0.5184729",
"0.5175961",
"0.51715994"
] | 0.59952337 | 15 |
Creates new form Data1Frame | public Plot6Frame() {
initComponents();
this.setDefaultCloseOperation(JFrame.HIDE_ON_CLOSE);
this.setIconImage(Toolkit.getDefaultToolkit().getImage(getClass().getResource("/draw/h.jpg")));
this.setTitle(LocaleManager.getInstance("Taiwan").getString("fig_plot6"));
setPanelInitVal();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public RDataframe() {\n\t\tsuper();\n\t}",
"public DataFrame copy() {\n return new DataFrame(data.values, header.values, index.values);\n }",
"DataFrame<R,C> copy();",
"private JInternalFrame createInternalFrame() {\n\n initializeChartPanel();\n\n chartPanel.setPreferredSize(new Dimension(200, 100));\n final JInternalFrame frame = new JInternalFrame(\"Frame 1\", true);\n frame.getContentPane().add(chartPanel);\n frame.setClosable(true);\n frame.setIconifiable(true);\n frame.setMaximizable(true);\n frame.setResizable(true);\n return frame;\n\n }",
"DataFrameContent<R,C> data();",
"private Dataset createDataset1() {\n final RDF factory1 = createFactory();\n\n final IRI name = factory1.createIRI(\"http://xmlns.com/foaf/0.1/name\");\n final Dataset g1 = factory1.createDataset();\n final BlankNode b1 = createOwnBlankNode(\"b1\", \"0240eaaa-d33e-4fc0-a4f1-169d6ced3680\");\n g1.add(b1, b1, name, factory1.createLiteral(\"Alice\"));\n\n final BlankNode b2 = createOwnBlankNode(\"b2\", \"9de7db45-0ce7-4b0f-a1ce-c9680ffcfd9f\");\n g1.add(b2, b2, name, factory1.createLiteral(\"Bob\"));\n\n final IRI hasChild = factory1.createIRI(\"http://example.com/hasChild\");\n g1.add(null, b1, hasChild, b2);\n\n return g1;\n }",
"public Patients_Data_Frame() {\n initComponents();\n Show_Products_in_jTable();\n }",
"public Copy(DataFrame owner)\n {\n this.owner = owner;\n\n setup();\n }",
"DataTable createDataTable();",
"static <R,C> DataFrame<R,C> empty() {\n return DataFrame.factory().empty();\n }",
"private PieDataset createDataset() {\n JOptionPane.showMessageDialog(null, \"teste\"+dados.getEntrada());\r\n \r\n DefaultPieDataset result = new DefaultPieDataset();\r\n result.setValue(\"Entrada\", dados.getEntrada());\r\n result.setValue(\"Saida\", dados.getSaida());\r\n result.setValue(\"Saldo do Periodo\", dados.getSaldo());\r\n return result;\r\n\r\n }",
"static DataFrameFactory factory() {\n return DataFrameFactory.getInstance();\n }",
"DataFrameFill fill();",
"@DataProvider(name = \"test1\")\n\tpublic Object[][] createData1() {\n\t return new Object[][] {\n\t { \"Cedric\", new Integer(36) },\n\t { \"Anne\", new Integer(37)},\n\t };\n\t}",
"@DataProvider(name = \"zimPageShowNotesPairs\")\n\tpublic\n\tObject[][] createData1()\n\t{\n\t\treturn new Object[][]\n\t\t\t{\n\t\t\t\t{\":UbuntuPodcast:s10:e05\", \"http://ubuntupodcast.org/2017/04/06/s10e05-supreme-luxuriant-gun/\"},\n\t\t\t};\n\t}",
"private XYDataset createDataset() {\n final XYSeriesCollection dataset = new XYSeriesCollection();\n //dataset.addSeries(totalDemand);\n dataset.addSeries(cerContent);\n //dataset.addSeries(cerDemand);\n dataset.addSeries(comContent);\n //dataset.addSeries(comDemand);\n dataset.addSeries(activation);\n dataset.addSeries(resolutionLevel);\n \n return dataset;\n }",
"public TestFrame() {\n\n final String[] columnNames = {\"Nombre\",\n \"Apellido\",\n \"webeo\",\n \"Años de Practica\",\n \"Soltero(a)\"};\n final Object[][] data = {\n\n {\"Lhucas\", \"Huml\",\n \"Patinar\", new Integer(3), new Boolean(true)},\n {\"Kathya\", \"Walrath\",\n \"Escalar\", new Integer(2), new Boolean(false)},\n {\"Marcus\", \"Andrews\",\n \"Correr\", new Integer(7), new Boolean(true)},\n {\"Angela\", \"Lalth\",\n \"Nadar\", new Integer(4), new Boolean(false)}\n };\n\n Vector dataV1 = new Vector();\n dataV1.add(\"XXXX\");\n dataV1.add(\"YYYY\");\n dataV1.add(\"JJJJ\");\n\n Vector dataV2 = new Vector();\n dataV2.add(\"XX2XX\");\n dataV2.add(\"Y2YYY\");\n dataV2.add(\"J2JJJ\");\n\n List dataF = new ArrayList();\n dataF.add(dataV1);\n dataF.add(dataV2);\n\n /*Vector dataC = new Vector();\n dataC.add(\"1\");\n dataC.add(\"2\");\n dataC.add(\"J23JJJ\");\n\n //model = new ModeloDatosTabla(data, true);\n model = new TableModel_1_1(dataC, dataF);\n model2 = new TableModel(columnNames, data, false);\n*/\n\n\n\n initComponents();\n\n\n }",
"@DataProvider(name = \"test1\")\n\tpublic Object [][] createData1() {\n\t\treturn new Object [][] {\n\t\t\tnew Object [] { 0, 0 },\n\t\t\tnew Object [] { 9, 2 },\n\t\t\tnew Object [] { 15, 0 },\n\t\t\tnew Object [] { 32, 0 },\n\t\t\tnew Object [] { 529, 4 },\n\t\t\tnew Object [] { 1041, 5 },\n\t\t\tnew Object [] { 65536, 0 },\n\t\t\tnew Object [] { 65537, 15 },\n\t\t\tnew Object [] { 100000, 4 }, \n\t\t\tnew Object [] { 2147483, 5 },\n\t\t\tnew Object [] { 2147483637, 1 }, //max - 10\n\t\t\tnew Object [] { 2147483646, 0 }, //max - 1\n\t\t\tnew Object [] { 2147483647, 0 } //max\n\t\t};\n\t}",
"private Dataset createDataSet(RecordingObject recordingObject, Group parentObject, String name) throws Exception\n\t{\n\t\t// dimension of dataset, length of array and 1 column\n\t\tlong[] dims2D = { recordingObject.getYValuesLength(), recordingObject.getXValuesLength() };\n\n\t\t// H5Datatype type = new H5Dataype(CLASS_FLOAT, 8, NATIVE, -1);\n\t\tDatatype dataType = recordingsH5File.createDatatype(recordingObject.getDataType(), recordingObject.getDataBytes(), Datatype.NATIVE, -1);\n\t\t// create 1D 32-bit float dataset\n\t\tDataset dataset = recordingsH5File.createScalarDS(name, parentObject, dataType, dims2D, null, null, 0, recordingObject.getValues());\n\n\t\t// add attributes for unit and metatype\n\t\tcreateAttributes(recordingObject.getMetaType().toString(), recordingObject.getUnit(), dataset);\n\n\t\treturn dataset;\n\t}",
"private XYMultipleSeriesDataset getdemodataset() {\n\t\t\tdataset1 = new XYMultipleSeriesDataset();// xy轴数据源\n\t\t\tseries = new XYSeries(\"温度 \");// 这个事是显示多条用的,显不显示在上面render设置\n\t\t\t// 这里相当于初始化,初始化中无需添加数据,因为如果这里添加第一个数据的话,\n\t\t\t// 很容易使第一个数据和定时器中更新的第二个数据的时间间隔不为两秒,所以下面语句屏蔽\n\t\t\t// 这里可以一次更新五个数据,这样的话相当于开始的时候就把五个数据全部加进去了,但是数据的时间是不准确或者间隔不为二的\n\t\t\t// for(int i=0;i<5;i++)\n\t\t\t// series.add(1, Math.random()*10);//横坐标date数据类型,纵坐标随即数等待更新\n\n\t\t\tdataset1.addSeries(series);\n\t\t\treturn dataset1;\n\t\t}",
"private DefaultCategoryDataset createDataset() {\n\t\t\n\t\tdataset.clear();\n\t\t\n\t\t// Query HIM to submit data for bar chart display \n\t\tHistoricalInfoMgr.getChartDataset(expNum);\n\n\n\t\treturn dataset; // add the data point (y-value, variable, x-value)\n\t}",
"public IndexFrame() {\n initComponents();\n \n /*\n * Definition d'un nouveau modele pour la jTable\n */\n \n \n jTable1.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n \n },\n new String [] {\n \"Lemme \", \"Document n° \", \" TF \",\n }){\n boolean[] canEdit = new boolean [] {\n false, false\n };\n \n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n \n DefaultTableModel model = (DefaultTableModel) jTable1.getModel();\n \n \n try{\n FileInputStream fis=new FileInputStream(\"C:/ressources/indexOptim.ser\");\n ObjectInputStream ois= new ObjectInputStream(fis);\n \n HashMap temp=new HashMap();\n \n HashMap h=new HashMap();\n h=(HashMap)ois.readObject();\n for (Object k : h.keySet())\n {\n temp=(HashMap)h.get(k);\n for (Object k2 : temp.keySet())\n {\n model.insertRow(0, new Object [] {(String) k,(Integer )k2,(Integer)temp.get(k2) });\n }\n }\n \n \n }\n catch(Exception e )\n {e.printStackTrace();\n }\n \n }",
"private void buildFrame() {\n mainFrame = new JFrame();\n header = new JLabel(\"View Contact Information\");\n header.setHorizontalAlignment(JLabel.CENTER);\n header.setBorder(BorderFactory.createEmptyBorder(5, 0, 0, 0));\n \n infoTable.setFillsViewportHeight(true);\n infoTable.setShowGrid(true);\n infoTable.setVisible(true);\n scrollPane = new JScrollPane(infoTable);\n\n mainFrame.add(header, BorderLayout.NORTH);\n mainFrame.add(scrollPane, BorderLayout.CENTER);\n }",
"private void createDataPanel(final Composite composite) {\n\t\t//\n\t\t// Create context (popup) menu\n\t\t//\n\t\tMenu menu = createPopupMenu();\n\n\t\t//\n\t\t// Create data panel\n\t\t//\n\t\tComposite dataPanel = new Composite(composite, SWT.NONE);\n\t\tGridLayout layout = new GridLayout();\n\t\tlayout.numColumns = 1;\n\t\tlayout.horizontalSpacing = 0;\n\t\tlayout.verticalSpacing = 0;\n\t\tlayout.marginWidth = 0;\n\t\tlayout.marginHeight = 2;\n\t\tdataPanel.setLayout(layout);\n\n\t\tdataPanel.setLayoutData(\"data\"); //$NON-NLS-1$\n\n\t\t//\n\t\t// Create table\n\t\t//\n\t\ttable = new HexTable(dataPanel, this, SWT.VIRTUAL | SWT.V_SCROLL | SWT.BORDER | SWT.SINGLE);\n\t\ttable.getTable().setHeaderVisible(true);\n\t\ttable.getTable().setLinesVisible(true);\n\t\ttable.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));\n\t\ttable.setData(encodingTypes);\n\t\ttable.setMenu(menu);\n\n\t\t//\n\t\t// Create table cursor\n\t\t//\n\t\tcursor = new TableCursor(table.getTable(), SWT.NONE);\n\t\tcursor.setMenu(menu);\n\n\t\t//\n\t\t// Create an editor to edit the cell when the user hits 0..9 or A..F key\n\t\t// while over a cell in the table\n\t\t//\n\t\tfinal ControlEditor editor = new ControlEditor(cursor);\n\t\teditor.grabHorizontal = true;\n\t\teditor.grabVertical = true;\n\n\t\t//\n\t\t// Add some cursor listeners\n\t\t//\n\t\taddCursorListeners(cursor, editor);\n\n\t\t//\n\t\t// Create table header\n\t\t//\n\t\tcreateTableHeader(table);\n\n\t\ttable.initListeners();\n\t\ttable.updateColors();\n\t}",
"public NewJFrame() {\n initComponents();\n IniciarTabla();\n \n \n // ingreso al githup \n \n }",
"private XYDataset createDataset() {\n\t\tfinal XYSeriesCollection dataset = new XYSeriesCollection( ); \n\t\tdataset.addSeries(trainErrors); \n\t\tdataset.addSeries(testErrors);\n\t\treturn dataset;\n\t}",
"public NewJFrame1() {\n initComponents();\n }",
"public JFrame displayChart() {\n final JFrame frame = new JFrame(\"dds\");\n\n // Schedule a job for the event-dispatching thread:\n // creating and showing this application's GUI.\n try {\n javax.swing.SwingUtilities.invokeAndWait(new Runnable() {\n\n @Override\n public void run() {\n\n frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);\n // XChartPanel<XYChart> chartPanel = new XChartPanel<XYChart>(charts.get(0));\n //() chartPanels.add(chartPanel);\n // frame.add(chartPanel);\n\n // Display the window.\n frame.setName(\"Динаміка системи\");\n frame.pack();\n frame.setVisible(true);\n }\n });\n } catch (InterruptedException e) {\n e.printStackTrace();\n } catch (InvocationTargetException e) {\n e.printStackTrace();\n }\n\n return frame;\n }",
"Frame createFrame();",
"public interface DataFrame<R,C> extends DataFrameOperations<R,C,DataFrame<R,C>>, DataFrameIterators<R,C>, DataFrameAlgebra<R,C> {\n /**\n * Checks if this DataFrame is empty, according to its number of rows.\n * @return true if the DataFrame is empty, false otherwise\n */\n boolean isEmpty();\n\n /**\n * Returns the row count for <code>DataFrame</code>\n * @return the row count\n */\n int rowCount();\n\n /**\n * Returns the column count for <code>DataFrame</code>\n * @return the column count\n */\n int colCount();\n\n /**\n * Returns true if this frame operates in parallel mode\n * @return true if parallel mode is enabled\n */\n boolean isParallel();\n\n /**\n * Returns a parallel implementation of the DataFrame\n * @return a parallel implementation of the DataFrame\n */\n DataFrame<R,C> parallel();\n\n /**\n * Returns a sequential implementation of the DataFrame\n * @return a sequential implementation of the DataFrame\n */\n DataFrame<R,C> sequential();\n\n /**\n * Returns a deep copy of this <code>DataFrame</code>\n * @return deep copy of this <code>DataFrame</code>\n */\n DataFrame<R,C> copy();\n\n /**\n * Returns a reference to the output interface for this <code>DataFrame</code>\n * @return the output interface for this <code>DataFrame</code>\n */\n DataFrameOutput<R,C> out();\n\n /**\n * Returns a reference to the content of this DataFrame\n * @return the data access interface for this frame\n */\n DataFrameContent<R,C> data();\n\n /**\n * Returns the row operator for this DataFrame\n * @return the row operator for this DataFrame\n */\n DataFrameRows<R,C> rows();\n\n /**\n * Returns the column operator for this DataFrame\n * @return the column operator for this DataFrame\n */\n DataFrameColumns<R,C> cols();\n\n /**\n * Returns a newly created cursor for random access to elements of this frame\n * @return the newly created cursor for element random access\n */\n DataFrameCursor<R,C> cursor();\n\n /**\n * Returns a reference to the row for the key specified\n * @param rowKey the row key to match\n * @return the matching row\n */\n DataFrameRow<R,C> row(R rowKey);\n\n /**\n * Returns a reference to the column for the key specified\n * @param colKey the column key to match\n * @return the matching column\n */\n DataFrameColumn<R,C> col(C colKey);\n\n /**\n * Returns a reference to a row for the ordinal specified\n * @param rowOrdinal the row ordinal\n * @return the matching row\n */\n DataFrameRow<R,C> rowAt(int rowOrdinal);\n\n /**\n * Returns a reference to a column for the ordinal specified\n * @param colIOrdinal the column ordinal\n * @return the matching column\n */\n DataFrameColumn<R,C> colAt(int colIOrdinal);\n\n /**\n * Returns a stream of values over this DataFrame\n * @return the stream of values over this DataFrame\n */\n Stream<DataFrameValue<R,C>> values();\n\n /**\n * Returns a reference to the fill interface for copy values\n * @return the fill interface for this <code>DataFrame</code>\n */\n DataFrameFill fill();\n\n /**\n * Returns the sign DataFrame of -1, 0, 1 for negative, zero and positive elements\n * @return a DataFrame of -1, 0, 1 for negative, zero and positive elements\n * @see <a href=\"http://en.wikipedia.org/wiki/Signum_function\">Wikiepdia Reference</a>\n */\n DataFrame<R,C> sign();\n\n /**\n * Returns the stats for this <code>DataFrame</code>\n * @return the stats for frame\n */\n Stats<Double> stats();\n\n /**\n * Returns the transpose of this DataFrame\n * @return the transpose of this frame\n */\n DataFrame<C,R> transpose();\n\n /**\n * Returns the rank interface for this <code>DataFrame</code>\n * @return the rank interface for the <code>DataFrame</code>\n */\n DataFrameRank<R,C> rank();\n\n /**\n * Returns the event notification interface for this DataFrame\n * @return the event notification interface\n */\n DataFrameEvents events();\n\n /**\n * Returns the write interface which provides a mechanism to write frames to a data store\n * @return the DataFrame write interface\n */\n DataFrameWrite<R,C> write();\n\n /**\n * Returns an interface that enables this frame to be exported as other types\n * @return the <code>DataFrame</code> export interface\n */\n DataFrameExport export();\n\n /**\n * Returns an interface that can be used to efficiently cap values in the frame\n * @param inPlace true if capping should be applied in place, otherwise cap & copy.\n * @return the DataFrame capping interface\n */\n DataFrameCap<R,C> cap(boolean inPlace);\n\n /**\n * Returns a DataFrame containing the first N rows where N=min(count, frame.rowCount())\n * @param count the max number of rows to capture\n * @return the DataFrame containing first N rows where N=min(count, frame.rowCount())\n */\n DataFrame<R,C> head(int count);\n\n /**\n * Returns a DataFrame containing the last N rows where N=min(count, frame.rowCount())\n * @param count the max number of rows to capture\n * @return the DataFrame containing last N rows where N=min(count, frame.rowCount())\n */\n DataFrame<R,C> tail(int count);\n\n /**\n * Returns a DataFrame containing the first N columns where N=min(count, frame.colCount())\n * @param count the max number of left most columns to include\n * @return the DataFrame containing the first B columns where N=min(count, frame.colCount())\n */\n DataFrame<R,C> left(int count);\n\n /**\n * Returns a DataFrame containing the last N columns where N=min(count, frame.colCount())\n * @param count the max number of right most columns to include\n * @return the DataFrame containing the last N columns where N=min(count frame.colCount())\n */\n DataFrame<R,C> right(int count);\n\n /**\n * Returns the calculation interface for this <code>DataFrame</code>\n * @return the calculation interface for the <code>DataFrame</code>\n */\n DataFrameCalculate<R,C> calc();\n\n /**\n * Returns the Principal Component Analysis interface for this DataFrame\n * @return the PCA interface for this DataFrame\n */\n DataFramePCA<R,C> pca();\n\n /**\n * Returns the DataFrame smoothing interface to apply SMA or an EWMA filter to the data\n * @param inPlace if true, smoothing will be applied to this frame, otherwise copy & smooth.\n * @return the DataFrame smoothing data smoothing interface\n */\n DataFrameSmooth<R,C> smooth(boolean inPlace);\n\n /**\n * Returns a reference to the regression interface for this DataFrame\n * @return the regression interface for this DataFrame\n */\n DataFrameRegression<R,C> regress();\n\n /**\n * Adds all rows & columns from the argument that do not exist in this frame, and applies data for added coordinates\n * @param other the other frame from which to add rows, columns & data that do not exist in this frame\n * @return the resulting frame with additional rows and columns\n */\n DataFrame<R,C> addAll(DataFrame<R,C> other);\n\n /**\n * Updates data in this frame based on update frame provided\n * @param update the DataFrame with updates to apply to this frame\n * @param addRows if true, add any missing row keys from the update\n * @param addColumns if true, add any missing column keys from the update\n * @return the updated DataFrame\n */\n DataFrame<R,C> update(DataFrame<R,C> update, boolean addRows, boolean addColumns);\n\n /**\n * Returns a <code>DataFrame</code> filter that includes a subset of rows and columns\n * @param rowKeys the row key selection\n * @param colKeys the column key selection\n * @return the <code>DataFrame</code> filter containing selected rows & columns\n */\n DataFrame<R,C> select(Iterable<R> rowKeys, Iterable<C> colKeys);\n\n /**\n * Returns a <code>DataFrame</code> selection that includes a subset of rows and columns\n * @param rowPredicate the predicate to select rows\n * @param colPredicate the predicate to select columns\n * @return the <code>DataFrame</code> containing selected rows & columns\n */\n DataFrame<R,C> select(Predicate<DataFrameRow<R,C>> rowPredicate, Predicate<DataFrameColumn<R,C>> colPredicate);\n\n /**\n * Returns a newly created DataFrame with all elements of this frame mapped to booleans\n * @param mapper the mapper function to apply\n * @return the newly created frame\n */\n DataFrame<R,C> mapToBooleans(ToBooleanFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a newly created DataFrame with all elements of this frame mapped to ints\n * @param mapper the mapper function to apply\n * @return the newly created frame\n */\n DataFrame<R,C> mapToInts(ToIntFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a newly created DataFrame with all elements of this frame mapped to longs\n * @param mapper the mapper function to apply\n * @return the newly created frame\n */\n DataFrame<R,C> mapToLongs(ToLongFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a newly created DataFrame with all elements of this frame mapped to doubles\n * @param mapper the mapper function to apply\n * @return the newly created frame\n */\n DataFrame<R,C> mapToDoubles(ToDoubleFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a newly created DataFrame with all elements of this frame mapped to objects\n * @param type the type for mapper function\n * @param mapper the mapper function to apply\n * @return the newly created frame\n */\n <T> DataFrame<R,C> mapToObjects(Class<T> type, Function<DataFrameValue<R,C>,T> mapper);\n\n /**\n * Returns a shallow copy of the DataFrame with the specified column mapped to booleans\n * @param colKey the column key to apply mapping function\n * @param mapper the mapper function to apply\n * @return the new frame\n * @throws DataFrameException if frame is transposed, or column does not exist\n */\n DataFrame<R,C> mapToBooleans(C colKey, ToBooleanFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a shallow copy of the DataFrame with the specified column mapped to ints\n * @param colKey the column key to apply mapping function\n * @param mapper the mapper function to apply\n * @return the new frame\n * @throws DataFrameException if frame is transposed, or column does not exist\n */\n DataFrame<R,C> mapToInts(C colKey, ToIntFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a shallow copy of the DataFrame with the specified column mapped to longs\n * @param colKey the column key to apply mapping function\n * @param mapper the mapper function to apply\n * @return the new frame\n * @throws DataFrameException if frame is transposed, or column does not exist\n */\n DataFrame<R,C> mapToLongs(C colKey, ToLongFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a shallow copy of the DataFrame with the specified column mapped to doubles\n * @param colKey the column key to apply mapping function\n * @param mapper the mapper function to apply\n * @return the new frame\n * @throws DataFrameException if frame is transposed, or column does not exist\n */\n DataFrame<R,C> mapToDoubles(C colKey, ToDoubleFunction<DataFrameValue<R,C>> mapper);\n\n /**\n * Returns a shallow copy of the DataFrame with the specified column mapped to objects\n * @param colKey the column key to apply mapping function\n * @param type the data type for mapped column\n * @param mapper the mapper function to apply\n * @return the new frame\n * @throws DataFrameException if frame is transposed, or column does not exist\n */\n <T> DataFrame<R,C> mapToObjects(C colKey, Class<T> type, Function<DataFrameValue<R,C>,T> mapper);\n\n /**\n * Returns a reference to the factory that creates new DataFrames\n * @return the DataFrame factory\n */\n static DataFrameFactory factory() {\n return DataFrameFactory.getInstance();\n }\n\n /**\n * Returns a reference to the DataFrame read interfavce\n * @return the DataFrame read interface\n */\n static DataFrameRead read() {\n return DataFrameFactory.getInstance().read();\n }\n\n /**\n * Returns an empty DataFrame with zero length rows and columns\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the empty DataFrame\n */\n static <R,C> DataFrame<R,C> empty() {\n return DataFrame.factory().empty();\n }\n\n /**\n * Returns an empty DataFrame with zero length rows and columns\n * @param rowAxisType the row axis key type\n * @param colAxisType the column axis key type\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the empty DataFrame\n */\n static <R,C> DataFrame<R,C> empty(Class<R> rowAxisType, Class<C> colAxisType) {\n return DataFrame.factory().empty(rowAxisType, colAxisType);\n }\n\n /**\n * Returns a DataFrame result by concatenating a selection of frames\n * @param frames the iterable of frames to concatenate\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the concatenated DataFrame\n */\n @SafeVarargs\n static <R,C> DataFrame<R,C> combineFirst(DataFrame<R,C>... frames) {\n return DataFrame.factory().combineFirst(Arrays.asList(frames).iterator());\n }\n\n /**\n * Returns a DataFrame result by concatenating a selection of frames\n * @param frames the iterable of frames to concatenate\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the concatenated DataFrame\n */\n static <R,C> DataFrame<R,C> combineFirst(Iterable<DataFrame<R,C>> frames) {\n return DataFrame.factory().combineFirst(frames.iterator());\n }\n\n /**\n * Returns a DataFrame result by combining multiple frames into one while applying only the first non-null element value\n * If there are intersecting coordinates across the frames, that first non-null value will apply in the resulting frame\n * @param frames the stream of frames to apply\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the concatenated DataFrame\n */\n static <R,C> DataFrame<R,C> combineFirst(Stream<DataFrame<R,C>> frames) {\n return DataFrame.factory().combineFirst(frames.iterator());\n }\n\n /**\n * Returns a newly created DataFrame by concatenating rows from the input frames\n * If there are overlapping row keys, the row values from the first frame will apply\n * @param frames the iterable of frames from which to concatenate rows\n * @param <R> the row key type for frames\n * @param <C> the column key type for frames\n * @return the resulting DataFrame\n */\n @SafeVarargs\n static <R,C> DataFrame<R,C> concatRows(DataFrame<R,C>... frames) {\n return DataFrame.factory().concatRows(Arrays.asList(frames).iterator());\n }\n\n /**\n * Returns a newly created DataFrame by concatenating rows from the input frames\n * If there are overlapping row keys, the row values from the first frame will apply\n * @param frames the iterable of frames from which to concatenate rows\n * @param <R> the row key type for frames\n * @param <C> the column key type for frames\n * @return the resulting DataFrame\n */\n static <R,C> DataFrame<R,C> concatRows(Iterable<DataFrame<R,C>> frames) {\n return DataFrame.factory().concatRows(frames.iterator());\n }\n\n /**\n * Returns a newly created DataFrame by concatenating rows from the input frames\n * If there are overlapping row keys, the row values from the first frame will apply\n * @param frames the iterable of frames from which to concatenate rows\n * @param <R> the row key type for frames\n * @param <C> the column key type for frames\n * @return the resulting DataFrame\n */\n static <R,C> DataFrame<R,C> concatRows(Stream<DataFrame<R,C>> frames) {\n return DataFrame.factory().concatRows(frames.iterator());\n }\n\n /**\n * Returns a newly created DataFrame by concatenating columns from the input frames\n * If there are overlapping column keys, the row values from the first frame will apply\n * @param frames the iterable of frames from which to concatenate columns\n * @param <R> the row key type for frames\n * @param <C> the column key type for frames\n * @return the resulting DataFrame\n */\n @SafeVarargs\n static <R,C> DataFrame<R,C> concatColumns(DataFrame<R,C>... frames) {\n return DataFrame.factory().concatColumns(Arrays.asList(frames).iterator());\n }\n\n /**\n * Returns a newly created DataFrame by concatenating columns from the input frames\n * If there are overlapping column keys, the row values from the first frame will apply\n * @param frames the iterable of frames from which to concatenate columns\n * @param <R> the row key type for frames\n * @param <C> the column key type for frames\n * @return the resulting DataFrame\n */\n static <R,C> DataFrame<R,C> concatColumns(Iterable<DataFrame<R,C>> frames) {\n return DataFrame.factory().concatColumns(frames.iterator());\n }\n\n /**\n * Returns a newly created DataFrame by concatenating columns from the input frames\n * If there are overlapping column keys, the row values from the first frame will apply\n * @param frames the iterable of frames from which to concatenate columns\n * @param <R> the row key type for frames\n * @param <C> the column key type for frames\n * @return the resulting DataFrame\n */\n static <R,C> DataFrame<R,C> concatColumns(Stream<DataFrame<R,C>> frames) {\n return DataFrame.factory().concatColumns(frames.iterator());\n }\n\n /**\n * Returns an empty DataFrame with the row and column types specified\n * @param rowType the row key type\n * @param colType the column key type\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> of(Class<R> rowType, Class<C> colType) {\n return DataFrame.factory().from(Index.of(rowType, 1000), Index.of(colType, 20), Object.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized for columns with the type specified\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param type the data type for columns\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> of(Iterable<R> rowKeys, Iterable<C> colKeys, Class<?> type) {\n return DataFrame.factory().from(rowKeys, colKeys, type);\n }\n\n /**\n * Returns a newly created DataFrame with 1 row and N columns all with the data type specified\n * @param rowKey the row key for frame\n * @param colKeys the column keys for frame\n * @param dataType the data type for columns\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> of(R rowKey, Iterable<C> colKeys, Class<?> dataType) {\n return DataFrame.factory().from(Index.singleton(rowKey), colKeys, dataType);\n }\n\n /**\n * Returns a newly created DataFrame with N rows and 1 column with the data type specified\n * @param rowKeys the row keys for frame\n * @param colKey the column key for frame\n * @param type the data type for columns\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> of(Iterable<R> rowKeys, C colKey, Class<?> type) {\n return DataFrame.factory().from(rowKeys, Index.singleton(colKey), type);\n }\n\n /**\n * Returns a newly created DataFrame initialized with rows and any state added by the consumer\n * @param rowKeys the row keys for frame\n * @param colType the column key type\n * @param columns the consumer which can be used to add columns\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created <code>DataFrame</code>\n */\n static <R,C> DataFrame<R,C> of(Iterable<R> rowKeys, Class<C> colType, Consumer<DataFrameColumns<R,C>> columns) {\n return DataFrame.factory().from(rowKeys, colType, columns);\n }\n\n /**\n * Returns a newly created DataFrame with 1 row optimized to hold primitive booleans\n * @param rowKey the row key for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofBooleans(R rowKey, Iterable<C> colKeys) {\n return DataFrame.factory().from(Index.singleton(rowKey), colKeys, Boolean.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 row optimized to hold primitive integers\n * @param rowKey the row key for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofInts(R rowKey, Iterable<C> colKeys) {\n return DataFrame.factory().from(Index.singleton(rowKey), colKeys, Integer.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 row optimized to hold primitive longs\n * @param rowKey the row key for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofLongs(R rowKey, Iterable<C> colKeys) {\n return DataFrame.factory().from(Index.singleton(rowKey), colKeys, Long.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 row optimized to hold primitive doubles\n * @param rowKey the row key for frame\n * @param colKeys the column index for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofDoubles(R rowKey, Iterable<C> colKeys) {\n return DataFrame.factory().from(Index.singleton(rowKey), colKeys, Double.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 row optimized to hold any object\n * @param rowKey the row key for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofObjects(R rowKey, Iterable<C> colKeys) {\n return DataFrame.factory().from(Index.singleton(rowKey), colKeys, Object.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 column optimized to hold primitive booleans\n * @param rowKeys the row keys for frame\n * @param colKey the column key for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofBooleans(Iterable<R> rowKeys, C colKey) {\n return DataFrame.factory().from(rowKeys, Index.singleton(colKey), Boolean.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 column optimized to hold primitive integers\n * @param rowKeys the row keys for frame\n * @param colKey the column key for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofInts(Iterable<R> rowKeys, C colKey) {\n return DataFrame.factory().from(rowKeys, Index.singleton(colKey), Integer.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 column optimized to hold primitive longs\n * @param rowKeys the row keys for frame\n * @param colKey the column key for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofLongs(Iterable<R> rowKeys, C colKey) {\n return DataFrame.factory().from(rowKeys, Index.singleton(colKey), Long.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 column optimized to hold primitive doubles\n * @param rowKeys the row keys for frame\n * @param colKey the column key for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofDoubles(Iterable<R> rowKeys, C colKey) {\n return DataFrame.factory().from(rowKeys, Index.singleton(colKey), Double.class);\n }\n\n /**\n * Returns a newly created DataFrame with 1 column optimized to hold any object\n * @param rowKeys the row keys for frame\n * @param colKey the column key for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofObjects(Iterable<R> rowKeys, C colKey) {\n return DataFrame.factory().from(rowKeys, Index.singleton(colKey), Object.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive booleans\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofBooleans(Iterable<R> rowKeys, Iterable<C> colKeys) {\n return DataFrame.factory().from(rowKeys, colKeys, Boolean.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive integers\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofInts(Iterable<R> rowKeys, Iterable<C> colKeys) {\n return DataFrame.factory().from(rowKeys, colKeys, Integer.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive longs\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofLongs(Iterable<R> rowKeys, Iterable<C> colKeys) {\n return DataFrame.factory().from(rowKeys, colKeys, Long.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive doubles\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofDoubles(Iterable<R> rowKeys, Iterable<C> colKeys) {\n return DataFrame.factory().from(rowKeys, colKeys, Double.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold Strings\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofStrings(Iterable<R> rowKeys, Iterable<C> colKeys) {\n return DataFrame.factory().from(rowKeys, colKeys, String.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold any objects\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofObjects(Iterable<R> rowKeys, Iterable<C> colKeys) {\n return DataFrame.factory().from(rowKeys, colKeys, Object.class);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive booleans\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param initials a function to provide initial values\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofBooleans(Iterable<R> rowKeys, Iterable<C> colKeys, ToBooleanFunction<DataFrameValue<R,C>> initials) {\n return DataFrame.factory().from(rowKeys, colKeys, Boolean.class).applyBooleans(initials);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive integers\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param initials a function to provide initial values\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofInts(Iterable<R> rowKeys, Iterable<C> colKeys, ToIntFunction<DataFrameValue<R,C>> initials) {\n return DataFrame.factory().from(rowKeys, colKeys, Integer.class).applyInts(initials);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive longs\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param initials a function to provide initial values\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofLongs(Iterable<R> rowKeys, Iterable<C> colKeys, ToLongFunction<DataFrameValue<R,C>> initials) {\n return DataFrame.factory().from(rowKeys, colKeys, Long.class).applyLongs(initials);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold primitive doubles\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param initials a function to provide initial values\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofDoubles(Iterable<R> rowKeys, Iterable<C> colKeys, ToDoubleFunction<DataFrameValue<R,C>> initials) {\n return DataFrame.factory().from(rowKeys, colKeys, Double.class).applyDoubles(initials);\n }\n\n /**\n * Returns a newly created DataFrame optimized to hold any objects\n * @param rowKeys the row keys for frame\n * @param colKeys the column keys for frame\n * @param initials a function to provide initial values\n * @param <R> the row key type\n * @param <C> the column key type\n * @return the newly created DataFrame\n */\n static <R,C> DataFrame<R,C> ofObjects(Iterable<R> rowKeys, Iterable<C> colKeys, Function<DataFrameValue<R, C>, ?> initials) {\n return DataFrame.factory().from(rowKeys, colKeys, Object.class).applyValues(initials);\n }\n\n /**\n * Returns a DataFrame of doubles initialized with ARGB values for each pixel in the image\n * @param file the file to load the image from\n * @return the DataFrame of ARGB values extracted from java.awt.image.BufferedImage\n * @link java.awt.image.BufferedImage#getRGB\n */\n static DataFrame<Integer,Integer> ofImage(File file) {\n try {\n final BufferedImage image = ImageIO.read(file);\n final Range<Integer> rowKeys = Range.of(0, image.getHeight());\n final Range<Integer> colKeys = Range.of(0, image.getWidth());\n return DataFrame.ofInts(rowKeys, colKeys, v -> image.getRGB(v.colOrdinal(), v.rowOrdinal()));\n } catch (Exception ex) {\n throw new DataFrameException(\"Failed to initialize DataFrame from image file: \" + file.getAbsolutePath(), ex);\n }\n }\n\n /**\n * Returns a DataFrame of doubles initialized with ARGB values for each pixel in the image\n * @param url the url to load the image from\n * @return the DataFrame of ARGB values extracted from java.awt.image.BufferedImage\n * @see java.awt.image.BufferedImage#getRGB\n */\n static DataFrame<Integer,Integer> ofImage(URL url) {\n try {\n final BufferedImage image = ImageIO.read(url);\n final Range<Integer> rowKeys = Range.of(0, image.getHeight());\n final Range<Integer> colKeys = Range.of(0, image.getWidth());\n return DataFrame.ofInts(rowKeys, colKeys, v -> image.getRGB(v.colOrdinal(), v.rowOrdinal()));\n } catch (Exception ex) {\n throw new DataFrameException(\"Failed to initialize DataFrame from image url: \" + url, ex);\n }\n }\n\n\n /**\n * Returns a DataFrame of doubles initialized with ARGB values for each pixel in the image\n * @param inputStream the input stream to load the image from\n * @return the DataFrame of ARGB values extracted from java.awt.image.BufferedImage\n * @see java.awt.image.BufferedImage#getRGB\n */\n static DataFrame<Integer,Integer> ofImage(InputStream inputStream) {\n try {\n final BufferedImage image = ImageIO.read(inputStream);\n final Range<Integer> rowKeys = Range.of(0, image.getHeight());\n final Range<Integer> colKeys = Range.of(0, image.getWidth());\n return DataFrame.ofInts(rowKeys, colKeys, v -> image.getRGB(v.colOrdinal(), v.rowOrdinal()));\n } catch (Exception ex) {\n throw new DataFrameException(\"Failed to initialize DataFrame from image input stream\", ex);\n }\n }\n}",
"public Frame1() {\n initComponents();\n }",
"public void rebuildFrame(){\n \n // Re-initialize frame with default attributes\n controlFrame.dispose();\n controlFrame = buildDefaultFrame(\"CSCI 446 - A.I. - Montana State University\");\n \n // Initialize header with default attributes\n header = buildDefaultHeader();\n \n // Initialize control panel frame with default attributes\n controlPanel = buildDefaultPanel(BoxLayout.Y_AXIS);\n \n // Combine objects\n controlPanel.add(header, BorderLayout.NORTH);\n controlFrame.add(controlPanel);\n \n }",
"public DataRecord() {\n super(DataTable.DATA);\n }",
"protected abstract D createData();",
"public JexlEngine.Frame createFrame(Object... values) {\r\n return scope != null? scope.createFrame(values) : null;\r\n }",
"public DatasetTab(int index) {\n tab = new VerticalLayout();\n replicatesSheet = new TabSheet();\n for (int replicateIndex = 0;\n replicateIndex < presenter.getNumberOfReplicates();\n replicateIndex++) {\n ReplicateTab replicateTab = new ReplicateTab(index, replicateIndex);\n replicatesSheet.addTab(replicateTab, \"Replicate \" + createAlphabeticalIndex(replicateIndex));\n }\n setCompositionRoot(tab);\n }",
"private static DataTable createDataTable() throws Exception {\n DataTable t = new DataTable(\"Items\");\r\n\r\n // Add two columns\r\n DataColumn c;\r\n\r\n // First column\r\n c = t.getColumns().Add(\"id\", TClrType.getType(\"System.Int32\"));\r\n c.setAutoIncrement(true);\r\n\r\n // Second column\r\n t.getColumns().Add(\"item\", TClrType.getType(\"System.String\"));\r\n\r\n // Set primary key\r\n t.setPrimaryKey(new DataColumnArray(new DataColumn[]{t.getColumns().getItem(0)}));\r\n\r\n // Add twelve rows\r\n for (int i = 0; i < 10; i++) {\r\n DataRow row = t.NewRow();\r\n row.setItem(0, i);\r\n row.setItem(1, String.format(\"%s\", i));\r\n t.getRows().Add(row);\r\n }\r\n DataRow row = t.NewRow();\r\n row.setItem(0, 11);\r\n row.setItem(1, \"abc\");\r\n t.getRows().Add(row);\r\n\r\n row = t.NewRow();\r\n row.setItem(0, 15);\r\n row.setItem(1, \"ABC\");\r\n t.getRows().Add(row);\r\n\r\n return t;\r\n }",
"public abstract DataTableDefinition clone();",
"public FullWaveformData() {\n\t\tchannelSampleArrayList = new ArrayList<>();\n\t\tdataSetArray = new DataSet[34];\n\t\tfor (int i = 0; i < 34; i++) {\n\t\t\tchannelSampleArrayList.add(new ArrayList<>());\n\t\t}\n\t\tfor (int i = 0; i < 34; i++) {\n\t\t\ttry {\n\t\t\t\tdataSetArray[i] = new DataSet(DataSetType.XYXY, WavePlot.getColumnNames());\n\t\t\t} catch (DataSetException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}",
"ExpData createData(Container container, @NotNull DataType type);",
"DataList createDataList();",
"Rows createRows();",
"public RiswanAgam_HistoryFrame() {\n initComponents();\n Dimension size = Toolkit.getDefaultToolkit().getScreenSize();\n int width = (int)size.getWidth();\n int height = (int)size.getHeight();\n setBounds(width/2-200,height/2-250,670,540);\n database = new RiswanAgam_Database();\n database.connection();\n initTable();\n setResizable(false);\n setTitle(\"History\");\n setDefaultCloseOperation(this.DO_NOTHING_ON_CLOSE);\n }",
"FData createFData();",
"public Table copy(int start, int length) {\n\t\tTableImpl vt;\n\t\tint[] newsubset = this.resubset(start, length);\n\n\t\t// Copy failed, maybe objects in a column that are not serializable.\n\t\tColumn[] cols = new Column[this.getNumColumns()];\n\t\tColumn[] oldcols = this.getColumns();\n\t\tfor (int i = 0; i < cols.length; i++) {\n\t\t\tcols[i] = oldcols[i].getSubset(newsubset);\n\t\t}\n\n\t\tvt = new MutableTableImpl(cols);\n\t\tvt.setLabel(this.getLabel());\n\t\tvt.setComment(this.getComment());\n\t\treturn vt;\n\t}",
"public DataTable() {\n\n\t\t// In this application, we use HashMap data structure defined in\n\t\t// java.util.HashMap\n\t\tdc = new HashMap<String, DataColumn>();\n\t}",
"public data2() {\n initComponents();\n }",
"DataFrameExport export();",
"public hu.blackbelt.epsilon.runtime.model.test1.data.DataModel build() {\n final hu.blackbelt.epsilon.runtime.model.test1.data.DataModel _newInstance = hu.blackbelt.epsilon.runtime.model.test1.data.DataFactory.eINSTANCE.createDataModel();\n if (m_featureNameSet) {\n _newInstance.setName(m_name);\n }\n if (m_featureEntitySet) {\n _newInstance.getEntity().addAll(m_entity);\n } else {\n if (!m_featureEntityBuilder.isEmpty()) {\n for (hu.blackbelt.epsilon.runtime.model.test1.data.util.builder.IDataBuilder<? extends hu.blackbelt.epsilon.runtime.model.test1.data.Entity> builder : m_featureEntityBuilder) {\n _newInstance.getEntity().add(builder.build());\n }\n }\n }\n return _newInstance;\n }",
"DT createDT();",
"public DataSet() {\r\n \r\n }",
"private static void createAndShowGUI() {\n JFrame frame = new JFrame(\"SimpleTableDemo\");\n frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\n //Create and set up the content pane.\n EshopTable newContentPane = new EshopTable();\n newContentPane.addColumn(\"name\", \"toto je hlaviska1\", null, 500);\n newContentPane.addColumn(\"vek\", \"toto je hlaviska2\", \"sortHlav2\", 250);\n newContentPane.markAsVisible();\n\n newContentPane.setOpaque(true); //content panes must be opaque\n frame.setContentPane(newContentPane);\n\n //Display the window.\n frame.pack();\n frame.setVisible(true);\n }",
"private XYDataset createDataset() {\n\t \tXYSeriesCollection dataset = new XYSeriesCollection();\n\t \t\n\t \t//Definir cada Estacao\n\t\t XYSeries aes1 = new XYSeries(\"Estação1\");\n\t\t XYSeries aes2 = new XYSeries(\"Estação2\");\n\t\t XYSeries aes3 = new XYSeries(\"Estação3\");\n\t\t XYSeries aes4 = new XYSeries(\"Estação4\");\n\t\t XYSeries aes5 = new XYSeries(\"Estação5\");\n\t\t XYSeries aes6 = new XYSeries(\"Estação6\");\n\t\t XYSeries aes7 = new XYSeries(\"Estação7\");\n\t\t XYSeries aes8 = new XYSeries(\"Estação8\");\n\t\t XYSeries aes9 = new XYSeries(\"Estação9\");\n\t\t XYSeries aes10 = new XYSeries(\"Estação10\");\n\t\t XYSeries aes11 = new XYSeries(\"Estação11\");\n\t\t XYSeries aes12 = new XYSeries(\"Estação12\");\n\t\t XYSeries aes13 = new XYSeries(\"Estação13\");\n\t\t XYSeries aes14 = new XYSeries(\"Estação14\");\n\t\t XYSeries aes15 = new XYSeries(\"Estação15\");\n\t\t XYSeries aes16 = new XYSeries(\"Estação16\");\n\t\t \n\t\t //Definir numero de utilizadores em simultaneo para aparece na Interface\n\t\t XYSeries au1 = new XYSeries(\"AU1\");\n\t\t XYSeries au2 = new XYSeries(\"AU2\");\n\t\t XYSeries au3 = new XYSeries(\"AU3\");\n\t\t XYSeries au4 = new XYSeries(\"AU4\");\n\t\t XYSeries au5 = new XYSeries(\"AU5\");\n\t\t XYSeries au6 = new XYSeries(\"AU6\");\n\t\t XYSeries au7 = new XYSeries(\"AU7\");\n\t\t XYSeries au8 = new XYSeries(\"AU8\");\n\t\t XYSeries au9 = new XYSeries(\"AU9\");\n\t\t XYSeries au10 = new XYSeries(\"AU10\");\n\t\t \n\t\t //Colocar estacoes no gráfico\n\t\t aes1.add(12,12);\n\t\t aes2.add(12,37);\n\t\t aes3.add(12,62);\n\t\t aes4.add(12,87);\n\t\t \n\t\t aes5.add(37,12);\n\t\t aes6.add(37,37);\n\t\t aes7.add(37,62);\n\t\t aes8.add(37,87);\n\t\t \n\t\t aes9.add(62,12); \n\t\t aes10.add(62,37);\n\t\t aes11.add(62,62);\n\t\t aes12.add(62,87);\n\t\t \n\t\t aes13.add(87,12);\n\t\t aes14.add(87,37);\n\t\t aes15.add(87,62);\n\t\t aes16.add(87,87);\n\t\t \n\t\t//Para a bicicleta 1\n\t\t \t\n\t\t\t for(Entry<String, String> entry : position1.entrySet()) {\n\t\t\t\t String key = entry.getKey();\n\t\t\t\t \n\t\t\t\t String[] part= key.split(\",\");\n\t\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t\t \n\t\t\t\t au1.add(keyX,keyY);\n\t\t\t }\n\t\t \n\t\t\t //Para a bicicleta 2\n\t\t for(Entry<String, String> entry : position2.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au2.add(keyX,keyY);\n\t\t }\n\t\t \n\t\t //Para a bicicleta 3\n\t\t for(Entry<String, String> entry : position3.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au3.add(keyX,keyY);\n\t\t }\n\t\t for(Entry<String, String> entry : position4.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au4.add(keyX,keyY);\n\t\t }\n\t\t for(Entry<String, String> entry : position5.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au5.add(keyX,keyY);\n\t\t }\n\t\t for(Entry<String, String> entry : position6.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au6.add(keyX,keyY);\n\t\t }\n\t\t for(Entry<String, String> entry : position7.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au7.add(keyX,keyY);\n\t\t }\n\t\t for(Entry<String, String> entry : position8.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au8.add(keyX,keyY);\n\t\t }\n\t\t for(Entry<String, String> entry : position9.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au9.add(keyX,keyY);\n\t\t }\n\t\t for(Entry<String, String> entry : position10.entrySet()) {\n\t\t\t String key = entry.getKey();\n\t\t\t \n\t\t\t String[] part= key.split(\",\");\n\t\t\t double keyX=Double.valueOf(part[0]);\n\t\t\t double keyY=Double.valueOf(part[1]);\n\t\t\t \n\t\t\t au10.add(keyX,keyY);\n\t\t }\n\t\t \n\t\t //Add series to dataset\n\t\t dataset.addSeries(au1);\n\t\t dataset.addSeries(au2);\n\t\t dataset.addSeries(au3);\n\t\t dataset.addSeries(au4);\n\t\t dataset.addSeries(au5);\n\t\t dataset.addSeries(au6);\n\t\t dataset.addSeries(au7);\n\t\t dataset.addSeries(au8);\n\t\t dataset.addSeries(au9);\n\t\t dataset.addSeries(au10);\n\t\t \n\t\t \n\t\t dataset.addSeries(aes1);\n\t\t dataset.addSeries(aes2);\n\t\t dataset.addSeries(aes3);\n\t\t dataset.addSeries(aes4);\n\t\t dataset.addSeries(aes5);\n\t\t dataset.addSeries(aes6);\n\t\t dataset.addSeries(aes7);\n\t\t dataset.addSeries(aes8);\n\t\t dataset.addSeries(aes9);\n\t\t dataset.addSeries(aes10);\n\t\t dataset.addSeries(aes11);\n\t\t dataset.addSeries(aes12);\n\t\t dataset.addSeries(aes13);\n\t\t dataset.addSeries(aes14);\n\t\t dataset.addSeries(aes15);\n\t\t dataset.addSeries(aes16);\n\t\t \n\t\t return dataset;\n\t }",
"public void createAndShowGUI() {\n //Create and set up the window.\n JFrame frame = new JFrame(\"SimpleTableDemo\");\n frame.setTitle(titulo);\n frame.setLocationRelativeTo(null);\n frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);\n //Create and set up the content pane.\n SimpleTableDemo newContentPane = new SimpleTableDemo();\n newContentPane.setOpaque(true); //content panes must be opaque\n frame.setContentPane(this);\n \n //Display the window.\n frame.pack();\n frame.setVisible(true);\n \n }",
"public AppData() {\n super(0,Entry.DataColumn.values().length);\n setColumnIdentifiers(Arrays.stream(Entry.DataColumn.values()).map(Entry.DataColumn::getName).toArray());\n System.out.println(\"a new AppData has been constructed\");\n }",
"public Builder clearData1() {\n bitField0_ = (bitField0_ & ~0x00000002);\n data1_ = 0;\n \n return this;\n }",
"public Builder clearData1() {\n bitField0_ = (bitField0_ & ~0x00000002);\n data1_ = 0;\n \n return this;\n }",
"private Node createFrameHolder(Data<X,Y> dataItem){\n Node frameHolder = dataItem.getNode();\n if (frameHolder == null){\n frameHolder = new StackPane();\n dataItem.setNode(frameHolder);\n }\n frameHolder.getStyleClass().add(getStyleClass(dataItem.getExtraValue()));\n return frameHolder;\n }",
"public void changeData() {\n\t\tDefaultTableModel dtm = new DefaultTableModel(dataModel.getData(),\n\t\t\t\tdataModel.getHeader());\n\t\tsetModel(dtm);\n\t}",
"DataFrame<R,C> addAll(DataFrame<R,C> other);",
"private void initialize() {\r\n\t\t//frame = new JFrame();\r\n\t\tframe.setSize(725, 482);\r\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\t//frame.getContentPane().setLayout(null);\r\n\t\t\r\n\t\t\r\n\t\tDefaultCategoryDataset dataset= new DefaultCategoryDataset();\r\n\t\t//JOptionPane.showMessageDialog(null, \"BUTTON CLICKED!!!\");\r\n\t\t//LableMessage.setText(\"BUTTON CLICKED!!!\");\r\n\t\t\r\n\t\t//Pain, Drowsiness, Nausea, Anxiety, and Depression\r\n\t\tdataset.setValue(2, \"day1\",\"Pain\");\r\n\t\tdataset.setValue(5, \"day2\",\"Pain\");\r\n\t\tdataset.setValue(4, \"day3\",\"Pain\");\r\n\t\tdataset.setValue(6, \"day1\", \"Drowsiness\");\r\n\t\tdataset.setValue(10, \"day2\", \"Drowsiness\");\r\n\t\tdataset.setValue(8, \"day3\", \"Drowsiness\");\r\n\t\tdataset.setValue(1, \"day1\", \"Nausea\");\r\n\t\tdataset.setValue(7, \"day2\", \"Nausea\");\r\n\t\tdataset.setValue(5, \"day3\", \"Nausea\");\r\n\t\tdataset.setValue(3,\"day1\",\"Anxiety\");\t\r\n\t\tdataset.setValue(8,\"day2\",\"Anxiety\");\r\n\t\tdataset.setValue(9,\"day3\",\"Anxiety\");\r\n\t\tdataset.setValue(8, \"day1\", \"Depression\");\r\n\t\tdataset.setValue(7, \"day2\", \"Depression\");\r\n\t\tdataset.setValue(9, \"day3\", \"Depression\");\r\n\t\tint test[] = new int[7];\r\n\t\tfor (int i=0;i<7; i++)\r\n\t\t{\r\n\t\t\ttest[i]=5;\r\n\t\t}\r\n\t\tDefaultCategoryDataset dataset2= new DefaultCategoryDataset();\r\n\t\t//dataset2 = dataSetInit(P1.getEnterSymptomLevel(),P1.getPreviousSymptomLevel1(),P1.getPreviousSymptomLevel2());\r\n\t\tdataset2 = dataSetInit(test,test,test);\r\n\t\t//P1.getEnter\r\n\t\t//DefaultCategoryDataset dataset2= new DefaultCategoryDataset();\r\n\r\n\t\t//JFreeChart chart= ChartFactory.createBarChart(P1.firstName+\" \"+P1.lastName,\"Symptoms\", \"Levels\", dataset2, PlotOrientation.VERTICAL,false,true,false);\r\n\r\n\t\tJFreeChart chart= ChartFactory.createBarChart3D(\"Symptom Report\",\"Symptoms\", \"Levels\", dataset2, PlotOrientation.VERTICAL,true,true,true);\r\n\t\t//JFreeChart chart2= ChartFactory.createBarChart(\"Symptom Report\",\"Symptoms\", \"Levels\", dataset2, PlotOrientation.VERTICAL,false,true,false);\r\n\t\tchart.setBackgroundPaint(Color.lightGray);\r\n\t\t//JFreeChart chart2= ChartFactory.createBarChart(\"Grade Report\",\"Student Name\", \"Marks\", dataset2, PlotOrientation.VERTICAL,false,true,false);\r\n\t\t\r\n\t\tChartPanel chartPanel = new ChartPanel(chart);\r\n\t\tchartPanel.setPreferredSize(new Dimension(700,350));\r\n\t\tPan.add(chartPanel);\r\n\t\t\r\n\t\tframe.getContentPane().add(Pan);\r\n\t\tCategoryPlot p=chart.getCategoryPlot();\r\n\t\tp.setRangeGridlinePaint(Color.red);\r\n\t\tp.setBackgroundPaint(Color.WHITE);\r\n\t\tframe.setVisible(true);\r\n//\t\tChartFrame frame= new ChartFrame(\"Bar Graph Test\",chart,false);\r\n//\t\t\r\n//\t\tframe.setVisible(true);\r\n//\t\tframe.setSize(700,350);\r\n//\t\tframe.setResizable(false);\r\n\t\t//frame2 =new JFrame()\r\n\t}",
"private PieDataset createDataset() {\n\t\tDefaultPieDataset result = new DefaultPieDataset();\n\t\tresult.setValue(\"Linux\", 29);\n\t\tresult.setValue(\"Mac\", 20);\n\t\tresult.setValue(\"Windows\", 51);\n\t\treturn result;\n\n\t}",
"private XYDataset createDataset(String WellID, String lang) {\n final TimeSeries eur = createEURTimeSeries(WellID, lang);\n final TimeSeriesCollection dataset = new TimeSeriesCollection();\n dataset.addSeries(eur);\n return dataset;\n }",
"public DataSet(){\r\n\t\tdocs = Lists.newArrayList();\r\n//\t\t_docs = Lists.newArrayList();\r\n\t\t\r\n\t\tnewId2trnId = HashBiMap.create();\r\n\t\t\r\n\t\tM = 0;\r\n\t\tV = 0;\r\n\t}",
"private Frame buildFrame() {\n return new Frame(command, headers, body);\n }",
"DataFrame<R,C> sequential();",
"private void fillData() {\n table.setRowList(data);\n }",
"public StatisticsJFrame() {\n initComponents();\n initData();\n }",
"public SearchDataView(JFrame parent) {\n \tthis.parentObject = parent;\n \taction = new SearchDataAction(this);\n initComponents();\n prepareComponents();\n }",
"public void buildFrame();",
"public NewJFrame1() {\n initComponents();\n\n dip();\n sh();\n }",
"private RecordSet getRecordSet(String arg[]){\n RecordSet datos = new RecordSet();\n datos.addColumn(\"CODIGO\");\n\t\tdatos.addColumn(\"VALOR\"); \n\n for(int j=0;j<arg.length;j++) { \n datos.addRow(new Object[] { arg[j], arg[j] }); \n }\n return datos;\n }",
"public CreateData() {\n\t\t\n\t\t// TODO Auto-generated constructor stub\n\t}",
"private void initComponents() {\n scrollPane1 = new JScrollPane();\n table1 = new JTable();\n\n //======== this ========\n\n\n //======== scrollPane1 ========\n {\n\n //---- table1 ----\n table1.setModel(new DefaultTableModel(\n t_date,\n new String[]{\n \"\\u7f16\\u53f7\", \"\\u5c97\\u4f4d\\u5de5\\u8d44\", \"\\u57fa\\u7840\\u6548\\u7ee9\", \"课酬\", \"其他补助\", \"管理效绩\", \"\\u65f6\\u95f4\", \"\\u603b\\u548c\"\n }\n ));\n scrollPane1.setViewportView(table1);\n }\n\n GroupLayout layout = new GroupLayout(this);\n setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup()\n .addGroup(layout.createSequentialGroup()\n .addComponent(scrollPane1, GroupLayout.PREFERRED_SIZE, 663, GroupLayout.PREFERRED_SIZE)\n .addGap(0, 0, Short.MAX_VALUE))\n );\n layout.setVerticalGroup(\n layout.createParallelGroup()\n .addComponent(scrollPane1, GroupLayout.DEFAULT_SIZE, 300, Short.MAX_VALUE)\n );\n // JFormDesigner - End of component initialization //GEN-END:initComponents\n }",
"public DataGraphFrame(Graph graph, String frameTitle, boolean isVisible) {\r\n\t\tinit(graph, isVisible, frameTitle);\r\n\t}",
"@Override\n public Data clone() {\n final Data data = new Data(name, code, numeric, symbol, fractionSymbol, fractionsPerUnit, rounding, formatString,\n triangulated.clone());\n return data;\n }",
"public PDSData() {\n initComponents();\n }",
"FRAME createFRAME();",
"private void loadData()\n\t{\n\t\tVector<String> columnNames = new Vector<String>();\n\t\tcolumnNames.add(\"Item Name\");\n\t\tcolumnNames.add(\"Item ID\");\n\t\tcolumnNames.add(\"Current Stock\");\n\t\tcolumnNames.add(\"Unit Price\");\n\t\tcolumnNames.add(\"Section\");\n\t\t\n\t\tVector<Vector<Object>> data= new Vector<Vector<Object>>();\n\t\t\n\t\tResultSet rs = null;\n\t\ttry \n\t\t{\n\t\t\tConnection con = Connector.DBcon();\n\t\t\tString query=\"select * from items natural join sections order by sections.s_name\";\n\t\t\tPreparedStatement pst = con.prepareStatement(query);\n\t\t\trs = pst.executeQuery();\n\t\t\t\n\t\t\twhile(rs.next())\n\t\t\t{\n\t\t\t\tVector<Object> vector = new Vector<Object>();\n\t\t for (int columnIndex = 1; columnIndex <= 9; columnIndex++)\n\t\t {\n\t\t \t\n\t\t \tvector.add(rs.getObject(1));\n\t\t \tvector.add(rs.getObject(2));\n\t\t vector.add(rs.getObject(3));\n\t\t vector.add(rs.getObject(4));\n\t\t vector.add(rs.getObject(6));\n\t\t \n\t\t }\n\t\t data.add(vector);\n\t\t\t}\n\t\t\t\n\t\t\t tableModel.setDataVector(data, columnNames);\n\t\t\t \n\t\t\t rs.close();\n\t\t\t pst.close();\n\t\t\t con.close();\n\t\t} \n\t\tcatch (Exception e) \n\t\t{\n\t\t\tJOptionPane.showMessageDialog(null, e);\n\t\t}\n\t\t\n\t\t\n\t}",
"private void fillData()\n {\n\n }",
"DataSource clone();",
"private void createComposite1() {\n \t\t\tGridLayout gridLayout2 = new GridLayout();\n \t\t\tgridLayout2.numColumns = 7;\n \t\t\tgridLayout2.makeColumnsEqualWidth = true;\n \t\t\tGridData gridData1 = new org.eclipse.swt.layout.GridData();\n \t\t\tgridData1.horizontalSpan = 3;\n \t\t\tgridData1.horizontalAlignment = org.eclipse.swt.layout.GridData.FILL;\n \t\t\tgridData1.verticalAlignment = org.eclipse.swt.layout.GridData.FILL;\n \t\t\tgridData1.grabExcessVerticalSpace = true;\n \t\t\tgridData1.grabExcessHorizontalSpace = true;\n \t\t\tcalendarComposite = new Composite(this, SWT.BORDER);\n \t\t\tcalendarComposite.setBackground(Display.getDefault().getSystemColor(SWT.COLOR_WHITE));\n \t\t\tcalendarComposite.setLayout(gridLayout2);\n \t\t\tcalendarComposite.setLayoutData(gridData1);\n \t\t}",
"public Reporte4() {\n initComponents();\n modelo = new DefaultTableModel();\n modelo.addColumn(\"id_partidos\");\n modelo.addColumn(\"equipo_local\");\n modelo.addColumn(\"equipo_visitante\");\n modelo.addColumn(\"estadio\");\n modelo.addColumn(\"fecha\");\n modelo.addColumn(\"marcador_local\");\n modelo.addColumn(\"marcador_visitante\");\n // jPanel2.setVisible(false);\n // jPanel3.setVisible(false);\n //jPanel4.setVisible(false);\n //modelo.addColumn(\"Año escolar\");\n this.jTable1.setModel(modelo);\n CargarBD();\n }",
"FRAMESET createFRAMESET();",
"private GenericTableView populateSeriesSamplesTableView(String viewName) {\n\t GenericTable table = assembler.createTable();\n GenericTableView tableView = new GenericTableView (viewName, 5, table);\n tableView.setRowsSelectable();\n\t\ttableView.addCollection(0, 0);\n tableView.setCollectionBottons(1);\n tableView.setDisplayTotals(false);\n //tableView.setColAlignment(2, 0);\n tableView.setColAlignment(5, 0);\n tableView.setColAlignment(6, 0);\n \n return tableView;\n }",
"public QLDSV() {\n initComponents();\n this.setLocationRelativeTo(null);\n cn = ConnectSQL.ketnoi(\"FPL_DAOTAO\");\n model = (DefaultTableModel) tblShow.getModel();\n loadData();\n display(0);\n tblShow.setRowSelectionInterval(0, 0);\n\n }",
"static DataFrameRead read() {\n return DataFrameFactory.getInstance().read();\n }",
"private void initialize() {\r\n\t\tframe = new JFrame();\r\n\t\tframe.addWindowListener(new WindowAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void windowOpened(WindowEvent e) {\r\n\t\t\t\tShowdata();\r\n\t\t\t}\r\n\t\t});\r\n\t\tframe.setBounds(100, 100, 1058, 592);\r\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\tframe.getContentPane().setLayout(null);\r\n\t\t\r\n\t\tJScrollPane scrollPane = new JScrollPane();\r\n\t\tscrollPane.setBounds(10, 149, 1022, 376);\r\n\t\tframe.getContentPane().add(scrollPane);\r\n\t\t\r\n\t\ttable = new JTable();\r\n\t\tscrollPane.setViewportView(table);\r\n\t\t\r\n\t\tlblNewLabel = new JLabel(\"DEATH IS LIKE THE WIND ALWAYS BY MY SIDE !\\r\\nHasagi\");\r\n\t\tlblNewLabel.setFont(new Font(\"Times New Roman\", Font.BOLD | Font.ITALIC, 25));\r\n\t\tlblNewLabel.setBounds(205, 11, 699, 84);\r\n\t\tframe.getContentPane().add(lblNewLabel);\r\n\t}",
"ColumnFull createColumnFull();",
"public NewFrame() {\n initComponents();\n }",
"@SuppressWarnings({ \"unchecked\", \"rawtypes\" })\r\n\tpublic Data(String table) throws EmptyDatasetException, SQLException, EmptySetException, NoValueException{\r\n\t\tTableData tableData = new TableData(new DbAccess());\r\n\t\tdata = tableData.getDistinctTransazioni(table);\r\n\t\t\r\n\t\tTableSchema tableSchema = new TableSchema(new DbAccess(),table);\r\n\t\tnumberOfExamples=data.size();\r\n\t\t\r\n\t\tQUERY_TYPE min,max;\r\n\t\tmin = QUERY_TYPE.MIN;\r\n\t\tmax = QUERY_TYPE.MAX;\r\n\t\t\r\n\t\tfor (int i=0;i<tableSchema.getNumberOfAttributes();i++) {\r\n\t\t\tif(!tableSchema.getColumn(i).isNumber()) {\r\n\t\t\t\texplanatorySet.add((T) new DiscreteAttribute(tableSchema.getColumn(i).getColumnName(),i,(TreeSet)tableData.getDistinctColumnValues(table, tableSchema.getColumn(i))));\r\n\t\t\t}else {\r\n\t\t\t\texplanatorySet.add((T) new ContinuousAttribute(tableSchema.getColumn(i).getColumnName(),i,(float)tableData.getAggregateColumnValue(table,tableSchema.getColumn(i),min),(float)tableData.getAggregateColumnValue(table,tableSchema.getColumn(i),max)));\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t}\r\n\t}",
"FromTable createFromTable();",
"public DataTableModel() {\n super();\n LanguageObservable.getInstance().attach(this);\n setLocalizedResourceBundle(\"ch.ethz.origo.jerpa.jerpalang.perspective.ededb.EDEDB\");\n initColumns();\n data = new LinkedList<DataRowModel>();\n }",
"@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jPanel1 = new javax.swing.JPanel();\n jLabel1 = new javax.swing.JLabel();\n dataSetLocation = new javax.swing.JTextField();\n fileButton = new javax.swing.JButton();\n jScrollPane1 = new javax.swing.JScrollPane();\n dataTable = new javax.swing.JTable();\n jPanel2 = new javax.swing.JPanel();\n jScrollPane2 = new javax.swing.JScrollPane();\n principalComponentsTable = new javax.swing.JTable();\n jScrollPane3 = new javax.swing.JScrollPane();\n dataInPCATable = new javax.swing.JTable();\n\n jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder(\"Data Set\"));\n\n jLabel1.setText(\"File :\");\n\n dataSetLocation.setText(\"jTextField1\");\n dataSetLocation.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n dataSetLocationActionPerformed(evt);\n }\n });\n\n fileButton.setText(\"File\");\n fileButton.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n fileButtonActionPerformed(evt);\n }\n });\n\n dataTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null, null, null, null},\n {null, null, null, null, null, null, null},\n {null, null, null, null, null, null, null},\n {null, null, null, null, null, null, null}\n },\n new String [] {\n \"Date\", \"Open\", \"High\", \"Low\", \"Close\", \"Volume\", \"Adj Close\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false, false, false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n dataTable.setEnabled(false);\n jScrollPane1.setViewportView(dataTable);\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 677, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(jLabel1)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(dataSetLocation)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(fileButton)))\n .addGap(6, 6, 6))\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(jLabel1)\n .addComponent(dataSetLocation, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addComponent(fileButton))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 152, Short.MAX_VALUE))\n );\n\n jPanel2.setBorder(javax.swing.BorderFactory.createTitledBorder(\"Principal Component Analysis\"));\n\n principalComponentsTable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null},\n {null, null, null},\n {null, null, null},\n {null, null, null}\n },\n new String [] {\n \"Eige.\", \"Con.r\", \"C-con.r\"\n }\n ) {\n boolean[] canEdit = new boolean [] {\n false, false, false\n };\n\n public boolean isCellEditable(int rowIndex, int columnIndex) {\n return canEdit [columnIndex];\n }\n });\n principalComponentsTable.setEnabled(false);\n jScrollPane2.setViewportView(principalComponentsTable);\n\n dataInPCATable.setModel(new javax.swing.table.DefaultTableModel(\n new Object [][] {\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null},\n {null, null, null, null}\n },\n new String [] {\n \"Title 1\", \"Title 2\", \"Title 3\", \"Title 4\"\n }\n ));\n dataInPCATable.setEnabled(false);\n jScrollPane3.setViewportView(dataInPCATable);\n\n javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);\n jPanel2.setLayout(jPanel2Layout);\n jPanel2Layout.setHorizontalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 351, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n jPanel2Layout.setVerticalGroup(\n jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel2Layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)\n .addComponent(jScrollPane3, javax.swing.GroupLayout.DEFAULT_SIZE, 227, Short.MAX_VALUE)\n .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()\n .addContainerGap()\n .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)\n .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addContainerGap())\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addContainerGap())\n );\n }",
"public MainClass()\n\t{\n\t\t// Set the frame characteristics\n\t\tsetTitle( \"Excel Table In Java\" );\n\t\tsetSize( 300, 200 );\n\t\tsetBackground( Color.gray );\n\n\t\t// Create a panel to hold all other components\n\t\ttopPanel = new JPanel();\n\t\ttopPanel.setLayout( new BorderLayout() );\n\t\tgetContentPane().add( topPanel );\n\n\t\t//func to find length and get coulomn data\n\t\tArrayList list = new ArrayList();\n\t\tint columnslength=FuncFillColumnList(list,0);\n\t\tint rowslength=list.size();\n\t\t// Create columns array and fill from the list\n\t\tString columnNames[] = new String[rowslength];\n\t\tfor(int i=0;i<rowslength;i++){\n\t\t\ttry{\n\t\t\tcolumnNames[i]=(String) list.get(i);\n\t\t\t}catch(Exception e){\n\t\t\t\tcolumnNames[i]=String.valueOf(list.get(i));\n\t\t\t}\n\t\t}\n\n\n\t\t// fill body\n\t\tString bodyValues[][] =new String[columnslength][rowslength];\n\t\tFuncFillbody(bodyValues,0,rowslength);\n\n\t\t// Create a new table instance\n\t\ttable = new JTable( bodyValues, columnNames );\n\t\tDefaultTableCellRenderer centerRenderer = new DefaultTableCellRenderer();\n\t\tcenterRenderer.setHorizontalAlignment( JLabel.CENTER );\n\t\t//center all cells\n\t\tfor(int i=0;i<rowslength;i++){\n\t\ttable.getColumnModel().getColumn(i).setCellRenderer( centerRenderer );\n\t\t}\n\t\t// Add the table to a scrolling pane\n\t\tscrollPane = new JScrollPane( table );\n\t\ttopPanel.add( scrollPane, BorderLayout.CENTER );\n\t\tthis.addWindowListener(new WindowAdapter() {\n\t public void windowClosing(WindowEvent e) {\n\t \tSystem.exit(0);\n\t }\n\n\t });\n\n\t}",
"private void loadData() {\n\n // connect the table column with the attributes of the patient from the Queries class\n id_In_editTable.setCellValueFactory(new PropertyValueFactory<>(\"pstiantID\"));\n name_In_editTable.setCellValueFactory(new PropertyValueFactory<>(\"name\"));\n date_In_editTable.setCellValueFactory(new PropertyValueFactory<>(\"reserveDate\"));\n time_In_editTable.setCellValueFactory(new PropertyValueFactory<>(\"reserveTime\"));\n\n try {\n\n // database related code \"MySql\"\n ps = con.prepareStatement(\"select * from visitInfo \");\n ResultSet rs = ps.executeQuery();\n\n while (rs.next()) {\n\n // load data to the observable list\n editOL.add(new Queries(new SimpleStringProperty(rs.getString(\"id\")),\n new SimpleStringProperty(rs.getString(\"patiantID\")),\n new SimpleStringProperty(rs.getString(\"patiant_name\")),\n new SimpleStringProperty(rs.getString(\"visit_type\")),\n new SimpleStringProperty(rs.getString(\"payment_value\")),\n new SimpleStringProperty(rs.getString(\"reserve_date\")),\n new SimpleStringProperty(rs.getString(\"reserve_time\")),\n new SimpleStringProperty(rs.getString(\"attend_date\")),\n new SimpleStringProperty(rs.getString(\"attend_time\")),\n new SimpleStringProperty(rs.getString(\"payment_date\")),\n new SimpleStringProperty(rs.getString(\"attend\")),\n new SimpleStringProperty(rs.getString(\"attend_type\"))\n\n ));\n }\n\n // assigning the observable list to the table\n table_view_in_edit.setItems(editOL);\n\n ps.close();\n rs.close();\n\n } catch (SQLException e) {\n e.printStackTrace();\n }\n\n }",
"public Cotizaciones() throws DatatypeConfigurationException {\r\n initComponents();\r\n this.jDateChooser1.setDateFormatString(\"yyyy-MM-dd\");\r\n this.jDateChooser2.setDateFormatString(\"yyyy-MM-dd\");\r\n \r\n //Escondo la columna que tiene el objeto guardado.\r\n jTable1.getColumnModel().getColumn(4).setMinWidth(0);\r\n jTable1.getColumnModel().getColumn(4).setMaxWidth(0);\r\n jTable1.getColumnModel().getColumn(4).setWidth(0);\r\n DefaultTableCellRenderer Alinear = new DefaultTableCellRenderer();\r\n Alinear.setHorizontalAlignment(SwingConstants.LEFT);\r\n \r\n jTable1.getColumnModel().getColumn(0).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(1).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(2).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(3).setCellRenderer(Alinear);\r\n \r\n }",
"private void TampilData() {\n DefaultTableModel model = new DefaultTableModel();\n model.addColumn(\"NO\");\n model.addColumn(\"ID\");\n model.addColumn(\"NAME\");\n model.addColumn(\"USERNAME\");\n tabelakses.setModel(model);\n\n //menampilkan data database kedalam tabel\n try {\n int i=1;\n java.sql.Connection conn = new DBConnection().connect();\n java.sql.Statement stat = conn.createStatement();\n ResultSet data = stat.executeQuery(\"SELECT * FROM p_login order by Id asc\");\n while (data.next()) {\n model.addRow(new Object[]{\n (\"\" + i++),\n data.getString(\"Id\"),\n data.getString(\"Name\"),\n data.getString(\"Username\")\n });\n tabelakses.setModel(model);\n }\n } catch (Exception e) {\n System.err.println(\"ERROR:\" + e);\n }\n }",
"public static void createMainframe()\n\t{\n\t\t//Creates the frame\n\t\tJFrame foodFrame = new JFrame(\"USDA Food Database\");\n\t\t//Sets up the frame\n\t\tfoodFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tfoodFrame.setSize(1000,750);\n\t\tfoodFrame.setResizable(false);\n\t\tfoodFrame.setIconImage(icon.getImage());\n\t\t\n\t\tGui gui = new Gui();\n\t\t\n\t\tgui.setOpaque(true);\n\t\tfoodFrame.setContentPane(gui);\n\t\t\n\t\tfoodFrame.setVisible(true);\n\t}",
"public PatientFrame(Patient pa) {\n patient = pa;\n initComponents();\n updateTable();\n }",
"public Data() {\n initComponents();\n getData();\n }"
] | [
"0.6617628",
"0.63948506",
"0.6184503",
"0.6082186",
"0.6062307",
"0.59031117",
"0.57908446",
"0.57623607",
"0.57071203",
"0.5684128",
"0.5663814",
"0.563697",
"0.5438734",
"0.54310304",
"0.54134274",
"0.54031223",
"0.5401797",
"0.53887266",
"0.5369376",
"0.533187",
"0.5306003",
"0.52708876",
"0.5270141",
"0.5262407",
"0.5236765",
"0.522306",
"0.5206075",
"0.52059245",
"0.52050054",
"0.5193364",
"0.51927984",
"0.5178084",
"0.5177566",
"0.51770246",
"0.51714265",
"0.5171172",
"0.51690894",
"0.5163346",
"0.5155323",
"0.51526076",
"0.5149956",
"0.5144831",
"0.5135083",
"0.51178",
"0.5108218",
"0.51013803",
"0.5088858",
"0.50850916",
"0.5083145",
"0.50777006",
"0.5067932",
"0.5066955",
"0.5063973",
"0.5059682",
"0.5059237",
"0.50590277",
"0.50590277",
"0.5039652",
"0.50357014",
"0.50352186",
"0.5033952",
"0.5033522",
"0.5029595",
"0.50260174",
"0.5011691",
"0.49977863",
"0.49903297",
"0.49719372",
"0.49685785",
"0.4959744",
"0.49578705",
"0.49556968",
"0.49531293",
"0.49456716",
"0.49372613",
"0.4932657",
"0.4923008",
"0.49228212",
"0.49201623",
"0.4913835",
"0.49135086",
"0.49116382",
"0.49098337",
"0.49081597",
"0.49022058",
"0.48981017",
"0.489583",
"0.48940256",
"0.48938334",
"0.48870602",
"0.48728782",
"0.48694587",
"0.48562554",
"0.48536402",
"0.48424202",
"0.48420456",
"0.4840527",
"0.48375827",
"0.48362058",
"0.48234838",
"0.4819819"
] | 0.0 | -1 |
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor. | @SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
pitchPanel = new tw.com.hasco.MSFS.ui.Plot1Panel();
rollPanel = new tw.com.hasco.MSFS.ui.Plot1Panel();
yawPanel = new tw.com.hasco.MSFS.ui.Plot1Panel();
altPanel = new tw.com.hasco.MSFS.ui.Plot1Panel();
aoaPanel = new tw.com.hasco.MSFS.ui.Plot1Panel();
betaPanel = new tw.com.hasco.MSFS.ui.Plot1Panel();
upPanel = new tw.com.hasco.MSFS.ui.UpPanel();
downPanel = new tw.com.hasco.MSFS.ui.DownPanel();
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
pitchPanel.setMinimumSize(new java.awt.Dimension(0, 0));
rollPanel.setMinimumSize(new java.awt.Dimension(0, 0));
yawPanel.setMinimumSize(new java.awt.Dimension(0, 0));
altPanel.setMinimumSize(new java.awt.Dimension(0, 0));
aoaPanel.setMinimumSize(new java.awt.Dimension(0, 0));
betaPanel.setMinimumSize(new java.awt.Dimension(0, 0));
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
getContentPane().setLayout(layout);
layout.setHorizontalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(pitchPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 652, Short.MAX_VALUE)
.addComponent(rollPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(yawPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(altPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(aoaPanel, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(betaPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(upPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(downPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addContainerGap())
);
layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addComponent(upPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(pitchPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 89, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(rollPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 89, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(yawPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 89, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(altPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 89, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(aoaPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 88, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(betaPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 85, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(downPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 32, javax.swing.GroupLayout.PREFERRED_SIZE)
.addContainerGap())
);
pack();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Form() {\n initComponents();\n }",
"public MainForm() {\n initComponents();\n }",
"public MainForm() {\n initComponents();\n }",
"public MainForm() {\n initComponents();\n }",
"public frmRectangulo() {\n initComponents();\n }",
"public form() {\n initComponents();\n }",
"public AdjointForm() {\n initComponents();\n setDefaultCloseOperation(HIDE_ON_CLOSE);\n }",
"public FormListRemarking() {\n initComponents();\n }",
"public MainForm() {\n initComponents();\n \n }",
"public FormPemilihan() {\n initComponents();\n }",
"public GUIForm() { \n initComponents();\n }",
"public FrameForm() {\n initComponents();\n }",
"public TorneoForm() {\n initComponents();\n }",
"public FormCompra() {\n initComponents();\n }",
"public muveletek() {\n initComponents();\n }",
"public Interfax_D() {\n initComponents();\n }",
"public quanlixe_form() {\n initComponents();\n }",
"public SettingsForm() {\n initComponents();\n }",
"public RegistrationForm() {\n initComponents();\n this.setLocationRelativeTo(null);\n }",
"public Soru1() {\n initComponents();\n }",
"public FMainForm() {\n initComponents();\n this.setResizable(false);\n setLocationRelativeTo(null);\n }",
"public soal2GUI() {\n initComponents();\n }",
"public EindopdrachtGUI() {\n initComponents();\n }",
"public MechanicForm() {\n initComponents();\n }",
"public AddDocumentLineForm(java.awt.Frame parent) {\n super(parent);\n initComponents();\n myInit();\n }",
"public BloodDonationGUI() {\n initComponents();\n }",
"public quotaGUI() {\n initComponents();\n }",
"public Customer_Form() {\n initComponents();\n setSize(890,740);\n \n \n }",
"public PatientUI() {\n initComponents();\n }",
"public myForm() {\n\t\t\tinitComponents();\n\t\t}",
"public Oddeven() {\n initComponents();\n }",
"public intrebarea() {\n initComponents();\n }",
"public Magasin() {\n initComponents();\n }",
"public RadioUI()\n {\n initComponents();\n }",
"public NewCustomerGUI() {\n initComponents();\n }",
"public ZobrazUdalost() {\n initComponents();\n }",
"public FormUtama() {\n initComponents();\n }",
"public p0() {\n initComponents();\n }",
"public INFORMACION() {\n initComponents();\n this.setLocationRelativeTo(null); \n }",
"public ProgramForm() {\n setLookAndFeel();\n initComponents();\n }",
"public AmountReleasedCommentsForm() {\r\n initComponents();\r\n }",
"public form2() {\n initComponents();\n }",
"public MainForm() {\n\t\tsuper(\"Hospital\", List.IMPLICIT);\n\n\t\tstartComponents();\n\t}",
"public kunde() {\n initComponents();\n }",
"public LixeiraForm() {\n initComponents();\n setLocationRelativeTo(null);\n }",
"@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setName(\"Form\"); // NOI18N\n setRequestFocusEnabled(false);\n setVerifyInputWhenFocusTarget(false);\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 465, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 357, Short.MAX_VALUE)\n );\n }",
"public MusteriEkle() {\n initComponents();\n }",
"public frmMain() {\n initComponents();\n }",
"public frmMain() {\n initComponents();\n }",
"public DESHBORDPANAL() {\n initComponents();\n }",
"public frmVenda() {\n initComponents();\n }",
"public GUIForm() {\n initComponents();\n inputField.setText(NO_FILE_SELECTED);\n outputField.setText(NO_FILE_SELECTED);\n progressLabel.setBackground(INFO);\n progressLabel.setText(SELECT_FILE);\n }",
"public Botonera() {\n initComponents();\n }",
"public FrmMenu() {\n initComponents();\n }",
"public OffertoryGUI() {\n initComponents();\n setTypes();\n }",
"public JFFornecedores() {\n initComponents();\n }",
"@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents()\n {\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n setBackground(new java.awt.Color(255, 255, 255));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 983, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 769, Short.MAX_VALUE)\n );\n\n pack();\n }",
"public EnterDetailsGUI() {\n initComponents();\n }",
"public vpemesanan1() {\n initComponents();\n }",
"public Kost() {\n initComponents();\n }",
"public FormHorarioSSE() {\n initComponents();\n }",
"public frmacceso() {\n initComponents();\n }",
"public UploadForm() {\n initComponents();\n }",
"public HW3() {\n initComponents();\n }",
"public Managing_Staff_Main_Form() {\n initComponents();\n }",
"@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents()\n {\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n getContentPane().setLayout(null);\n\n pack();\n }",
"@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setName(\"Form\"); // NOI18N\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 400, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 300, Short.MAX_VALUE)\n );\n }",
"public sinavlar2() {\n initComponents();\n }",
"public P0405() {\n initComponents();\n }",
"public IssueBookForm() {\n initComponents();\n }",
"public MiFrame2() {\n initComponents();\n }",
"public Choose1() {\n initComponents();\n }",
"public MainForm() {\n initComponents();\n\n String oldAuthor = prefs.get(\"AUTHOR\", \"\");\n if(oldAuthor != null) {\n this.authorTextField.setText(oldAuthor);\n }\n String oldBook = prefs.get(\"BOOK\", \"\");\n if(oldBook != null) {\n this.bookTextField.setText(oldBook);\n }\n String oldDisc = prefs.get(\"DISC\", \"\");\n if(oldDisc != null) {\n try {\n int oldDiscNum = Integer.parseInt(oldDisc);\n oldDiscNum++;\n this.discNumberTextField.setText(Integer.toString(oldDiscNum));\n } catch (Exception ex) {\n this.discNumberTextField.setText(oldDisc);\n }\n this.bookTextField.setText(oldBook);\n }\n\n\n }",
"public GUI_StudentInfo() {\n initComponents();\n }",
"public JFrmPrincipal() {\n initComponents();\n }",
"public Lihat_Dokter_Keseluruhan() {\n initComponents();\n }",
"public bt526() {\n initComponents();\n }",
"public Pemilihan_Dokter() {\n initComponents();\n }",
"public Ablak() {\n initComponents();\n }",
"@Override\n\tprotected void initUi() {\n\t\t\n\t}",
"@SuppressWarnings(\"unchecked\")\n\t// <editor-fold defaultstate=\"collapsed\" desc=\"Generated\n\t// Code\">//GEN-BEGIN:initComponents\n\tprivate void initComponents() {\n\n\t\tlabel1 = new java.awt.Label();\n\t\tlabel2 = new java.awt.Label();\n\t\tlabel3 = new java.awt.Label();\n\t\tlabel4 = new java.awt.Label();\n\t\tlabel5 = new java.awt.Label();\n\t\tlabel6 = new java.awt.Label();\n\t\tlabel7 = new java.awt.Label();\n\t\tlabel8 = new java.awt.Label();\n\t\tlabel9 = new java.awt.Label();\n\t\tlabel10 = new java.awt.Label();\n\t\ttextField1 = new java.awt.TextField();\n\t\ttextField2 = new java.awt.TextField();\n\t\tlabel14 = new java.awt.Label();\n\t\tlabel15 = new java.awt.Label();\n\t\tlabel16 = new java.awt.Label();\n\t\ttextField3 = new java.awt.TextField();\n\t\ttextField4 = new java.awt.TextField();\n\t\ttextField5 = new java.awt.TextField();\n\t\tlabel17 = new java.awt.Label();\n\t\tlabel18 = new java.awt.Label();\n\t\tlabel19 = new java.awt.Label();\n\t\tlabel20 = new java.awt.Label();\n\t\tlabel21 = new java.awt.Label();\n\t\tlabel22 = new java.awt.Label();\n\t\ttextField6 = new java.awt.TextField();\n\t\ttextField7 = new java.awt.TextField();\n\t\ttextField8 = new java.awt.TextField();\n\t\tlabel23 = new java.awt.Label();\n\t\ttextField9 = new java.awt.TextField();\n\t\ttextField10 = new java.awt.TextField();\n\t\ttextField11 = new java.awt.TextField();\n\t\ttextField12 = new java.awt.TextField();\n\t\tlabel24 = new java.awt.Label();\n\t\tlabel25 = new java.awt.Label();\n\t\tlabel26 = new java.awt.Label();\n\t\tlabel27 = new java.awt.Label();\n\t\tlabel28 = new java.awt.Label();\n\t\tlabel30 = new java.awt.Label();\n\t\tlabel31 = new java.awt.Label();\n\t\tlabel32 = new java.awt.Label();\n\t\tjButton1 = new javax.swing.JButton();\n\n\t\tlabel1.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel1.setText(\"It seems that some of the buttons on the ATM machine are not working!\");\n\n\t\tlabel2.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel2.setText(\"Unfortunately these numbers are exactly what Professor has to use to type in his password.\");\n\n\t\tlabel3.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 18)); // NOI18N\n\t\tlabel3.setText(\n\t\t\t\t\"If you want to eat tonight, you have to help him out and construct the numbers of the password with the working buttons and math operators.\");\n\n\t\tlabel4.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 14)); // NOI18N\n\t\tlabel4.setText(\"Denver's Password: 2792\");\n\n\t\tlabel5.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel5.setText(\"import java.util.Scanner;\\n\");\n\n\t\tlabel6.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel6.setText(\"public class ATM{\");\n\n\t\tlabel7.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel7.setText(\"public static void main(String[] args){\");\n\n\t\tlabel8.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel8.setText(\"System.out.print(\");\n\n\t\tlabel9.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel9.setText(\" -\");\n\n\t\tlabel10.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel10.setText(\");\");\n\n\t\ttextField1.addActionListener(new java.awt.event.ActionListener() {\n\t\t\tpublic void actionPerformed(java.awt.event.ActionEvent evt) {\n\t\t\t\ttextField1ActionPerformed(evt);\n\t\t\t}\n\t\t});\n\n\t\tlabel14.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel14.setText(\"System.out.print( (\");\n\n\t\tlabel15.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel15.setText(\"System.out.print(\");\n\n\t\tlabel16.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel16.setText(\"System.out.print( ( (\");\n\n\t\tlabel17.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel17.setText(\")\");\n\n\t\tlabel18.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel18.setText(\" +\");\n\n\t\tlabel19.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel19.setText(\");\");\n\n\t\tlabel20.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel20.setText(\" /\");\n\n\t\tlabel21.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel21.setText(\" %\");\n\n\t\tlabel22.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel22.setText(\" +\");\n\n\t\tlabel23.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel23.setText(\");\");\n\n\t\tlabel24.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel24.setText(\" +\");\n\n\t\tlabel25.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel25.setText(\" /\");\n\n\t\tlabel26.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel26.setText(\" *\");\n\n\t\tlabel27.setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));\n\t\tlabel27.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel27.setText(\")\");\n\n\t\tlabel28.setFont(new java.awt.Font(\"Dialog\", 0, 14)); // NOI18N\n\t\tlabel28.setText(\")\");\n\n\t\tlabel30.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel30.setText(\"}\");\n\n\t\tlabel31.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel31.setText(\"}\");\n\n\t\tlabel32.setFont(new java.awt.Font(\"Consolas\", 0, 14)); // NOI18N\n\t\tlabel32.setText(\");\");\n\n\t\tjButton1.setFont(new java.awt.Font(\"Segoe UI Semibold\", 0, 14)); // NOI18N\n\t\tjButton1.setText(\"Check\");\n\t\tjButton1.addActionListener(new java.awt.event.ActionListener() {\n\t\t\tpublic void actionPerformed(java.awt.event.ActionEvent evt) {\n\t\t\t\tjButton1ActionPerformed(evt);\n\t\t\t}\n\t\t});\n\n\t\tjavax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n\t\tlayout.setHorizontalGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(28).addGroup(layout\n\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING).addComponent(getDoneButton()).addComponent(jButton1)\n\t\t\t\t\t\t.addComponent(label7, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label6, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label5, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label4, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addComponent(label3, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t.addComponent(label1, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t\t\t.addComponent(label2, GroupLayout.PREFERRED_SIZE, 774, GroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t.addGap(92).addGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING, false)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label15, GroupLayout.PREFERRED_SIZE, 145,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField8, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(2)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label21, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField7, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label8, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField1, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label9, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED).addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField2, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label31, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label14, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(37))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(174)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField5, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label18, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(7)))\n\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING, false).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField4, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label17, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label22, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField9, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(20)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label23, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label20, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField3, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t20, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(20).addComponent(label19, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(23).addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel10, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label16, GroupLayout.PREFERRED_SIZE, 177,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField12, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label24, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField6, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label27, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label25, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField11, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label28, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label26, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField10, GroupLayout.PREFERRED_SIZE, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED).addComponent(label32,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t.addComponent(label30, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addContainerGap(GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)));\n\t\tlayout.setVerticalGroup(\n\t\t\t\tlayout.createParallelGroup(Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap()\n\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t.addComponent(label1, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t.addComponent(label2, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t.addGap(1)\n\t\t\t\t\t\t.addComponent(label3, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label4, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label5, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label6, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(label7, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t.addGroup(\n\t\t\t\t\t\t\t\t\t\tlayout.createSequentialGroup().addGroup(layout.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING).addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label9,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label8,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField1,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField2, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label10,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(3)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(19)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField5,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label14,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label18,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label17,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField4,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1))))\n\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label20, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label19, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField3, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE, GroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(78)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label27, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(76)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField11, GroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup().addGap(75)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label32,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField10,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED, 20,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tShort.MAX_VALUE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.TRAILING, false)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label15,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField8,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label21,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField7,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(27))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField9,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label22,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlayout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(3)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel23,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(29)))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label16,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField12,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout.createSequentialGroup()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGroup(layout\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.createParallelGroup(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tAlignment.TRAILING)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(label24,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addComponent(textField6,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.addGap(1))))))\n\t\t\t\t\t\t\t\t.addGroup(layout.createParallelGroup(Alignment.LEADING)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label25, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label28, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t\t\t\t\t.addComponent(label26, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)))\n\t\t\t\t\t\t.addGap(30)\n\t\t\t\t\t\t.addComponent(label31, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGap(25)\n\t\t\t\t\t\t.addComponent(label30, GroupLayout.PREFERRED_SIZE, GroupLayout.DEFAULT_SIZE,\n\t\t\t\t\t\t\t\tGroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t\t.addGap(26).addComponent(jButton1).addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t\t.addComponent(getDoneButton()).addContainerGap(23, Short.MAX_VALUE)));\n\t\tthis.setLayout(layout);\n\n\t\tlabel16.getAccessibleContext().setAccessibleName(\"System.out.print( ( (\");\n\t\tlabel17.getAccessibleContext().setAccessibleName(\"\");\n\t\tlabel18.getAccessibleContext().setAccessibleName(\" +\");\n\t}",
"public Pregunta23() {\n initComponents();\n }",
"public FormMenuUser() {\n super(\"Form Menu User\");\n initComponents();\n }",
"public AvtekOkno() {\n initComponents();\n }",
"public busdet() {\n initComponents();\n }",
"public ViewPrescriptionForm() {\n initComponents();\n }",
"public Ventaform() {\n initComponents();\n }",
"public Kuis2() {\n initComponents();\n }",
"public CreateAccount_GUI() {\n initComponents();\n }",
"public Carrera() {\n initComponents();\n }",
"public POS1() {\n initComponents();\n }",
"public EqGUI() {\n initComponents();\n }",
"public JFriau() {\n initComponents();\n this.setLocationRelativeTo(null);\n this.setTitle(\"BuNus - Budaya Nusantara\");\n }",
"@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n setBackground(new java.awt.Color(204, 204, 204));\n setMinimumSize(new java.awt.Dimension(1, 1));\n setPreferredSize(new java.awt.Dimension(760, 402));\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 750, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 400, Short.MAX_VALUE)\n );\n }",
"public nokno() {\n initComponents();\n }",
"public dokter() {\n initComponents();\n }",
"public ConverterGUI() {\n initComponents();\n }",
"public hitungan() {\n initComponents();\n }",
"public Modify() {\n initComponents();\n }",
"public frmAddIncidencias() {\n initComponents();\n }",
"public FP_Calculator_GUI() {\n initComponents();\n \n setVisible(true);\n }"
] | [
"0.731952",
"0.72909003",
"0.72909003",
"0.72909003",
"0.72862417",
"0.7248404",
"0.7213685",
"0.72086793",
"0.7195972",
"0.71903807",
"0.71843296",
"0.7158833",
"0.71475875",
"0.70933676",
"0.7081167",
"0.7056787",
"0.69876975",
"0.6977383",
"0.6955115",
"0.6953839",
"0.69452274",
"0.6942602",
"0.6935845",
"0.6931919",
"0.6928187",
"0.6925288",
"0.69251484",
"0.69117147",
"0.6911646",
"0.6892842",
"0.68927234",
"0.6891408",
"0.68907607",
"0.68894386",
"0.68836755",
"0.688209",
"0.6881168",
"0.68787616",
"0.68757504",
"0.68741524",
"0.68721044",
"0.685922",
"0.68570775",
"0.6855737",
"0.6855207",
"0.68546575",
"0.6853559",
"0.6852262",
"0.6852262",
"0.68443567",
"0.6837038",
"0.6836797",
"0.68291426",
"0.6828922",
"0.68269444",
"0.6824652",
"0.682331",
"0.68175536",
"0.68167555",
"0.6810103",
"0.6809546",
"0.68085015",
"0.68083894",
"0.6807979",
"0.68027437",
"0.67950374",
"0.67937446",
"0.67921823",
"0.67911226",
"0.67900467",
"0.6788873",
"0.67881",
"0.6781613",
"0.67669237",
"0.67660683",
"0.6765841",
"0.6756988",
"0.675558",
"0.6752552",
"0.6752146",
"0.6742482",
"0.67395985",
"0.673791",
"0.6736197",
"0.6733452",
"0.67277217",
"0.6726687",
"0.67204696",
"0.67168",
"0.6714824",
"0.6714823",
"0.6708782",
"0.67071444",
"0.670462",
"0.67010295",
"0.67004406",
"0.6699407",
"0.6698219",
"0.669522",
"0.66916007",
"0.6689694"
] | 0.0 | -1 |
End of variables declaration//GENEND:variables | @Override
public void update(FSBasic fsBasic) {
int time = fsBasic.hour() * 3600 + fsBasic.min() * 60 + fsBasic.sec();
// if (currTime == time) {
// return;
//}
currTime = time;
upPanel.addData(currTime);
downPanel.addData(currTime);
pitchPanel.addData(fsBasic.pitch());
rollPanel.addData(fsBasic.bank());
yawPanel.addData(fsBasic.heading());
altPanel.addData(fsBasic.altitude());
aoaPanel.addData(fsBasic.aoa());
betaPanel.addData(fsBasic.beta());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void lavar() {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t}",
"public void mo38117a() {\n }",
"@Override\r\n\tpublic void initVariables() {\n\t\t\r\n\t}",
"private void assignment() {\n\n\t\t\t}",
"private void kk12() {\n\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"public void mo21779D() {\n }",
"public final void mo51373a() {\n }",
"protected boolean func_70041_e_() { return false; }",
"public void mo4359a() {\n }",
"public void mo21782G() {\n }",
"private void m50366E() {\n }",
"public void mo12930a() {\n }",
"public void mo115190b() {\n }",
"public void method_4270() {}",
"public void mo1403c() {\n }",
"public void mo3376r() {\n }",
"public void mo3749d() {\n }",
"public void mo21793R() {\n }",
"protected boolean func_70814_o() { return true; }",
"public void mo21787L() {\n }",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo21780E() {\n }",
"public void mo21792Q() {\n }",
"public void mo21791P() {\n }",
"public void mo12628c() {\n }",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"public void mo97908d() {\n }",
"public void mo21878t() {\n }",
"public void mo9848a() {\n }",
"public void mo21825b() {\n }",
"public void mo23813b() {\n }",
"public void mo3370l() {\n }",
"public void mo21879u() {\n }",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"public void mo21785J() {\n }",
"public void mo21795T() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void m23075a() {\n }",
"public void mo21789N() {\n }",
"@Override\n\tpublic void einkaufen() {\n\t}",
"public void mo21794S() {\n }",
"public final void mo12688e_() {\n }",
"@Override\r\n\tvoid func04() {\n\t\t\r\n\t}",
"private Rekenhulp()\n\t{\n\t}",
"public void mo6944a() {\n }",
"public static void listing5_14() {\n }",
"public void mo1405e() {\n }",
"public final void mo91715d() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\r\n\tprotected void func03() {\n\t\t\r\n\t}",
"public void mo9137b() {\n }",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"public void func_70295_k_() {}",
"void mo57277b();",
"public void mo21877s() {\n }",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"public void Tyre() {\n\t\t\r\n\t}",
"void berechneFlaeche() {\n\t}",
"public void mo115188a() {\n }",
"public void mo21880v() {\n }",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"public void mo21784I() {\n }",
"private stendhal() {\n\t}",
"@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"public void mo56167c() {\n }",
"public void mo44053a() {\n }",
"public void mo21781F() {\n }",
"public void mo2740a() {\n }",
"public void mo21783H() {\n }",
"public void mo1531a() {\n }",
"double defendre();",
"private zzfl$zzg$zzc() {\n void var3_1;\n void var2_-1;\n void var1_-1;\n this.value = var3_1;\n }",
"public void stg() {\n\n\t}",
"void m1864a() {\r\n }",
"private void poetries() {\n\n\t}",
"public void skystonePos4() {\n }",
"public void mo2471e() {\n }",
"@Override\n\tprotected void getExras() {\n\n\t}",
"private void yy() {\n\n\t}",
"@Override\n\tpublic void verkaufen() {\n\t}",
"@AnyLogicInternalCodegenAPI\n private void setupPlainVariables_Main_xjal() {\n }",
"static void feladat4() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\t\t\tpublic void func02() {\n\t\t\t\t\r\n\t\t\t}",
"public void init() { \r\n\t\t// TODO Auto-generated method\r\n\t }",
"public void furyo ()\t{\n }",
"public void verliesLeven() {\r\n\t\t\r\n\t}",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"protected void mo6255a() {\n }"
] | [
"0.6359434",
"0.6280371",
"0.61868024",
"0.6094568",
"0.60925734",
"0.6071678",
"0.6052686",
"0.60522056",
"0.6003249",
"0.59887564",
"0.59705925",
"0.59680873",
"0.5967989",
"0.5965816",
"0.5962006",
"0.5942372",
"0.5909877",
"0.5896588",
"0.5891321",
"0.5882983",
"0.58814824",
"0.5854075",
"0.5851759",
"0.58514243",
"0.58418584",
"0.58395296",
"0.5835063",
"0.582234",
"0.58090156",
"0.5802706",
"0.5793836",
"0.57862717",
"0.5784062",
"0.5783567",
"0.5782131",
"0.57758564",
"0.5762871",
"0.5759349",
"0.5745087",
"0.57427835",
"0.573309",
"0.573309",
"0.573309",
"0.573309",
"0.573309",
"0.573309",
"0.573309",
"0.57326084",
"0.57301426",
"0.57266665",
"0.57229686",
"0.57175463",
"0.5705802",
"0.5698347",
"0.5697827",
"0.569054",
"0.5689405",
"0.5686434",
"0.56738997",
"0.5662217",
"0.56531453",
"0.5645255",
"0.5644223",
"0.5642628",
"0.5642476",
"0.5640595",
"0.56317437",
"0.56294966",
"0.56289655",
"0.56220204",
"0.56180173",
"0.56134313",
"0.5611337",
"0.56112075",
"0.56058615",
"0.5604383",
"0.5602629",
"0.56002104",
"0.5591573",
"0.55856615",
"0.5576992",
"0.55707216",
"0.5569681",
"0.55570376",
"0.55531484",
"0.5551123",
"0.5550893",
"0.55482954",
"0.5547471",
"0.55469507",
"0.5545719",
"0.5543553",
"0.55424106",
"0.5542057",
"0.55410767",
"0.5537739",
"0.55269134",
"0.55236584",
"0.55170715",
"0.55035424",
"0.55020875"
] | 0.0 | -1 |
Do something when server starting event dispatched. | @SubscribeEvent
public void onServerStarting(final FMLServerStartingEvent event) {
LOGGER.info("server starting...");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void onServerStarted();",
"@SubscribeEvent\n public void onServerStarting(FMLServerStartingEvent event) {\n // do something when the server starts\n Server server = new Server(event.getServer());\n }",
"@SubscribeEvent\n public void onServerStarting(FMLServerStartingEvent event) {\n LOGGER.log(Level.INFO, \"starting fabric server mods\");\n FabricLoaderImpl.INSTANCE.getEntrypoints(\"server\", DedicatedServerModInitializer.class).forEach(DedicatedServerModInitializer::onInitializeServer);\n }",
"public void start()\n/* 354: */ {\n/* 355:434 */ onStartup();\n/* 356: */ }",
"@Override\n\tpublic void contextInitialized(ServletContextEvent arg0) {\n\t\tserverAPP.start();\n\t}",
"@Listener\n public void onServerStart(GameStartedServerEvent event) {\n logger.debug(\"*************************\");\n logger.debug(\"HI! MY PLUGIN IS WORKING!\");\n logger.debug(\"*************************\");\n }",
"protected void serverStarted()\n {\n // System.out.println\n // (\"Server listening for connections on port \" + getPort());\n }",
"public void handleStart()\n {\n }",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tSystem.out.println(\"onStart\");\n\t\t\t\tif(listener!=null) listener.onMessage(\"onStart\");\n\t\t\t\tisRun = true;\n\t\t\t}",
"void onStarted();",
"protected void serverStarted()\n {\n System.out.println(\"Server listening for connections on port \" + getPort());\n }",
"protected void serverStarted()\r\n {\r\n System.out.println\r\n (\"Server listening for connections on port \" + getPort());\r\n }",
"public void onServerStart(MinecraftServer server)\n\t{\n\t\t// WARNING : integrated server work whit proxy on ClienSide.\n\t\tJLog.info(\" --- SERVER START --- \");\n\t\tElementalIntegrationHelper.initializeClass();\n\t}",
"public void startServer()\n\t{\n\t\twhile(true)\n\t\t{\n\t\t\tSystem.out.println(\"Listen\");\n\t\t\tif(listenInitialValuesRequest)\n\t\t\t{\n\t\t\t\tlistenInitialValuesRequest();\n\t\t\t}\n\t\t}\n\t}",
"@SubscribeEvent\n public void onClientStarting(final FMLClientSetupEvent event) {\n LOGGER.info(\"client setting up\");\n }",
"public static void\tload(FMLServerStartingEvent event)\r\n\t{\n\t}",
"public void startup() {\n\t\tstart();\n }",
"@Override\n\tpublic void onApplicationEvent(ContextStartedEvent event) {\n\t\tSystem.out.println(\"start event \" + event);\n\t}",
"@Override\n public void startup() {\n }",
"@Override\n\tpublic void onModServerStarting2(FMLServerStartingEvent aEvent) {\n\t}",
"public static void startServer() {\n clientListener.startListener();\n }",
"@Override\n\tpublic void onStart() {\n\t\tsuper.onStart();\n\t\tdisplayEvent();\n\t}",
"public void startup(){}",
"public void startServer() {\n server.start();\n }",
"public void onStart() {\n\t\t\n\t}",
"public void notifyStartup();",
"public void starting();",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tLog.e(\"xx\", \"onstart\");\n\n\t\t\t}",
"@Override\n\tprotected void onStart() {\n\t\tSystem.out.println(\"onStart\");\n\t}",
"@Override\n\tpublic void contextInitialized(ServletContextEvent sce) {\n\t\tstartupEvt.fire(new ContainerStartupEvent());\n\t}",
"public void onStart() {\n /* do nothing - stub */\n }",
"private void startServer() {\n\t\ttry {\n//\t\t\tserver = new Server();\n//\t\t\tserver.start();\n\t\t} catch (Exception e) {\n\t\t\t// TODO: add message in UI for user\n\t\t}\n\t}",
"@Override\n\t\t\t\t\tpublic void onStart(int what, Object[] params) {\n\n\t\t\t\t\t}",
"public void doMyStartupStuff() {\r\n\t\tSystem.out.println(\"TrackCoach: inside method doMyStartupStuff\");\r\n\t}",
"public void start() {}",
"public void start() {}",
"@Override\n\tpublic void onStartup(ServletContext servletContext)\n\t\t\tthrows ServletException {\n\t\tsuper.onStartup(servletContext);//master line where whole framework works\n\t\t//configure global objects/tasks if required\n\t}",
"public void onStarted(long startedTime);",
"public void doMyStartupStuff() {\n System.out.println(\"init method\");\n }",
"public void start() throws IOException {\n\t\tserverSocket = new ServerSocket(port);\n\t\tserverCallbacks.forEach(c -> c.onServerStarted(this, port));\n\t}",
"public void start() {\n System.err.println(\"Server will listen on \" + server.getAddress());\n server.start();\n }",
"@Override\n\tprotected void onStart() {\n\t\tsuper.onStart();\n\t\tSystem.out.println(\"onStart...\");\n\t}",
"public void onStart() {\n super.onStart();\n this.eventDelegate.onStart();\n }",
"protected void serverStarting(final ComponentManager manager) {\n OpenGammaComponentServerMonitor.create(manager.getRepository());\n }",
"@PostConstruct\r\n\tpublic void doMyStartUpStuff() {\r\n\t\t\r\n\t\tSystem.out.println(\"TennisCoach : -> Inside of doMyStartUpStuff()\");\r\n\t}",
"public void onStart() {\n }",
"public void startEventHandler() {\n Thread eventThread = new Thread(this, \"Nxt Event Handler\");\n eventThread.setDaemon(true);\n eventThread.start();\n }",
"@Override\r\n\tpublic void startEvent() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void startEvent() {\n\t\t\r\n\t}",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tLog.e(\"xx\",\"onstart\");\n\n\t\t\t}",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tLog.e(\"xx\",\"onstart\");\n\n\t\t\t}",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tLog.e(\"xx\",\"onstart\");\n\n\t\t\t}",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tLog.e(\"xx\",\"onstart\");\n\n\t\t\t}",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tLog.e(\"xx\",\"onstart\");\n\n\t\t\t}",
"@Override\n\tpublic void onModServerStarted2(FMLServerStartedEvent aEvent) {\n\t}",
"public void onStart() {\n }",
"@Override\n\tpublic void onStart() {\n\t\tnew Starfire();\n\t}",
"void onSuccessfulStarted();",
"public void processStart(){\n initWorkerQueue();\n DataBean serverArgs = new DataBean();\n serverArgs.setValue(\"mode\",\"server\");\n serverArgs.setValue(\"messagekey\",\"72999\");\n serverArgs.setValue(\"user\",\"auth\");\n serverArgs.setValue(\"messagechannel\",\"/esb/system\");\n messageClient = new MessageClient(this,serverArgs);\n Helper.writeLog(1,\"starting message server\");\n messageClient.addHandler(this);\n \n }",
"@PostConstruct\n\tpublic void doMyStartupStfff() {\n\t\tSystem.out.println(\">> TennisCoach: inside of doMyStartupStuff\");\n\t}",
"@Override\n public void onStart() {\n System.out.println(\"ONstart\");\n super.onStart();\n\n }",
"public void run(){\n\t\tstartServer();\n\t}",
"@Override\n public void preStart() {\n //#subscribe\n cluster.subscribe(getSelf(), ClusterEvent.initialStateAsEvents(),\n ClusterEvent.MemberEvent.class, ClusterEvent.UnreachableMember.class);\n //#subscribe\n }",
"@Override\n\tpublic void onStart(ITestContext arg0) {\n\t\tSystem.out.println(\"when started\");\n\t}",
"protected void start() {\n }",
"public void startup()\n\t{\n\t\t; // do nothing\n\t}",
"void onStart(@Observes Startup event, ApplicationLifecycle app) {\n\n\t\tif (!newstore)\n\t\t\tapp.markAsRestart();\n\t\t\n\t}",
"@Override\n public void firstApplicationStartup()\n {\n System.out.println(\"firstApplicationStartup\");\n \n }",
"public void onStart() {\n\t\tnew Thread() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\tinitConnection();\n\t\t\t\treceive();\n\t\t\t}\n\t\t}.start();\n\t}",
"public abstract void startup();",
"public void start() {\n _serverRegisterProcessor = new ServerRegisterProcessor();\n _serverRegisterProcessor.start();\n }",
"@Override\n public void initialize() {\n\n try {\n /* Bring up the API server */\n logger.info(\"loading API server\");\n apiServer.start();\n logger.info(\"API server started. Say Hello!\");\n /* Bring up the Dashboard server */\n logger.info(\"Loading Dashboard Server\");\n if (dashboardServer.isStopped()) { // it may have been started when Flux is run in COMBINED mode\n dashboardServer.start();\n }\n logger.info(\"Dashboard server has started. Say Hello!\");\n } catch (Exception e) {\n throw new RuntimeException(e);\n }\n }",
"@Override\n @SuppressWarnings(\"CallToPrintStackTrace\")\n public void simpleInitApp() {\n \n\n try {\n System.out.println(\"Using port \" + port);\n // create the server by opening a port\n server = Network.createServer(port);\n server.start(); // start the server, so it starts using the port\n } catch (IOException ex) {\n ex.printStackTrace();\n destroy();\n this.stop();\n }\n System.out.println(\"Server started\");\n // create a separat thread for sending \"heartbeats\" every now and then\n new Thread(new NetWrite()).start();\n server.addMessageListener(new ServerListener(), ChangeVelocityMessage.class);\n // add a listener that reacts on incoming network packets\n \n }",
"@Override\r\n public void start() {\r\n }",
"@Override\r\n protected void start() throws StartException {\n\r\n if (!Main.INIT_COMPLETE.isReached()) startServer();\r\n new EDTRunner() {\r\n\r\n @Override\r\n protected void runInEDT() {\r\n initGUI();\r\n }\r\n };\r\n\r\n }",
"@Override\n public void start() {}",
"public void start()\n {}",
"public void start() {\n System.out.println(\"server started\");\n mTerminalNetwork.listen(mTerminalConfig.port);\n }",
"public void start() {\n }",
"@Override public void start() {\n }",
"public abstract void started();",
"@Override\r\n\tpublic void tellStarting() {\r\n\t\t// TODO Auto-generated method stub\r\n\r\n\t\t// Not used here\r\n\t}",
"void doManualStart();",
"private void start() {\n\n\t}",
"public void start(){\n }",
"@Override\n public void preStart() {\n cluster.subscribe(self(), ClusterEvent.MemberUp.class);\n }",
"public abstract void tellStarting();",
"@Override\n\t\t\t\tpublic void onStart() {\n\t\t\t\t}",
"public void startServer() {\n URLClassLoader loader = createClasspath(opts);\n X_Process.runInClassloader(loader, appServer\n .map(DevAppServer::doStartServer, getAppName() + \"Server\", getPort())\n .ignoreOut1().unsafe());\n }",
"@Override\n public void start() {\n }",
"@Override\n public void start() {\n }",
"@Override\n public void start() {\n }",
"@Override\n public void start() {\n }",
"@Override\n public void start() {\n }",
"@Override\n public void start() {\n }",
"@Override\n public void start() {\n }",
"public void doMyStartupStuff(){\r\n System.out.println(\"TrackCoach: inside method doMyStartupStuff\");\r\n }",
"@Override\n public void start() { }",
"@Override\n protected void appStart() {\n }",
"void onListeningStarted();"
] | [
"0.78394496",
"0.78318083",
"0.74557763",
"0.74238616",
"0.71824485",
"0.71267456",
"0.7126087",
"0.701329",
"0.70126975",
"0.6997693",
"0.6980449",
"0.69466645",
"0.68456084",
"0.68234825",
"0.6728248",
"0.66981965",
"0.66907537",
"0.66903555",
"0.6671707",
"0.66705847",
"0.6666333",
"0.66399336",
"0.6593423",
"0.65710837",
"0.6562571",
"0.65315694",
"0.65307415",
"0.6528254",
"0.65149975",
"0.651298",
"0.64940286",
"0.64839786",
"0.6475887",
"0.6447161",
"0.64321923",
"0.64321923",
"0.6430432",
"0.642027",
"0.64158684",
"0.64098704",
"0.64090055",
"0.6400349",
"0.6395808",
"0.6392238",
"0.6387499",
"0.63818353",
"0.6380257",
"0.63764024",
"0.63764024",
"0.63705635",
"0.63705635",
"0.63705635",
"0.63705635",
"0.63705635",
"0.636553",
"0.63541126",
"0.6349405",
"0.6306229",
"0.6306006",
"0.63028127",
"0.6300346",
"0.629554",
"0.6294869",
"0.6285404",
"0.62852496",
"0.62791806",
"0.62746286",
"0.62692094",
"0.6263959",
"0.62537855",
"0.6247838",
"0.6247783",
"0.6243339",
"0.62298983",
"0.6226186",
"0.62163275",
"0.62114793",
"0.62081736",
"0.6207187",
"0.6205471",
"0.6200867",
"0.6200746",
"0.61883104",
"0.61880094",
"0.61802554",
"0.6180051",
"0.6176054",
"0.6174144",
"0.6171449",
"0.6170635",
"0.6170635",
"0.6170635",
"0.6170635",
"0.6170635",
"0.6170635",
"0.6170635",
"0.6164891",
"0.61611915",
"0.61611265",
"0.6160763"
] | 0.8064511 | 0 |
Do something when client setup event dispatched. | @SubscribeEvent
public void onClientStarting(final FMLClientSetupEvent event) {
LOGGER.info("client setting up");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void onSetup(ProcessingSetup processingSetup);",
"@Override\r\n\tprotected final void setup() {\r\n \tsuper.setup();\r\n\r\n \tdoSetup();\r\n }",
"public void send_setup()\n {\n out.println(\"chain_setup\");\n }",
"private void commonSetup(FMLCommonSetupEvent event) {\n WorldGen.addWorldGen();\n\n // Add all messaging\n DreamEventListener.registerMessages();\n }",
"void addSetupEvent(SetupEvent setupEvent);",
"public static void initClient() {\n BundleEvents.register();\n }",
"private void onCallSetup(int callsetup, byte[] address) {\n StackEvent event = new StackEvent(StackEvent.EVENT_TYPE_CALLSETUP);\n event.valueInt = callsetup;\n event.device = getDevice(address);\n if (DBG) {\n Log.d(TAG, \"onCallSetup: addr \" + address + \" device\" + event.device);\n Log.d(TAG, \"onCallSetup: address \" + address + \" event \" + event);\n }\n HeadsetClientService service = HeadsetClientService.getHeadsetClientService();\n if (service != null) {\n service.messageFromNative(event);\n } else {\n Log.w(TAG, \"onCallSetup: Ignoring message because service not available: \" + event);\n }\n }",
"private void onCallSetup(int callsetup, byte[] address) {\n StackEvent event = new StackEvent(StackEvent.EVENT_TYPE_CALLSETUP);\n event.valueInt = callsetup;\n event.device = getDevice(address);\n if (DBG) {\n Log.d(TAG, \"onCallSetup: addr \" + address + \" device\" + event.device);\n Log.d(TAG, \"onCallSetup: address \" + address + \" event \" + event);\n }\n HeadsetClientService service = HeadsetClientService.getHeadsetClientService();\n if (service != null) {\n service.messageFromNative(event);\n } else {\n Log.w(TAG, \"onCallSetup: Ignoring message because service not available: \" + event);\n }\n }",
"private final void doSetup() {\r\n \tsetEnvironmentVariables();\r\n \t\r\n \tcreateAppWindows();\r\n \t\r\n \tcreateAppPages();\r\n\r\n \t//Set the default resource bundle. This necessary even for non-L10N tests, because even they\r\n \t// need to call localizeFieldLocators()\r\n\t\tsetResourceBundle(DDConstants.DEFAULT_L10N_BUNDLE);\r\n\t\t\r\n\t\t//MUST be called after super.setup!!!\r\n \t//NOTE that ddUser is the equivalent of a user that is found in the setup screen.\r\n \t// The user that logs in to the app is known as the auto user. Until we figure out\r\n \t// whether that model applies, don't call this.\r\n \t//setDDUser();\r\n }",
"void clientReady();",
"public void ondemandSetupIsDone();",
"public void preSetup() {\r\n // Any of your pre setup before the loop starts should go here\r\n }",
"public void preSetup() {\r\n // Any of your pre setup before the loop starts should go here\r\n\r\n }",
"protected abstract void setup();",
"@PostConstruct\r\n\tpublic void doMyStartUpStuff() {\r\n\t\t\r\n\t\tSystem.out.println(\"TennisCoach : -> Inside of doMyStartUpStuff()\");\r\n\t}",
"@PostConstruct\n\tpublic void doMyStartupStfff() {\n\t\tSystem.out.println(\">> TennisCoach: inside of doMyStartupStuff\");\n\t}",
"@PostConstruct // called after dependencies are injected\n public void setup(){\n if(fileExistsRemoteProxy != null){\n fileExistsRemoteProxy.subscribe(this.fileExistsWebDialog.getID(), this);\n }\n }",
"public void commonSetup(FMLCommonSetupEvent event){\n PacketHandler.registerMessages();\n// config = new Configuration(event.getSuggestedConfigurationFile());\n// ConfigHandler.readConfig();\n }",
"public void doMyStartupStuff() {\r\n\t\tSystem.out.println(\"TrackCoach: inside method doMyStartupStuff\");\r\n\t}",
"@Before\n\tpublic void setup() {\n\n\t\tclient = ClientBuilder.newClient();\n\n\t}",
"private ClientBootstrap() {\r\n init();\r\n }",
"public void preInstallHook() {\n }",
"@Override\n\tpublic void initialize() {\n\t\tSystem.out.println(\"TestClient initialization\");\n\t\tsubscribe(\"Scalars\");\n\t\tsubscribe(\"Triggers\");\n\t\tsubscribe(\"Alarms\");\n\n\t\t//If I'm a sender, run some tests\n\t\tif (_sender) {\n//\t\t\ttestIntArray();\n//\t\t\ttestSerializedObject();\n//\t\t\ttestStringArray();\n//\t\t\ttestDoubleArray();\n//\t\t\ttestString();\n//\t\t\ttestByteArray();\n//\t\t\ttestStreamedMessage();\n\t\t\tstressTest();\n\t\t}\n\t}",
"public boolean setup() throws exceptions.ExitProgram {\n\t\tthis.showNamedMessage(\"Setting up the client...\");\n\t\tboolean success = false;\n\n\t\tboolean successFileSystem = this.setupFileSystem();\n\t\tboolean succesSocket = this.setupSocket();\n\t\tboolean succesNetwork = this.setupOwnAddress();\n\t\tboolean succesServer = this.setServer();\n\t\tboolean succesSession = this.setupStartSession();\n\n\t\tsuccess = successFileSystem && succesSocket && succesNetwork \n\t\t\t\t&& succesServer && succesSession;\n\t\t\n\t\tif (success) {\n\t\t\tthis.showNamedMessage(\"Setup complete!\");\n\t\t}\n\t\t\n\t\treturn success;\n\t}",
"public void autonomousInit() {\n }",
"public void autonomousInit() {\n }",
"public void autonomousInit() {\n \n }",
"protected void setup() {\n\t\t\t\t\tDFAgentDescription dfd = new DFAgentDescription();\n\t\t\t\t\tdfd.setName(getAID());\n\t\t\t\t\tServiceDescription sd = new ServiceDescription();\n\t\t\t\t\tsd.setType(\"wHOST\");\n\t\t\t\t\tsd.setName(\"wumpus-host-\" + Math.random());\n\t\t\t\t\tdfd.addServices(sd);\n\t\t\t\t\t\n\t\t\t\t\ttry {\n\t\t\t\t\t\tDFService.register(this, dfd);\n\t\t\t\t\t\thostMap = new WumpusMapHost();\n\t\t\t\t\t\tSystem.out.println(\"Registered as a host in the DF Service.\");\n\t\t\t\t\t\tlogic = new WumpusLogic();\n\t\t\t\t\t\tlogic.setHostMap(hostMap.getMap());\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\tcatch (FIPAException fe) {\n\t\t\t\t\t\tfe.printStackTrace();\n\t\t\t\t\t}\n\t\t\n\t\t// Printing out a message stating that the agent is ready for service.\n\t\tSystem.out.println(\"Wumpus host \"+getAID().getName()+\" is ready.\");\n\t\t\n\t\taddBehaviour(new TickerBehaviour(this, 1000) {\n\t\t\tprotected void onTick() {\n\t\t\t\tmyAgent.addBehaviour(new HandleRequest());\n\t\t\t}\n\t\t});\n\t \t\n\t\t\n\t}",
"@Override\n public void autonomousInit() {\n }",
"@Override\n public void autonomousInit() {\n }",
"@Override\r\n\tprotected void setup() {\n\t\tgetContentManager().registerLanguage(codec);\r\n\t\tgetContentManager().registerOntology(ontology);\r\n\t\t\r\n\t\tObject[] args = getArguments();\r\n\t\tif(args != null && args.length > 0) {\r\n\t\t\tbroker = (Broker)args[0];\r\n\t\t} else {\r\n\t\t\tbroker = new Broker(\"Broker\");\r\n\t\t}\r\n\t\t\r\n\t\tProgramGUI.getInstance().printToLog(broker.hashCode(), getLocalName(), \"created\", Color.GREEN.darker());\r\n\t\t\r\n\t\t// Register in the DF\r\n\t\tDFRegistry.register(this, BROKER_AGENT);\r\n\t\t\r\n\t\tsubscribeToRetailers();\r\n\t\tquery();\r\n\t\tpurchase();\r\n\t}",
"@Override\n protected void preClientStart() {\n client.registerListener(new BuddycloudLocationChannelListener(\n getContentResolver()\n ));\n client.registerListener(new BuddycloudChannelMetadataListener(\n getContentResolver()\n ));\n BCConnectionAtomListener atomListener = new BCConnectionAtomListener(\n getContentResolver(), this);\n registerListener(atomListener);\n }",
"public void setupServer(EventInterface server) throws RemoteException {\r\n this.server = server;\r\n this.agentID = server.connect(this);\r\n }",
"@Override\n\tpublic void autonomousInit() {\n\t}",
"public void autonomousInit() {\n\t\t\n\t}",
"public void doMyStartupStuff() {\n System.out.println(\"init method\");\n }",
"public void clientModSetup(){\n\t\tRenderingRegistry.registerEntityRenderingHandler(Content.mercEntityType.get(), RenderMercenary::new );\n\t\tScreenManager.registerFactory(Content.mercContainerType.get(), GUIContainerMercenary::new);\n\t}",
"@Override\n protected void doPreSetup() throws Exception {\n broker = new EmbeddedActiveMQ();\n deleteDirectory(\"target/data\");\n port = AvailablePortFinder.getNextAvailable();\n brokerUri = \"tcp://localhost:\" + port;\n configureBroker(this.broker);\n startBroker();\n }",
"@Override\r\n\tprotected void onStart() {\n\t\tsuper.onStart();\r\n\t\tUiUpdater.registerClient(handler);\r\n\t\tupdateUI();\r\n\t}",
"protected void setup() {\r\n }",
"@Override\n public void autonomousInit() {\n \n }",
"public void notifyStartup();",
"@Override\n\tpublic void setup()\n\t{\n\t\tCoreNotifications.get().addListener(this, ICoreContextOperationListener.class);\n\t\tCoreNotifications.get().addListener(this, ICoreProcedureInputListener.class);\n\t\tCoreNotifications.get().addListener(this, ICoreProcedureRuntimeListener.class);\n\t\tCoreNotifications.get().addListener(this, ICoreProcedureOperationListener.class);\n\t}",
"@Override\n public void onReady(ReadyEvent event) {\n\n }",
"@Before\r\n public void setUp() {\r\n clientAuthenticated = new MockMainServerForClient();\r\n }",
"@Override\n protected void setup() {\n // exception handling for invoke the main2();\n try {\n main2();\n } catch (StaleProxyException e) {\n e.printStackTrace();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n // create central agent of the application\n try {\n AgentController Main = main1.createNewAgent(\"Main\",\"test.Main\",null);\n Main.start();\n } catch (StaleProxyException e) {\n e.printStackTrace();\n }\n try {\n showResualt();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }",
"@EventHandler\n public void preInit(FMLPreInitializationEvent event) {\n System.out.println(\"TFCEngineer: Pre init\");\n\n TFCEConfigs.preInit(event);\n\n TFCEItems.registerItems();\n\n TFCEBlocks.registerBlocks();\n TFCEBlocks.registerTileEntities();\n\n proxy.registerGUIHandler();\n\n proxy.registerNetworkChannel();\n proxy.registerPackets();\n }",
"protected void setUp() {\n\t\tif (!Message.configure(\"wordsweeper.xsd\")) {\r\n\t\t\tfail (\"unable to configure protocol\");\r\n\t\t}\r\n\t\t\r\n\t\t// prepare client and connect to server.\r\n\t\tmodel = new Model();\r\n\t\t\r\n\t\t\r\n\t\tclient = new Application (model);\r\n\t\tclient.setVisible(true);\r\n\t\t\r\n\t\t// Create mockServer to simulate server, and install 'obvious' handler\r\n\t\t// that simply dumps to the screen the responses.\r\n\t\tmockServer = new MockServerAccess(\"localhost\");\r\n\t\t\r\n\t\t// as far as the client is concerned, it gets a real object with which\r\n\t\t// to communicate.\r\n\t\tclient.setServerAccess(mockServer);\r\n\t}",
"public void setUp() {\n _notifier = new EventNotifier();\n _doc = new DefinitionsDocument(_notifier);\n }",
"@Override\n\tpublic void onStart() {\n\t\tsuper.onStart();\n\t\tdisplayEvent();\n\t}",
"public abstract void onInit();",
"@Override\n public void postBootSetup() {\n }",
"public void onInitHandler() {\n }",
"@Override\n\tpublic void onStartup(ServletContext servletContext)\n\t\t\tthrows ServletException {\n\t\tsuper.onStartup(servletContext);//master line where whole framework works\n\t\t//configure global objects/tasks if required\n\t}",
"@SuppressWarnings(\"ConstantConditions\")\n @Inject(method = \"setupServer()Z\", at = @At(\"RETURN\"))\n public void setupServer(CallbackInfoReturnable<Boolean> info) {\n // Make sure that the server successfully started\n if (info.getReturnValueZ()) {\n IdleShutdownServer.INSTANCE.getShutdownController().notifyServerStart((MinecraftDedicatedServer)(Object)this);\n }\n }",
"public void onEnable()\n\t{\n\t\t//Tells the user that the plugin is starting up.\n\t\tlog.info(\"Started up.\");\n\t}",
"public void doMyStartupStuff(){\r\n System.out.println(\"TrackCoach: inside method doMyStartupStuff\");\r\n }",
"public void notifyStartup(StartupEvent event) {\n this.eventHandler = new MyEventHandler2(popSize);\r\n\t\t//event.addHandler(this.eventHandler);\r\n\t}",
"public static void setUpServer() {\n\t\tList<ServerDefinition> srvToSC0CascDefs = new ArrayList<ServerDefinition>();\r\n\t\tServerDefinition srvToSC0CascDef = new ServerDefinition(TestConstants.COMMUNICATOR_TYPE_PUBLISH, TestConstants.logbackSrv, TestConstants.pubServerName1,\r\n\t\t\t\tTestConstants.PORT_PUB_SRV_TCP, TestConstants.PORT_SC0_TCP, 1, 1, TestConstants.pubServiceName1);\r\n\t\tsrvToSC0CascDefs.add(srvToSC0CascDef);\r\n\t\tSystemSuperTest.srvDefs = srvToSC0CascDefs;\r\n\t}",
"@Override\r\n\t@Before\r\n\tpublic void callSetup() throws Exception\r\n\t{\r\n\t\tsuper.callSetup();\r\n\t}",
"public void setupEvent(Controller controller) {\n this.cylinderContainer.setOnMouseClicked(e -> controller.setSelectedPiece(this));\n }",
"@Override\n\tprotected void setup() {\n\t\t{\n\t\t\tKeyPairGenerator kpg = null;\n\t\t\ttry {\n\t\t\t\tkpg = KeyPairGenerator.getInstance(\"RSA\");\n\t\t\t} catch (NoSuchAlgorithmException e) {\n\t\t\t\te.printStackTrace(); // There is such an algorithm\n\t\t\t}\n\t\t\tkpg.initialize(GlobalPreferences.getKeysize(), new SecureRandom());\n\t\t\tkeys = kpg.genKeyPair();\n\t\t\t\n\t\t\tMLoginInitiate loginInitiate = new MLoginInitiate(keys.getPublic());\n\t\t\tputMessage(loginInitiate);\n\t\t}\n\t\t\n\t\twhile(!loginCompleted)\n\t\t{\n\t\t\ttry {\n\t\t\t\tThread.sleep(50); // Wait a bit for response\n\t\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\tputMessage(new MLoginCompleted(loginSuccess, -2, \"admin\", \"admin\", false));\n\t}",
"public void onStart(LoadScenarioInfo loadScenarioInfo){\n }",
"public void setupEvent(AbstractController controller) {\n this.cylinderContainer.setOnMouseClicked(e -> controller.setSelectedPiece(this));\n }",
"void preInit();",
"void preInit();",
"@Override\n\tpublic void contextInitialized(ServletContextEvent sce) {\n\t\tstartupEvt.fire(new ContainerStartupEvent());\n\t}",
"protected void setup() {\n\t\tSystem.out.println(\"Messenger agent \"+getAID().getName()+\" is ready.\");\r\n\t\tagentList = new ArrayList();\r\n\t\trefreshActiveAgents();\r\n\r\n\t\tmessageGUI = new MessageAgentGui(this);\r\n\t\tmessageGUI.displayGUI();\r\n\r\n\t\tDFAgentDescription dfd = new DFAgentDescription();\r\n\t\tdfd.setName(getAID());\r\n\t\tServiceDescription sd = new ServiceDescription();\r\n\t\tsd.setType(\"messenger-agent\");\r\n\t\tsd.setName(getLocalName()+\"-Messenger agent\");\r\n\t\tdfd.addServices(sd);\r\n\t\ttry {\r\n\t\t\tDFService.register(this, dfd);\r\n\t\t}\r\n\t\tcatch (FIPAException fe) {\r\n\t\t\tfe.printStackTrace();\r\n\t\t}\r\n\t\taddBehaviour(new ReceiveMessage());\r\n\t}",
"protected void initSDK() {\n\t\tSMSSDK.initSDK(this,\"672e0e8c7203\",\"c3728cc22e8e1d75501de2a100b4586c\");\n\t\tEventHandler eventHandler = new EventHandler() {\n\t\t\tpublic void afterEvent(int event, int result, Object data) {\n\t\t\t\tMessage msg = new Message();\n\t\t\t\tmsg.arg1 = event;\n\t\t\t\tmsg.arg2 = result;\n\t\t\t\tmsg.obj = data;\n\t\t\t\thandler.sendMessage(msg);\n\t\t\t}\n\t\t};\n\t\n\t\tSMSSDK.registerEventHandler(eventHandler);\n\t\tready=true;\n\t}",
"private void initSetUp()\n\t{\n\t\tthis.setActionName(NAME);\n\t\tthis.setDescription(DESCRIPTION);\n\t\tthis.setMagic(IS_MAGIC);\n\t\tthis.setAttack(IS_ATTACK);\n\t\tthis.setTargetSelf(IS_TARGET_SELF);\n\t\tthis.setInternalName(INTERNAL_NAME);\n\t}",
"public void clientReady(String user){\r\n\t\tuserReady.put(user, true);\t\r\n\t\tthis.checkState();\r\n\t}",
"public void clientInfo() {\n uiService.underDevelopment();\n }",
"void onServerStarted();",
"@Override\r\n\tprotected void processInit() {\n\t\t\r\n\t}",
"@Override\n\t\t\tpublic void onStart() {\n\t\t\t\tSystem.out.println(\"onStart\");\n\t\t\t\tif(listener!=null) listener.onMessage(\"onStart\");\n\t\t\t\tisRun = true;\n\t\t\t}",
"public void consulterEvent() {\n\t\t\n\t}",
"@Override\n\tpublic void earlyStartup() {\n\t}",
"@Override\n public void preStart() {\n cluster.subscribe(self(), ClusterEvent.MemberUp.class);\n }",
"@Override\n\tpublic void beforeClassSetup() {\n\t\t\n\t}",
"@Override\n public void startup() {\n }",
"public void onStart() {\n /* do nothing - stub */\n }",
"@Override\r\n\tpublic void initEvent() {\n\r\n\t}",
"public void start()\n/* 354: */ {\n/* 355:434 */ onStartup();\n/* 356: */ }",
"private void initializeEvents() {\r\n\t}",
"public void onStart() {\n super.onStart();\n this.eventDelegate.onStart();\n }",
"@java.lang.Override\n public boolean getDidSetup() {\n return didSetup_;\n }",
"public void initEventsAndProperties() {\r\n }",
"private void handleGroupInitStubEvent(GroupInitStubEvent event) throws AppiaEventException {\n \t\tevent.loadMessage();\n \n \t\tSystem.out.println(\"Received a new client connecting to me for group: \" + event.getGroup().id);\n \n \t\t//Let's get the arguments\n \t\tEndpt clientEndpt = event.getEndpoint();\n \n \n \t\t//Let's create the client\n \t\tVsClient newClient = new VsClient(clientEndpt, \n \t\t\t\tevent.getGroup(), (InetSocketAddress) event.source, listenAddress);\n \n \t\t//Let's warn everybody that a client wishes to Join\n \t\tNewClientProxyEvent newClientProxyEvent = new NewClientProxyEvent(newClient, clientEndpt);\n \t\tsendToOtherServers(newClientProxyEvent);\n \t\tsendToMyself(newClientProxyEvent);\n \t}",
"@Override\n @SideOnly(Side.CLIENT)\n public void onClientPostInit()\n {\n\n }",
"public void onStart(ISuite arg0) {\n\t\t\r\n\t}",
"@Before\n \tpublic static void setup() {\n \t\trenderArgs.put(\"base\", request.getBase());\n\t\tString location = request.getBase() + \"/services/RawService.wsdl\";\n \t\trenderArgs.put(\"wsdl\", location);\n \t}",
"@Override\r\n\tprotected void processInit() {\n\r\n\t}",
"void setupExternalMessages();",
"@SubscribeEvent\n public static void onCommonSetupEvent(FMLCommonSetupEvent event) {\n CapabilityManager.INSTANCE.register(TransactionsCapability.class, new TransactionsCapability.TransactionsCapabilityStorage(), TransactionsCapability::new);\n }",
"abstract void setup();",
"@Override\n protected void setup() {\n }",
"public void registerCustomerToEvent(Client client) {\n\n\t}",
"private void initializeStartup()\n {\n /* Turn off Limelight LED when first started up so it doesn't blind drive team. */\n m_limelight.turnOffLED();\n\n /* Start ultrasonics. */\n m_chamber.startUltrasonics();\n }",
"public void setup() {\n }",
"@Override\n protected void startUp() {\n }"
] | [
"0.66120344",
"0.641776",
"0.6411881",
"0.6386369",
"0.6354009",
"0.63386595",
"0.6272844",
"0.6272844",
"0.61889106",
"0.6174571",
"0.6172607",
"0.6108849",
"0.6079519",
"0.6051608",
"0.6021239",
"0.59921265",
"0.59794736",
"0.5963063",
"0.5956539",
"0.5948703",
"0.5924805",
"0.5918155",
"0.59003264",
"0.58682424",
"0.58681446",
"0.58681446",
"0.5836892",
"0.58346844",
"0.58295166",
"0.58295166",
"0.5814871",
"0.5799248",
"0.57936543",
"0.57881993",
"0.5786222",
"0.5766867",
"0.5761499",
"0.57494855",
"0.5748691",
"0.57392484",
"0.5724697",
"0.57147765",
"0.571414",
"0.56928015",
"0.5677714",
"0.56730586",
"0.56718355",
"0.5664812",
"0.5660245",
"0.5660205",
"0.5657552",
"0.56563324",
"0.5654551",
"0.5652747",
"0.565063",
"0.5650317",
"0.5648396",
"0.56417143",
"0.56400144",
"0.5637562",
"0.5629097",
"0.562422",
"0.5615567",
"0.5607618",
"0.56054896",
"0.56054896",
"0.5602112",
"0.5595563",
"0.5590137",
"0.55894655",
"0.5582488",
"0.5582421",
"0.55816317",
"0.5572755",
"0.55659294",
"0.55625385",
"0.5556579",
"0.5552072",
"0.55462873",
"0.55422235",
"0.55419374",
"0.5536197",
"0.55283827",
"0.55189586",
"0.5511797",
"0.5502374",
"0.5501297",
"0.54978263",
"0.5495759",
"0.54941344",
"0.5489414",
"0.5489039",
"0.54865324",
"0.54837084",
"0.5482746",
"0.54792553",
"0.5478567",
"0.5475347",
"0.54742557",
"0.54721683"
] | 0.80781525 | 0 |
Unregisters all the watchers. | public void clearAllWatchers() {
if (registeredWatchers.size() > 0) {
boolean isRemoved = false;
LOG.info("About to unregister all watchers.");
for (WatchKey watchKey : registeredWatchers.keySet()) {
try {
isRemoved = notifier.removeWatcher(watchKey);
if (isRemoved) {
registeredWatchers.remove(watchKey);
}
} catch (IOException e) {
// Let other watchers be cleared off
}
}
if (registeredWatchers.size() > 0) {
LOG.info("Failed to clear all the watchers. Some watchers couldn't be unregistered.");
}
} else {
LOG.warn("Failed to clear all the watchers as no watchers registered.");
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void unregisterAll();",
"public synchronized void unRegisterAll()\r\n {\r\n clearNameObjectMaps();\r\n }",
"public synchronized final void deleteWidgetWatchers() {\n _watchers.removeAllElements();\n }",
"private void unregisterReceivers() {\n \t\t\n\t\tunregisterReceiver(newReadingsReceiver);\n\t\tunregisterReceiver(sensorStatusReceiver);\n\t\tunregisterReceiver(servalMeshStatusReceiver);\n \t}",
"public void unregisterListeners(){\n listeners.clear();\n }",
"public void unregisterAll()\n {\n final Set<javax.servlet.Servlet> servlets = new HashSet<>(this.localServlets);\n for (final javax.servlet.Servlet servlet : servlets)\n {\n unregisterServlet(servlet);\n }\n }",
"void unsubscribeAll();",
"public void closeWatchers() {\n //inform all the children windows (plots/lists) that the parent has died\n for (RtStatusListener i : watchers) {\n i.bailOut();\n }\n\n watchers.clear();\n }",
"private void stopAllListeners() {\n if (unitReg != null && unitListener != null) {\n unitReg.remove();\n }\n }",
"public void reset() {\n logger.debug(\"Resetting {}\", this);\n for (final Source source : watchers.keySet()) {\n reset(source);\n }\n }",
"void unregisterListeners();",
"public String[] unregisterAll()\n {\n String[] ret = getRegisteredChannels();\n channelToHandlers.clear();\n handlerToChannels.clear();\n return ret;\n }",
"private void tearEverythingDown() {\n\t\t// It doesn't do any harm if we call this method repeatedly - we only ever end up subscribing once.\n\t\tMultiLocationProvider.getInstance().addListener(this);\n\t}",
"private void unregisterReceivers() {\n LocalBroadcastManager.getInstance(getActivity()).unregisterReceiver(userUpdater);\n postChangeController.unregisterReceivers(getActivity());\n }",
"public void releaseAllSensors() {\n mSensorManager.unregisterListener(this, mRotationSensor);\n }",
"public void clearScopeRegistrationListeners();",
"void shutdown() {\n if (metricRegistry != null) {\n for (String metricName : gaugeMetricNames) {\n try {\n metricRegistry.remove(metricName);\n } catch (RuntimeException e) {\n // ignore\n }\n }\n }\n }",
"@Override\n public void clearAllRegistrations()\n {\n writeRegistryStoreProperties(null);\n }",
"static void destroyAll()\n {\n synchronized(allSchedulers)\n {\n // destroy all registered schedulers\n Iterator iter = allSchedulers.iterator();\n while (iter.hasNext())\n {\n Scheduler scheduler = (Scheduler) iter.next();\n \n // do not call cancel() since this method modifies allSchedulers\n scheduler.destroy();\n }\n \n if (logger.isInfoEnabled())\n {\n logger.info(allSchedulers.size() + \" scheduler instances destroyed\");\n }\n \n // be sure and clear set\n allSchedulers.clear();\n \n // and set flag that scheduler service ist stopped\n schedulerServiceRunning = false;\n }\n }",
"public void resetListeners() {\n\t\tfinal ListenerSupport<AgentShutDownListener> backup = new ListenerSupport<>();\n\n\t\tgetListeners().apply(backup::add);\n\n\t\tbackup.apply(listener -> {\n\t\t\tgetListeners().remove(listener);\n\t\t});\n\t}",
"private void shutdownWatchListTimers()\r\n {\r\n debug(\"shutdownWatchListTimers() all timers\");\r\n // Null our our parser, It is not needed now.\r\n if (populateListVector == null)\r\n {\r\n return;\r\n }\r\n // Stop All of our timers.\r\n for (int i = 0; i < populateListVector.size(); i++)\r\n {\r\n PopulateWatchListTask task = (PopulateWatchListTask) populateListVector.elementAt(i);\r\n task.cancel();\r\n this.setStatusBar(\"WatchList [\" + tabPane.getTitleAt(i) + \"] - Stopped.\");\r\n debug(\"WatchList [\" + tabPane.getTitleAt(i) + \"] - Stopped.\");\r\n }\r\n // Clear all objects from the Timer List\r\n populateListVector.removeAllElements();\r\n populateListVector = null;\r\n // Signal the Garbage Collector to reclaim anything it may see neccessary\r\n System.gc();\r\n debug(\"shutdownWatchListTimers() all timers - complete\");\r\n }",
"public void shutdown() {\n for (BucketMonitor monitor : this.monitors.values()) {\n monitor.shutdown();\n }\n }",
"public void shutdown() {\n \t\tfor(Expirator e : expirators) {\n\t\t\te.shutdown();\n \t\t}\n \t\texpirators.clear();\n \t}",
"protected void unregisterContractEvents()\n {\n for(final Subscription subscription : subscriptions)\n {\n Async.run(new Callable<Void>() {\n @Override\n public Void call() throws Exception {\n subscription.unsubscribe();\n return null;\n }\n });\n }\n\n subscriptions.clear();\n }",
"private void unWatchDir(Path path) {\n watcher_service.deRegisterAll(path);\n }",
"public abstract void unregisterListeners();",
"public void detachAllObservers();",
"private void unRegisterSensors()\n {\n // Double check that the device has the required sensor capabilities\n // If not then we can simply return as nothing will have been already\n // registered\n if(!HasGotSensorCaps()){\n return;\n }\n\n // Perform un-registration of the sensor listeners\n\n sensorManager.unregisterListener(this, sensorManager.getDefaultSensor(Sensor.TYPE_STEP_COUNTER));\n sensorManager.unregisterListener(this, sensorManager.getDefaultSensor(Sensor.TYPE_STEP_DETECTOR));\n sensorManager.unregisterListener(this, sensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER));\n }",
"public void unbindAll() {\n\t\tmGlobalCallbacks.clear();\n\t\t/* remove all local callback lists, that is removes all local callbacks */\n\t\tmLocalCallbacks.clear();\n\t}",
"public void removeAllListeners() {\r\n\t\tgetListeners().removeAllListeners();\r\n\t}",
"public synchronized void removeAll() {\r\n\t\tif (trackedResources == null)\r\n\t\t\treturn;\r\n\t\tPair<IPath, IResourceChangeHandler>[] entries = (Pair<IPath, IResourceChangeHandler>[]) trackedResources.toArray(new Pair[trackedResources.size()]);\r\n\t\tfor (Pair<IPath, IResourceChangeHandler> entry : entries) {\r\n\t\t\tremoveResource(entry.first, entry.second);\r\n\t\t}\r\n\t}",
"public void removeAllListeners() {\n die();\n }",
"public void cleanup() {\n\t\tref.removeEventListener(listener);\n\t\tmodels.clear();\n\t\tmodelNames.clear();\n\t\tmodelNamesMapping.clear();\n\t}",
"public void removeAll() {\n\t\tmListenerSet.clear();\n\t}",
"public void stopAll() {\n List<String> startedEvents = new ArrayList<>(started.keySet());\n for (String event : startedEvents) {\n stop(event);\n }\n started.clear();\n }",
"@SuppressWarnings(\"unused\")\n public void removeAllListeners() {\n eventHandlerList.clear();\n }",
"public void unregister() {\n unregistered = true;\n }",
"protected void unhookViewers() {\n\t}",
"public void clearChangeListeners() {\n observer.clear();\n }",
"public void removeListeners() {\n for (LetterTile tile : rack)\n tile.removeTileListener();\n }",
"public static void clean() {\n keptObservers.put(new Object(), new ArrayList<Runnable>());\n }",
"void unregister() {\n for (Component comp : jTabbedPane1.getComponents()) {\n if (comp instanceof MiniTimelinePanel) {\n DiscoveryEventUtils.getDiscoveryEventBus().unregister(comp);\n }\n }\n }",
"public void removeAllObjectChangeListeners()\n\t{\n\t\tlistenerList = null;\n\t}",
"public void removeAllObjectChangeListeners()\n\t{\n\t\tlistenerList = null;\n\t}",
"public void unregisterCrashWatcher() {\n mDevice.removeWatcher(\"GoogleCamera-crash-watcher\");\n }",
"public void destroy() {\n for (ComponentBean component : this.componentMap.values()) {\n component.getObject().destroy();\n }\n\n flushRegistry();\n\n }",
"public void destroyForAll() {\n super.destroyForAll();\n }",
"public void removeMultiTouchListeners() {\r\n\t\tlisteners.clear();\r\n\t}",
"protected void removeListeners() {\n Window topLevelWindows[] = EventQueueMonitor.getTopLevelWindows();\n if (topLevelWindows != null) {\n for (int i = 0; i < topLevelWindows.length; i++) {\n if (topLevelWindows[i] instanceof Accessible) {\n removeListeners((Accessible) topLevelWindows[i]);\n }\n }\n }\n }",
"public static void clearRegistry() {\r\n\t\tINTERPRETERS.clear();\r\n\t}",
"private void unblockWaiters() {\n synchronized (sERDLock) {\n sERDLock.notifyAll();\n }\n }",
"public void removeAllTuioListeners()\n\t{\n\t\tlistenerList.clear();\n\t}",
"public void destroy() {\n\t\tfor (ANodeAttributeRenderer attributeRenderer : attributeRenderers) {\n\t\t\tattributeRenderer.unregisterPickingListeners();\n\t\t}\n\t}",
"@Override\n public void stop() {\n\n for (FermatEventListener fermatEventListener : listenersAdded) {\n eventManager.removeListener(fermatEventListener);\n }\n\n listenersAdded.clear();\n }",
"public void unregister() {\n this.dispatcher.context.unregisterReceiver(this);\n }",
"void clearEventsDetectors();",
"public void clearRegistrationStateChangeListener()\n {\n synchronized (registrationListeners) {\n registrationListeners.clear();\n }\n }",
"@Override\n protected void onUnregister() {\n Core.unregister(this);\n }",
"@Override\n public void removeNotify()\n {\n unregisterListeners();\n super.removeNotify();\n }",
"public void removeAllAppenders() {\n synchronized (myAppenders) {\n myAppenders.removeAllAppenders();\n }\n }",
"public void teardown() {\n for (App app : applications) {\n app.icon.setCallback(null);\n }\n\t}",
"public void disposeAllInspectors() {\n Object obj;\n Enumeration e = inspectors.elements();\n while (e.hasMoreElements()) {\n obj = e.nextElement();\n ((InspectorInterface)obj).dispose();\n com.cosylab.vdct.DataProvider.getInstance().removeInspectableListener((InspectableObjectsListener)obj);\n }\n inspectors.removeAllElements();\n}",
"public void removeAllRatioListeners()\r\n {\r\n ratioListeners.clear();\r\n }",
"public synchronized void clear() {\n synchronized (this.factories) {\n for (Map.Entry<String, CachedAnnotator> entry : new HashSet<>(this.factories.entrySet())) {\n // Unmount the annotator\n Optional.ofNullable(entry.getValue()).flatMap(ann -> Optional.ofNullable(ann.annotator.getIfDefined())).ifPresent(Annotator::unmount);\n // Remove the annotator\n this.factories.remove(entry.getKey());\n }\n }\n }",
"void exit() {\n\t\tfor (ScopedProvider<?> e : scopedProviders.keySet()) {\n\t\t\tsynchronized(e) {\n\t\t\t\te.values.clear();\n\t\t\t}\n\t\t}\n\t}",
"public void stop()\r\n {\r\n debug(\"stop() all timers\");\r\n // Shutdown all the Timers\r\n shutdownWatchListTimers();\r\n\r\n debug(\"stop() all timers - complete\");\r\n }",
"public static void removeAllSensors() {\n\t\tmSensors.clear();\n\t}",
"final void cleanUp() {\r\n\t\t\tfor (Variable var : varRefs.keySet()) {\r\n\t\t\t\tvar.deleteObserver(this);\r\n\t\t\t}\r\n\t\t\tvarRefs.clear();\r\n\t\t}",
"public void removeAllListeners()\n {\n tableModelListeners.clear();\n comboBoxModelListDataListeners.clear();\n }",
"public void stop() {\n executor.shutdownNow();\n\n Collection<NodeRegistrationContext> allRegistrations = nodeRegistrations.values();\n for (NodeRegistrationContext registration : allRegistrations) {\n sendUnregistrationEvent(registration.resolvedDeployment);\n }\n }",
"public void shutdown() {\n logger.info(\"Shutting down modules.\");\n for (Module module : modules) {\n module.stop();\n }\n logger.info(\"Shutting down reporters.\");\n for (Reporter reporter : reporters.values()) {\n reporter.stop();\n }\n }",
"@Override\n public void close() {\n for (Servlet registeredServlet : registeredServlets) {\n paxWeb.unregisterServlet(registeredServlet);\n }\n for (Filter filter : registeredFilters) {\n paxWeb.unregisterFilter(filter);\n }\n for (EventListener eventListener : registeredEventListeners) {\n paxWeb.unregisterEventListener(eventListener);\n }\n for (String alias : registeredResources) {\n paxWeb.unregister(alias);\n }\n }",
"private void stopSensors() {\n for (MonitoredSensor sensor : mSensors) {\n sensor.stopListening();\n }\n }",
"public void removeItemListerners() {\r\n\t\titemListeners.clear();\r\n\t}",
"public void removeAllAmplitudeListeners()\r\n {\r\n amplitudeListeners.clear();\r\n }",
"public static void resetAll() {\n\t\tfor (int x = 0; x < mSensors.size(); x++) {\n\t\t\tmSensors.get(x).reset();\n\t\t}\n\t}",
"public void removeAllListeners() {\n mCircularBar.removeAllListeners();\n }",
"public void clearObservers(){\r\n\t\tobservers.clear();\r\n\t}",
"public void stop()\n throws Exception\n {\n for(int i = 0; i < this.monitoredObjectsCache.size(); i++) {\n \n ObjectName target = null;\n \n try {\n target = (ObjectName) this.monitoredObjectsCache.get(i);\n \n this.server.removeNotificationListener(target, listener);\n \n if (log.isDebugEnabled())\n log.debug(\"Unsubscribed from \\\"\" + target + \"\\\"\");\n }\n catch(Exception e) {\n log.error(\"Unsubscribing from \\\"\" + target + \"\\\"\", e);\n }\n }\n }",
"public void watchAndClean() {\n runtimeClient.watchWithWatcher(new Watcher<Event>() {\n\n @Override\n public void eventReceived(Action action, Event resource) {\n if ((resource.getInvolvedObject().getKind().equals(\"Deployment\") ||\n resource.getInvolvedObject().getKind().equals(\"Service\"))\n && resource.getInvolvedObject().getName().startsWith(Constants.BPG_APP_TYPE_LAUNCHER)\n && (action == Action.DELETED || action == Action.MODIFIED)) {\n\n log.info(\"Received \"\n + action.toString() + \" event for \"\n + resource.getInvolvedObject().getKind() + \" \"\n + resource.getInvolvedObject().getName());\n\n cleanOrphanDeployments();\n cleanOrphanServices();\n } else {\n log.debug(\"Received action \" + action.toString() + \" for resource \"\n + resource.getInvolvedObject().getKind() + \":\"\n + resource.getInvolvedObject().getName());\n }\n }\n\n @Override\n public void onClose(KubernetesClientException cause) {\n log.info(\"Shutting down Event Watcher...\");\n }\n });\n }",
"public void removeAllListener() {\r\n listeners.clear();\r\n }",
"protected void uninstallListeners() {\n }",
"protected void uninstallListeners() {\n }",
"private void unregisterBroadcastReceivers(){\n if (mBufferBroadcastIsRegistered)\n try {\n this.unregisterReceiver(BufferBroadcastReceiver);\n mBufferBroadcastIsRegistered=false;\n }catch (Exception e){\n e.printStackTrace();\n }\n\n /**unregister broadcastReceiver for seekBar*/\n if (mSeekBarBroadcastIsRegistered){\n try {\n this.unregisterReceiver(seekBarBroadcastReceiver);\n mSeekBarBroadcastIsRegistered=false;\n }catch (Exception e){\n e.printStackTrace();\n }\n }\n\n /** register broadcastReceiver for afterCall alertDialog\n * in StopService in case of call while playing */\n\n }",
"protected void uninstallListeners() {\n\t}",
"public void clearObservers() {\r\n\t\tobservers.clear();\r\n\t}",
"public static void removeAllObservers() {\n compositeDisposable.clear();\n observersList.clear();\n Timber.i(\"This is the enter point: All live assets and team feed auto refresh DOs are removed\");\n }",
"@After\n public void clearMeters() {\n Search.in(registry)\n .name(name -> name.startsWith(\"org.drools.metric\"))\n .meters()\n .forEach(registry::remove);\n MicrometerUtils.INSTANCE.clear();\n registry = null;\n }",
"private void cleanupReceiver ()\n {\n if (receiver != null)\n {\n unregisterReceiver(receiver);\n receiver = null;\n }\n }",
"protected void stopAll() {\n\t\tif (this.udpServer!=null)\n\t\t\tthis.udpServer.interrupt();\n\t\tif (this.connectionServer!=null)\n\t\t\tthis.connectionServer.interrupt();\n\t\tthis.connectionServer=null; // supprime le TCPServer et les Sockets associés\n\t\tthis.udpServer=null; // supprime l'UDPServer et les Sockets associés\n\t\tif (this.agent.getUserStatusManager()!=null)\n\t\t\tfor (String u : this.agent.getUserStatusManager().getActiveUsers())\n\t\t\t\tthis.removeSocket(u);; // interrompt tous les UserSockets\n\t\tthis.mapSockets.clear();\n\t}",
"private void unregisterScanners() throws JMException {\n unregisterMBeans(scanmap);\n }",
"public static void clearRegistry() {\n \t\tLIBRARIES.clear();\n \t}",
"public void unregisterAdapters(IAdapterFactory factory);",
"@Override\r\n\tpublic void clearEventHandlers() {\n\t\t\r\n\t}",
"public static synchronized void resetAllTimers() {\r\n _count = 0;\r\n _time = 0;\r\n _serverStarted = -1;\r\n _timers.clear();\r\n }",
"public void clearEvents()\n {\n ClientListener.INSTANCE.clear();\n BackingMapListener.INSTANCE.clear();\n }",
"public void removeListeners() {\n if ( listeners != null ) {\n listeners.clear();\n }\n }",
"public void exitAllRooms() {\n\t\tfor (RoomSetting roomSetting : roomSettings) {\n\t\t\troomSetting.getRoom().removeClient(this);\n\t\t}\n\t\troomSettings.clear();\n\t}",
"public void disposeResources() {\n Arrays.fill(icons, null);\n iconComponent.removeAncestorListener(this);\n }",
"void unbindAll();"
] | [
"0.75906837",
"0.7384652",
"0.73738873",
"0.70732033",
"0.6969986",
"0.69356644",
"0.68418777",
"0.682043",
"0.6744174",
"0.67214537",
"0.6622998",
"0.65704256",
"0.65482384",
"0.65289956",
"0.64489615",
"0.6405453",
"0.63626933",
"0.6361786",
"0.6309553",
"0.62994",
"0.62992775",
"0.627985",
"0.626682",
"0.62519044",
"0.6226444",
"0.6199772",
"0.6198197",
"0.615171",
"0.6145677",
"0.6137735",
"0.61354434",
"0.6094388",
"0.609153",
"0.6077251",
"0.60766286",
"0.6039888",
"0.60377216",
"0.60270363",
"0.59942645",
"0.5983398",
"0.5972162",
"0.59705323",
"0.5959354",
"0.5959354",
"0.59428364",
"0.59401494",
"0.5925227",
"0.5921242",
"0.59052527",
"0.5899584",
"0.5889604",
"0.5889244",
"0.5881925",
"0.58785075",
"0.5878226",
"0.58679473",
"0.5855289",
"0.5844398",
"0.58373094",
"0.5835055",
"0.5834249",
"0.5826106",
"0.58255816",
"0.58212185",
"0.5818672",
"0.5806099",
"0.5798467",
"0.57870114",
"0.57775086",
"0.575642",
"0.5744434",
"0.57291317",
"0.5727966",
"0.57250667",
"0.57200116",
"0.5716266",
"0.5710842",
"0.5710401",
"0.5706121",
"0.57051957",
"0.5702605",
"0.57004356",
"0.57004356",
"0.5695536",
"0.568699",
"0.5686865",
"0.56760037",
"0.5673161",
"0.56635606",
"0.5653745",
"0.5649018",
"0.5646109",
"0.5645841",
"0.56435823",
"0.56430924",
"0.56371987",
"0.5636314",
"0.56207234",
"0.557801",
"0.55708534"
] | 0.8422791 | 0 |
number of spaces per tab | public OutputFormatter( final Jetty jetty, PlatformIO io ) {
super( jetty );
_platform_io = io;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private static void processTab() {\n\t\tfor (int i = 0; i < 4; i++) {\n\t\t\tif (charCount == MAX_W) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tline[charCount] = ' ';\n\t\t\tcharCount++;\n\t\t}\n\t\tcurrentWord = charCount;\n\t}",
"void setTabLength(int tabLength) {\n\tGC gc = getGC();\n\tStringBuffer tabBuffer = new StringBuffer(tabLength);\n\tfor (int i = 0; i < tabLength; i++) {\n\t\ttabBuffer.append(' ');\n\t}\n\ttabWidth = gc.stringExtent(tabBuffer.toString()).x;\n\tdisposeGC(gc);\n}",
"private String getNumberOfTabs(int numOfTabs) {\r\n String tabs = \"\";\r\n // If numOfTabs is 0, return an empty string\r\n if (numOfTabs == 0)\r\n return \"\";\r\n // Loop through until the number of tabs required is added to tabs\r\n while (numOfTabs > 0) {\r\n // Add a tab character to tabs\r\n tabs += \"\\t\";\r\n // Decrement numOfTabs\r\n numOfTabs--;\r\n }\r\n // Return the string of numOfTabs of tabs\r\n return tabs;\r\n }",
"protected short getIndentSize() {\n return (short) (tabLevel * tabSize);\n }",
"private boolean checkSpacingTabs(){\r\n\t\tString tmp = \"\";\r\n\t\ttry{ tmp = doc.getText(getCaretPosition()-2,1); }\r\n\t\tcatch(BadLocationException a){};\r\n\t\tSystem.out.println((int)tmp.charAt(0));\r\n\t\tif(tmp.charAt(0) == 9) return true;\r\n\t\telse return false;\r\n\t}",
"int nbColonnes();",
"@Override\n\tpublic int getTabCount() {\n\t\treturn 0;\n\t}",
"private void tabPrinter() {\n IntStream.range(0, tabs).forEach(i -> writer.print(\" \"));\n }",
"int getIndentSize();",
"@Override\n public void run() {\n int count = text.length() - text.replace(\" \", \"\").length();\n System.out.printf(\"Spaces: %d;\\n\", count);\n }",
"public String getTab() {\r\n if(date.length() < 10)\r\n return \"\\t\\t\";\r\n else\r\n return \"\\t\";\r\n }",
"public int getTabCount() {\n\t\treturn tabMap.size();\n\t}",
"private static String manualTab(String entry)\r\n\t{\r\n\t\tString tab = \"\";\r\n\t\tfor(int count=0; count < 15 - entry.length(); count++)\r\n\t\t\ttab += \" \";\r\n\t\treturn tab;\r\n\t}",
"int getKeyspacesCount();",
"public int space(){\n return (tableSize - usedIndex);\n }",
"public static void spaces() {\r\n // prints 13 spaces\r\n for (int space = 0; space < 15; space++) {\r\n System.out.println(\"\");\r\n }\r\n\r\n }",
"public void indent() {\n ++tabLevel;\n }",
"public static String tab() {\n return indent;\n }",
"public AttributedStringBuilder tabs(int tabsize) {\n/* 378 */ if (tabsize < 0) {\n/* 379 */ throw new IllegalArgumentException(\"Tab size must be non negative\");\n/* */ }\n/* 381 */ return tabs(Arrays.asList(new Integer[] { Integer.valueOf(tabsize) }));\n/* */ }",
"public static void countSpaces(Scanner in) {\n }",
"@Test\n @Order(6)\n void tabuSizeTest() {\n for (String taillardFilename : SearchTestUtil.taillardFilenames) {\n System.out.println(\"-----------------\");\n System.out.println(\"Run \" + taillardFilename);\n System.out.println(\"-----------------\");\n tabuSizeTestWith(taillardFilename);\n }\n }",
"private String tabulatorString(int level) {\r\n String tabs = \"\";\r\n for (int i = 0; i < level; i++) {\r\n tabs += \"\\t\";\r\n }\r\n return tabs;\r\n }",
"public static final String tab(int count) {\n if (count == 1)\n return TAB;\n return repeat(\"TAB\"/*I18nOK:EMS*/, count);\n }",
"public int getColspan() \n {\n return 1;\n }",
"public StrTab() {\n maxIndex = 1;\n }",
"public static int getSpaceCounter() {\n\t\treturn spaceCounter;\n\t}",
"int tableSize();",
"public int getNumberOfTabs() {\n\t\treturn this.tabPanelsMap.size();\n\t}",
"private void createTab() {\n tab = new char[tabSize];\n for (int i = 0; i < tabSize; i++) {\n tab[i] = tabChar;\n }\n }",
"@Override\n public int NumCVSpaces() {\n return 0;\n }",
"public int LengthTab(NodesVector nvector) {\n\t\tint L = 0;\n\t\tNodes nodes;\n\n\t\tfor (int i = 1; i < nvector.size(); i++) {\n\t\t\tnodes = (Nodes) nvector.elementAt(i);\n\t\t\tL = (L + nodes.path.size()) - 1;\n\t\t}\n\n\t\treturn (((L + NbPipes) * NbDiam) + NbNodes) - 1 + (NbDiam * NbPipes);\n\t}",
"public long getWhiteSpacesCount() {\n return whiteSpacesCount;\n }",
"int getLinesCount();",
"private static int numLines() {\n\t\tif(subway != null)\n\t\t\treturn subway[0].length;\n\t\treturn 0;\n\t}",
"protected int bytesPerLine() {\n return (48);\n }",
"protected int bytesPerLine() {\n return (48);\n }",
"public int getTakeSpace() {\n return 0;\n }",
"public static void countRowCol(){\n\t String line=\"\";\n\t row=0;\n\t col=0;\n try{\n Scanner reader = new Scanner(file);\n while(reader.hasNextLine()){\n row++;\n line=reader.nextLine();\n }\n reader.close();\n }catch (FileNotFoundException e) {\n \t e.printStackTrace();\n }\n String[] seperatedRow = line.split(\"\\t\");\n col=seperatedRow.length;\n\t}",
"public static String tab(String string, int number){\n String concl = \"\";\n for (String line : string.split(\"\\n\")){\n for (int i = 0; i < number; i++){\n concl += \" \";\n }\n concl += line + \"\\n\";\n }\n return concl;\n }",
"@Override\n\tprotected void handleTab() {\n\t\thandleSpace();\n\t}",
"private int calcWhiteSpaces(Set<Room> rooms) {\n int n = 0;\n for (Room room : rooms) {\n if (room.getId() > n) {\n n = room.getId();\n }\n }\n for (Room room : rooms) {\n if (room.getObjects().toString().length() > n) {\n n = room.getObjects().toString().length();\n }\n }\n\n for (Room room : rooms) {\n if (room.getName().length() > n) {\n n = room.getName().length();\n }\n }\n\n return n + 3; // longest word + extra spaces\n }",
"public String tab(String str) {\n if (str == null || str.trim().isEmpty()) {\n return str;\n }\n str = str.replaceAll(\"\\n\\t\", \"\\n\\t\\t\");\n str = str.replaceAll(\"\\n<\", \"\\n\\t<\");\n return \"\\t\" + str;\n }",
"public static void tab(String tab) {\n Formatting.indent = tab;\n }",
"public int getNumLines ();",
"public int getDisplayCharacterCount() {\r\n return _displaySize;\r\n }",
"public Long getSPACE() {\n return SPACE;\n }",
"private int[] numberOfLines(int[] widths, String S) {\n int linesCount = 0;\n int wordCount = 0;\n\n for(char character: S.toCharArray()){\n int index = character - 97;\n int wordLength = widths[index];\n if(wordCount + wordLength <= 100){\n wordCount+=wordLength;\n } else {\n linesCount++;\n wordCount = wordLength;\n }\n }\n\n if(wordCount > 0){\n linesCount++;\n }\n return new int[]{linesCount, wordCount};\n }",
"private int getTableLength() {\n\t\tif (proposalList == null)\n\t\t\treturn 0;\n\t\treturn proposalList.length() + proposalList.getProviderList().size()\n\t\t\t\t+ proposalList.getTopProposalList().size();\n\t}",
"private int getChatTabCount()\n {\n return (chatTabbedPane == null) ? 0 : chatTabbedPane.getTabCount();\n }",
"public int getMazeWidth() {\n\t\tint result = 0;\n\t\t\n\t\tfor (String line : this.mMazeChars) {\n\t\t\tif (result < line.length()) \n\t\t\t\tresult = line.length();\n\t\t}\n\t\t\n\t\treturn result;\n\t}",
"void addSpaces() {\n\t\tSystem.out.print(\" \");\n\t\tfor (int j = 0; j < 3; j++)\n\t\t\tSystem.out.print(\"| \");\n\t\tSystem.out.println(\"|\");\n\t}",
"public static int getTabViewCount() {\n return tabViews.size();\n }",
"public int getWordCount() {\n\t\treturn 10;\n\t}",
"public static void tenthProgram() {\n\t\tfor(int i=1;i<=4;i++) {\n\t\t\tfor(int j=1;j<=i-1;j++) {\n\t\t\t\tSystem.out.print(\" \");\t\t\t\n\t\t\t}for(int k=1;k<=4;k++) {\n\t\t\t\tSystem.out.print(\"*\");\t\t\n\t\t\t}System.out.println();\n\t\t}\n\t}",
"public abstract int numberOfLines();",
"public int getNumEspacios() {\r\n\t\treturn numEspacios;\r\n\t}",
"void getCounter(){// wazifeye in mthod, shomaresh ast.\n selectedCellCounter=0;\n emptyCellCounter=0;\n charCounter=0;\n for(int i=0; i<30;i++)\n for(int j=0; j<26;j++){\n if(jtf[i][j].getText().length()==0)\n ++emptyCellCounter;\n else\n charCounter+=jtf[i][j].getText().length();\n if(jtf[i][j].getBackground()==Color.blue || jtf[i][j].getBackground()==Color.green)\n ++selectedCellCounter;\n }\n }",
"protected short getIndentLevel() {\n return tabLevel;\n }",
"private void writeColumnSpace(BufferedWriter writer, int totalSpace)\n\tthrows IOException\n {\n\tfor(int i = 0; i < totalSpace; i++) \n {\n\t\twriter.write(\" \");\n\t}\n }",
"public int totalWordsTree() {\r\n\t\treturn count;\r\n\t}",
"int getTablesCount();",
"public abstract int getNumColumns();",
"public int countTokens(int row)\r\n\t{\r\n\t\tint result = 0;\r\n\r\n\t\tfor(int x=0;x<Column_Size;x++)\r\n\t\t{\r\n\t\t\tif(row<0)\r\n\t\t\t\treturn result;\r\n\t\t\telse\r\n\t\t\t\tif(Layout[row][x]==1)\r\n\t\t\t\t\tresult += 1;\r\n\t\t}\r\n\t\treturn result + countTokens(row-1);\r\n\t}",
"int colCount();",
"public int getColumnCount() { return tableWidth;}",
"private String indent(int spaces) {\n\t\tString result = \"\";\n\t\tfor (int i = 0; i < spaces; i++) {\n\t\t\tresult = result + \" \";// it creates as much spaces as it is told to\n\t\t}\n\t\treturn result;\n\t}",
"public int width();",
"public static String whitespace(int count, String spaces) {\r\n\t\tfor (int i = 0; i < count; i++) {spaces += \" \";}\r\n\t\treturn spaces;\r\n\t}",
"private void Spacing() {\n\n try {\n while (true) {\n try {\n Space();\n } catch (SyntaxError e) {\n Comment();\n }\n }\n } catch (SyntaxError e) {\n }\n }",
"char skipSpaces () {\n char c = getChar ();\n while (c == ' ' || c == '\\t' || c == '\\n' || c == '\\r') {\n if (c == '\\n') { m_nbLines++; }\n c = getNextChar ();\n }\n return c;\n }",
"public static void main_getSize(){\n\n System.out.println(table.size());\n\n }",
"public void setWhiteSpacesCount(long value) {\n this.whiteSpacesCount = value;\n }",
"private static int countSpacesLeft(char[] dest,\n int start,\n int count) {\n for (int i = start, e = start + count; i < e; ++i) {\n if (dest[i] != SPACE_CHAR) {\n return i - start;\n }\n }\n return count;\n }",
"@Override\n\tpublic int count() {\n\t\treturn 4;\n\t}",
"int getNumOfChunks();",
"public String toStringTabbed(int tabs){\n StringBuilder b = new StringBuilder();\n for(int i = 0; i < tabs; i++){\n b.append(\"\\t\");\n }\n b.append(\"while (\" + bExpression.toString() + \")\\n\" + s1.toStringTabbed(tabs+1));\n return b.toString();\n \n }",
"public double getCharSpace(\n )\n {return charSpace;}",
"public int numPages() {\n // some code goes here\n //System.out.println(\"File length :\" + f.length());\n\n return (int) Math.ceil(f.length() * 1.0 / BufferPool.PAGE_SIZE * 1.0);\n }",
"int getColumnCount();",
"int getColumnCount();",
"protected static void appendTabs(final StringBuffer sb, final int depth) {\n int tmp = depth;\n while (tmp-- > 0) {\n sb.append('\\t');\n }\n }",
"public static int sizeOf()\n {\n return 4;\n }",
"public int lines( )\n {\n int lin = 0;\n\n if( table != null )\n {\n lin = table.length;\n } //end\n return(lin);\n }",
"protected final String space(int n) {\n StringBuffer buf = new StringBuffer(0);\n for (int i = 0; i < n; i++) {\n buf.append(\" \");\n }\n return buf.toString();\n }",
"int getNumberOfLines();",
"public int getRecordSize()\n {\n return 4 + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 4;\n }",
"private void calculateCharSize() {\n int charMaxAscent;\n int charLeading;\n FontMetrics fm = getFontMetrics(getFont());\n charWidth = -1; // !!! Does not seem to work: fm.getMaxAdvance();\n charHeight = fm.getHeight() + lineSpaceDelta;\n charMaxAscent = fm.getMaxAscent();\n fm.getMaxDescent();\n charLeading = fm.getLeading();\n baselineIndex = charMaxAscent + charLeading - 1;\n\n if (charWidth == -1) {\n int widths[] = fm.getWidths();\n for (int i=32; i<127; i++) {\n if (widths[i] > charWidth) {\n charWidth = widths[i];\n }\n }\n }\n }",
"public static void printTimesTable(int tableSize) {\n System.out.format(\" \");\n for(int i = 1; i<=tableSize;i++ ) {\n System.out.format(\"%4d\",i);\n }\n System.out.println();\n System.out.println(\"--------------------------------------------------------\");\n\n for (int row = 1; row<=tableSize; row++){\n \n System.out.format(\"%4d\",row);\n System.out.print(\" |\");\n \n for (int column = 1; column<=tableSize; column++){\n System.out.format(\"%4d\",column*row);\n }\n System.out.print(\"\\n\");\n }\n\n }",
"private int calculateTextWidth(String[] lines, FontMetrics fm)\r\n {\r\n int numChars = 0;\r\n String maxString = \"\";\r\n // calculate the number of characters in the line\r\n for (String lineNo : lines)\r\n {\r\n if (numChars < lineNo.length())\r\n {\r\n numChars = lineNo.length();\r\n maxString = lineNo;\r\n }\r\n }\r\n // width will be the numChars * text metrics for the font\r\n int maxWidth = fm.stringWidth(maxString);\r\n return maxWidth;\r\n }",
"public static int count(String str){\r\n\t\tString[] splitStr = str.trim().split(\"\\\\s+\"); //split according to spaces and tabs.\r\n\t\treturn splitStr.length;\r\n\t}",
"int getFixedLines();",
"int getBlockNumbersCount();",
"public int getClassSize()\r\n {\r\n return number_of_entries;\r\n }",
"public int getNumTable() {\n\t\treturn numTable;\n\t}",
"public int printLength() { return printLength; }",
"int getNumberOfFold();",
"public int numberOfTires() {\n int tires = 4;\n return tires;\n }",
"@Override\n public int contentColumn(\n @NotNull CharSequence lineChars,\n int indentColumn,\n @NotNull PsiEditContext editContext\n ) {\n // default 4 leading spaces removed\n int column = indentColumn;\n int leadingSpaces = myLeadingSpaces;\n int i = 0;\n\n while (leadingSpaces > 0 && i < lineChars.length()) {\n switch (lineChars.charAt(i++)) {\n case '\\t':\n int spaces = min(columnsToNextTabStop(column), leadingSpaces);\n leadingSpaces -= spaces;\n column += spaces;\n break;\n\n case ' ':\n leadingSpaces--;\n column++;\n break;\n\n default:\n return column;\n }\n }\n return column;\n }",
"public int getNumTokens() {\n \treturn numTokens;\n }",
"public int tableLength() {\n\t\treturn table.length;\n\t}",
"int columnPairsSize();"
] | [
"0.71428925",
"0.67789525",
"0.6622277",
"0.6606109",
"0.6605084",
"0.65797096",
"0.6489289",
"0.6453726",
"0.6382567",
"0.63362014",
"0.6303802",
"0.6301777",
"0.62806183",
"0.6279555",
"0.6196582",
"0.61748385",
"0.6140346",
"0.60977656",
"0.60668063",
"0.60427815",
"0.60191923",
"0.59961134",
"0.59795654",
"0.5916017",
"0.59093624",
"0.5859916",
"0.5833354",
"0.58205175",
"0.5811712",
"0.5811486",
"0.5808503",
"0.5803001",
"0.57618946",
"0.57420295",
"0.5735743",
"0.5735743",
"0.5734315",
"0.5731388",
"0.5724755",
"0.5699706",
"0.5654637",
"0.56411636",
"0.56078035",
"0.5589552",
"0.5568616",
"0.55449605",
"0.5528511",
"0.5524507",
"0.55200523",
"0.5503502",
"0.5502453",
"0.54718584",
"0.5470045",
"0.54596937",
"0.54500115",
"0.54415035",
"0.5433375",
"0.5431533",
"0.5431303",
"0.54288113",
"0.542559",
"0.541383",
"0.54130703",
"0.5406408",
"0.538827",
"0.53704673",
"0.5369721",
"0.5369267",
"0.536736",
"0.5362725",
"0.53544253",
"0.5350352",
"0.534322",
"0.5342339",
"0.5339254",
"0.53377235",
"0.5333846",
"0.53327185",
"0.5325121",
"0.5325121",
"0.53201365",
"0.53174347",
"0.5316624",
"0.5314092",
"0.5308083",
"0.5301099",
"0.529865",
"0.52930695",
"0.5290311",
"0.5288965",
"0.52810687",
"0.5267359",
"0.52644295",
"0.52611285",
"0.52504927",
"0.52442855",
"0.5243795",
"0.52360743",
"0.5230956",
"0.5229641",
"0.52250427"
] | 0.0 | -1 |
possibly filter it first: | public void print( String text )
throws ParseException, ReparseException, HaltTurnException,
GameOverException {
if ( _filter != null ) {
TValue arg = newTValue( TValue.SSTRING, text );
TValue ret = getRunner().run( _filter.get_data(), this.arg_array( arg ) );
if ( ret.get_type() == TValue.SSTRING ) {
text = ret.get_string();
}
// apparently any other return type is allowed & ignored
}
// we go through and handle the %-escapes first; why? because we want to
// skip out right after that if we're doing an outhide()/outcapture()
text = expand_format_strings( text );
if ( text.length() == 0 ) {
return;
}
// now, if we're hiding/capturing output, handle those:
// if there's any outhide() calls going on, just set every one
// that's happening to true, since they've all now had some output
// going on (and, of course, don't print anything)
if ( _outhides.size() > 0 ) {
for ( int i = 0; i < _outhides.size(); i++ ) {
_outhides.setElementAt( Boolean.TRUE, i );
}
return; // and we're done printing
}
// or if there's any outcapture() calls going on, print this string
// to every one (and don't print anything to stdout).
// note that nesting makes no difference here: if an outhide surrounds
// some printed text, it will not be printed, and if there is an
// outcapture nested within that it will capture no text
else if ( _outcaptures.size() > 0 ) {
for ( int i = 0; i < _outcaptures.size(); i++ ) {
( (StringWriter)_outcaptures.elementAt( i ) ).write( text );
}
return; // and we're done printing
}
// ok, at last we can do the print for real:
LOOP: for ( int i = 0; i < text.length(); i++ ) {
char c = text.charAt( i );
// skip over high-bit characters (noted by Stephen Newton)
if ( Character.isISOControl( c ) ) {
continue;
}
// first consider html mode
if ( _html_mode ) {
if ( _current_entity != null ) {
if ( Character.isLetterOrDigit( c ) || c == '#' ) {
_current_entity.append( c );
} else {
// we could be fussy and insist on a ;, but if they are in html
// mode and have "&foo ", what are we supposed to do?
process_entity( _current_entity.toString() );
_current_entity = null;
}
continue;
} else if ( _current_tag != null ) {
if ( c != '>' ) {
_current_tag.append( c );
} else {
process_tag( _current_tag.toString() );
_current_tag = null;
}
continue;
} else if ( c == '&' ) {
_current_entity = new StringBuffer( 5 );
continue;
} else if ( c == '<' ) {
_current_tag = new StringBuffer( 5 );
continue;
}
}
// stupid hack because we don't want to flush in the middle
// of a series of hyphens
if ( _last_printed == '-' && c != '-' ) {
flush();
_last_printed = 0;
}
// So the escapes are:
// n, t, b, ^, v, H+, H-, [space], (, ), -, everything else
if ( c == '\\' ) {
c = text.charAt( ++i ); // safe -- compiler checks that strings
// don't end with unescaped slash
switch ( c ) {
case 'n':
{
print_newline();
}
break;
case 'b':
{
print_blankline();
}
break;
case 't':
{
print_tab( DEFAULT_TAB_SIZE );
}
break;
case '^':
case 'v':
{
_last_printed = c;
}
break;
case '(':
{
if ( !printing_status() ) {
flush(); // we flush here to ensure the last word is not bolded
_platform_io.set_style( PlatformIO.BOLD, true );
}
}
break;
case ')':
{
if ( !printing_status() ) {
// what does normal tads do for nesting and
// so on? (and mismatched close \)s)
flush(); // we flush here to ensure the last word is bolded
_platform_io.set_style( PlatformIO.BOLD, false );
}
}
break;
case '-':
{
add_char( '-', '-' ); // non-breaking hyphen
}
break;
case ' ':
{
add_char( ' ', ' ' ); // non-breaking space
}
break;
case 'H':
{
// html-toggle mode, which can have + or - as an argument
// (or any other character, really, which counts as +).
_html_mode = true;
if ( ++i < text.length() && text.charAt( i ) == '-' ) {
_html_mode = false;
}
}
break;
default:
{
add_char( c, '\0' ); // everything else is literal
}
}
} else if ( c == ' ' ) {
if ( !Character.isWhitespace( _last_printed ) ) {
add_char( ' ', ' ' );
}
flush();
} else if ( c == '-' ) {
// possibly-breaking hyphen; but we can't just flush here because
// we *don't* want to break if we're in the middle of a series of
// hyphens
add_char( '-', '-' );
} else {
if ( _last_printed == '^' ) {
c = Character.toUpperCase( c );
} else if ( _last_printed == 'v' ) {
c = Character.toLowerCase( c );
}
add_char( c, '\0' );
}
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"boolean doFilter() { return false; }",
"@Override\n public int filterOrder() {\n return 1;\n }",
"@Override\n public int filterOrder() {\n return 1;\n }",
"@Override\n\tpublic int filterOrder() {\n\t\treturn 1;\n\t}",
"public abstract void filter();",
"boolean isPreFiltered();",
"@Override public Filter getFilter() { return null; }",
"@Override\n public boolean shouldFilter() {\n return true;\n }",
"@Test\r\n void filterMethod() {\r\n\t\tStream<TransactionBean> transactionBeanStream = transactions.stream().filter(t -> t.getType() == Transaction.GROCERY);\r\n\t\tList<TransactionBean> afterStreamList = transactionBeanStream.peek(System.out::println).collect(Collectors.toCollection(ArrayList::new));\r\n\t\tassertSame(\"wrong type\", Transaction.GROCERY, afterStreamList.get(0).getType());\r\n\t\tassertSame(\"wrong type\", Transaction.GROCERY, afterStreamList.get(1).getType());\r\n }",
"@Override\n\tpublic boolean shouldFilter() {\n\t\treturn true;\n\t}",
"@Override\r\n\t public Filter getFilter() {\n\t return null;\r\n\t }",
"@Override\r\n\tprotected void preFilter(Procedure procedure) {\r\n\t\tsuper.preFilter(procedure);\r\n\t}",
"Try<T> filter(Predicate<? super T> p);",
"public Jode first(Predicate<Jode> filter) {\n return children().first(filter);\n }",
"@Override\n protected SerializablePredicate<T> getFilter(Query<T, Void> query) {\n return Optional.ofNullable(inMemoryDataProvider.getFilter())\n .orElse(item -> true);\n }",
"@Test\r\n void multiLevelFilter() {\r\n\t\tStream<TransactionBean> transactionBeanStream = transactions.stream().filter(t -> t.getType() == Transaction.GROCERY).filter(t -> \"r3\".equals(t.getValue()));\r\n\t\tList<TransactionBean> afterStreamList = transactionBeanStream.peek(System.out::println).collect(Collectors.toCollection(ArrayList::new));\r\n\t\tassertSame(\"wrong type\", Transaction.GROCERY, afterStreamList.get(0).getType());\r\n\t\tassertSame(\"wrong value\", \"r3\", afterStreamList.get(0).getValue());\r\n }",
"public Boolean filter(Entry e) {\n\t\t//TODO you will need to implement this method\n\t\treturn false;\n\t}",
"public<T> List<T> takeWhile(final Collection<T> collection, final Filter<T> filter ){\t\t\n\t\tList<T> result = create.createLinkedList();\n\t\tfor(T t:query.getOrEmpty(collection)){\t\t\t\n\t\t\tif(!filter.applicable(t)){\n\t\t\t\treturn result;\n\t\t\t}\n\t\t\tresult.add(t);\n\t\t}\n\t\treturn result;\n\t}",
"@SuppressWarnings(\"unused\")\n\tprivate static SequentialFilter determineFinalFilter(String command){\n\t\treturn null;\n\t}",
"public boolean shouldFilter() {\n return true;\n }",
"final <E, T extends Collection<E>> T filter(\n Class<?>[] arr, Class<?> from, T c, int type, T prototype\n ) {\n T ret = null;\n\n\n// optimistic strategy expecting we will not need to filter\nTWICE: \n for (;;) {\n Iterator<E> it = c.iterator();\nBIG: \n while (it.hasNext()) {\n E res = it.next();\n\n if (!isObjectAccessible(arr, from, res, type)) {\n if (ret == null) {\n // we need to restart the scanning again \n // as there is an active filter\n ret = prototype;\n continue TWICE;\n }\n\n continue BIG;\n }\n\n if (ret != null) {\n // if we are running the second round from TWICE\n ret.add(res);\n }\n }\n\n // ok, processed\n break TWICE;\n }\n\n return (ret != null) ? ret : c;\n }",
"public abstract Filter<T> filter();",
"@Override\n\tpublic Object visit(ASTRelFilter node, Object data) {\n\t\treturn null;\n\t}",
"public LinkedList<Article> filterArticleList(int filter)\n\t{\n\t\treturn null;\n\t}",
"private void checkFilterInitNext(String result){\n\n //If there is no longer\n if(linkedList.size() == 0){\n resultToOutput = result;\n L.d(\"Rule Passed: got output \" + resultToOutput + \" and sent to \" + rule.getOutputDevice());\n if(singleton.isConnected()){\n singleton.sendToArduino(resultToOutput, rule.getOutputDevice());\n }\n else{\n L.d(\"App is not connected to arduino\");\n }\n return;\n\n }\n\n Filter f = linkedList.poll();\n if(!f.isFilterValid(result)){\n L.d(\"Rule \" + rule.getName() + \" was not satisfied with filter \" + result + \" \" + f.getOperator() + \" \" + f);\n return;\n }\n\n if(linkedList.size() == 0){\n //Get rule filteroutput\n recursiveFiltering(rule.getOutputFilter().split(\":\"),null);\n\n }\n else{\n recursiveFiltering(linkedList.peek().filter.split(\":\"),null);\n }\n }",
"void edgeFilter() {\n for (int i = 0; i < size(); i++) {\n Exp f = get(i);\n if (f.isFilter() && f.size() > 0 && f.get(0).type() == TEST\n && i >= 1 && get(i - 1).isEdge()) {\n Exp edge = get(i - 1);\n if (match(edge, f)) {\n edge.add(f);\n }\n }\n }\n }",
"Filter getFilter();",
"@Override\n public List runFilter(String filter) {\n return runFilter(\"\", filter);\n }",
"public void resetFilter();",
"FeatureHolder filter(FeatureFilter filter);",
"@Override\n\tpublic Filter getFilter() {\n\t\treturn null;\n\t}",
"@Override\n\tpublic Filter getFilter() {\n\t\treturn null;\n\t}",
"public abstract String getDefaultFilter ();",
"@Test\n public void testNondeterministicFilter() throws Exception {\n String query = \"A =LOAD 'file.txt' AS (name, cuisines:bag{ t : ( cuisine ) }, num:int );\" +\n \"B = FOREACH A GENERATE name, flatten(cuisines), num;\" +\n \"C = FILTER B BY RANDOM(num) > 5;\" +\n \"D = STORE C INTO 'empty';\" ;\n\n LogicalPlan newLogicalPlan = buildPlan( query );\n\n newLogicalPlan.explain(System.out, \"text\", true);\n\n // Expect Filter to not be pushed, so it should be load->foreach-> filter\n Operator load = newLogicalPlan.getSources().get( 0 );\n Assert.assertTrue( load instanceof LOLoad );\n Operator fe1 = newLogicalPlan.getSuccessors( load ).get( 0 );\n Assert.assertTrue( fe1 instanceof LOForEach );\n Operator fe2 = newLogicalPlan.getSuccessors( fe1 ).get( 0 );\n Assert.assertTrue( fe2 instanceof LOForEach );\n Operator filter = newLogicalPlan.getSuccessors( fe2 ).get( 0 );\n Assert.assertTrue( filter instanceof LOFilter );\n }",
"private void clearAllFilter() {\n }",
"public OptionalThing<THING> filter(OptionalThingPredicate<THING> oneArgLambda) {\n assertOneArgLambdaNotNull(oneArgLambda);\n return (OptionalThing<THING>) callbackFilter(oneArgLambda);\n }",
"public boolean enoughToFilter() {\n/* 468 */ throw new RuntimeException(\"Stub!\");\n/* */ }",
"@Override\n public Event firstScan() {\n return null;\n }",
"String getFilter();",
"public void filter(Filter filter) throws NoTestsRemainException {\n runner.filter(filter);\n }",
"@Override\n\tpublic void filterChange() {\n\t\t\n\t}",
"public void metodoTakeWhile() {\n\n // takeWhile it stops once it has found an element that fails to match\n List<Dish> slicedMenu1\n = specialMenu.stream()\n .takeWhile(dish -> dish.getCalories() < 320)\n .collect(toList());\n }",
"java.lang.String getFilter();",
"@Override\n public Filter getFilter(String filterId) {\n return null;\n }",
"void filterDisposed(Filter filter);",
"public static ArticleFilter none() {\n return new ArticleFilter() {\n @Override public boolean testArticle(PubmedArticle article) {\n return false;\n };\n };\n }",
"BuildFilter defaultFilter();",
"public void removeFilter() {\r\n\t\tfilter = null;\r\n\t}",
"default ItemStack findOne(Predicate<ItemStack> filter) {\n for (IInventoryAdapter inventoryObject : this) {\n InventoryManipulator im = InventoryManipulator.get(inventoryObject);\n ItemStack removed = im.tryRemoveItem(filter);\n if (!InvTools.isEmpty(removed))\n return removed;\n }\n return InvTools.emptyStack();\n }",
"public void resetFilter() {\n filters.clear();\n modifiedSinceLastResult = true;\n }",
"public UntagFilter(Filter nextFilter) {\n super(nextFilter);\n }",
"protected Filter getFilter() {\n/* 631 */ throw new RuntimeException(\"Stub!\");\n/* */ }",
"private void updateFilteredData() {\n mainApp.getFilteredData().clear();\n\n for (FilmItem p : mainApp.getFilmData()) {\n if (matchesFilter(p)) {\n \tmainApp.getFilteredData().add(p);\n }\n }\n }",
"FeatureHolder filter(FeatureFilter fc, boolean recurse);",
"private boolean updateFilter() {\n \tList<Rankable> items = rankings.getRankings();\n \tHashSet<String> hashtags = new HashSet<String>();\n \t\n \tfor (Rankable item: items) {\n \thashtags.add((String)item.getObject());\n }\n \t\n \n \t\n \tfor(String word: initialWords){\n \t\thashtags.add(word);\n \t}\n \n \tif(filter.equals(hashtags)){\n \t\treturn false;\n \t} else {\n \t\tfilter = hashtags;\n \t\treturn true;\n \t}\n \n\t\t\n\t}",
"static public FileFilter nullFilter() {\n return new FileFilter();\n }",
"public static void filter() {\n\t\t\n\t\tResult.filter(toggleGroup.getSelectedToggle().getUserData(), ((ComboBox)hbox3.getChildren().get(0)).getValue());\n\t\t\n\t}",
"private void updateFilter(BasicOutputCollector collector) {\n if (updateFilter()){\n \tValues v = new Values();\n v.add(ImmutableList.copyOf(filter));\n \n collector.emit(\"filter\",v);\n \t\n }\n \n \n \n }",
"default ItemStack removeOneItem(Predicate<ItemStack> filter) {\n for (IInventoryAdapter inventoryObject : this) {\n InventoryManipulator im = InventoryManipulator.get(inventoryObject);\n ItemStack stack = im.removeItem(filter);\n if (!InvTools.isEmpty(stack))\n return stack;\n }\n return InvTools.emptyStack();\n }",
"boolean isEntriesFirst();",
"@Override\n public void filter(Filter arg0) throws NoTestsRemainException {\n super.filter(getCustomFilter());\n }",
"@Override\n public Filter getFilter() {\n return main_list_filter;\n }",
"private void filter(Node<Context> node) {\n if (node != null && node.parent != null) {\n Node<Context> parent = tree.getNode(node.parent);\n FilterInfo filterInfo = new FilterInfo(parent, node);\n filterStack.add(filterInfo);\n filter(filterInfo);\n tree.openNode(MODEL_BROWSER_ROOT, () -> tree.selectNode(MODEL_BROWSER_ROOT));\n }\n }",
"private void collectUsingStream() {\n List<Person> persons =\n Arrays.asList(\n new Person(\"Max\", 18),\n new Person(\"Vicky\", 23),\n new Person(\"Ron\", 23),\n new Person(\"Harry\", 12));\n\n List<Person> filtered = persons\n .stream()\n .filter(p -> p.name.startsWith(\"H\"))\n .collect(Collectors.toList());\n\n System.out.println(\"collectUsingStream Filtered: \" + filtered);\n }",
"public\t\tMiPart\t\tgetPrevious()\n\t\t{\n\t\tMiPart obj = iterator.getPrevious();\n\t\twhile ((obj == null) || ((filter != null) && ((obj = filter.accept(obj)) == null)))\n\t\t\t{\n\t\t\tif (!hasLayers)\n\t\t\t\treturn(null);\n\t\t\tif (!iterateThroughAllLayers)\n\t\t\t\treturn(null);\n\t\t\tMiContainerIterator iter = getPreviousIterator();\n\t\t\tif (iter == null)\n\t\t\t\treturn(null);\n\t\t\titerator = iter;\n\t\t\tobj = iterator.getPrevious();\n\t\t\t}\n\t\treturn(obj);\n\t\t}",
"Object removeFirst();",
"public void filter()\n {\n Map<String,Headline> currHeadlineMap;\n try\n {\n // Run while the thread has not been interrupted \n while( !Thread.currentThread().isInterrupted() )\n {\n synchronized(this.monitor)\n {\n this.monitor.wait(); // Wait for a plugin to finish\n Headline retrievedHeadline;\n \n while(this.queue.size() > 0) // While there are things to take\n {\n retrievedHeadline = this.queue.take(); //Take from the blocking queue\n currHeadlineMap = this.retrieved.get(retrievedHeadline.getSource()); // Retrieve map associated with headline source\n // Instantiate a new map if one does not exist yet\n if ( currHeadlineMap == null)\n {\n currHeadlineMap = new HashMap<>();\n }\n // Add headline the map for that news plugin\n currHeadlineMap.put(retrievedHeadline.getHeadline(), retrievedHeadline); \n\n // Insert the map for a plugin into the larger map of all headlines\n this.retrieved.put(retrievedHeadline.getSource(), currHeadlineMap); \n }\n \n // Retrieve map associated with the plugin that has just finished\n // Leaving all other headlines from other sources in the retrieved map\n currHeadlineMap = this.retrieved.get(finished);\n \n // Retrieve updated list\n List<Headline> update = updatedList(currHeadlineMap);\n\n // Clear the headline map for a plugin\n currHeadlineMap = new HashMap<>();\n \n // If the user has not signalled cancel prior to the filter finishing its task\n synchronized( this.cancelledMonitor )\n {\n if( !cancelled )\n { \n // Send the updated headline list to the UI\n this.ui.finishedTasks(finished + \" is running\");\n this.ui.update(update);\n theLogger.info(\"Update sent. Plugin:\" + finished);\n }\n else \n {\n clear();\n theLogger.info(\"Update cancelled\");\n }\n }\n \n }\n theLogger.info(\"Filter complete. Plugin:\" + finished);\n }\n }\n catch(InterruptedException e)\n {\n System.out.println(\"Interrupted filtering\");\n \n this.queue.clear(); // Empty queue\n this.retrieved = new HashMap<>(); // Reset all running plugins\n }\n }",
"public LinkedList <AbsAttraction> filter(ISelect s){\r\n return new LinkedList <AbsAttraction>(); \r\n }",
"protected Vector filterInputInternal(Vector before)\n\t{\n\t\treturn filterInternal(before, featureMins, featureMaxes);\n\t}",
"@Override\n\tpublic String find(Set<String> filterField) {\n\t\treturn null;\n\t}",
"@Override\n public Filter getFilter() {\n\n return new Filter() {\n @Override\n protected FilterResults performFiltering(CharSequence charSequence) {\n\n String charString = charSequence.toString();\n\n if (charString.isEmpty()) {\n\n mDataset = mArrayList;\n } else {\n\n ArrayList<DataObject> filteredList = new ArrayList<>();\n\n for (DataObject data : mArrayList) {\n\n if (data.getid().toLowerCase().contains(charString.toLowerCase()) || data.getname().toLowerCase().contains(charString.toLowerCase())) {\n\n filteredList.add(data);\n }\n }\n\n mDataset = filteredList;\n }\n\n FilterResults filterResults = new FilterResults();\n filterResults.values = mDataset;\n return filterResults;\n }\n\n @Override\n protected void publishResults(CharSequence charSequence, FilterResults filterResults) {\n mDataset = (ArrayList<DataObject>) filterResults.values;\n notifyDataSetChanged();\n }\n };\n }",
"@VTID(37)\n boolean getFilterCleared();",
"boolean hasFiltered() {\n return filtered;\n }",
"List<WebURL> Filter(List<WebURL> urls){\n return null;\n }",
"@Override\r\n\tpublic Collection<CBRCase> retrieveSomeCases(CaseBaseFilter arg0) {\n\t\treturn null;\r\n\t}",
"@Override\n public boolean isEmpty() {\n return filtered.isEmpty();\n }",
"public boolean get(boolean next) {\n for (BFilter filter : mFilters) {\n next = filter.get(next);\n }\n\n // Return filtered value\n return next;\n }",
"protected HttpRequestRecord filterRecord(HttpRequestRecord record) {\n return record;\n }",
"public List<Element> filter(Predicate<Element> p)\n\t{\n\t\treturn recursive_filter(new ArrayList<Element>(), p, group);\n\t}",
"public List<StudentRecord> filter(IFilter filter) {\n\t\tList<StudentRecord> temporaryList = new ArrayList<>();\n\n\t\tfor (StudentRecord studentRecord : studentRecords) {\n\t\t\tif (filter.accepts(studentRecord)) {\n\t\t\t\ttemporaryList.add(studentRecord);\n\t\t\t}\n\t\t}\n\t\treturn temporaryList;\n\t}",
"FilterResults performFiltering(CharSequence charSequence) { // Aplicamos el filtro\n String charString = charSequence.toString(); // String con el filtro\n if (charString.isEmpty()) { // Si esta vacio\n filteredSites = allSites; // No hay filtro y se muestran todas las instalaciones\n } else { // Si no\n ArrayList<ULLSiteSerializable> auxFilteredList = new ArrayList<>();\n for (ULLSiteSerializable site : allSites) { // Para todas las instalaciones \n // Se comprueba si el nombre la filtro coincide con la instalacion\n if (site.getName().toLowerCase().contains(charString.toLowerCase())) \n auxFilteredList.add(site); // Si coincide se agregan a la lista\n // auxiliar\n }\n filteredSites = auxFilteredList; // La lista auxiliar es igual a la de \n } // las instalaciones filtradas a mostrar\n FilterResults filterResults = new FilterResults();\n filterResults.values = filteredSites;\n return filterResults; // Se devuelve el resultado del filtro\n }",
"private Reviews filterByFunc(FilterFunction filterFunc)\n\t{\n\t\tArrayList<Review> filteredList = new ArrayList<Review>();\n\t\tfor(Review review : list)\n\t\t\tif(filterFunc.filter(review))\n\t\t\t\tfilteredList.add(review);\n\t\treturn new Reviews(filteredList);\n\t}",
"public void filterArticles() {\n filterAgent.score(articles, filterType);\n articles = insertionSort(articles); // sorted articles list\n\n refreshTable();\n if (articles.size() > 0) {\n currentArt = (NewsArticle) articles.elementAt(0);\n }\n }",
"PropertiedObjectFilter<O> getFilter();",
"static ObjectInputFilter createFilter(String param2String, boolean param2Boolean) {\n/* 446 */ Global global = new Global(param2String, param2Boolean);\n/* 447 */ return global.isEmpty() ? null : global;\n/* */ }",
"public String getFilter();",
"@Test\n @Order(2)\n public void findFirstTest() {\n Instant start = Instant.now();\n Optional<String> elementContainsCharZ = texts.stream()\n .map(String::toLowerCase)\n .filter(text -> text.contains(\"z\"))\n .findFirst();\n\n elementContainsCharZ.ifPresent(System.out::println);\n Instant end = Instant.now();\n System.out.println(\"Elapsed time of findFirst: \" + Duration.between(start, end).toNanos());\n }",
"public EventPacket filterPacket(EventPacket in) {\n if (in == null) {\n return null;\n }\n if (!filterEnabled) {\n return in;\n }\n if (enclosedFilter != null) {\n out = enclosedFilter.filterPacket(in);\n track(out);\n return out;\n } else {\n track(in);\n\n if (this.isSendToRubiosEnabled())\n {\n this.sendClustersToRubios();\n }\n return in;\n }\n }",
"public void filter(Filter filter) throws NoTestsRemainException {\n childrenLock.lock();\n try {\n List<T> children = new ArrayList<T>(getFilteredChildren());\n for (Iterator<T> iter = children.iterator(); iter.hasNext(); ) {\n T each = iter.next();\n if (shouldRun(filter, each)) {\n try {\n filter.apply(each);\n } catch (NoTestsRemainException e) {\n iter.remove();\n }\n } else {\n iter.remove();\n }\n }\n filteredChildren = Collections.unmodifiableCollection(children);\n if (filteredChildren.isEmpty()) {\n throw new NoTestsRemainException();\n }\n } finally {\n childrenLock.unlock();\n }\n }",
"protected Set<String> getFilter(StaplerRequest req) throws ServletException, IllegalAccessException, IllegalArgumentException, InvocationTargetException{\n Set<String> filter = new TreeSet<String>();\n String values[] = {\"other\",\"job\",\"view\",\"computer\",\"user\"};\n for(String s:values){\n if(req.getParameter(s)!=null)\n filter.add(s); \n }\n return filter;\n }",
"public void filterLowerPrice(double price){\n market.filterLowerPrice(price);\n car = market.filters;\n }",
"public Filter doUnion(Filter f);",
"private void detachFilter(Appender<ILoggingEvent> appender, FilterInfo fi){\n if(appender.getCopyOfAttachedFiltersList().contains(fi.filter)){\n //Clone\n List<Filter<ILoggingEvent>> filters = appender.getCopyOfAttachedFiltersList();\n\n //Clear\n appender.clearAllFilters();\n\n //Add\n for(Filter<ILoggingEvent> filter : filters){\n if(!fi.filter.equals(filter)){\n appender.addFilter(filter);\n }\n }\n }\n }",
"private void isFiltersSatisfied() {\n Filter[] filters = rule.getFilters();\n for (int i = 0; i < filters.length; i++) {\n linkedList.add(filters[i]);\n }\n recursiveFiltering(linkedList.peek().filter.split(\":\"),null);\n }",
"private Consumer<ExtendedRecord> filterByGbifId() {\n return er ->\n idTransformFn\n .apply(er)\n .ifPresent(\n id -> {\n if (skipTransform) {\n idMap.put(id.getId(), id);\n } else if (id.getInternalId() != null) {\n filter(id);\n } else {\n incMetrics(INVALID_GBIF_ID_COUNT);\n idInvalidMap.put(id.getId(), id);\n log.error(\"GBIF ID is null, occurrenceId - {}\", id.getId());\n }\n erIdMap.put(er.getId(), id);\n });\n }",
"protected NullFilterImpl() {\n }",
"@Override//过滤器执行顺序,当一个请求在同一个阶段的时候,存在多个过滤器的时候,多个过滤器的执行顺序问题\r\n\tpublic int filterOrder() {\n\t\treturn 0;\r\n\t}",
"private static Filter newFilter()\r\n {\r\n Filter filter = new Filter(\"filter1\", new Source(\"display1\", \"name1\", \"server\", \"key1\"));\r\n filter.getOtherSources().add(filter.getSource());\r\n Group group = new Group();\r\n group.addFilterCriteria(new Criteria(\"field1\", Conditional.EQ, \"123\"));\r\n Group group2 = new Group();\r\n group2.addFilterCriteria(new Criteria(\"field1\", Conditional.EQ, \"124\"));\r\n group.addFilterGroup(group2);\r\n filter.setFilterGroup(group);\r\n return filter;\r\n }",
"@Test\n public void testAbFiltering() throws Exception {\n final Set<String> fails = CollectionUtil.makeSet(\"tf2\", \"rs28566954\", \"rs28548431\");\n final File out = testFiltering(INPUT, \".vcf.gz\", 0.4, 0, 0, Double.MAX_VALUE);\n final ListMap<String, String> filters = slurpFilters(out);\n Assert.assertEquals(sorted(filters.keySet()), sorted(fails), \"Failed sites did not match expected set of failed sites.\");\n }",
"static ObjectInputFilter createFilter(String param2String, boolean param2Boolean) {\n/* 448 */ Global global = new Global(param2String, param2Boolean);\n/* 449 */ return global.isEmpty() ? null : global;\n/* */ }",
"protected boolean filterOutObject(PhysicalObject object) {\n return false;\n }"
] | [
"0.6762645",
"0.6699698",
"0.6699698",
"0.64500684",
"0.6260368",
"0.61056596",
"0.5889433",
"0.58422744",
"0.5814763",
"0.5808386",
"0.57897997",
"0.56999284",
"0.5672978",
"0.5632314",
"0.56083184",
"0.55796814",
"0.5550233",
"0.55480814",
"0.55443186",
"0.5536748",
"0.55217636",
"0.55167407",
"0.55160666",
"0.54711443",
"0.54623026",
"0.5457166",
"0.54354775",
"0.54346436",
"0.54108644",
"0.5403995",
"0.54025626",
"0.54025626",
"0.5396888",
"0.53948396",
"0.536189",
"0.53605145",
"0.53535247",
"0.5352108",
"0.5345007",
"0.53400725",
"0.53395534",
"0.5334885",
"0.53296995",
"0.5316833",
"0.53158796",
"0.53071517",
"0.53036904",
"0.529841",
"0.528574",
"0.52571857",
"0.5248957",
"0.5241338",
"0.5234605",
"0.52124757",
"0.5208932",
"0.51939636",
"0.51851666",
"0.5179347",
"0.5168273",
"0.51594484",
"0.51552343",
"0.5154234",
"0.5151923",
"0.5143089",
"0.51361233",
"0.5108862",
"0.51006556",
"0.5098992",
"0.509526",
"0.5090929",
"0.50855714",
"0.50832075",
"0.5081397",
"0.5060437",
"0.5057166",
"0.5037179",
"0.50312847",
"0.5028083",
"0.5025153",
"0.5024591",
"0.5018016",
"0.5016644",
"0.50145453",
"0.5011344",
"0.50014526",
"0.50000674",
"0.49855623",
"0.4984499",
"0.4983503",
"0.49808747",
"0.49769092",
"0.49763343",
"0.49709898",
"0.4964265",
"0.49614894",
"0.4953474",
"0.49472764",
"0.49436298",
"0.4941036",
"0.49392995",
"0.4932054"
] | 0.0 | -1 |
switch into or out of statuslineprinting mode (and when we switch out, actually send the updated status line to the screen) | public void print_statusline( boolean start, boolean left ) {
if ( start ) {
flush();
_status_line = new StringBuffer( 10 );
_status_line.append( _last_printed ); // store this here
return;
}
// this always prints to the statusline and is not affected by
// outhide() or outcapture()
flush();
_platform_io.set_status_string( _status_line.toString().substring( 1 ), left );
_last_printed = _status_line.charAt( 0 ); // and restore it
_status_line = null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void printStatus(){\n System.out.println();\n System.out.println(\"Status: \");\n System.out.println(currentRoom.getLongDescription());\n currentRoom.printItems();\n System.out.println(\"You have made \" + moves + \" moves so far.\");\n }",
"private boolean printing_status() {\n\t\treturn _status_line != null;\n\t}",
"public static void status(){\n System.out.print(\"\\033[H\\033[2J\");//limpia pantalla\n System.out.flush();\n System.out.printf(\"\\nNOMBRE:\\t\\t\\t\"+nombrePersonaje);\n\tSystem.out.printf(\"\\nPuntos De Vida (HP):\\t\"+puntosDeVida);\n\tSystem.out.printf(\"\\nPuntos De mana (MP):\\t\"+puntosDeMana);\n System.out.printf(\"\\nNivel: \\t\\t\\t\"+nivel);\n\tSystem.out.printf(\"\\nExperiencia:\\t\\t\"+experiencia);\n\tSystem.out.printf(\"\\nOro: \\t\\t\"+oro);\n System.out.printf(\"\\nPotion:\\t\\t\\t\"+articulo1);\n System.out.printf(\"\\nHi-Potion:\\t\\t\"+articulo2);\n System.out.printf(\"\\nM-Potion:\\t\\t\"+articulo3);\n System.out.printf(\"\\n\\tEnemigos Vencidos:\\t\");\n\tSystem.out.printf(\"\\nNombre:\\t\\t\\tNo.Derrotas\");\n System.out.printf(\"\\nDark Wolf:\\t\\t\"+enemigoVencido1);\n\tSystem.out.printf(\"\\nDragon:\\t\\t\\t\"+enemigoVencido2);\n System.out.printf(\"\\nMighty Golem:\\t\\t\"+enemigoVencido3);\t\n }",
"public void printStatus();",
"private void internalSetStatus(String status) {\n jStatusLine.setText(\"Status: \" + status);\n }",
"public void switchStatus() {\n if (ioStatus.get() == EdgeStatus.INPUT) {\n ioStatus.set(EdgeStatus.OUTPUT);\n } else {\n ioStatus.set(EdgeStatus.INPUT);\n }\n }",
"void printout() {\n\t\tprintstatus = idle;\n\t\tanyprinted = false;\n\t\tfor (printoldline = printnewline = 1;;) {\n\t\t\tif (printoldline > oldinfo.maxLine) {\n\t\t\t\tnewconsume();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (printnewline > newinfo.maxLine) {\n\t\t\t\toldconsume();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (newinfo.other[printnewline] < 0) {\n\t\t\t\tif (oldinfo.other[printoldline] < 0)\n\t\t\t\t\tshowchange();\n\t\t\t\telse\n\t\t\t\t\tshowinsert();\n\t\t\t} else if (oldinfo.other[printoldline] < 0)\n\t\t\t\tshowdelete();\n\t\t\telse if (blocklen[printoldline] < 0)\n\t\t\t\tskipold();\n\t\t\telse if (oldinfo.other[printoldline] == printnewline)\n\t\t\t\tshowsame();\n\t\t\telse\n\t\t\t\tshowmove();\n\t\t}\n\t\tif (anyprinted == true)\n\t\t\tprintln(\">>>> End of differences.\");\n\t\telse\n\t\t\tprintln(\">>>> Files are identical.\");\n\t}",
"static void printStatus() {\r\n System.out.println(\"\"\"\r\n\r\n +---------------------------------------+\r\n | Welcome to the FIT2099 AutoShowroom! |\r\n +---------------------------------------+\"\"\");\r\n while(isRunning){\r\n try {\r\n consoleMenu();\r\n } catch (InputMismatchException e) {\r\n System.out.println(\"\\nInput Mismatch Exception encountered, sorry for the inconvenience!\");\r\n } catch (RuntimeException e) {\r\n System.out.println(\"\\nRuntime Exception encountered, sorry for the inconvenience!\");\r\n } catch (Exception e) {\r\n System.out.println(\"\\nSome other Exception encountered, sorry for the inconvenience!\");\r\n }\r\n }\r\n System.out.println(\"\\nThank you for visiting the FIT2099 Showroom\");\r\n }",
"public void flush() {\n\t\tif ( !printing_status() ) {\n\t\t\tint sz = _platform_io.size_text( _current_word.toString() );\n\t\t\tif ( _last_column + sz >= _wrap_column ) {\n\t\t\t\tinc_line();\n\t\t\t}\n\n\t\t\t_last_column += sz;\n\t\t\t_platform_io.print_text( _current_word.toString() );\n\t\t\t_current_word.setLength( 0 );\n\t\t} else {\n\t\t\t_status_line.append( _current_word.toString() );\n\t\t\t_current_word.setLength( 0 );\n\t\t}\n\t}",
"private void displayStatus(final byte b) {\n\n\t\trunOnUiThread(new Runnable() {\n\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\tbyte[] output = {b};\n Log.d(TAG, \"status: \" + Utils.bytesToHex2(output)); \n\t\t\t\tString currentTime = \"[\" + formater.format(new Date()) + \"] : \";\n\t\t\t\tif ((byte) (b & 0x01) == 0x01) {\n\t\t\t\t\tsynchronized (this) {\n\t\t\t\t\t\tisUsbDisconnected = false;\n\t\t\t\t\t}\n\t\t\t\t\tledUsb.setPressed(true);\n\t\t\t\t\tif ((byte) (mPreviousStatus & 0x01) == 0x00)\n\t\t\t\t\t\tlog(currentTime + \"usb connected\");\n\t\t\t\t} else {\n\t\t\t\t\tledUsb.setPressed(false);\n\t\t\t\t\tif ((byte) (mPreviousStatus & 0x01) == 0x01)\n\t\t\t\t\t\tlog(currentTime + \"usb disconnected\");\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\tif ((byte) (b & 0x02) == 0x02) {\n\t\t\t\t\tledWifi.setPressed(true);\n\t\t\t\t\tif ((byte) (mPreviousStatus & 0x02) == 0x00)\n\t\t\t\t\t log(currentTime + \"wifi connected\");\n\t\t\t\t\t\n\t\t\t\t} else {\n\t\t\t\t\tledWifi.setPressed(false);\n\t\t\t\t\tif ((byte) (mPreviousStatus & 0x02) == 0x02)\n\t\t\t\t\tlog(currentTime + \"wifi disconnected\");\n\t\t\t\t\n\t\t\t\t}\n\n\t\t\t\tif ((byte) (b & 0x04) == 0x04) {\n\t\t\t\t\tledTelep.setPressed(true);\n\t\t\t\t\tif ((byte) (mPreviousStatus & 0x04) == 0x00)\n\t\t\t\t log(currentTime + \"telep. connected\");\n\t\t\t\t\t\n\t\t\t\t} else {\n\t\t\t\t\tledTelep.setPressed(false);\n\t\t\t\t\tif ((byte) (mPreviousStatus & 0x04) == 0x04)\n\t\t\t\t\tlog(currentTime + \"telep. disconnected\");\n\t\t\t\t\t\n\t\t\t\t}\n\n\t\t\t\tmPreviousStatus = b;\n\n\t\t\t}\n\t\t});\n\n\t}",
"private void changeStatusBar(String status)\r\n {\r\n jStatusBar.setText(status);\r\n }",
"private static void statusCommand() {\n String lineFormat = \"%-8s | %-15s | %s\\n\";\n\n List<Job> neededJobs = fetchNeededJobs();\n\n // table header\n if (neededJobs.size() < 2) {\n System.out.printf(lineFormat, \"STATE\", \"START TIME\", \"JOB DIRECTORY\");\n for (int i = 0; i < 78; i++) {\n System.out.print(((9 == i || 27 == i) ? \"+\" : \"-\"));\n }\n System.out.println();\n }\n\n // table rows\n ObjectCounter<JobState> counter = new ObjectCounter<JobState>();\n for (Job job : neededJobs) {\n Date startDate = job.getStartDate();\n JobState state = job.getState();\n counter.add(state);\n String startDateStr = (null == startDate) ? \"N/A\" : new SimpleDateFormat(\"yyyyMMdd HHmmss\").format(startDate);\n System.out.printf(lineFormat, state.toString(), startDateStr, job.getDir());\n }\n\n // table footer\n System.out.println();\n String sumFormat = \"%6d %s\\n\";\n System.out.printf(sumFormat, heritrix.getJobs().size(), \"TOTAL JOBS\");\n for (JobState state : JobState.values()) {\n if (counter.getMap().keySet().contains(state)) {\n System.out.printf(sumFormat, counter.get(state), state.toString());\n }\n }\n }",
"void updateStatusLines(boolean showStatusLines) {\n if (DEBUG) Log.v(TAG, \"updateStatusLines(\" + showStatusLines + \")\");\n mShowingStatus = showStatusLines;\n updateAlarmInfo();\n updateOwnerInfo();\n updateStatus1();\n updateCarrierText();\n }",
"void showchange() {\n\t\tif (printstatus != change)\n\t\t\tprintln(\">>>> \" + printoldline + \" CHANGED FROM <br/>\");\n\t\tprintstatus = change;\n\t\toutput+=oldinfo.symbol[printoldline].showSymbol();\n\t\toutput+=\"<br/>\";\n\t\tanyprinted = true;\n\t\tprintoldline++;\n\t}",
"private void printTestingStatus(final boolean status) {\n this.out.println();\n this.print(\n new If<Text>(\n () -> status,\n () -> new GreenText(\"Testing successful.\"),\n () -> new RedText(\"Testing failed.\")\n ).value().text()\n );\n this.out.println();\n }",
"public void status(leapstream.scoreboard.core.model.Status status) {\n Stati stati = status.is();\n foreground(stati);\n background(stati);\n label.text(\"\" + stati);\n }",
"private void updateStatusText() {\n Piece.Color playerColor = board.getTurnColor();\n\n if(board.isGameOver()) {\n if(board.isDraw()) {\n tvShowStatus.setTextColor(Color.BLUE);\n tvShowStatus.setText(\"DRAW\");\n }\n else if (board.getWinnerColor() == Piece.Color.Black) {\n tvShowStatus.setTextColor(Color.BLACK);\n tvShowStatus.setText(\"BLACK WINS\");\n }\n else {\n tvShowStatus.setTextColor(Color.WHITE);\n tvShowStatus.setText(\"WHITE WINS\");\n }\n }\n else if(playerColor == Piece.Color.Black) {\n tvShowStatus.setTextColor(Color.BLACK);\n tvShowStatus.setText(\"BLACK\");\n }\n else {\n tvShowStatus.setTextColor(Color.WHITE);\n tvShowStatus.setText(\"WHITE\");\n }\n }",
"private void handle_mode_display() {\n\t\t\t\n\t\t}",
"public abstract void onLineMode ();",
"public void showStatus(){\n\t\tjlMoves.setText(\"\"+moves);\n\t\tjlCorrectMoves.setText(\"\"+correctMoves);\n\t\tjlWrongMoves.setText(\"\"+wrongMoves);\n\t\tjlOpenMoves.setText(\"\"+openMoves);\n\t\tjlNumberGames.setText(\"\"+numberGames);\n\t}",
"private void updateGUIStatus() {\r\n\r\n }",
"public void notifyGameOn() {\n this.myStatusString.setText(\"Game is On\");\n final LineBorder line = new LineBorder(Color.GREEN, 2, true);\n this.myStatusString.setBorder(line);\n this.myStatusString.setForeground(Color.GREEN);\n this.myStatusString.setFont(new Font(FONT_TIMES, Font.BOLD, NUM_FONT_SIZE)); \n }",
"private void updateStatus(final String status)\n {\n jLabelStatus.setText(status);\n jLabelStatus.paintImmediately(jLabelStatus.getVisibleRect());\n }",
"@Override\n public void printActionsAndReceiveInput(Terminal terminal) { this.terminal=terminal;\n inputBasicMode();\n responseIsReady = true;\n }",
"private void feedback_output(){\r\n\t\tif(up){controller_computer.gui_computer.PressedBorderUp();}\r\n\t\tif(down){controller_computer.gui_computer.PressedBorderDown();}\r\n\t\tif(right){controller_computer.gui_computer.PressedBorderRight();}\r\n\t\tif(left){controller_computer.gui_computer.PressedBorderLeft();}\r\n\t}",
"public void setStatus(char status) {\n\t\tthis.status = status;\n\t}",
"private void displayLine()\n {\n System.out.println(\"#################################################\");\n }",
"public void printStatus() {\n\t\tSystem.out.println(\"Current : \"+current+\"\\n\"\n\t\t\t\t+ \"Tour restant : \"+nb_rounds+\"\\n\"\n\t\t\t\t\t\t+ \"Troupe restant : \"+nb_to_train);\n\t}",
"private void pause() {\n if (!isStarted) {\n return;\n }\n\n isPaused = !isPaused;\n\n if (isPaused) {\n\n statusbar.setText(\"paused\");\n } else {\n\n statusbar.setText(String.valueOf(numLinesRemoved));\n }\n }",
"private void statusCheck() {\n\t\tif(status.equals(\"waiting\")) {if(waitingPlayers.size()>1) status = \"ready\";}\n\t\tif(status.equals(\"ready\")) {if(waitingPlayers.size()<2) status = \"waiting\";}\n\t\tif(status.equals(\"start\")) {\n\t\t\tif(players.size()==0) status = \"waiting\";\n\t\t}\n\t\tview.changeStatus(status);\n\t}",
"public void print() {\n System.out.println(\"I am \" + status() + (muted ? \" and told to shut up *sadface*\" : \"\") + \" (\" + toString() + \")\");\n }",
"void showmove() {\n\t\tint oldblock = blocklen[printoldline];\n\t\tint newother = newinfo.other[printnewline];\n\t\tint newblock = blocklen[newother];\n\n\t\tif (newblock < 0)\n\t\t\tskipnew(); // already printed.\n\t\telse if (oldblock >= newblock) { // assume new's blk moved.\n\t\t\tblocklen[newother] = -1; // stamp block as \"printed\".\n\t\t\tprintln(\">>>> \" + newother + \" THRU \" + (newother + newblock - 1)\n\t\t\t\t\t+ \" MOVED TO BEFORE \" + printoldline + \"<br/>\");\n\t\t\tfor (; newblock > 0; newblock--, printnewline++)\n\t\t\t{\n\t\t\t\toutput+=newinfo.symbol[printnewline].showSymbol();\n\t\t\t\toutput+=\"<br/>\";\n\t\t\t}\n\t\t\tanyprinted = true;\n\t\t\tprintstatus = idle;\n\n\t\t} else\n\t\t\t/* assume old's block moved */\n\t\t\tskipold(); /* target line# not known, display later */\n\t}",
"private void instruct() {\n\t\tif (vsComputer) {\n\t\t\tSystem.out.println(\"\"\"\n 1. Stone\n 2. Paper\n 3. Scissors\n You have to enter your choice\n \"\"\");\n\t\t}\n\t}",
"void resetStatus();",
"public void setStatus(String newStatus)throws Exception{\n\t\t\n\t\tthis.status = newStatus;\n\t\toverWriteLine(\"Status\", newStatus);\n\t}",
"public static void updateStatusBar(){\n\t\tstatus.setText(\"Sensors: \"+Sensor.idToSensor.size()+(TurnController.getInstance().getCurrentTurn()!=null?\", Turn: \"+TurnController.getInstance().getCurrentTurn().turn:\"\"));\n\t}",
"public void sendStatusToServer(String status){\n System.out.println(\"typingstatus\" + chatID + username + \" \" + status);\n toServer.println(\"typingstatus\"+ \" \" + chatID + \" \" + username + \" \" + status);\n toServer.flush();\n }",
"private void updateStatus() {\n \tif (!status.getText().equals(\"\")) {\n\t\t\tif (currentProfile != null) {\n\t\t\t\tcurrentProfile.setStatus(status.getText());\n\t\t\t\tcanvas.displayProfile(currentProfile);\n\t\t\t\tcanvas.showMessage(\"Status updated to \" + status.getText());\n\t\t\t} else {\n\t\t\t\tcanvas.showMessage(\"Please select a profile to change status\");\n\t\t\t}\n\t\t}\n\t}",
"@Override\n public void move(int type) {\n System.out.println(\"本次乘坐豪华型交通工具出行\");\n }",
"public void changeStatus()\n {\n if(this.isActivate == false)\n {\n this.isActivate = true;\n switchSound.play();\n //this.dungeon.updateSwitches(true); \n }\n else{\n this.isActivate = false;\n switchSound.play(1.75, 0, 1.5, 0, 1);\n //this.dungeon.updateSwitches(false); \n }\n notifyObservers();\n\n }",
"void suspendOutput();",
"StatusLine getStatusLine();",
"void setStatus(java.lang.String status);",
"@Override\n public void update() {\n CommandNodeGameState gs = (CommandNodeGameState) state;\n String acc = String.valueOf(gs.getAcc());\n accView.setText(acc);\n String bak = String.valueOf(gs.getBak());\n bakView.setText(bak);\n String last = String.valueOf(gs.getLast());\n lastView.setText(last);\n String mode = String.valueOf(gs.getMode());\n modeView.setText(mode);\n String idle = String.valueOf(0);\n idleView.setText(idle);\n\n StringBuilder builder = new StringBuilder();\n for (int i = 0; i < gs.lineCount(); i++) {\n builder.append(gs.getLine(i).toString());\n builder.append(\"\\n\");\n }\n textArea.setText(builder.toString());\n\n if (state.isActive()) {\n highlightedLine = gs.getSelectedLine();\n } else {\n highlightedLine = null;\n }\n invalidate();\n }",
"void switchScreen()\n {\n\n byte[] data = new byte[13];\n data[0] = (byte)0xF0;\n data[1] = (byte)0x00;\n data[2] = (byte)0x01;\n data[3] = (byte)0x05;\n data[4] = (byte)0x21;\n data[5] = (byte)DEFAULT_ID; //(byte)getID();\n data[6] = (byte)0x02; // \"Write Dump\" What??? Really???\n data[7] = (byte)0x15; // UNDOCUMENTED LOCATION\n data[8] = (byte)0x00; // UNDOCUMENTED LOCATION\n data[9] = (byte)0x01; // UNDOCUMENTED LOCATION\n data[10] = (byte)0x00; \n data[11] = (byte)0x00;\n data[12] = (byte)0xF7;\n tryToSendSysex(data);\n }",
"public synchronized void setState(Status status){\n state=status;\n if(status.equals(Status.RED)){\n updateScreen(\"red\");\n }\n else if(status.equals(Status.YELLOW)){\n updateScreen(\"yellow\");\n }\n }",
"public static void battleStatus(){\n Program.terminal.println(\"________________TURN \"+ turn +\"________________\");\n Program.terminal.println(\"\");\n Program.terminal.println(\" +-------------------- \");\n Program.terminal.println(\" |Name:\"+ currentMonster.name);\n Program.terminal.println(\" |HP: \" + currentMonster.currentHp+\"/\"+currentMonster.hp);\n Program.terminal.println(\" |\" + barGauge(1));\n Program.terminal.println(\" +-------------------- \");\n Program.terminal.println(\"\");\n Program.terminal.println(\"My HP:\" + MainCharacter.hpNow +\"/\"+ MainCharacter.hpMax + \" \" + barGauge(2));\n Program.terminal.println(\"My MP:\" + MainCharacter.mpNow +\"/\"+ MainCharacter.mpMax + \" \" + barGauge(3));\n Program.terminal.println(\"\");\n askAction();\n }",
"private void addStateLog(){\n int state = GUIState.getState();\n if(state == 1){\n addText(\"Beginning \" + GUIState.command + \" processing!\");\n addText(\"Choose which card this card will affect!\");\n } if(state == 2){\n if(GUIState.command.equals(\"Summon\") || GUIState.command.equals(\"Defense\")){\n addText(\"Beginning \" + GUIState.command + \" processing!\");\n }\n addText(\"Choose where to put this card!\");\n }\n }",
"public void setSprinting ( boolean sprinting ) {\n\t\texecute ( handle -> handle.setSprinting ( sprinting ) );\n\t}",
"public void updateStatus(final String newStatus)\n\t{\n\t\tif(statusBar!=null)\n\t\t{\n\t\t\tstatusBar.setText(\"Program Status: \" + newStatus);\n\t\t}\n\t\t//statusBar.repaint();\n\t}",
"void inProcessing(String statusMsg);",
"private void setStatusBar(String statusMsg)\r\n {\r\n\r\n debug(\"setStatusBar() - get a handle to the main application\");\r\n StockMarketApp mainApp = getMainApp();\r\n\r\n if (mainApp != null)\r\n {\r\n debug(\"setStatusBar() - Sending message to change applications\");\r\n mainApp.setStatus(statusMsg);\r\n }\r\n debug(\"setStatusBar() - Processing completed\");\r\n }",
"void setStatus(int status);",
"public void setStatus(String status) {\n SwingUtilities.invokeLater(() -> {\n this.internalSetStatus(status);\n });\n }",
"private void updateStatus() {\n if (bold != null) {\n bold.setDown(basic.isBold());\n }\n\n if (italic != null) {\n italic.setDown(basic.isItalic());\n }\n\n if (underline != null) {\n underline.setDown(basic.isUnderlined());\n }\n\n if (subscript != null) {\n subscript.setDown(basic.isSubscript());\n }\n\n if (superscript != null) {\n superscript.setDown(basic.isSuperscript());\n }\n\n if (strikethrough != null) {\n strikethrough.setDown(extended.isStrikethrough());\n }\n }",
"public void moveAccepted()\n {\n printOut(printerMaker.moveAccepted());\n }",
"public void setStatus(boolean newStatus);",
"public void setSecondaryPrintIndicator(java.lang.String param){\n localSecondaryPrintIndicatorTracker = true;\n \n this.localSecondaryPrintIndicator=param;\n \n\n }",
"private void printStatusHtmlEnd\n\t\t(PrintWriter out)\n\t\t{\n\t\tout.println (\"<P>\");\n\t\tout.println (\"<TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0>\");\n\t\tout.println (\"<TR>\");\n\t\tout.println (\"<TD ALIGN=\\\"left\\\" VALIGN=\\\"top\\\">\");\n\t\tout.println (\"Web interface: \");\n\t\tout.println (\"</TD>\");\n\t\tout.println (\"<TD ALIGN=\\\"left\\\" VALIGN=\\\"top\\\">\");\n\t\tout.print (\"<A HREF=\\\"\");\n\t\tprintWebInterfaceURL (out);\n\t\tout.print (\"\\\">\");\n\t\tprintWebInterfaceURL (out);\n\t\tout.println (\"</A>\");\n\t\tout.println (\"</TD>\");\n\t\tout.println (\"</TR>\");\n\t\tout.println (\"<TR>\");\n\t\tout.println (\"<TD ALIGN=\\\"left\\\" VALIGN=\\\"top\\\">\");\n\t\tout.println (\"Powered by Parallel Java: \");\n\t\tout.println (\"</TD>\");\n\t\tout.println (\"<TD ALIGN=\\\"left\\\" VALIGN=\\\"top\\\">\");\n\t\tout.println (\"<A HREF=\\\"http://www.cs.rit.edu/~ark/pj.shtml\\\">http://www.cs.rit.edu/~ark/pj.shtml</A>\");\n\t\tout.println (\"</TD>\");\n\t\tout.println (\"</TR>\");\n\t\tout.println (\"<TR>\");\n\t\tout.println (\"<TD ALIGN=\\\"left\\\" VALIGN=\\\"top\\\">\");\n\t\tout.println (\"Developed by Alan Kaminsky: \");\n\t\tout.println (\"</TD>\");\n\t\tout.println (\"<TD ALIGN=\\\"left\\\" VALIGN=\\\"top\\\">\");\n\t\tout.println (\"<A HREF=\\\"http://www.cs.rit.edu/~ark/\\\">http://www.cs.rit.edu/~ark/</A>\");\n\t\tout.println (\"</TD>\");\n\t\tout.println (\"</TR>\");\n\t\tout.println (\"</TABLE>\");\n\t\tout.println (\"</BODY>\");\n\t\tout.println (\"</HTML>\");\n\t\t}",
"public static void printUpdateAnswerLine(FlashCard flashCard) {\n // No offset since printing from start of line.\n System.out.println(System.lineSeparator() + flashCard.toString(false, 0));\n System.out.println(NEW_ANSWER_LINE);\n printPrompt();\n }",
"@Override\n\t\tpublic void onReceive(Context context, Intent intent) {\n\t\t\tString action = intent.getAction();\n\t\t\tif(action.equalsIgnoreCase(PosApi.ACTION_POS_COMM_STATUS)){\n\t\t\t\tint cmdFlag =intent.getIntExtra(PosApi.KEY_CMD_FLAG, -1);\n\t\t\t\tint status\t=intent.getIntExtra(PosApi.KEY_CMD_STATUS , -1);\n\n\t\t\t\tif(cmdFlag== PosApi.POS_PRINT_PICTURE || cmdFlag == PosApi.POS_PRINT_TEXT){\n\n\t\t\t\t\tswitch(status){\n\t\t\t\t\tcase PosApi.ERR_POS_PRINT_SUCC:\n\t\t\t\t\t\t//Print Success\n\t\t\t\t\t\tprintNext();\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase PosApi.ERR_POS_PRINT_NO_PAPER:\n\t\t\t\t\t\t//No paper\n\t\t\t\t\t\tprintStop(status);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase PosApi.ERR_POS_PRINT_FAILED:\n\t\t\t\t\t\t//Print Failed\n\t\t\t\t\t\tprintStop(status);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase PosApi.ERR_POS_PRINT_VOLTAGE_LOW:\n\t\t\t\t\t\t//Low Power\n\t\t\t\t\t\tprintStop(status);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase PosApi.ERR_POS_PRINT_VOLTAGE_HIGH:\n\t\t\t\t\t\t//Hight Power\n\t\t\t\t\t\tprintStop(status);\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t\tif(cmdFlag == PosApi.POS_PRINT_GET_STATE){\n\t\t\t\t\tif(mListener==null){\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tmListener.onGetState(status);\n\t\t\t\t}\n\n\t\t\t\tif(cmdFlag == PosApi.POS_PRINT_SETTING){\n\t\t\t\t\tif(mListener==null){\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tmListener.onPrinterSetting(status);\n\t\t\t\t}\n\n\t\t\t}\n\t\t}",
"private void doPrintAdvice(){\n\t\tcurrentStep = OPERATION_NAME+\": printing advice\";\n\t\tString[] toDisplay = {\n\t\t\t\t\"Operation succeeded!\",\n\t\t\t\t\"You have changed your password\",\n\t\t\t\t\"Press 1 -> Print the advice\",\n\t\t\t\t\"Press 2 -> Quit without printing\"\n\t\t};\n\t\tif (!_atmssHandler.doDisDisplayUpper(toDisplay)) {\n\t\t\trecord(\"Dis\");\n\t\t\treturn;\n\t\t}\n\t\twhile (true) {\n\t\t\tString userInput = _atmssHandler.doKPGetSingleInput(TIME_LIMIT);\n\t\t\tif (userInput == null) return;\n\t\t\tif (userInput.equals(\"1\")) {\n\t\t\t\tString[] toPrint = {\n\t\t\t\t\t\t\"Operation name: \" + OPERATION_NAME,\n\t\t\t\t\t\t\"Card Number: \" + _session.getCardNo(),\n\t\t\t\t\t\t\"Result: succeeded\"\n\t\t\t\t};\n\t\t\t\tif (!_atmssHandler.doAPPrintStrArray(toPrint)) record(\"AP\");\n\t\t\t\treturn;\n\t\t\t} else if (userInput.equals(\"2\")) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t}",
"public void setStable() {\n this.unstable = false;\n this.unstableTimeline.stop();\n this.statusLed.setFastBlink(false);\n if (this.shutdownButton.isSelected() == true) {\n this.statusLed.setStatus(\"off\");\n } else if (this.offlineButton.isSelected() == true) {\n this.statusLed.setStatus(\"warning\");\n } else {\n this.statusLed.setStatus(\"ok\");\n } \n }",
"protected void printMove(GameStatus status, int index) {\n System.out.println(name + \" chose \" + index + \" \" + status.remainingCandidates.get(index).name\n + \"(\" + status.remainingCandidates.get(index).score(compatibilityScoreSet) + \")\\n\");\n }",
"private void updateStatus() {\n Response block = blockTableModel.getChainHead();\n int height = (block != null ? block.getInt(\"height\") : 0);\n nodeField.setText(String.format(\"<html><b>NRS node: [%s]:%d</b></html>\",\n Main.serverConnection.getHost(),\n Main.serverConnection.getPort()));\n chainHeightField.setText(String.format(\"<html><b>Chain height: %d</b></html>\",\n height));\n connectionsField.setText(String.format(\"<html><b>Peer connections: %d</b></html>\",\n connectionTableModel.getActiveCount()));\n }",
"@Override\n\tpublic void statusVomMenschen() {\n\t\tSystem.out.println(\"Sie wurden getroffen nun können Sie nicht mehr so schnell laufen!\");\n\t}",
"public void setStatus(boolean status) {\r\n this.AsGraph.setEnabled(status);\r\n this.AsDia.setEnabled(status);\r\n this.AsFile.setEnabled(status);\r\n this.AsDB.setEnabled(status);\r\n\r\n this.FileOutBox.setEnabled(status);\r\n this.DBOutBox.setEnabled(status);\r\n this.startFileDB.setEnabled(status);\r\n if (status && (this.DBOutBox.isSelected() || this.FileOutBox.isSelected())) {\r\n this.startFileDB.setEnabled(true);\r\n } else {\r\n this.startFileDB.setEnabled(false);\r\n }\r\n }",
"public void turnOnSystemOutput(){\n if(originalSystemOut == null){\n originalSystemOut = System.out;\n System.setOut(new PrintStream(generalStream));\n //will cause CSS hang up\n// System.setIn(console.getInputStream());\n }\n }",
"protected void logToScreen() {\r\n\t\tif (smscListener != null) {\r\n\t\t\tsynchronized (processors) {\r\n\t\t\t\tdisplayInfo = !displayInfo;\r\n\t\t\t\tint procCount = processors.count();\r\n\t\t\t\tSimulatorPDUProcessor proc;\r\n\t\t\t\tfor (int i = 0; i < procCount; i++) {\r\n\t\t\t\t\tproc = (SimulatorPDUProcessor) processors.get(i);\r\n\t\t\t\t\tproc.setDisplayInfo(displayInfo);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tfactory.setDisplayInfo(displayInfo);\r\n\t\t}\r\n\t}",
"private static void clearScreen() {\n\t\tSystem.out.println(\"\\033[H\\033[2J\"); \n\t\tSystem.out.flush();\n\t}",
"private void makeTerminalReady() {\n if (currentMode != MODE_CONV) {\n doSetConversationalMode();\n }\n }",
"protected void setStatus(String status) {\n Message msg = mHandler.obtainMessage(DIALOG_UPDATE, status);\n mHandler.sendMessage(msg);\n }",
"public void setStatus(Status newStatus){\n status = newStatus;\n }",
"public void update() \n {\n System.out.print( \" \" + Integer.toHexString( subj.getState() ) ); \n}",
"public void setgetStatus()\r\n\t{\r\n\t\tthis.status = 'S';\r\n\t}",
"public void printDetails()\r\n\t{\r\n\t\tSystem.out.println(flightNumber);\r\n\t\tSystem.out.println(departurePoint);\r\n\t\tSystem.out.println(destination);\r\n\t\tSystem.out.println(departureTime);\r\n\t\tSystem.out.println(arrivalTime);\r\n\t\tSystem.out.println(checkedInPassengers);\r\n\t\tif(status == 'S')\r\n\t\t\tSystem.out.println(\"Scheduled\");\r\n\t\t\t\r\n\t\tif(status == 'B')\r\n\t\t\tSystem.out.println(\"Boarding\");\r\n\t\tif(status == 'D')\r\n\t\t\tSystem.out.println(\"Departed\");\r\n\t\tif(status == 'C')\r\n\t\t\tSystem.out.println(\"Canceled\");\r\n\t\t\r\n\t\t\t\t\r\n\t}",
"void setStatus(STATUS status);",
"protected void setOffLineMode () {\n if (theDowntimeMgr != null)\n theDowntimeMgr.setOnLine(false);\n }",
"public void setStatus(int status);",
"public void setStatus(int status);",
"public void turnOn() {\n this.status = true;\n update(this.redValue, this.greenValue, this.blueValue);\n }",
"public abstract void offLineMode ();",
"public void status(boolean b) {\n status = b;\n }",
"void setStatus(String status);",
"public void clearScreen() { \n\t System.out.print(\"\\033[H\\033[2J\"); \n\t System.out.flush(); \n\t }",
"private void prepareStatus() {\n clock = new JLabel(new Date().toString());\n statusPanel = new JPanel();\n statusPanel.setBorder(new BevelBorder(BevelBorder.LOWERED));\n this.add(statusPanel, BorderLayout.SOUTH);\n statusPanel.setPreferredSize(new Dimension(this.getWidth(), 16));\n statusPanel.setLayout(new BoxLayout(statusPanel, BoxLayout.X_AXIS));\n statusLabel = new JLabel(\"status\");\n statusLabel.setHorizontalAlignment(SwingConstants.LEFT);\n statusPanel.add(statusLabel);\n statusPanel.add(new JLabel(\" \"));\n clock.setHorizontalAlignment(SwingConstants.RIGHT);\n statusPanel.add(clock);\n \n ActionListener updateClockAction = new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n clock.setText(new Date().toString()); \n }\n };\n Timer t = new Timer(1000, updateClockAction);\n t.start();\n }",
"public void updateOn(boolean on) {\r\n\t\toutString = \"O\" + on + \"\\n\";\r\n\t\tmyPort.write(outString);\r\n\t\tSystem.out.println(outString);\r\n\t}",
"public void setStatus(boolean status) {\n\tthis.status = status;\n }",
"private void displayStoppedScreen(final Graphics2D theGraphics) {\n final int relativeFontSize = myWidth / 5;\n theGraphics.setFont(new Font(FONT_TYPE, Font.BOLD, relativeFontSize));\n theGraphics.setPaint(STOPPED_COLOR);\n theGraphics.fill(new Rectangle2D.Double(0, 0, myWidth, myHeight));\n theGraphics.setPaint(Color.WHITE);\n\n if (myWelcome) {\n drawCenteredString(\"WELCOME\", theGraphics);\n } else if (myGameOver) {\n drawCenteredString(\"GAME OVER\", theGraphics);\n } else {\n drawCenteredString(\"PAUSED\", theGraphics);\n }\n }",
"private void setUIState(WorkoutServiceStatus status) {\n\n\t\tboolean shouldEnableTimer = false;\n\n\t\t// If we can't start a new workout, and we're not monitoring, then we're in the \"setup\" phase.\n\t\tif (status == null || !(status.canStartNewWorkout() || status.isMonitoring())) {\n\t\t\t//symptoms and notifications are disabled\n//\t\t\tbtnSymptoms.setEnabled(false);\n//\t\t\tbtnNotifications.setEnabled(false);\n\t\t\tbtnSelectWorkout.setEnabled(false);\n\t\t\tbtnStartWorkout.setVisibility(View.INVISIBLE);\n\t\t\tbtnStopWorkout.setVisibility(View.INVISIBLE);\n\t\t}\n\n\t\t// If we're monitoring, we're in the \"workout\" phase.\n\t\telse if (status.isMonitoring()) {\n//\t\t\tbtnSymptoms.setEnabled(true);\n//\t\t\tbtnNotifications.setEnabled(true);\n\t\t\tbtnSelectWorkout.setEnabled(false);\n\t\t\tbtnStartWorkout.setVisibility(View.INVISIBLE);\n\t\t\tbtnStopWorkout.setVisibility(View.VISIBLE);\n\t\t\tshouldEnableTimer = true;\n\t\t}\n\n\t\t// if we're not monitoring (but we can start a new workout), we're in the \"ready\" phase.\n\t\telse {\n//\t\t\tbtnSymptoms.setEnabled(false);\n//\t\t\tbtnNotifications.setEnabled(false);\n\t\t\tbtnSelectWorkout.setEnabled(true);\n\t\t\tbtnStartWorkout.setVisibility(View.VISIBLE);\n\t\t\tbtnStopWorkout.setVisibility(View.INVISIBLE);\n\t\t}\n\n\t\t// If we're not fully connected to both Odin and the Bioharness, show the connection dialog.\n\t\tif (status == null || status.getBioharnessConnectivityStatus() != BHConnectivityStatus.CONNECTED) {\n\t\t\t//\tTODO: REMOVE ODIN CONNECTION\n//\t\t\t\t|| status.getOdinConnectivityStatus() != EndpointConnectionStatus.CONNECTED) {\n\n\n\t\t\tif (this.connectionDialog == null) {\n\t\t\t\tthis.connectionDialog = new ConnectionProgressDialogFragment();\n\n\t\t\t\tif (activityVisible) {\n\t\t\t\t\tthis.connectionDialog.show(this.getSupportFragmentManager(), \"ConnectionDialog\");\n\t\t\t\t} else {\n\t\t\t\t\tdismissConnectionDialogOnResume = false;\n\t\t\t\t\tshowConnectionDialogOnResume = true;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (status != null) {\n\t\t\t\tthis.connectionDialog.setBioharnessConnectionStatus(status.getBioharnessConnectivityStatus());\n\t\t\t\t//\tTODO: REMOVE ODIN CONNECTION\n//\t\t\t\tthis.connectionDialog.setOdinConnectionStatus(status.getOdinConnectivityStatus());\n\t\t\t} else {\n\t\t\t\tthis.connectionDialog.setBioharnessConnectionStatus(BHConnectivityStatus.DISCONNECTED);\n\t\t\t\tthis.connectionDialog.setOdinConnectionStatus(EndpointConnectionStatus.DISCONNECTED);\n\t\t\t}\n\n\t\t}\n\n\t\t// Otherwise, hide it.\n\t\telse {\n\t\t\tif (this.connectionDialog != null) {\n\t\t\t\tif (activityVisible) {\n\t\t\t\t\tthis.connectionDialog.dismiss();\n\t\t\t\t\tthis.connectionDialog = null;\n\t\t\t\t} else {\n\t\t\t\t\tdismissConnectionDialogOnResume = true;\n\t\t\t\t\tshowConnectionDialogOnResume = false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// If the timer should be enabled, but isn't, enable it now. Also enable navigation\n\t\tif (shouldEnableTimer && timerUpdateThread == null) {\n\t\t\ttimerUpdateThread = new Thread(timerUpdateTask);\n\t\t\ttimerUpdateThread.setDaemon(true);\n\t\t\ttimerUpdateThread.start();\n\t\t\tisPaused = false;\n\t\t\tWorkoutService.setIsPaused(false);\n\t\t}\n\n\t\t// If the timer should be disabled, but is enabled, disable it now.\n\t\telse if (!shouldEnableTimer && timerUpdateThread != null) {\n\t\t\ttimerUpdateThread.interrupt();\n\t\t\ttry {\n\t\t\t\ttimerUpdateThread.join();\n\t\t\t} catch (InterruptedException e) {\n\t\t\t}\n\t\t\ttimerUpdateThread = null;\n\t\t\tisPaused = true;\n\t\t\tWorkoutService.setIsPaused(true);\n\t\t}\n\n\t}",
"public void performRequestCurrentDump()\n {\n super.performRequestCurrentDump();\n switchScreen();\n }",
"public void setStatus(String status) { this.status = status; }",
"public void notifyStateChange(String str) {\n out.println(str); \n }",
"private void setLightStatus() {\n if (mCmd.equals(MSG_ON)) {\n setLighIsOn(true);\n } else {\n setLighIsOn(false);\n }\n }",
"public void printStatus() {\n printBranches();\n printAllStages();\n printModified();\n printUntracked();\n }",
"public void runSecurityDisplay(Scanner scan, PrintWriter pout)\n {\n if(sout != null)\n {\n sendMessage(\"another\", pout);\n return;\n }\n sout = pout;\n sout.println(\"successful connection!\");\n \n while(theSocket.isConnected())\n {\n if(theSocket.isClosed())\n break;\n try \n {\n Thread.sleep(2000);\n } \n catch (InterruptedException e) \n {\n System.out.println(e);\n }\n sendStatus();\n }\n\n sout = null;\n displayConnections.put(\"security\", null); \n }",
"@Override\r\n public void display(PrintWriter out) {\r\n if (this.nrBasic > 0) {\r\n out.println(\"Basic\");\r\n } else {\r\n super.display(out);\r\n }\r\n }",
"public void updateStatusPanel() {\n\t\ttable.redraw();\n\t\tcursor.redraw();\n\t\tint rowIndex = table.getSelectionIndex();\n\t\tint columnIndex = cursor.getColumn();\n\n\t\tif (rowIndex < 0 || columnIndex < 0 || columnIndex >= HexEditorConstants.TABLE_NUM_COLUMNS) {\n\t\t\tHexManager.log(\"updateStatusPanel(): incorrect cursor coordinates!\"); //$NON-NLS-1$\n\t\t\treturn;\n\t\t}\n\n\t\tString cellData = table.getTableItem(rowIndex).getText(columnIndex);\n\n\t\tif (columnIndex < 1 || columnIndex > HexEditorConstants.TABLE_NUM_DATA_COLUMNS || cellData.length() == 0 || cellData.equals(HexEditorConstants.TABLE_EMPTY_CELL)) {\n\t\t\t//\n\t\t\t// Cursor is out of data cells - nothing to display\n\t\t\t//\n\t\t\tstatusOffset.setText(\"\"); //$NON-NLS-1$\n\t\t\tstatusValue.setText(\"\"); //$NON-NLS-1$\n\t\t} // if\n\t\telse {\n\t\t\t//\n\t\t\t// Cursor is above the data cell - update offset panel\n\t\t\t//\n\t\t\tHexTablePointer p = new HexTablePointer(rowIndex, columnIndex - 1);\n\t\t\tint offset = p.getOffset();\n\t\t\tint tableSize = table.getBufferSize();\n\t\t\tint ratio = (tableSize > 1) ? (100 * offset / (tableSize - 1)) : 100;\n\t\t\tstatusOffset.setText(Messages.HexEditorControl_54 + HexUtils.zeroPadding(Integer.toHexString(offset).toUpperCase(), 8) + Messages.HexEditorControl_55 + HexUtils.zeroPadding(Integer.toHexString(tableSize - 1).toUpperCase(), 8) + \"h (\" + ratio + \"%) \"); //$NON-NLS-3$ //$NON-NLS-4$\n\n\t\t\t//\n\t\t\t// Update value panel\n\t\t\t//\n\t\t\tint number = Integer.parseInt(cellData, 16);\n\n\t\t\tString binString = Integer.toBinaryString(number);\n\t\t\tstatusValue.setText(Messages.HexEditorControl_58 + cellData + Messages.HexEditorControl_59 + number + Messages.HexEditorControl_60 + Integer.toOctalString(number) + Messages.HexEditorControl_61 + (\"00000000\".substring(binString.length()) + binString) + Messages.HexEditorControl_63); //$NON-NLS-5$\n\t\t} // else\n\n\t\t//\n\t\t// Update table/file size\n\t\t//\n\t\tstatusFileSize.setText(Messages.HexEditorControl_64 + fileSizeFormat.format(table.getBufferSize()) + Messages.HexEditorControl_65);\n\t}",
"public void setStatus(Boolean s){ status = s;}",
"public void playBoardInTextMode() {\n System.out.println(board.makeTextModeDisplay());\n while (true) {\n try {\n int sleepTime = (int)(board.timeStep*1000);\n Thread.sleep(sleepTime);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n this.readMessages();\n List<String> messagesToSend = board.updateState();\n System.out.println(messagesToSend);\n this.sendMessages(messagesToSend);\n System.out.println(board.makeTextModeDisplay());\n }\n }"
] | [
"0.65059763",
"0.63177246",
"0.6299405",
"0.61880875",
"0.6149791",
"0.60362726",
"0.60298276",
"0.58570266",
"0.5825224",
"0.5807538",
"0.5783068",
"0.5747635",
"0.5737283",
"0.57090324",
"0.5630827",
"0.560804",
"0.55965835",
"0.55945724",
"0.55834013",
"0.55822915",
"0.55606675",
"0.55567014",
"0.5553359",
"0.5534981",
"0.553101",
"0.54926676",
"0.54850394",
"0.54841566",
"0.547532",
"0.5470267",
"0.5462451",
"0.5429289",
"0.54131657",
"0.5407245",
"0.54062396",
"0.54052824",
"0.54043615",
"0.53807616",
"0.53788954",
"0.5371375",
"0.53525394",
"0.53478533",
"0.53459376",
"0.5342009",
"0.53253067",
"0.532511",
"0.53182536",
"0.5316988",
"0.53155774",
"0.53068966",
"0.5303597",
"0.5290964",
"0.528624",
"0.5282019",
"0.5279374",
"0.52778494",
"0.52775025",
"0.52740735",
"0.5262008",
"0.52614284",
"0.5248474",
"0.5246171",
"0.52447134",
"0.5239653",
"0.5237667",
"0.52327704",
"0.52315146",
"0.52293557",
"0.5220234",
"0.5208711",
"0.5204842",
"0.520241",
"0.51980376",
"0.51972944",
"0.51971024",
"0.5191847",
"0.5189631",
"0.51878434",
"0.5184031",
"0.5184031",
"0.51816356",
"0.5180856",
"0.5178659",
"0.51735747",
"0.517238",
"0.51603043",
"0.5153925",
"0.5152674",
"0.51506877",
"0.51506346",
"0.5148198",
"0.51446563",
"0.5140317",
"0.51374996",
"0.5136245",
"0.51327425",
"0.5122344",
"0.51182145",
"0.5117004",
"0.51166433"
] | 0.66778946 | 0 |
note that it can be relatively expensive to construct the string argument to this function, even if it's not printed. For higher debug levels (3 and 4) you probably want to make sure this function is never called, not just that it doesn't do anything. so wrap the call in an actual if statement. | public void print_error( String text, int level ) {
if ( get_debug_level() >= level ) {
_platform_io.print_error( text );
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private static void printDebug(String s)\n {\n }",
"private void debug(String str) {\n }",
"@Override\r\n\t\t\tpublic void debug(String arg) {\n\t\t\t\t\r\n\t\t\t}",
"public void logDebug(String str) {\n }",
"private static void debug(@Nullable String s) {\n LOG.debug(s);\n }",
"public void debug(Object message)\n/* */ {\n/* 118 */ if (message != null) {\n/* 119 */ getLogger().debug(String.valueOf(message));\n/* */ }\n/* */ }",
"@SuppressWarnings(\"unused\")\n\tprivate static void printDebug(String p) {\n\t\tif (DEBUG) {\n\t\t\tSystem.out.println(PREFIX + p);\n\t\t}\n\t}",
"public static java.lang.String getDebugString(int r10, android.location.Location r11) {\n /*\n r0 = \"\";\n r2 = debugLock;\t Catch:{ Exception -> 0x00d9 }\n r2.lock();\t Catch:{ Exception -> 0x00d9 }\n r2 = java.util.Locale.US;\t Catch:{ Exception -> 0x00d9 }\n r3 = \"attempt-%d-unsentFixes-%d-\";\n r4 = 2;\n r4 = new java.lang.Object[r4];\t Catch:{ Exception -> 0x00d9 }\n r5 = 0;\n r6 = java.lang.Integer.valueOf(r10);\t Catch:{ Exception -> 0x00d9 }\n r4[r5] = r6;\t Catch:{ Exception -> 0x00d9 }\n r5 = 1;\n r6 = droppedLocations;\t Catch:{ Exception -> 0x00d9 }\n r6 = r6.size();\t Catch:{ Exception -> 0x00d9 }\n r6 = java.lang.Integer.valueOf(r6);\t Catch:{ Exception -> 0x00d9 }\n r4[r5] = r6;\t Catch:{ Exception -> 0x00d9 }\n r0 = java.lang.String.format(r2, r3, r4);\t Catch:{ Exception -> 0x00d9 }\n r2 = droppedLocations;\t Catch:{ Exception -> 0x00d9 }\n r2 = r2.isEmpty();\t Catch:{ Exception -> 0x00d9 }\n if (r2 != 0) goto L_0x005f;\n L_0x0030:\n r2 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x00d9 }\n r2.<init>();\t Catch:{ Exception -> 0x00d9 }\n r2 = r2.append(r0);\t Catch:{ Exception -> 0x00d9 }\n r3 = \"-dropped \";\n r2 = r2.append(r3);\t Catch:{ Exception -> 0x00d9 }\n r3 = droppedLocations;\t Catch:{ Exception -> 0x00d9 }\n r3 = r3.size();\t Catch:{ Exception -> 0x00d9 }\n r2 = r2.append(r3);\t Catch:{ Exception -> 0x00d9 }\n r3 = \" Locations because did not pass the filters, locations dropped: \";\n r2 = r2.append(r3);\t Catch:{ Exception -> 0x00d9 }\n r3 = droppedLocations;\t Catch:{ Exception -> 0x00d9 }\n r3 = getLocationLog(r3);\t Catch:{ Exception -> 0x00d9 }\n r2 = r2.append(r3);\t Catch:{ Exception -> 0x00d9 }\n r0 = r2.toString();\t Catch:{ Exception -> 0x00d9 }\n L_0x005f:\n if (r11 == 0) goto L_0x00cf;\n L_0x0061:\n r2 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x00d9 }\n r2.<init>();\t Catch:{ Exception -> 0x00d9 }\n r3 = r2.append(r0);\t Catch:{ Exception -> 0x00d9 }\n r2 = com.tado.android.location.LocationUtil.isMockLocation(r11);\t Catch:{ Exception -> 0x00d9 }\n if (r2 == 0) goto L_0x00d5;\n L_0x0070:\n r2 = \"MOCK\";\n L_0x0073:\n r2 = r3.append(r2);\t Catch:{ Exception -> 0x00d9 }\n r0 = r2.toString();\t Catch:{ Exception -> 0x00d9 }\n r2 = r11.getExtras();\t Catch:{ Exception -> 0x00d9 }\n if (r2 == 0) goto L_0x00cf;\n L_0x0081:\n r2 = r11.getExtras();\t Catch:{ Exception -> 0x00d9 }\n r3 = \"overriden\";\n r2 = r2.containsKey(r3);\t Catch:{ Exception -> 0x00d9 }\n if (r2 == 0) goto L_0x00cf;\n L_0x008e:\n r2 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x00d9 }\n r2.<init>();\t Catch:{ Exception -> 0x00d9 }\n r2 = r2.append(r0);\t Catch:{ Exception -> 0x00d9 }\n r3 = java.util.Locale.US;\t Catch:{ Exception -> 0x00d9 }\n r4 = \" real-loc: %f,%f\";\n r5 = 2;\n r5 = new java.lang.Object[r5];\t Catch:{ Exception -> 0x00d9 }\n r6 = 0;\n r7 = r11.getExtras();\t Catch:{ Exception -> 0x00d9 }\n r8 = \"realLat\";\n r8 = r7.getDouble(r8);\t Catch:{ Exception -> 0x00d9 }\n r7 = java.lang.Double.valueOf(r8);\t Catch:{ Exception -> 0x00d9 }\n r5[r6] = r7;\t Catch:{ Exception -> 0x00d9 }\n r6 = 1;\n r7 = r11.getExtras();\t Catch:{ Exception -> 0x00d9 }\n r8 = \"realLon\";\n r8 = r7.getDouble(r8);\t Catch:{ Exception -> 0x00d9 }\n r7 = java.lang.Double.valueOf(r8);\t Catch:{ Exception -> 0x00d9 }\n r5[r6] = r7;\t Catch:{ Exception -> 0x00d9 }\n r3 = java.lang.String.format(r3, r4, r5);\t Catch:{ Exception -> 0x00d9 }\n r2 = r2.append(r3);\t Catch:{ Exception -> 0x00d9 }\n r0 = r2.toString();\t Catch:{ Exception -> 0x00d9 }\n L_0x00cf:\n r2 = debugLock;\n r2.unlock();\n L_0x00d4:\n return r0;\n L_0x00d5:\n r2 = \"\";\n goto L_0x0073;\n L_0x00d9:\n r1 = move-exception;\n r2 = com.tado.android.utils.Snitcher.start();\t Catch:{ all -> 0x00eb }\n r2 = r2.toLogger();\t Catch:{ all -> 0x00eb }\n r2.logException(r1);\t Catch:{ all -> 0x00eb }\n r2 = debugLock;\n r2.unlock();\n goto L_0x00d4;\n L_0x00eb:\n r2 = move-exception;\n r3 = debugLock;\n r3.unlock();\n throw r2;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.tado.android.utils.DebugUtil.getDebugString(int, android.location.Location):java.lang.String\");\n }",
"private void debug(String s) {\r\n\t\tif (debug)\r\n\t\t\tSystem.out.println(s);\r\n\t}",
"final void out (String msg) { if (m_debugMode) { Logger.println (msg); } }",
"private static void logd(java.lang.String r1) {\n /*\n // Can't load method instructions: Load method exception: bogus opcode: 00e9 in method: com.mediatek.internal.telephony.worldphone.WorldPhoneOp01.logd(java.lang.String):void, dex: \n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.mediatek.internal.telephony.worldphone.WorldPhoneOp01.logd(java.lang.String):void\");\n }",
"protected abstract void debug(String msg);",
"public boolean supportsDebugArgument();",
"void debug(String a, String b) {\n\t\t}",
"static void m14940f(String str, String str2, Throwable th) {\n if (m14929b() > C3205z0.DEBUG.mo12550d()) {\n StringBuilder sb = new StringBuilder();\n sb.append(\"CleverTap:\");\n sb.append(str);\n sb.toString();\n }\n }",
"public static final void debug(@org.jetbrains.annotations.NotNull org.jetbrains.anko.AnkoLogger r4, @org.jetbrains.annotations.Nullable java.lang.Object r5, @org.jetbrains.annotations.Nullable java.lang.Throwable r6) {\n /*\n r3 = \"$receiver\";\n kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull(r4, r3);\n r0 = 3;\n r2 = r4.getLoggerTag();\n r3 = android.util.Log.isLoggable(r2, r0);\n if (r3 == 0) goto L_0x0025;\n L_0x0011:\n if (r6 == 0) goto L_0x002a;\n L_0x0013:\n if (r5 == 0) goto L_0x0026;\n L_0x0015:\n r3 = r5.toString();\n if (r3 == 0) goto L_0x0026;\n L_0x001b:\n r6 = (java.lang.Throwable) r6;\n r3 = (java.lang.String) r3;\n r1 = r2;\n r1 = (java.lang.String) r1;\n android.util.Log.d(r1, r3, r6);\n L_0x0025:\n return;\n L_0x0026:\n r3 = \"null\";\n goto L_0x001b;\n L_0x002a:\n if (r5 == 0) goto L_0x003b;\n L_0x002c:\n r3 = r5.toString();\n if (r3 == 0) goto L_0x003b;\n L_0x0032:\n r3 = (java.lang.String) r3;\n r1 = r2;\n r1 = (java.lang.String) r1;\n android.util.Log.d(r1, r3);\n goto L_0x0025;\n L_0x003b:\n r3 = \"null\";\n goto L_0x0032;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: org.jetbrains.anko.Logging.debug(org.jetbrains.anko.AnkoLogger, java.lang.Object, java.lang.Throwable):void\");\n }",
"@Override\n\tpublic String toStringDebug() {\n\t\treturn null;\n\t}",
"final void out (String msg1, String msg2) { if (m_debugMode) { Logger.print (msg1); Logger.println (msg2); } }",
"public java.lang.String toDebugString () { throw new RuntimeException(); }",
"@Override\n public void printDebug(String string) {\n if(allActive && active)\n System.out.println(SC + string + R);\n }",
"private static boolean m1034a(int i, String str, Object... objArr) {\n if (!f1188c) {\n return false;\n }\n if (str == null) {\n str = \"null\";\n } else if (!(objArr == null || objArr.length == 0)) {\n str = String.format(Locale.US, str, objArr);\n }\n switch (i) {\n case 0:\n Log.i(f1187b, str);\n return true;\n case 1:\n Log.d(f1187b, str);\n return true;\n case 2:\n Log.w(f1187b, str);\n return true;\n case 3:\n Log.e(f1187b, str);\n return true;\n case 5:\n Log.i(f1186a, str);\n return true;\n default:\n return false;\n }\n }",
"public boolean isDebugEnabled()\n/* */ {\n/* 250 */ return getLogger().isDebugEnabled();\n/* */ }",
"protected void debug(String string) {\n\t\tif (DEBUGMODE)\n\t\t\tSystem.out.println(string);\n\t}",
"@Override\n\tpublic void debug(String message, Object p0) {\n\n\t}",
"static void m14939f(String str, String str2) {\n if (m14929b() > C3205z0.DEBUG.mo12550d()) {\n StringBuilder sb = new StringBuilder();\n sb.append(\"CleverTap:\");\n sb.append(str);\n sb.toString();\n }\n }",
"private static void debug(Context context, String p){\n\t\tToast.makeText(context, p, Toast.LENGTH_SHORT).show();\n\t}",
"protected String getDebugParameter() {\n return debug ? \"/debug\" : null;\n }",
"boolean isDebug();",
"boolean isDebug();",
"public static void debug(String string, Object... val) {\n\n }",
"public static void debug(String arg0) {\n MDC.put(classNameProp, \"\");\n debugLogger.debug(arg0);\n }",
"public static void debugInfo() { throw Extensions.todo(); }",
"public void printWarning(String arg0) {\n\n }",
"@Test\n\tpublic void logFormattedStringWithSingleObject() {\n\t\tlogger.logf(org.jboss.logging.Logger.Level.DEBUG, \"Hello %s!\", \"World\");\n\n\t\tif (debugEnabled) {\n\t\t\tverify(provider).log(eq(2), isNull(), eq(Level.DEBUG), same(null), any(PrintfStyleFormatter.class), eq(\"Hello %s!\"),\n\t\t\t\t\teq(\"World\"));\n\t\t} else {\n\t\t\tverify(provider, never()).log(anyInt(), anyString(), any(), any(), any(), any(), any());\n\t\t}\n\n\t\tlogger.logf(org.jboss.logging.Logger.Level.WARN, \"Hello %s!\", \"World\");\n\n\t\tif (warnEnabled) {\n\t\t\tverify(provider).log(eq(2), isNull(), eq(Level.WARN), same(null), any(PrintfStyleFormatter.class), eq(\"Hello %s!\"),\n\t\t\t\t\teq(\"World\"));\n\t\t} else {\n\t\t\tverify(provider, never()).log(anyInt(), anyString(), any(), any(), any(), any(), any());\n\t\t}\n\t}",
"String d(String paramString, int paramInt)\r\n/* 613: */ {\r\n/* 614:609 */ int i1 = e(paramString, paramInt);\r\n/* 615:610 */ if (paramString.length() <= i1) {\r\n/* 616:611 */ return paramString;\r\n/* 617: */ }\r\n/* 618:614 */ String str1 = paramString.substring(0, i1);\r\n/* 619: */ \r\n/* 620:616 */ int i2 = paramString.charAt(i1);\r\n/* 621:617 */ int i3 = (i2 == 32) || (i2 == 10) ? 1 : 0;\r\n/* 622:618 */ String str2 = b(str1) + paramString.substring(i1 + (i3 != 0 ? 1 : 0));\r\n/* 623: */ \r\n/* 624:620 */ return str1 + \"\\n\" + d(str2, paramInt);\r\n/* 625: */ }",
"public abstract boolean shouldPrintWorkerString();",
"public void debug(String msg);",
"@Test\n\tpublic void logFormattedStringWithTwoObjects() {\n\t\tlogger.logf(org.jboss.logging.Logger.Level.DEBUG, \"%s = %d\", \"magic\", 42);\n\n\t\tif (debugEnabled) {\n\t\t\tverify(provider).log(eq(2), isNull(), eq(Level.DEBUG), same(null), any(PrintfStyleFormatter.class), eq(\"%s = %d\"), eq(\"magic\"),\n\t\t\t\t\teq(42));\n\t\t} else {\n\t\t\tverify(provider, never()).log(anyInt(), anyString(), any(), any(), any(), any(), any());\n\t\t}\n\n\t\tlogger.logf(org.jboss.logging.Logger.Level.WARN, \"%s = %d\", \"magic\", 42);\n\n\t\tif (warnEnabled) {\n\t\t\tverify(provider).log(eq(2), isNull(), eq(Level.WARN), same(null), any(PrintfStyleFormatter.class), eq(\"%s = %d\"), eq(\"magic\"),\n\t\t\t\t\teq(42));\n\t\t} else {\n\t\t\tverify(provider, never()).log(anyInt(), anyString(), any(), any(), any(), any(), any());\n\t\t}\n\t}",
"public static final void wtf(@org.jetbrains.annotations.NotNull org.jetbrains.anko.AnkoLogger r2, @org.jetbrains.annotations.Nullable java.lang.Object r3, @org.jetbrains.annotations.Nullable java.lang.Throwable r4) {\n /*\n r0 = \"$receiver\";\n kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull(r2, r0);\n if (r4 == 0) goto L_0x001c;\n L_0x0008:\n r1 = r2.getLoggerTag();\n if (r3 == 0) goto L_0x0018;\n L_0x000e:\n r0 = r3.toString();\n if (r0 == 0) goto L_0x0018;\n L_0x0014:\n android.util.Log.wtf(r1, r0, r4);\n L_0x0017:\n return;\n L_0x0018:\n r0 = \"null\";\n goto L_0x0014;\n L_0x001c:\n r1 = r2.getLoggerTag();\n if (r3 == 0) goto L_0x002c;\n L_0x0022:\n r0 = r3.toString();\n if (r0 == 0) goto L_0x002c;\n L_0x0028:\n android.util.Log.wtf(r1, r0);\n goto L_0x0017;\n L_0x002c:\n r0 = \"null\";\n goto L_0x0028;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: org.jetbrains.anko.Logging.wtf(org.jetbrains.anko.AnkoLogger, java.lang.Object, java.lang.Throwable):void\");\n }",
"@Test\n public void testCheckNullWithLogging() {\n Helper.checkNullWithLogging(\"obj\", \"obj\", \"method\", LogManager.getLog());\n }",
"void printLog(String str)\n { printLog(str,Log.LEVEL_HIGH);\n }",
"public boolean isDebug();",
"private void debug(final String msg) {\n \t\tif (debug) System.out.println(msg);\n \t}",
"private void printLog(String str)\n { printLog(str,Log.LEVEL_HIGH);\n }",
"protected void dbgOut(String text_out)\n {\n if (debugOn)\n System.out.println(text_out);\n }",
"private static void log_d( String msg ) {\n\t if (D) Log.d( TAG, TAG_SUB + \" \" + msg );\n}",
"@Override\r\n\tpublic StringBuffer showMe(String data) {\n\t\tlogger.trace(data);\r\n\t\t//int i = 1/0;\r\n\t\treturn new StringBuffer(data);\r\n\t}",
"private void myPrint(String x) {\n if (printOn) {\n System.out.println(x);\n }\n }",
"static void call_without_condition(String passed){\n\t\tcomplete_call_req(passed.substring(5));\n\t}",
"private void debugMessage(String result)\n\t{\n\t\tmain.addDebugMessage(result);\n\t}",
"static void m14932d(String str, String str2, Throwable th) {\n if (m14929b() > C3205z0.INFO.mo12550d()) {\n StringBuilder sb = new StringBuilder();\n sb.append(\"CleverTap:\");\n sb.append(str);\n sb.toString();\n }\n }",
"@Override\n\tpublic void debug(Supplier<?> msgSupplier) {\n\n\t}",
"public static void debug(Object arg0) {\n\n MDC.put(classNameProp, \"\");\n debugLogger.debug(\"{}\", arg0);\n }",
"@SuppressWarnings({\"UNUSED_SYMBOL\"})\r\n private void plog(String m) {\n }",
"@Override\n\tpublic void debug(MessageSupplier msgSupplier) {\n\n\t}",
"private static void debug(String s) {\n if (System.getProperty(\"javafind.debug\") != null)\n System.out.println(\"debug in GnuNativeFind: \" + s);\n }",
"public void debug(Object message, Throwable t)\n/* */ {\n/* 132 */ if (message != null) {\n/* 133 */ getLogger().debug(String.valueOf(message), t);\n/* */ }\n/* */ }",
"@Override\r\n\tpublic StringBuffer callMe(String data) {\n\t\tlogger.trace(data);\r\n\t\treturn new StringBuffer(data);\r\n\t}",
"private void debug(String post) {\n if (GameLauncher.isDebugging()) {\n System.out.println(post);\n }\n }",
"@Override\n\tpublic void debug(Marker marker, String message, Object p0) {\n\n\t}",
"private final void m31778a(String str, boolean z) {\n boolean z2;\n if (!TextUtils.isEmpty(str)) {\n if (z) {\n try {\n if (this.f23849b == null) {\n if (!\"com.google.android.gms\".equals(this.f23850c) && !C9951o.m31001a(this.f23848a.mo25895b(), Binder.getCallingUid())) {\n if (!C9923j.m30933a(this.f23848a.mo25895b()).mo25450a(Binder.getCallingUid())) {\n z2 = false;\n this.f23849b = Boolean.valueOf(z2);\n }\n }\n z2 = true;\n this.f23849b = Boolean.valueOf(z2);\n }\n if (this.f23849b.booleanValue()) {\n return;\n }\n } catch (SecurityException e) {\n this.f23848a.mo25898e().mo25874t().mo25909a(\"Measurement Service called with invalid calling package. appId\", C10099k3.m31423a(str));\n throw e;\n }\n }\n if (this.f23850c == null && C9832i.m30627a(this.f23848a.mo25895b(), Binder.getCallingUid(), str)) {\n this.f23850c = str;\n }\n if (!str.equals(this.f23850c)) {\n throw new SecurityException(String.format(\"Unknown calling package name '%s'.\", new Object[]{str}));\n }\n return;\n }\n String str2 = \"Measurement Service called without app package\";\n this.f23848a.mo25898e().mo25874t().mo25908a(str2);\n throw new SecurityException(str2);\n }",
"public void debug() {\n\n }",
"@Override\n\tpublic void debug(String message, Supplier<?>... paramSuppliers) {\n\n\t}",
"@Override\n\tpublic void debug(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5, Object p6, Object p7, Object p8, Object p9) {\n\n\t}",
"public abstract void logd(String str);",
"public String a(String paramString, int paramInt, boolean paramBoolean)\r\n/* 517: */ {\r\n/* 518:516 */ StringBuilder localStringBuilder = new StringBuilder();\r\n/* 519:517 */ int i1 = 0;\r\n/* 520:518 */ int i2 = paramBoolean ? paramString.length() - 1 : 0;\r\n/* 521:519 */ int i3 = paramBoolean ? -1 : 1;\r\n/* 522:520 */ int i4 = 0;\r\n/* 523:521 */ int i5 = 0;\r\n/* 524:523 */ for (int i6 = i2; (i6 >= 0) && (i6 < paramString.length()) && (i1 < paramInt); i6 += i3)\r\n/* 525: */ {\r\n/* 526:524 */ char c1 = paramString.charAt(i6);\r\n/* 527:525 */ int i7 = a(c1);\r\n/* 528:527 */ if (i4 != 0)\r\n/* 529: */ {\r\n/* 530:528 */ i4 = 0;\r\n/* 531:530 */ if ((c1 == 'l') || (c1 == 'L')) {\r\n/* 532:531 */ i5 = 1;\r\n/* 533:532 */ } else if ((c1 == 'r') || (c1 == 'R')) {\r\n/* 534:533 */ i5 = 0;\r\n/* 535: */ }\r\n/* 536: */ }\r\n/* 537:535 */ else if (i7 < 0)\r\n/* 538: */ {\r\n/* 539:536 */ i4 = 1;\r\n/* 540: */ }\r\n/* 541: */ else\r\n/* 542: */ {\r\n/* 543:538 */ i1 += i7;\r\n/* 544:539 */ if (i5 != 0) {\r\n/* 545:540 */ i1++;\r\n/* 546: */ }\r\n/* 547: */ }\r\n/* 548:544 */ if (i1 > paramInt) {\r\n/* 549: */ break;\r\n/* 550: */ }\r\n/* 551:548 */ if (paramBoolean) {\r\n/* 552:549 */ localStringBuilder.insert(0, c1);\r\n/* 553: */ } else {\r\n/* 554:551 */ localStringBuilder.append(c1);\r\n/* 555: */ }\r\n/* 556: */ }\r\n/* 557:555 */ return localStringBuilder.toString();\r\n/* 558: */ }",
"public String call()\r\n/* 9: */ {\r\n/* 10:277 */ if (this.a == 0) {\r\n/* 11:278 */ return \"MISC_TEXTURE\";\r\n/* 12: */ }\r\n/* 13:279 */ if (this.a == 1) {\r\n/* 14:280 */ return \"TERRAIN_TEXTURE\";\r\n/* 15: */ }\r\n/* 16:281 */ if (this.a == 3) {\r\n/* 17:282 */ return \"ENTITY_PARTICLE_TEXTURE\";\r\n/* 18: */ }\r\n/* 19:284 */ return \"Unknown - \" + this.a;\r\n/* 20: */ }",
"private void log_d( String msg ) {\n\t if (D) Log.d( TAG, TAG_SUB + \" \" + msg );\n}",
"public static final void verbose(@org.jetbrains.annotations.NotNull org.jetbrains.anko.AnkoLogger r4, @org.jetbrains.annotations.Nullable java.lang.Object r5, @org.jetbrains.annotations.Nullable java.lang.Throwable r6) {\n /*\n r3 = \"$receiver\";\n kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull(r4, r3);\n r0 = 2;\n r2 = r4.getLoggerTag();\n r3 = android.util.Log.isLoggable(r2, r0);\n if (r3 == 0) goto L_0x0025;\n L_0x0011:\n if (r6 == 0) goto L_0x002a;\n L_0x0013:\n if (r5 == 0) goto L_0x0026;\n L_0x0015:\n r3 = r5.toString();\n if (r3 == 0) goto L_0x0026;\n L_0x001b:\n r6 = (java.lang.Throwable) r6;\n r3 = (java.lang.String) r3;\n r1 = r2;\n r1 = (java.lang.String) r1;\n android.util.Log.v(r1, r3, r6);\n L_0x0025:\n return;\n L_0x0026:\n r3 = \"null\";\n goto L_0x001b;\n L_0x002a:\n if (r5 == 0) goto L_0x003b;\n L_0x002c:\n r3 = r5.toString();\n if (r3 == 0) goto L_0x003b;\n L_0x0032:\n r3 = (java.lang.String) r3;\n r1 = r2;\n r1 = (java.lang.String) r1;\n android.util.Log.v(r1, r3);\n goto L_0x0025;\n L_0x003b:\n r3 = \"null\";\n goto L_0x0032;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: org.jetbrains.anko.Logging.verbose(org.jetbrains.anko.AnkoLogger, java.lang.Object, java.lang.Throwable):void\");\n }",
"private DebugMessage() {\n initFields();\n }",
"private static String asVerboseString(Object obj) {\n String name = obj.getClass().getSimpleName();\n String toString = String.valueOf(obj);\n if (toString.startsWith(name)) {\n return toString;\n } else {\n return String.format(\"%s:%s\", name, toString);\n }\n }",
"public static final void debug(@org.jetbrains.annotations.NotNull org.jetbrains.anko.AnkoLogger r2, @org.jetbrains.annotations.NotNull kotlin.jvm.functions.Function0<? extends java.lang.Object> r3) {\n /*\n r1 = \"$receiver\";\n kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull(r2, r1);\n r1 = \"message\";\n kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull(r3, r1);\n r0 = r2.getLoggerTag();\n r1 = 3;\n r1 = android.util.Log.isLoggable(r0, r1);\n if (r1 == 0) goto L_0x0026;\n L_0x0017:\n r1 = r3.invoke();\n if (r1 == 0) goto L_0x0027;\n L_0x001d:\n r1 = r1.toString();\n if (r1 == 0) goto L_0x0027;\n L_0x0023:\n android.util.Log.d(r0, r1);\n L_0x0026:\n return;\n L_0x0027:\n r1 = \"null\";\n goto L_0x0023;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: org.jetbrains.anko.Logging.debug(org.jetbrains.anko.AnkoLogger, kotlin.jvm.functions.Function0):void\");\n }",
"private static void debugger(int d, int l, String msg){\n if(d >= l){\n System.out.println(msg);\n }\n }",
"public static void print(Object ... strings)\n {\n if(!info) return;\n for(Object s: strings) \n debugger.log.print((s != null) ? s.toString() : \"null\");\n }",
"@Override\n\tpublic void debug(String message, Object p0, Object p1, Object p2, Object p3, Object p4) {\n\n\t}",
"@Override\n\tpublic void debug(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5, Object p6, Object p7, Object p8) {\n\n\t}",
"public static final void info(@org.jetbrains.annotations.NotNull org.jetbrains.anko.AnkoLogger r4, @org.jetbrains.annotations.Nullable java.lang.Object r5, @org.jetbrains.annotations.Nullable java.lang.Throwable r6) {\n /*\n r3 = \"$receiver\";\n kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull(r4, r3);\n r0 = 4;\n r2 = r4.getLoggerTag();\n r3 = android.util.Log.isLoggable(r2, r0);\n if (r3 == 0) goto L_0x0025;\n L_0x0011:\n if (r6 == 0) goto L_0x002a;\n L_0x0013:\n if (r5 == 0) goto L_0x0026;\n L_0x0015:\n r3 = r5.toString();\n if (r3 == 0) goto L_0x0026;\n L_0x001b:\n r6 = (java.lang.Throwable) r6;\n r3 = (java.lang.String) r3;\n r1 = r2;\n r1 = (java.lang.String) r1;\n android.util.Log.i(r1, r3, r6);\n L_0x0025:\n return;\n L_0x0026:\n r3 = \"null\";\n goto L_0x001b;\n L_0x002a:\n if (r5 == 0) goto L_0x003b;\n L_0x002c:\n r3 = r5.toString();\n if (r3 == 0) goto L_0x003b;\n L_0x0032:\n r3 = (java.lang.String) r3;\n r1 = r2;\n r1 = (java.lang.String) r1;\n android.util.Log.i(r1, r3);\n goto L_0x0025;\n L_0x003b:\n r3 = \"null\";\n goto L_0x0032;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: org.jetbrains.anko.Logging.info(org.jetbrains.anko.AnkoLogger, java.lang.Object, java.lang.Throwable):void\");\n }",
"public static void dbg(String str) {\n\t\tString time = \"\";\r\n\t\tout(\"[MN] \"+Thread.currentThread().getId()+\" [\"+time+\"]> \"+str);\t\t\r\n\t}",
"public boolean isDebugEnabled();",
"private void buildToString(int access, boolean hasOffset) {\n MethodVisitor mv = cv.visitMethod(access, \"toString\", \n \"()Ljava/lang/String;\", null, null);\n if (mv == null) return;\n\n if ((access & ACC_ABSTRACT) != 0) {\n mv.visitEnd();\n return;\n }\n \n mv.visitCode();\n mv.visitVarInsn(ALOAD, 0);\n mv.visitMethodInsn(INVOKESTATIC, \"jtaint/OrigStringUtil\",\n \"toBaseString\", \n \"(L\" + className + \";)Ljava/lang/String;\");\n mv.visitInsn(ARETURN);\n mv.visitMaxs(1, 1);\n mv.visitEnd();\n }",
"@Test\n\tpublic void logFormattedStringWithThreeObject() {\n\t\tlogger.logf(org.jboss.logging.Logger.Level.DEBUG, \"%s, %s or %s\", \"one\", \"two\", \"three\");\n\n\t\tif (debugEnabled) {\n\t\t\tverify(provider).log(eq(2), isNull(), eq(Level.DEBUG), same(null), any(PrintfStyleFormatter.class), eq(\"%s, %s or %s\"),\n\t\t\t\t\teq(\"one\"), eq(\"two\"), eq(\"three\"));\n\t\t} else {\n\t\t\tverify(provider, never()).log(anyInt(), anyString(), any(), any(), any(), any(), any());\n\t\t}\n\n\t\tlogger.logf(org.jboss.logging.Logger.Level.WARN, \"%s, %s or %s\", \"one\", \"two\", \"three\");\n\n\t\tif (warnEnabled) {\n\t\t\tverify(provider).log(eq(2), isNull(), eq(Level.WARN), same(null), any(PrintfStyleFormatter.class), eq(\"%s, %s or %s\"),\n\t\t\t\t\teq(\"one\"), eq(\"two\"), eq(\"three\"));\n\t\t} else {\n\t\t\tverify(provider, never()).log(anyInt(), anyString(), any(), any(), any(), any(), any());\n\t\t}\n\t}",
"void debug(String msg)\n{\n if (yydebug)\n System.out.println(msg);\n}",
"void debug(String msg)\n{\n if (yydebug)\n System.out.println(msg);\n}",
"public void mo33174d(Object obj) {\n if (mo33175d()) {\n Log.w(this.f14707a, obj.toString());\n }\n }",
"@Override\n\tpublic void debug(String message, Object p0, Object p1, Object p2, Object p3) {\n\n\t}",
"private static void logDebug(String message, Object... arguments) {\n\t\tif (LOGGER.isDebugEnabled()) {\n\t\t\tLOGGER.debug(message, arguments);\n\t\t}\n\t}",
"private static void m9058c(String str) {\n StackTraceElement stackTraceElement = Thread.currentThread().getStackTrace()[3];\n String className = stackTraceElement.getClassName();\n String methodName = stackTraceElement.getMethodName();\n throw ((IllegalArgumentException) m9050a(new IllegalArgumentException(\"Parameter specified as non-null is null: method \" + className + \".\" + methodName + \", parameter \" + str)));\n }",
"@Override\n\tpublic void debug(String message, Object p0, Object p1) {\n\n\t}",
"public void trace(Object message)\n/* */ {\n/* 95 */ debug(message);\n/* */ }",
"protected static void debug(String istrMessage) {\n\t\tif (isDebugEnabled()) {\n\t\t\tSystem.out.println(Thread.currentThread().getName() + \": \"\n\t\t\t\t\t+ istrMessage);\n\t\t}\n\t}",
"@Override\n\tpublic void debug(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5, Object p6, Object p7) {\n\n\t}",
"public static void log(String str)\r\n\t{\n\t}",
"boolean isDebugEnabled();",
"public java.lang.String toString() {\n /*\n // Can't load method instructions: Load method exception: bogus opcode: 00e9 in method: android.telephony.SmsCbCmasInfo.toString():java.lang.String, dex: \n */\n throw new UnsupportedOperationException(\"Method not decompiled: android.telephony.SmsCbCmasInfo.toString():java.lang.String\");\n }",
"public void mo43852a(StringBuilder aLog) {\n }",
"public String toString() {\n/* 106 */ return \"m= \" + this.b + \", n= \" + this.a + \", skipMSBP= \" + this.c + \", data.length= \" + ((this.d != null) ? (\"\" + this.d.length) : \"(null)\");\n/* */ }",
"static void call_when_not_zero(String passed){\n\t\tif(!Z)\n\t\t\tcomplete_call_req(passed.substring(4));\n\t}",
"public void addToDebug(String callingObject, String string) {\n date = java.util.Calendar.getInstance().getTime();\n String currDebugLog = (date+\" : \" +callingObject+ \" : \" + string);\n debugLog.push(currDebugLog);\n System.out.println(currDebugLog);\n }",
"public String cnf2String() { return parentheses around non-and arguments\n //\n System.out.println( \" should not call \" );\n System.exit( 1 );\n return null;\n }",
"private void doIt() {\n\t\tlogger.debug(\"hellow this is the first time I use Logback\");\n\t\t\n\t}",
"@Override\n public boolean isDebugEnabled() {\n return innerLog.isDebugEnabled();\n }"
] | [
"0.6534124",
"0.64542717",
"0.62346745",
"0.61791253",
"0.6139408",
"0.60879326",
"0.5939424",
"0.5877455",
"0.5766069",
"0.5728181",
"0.57177883",
"0.5715586",
"0.56787497",
"0.567294",
"0.5627957",
"0.55980927",
"0.559014",
"0.5585328",
"0.5584512",
"0.5541258",
"0.55332875",
"0.5526459",
"0.5510939",
"0.5502723",
"0.5488491",
"0.5483931",
"0.5474692",
"0.54655695",
"0.54655695",
"0.5442769",
"0.5430519",
"0.54161775",
"0.5414417",
"0.538169",
"0.53812915",
"0.53736997",
"0.5369911",
"0.5354411",
"0.5350282",
"0.5341891",
"0.53319067",
"0.532493",
"0.53161544",
"0.530702",
"0.5306617",
"0.53052896",
"0.53028476",
"0.5301417",
"0.5301132",
"0.52986676",
"0.52986634",
"0.5282657",
"0.5282408",
"0.5278099",
"0.5264652",
"0.52617776",
"0.5258662",
"0.5257886",
"0.5255523",
"0.5254409",
"0.5243224",
"0.52420956",
"0.52420914",
"0.5229175",
"0.5221573",
"0.5221032",
"0.5212509",
"0.520991",
"0.5206775",
"0.5201432",
"0.5201166",
"0.51998353",
"0.51995957",
"0.5189014",
"0.51862115",
"0.51847297",
"0.5183995",
"0.5183015",
"0.51806486",
"0.51804787",
"0.5178527",
"0.5166089",
"0.5166089",
"0.51535213",
"0.5135523",
"0.5122779",
"0.5122642",
"0.5119446",
"0.5118828",
"0.5118095",
"0.51179487",
"0.51167893",
"0.51143456",
"0.5112242",
"0.5110687",
"0.5102182",
"0.51014954",
"0.50889945",
"0.5081462",
"0.5079655",
"0.5074754"
] | 0.0 | -1 |
wrap if necessary and print out what we've got so far | public void flush() {
if ( !printing_status() ) {
int sz = _platform_io.size_text( _current_word.toString() );
if ( _last_column + sz >= _wrap_column ) {
inc_line();
}
_last_column += sz;
_platform_io.print_text( _current_word.toString() );
_current_word.setLength( 0 );
} else {
_status_line.append( _current_word.toString() );
_current_word.setLength( 0 );
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void print() {\n\t\t// reorganize a wraparound queue and print\n\t\tfor (int i = 0; i < size; i++) {\n\t\t\tSystem.out.print(bq[(head + i) % bq.length] + \" \");\n\t\t}\n\t\tSystem.out.println(\"\\n\");\n\t}",
"private ResultHandler print() {\n\t\treturn null;\r\n\t}",
"public void wrap() {\n if (fSavedOut != null) {\n return;\n }\n fSavedOut = System.out;\n fSavedErr = System.err;\n final IOConsoleOutputStream out = fCurrent.newOutputStream();\n out.setColor(ConsoleUtils.getDefault().getBlack()); \n \n System.setOut(new PrintStream(out));\n final IOConsoleOutputStream err = fCurrent.newOutputStream();\n err.setColor(ConsoleUtils.getDefault().getRed()); \n \n System.setErr(new PrintStream(err));\n }",
"void printout() {\n\t\tprintstatus = idle;\n\t\tanyprinted = false;\n\t\tfor (printoldline = printnewline = 1;;) {\n\t\t\tif (printoldline > oldinfo.maxLine) {\n\t\t\t\tnewconsume();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (printnewline > newinfo.maxLine) {\n\t\t\t\toldconsume();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (newinfo.other[printnewline] < 0) {\n\t\t\t\tif (oldinfo.other[printoldline] < 0)\n\t\t\t\t\tshowchange();\n\t\t\t\telse\n\t\t\t\t\tshowinsert();\n\t\t\t} else if (oldinfo.other[printoldline] < 0)\n\t\t\t\tshowdelete();\n\t\t\telse if (blocklen[printoldline] < 0)\n\t\t\t\tskipold();\n\t\t\telse if (oldinfo.other[printoldline] == printnewline)\n\t\t\t\tshowsame();\n\t\t\telse\n\t\t\t\tshowmove();\n\t\t}\n\t\tif (anyprinted == true)\n\t\t\tprintln(\">>>> End of differences.\");\n\t\telse\n\t\t\tprintln(\">>>> Files are identical.\");\n\t}",
"private void wrap_long_words() {\n\t\tif ( printing_status() ) {\n\t\t\treturn;\n\t\t}\n\n\t\tString cur = _current_word.toString();\n\t\tif ( _platform_io.size_text( cur ) >= _wrap_column ) {\n\t\t\t// print out the first bit:\n\t\t\tString trim = cur;\n\t\t\twhile ( _platform_io.size_text( trim ) >= _wrap_column ) {\n\t\t\t\ttrim = trim.substring( 0, trim.length() - 1 );\n\t\t\t}\n\n\t\t\t_platform_io.print_text( trim );\n\t\t\tinc_line();\n\n\t\t\t// then truncate the rest:\n\t\t\tString tail = cur.substring( trim.length() );\n\n\t\t\tif ( _current_word.length() == _wrap_column ) // wrapped exactly?\n\t\t\t{\n\t\t\t\t_last_printed = '\\n';\n\t\t\t}\n\n\t\t\t_current_word = new StringBuffer( tail );\n\t\t}\n\t}",
"public void printResults() {\n\t System.out.println(\"BP\\tBR\\tBF\\tWP\\tWR\\tWF\");\n\t System.out.print(NF.format(boundaryPrecision) + \"\\t\" + NF.format(boundaryRecall) + \"\\t\" + NF.format(boundaryF1()) + \"\\t\");\n\t System.out.print(NF.format(chunkPrecision) + \"\\t\" + NF.format(chunkRecall) + \"\\t\" + NF.format(chunkF1()));\n\t System.out.println();\n }",
"private static StringBuilder printUtilResultLine(DSEIndividual ind,\r\n\t\t\tStringBuilder output) {\r\n\t\t\r\n\t\tObjectives obs = ind.getObjectives();\r\n\t\tif (obs instanceof DSEObjectives){\r\n\t\t\tDSEObjectives dseObj = ((DSEObjectives)obs);\r\n\t\t\tfor (Entry<Objective, Value<?>> o : dseObj) {\r\n\t\t\t\tif (dseObj.hasResultDecoratorFor(o.getKey())){\r\n\t\t\t\t\tResultDecoratorRepository results = dseObj.getResultDecoratorFor(o.getKey());\r\n\t\t\t\t\tList<UtilisationResult> utilisations = results.getUtilisationResults_ResultDecoratorRepository();\r\n\t\t\t\t\tPCMInstance pcm = Opt4JStarter.getProblem().getInitialInstance();\r\n\t\t\t\t\tList<ResourceContainer> containers = pcm.getResourceEnvironment().getResourceContainer_ResourceEnvironment();\r\n\t\t\t\t\tList<LinkingResource> links = pcm.getResourceEnvironment().getLinkingResources__ResourceEnvironment();\r\n\t\t\t\t\tif (utilisations != null){\r\n\t\t\t\t\t\tfor (ResourceContainer resourceContainer : containers) {\r\n\t\t\t\t\t\t\tfor (ProcessingResourceSpecification processingResourceSpecification : resourceContainer.getActiveResourceSpecifications_ResourceContainer()) {\r\n\t\t\t\t\t\t\t\tfor (UtilisationResult utilisationResult : utilisations) {\r\n\t\t\t\t\t\t\t\t\tif (utilisationResult instanceof ProcessingResourceSpecificationResult){\r\n\t\t\t\t\t\t\t\t\t\tProcessingResourceSpecificationResult procResResult = ((ProcessingResourceSpecificationResult)utilisationResult);\r\n\t\t\t\t\t\t\t\t\t\t// compare container and resource type, because the proc resource may have changed (the printed candidate is not necessarily the current one on the blackboard). \r\n\t\t\t\t\t\t\t\t\t\tif (EMFHelper.checkIdentity((ResourceContainer)procResResult.getProcessingResourceSpecification_ProcessingResourceSpecificationResult().eContainer(),resourceContainer)\r\n\t\t\t\t\t\t\t\t\t\t\t\t&& EMFHelper.checkIdentity(procResResult.getProcessingResourceSpecification_ProcessingResourceSpecificationResult().getActiveResourceType_ActiveResourceSpecification(), processingResourceSpecification.getActiveResourceType_ActiveResourceSpecification())){\r\n\t\t\t\t\t\t\t\t\t\t\toutput.append(procResResult.getResourceUtilisation());\r\n\t\t\t\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\toutput.append(\";\");\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tfor (LinkingResource linkingResource : links) {\r\n\t\t\t\t\t\t\tfor (UtilisationResult utilisationResult : utilisations) {\r\n\t\t\t\t\t\t\t\tif (utilisationResult instanceof LinkingResourceResults){\r\n\t\t\t\t\t\t\t\t\tLinkingResourceResults linkResult = ((LinkingResourceResults)utilisationResult);\r\n\t\t\t\t\t\t\t\t\tif (EMFHelper.checkIdentity(linkResult.getLinkingResource_LinkingResourceResults(),linkingResource)){\r\n\t\t\t\t\t\t\t\t\t\toutput.append(linkResult.getResourceUtilisation());\r\n\t\t\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\toutput.append(\";\");\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t for (int i = 0; i < containers.size()+links.size(); i++){\r\n\t\t\t\t\t\t output.append(\";\");\r\n\t\t\t\t\t }\r\n\t\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn output;\r\n\t}",
"@Override\n\t\t\tpublic void print() {\n\t\t\t\t\n\t\t\t}",
"@Override\r\n\t\t\tpublic void print() {\n\t\t\t\t\r\n\t\t\t}",
"void printHellow() {\n logger.debug(\"hellow world begin....\");\n logger.info(\"it's a info message\");\n logger.warn(\"it's a warning message\");\n loggerTest.warn(\"from test1 :....\");\n loggerTest.info(\"info from test1 :....\");\n\n // print internal state\n LoggerContext lc = (LoggerContext) LoggerFactory.getILoggerFactory();\n StatusPrinter.print(lc);\n }",
"private void printHelp() \n {\n Logger.Log(\"You have somehow ended up in this strange, magical land. But really you just want to go home.\");\n Logger.Log(\"\");\n Logger.Log(\"Your command words are:\");\n parser.showCommands();\n Logger.Log(\"You may view your inventory or your companions\");\n }",
"@Override\n\tpublic void juxing() {\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t}",
"private void out(Object obj) {\r\n\t\tSystem.out.println(deb + obj.toString());\r\n\t}",
"@Override\n\t\tpublic void print() {\n\n\t\t}",
"public String printSortedResult() {\n\t\tStringBuilder sb = new StringBuilder();\n\n\t\tsb.append(printStartNumberAndName() + \"; \");\n\t\tsb.append(printInfo());\n\t\t\n\t\tsb.append(printTotalTime());\n\t\t\n\t\tsb.append(errorHandler.print());\n\t\t\n\t\treturn sb.toString();\n\t}",
"private void doPrint(final PrintStream out) {\n\t\tdoPrintLine(out);\n\t\tprintComponent(out, \"modules\", \"components\", \"plugins\");\n\t\tdoPrintLine(out);\n\t\tprintComponents(out, \"boot\", bootConfig.getComponentConfigs());\n\t\tfor (final ModuleConfig moduleConfig : modules) {\n\t\t\tdoPrintLine(out);\n\t\t\tprintModule(out, moduleConfig);\n\t\t}\n\t\tdoPrintLine(out);\n\t}",
"private void printOutResult (){\n if (!numStack.empty()){\n System.out.println(numStack.peek());\n }\n else{\n System.out.println(\"Stack empty.\");\n }\n }",
"private String printHelp()//refactored\n { String result = \"\";\n result += \"\\n\";\n result += \"You are weak if you have to ask me\\n\";\n result += \"Try not to die, while i´am mocking you.\\n\";\n result += \"\\n\";\n result += \"\" + currentRoom.getDescription() + \"\\n\"; //new\n result += \"\\nExits: \" + currentRoom.getExitDescription() + \"\\n\";//new\n result += \"\\nCommand words:\\n\";\n result += ValidAction.getValidCommandWords();\n result += \"\\n\";\n \n return result;\n }",
"public void printInfo(){\n\t}",
"public void printInfo(){\n\t}",
"public void printInfo(){\n System.out.println(\" this is my y \"+(y+1)+\" this is my x \"+ X.valueOfInt(x));\n System.out.println(\"i am full: \"+ isFull);\n }",
"void print() {\r\n\t\tOperations.print(lexemes, tokens);\r\n\t}",
"void displayResults(final InvokeResult[] results)\n {\n for (int i = 0; i < results.length; ++i)\n {\n final InvokeResult result = results[i];\n\n final String s = new SmartStringifier(\"\\n\", false).stringify(result);\n println(s + \"\\n\");\n }\n }",
"public String printResult() {\n\t\tStringBuilder sb = new StringBuilder();\n\n\t\tsb.append(printStartNumberAndName() + \"; \");\n\t\tsb.append(printInfo());\n\n\t\tsb.append(printTotalTime() + \"; \");\n\n\t\tsb.append(getStartTime() + \"; \");\n\t\tsb.append(getFinishTime());\n\t\n\t\tsb.append(errorHandler.print());\n\t\t\n\t\treturn sb.toString();\n\t}",
"private void printEndingStory()\n {\n System.out.println();\n System.out.println(\"Princess Peach: Thanks, Mario. We'll be forever friends!\");\n System.out.println(\"Mario: Oh, no...\");\n System.out.println(\"Mario: Princess Peach you are more than a friend to me...\");\n System.out.println();\n }",
"public void print()\r\n\t{\r\n\t\tSystem.out.println(\"Method name: \" + name);\r\n\t\tSystem.out.println(\"Return type: \" + returnType);\r\n\t\tSystem.out.println(\"Modifiers: \" + modifiers);\r\n\r\n\t\tif(exceptions != null)\r\n\t\t{\r\n\t\t\tSystem.out.print(\"Exceptions: \" + exceptions[0]);\r\n\t\t\tfor(int i = 1; i < exceptions.length; i++)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.println(\", \" + exceptions[i]);\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Exceptions: none\");\r\n\t\t}\r\n\r\n\t\tif(parameters != null)\r\n\t\t{\r\n\t\t\tSystem.out.print(\"Parameters: \" + parameters[0]);\r\n\t\t\tfor(int i = 1; i < parameters.length; i++)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.print(\", \" + parameters[i]);\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Parameters: none\");\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println();\r\n\t}",
"public static void print() {\r\n\t\tSystem.out.println(\"1: Push\");\r\n\t\tSystem.out.println(\"2: Pop\");\r\n\t\tSystem.out.println(\"3: Peek\");\r\n\t\tSystem.out.println(\"4: Get size\");\r\n\t\tSystem.out.println(\"5: Check if empty\");\r\n\t\tSystem.out.println(\"6: Exit\");\r\n\t\tSystem.out.println(\"====================================================================\");\r\n\t}",
"private static void printDetail() {\n System.out.println(\"Welcome to LockedMe.com\");\n System.out.println(\"Version: 1.0\");\n System.out.println(\"Developer: Sherman Xu\");\n System.out.println(\"sherman.xu@lockers.com\");\n }",
"private void outputMe() {\n\t\tif (changeCount > 2) changeCount = 4 - (changeCount & 1);\n\t\tif (outputValue) {\n\t\t\tSystem.out.append( trueArray[ changeCount ] );\n\t\t} else {\n\t\t\tSystem.out.append( falseArray[ changeCount ] );\n\t\t}\n\t\tchangeCount = 0;\n\t}",
"private void print(String toBeWritten)\n\t\t{ pw.print(getIndentString() + toBeWritten); }",
"private static void task43() {\n System.out.println(\"Twinkle, twinkle, little star,\");\n System.out.println(\"\\tHow I wonder what you are!\");\n System.out.println(\"\\t\\tUp above the world so high,\");\n System.out.println(\"\\t\\tLike a diamond in the sky!\");\n System.out.println(\"Twinkle, twinkle, little star,\");\n System.out.println(\"How I wonder what you are.\");\n }",
"public static void shoInfo() {\n\t\tSystem.out.println(description);\n\t \n\t}",
"public void printOut() {\n System.out.println(\"\\t\" + result + \" = icmp \" + cond.toLowerCase() + \" \" + type + \" \" + op1 + \", \" + op2 );\n\n // System.out.println(\"\\t\" + result + \" = bitcast i1 \" + temp + \" to i32\");\n }",
"private void writeHelper(PrintStream output, QuestionNode root) {\r\n if (root.left == null || root.right == null) {\r\n output.println(\"A:\");\r\n output.println(root.data);\r\n } else {\r\n output.println(\"Q:\");\r\n output.println(root.data);\r\n writeHelper(output, root.left);\r\n writeHelper(output, root.right);\r\n }\r\n }",
"@Override\n public void println ()\n {\n if (text != null)\n {\n text.append (Out.NL);\n col = 0;\n }\n else\n super.println ();\n }",
"private void printResults() {\n\t\tfor (Test test : tests) {\n\t\t\ttest.printResults();\n\t\t}\n\t}",
"public void display() {\n\t\tSystem.out.println(\"[\" + recDisplay(head) + \"]\");\n\t}",
"public static void stdout(){\n\t\tSystem.out.println(\"Buildings Found: \" + buildingsFound);\n\t\tSystem.out.println(\"Pages searched: \"+ pagesSearched);\n\t\tSystem.out.println(\"Time Taken: \" + (endTime - startTime) +\"ms\");\t\n\t}",
"public void print() {\n\t\tSystem.out.println(word0 + \" \" + word1 + \" \" + similarity);\n\t}",
"static void print(Collection c) {\n\t\tSystem.out.print(\"{\");\n\t\tfor(Iterator iterator=c.iterator();iterator.hasNext();) {\n\t\t\tSystem.out.printf(\"\\\"%s\\\"\", iterator.next());\n\t\t\tSystem.out.print(iterator.hasNext()?\", \":\"}\\n\");\n\t\t}\n\t}",
"public void print() {\n System.out.println();\n for (int level = 0; level < 4; level++) {\n System.out.print(\" Z = \" + level + \" \");\n }\n System.out.println();\n for (int row = 3; row >= 0; row--) {\n for (int level = 0; level < 4; level++) {\n for (int column = 0; column < 4; column++) {\n System.out.print(get(column, row, level));\n System.out.print(\" \");\n }\n System.out.print(\" \");\n }\n System.out.println();\n }\n System.out.println();\n }",
"public String printStory() {\r\n\t\tString output = \"\";\r\n\t\tboolean start = true;\r\n\t\tArrayList<String> list = null;\r\n\t\ttry {\r\n\t\t\tlist = load();\r\n\t\t} catch (Exception e) {\r\n\t\t\tSystem.out.println(\"Load has failed.\");\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\tfor (String str : list) {\r\n\t\t\tif (start == true) { // if this is the first line passed in\r\n\t\t\t\toutput = output + str;\r\n\t\t\t\tstart = false;\r\n\t\t\t} else {\r\n\t\t\t\toutput = output + \" \" + str;\r\n\t\t\t\t// add this after the first story line has been passed in\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn output;\r\n\t}",
"public static void printInfo(){\n }",
"private void realPrint(PrintJob job) {\n\t\tout.println(\"Print okay!\");\r\n\t}",
"@Override\n\tpublic void printInfo() {\n\t\tsuper.printInfo();\n\t\tmessage();\n\t\tdoInternet();\n\t\tmailing();\n\t\tcalling();\n\t\twatchingTV();\n\n\t}",
"private void print() {\n printInputMessage();\n printFrequencyTable();\n printCodeTable();\n printEncodedMessage();\n }",
"public void printPieces()\n {\n\tint last = 1;\n\tfor(int i=0;i<unused.length;i++)\n\t {\n\t\tif(unused[i]!=null)\n\t\t {\n\t\t\tSystem.out.println(last + \". \" + unused[i]);\n\t\t\tlast++;\n\t\t }\n\t }\n }",
"@Override\r\n\tpublic void print() {\n\t}",
"public void println() { System.out.println( toString() ); }",
"public void printDetails() {\n System.out.println(\"Name: \" + getFirstName() + \" \" + getLastName());\n System.out.println(\"Height: \" + getHeight() + \" inches\");\n System.out.println(\"Weight: \" + (int) getWeight() + \" pounds\");\n\n // unary, binary, ternary(3)\n // ternary operator\n String travelMessage = canTravel ? \"Does travel\" : \"Does not travel\";\n System.out.println(travelMessage);\n\n String smokeMessage = smokes ? \"Does smoke\" : \"Does not smoke\";\n System.out.println(smokeMessage);\n\n // ternary operators can replace simple if-else statement\n // System.out.print(\"Does \");\n // if (!isCanTravel())\n // System.out.print(\"not \");\n // System.out.println(\"travel\");\n // System.out.print(\"Does \");\n // if (!isSmokes())\n // System.out.print(\"not \");\n // System.out.println(\"smoke\");\n }",
"public void dump() {\n for(Object object : results) {\n System.out.println( object );\n }\n }",
"private void printHelp() \n {\n System.out.println(\"You are lost. You are alone. You wander\");\n System.out.println(\"around at the prision.\");\n System.out.println();\n System.out.println(\"Your command words are:\");\n System.out.println(parser.showCommands());\n }",
"private void printLine()\r\n\t{\r\n\t}",
"public void introduce() {\n\t\tSystem.out.println(\"[\" + this.className() + \"] \" + this.describeRacer());\n\t}",
"private static String print(final ResultSet res) throws Exception {\n final StringBuilder sb = new StringBuilder();\n final ResultSetMetaData md = res.getMetaData();\n for(int i = 0; i < md.getColumnCount(); ++i) {\n sb.append(' ');\n sb.append(md.getColumnName(i + 1));\n sb.append(\" |\");\n }\n sb.append('\\n');\n while(res.next()) {\n for(int i = 0; i < md.getColumnCount(); ++i) {\n sb.append(' ');\n sb.append(res.getString(i + 1));\n sb.append(\" |\");\n }\n sb.append('\\n');\n }\n return sb.toString();\n }",
"public void printAll() {\n\t\tSystem.out.println(mainPot);\n\t\tcurrentPlayer.printHandAndPocket();\n\t\tcurrentPlayer.printCombos();\n\t\topponentPlayer.printCombos();\n\t\tSystem.out.println();\n\t}",
"public void printDetails() {\n PrintFormatter pf = new PrintFormatter();\n\n String first = \"############# Armor Details #############\";\n System.out.println(first);\n pf.formatText(first.length(), \"# Items stats for: \" + name);\n pf.formatText(first.length(), \"# Armor Type: \" + itemsType);\n pf.formatText(first.length(), \"# Slot: \" + slot);\n pf.formatText(first.length(), \"# Armor level: \" + level);\n\n if (baseStats.getHealth() > 0)\n pf.formatText(first.length(), \"# Bonus HP: \" + baseStats.getHealth());\n\n if (baseStats.getStrength() > 0)\n pf.formatText(first.length(), \"# Bonus Str: \" + baseStats.getStrength());\n\n if (baseStats.getDexterity() > 0)\n pf.formatText(first.length(), \"# Bonus Dex: \" + baseStats.getDexterity());\n\n if (baseStats.getIntelligence() > 0)\n pf.formatText(first.length(), \"# Bonus Int: \" + baseStats.getIntelligence());\n\n System.out.println(\"########################################\");\n\n }",
"public void print()\n/* */ {\n/* 226 */ boolean emptyTarget = true;\n/* 227 */ Iterator it; if ((this.subjects != null) && (this.subjects.size() > 0)) {\n/* 228 */ System.out.println(\"\\nSubjects ---->\");\n/* 229 */ emptyTarget = false;\n/* 230 */ for (it = this.subjects.iterator(); it.hasNext();)\n/* 231 */ ((MatchList)it.next()).print();\n/* */ }\n/* 234 */ if ((this.resources != null) && (this.resources.size() > 0)) {\n/* 235 */ System.out.println((emptyTarget ? \"\\n\" : \"\") + \"Resources ---->\");\n/* 236 */ emptyTarget = false;\n/* 237 */ for (it = this.resources.iterator(); it.hasNext();)\n/* 238 */ ((MatchList)it.next()).print();\n/* */ }\n/* 241 */ if ((this.actions != null) && (this.actions.size() > 0)) {\n/* 242 */ System.out.println((emptyTarget ? \"\\n\" : \"\") + \"Actions ---->\");\n/* 243 */ emptyTarget = false;\n/* 244 */ for (it = this.actions.iterator(); it.hasNext();)\n/* 245 */ ((MatchList)it.next()).print();\n/* */ }\n/* 248 */ if ((this.environments != null) && (this.environments.size() > 0)) {\n/* 249 */ System.out.println((emptyTarget ? \"\\n\" : \"\") + \"Environments ---->\");\n/* 250 */ emptyTarget = false;\n/* 251 */ for (it = this.environments.iterator(); it.hasNext();) {\n/* 252 */ ((MatchList)it.next()).print();\n/* */ }\n/* */ }\n/* 255 */ if (emptyTarget) System.out.print(\"EMPTY\");\n/* */ }",
"@Override\r\n\tpublic void printResult() {\n\t\tfor(Integer i:numbers)\r\n\t\t{\r\n\t\t\tSystem.out.println(i+\" \");\r\n\t\t}\r\n\t\t\r\n\t}",
"void printInfo();",
"void print() {\n for (int i = 0; i < 8; i--) {\n System.out.print(\" \");\n for (int j = 0; j < 8; j++) {\n System.out.print(_pieces[i][j].textName());\n }\n System.out.print(\"\\n\");\n }\n }",
"private void sout() {\n\t\t\n\t}",
"public void printContents(){\n System.out.println(this);\n System.out.println(\"Occupied by: \" + pieceAtVertex + \"\\n Neighbors:\" + neighbors);\n }",
"static void print (Object output){\r\n \t\tSystem.out.println(output);\r\n \t}",
"@Override\n public String toString() {\n String output;\n if (isDone) {\n output = String.format(\"[X] %s\", description);\n } else {\n output = String.format(\"[ ] %s\", description);\n }\n return output;\n }",
"private static StringBuilder printUtilisationHeadline(DSEIndividual i,\r\n\t\t\tStringBuilder output) {\r\n\t\tObjectives obs = i.getObjectives();\r\n\t\tif (obs instanceof DSEObjectives){\r\n\t\t\tDSEObjectives dseObj = ((DSEObjectives)obs);\r\n\t\t\tfor (Entry<Objective, Value<?>> o : dseObj) {\r\n\t\t\t\tif (dseObj.hasResultDecoratorFor(o.getKey())){\r\n\t\t\r\n\t\t\t\t\tPCMInstance pcm = Opt4JStarter.getProblem().getInitialInstance();\r\n\t\t\t\t\tList<ResourceContainer> containers = pcm.getResourceEnvironment().getResourceContainer_ResourceEnvironment();\r\n\t\t\t\t\tfor (ResourceContainer resourceContainer : containers) {\r\n\t\t\t\t\t\tList<ProcessingResourceSpecification> procResource = resourceContainer.getActiveResourceSpecifications_ResourceContainer();\r\n\t\t\t\t\t\tfor (ProcessingResourceSpecification processingResourceSpecification : procResource) {\r\n\t\t\t\t\t\t\tProcessingResourceType procType = processingResourceSpecification.getActiveResourceType_ActiveResourceSpecification();\r\n\t\t\t\t\t\t\toutput.append(\"Util of \"+resourceContainer.getEntityName()+\" \"+procType.getEntityName()+\";\");\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\tList<LinkingResource> links = pcm.getResourceEnvironment().getLinkingResources__ResourceEnvironment();\r\n\t\t\t\t\tfor (LinkingResource linkingResource : links) {\r\n\t\t\t\t\t\toutput.append(\"Util of \"+linkingResource.getEntityName()+\" \"\r\n\t\t\t\t\t\t\t\t+linkingResource.getCommunicationLinkResourceSpecifications_LinkingResource().getCommunicationLinkResourceType_CommunicationLinkResourceSpecification().getEntityName()+\";\");\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn output;\r\n\t}",
"public void print()\n {\n System.out.println();\n System.out.println(\"Ticket to \" + destination +\n \" Price : \" + price + \" pence \" + \n \" Issued \" + issueDateTime);\n System.out.println();\n }",
"public synchronized String print() {\r\n return super.print();\r\n }",
"@Override\r\n public void display(PrintWriter out) {\r\n if (this.nrBasic > 0) {\r\n out.println(\"Basic\");\r\n } else {\r\n super.display(out);\r\n }\r\n }",
"protected void brkt() {\n println(breakPoints.toString());\n }",
"public void look() {\n\t\tthis.print((this.observe().get(0)).toString());\n\t\t\n\t}",
"public void print() {\n\t\tSystem.out.println(toString());\n\t}",
"public void doSomething(){\n\t\t// now in here calling doMore();\n\t\tdoMore();\n\t\tSystem.out.println(\"-----------\");\n\t\t\n\t\t\t\n\t\t}",
"@Override\n\tpublic void print() {\n\t\t\n\t}",
"private static void println(Object... obj) {\r\n\t\tif (obj.length == 0) {\r\n\t\t\tSystem.out.println();\r\n\t\t} else {\r\n\t\t\tSystem.out.println(obj[0]);\r\n\t\t}\r\n\t}",
"public void print() {\r\n\t\tSystem.out.print(getUID());\r\n\t\tSystem.out.print(getTITLE());\r\n\t\tSystem.out.print(getNOOFCOPIES());\r\n\t}",
"abstract public void printInfo();",
"private void print(final TestOutcome outcome) {\n this.print(\n new If<>(\n outcome.successful(),\n new MsgPassed(outcome),\n new MsgFailed(outcome)\n ).value()\n );\n }",
"public void printAll() {\n\t\tfor(int i = 0; i<r.length; i++)\n\t\t\tprintReg(i);\n\t\tprintReg(\"hi\");\n\t\tprintReg(\"lo\");\n\t\tprintReg(\"pc\");\n\t}",
"public void print() {\n\t\tif (cs213.isEmpty()) {\n\t\t\tSystem.out.println(\"List is empty!\");\n\t\t\treturn;\n\t\t}\n\t\telse {\n\t\t\tcs213.print();\n\t\t}\n\t\treturn;\n\t\t}",
"public static void preCrawling() {\n\t\ttry {\n\t\t\tHelper.directoryCheck(getOutputFolder());\n\t\t\toutput = new PrintStream(getOutputFolder() + getFilename());\n\n\t\t\t// Add opening bracket around whole trace\n\t\t\tPrintStream oldOut = System.out;\n\t\t\tSystem.setOut(output);\n\t\t\tSystem.out.println(\"{\");\n\t\t\tSystem.setOut(oldOut);\n\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void print()\n {\n System.out.println(\"Course: \" + title + \" \" + codeNumber);\n \n module1.print();\n module2.print();\n module3.print();\n module4.print();\n \n System.out.println(\"Final mark: \" + finalMark + \".\");\n }",
"public void print() {\n System.out.println(\"I am \" + status() + (muted ? \" and told to shut up *sadface*\" : \"\") + \" (\" + toString() + \")\");\n }",
"void printCheck();",
"public void putTail(PrintWriter out) {\n\n\t\tout.println(\"<p>\");\n\t\tout.println(\"<p>\");\n\t\tout.println(\"<h2>Getting Help and Information</h2>\");\n\n\t\tout.println(\"<p>\");\n\t\tout.println(\"For online help, see:\");\n\t\tout.println(\"<p>\");\n\t\tout.println(\n\t\t\t\t\"<a href=\\\"https://hanoi.central:443/TokenCards/ToknCrdEsntls.html\\\"> Token Card Essentials\");\n\n\t\tout.println(\"</a>\");\n\n\t\tout.println(\"<p>\");\n\t\tout.println(\"Contact your nearest Resolution Center:\");\n\t\tout.println(\"<p>\");\n\t\tout.println(\"Americas: <b>x27000</b> or <b>303-272-7000</b>\");\n\t\tout.println(\"<br>\");\n\t\tout.println(\"Europe: <b>x15555</b> or <b>+31-33-454-2555</b>\");\n\t\tout.println(\"<br>\");\n\t\tout.println(\"Japan: <b>x55119</b> or <b>+81-3-5717-5119</b>\");\n\t\tout.println(\"<br>\");\n\t\tout.println(\"Korea: <b>x85388</b> or <b>+82-2-2193-5388</b>\");\n\t\tout.println(\"<br>\");\n\t\tout.println(\"China/Taiwan: <b>x88888</b> or <b>+65-63959888</b>\");\n\t\tout.println(\"<br>\");\n\t\tout.println(\"Asia South: <b>x88888</b> or <b>+65-63959888</b>\");\n\t\tout.println(\"<br>\");\n\t\tout.println(\"Australia/NZ: <b>x88888</b> or <b>+65-63959888</b>\");\n<b>x57300</b> or <b>+61-2-9844-5300</b>\");\n\t\tout.println(\"<!-- ============================================================ -->\");\n\t\tout.println(\"<!-- END MAIN CONTENT -->\");\n\n\t\tout.println(\"<TR> \");\n\t\tout.println(\" <TD> </TD>\");\n\t\tout.println(\"</TR>\");\n\t\tout.println(\"</TABLE>\");\n\n\t\tout.println(\"</TD></TR></TABLE>\");\n\n\t\tout.println(\"</FONT>\");\n\t\tout.println(\"</TD>\");\n\t\tout.println(\"</TR>\");\n\t\tout.println(\"</TABLE>\");\n\n\t\tout.println(\"</TD>\");\n\t\tout.println(\"</TR>\");\n\t\tout.println(\"<TR>\");\n\t\tout.println(\"<TD>\");\n\n\n\t\tout.println(\"<TABLE BORDER=\\\"0\\\" CELLSPACING=\\\"0\\\" CELLPADDING=\\\"2\\\" WIDTH=\\\"100%\\\">\");\n\n\t\tout.println(\"<TR>\");\n\t\tout.println(\"<TD BGCOLOR=\\\"#CC0033\\\"><IMG SRC=\\\"/images/dot.gif\\\" WIDTH=\\\"151\\\" HEIGHT=\\\"1\\\" ALT=\\\"webtone\\\" BORDER=\\\"0\\\"></TD>\");\n\t\tout.println(\"<TD BGCOLOR=\\\"#CC9900\\\"><IMG SRC=\\\"/images/dot.gif\\\" WIDTH=\\\"151\\\" HEIGHT=\\\"1\\\" ALT=\\\"webtone\\\" BORDER=\\\"0\\\"></TD>\");\n\t\tout.println(\"<TD BGCOLOR=\\\"#CCCC33\\\"><IMG SRC=\\\"/images/dot.gif\\\" WIDTH=\\\"151\\\" HEIGHT=\\\"1\\\" ALT=\\\"webtone\\\" BORDER=\\\"0\\\"></TD>\");\n\t\tout.println(\"<TD BGCOLOR=\\\"#FF9900\\\"><IMG SRC=\\\"/images/dot.gif\\\" WIDTH=\\\"151\\\" HEIGHT=\\\"1\\\" ALT=\\\"webtone\\\" BORDER=\\\"0\\\"></TD>\");\n\t\tout.println(\"</TR>\");\n\n\t\tout.println(\"<TR><TD BGCOLOR=\\\"#000000\\\" COLSPAN=\\\"4\\\">\");\n\n\t\tout.println(\"<TABLE BORDER=\\\"0\\\" CELLSPACING=\\\"0\\\" CELLPADDING=\\\"4\\\">\");\n\t\tout.println(\"<TR><TD>\");\n\n\t\tout.println(\"<FONT FACE=\\\"Geneva, Helvetica, Arial, SunSans-Regular\\\" COLOR=\\\"#FFFFFF\\\" SIZE=\\\"2\\\">\");\n\t\tout.println(\"Copyright 1994-2000 Sun Microsystems, Inc., 901 San Antonio Road, Palo Alto, CA 94303 USA. All rights reserved.<BR>\");\n\t\tout.println(\"<A HREF=\\\"http://www.sun.com/share/text/SMICopyright.html\\\"><FONT COLOR=\\\"#FFFFFF\\\">Legal Terms</FONT></A>. \");\n\t\tout.println(\"<A HREF=\\\"http://www.sun.com/privacy/\\\"><FONT COLOR=\\\"#FFFFFF\\\">Privacy Policy</FONT></A>. \");\n\t\tout.println(\"<A HREF=\\\"mailto:Mark.Hotchkiss@Central.Sun.COM\\\"><FONT COLOR=\\\"#FFFFFF\\\">Feedback</FONT></A></FONT>\");\n\n\t\tout.println(\"</TD></TR>\");\n\t\tout.println(\"</TABLE>\");\n\n\t\tout.println(\"</TD></TR>\");\n\t\tout.println(\"</TABLE>\");\n\n\t\tout.println(\"</TD>\");\n\t\tout.println(\"</TR>\");\n\t\tout.println(\"</TABLE>\");\n\n\t\tout.println(\"</TD>\");\n\t\tout.println(\"</TR>\");\n\t\tout.println(\"</TABLE>\");\n\n\t\tout.println(\"</CENTER>\");\n\n\t\tout.println(\"</BODY>\");\n\t\tout.println(\"</HTML>\");\n\t}",
"private void printWelcome()//refactored\n {\n System.out.println();\n waitTime(0.5);\n System.out.println(\"Let´s play a game...\");\n waitTime(0.5);\n System.out.println(\"Welcome to the awesome Adventure Game 'Magic Quest'!\");\n waitTime(0.5);\n System.out.println(\"If you want to become a mighty madican - you have to play.\");\n waitTime(0.5);\n System.out.println(\"Type 'help' if you need help.\");\n waitTime(0.5);\n System.out.println();\n waitTime(0.5);\n System.out.println(currentRoom.getDescription() + \"\\n\");//new\n waitTime(0.5);\n System.out.println(currentRoom.getExitDescription() + \"\\n\");//new\n waitTime(0.5);\n System.out.println();\n }",
"@Override\n public String print() {\n return this.text + \"\\n\" + \"1. \" + this.option1.text + \"\\n\" + \"2. \" + this.option2.text;\n }",
"public void print() {\n System.out.print(\"[ \" + value + \":\" + numSides + \" ]\");\n }",
"public void outputActualIndentation() {\n\t\tfor (int steps = 1; steps <= indentLevel; steps++) {\n\t\t\toutputJALPrintStream.print(\" \");\n\t\t}\n\t\tif (showMarkerFlag) {\n\t\t\toutputJALPrintStream.print(\"|\");\n\t\t}\n\t}",
"public void print() {\r\n\t\tObject tmp[] = piece.values().toArray();\r\n\t\tfor (int i = 0; i < piece.size(); i++) {\r\n\t\t\tChessPiece p = (ChessPiece)tmp[i];\r\n\t\t\tSystem.out.println(i + \" \" + p.chessPlayer + \":\" + p.position + \" \" + p.isEnabled());\r\n\t\t}\r\n\t\tSystem.out.println();\r\n\t\tSystem.out.println(body.countComponents());\r\n\t}",
"private void printInfo() {\n System.out.println(\"\\nThis program reads the file lab4.dat and \" +\n \"inserts the elements into a linked list in non descending \"\n + \"order.\\n\" + \"The contents of the linked list are then \" +\n \"displayed to the user in column form.\\n\");\n }",
"public void printDetails()\n {\n System.out.println(title);\n System.out.println(\"by \" + author);\n System.out.println(\"no. of pages: \" + pages);\n \n if(refNumber == \"\"){\n System.out.println(\"reference no.: zzz\");\n }\n else{\n System.out.println(\"reference no.: \" + refNumber);\n }\n \n System.out.println(\"no. of times borrowed: \" + borrowed);\n }",
"@VisibleForTesting\n void print();",
"public void println() {\n\t\tprintln(\"\"); //$NON-NLS-1$\n\t}",
"public void printAll(){\n\t\tSystem.out.println(\"Single hits: \" + sin);\n\t\tSystem.out.println(\"Double hits: \" + doub);\n\t\tSystem.out.println(\"Triple hits: \" + trip);\n\t\tSystem.out.println(\"Homerun: \" + home);\n\t\tSystem.out.println(\"Times at bat: \" + atbat);\n\t\tSystem.out.println(\"Total hits: \" + hits);\n\t\tSystem.out.println(\"Baseball average: \" + average);\n\t}",
"public void print() { /* FILL IN */ }",
"private void summarize() {\n System.out.println();\n System.out.println(totalErrors + \" errors found in \" +\n totalTests + \" tests.\");\n }",
"private void summarize() {\n System.out.println();\n System.out.println(totalErrors + \" errors found in \" +\n totalTests + \" tests.\");\n }",
"java.lang.String getOutput();",
"@Override\r\n\tpublic void doThing() {\n\t\tSystem.out.print(\"ÎäÆ÷ÊDZ¦½£,\");\r\n\t}",
"public void printInfo() {\n\t\tString nodeType = \"\";\n\t\tif (nextLayerNodes.size() == 0) {\n\t\t\tnodeType = \"Output Node\";\n\t\t} else if (prevLayerNodes.size() == 0) {\n\t\t\tnodeType = \"Input Node\";\n\t\t} else {\n\t\t\tnodeType = \"Hidden Node\";\n\t\t}\n\t\tSystem.out.printf(\"%n-----Node Values %s-----%n\", nodeType);\n\t\tSystem.out.printf(\"\tNumber of nodes in next layer: %d%n\", nextLayerNodes.size());\n\t\tSystem.out.printf(\"\tNumber of nodes in prev layer: %d%n\", prevLayerNodes.size());\n\t\tSystem.out.printf(\"\tNext Layer Node Weights:%n\");\n\t\tNode[] nextLayer = new Node[nextLayerNodes.keySet().toArray().length];\n\t\tfor (int i = 0; i < nextLayer.length; i++) {\n\t\t\tnextLayer[i] = (Node) nextLayerNodes.keySet().toArray()[i];\n\t\t}\n\t\tfor (int i = 0; i < nextLayerNodes.size(); i++) {\n\t\t\tSystem.out.printf(\"\t\t# %f%n\", nextLayerNodes.get(nextLayer[i]));\n\t\t}\n\t\tSystem.out.printf(\"%n\tPartial err partial out = %f%n%n\", getPartialErrPartialOut());\n\t}"
] | [
"0.6297837",
"0.5953728",
"0.5798798",
"0.5776909",
"0.57745653",
"0.5767572",
"0.57103425",
"0.568606",
"0.56759924",
"0.5654663",
"0.561888",
"0.56047785",
"0.55722696",
"0.55550647",
"0.5551453",
"0.55393326",
"0.55356836",
"0.55269104",
"0.5498152",
"0.5498152",
"0.5495021",
"0.548101",
"0.5458061",
"0.5421505",
"0.5407614",
"0.5405415",
"0.53913367",
"0.53898156",
"0.5379268",
"0.5376364",
"0.5373546",
"0.5370968",
"0.53698754",
"0.5338027",
"0.53318787",
"0.5330715",
"0.53294003",
"0.5326361",
"0.53219354",
"0.5320328",
"0.5317996",
"0.53173697",
"0.53081584",
"0.53069663",
"0.5296841",
"0.52935755",
"0.5292876",
"0.5290795",
"0.5290616",
"0.5286957",
"0.52867055",
"0.52856565",
"0.52830565",
"0.52771854",
"0.52756876",
"0.52749276",
"0.5272435",
"0.5271569",
"0.5271337",
"0.5262733",
"0.5261525",
"0.52539325",
"0.52514344",
"0.5251248",
"0.52508247",
"0.5249223",
"0.52478147",
"0.5245661",
"0.524347",
"0.5240952",
"0.52401733",
"0.5239044",
"0.52351755",
"0.52307594",
"0.5229572",
"0.52294904",
"0.5225451",
"0.522488",
"0.52205294",
"0.5218474",
"0.52144045",
"0.5214378",
"0.5211591",
"0.5210526",
"0.5205127",
"0.5203383",
"0.5201067",
"0.51988286",
"0.51974845",
"0.5195498",
"0.51892173",
"0.518914",
"0.5189048",
"0.5186415",
"0.5185634",
"0.518333",
"0.5181637",
"0.5181637",
"0.5177053",
"0.5172674",
"0.5171399"
] | 0.0 | -1 |
check if this word is longer than the wrap length just by itself: | private void wrap_long_words() {
if ( printing_status() ) {
return;
}
String cur = _current_word.toString();
if ( _platform_io.size_text( cur ) >= _wrap_column ) {
// print out the first bit:
String trim = cur;
while ( _platform_io.size_text( trim ) >= _wrap_column ) {
trim = trim.substring( 0, trim.length() - 1 );
}
_platform_io.print_text( trim );
inc_line();
// then truncate the rest:
String tail = cur.substring( trim.length() );
if ( _current_word.length() == _wrap_column ) // wrapped exactly?
{
_last_printed = '\n';
}
_current_word = new StringBuffer( tail );
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Boolean checkLength(String detail);",
"public boolean checkWord(String word) {\n if (word.length() < longestWordLength) {\n return false;\n } else if (word.length() > longestWordLength) {\n longestWordLength = word.length();\n longestWords = new HashSet<>();\n longestWords.add(word);\n// System.out.println(word);\n } else {\n longestWords.add(word);\n// System.out.println(word);\n }\n return true;\n }",
"public boolean checkLength(Contribution contribution) {\n\t\tint longness= jdbc.queryForObject(\"select lineLength from stories where title=:title\", \n\t\t\t\tnew MapSqlParameterSource(\"title\", contribution.getTitle()), Integer.class);\n\t\tSystem.out.println(\"Your content: \"+contribution.getAddition().length()+\" the max length: \"+longness);\n\t\tif(contribution.getAddition().length() > longness) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}",
"public int lengthOfLongestWord(){\n int n=0;\n for(int i=0;i<size();i++)\n if(get(i).length()>n)n=get(i).length();\n return n;\n }",
"boolean hasSearchLength();",
"private boolean fitsOnBoard(Anchor anchor, ArrayList<Tile> word){\n //check if word would cause spilling off the edge of the board\n int anchorPos = getAnchorPosition(anchor, word);\n int prefixLength = anchorPos;\n int postfixLength = word.size() - anchorPos - 1 ;\n\n if (anchor.prefixCap >= prefixLength && anchor.postfixCap >= postfixLength){\n return true;\n } else {\n return false;\n }\n }",
"private boolean hasValidLength()\n {\n final int length = mTextInputLayout.getText().length();\n return (length >= mMinLen && length <= mMaxLen);\n }",
"private boolean isLengthCorrect(final String token) {\n return token.length() == VALID_TOKEN_LENGTH;\n }",
"public boolean checkInvariants() {\n\t\tRunningLengthWord rlw, prev;\n\n\t\ttry {\n\t\t\tEWAHIterator i =\n\t\t\t\t\tnew EWAHIterator(this.buffer, this.actualsizeinwords);\n\t\t\t// test that actualsizeinwords complies with info in headers and\n\t\t\t// test that literal number is not > max\n\t\t\twhile (i.hasNext()) {\n\t\t\t\tRunningLengthWord w = i.next();\n\t\t\t\tif (i.dirtyWords() > actualsizeinwords) {\n\t\t\t\t\tlog.error(i.dirtyWords() + \" larger than actual \"\n\t\t\t\t\t\t\t+ actualsizeinwords);\n\t\t\t\t\tlog.error(toDebugString());\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tif (i.pointer > actualsizeinwords) {\n\t\t\t\t\tlog.error(\"pointer \" + i.pointer + \" larger than actual \"\n\t\t\t\t\t\t\t+ actualsizeinwords);\n\t\t\t\t\tlog.error(toDebugString());\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tif (w.getNumberOfLiteralWords() > RunningLengthWord.largestrunninglengthcount) {\n\t\t\t\t\tlog.error(\"larger than max literals\"\n\t\t\t\t\t\t\t+ w.getNumberOfLiteralWords());\n\t\t\t\t\tlog.error(toDebugString());\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t\tif (w.getRunningLength() > RunningLengthWord.largestrunninglengthcount) {\n\t\t\t\t\tlog.error(\"larger than max running length \"\n\t\t\t\t\t\t\t+ w.getRunningLength());\n\t\t\t\t\tlog.error(toDebugString());\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// check adjacent words for errors\n\t\t\trlw = new RunningLengthWord(buffer, 0);\n\t\t\tprev = rlw;\n\t\t\trlw = rlw.getNext();\n\n\t\t\twhile (rlw.position < actualsizeinwords\n\t\t\t\t\t&& rlw.position + rlw.getNumberOfLiteralWords() < actualsizeinwords) {\n\t\t\t\t// case 1) second word has no running length -> first one should\n\t\t\t\t// have max literal count\n\t\t\t\tif (rlw.getRunningLength() == 0\n\t\t\t\t\t\t&& prev.getNumberOfLiteralWords() < RunningLengthWord.largestliteralcount) {\n\t\t\t\t\tlog.error(prev.getNumberOfLiteralWords()\n\t\t\t\t\t\t\t+ \" dirty words followed by \"\n\t\t\t\t\t\t\t+ rlw.getNumberOfLiteralWords()\n\t\t\t\t\t\t\t+ \" number of dirty words \" + \"\\n\\n\"\n\t\t\t\t\t\t\t+ toDebugString());\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\t// case 2) both have running length for same bit and first one\n\t\t\t\t// has\n\t\t\t\t// no literals -> first one should have max running length\n\t\t\t\tif (prev.getRunningLength() > 0\n\t\t\t\t\t\t&& rlw.getRunningLength() > 0\n\t\t\t\t\t\t&& prev.getNumberOfLiteralWords() == 0\n\t\t\t\t\t\t&& prev.getRunningBit() == rlw.getRunningBit()\n\t\t\t\t\t\t&& prev.getRunningLength() < RunningLengthWord.largestrunninglengthcount) {\n\t\t\t\t\tlog.error(\"Two running length for same bit of length \"\n\t\t\t\t\t\t\t+ prev.getRunningLength() + \" and \"\n\t\t\t\t\t\t\t+ rlw.getRunningLength() + \"\\n\\n\" + toDebugString());\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\tprev = rlw;\n\t\t\t\trlw = rlw.getNext();\n\t\t\t}\n\n\t\t\tif (!prev.equals(this.rlw)) {\n\t\t\t\tlog.error(\"Last word should have been \" + prev.toString()\n\t\t\t\t\t\t+ \" but was \" + this.rlw.toString());\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\t// the largest bit set == sizeinbits\n\t\t\tIntIterator it = intIterator();\n\t\t\tint greatest = -1;\n\t\t\twhile (it.hasNext()) {\n\t\t\t\tgreatest = it.next();\n\t\t\t}\n\t\t\tif (this.sizeinbits != greatest + 1) {\n\t\t\t\tlog.error(\"sizein bits \" + sizeinbits\n\t\t\t\t\t\t+ \" but largest value is \" + greatest + \"\\n\\n\"\n\t\t\t\t\t\t+ toDebugString());\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\tcatch (Exception e) {\n\t\t\tLoggerUtil.logException(e, log);\n\t\t\tlog.error(bufferToString());\n\t\t}\n\n\t\treturn true;\n\t}",
"public int getWordLength();",
"public static boolean checkLineLength(String matrice){\r\n String[] lignes = matrice.trim().split(\" {1,}\");\r\n int longeur = lignes[0].length();\r\n int i = 1;\r\n boolean memeLongeur = true;\r\n while(i < lignes.length && memeLongeur){\r\n memeLongeur = (longeur == lignes[i].length());\r\n ++i;\r\n }\r\n\r\n if(! memeLongeur){\r\n System.out.println(\"Matrice invalide, lignes de longueurs differentes !\");\r\n }\r\n\r\n return memeLongeur;\r\n }",
"public boolean meetsMinimumLength(){\n\n return alg.meetsMinimumLength(input.getText().toString());\n }",
"public static int getWordlenght() {\r\n\t\treturn lenght;\r\n\t}",
"public boolean longerThan(CMLVector3 v) {\r\n Vector3 veucl3 = this.getEuclidVector3();\r\n return (veucl3 == null) ? false : veucl3.longerThan(v\r\n .getEuclidVector3());\r\n }",
"private boolean isLong(int nextVal) {\n\t\treturn Character.isLetter(nextVal);\n\t}",
"public boolean isTextTruncated() {\n for (int i = 0; i < fragments.size(); i++) {\n if (((TextFragmentBox) fragments.get(i)).isTruncated())\n return true;\n }\n return false;\n }",
"boolean hasWidth();",
"boolean hasWidth();",
"boolean hasWidth();",
"boolean testLength(Tester t) {\n return t.checkExpect(lob3.length(), 3) && t.checkExpect(los3.length(), 3)\n && t.checkExpect(los1.length(), 1) && t.checkExpect(new MtLoGamePiece().length(), 0);\n }",
"public static boolean hasLength(String str) {\n\t\treturn hasLength((CharSequence) str);\n\t}",
"public static String longestWord(String sen) {\n if (sen == null) {\n return null;\n }\n String filtered = sen.replaceAll(\"[^a-zA-Z ]\", \"\");\n String[] words = filtered.split(\" \");\n String current = \"\";\n for (String word : words) {\n if (word.length() > current.length()) {\n current = word;\n }\n }\n return current;\n }",
"protected boolean isChunkAtWordBoundary(TextChunk chunk, TextChunk previousChunk) {\r\n\t\treturn chunk.getLocation().isAtWordBoundary(previousChunk.getLocation());\r\n\t}",
"LengthGreater createLengthGreater();",
"@Override\n public String longestWord() {\n if (this.word.length() > this.restOfSentence.longestWord().length()) {\n return this.word;\n }\n return this.restOfSentence.longestWord();\n }",
"private static boolean checkLength(String password) {\n \treturn password.length() >= minLength;\n }",
"private boolean checkString(){\n createString();\n char[] charsJoinedString=this.joinedTextPalindrome.toCharArray();\n int lengthString=charsJoinedString.length-1;\n for(int i=0;i<charsJoinedString.length;i++){\n if(charsJoinedString[i]!=charsJoinedString[lengthString]){\n return false;\n }\n lengthString--;\n }\n return true;\n \n }",
"public static boolean moreWordsOfOddLength(Scanner s){\n\t\t\n\t\tint oddWordCount = 0;\n\t\tint evenWordCount = 0;\n\t\t\n\t\twhile(s.hasNext()){\n\t\t\t\n\t\t\tString tempString = s.next();\n\t\t\t\n\t\t\t//check to see if tempString is even or odd and keep track of totals\n\t\t\tif(tempString.length() % 2 == 0){\n\t\t\t\tevenWordCount++;\n\t\t\t}\n\t\t\telse{\n\t\t\t\toddWordCount++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//check to see the amount of even words is greater or equal to odd words\n\t\tif(evenWordCount >= oddWordCount){\n\t\t\treturn false;\n\t\t}\n\t\telse{\n\t\t\treturn true;\n\t\t}\n\t\t\n\t}",
"int getTextLength();",
"public int numWordsOfLength(int len){\n int n=0;\n for(int i=0;i<size();i++)\n if(get(i).length()==len)n++;\n return n;\n }",
"public static boolean isValidLength(String test) {\n return test.length() <= MAX_CHARACTERS;\n }",
"public boolean isLargerThan(int length, int height){\n\t\treturn this.getArea() > (length * height);\n\t}",
"public int findLongestWordLength() {\n int longestWordLength = wordsArray[0].length();\n\n for (int i = 1; i < wordsArray.length; i++) {\n if (wordsArray[i].length() > wordsArray[i - 1].length()) {\n longestWordLength = wordsArray[i].length();\n }\n }\n if (summationWord.length() > longestWordLength) {\n longestWordLength = summationWord.length();\n }\n return longestWordLength;\n }",
"public static boolean differByOne(String word, String ladderLast) {\n if (word.length() != ladderLast.length()) {\n return false;\n }\n int count = 0;\n for (int i = 0; i < word.length(); i++) {\n if (word.charAt(i) != ladderLast.charAt(i)) {\n count++;\n }\n }\n return (count == 1);\n }",
"public String longestWord(String[] words) {\n String ans = \"\";\n\n Set<String> wordSet = new HashSet<String>();\n for (String w : words) {\n wordSet.add(w);\n }\n\n for (String w : words) {\n if (isValidWord(w, wordSet)) {\n System.out.println(w);\n if (w.length() > ans.length()) {\n ans = w;\n } else if (w.length() == ans.length() && w.compareTo(ans) > 0) {\n ans = w;\n }\n }\n }\n\n return ans;\n }",
"public static boolean isTextEllipsized(TextView textView){\n\n Layout textViewLayout = textView.getLayout();\n\n if (textViewLayout != null) {\n\n int lines = textViewLayout.getLineCount();\n\n if (lines > 0) {\n\n if (textViewLayout.getEllipsisCount(lines-1) > 0) return true;\n }\n }\n\n return false;\n }",
"private static boolean checkWords(String line) {\n\t\tint count = 0;\n\t\tScanner reader = new Scanner(line);\n\t\twhile (reader.hasNext()) {\n\t\t\tcount++;\n\t\t\treader.next();\n\t\t}\n\t\treader.close();\n\t\tif (count >= 4) {\n\t\t\treturn false;\n\t\t} else {\n\t\t\treturn true;\n\t\t}\n\t}",
"public boolean compareLength(Length l1, Length l2){\n return Double.compare(l1.value*l1.unit.baseUnitConversion, l2.value*l2.unit.baseUnitConversion) == 0;\n }",
"public int getLength() { return this.words.size(); }",
"@Test\n public void testSanitizeText() {\n assertEquals(text.length() - 9, WordUtil.sanitizeText(text).length());\n }",
"public static void main(String[] args) {\n\n Scanner scan = new Scanner(System.in);\n\n // Declare the maximum length\n final int maxLength = 10;\n\n // Input string\n System.out.println(\"Please, enter the word: \");\n String word = scan.nextLine();\n\n // Declare length of the word\n int stringLength = word.length();\n\n // Condition \"Ternary'\n String result = (stringLength > maxLength) ? \"ERROR! Wrong length of the word!\" : \"Great job, the length of your word is \" + stringLength;\n System.out.println(result);\n\n // Condition \"if...else\"\n /* if (stringLength > max) {\n System.out.println(\"ERROR! Wrong length of the word!\");\n } else {\n System.out.println(\"Great job, the length of your word is \" + stringLength);\n }*/\n }",
"public int numWords(int length) {\r\n return 0;\r\n }",
"private static int lengthOfLastWord(String s) {\n int count = 0;\n char[] arr = s.trim().toCharArray();\n\n for (int i = arr.length - 1; i >= 0; i--) {\n if (arr[i] == ' ') { break; }\n count++;\n }\n return count;\n }",
"public int getTextLength();",
"int lengthLastWord(String input) {\n int len = input.length();\n int lastLen = 0;\n int pastLen = 0;\n for (int index = 0;index < len;index++) {\n lastLen ++;\n if(input.charAt(index) == ' ') {\n pastLen = lastLen;\n lastLen = 0;\n \n }\n }\n \n return pastLen;\n \n}",
"@Test\r\n\tvoid testMaxWordLengthSimple() {\n\t\tString input[] = { \"Beet\" };\r\n\t\tint expected = 4;\r\n\r\n\t\t// Use assertEquals to compare numbers;\r\n\t\tassertEquals(expected, Main.maxWordLength(input));\r\n\r\n\t}",
"public boolean endsLy(String str) {\r\n return str.length() > 1 ? str.substring(str.length() - 2, str.length()).equals(\"ly\") : false;\r\n }",
"public static boolean minCharRequirementPassed(String toCheck, int limit) {\n if (toCheck == null) return false;\n return toCheck.length() >= limit;\n }",
"public boolean hasValidLength(String field, int maxLength) {\n return field.length() <= maxLength;\n }",
"private boolean isTooLarge(String name) {\n Dimension d = faFile.getDimension(name);\n return (d.width > theDialog.getWidth() - 10);\n }",
"public boolean isFull(){\n return this.top==this.maxLength-1;\n }",
"static String biggerIsGreater(String w) {\n int l = w.length();\n String[] strs = new String[w.length()];\n for (int i = 0; i < l; i++) {\n strs[i] = w.charAt(i)+\"\";\n }\n\n Arrays.sort(strs, Collections.reverseOrder());\n StringBuffer maxString = new StringBuffer();\n for (int i = 0; i < l; i++) {\n maxString.append(strs[i]);\n }\n StringBuffer s = new StringBuffer(w);\n if(s.toString().equals(maxString)){\n return \"no answer\";\n }\n boolean found = false;\n int i = l-1;\n int j = 0;\n while(!found && i>0 && s.toString().compareTo(maxString.toString()) <0){\n char qi = s.charAt(i);\n for (j = i-1; j >=0 ; j--) {\n char qj = s.charAt(j);\n if(qi > qj){\n s.setCharAt(i, qj);\n s.setCharAt(j, qi);\n found = true;\n break;\n }\n }\n i--;\n }\n String res = sort(s.toString(), j+1, s.length(), false);\n\n return found?res:\"no answer\";\n\n }",
"protected boolean isVmNameValidLength(VM vm) {\n\n // get VM name\n String vmName = vm.getvm_name();\n\n // get the max VM name (configuration parameter)\n int maxVmNameLengthWindows = Config.<Integer> GetValue(ConfigValues.MaxVmNameLengthWindows);\n int maxVmNameLengthNonWindows = Config.<Integer> GetValue(ConfigValues.MaxVmNameLengthNonWindows);\n\n // names are allowed different lengths in Windows and non-Windows OSs,\n // consider this when setting the max length.\n int maxLength = vm.getvm_os().isWindows() ? maxVmNameLengthWindows : maxVmNameLengthNonWindows;\n\n // check if name is longer than allowed name\n boolean nameLengthValid = (vmName.length() <= maxLength);\n\n // return result\n return nameLengthValid;\n }",
"public boolean wordBreak2(String s, List<String> wordDict) {\n int maxL =0;\n Set<String> wordSet = new HashSet<>(wordDict);\n for (String word : wordDict) {\n maxL = Math.max(maxL, word.length());\n }\n boolean[] dp = new boolean[s.length() + 1];\n dp[0] = true;\n for (int i = 1; i <= s.length(); i++) {\n for (int j = i-1; j >=0 && j >= i - maxL; j--) {\n if (dp[j] && wordSet.contains(s.substring(j, i))) {\n dp[i] = true;\n break;\n }\n }\n }\n return dp[s.length()];\n }",
"public static void main(String[] args) {\n String s = \"Human brain is a biological learning machine\";\n String [] word = s.split(\" \");\n String maxlethWord = \"\";\n for(int i = 0; i < word.length; i++){\n if(word[i].length() >= maxlethWord.length()){\n maxlethWord = word[i];\n }\n }\n System.out.println(\"The length and longest word : \"+maxlethWord);\n\n }",
"public boolean checkLength(String password) {\n return password.matches(\"^.{8,25}$\");\n }",
"public static int calculateLengthOfLongestWord(final List<String> lines)\n\t\t\t{\n\t\t\t\treturn 0;\n\t\t\t}",
"public static int calculateLengthOfLongestWord(final List<String> lines)\n\t\t\t{\n\n\t\t\t\tint lengthLongestWord = 0;\n\t\t\t\tfor (final String line : lines)\n\t\t\t\t{\n\t\t\t\t\tfor (final String word : line.split(\" \"))\n\t\t\t\t\t{\n\t\t\t\t\t\tif (word.length() > lengthLongestWord)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlengthLongestWord = word.length();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn lengthLongestWord;\n\t\t\t}",
"public void removeWordsOfLength(int len){\n for(int i=0;i<size();i++)\n if(get(i).length()==len){\n \tremove(i--);\n }\n }",
"public native boolean isLengthComputable() /*-{\n\t\treturn this.lengthComputable;\n\t}-*/;",
"public static int longerThanOriginalOne(String s){\n\n\t\tint count = 1;\n\t\tchar c = s.charAt(0);\n\n\t\tint total = 0;\n\n\t\tfor (int i = 1; i < s.length(); i++){\n\t\t\tif (s.charAt(i) == c){\n\t\t\t\tcount += 1;\n\t\t\t}else{\n\t\t\t\ttotal += 1 + Integer.toString(count).length();\n\t\t\t\tc = s.charAt(i);\n\t\t\t\tcount = 1;\n\n\t\t\t}\n\t\t}\n\t\ttotal += 1 + Integer.toString(count).length();\n\t return total;\n\n\n\t}",
"private boolean scanFrameLength() {\n\n // scan the 2, 3, or 4 characters of the base 64 encoded frame length, terminated by a close...\n StringBuilder frameLengthChars = new StringBuilder( 4 );\n boolean lengthDone = false;\n boolean done = false;\n while( !done & !lengthDone ) {\n\n byte thisByte = buffer.get();\n done = !buffer.hasRemaining();\n\n // if we just scanned a close character, then we need to test for validity of the length...\n if( thisByte == CLOSE ) {\n\n // if we have at least enough characters, we have a possible winner here...\n if( frameLengthChars.length() >= 2 ) {\n frameLength = (int) Base64.decodeLong( frameLengthChars.toString() );\n\n // if the frame is longer than the maximum, reject it...\n if( frameLength > maxMessageSize ) lengthDone = true;\n\n // otherwise, we DID get a winner...\n else {\n frameOpenDetected = true;\n done = true;\n }\n }\n\n // it's not a properly formed frame start, so time to keep scanning if we have any characters left...\n else lengthDone = true;\n }\n\n // if we just scanned a base 64 character, it's potentially part of the length...\n else if( Base64.isValidBase64Char( (char) thisByte ) ){\n\n // if we still could use more base 64 characters, just add it and get out of here...\n if( frameLengthChars.length() < 4 ) {\n frameLengthChars.append( (char) thisByte );\n }\n\n // if this would be the fifth base 64 character, then it's not a properly formed frame...\n else lengthDone = true;\n }\n\n // if we got some other character, then it's not a properly formed frame...\n else {\n buffer.position( buffer.position() - 1 ); // it's possible we just got another open, so back up just in case...\n lengthDone = true;\n }\n }\n return done;\n }",
"public void setWordLength(String wordSearched){\r\n wordLength = wordSearched.length();\r\n this.wordLength = wordLength;\r\n }",
"public boolean isLongPressedName(String name, String typed) {\n int nLen = name.length();\n int tLen = typed.length();\n for (int i = 0, j = 0; i < nLen;) {\n char c = name.charAt(i);\n int nRepeat = 1;\n for (++i; i < nLen && name.charAt(i) == c; i++, nRepeat++) {}\n int tRepeat = 0;\n for (; j < tLen && typed.charAt(j) == c; j++, tRepeat++) {}\n if (nRepeat > tRepeat) return false;\n }\n return true;\n }",
"public String findLongestWord(String s, List<String> d) {\n String ans = new String();\n for(String word : d)\n {\n if(word.length() < ans.length() || word.length() > s.length()\n || (word.length() == ans.length() && word.compareTo(ans) > 0))\n continue; //Special case, no need to check.\n \n if(isSubSequence(s, word) && betterAns(word, ans))\n ans = word;\n }\n return ans;\n }",
"boolean isRight() {\r\n\t\tint maxlength;\r\n\t\tmaxlength = Math.max(Math.max(side1, side2), side3);\r\n\t\treturn (maxlength * maxlength == (side1 * side1) + (side2 * side2) + (side3 * side3) - (maxlength * maxlength));\r\n\t}",
"public int getWordSize(){\n\t\treturn word.length;\n\t}",
"public boolean hasWord() {\n return ((bitField0_ & 0x00000004) == 0x00000004);\n }",
"public int getLength() {\n\t\t\treturn this.text.length();\n\t}",
"static void minMaxLengthWords(String input) \n {\n int len = input.length(); \n int si = 0, ei = 0; \n int min_length = len, min_start_index = 0, \n max_length = 0, max_start_index = 0; \n \n // Loop while input string is not empty \n while (ei <= len) \n { \n if (ei < len && input.charAt(ei) != ' ') \n { \n ei++; \n } \n else\n { \n // end of a word \n // find curr word length \n int curr_length = ei - si; \n \n if (curr_length < min_length) \n { \n min_length = curr_length; \n min_start_index = si; \n } \n \n if (curr_length > max_length) \n { \n max_length = curr_length; \n max_start_index = si; \n } \n ei++; \n si = ei; \n } \n } \n \n // store minimum and maximum length words \n minWord = input.substring(min_start_index, min_start_index + min_length); \n maxWord = input.substring(max_start_index, max_start_index + max_length); \n }",
"public boolean isLongPressedName2(String name, String typed) {\n int nLen = name.length();\n int tLen = typed.length();\n int i = 0;\n for (int j = 0; j < tLen; j++) {\n if (i < nLen && name.charAt(i) == typed.charAt(j)) {\n i++;\n } else if (j == 0 || typed.charAt(j) != typed.charAt(j - 1)) return false;\n }\n return i == nLen;\n }",
"public int lengthOfLongestSubstring(String s) {\n return sol2a(s); \n //return sol3_WRONG(s); //NO! D & C (unlike LC53)\n }",
"long countMessageLengthTill(long maxLength) throws IllegalStateException;",
"public int getLongestRepeatedSubstringLength()\r\n {\r\n return maxLength;\r\n }",
"public boolean isLargeStraight(){\n // TODO\n return false;\n }",
"public boolean trim() {\n\t\tif ( bits.length == numWords( length ) ) return false;\n\t\tbits = LongArrays.setLength( bits, numWords( length ) );\n\t\treturn true;\n\t}",
"public boolean isWordFullyGuessed()\n {\n for(int i=0; i<showChar.length; i++)\n {\n if(!showChar[i]) return false;\n }\n\n return true;\n }",
"private void checkLength(String value, int maxLength) throws WikiException {\r\n\t\tif (value != null && value.length() > maxLength) {\r\n\t\t\tthrow new WikiException(new WikiMessage(\"error.fieldlength\", value, Integer.valueOf(maxLength).toString()));\r\n\t\t}\r\n\t}",
"public static int segmentLengthCheck(String translationText, Shell shell, TransUnitInformationData trans, de.folt.util.Messages message)\n\t{\n\t\t// int iSegmentNumber = trans.getISegmentNumber();\n\t\t// add some checks for length here....\n\t\tif ((trans.getSegmentLengthInformation() != -1) && trans.getSizeunit().equals(\"char\"))\n\t\t{\n\t\t\tString translation = MonoLingualObject.simpleComputePlainText(translationText);\n\t\t\tint iLen = translation.length() + 1; // we must add 1 for the\n\t\t\t// current character!\n\t\t\tif (iLen > trans.getSegmentLengthInformation())\n\t\t\t{\n\t\t\t\tint style = SWT.PRIMARY_MODAL | SWT.ICON_WARNING | SWT.OK; // SWT.YES\n\t\t\t\t// |\n\t\t\t\t// SWT.NO;\n\t\t\t\tMessageBox messageBox = new MessageBox(Display.getCurrent().getActiveShell(), style);\n\t\t\t\tmessageBox.setText(message.getString(\"TranslationTooLong\"));\n\t\t\t\tmessageBox.setMessage(message.getString(\"TranslationTextTooLong\") + \"\\n\" + message.getString(\"targetTextWindowSize\") + \" \"\n\t\t\t\t\t\t+ trans.getSegmentLengthInformation() + \" < \" + iLen + \" \" + message.getString(\"targetTextWindowTextLength\"));\n\t\t\t\tint result = messageBox.open();\n\t\t\t\treturn result;\n\t\t\t}\n\t\t}\n\t\treturn -99;\n\t}",
"private int getMinimumWrapMarkWidth() {\n return metrics[Font.PLAIN].charWidth('W');\n }",
"public boolean isCnpRightLength(Person person) {\n\t\tString cnp = person.getCnp();\n\t\tif (cnp.length() < 12) {\n\t\t\treturn false;\n\t\t} else {\n\t\t\treturn true;\n\t\t}\n\n\t}",
"static String longestPalin(String str) {\n\t\t// to check last word for palindrome\n\t\tstr = str + \" \";\n\n\t\t// to store each word\n\t\tString longestword = \"\", word = \"\";\n\n\t\tint length, length1 = 0;\n\t\tfor (int i = 0; i < str.length(); i++) {\n\t\t\tchar ch = str.charAt(i);\n\n\t\t\t// extracting each word\n\t\t\tif (ch != ' ')\n\t\t\t\tword = word + ch;\n\t\t\telse {\n\t\t\t\tlength = word.length();\n\t\t\t\tif (checkPalin(word) && length > length1) {\n\t\t\t\t\tlength1 = length;\n\t\t\t\t\tlongestword = word;\n\t\t\t\t}\n\n\t\t\t\tword = \"\";\n\t\t\t}\n\t\t}\n\n\t\treturn longestword;\n\t}",
"public int getLongestWordLength(String word)\n\t{\n\t\t//checks to make sure the word is a word that starts with a lowercase letter, otherwise return 0\n\t\tif(word.charAt(0) >= 'a' && word.charAt(0) <= 'z')\n\t\t{\n\t\t\tchar letter = word.charAt(0);\n\t\t\t\n\t\t\treturn (myDictionaryArray[(int)letter - (int)'a'].getLongestWordLength());\n\t\t}\n\t\t\n\t\treturn 0;\n\t}",
"public static Object findLongestWord(List<String> words) {\n\t\tint longString = 0;\n\t\tString s= \"\";\n\t\tfor (int i = 0; i < words.size(); i++) {\n\t\t\tif (words.get(i).length()>longString) {\n\t\t\tlongString=words.get(i).length();\n\t\t\t\n\t\t\ts = words.get(i);\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\treturn s;\n\t\t//return null;\n\t}",
"public static boolean paswordLengt(String password){\n\n return password.length() >= 10;\n }",
"public boolean hasWord() {\n return ((bitField0_ & 0x00000004) == 0x00000004);\n }",
"public int lengthOfLastWord(String s) {\n return s.trim().length()-s.trim().lastIndexOf(\" \")-1;\n }",
"boolean hasHadithText();",
"private static boolean isLengthValue(String pageSizeChunk) {\n return CssUtils.isMetricValue(pageSizeChunk) || CssUtils.isRelativeValue(pageSizeChunk);\n }",
"public boolean isFixedWidth() throws PDFNetException {\n/* 561 */ return IsFixedWidth(this.a);\n/* */ }",
"public void findLength()\n\t{\n\t\tlength = name.length();\n\t}",
"boolean hasWord();",
"public boolean hasSecondWord()\r\n {\r\n return this.aSecondWord!=null;\r\n }",
"public boolean ifFieldTooBig(){\n if (SphericalUtil.computeArea(mMapInterface.getPathFrame()) > MAX_FIELD_SIZE) { //if the field is too big\n Toast.makeText(getContext(), getString(R.string.field_too_big), Toast.LENGTH_LONG).show();\n return true;\n }\n return false;\n }",
"public void testLength()\n {\n LinearSearch ls = new LinearSearch();\n\n assertFalse(ls.validLength(int [15] haystack));\n }",
"@Test\n\tpublic void invalidLengthLong() {\n\t\tboolean result = validator.isValid(\"73102851691\");\n\t\tassertFalse(result);\n\t}",
"public int lengthOfLongestSubstring(String s) {\n if (s == null || s.length() == 0) {\n return 0;\n }\n int res = 0;\n boolean[] used = new boolean[128];//ASCII 表共能表示 256 个字符,但是由于键盘只能表示 128 个字符,所以用 128 也行\n int left = 0, right = 0; //维持[i, j) 滑动窗口\n while (right < s.length()) {\n if (!used[s.charAt(right)]) {\n used[s.charAt(right ++)] = true;\n } else {\n res = Math.max(res, right - left);\n while ( left < right && s.charAt(left) != s.charAt(right)) {\n used[s.charAt(left ++)] = false;\n }\n left ++;\n right ++;\n }\n }\n res = Math.max(res, right - left);\n return res;\n }",
"public static boolean goodRuns(String sequence) {\n\t\tString run = sequence.charAt(0) + \"\";\n\t\tint longestRun = 0;\n\t\tfor (int i = 1; i < sequence.length(); i++) {\n\t\t\tif (run.contains(sequence.charAt(i) + \"\")) run += sequence.charAt(i);\n\t\t\telse {\n\t\t\t\tif (longestRun < run.length()) longestRun = run.length();\n\t\t\t\trun = sequence.charAt(i) + \"\";\n\t\t\t}\n\t\t}\n\t\treturn longestRun <= MAX_RUN;\n\t}",
"public int lengthOfLastWord(String s) {\n String[] words = s.split(\" \");\n return words.length==0?0:words[words.length-1].length();\n }",
"private boolean isSmallLexi(String curr, String ori) {\n if (curr.length() != ori.length()) {\n return curr.length() < ori.length();\n }\n for (int i = 0; i < curr.length(); i++) {\n if (curr.charAt(i) != ori.charAt(i)) {\n return curr.charAt(i) < ori.charAt(i);\n }\n }\n return true;\n }"
] | [
"0.65578544",
"0.64257747",
"0.6359306",
"0.6283284",
"0.6169356",
"0.6165757",
"0.6122775",
"0.6117083",
"0.6074723",
"0.60328335",
"0.5933797",
"0.5927836",
"0.59174865",
"0.59100413",
"0.5880513",
"0.58411807",
"0.5827659",
"0.5827659",
"0.5827659",
"0.5822545",
"0.5791631",
"0.57863325",
"0.5772895",
"0.5710898",
"0.57086897",
"0.5670902",
"0.5660933",
"0.56537557",
"0.5652799",
"0.5616501",
"0.5572416",
"0.55689037",
"0.556167",
"0.55251765",
"0.5520642",
"0.55195594",
"0.55083334",
"0.54983085",
"0.5496102",
"0.54891545",
"0.54874545",
"0.54727745",
"0.54516226",
"0.54154193",
"0.54119617",
"0.540392",
"0.54006284",
"0.5397478",
"0.538192",
"0.5381768",
"0.538069",
"0.537232",
"0.53715557",
"0.5369519",
"0.53550667",
"0.5354096",
"0.5341462",
"0.5339032",
"0.5316998",
"0.5309577",
"0.53076905",
"0.5305913",
"0.53051174",
"0.5304333",
"0.52963215",
"0.5291215",
"0.5291003",
"0.52792346",
"0.5264014",
"0.52602446",
"0.5258491",
"0.5257097",
"0.5252906",
"0.524991",
"0.52436435",
"0.5237995",
"0.5226024",
"0.52255595",
"0.52184725",
"0.52145475",
"0.5212439",
"0.5212398",
"0.5210055",
"0.520597",
"0.52046514",
"0.52043986",
"0.52017146",
"0.5199814",
"0.51941514",
"0.51885086",
"0.5185611",
"0.518502",
"0.51750857",
"0.5167381",
"0.5159188",
"0.51578945",
"0.51575625",
"0.51537484",
"0.5148855",
"0.5148784"
] | 0.5874168 | 15 |
reset the column marker to start of line and clear the line count | public void input_entered() {
_last_column = 0;
_last_line = 0;
_last_printed = '\n';
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void resetLine() {\n eof = (cursor == lineMark);\n cursor = lineMark;\n }",
"public void resetClearedLines() {\n this.myClearedLines = 0;\n this.myLineCleared.setText(Integer.toString(this.myClearedLines));\n }",
"public void reset() {\r\n\t\tcursor = mark;\r\n\t}",
"public void resetLines() {\r\n\t\tsetLines(new HashMap<String, ArrayList<Integer>>());\r\n\t}",
"public void resetCount() {\n\t\tresetCount(lineNode);\n\t}",
"public void adjustBeginLineColumn(int newLine, int newCol) {\n/* 511 */ int len, start = this.tokenBegin;\n/* */ \n/* */ \n/* 514 */ if (this.bufpos >= this.tokenBegin) {\n/* 515 */ len = this.bufpos - this.tokenBegin + this.inBuf + 1;\n/* */ } else {\n/* */ \n/* 518 */ len = this.bufsize - this.tokenBegin + this.bufpos + 1 + this.inBuf;\n/* */ } \n/* */ \n/* 521 */ int i = 0, j = 0, k = 0;\n/* 522 */ int nextColDiff = 0, columnDiff = 0;\n/* */ \n/* */ \n/* 525 */ while (i < len && this.bufline[j = start % this.bufsize] == this.bufline[k = ++start % this.bufsize]) {\n/* 526 */ this.bufline[j] = newLine;\n/* 527 */ nextColDiff = columnDiff + this.bufcolumn[k] - this.bufcolumn[j];\n/* 528 */ this.bufcolumn[j] = newCol + columnDiff;\n/* 529 */ columnDiff = nextColDiff;\n/* 530 */ i++;\n/* */ } \n/* */ \n/* 533 */ if (i < len) {\n/* 534 */ this.bufline[j] = newLine++;\n/* 535 */ this.bufcolumn[j] = newCol + columnDiff;\n/* */ \n/* 537 */ while (i++ < len) {\n/* 538 */ if (this.bufline[j = start % this.bufsize] != this.bufline[++start % this.bufsize]) {\n/* 539 */ this.bufline[j] = newLine++; continue;\n/* */ } \n/* 541 */ this.bufline[j] = newLine;\n/* */ } \n/* */ } \n/* */ \n/* 545 */ this.line = this.bufline[j];\n/* 546 */ this.column = this.bufcolumn[j];\n/* */ }",
"public void clear() {\r\n this.line.clear();\r\n }",
"public void flushCurrentLine()\n {\n line = null;\n }",
"public Builder clearStartLineNumber() {\n bitField0_ = (bitField0_ & ~0x00000020);\n startLineNumber_ = 0;\n onChanged();\n return this;\n }",
"public void reset() {\n\t\tif (marker >= 0) {\n\t\t\tsetSize(marker);\n\t\t\tmarker = -1;\n\t\t}\n\t}",
"void clearOffset();",
"void markLine() {\n lineMark = cursor;\n }",
"public synchronized final void reset() {\r\n f_index = getDefaultIndex();\r\n f_userSetWidth = -1;\r\n // by default the first column is sorted the others unsorted\r\n f_sort = getDefaultSort();\r\n }",
"public void reset() {\n position = 0;\n }",
"protected void resetNextAdvanceLineNumber() {\n this.nextAdvanceLineNumber = new Integer(1);\n }",
"public void remLineNumber(){\n ((MvwDefinitionDMO) core).remLineNumber();\n }",
"public void removeAtCursor() {\n lines.remove(cursor);\n if(cursor !=0 && cursor==lines.size())\n cursor--;\n }",
"public void reset()\n {\n currentPosition = 0;\n }",
"public synchronized void resetLineItems() {\n lineItems = null;\n }",
"public void reset() {\n\t\tfor (int i=0; i < this.WAYS; i++) {\n\t\t\tthis.cache[i] = new Line(this.alpha[i], REPL_VAL);\n\t\t}\n\t\t// set mru\n\t\tthis.cache[this.WAYS-1].state = INSERT_VAL;\n\t}",
"public void reset()\n {\n myOffset = 0;\n amIInsideDoubleQuotes = false;\n amIInsideSingleQuotes = false;\n myCurrLexeme = null;\n }",
"private final void yyResetPosition() {\n zzAtBOL = true;\n zzAtEOF = false;\n zzCurrentPos = 0;\n zzMarkedPos = 0;\n zzStartRead = 0;\n zzEndRead = 0;\n zzFinalHighSurrogate = 0;\n yyline = 0;\n yycolumn = 0;\n yychar = 0L;\n }",
"private final void yyResetPosition() {\n zzAtBOL = true;\n zzAtEOF = false;\n zzCurrentPos = 0;\n zzMarkedPos = 0;\n zzStartRead = 0;\n zzEndRead = 0;\n zzFinalHighSurrogate = 0;\n yyline = 0;\n yycolumn = 0;\n yychar = 0L;\n }",
"public void clear(){\r\n\t\tbeginMarker.next = endMarker;\r\n\t\tendMarker.prev = beginMarker;\r\n\t\tnumAdded=0;\r\n\t\tsize=0;\r\n \tmodCount++;\r\n\t}",
"private void clearCursor() {\n \n cursor_ = getDefaultInstance().getCursor();\n }",
"public synchronized void reset()\n {\n printDebug(\"reset() start\");\n\n if (open) {\n \tif(started) {\n \t\tline.stop();\n \t}\n \tif(!reset) {\n \t\tline.flush();\n \t} \t\n \ttotalWritten = 0;\n \t// TODO: totalWritten might be updated after this in write method.\n started = false;\n timeTracker.reset();\n notifyAll();\n }\n reset = true;\n printDebug(\"reset() end\");\n }",
"private int clearLines() {\n\t\tint numGarbageLines = 0;\n\t\tArrayList<Integer> linesToShift = new ArrayList<Integer>();\n\t\tfor (int r = 0; r < matrixHeight; r++) {\n\t\t\tif (isLineFull(r)) {\n\t\t\t\tif (isGarbageLine(r)) {\n\t\t\t\t\tnumGarbageLines++;\n\t\t\t\t}\n\t\t\t\tlinesToShift.add(r);\n\t\t\t\tnumLinesCleared++;\n\t\t\t\tfor (int c = 0; c < matrixWidth; c++) {\n\t\t\t\t\tboardTiles[r][c] = backgroundColor;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfor (Integer removedRow : linesToShift) {\n\t\t\tshiftDownBoard(removedRow);\n\t\t}\n\t\tupdateView();\n\t\treturn linesToShift.size() - numGarbageLines;\n\t}",
"private void resetCursorToMaxBufferedRowsPlus1() {\n if (cursorPosition > rows.size() + 1) {\n cursorPosition = rows.size() + 1;\n }\n }",
"public void resetLines() throws IOException {\n counterSeveralLines = linesAfter;\n if (currentPath != null) {\n bufferReader.close();\n fileReader.close();\n fileReader = new FileReader(currentPath);\n bufferReader = new BufferedReader(fileReader);\n arrayPreviousLines = new String[prevSize];\n resetDateBefore();\n }\n }",
"public void reset() {\r\n\t\tnextTokenPos = 0;\r\n\t}",
"@Override\n\tpublic void reset() {\n\t\tfor (int i = 0; i < _board.length; i++)\n for (int j = 0; j < _board[i].length; j++)\n \t_board[i][j] = null;\n\n\t\t_columnFull = new HashSet<Integer>();\n\t\t_lastPosition = new HashMap<Integer,Integer>();\n\t}",
"public void resetAndTruncate()\n {\n rowIndexFile.resetAndTruncate(riMark);\n partitionIndexFile.resetAndTruncate(piMark);\n }",
"public void reset()\r\n/* 89: */ {\r\n/* 90:105 */ this.pos = 0;\r\n/* 91: */ }",
"public void clear()\r\n\t{\r\n\t\tsynchronized (lines)\r\n\t\t{\r\n\t\t\tlines.clear();\r\n\t\t}\r\n\t}",
"@Override\n\tpublic int getTimeLinePos() {\n\t\treturn 0;\n\t}",
"void unsetBeginPosition();",
"public void clear() {\n this.setRowCount(0);\n }",
"@Override\n public void reset() throws IOException {\n setPosition(startPosition);\n }",
"public void reset() {\n for (int i = 0; i < this.numRows; i++) {\n this.rows[i] = new int[0];\n }\n for (int k = 0; k < this.numCols; k++) {\n this.cols[k] = new IntOpenHashSet();\n }\n }",
"public void reset() {\n\t\tx = 0;\n\t\ty = 0;\n\t\tdir = -90;\n\t\tcoul = 0;\n\t\tcrayon = true;\n\t\tlistSegments.clear();\n \t}",
"public void resetHitMarker() {}",
"public int clearLine()\n {\n int count = 0;\n for (int i = grid.length-1; i >= 1;)\n {\n //check if it's a row to remove\n boolean z = true;\n for (int j = 0; j < grid[i].length; j++)\n {\n if (grid[i][j] == 0)\n {\n z = false;\n break;\n }\n }\n \n //remove it, shift everything down one\n if (z)\n {\n for (int k = i; k >= 1; k--)\n {\n for (int l = 0; l < grid[i].length; l++)\n {\n grid[k][l] = grid[k-1][l];\n }\n }\n count++;\n } else\n {\n i--;\n }\n }\n return count;\n }",
"public void clearMark()\n {\n mark = false;\n }",
"public synchronized void reset() throws IOException {\n if(!marked) {\n throw new IOException(\"No position marked.\");\n }\n resetMarked();\n }",
"public Row resetPosition() {\n rowNumber = -1;\n return this;\n }",
"public void reset ()\n {\n // position our buffer at the beginning of the frame data\n _buffer.position(getHeaderSize());\n }",
"private void clearMarker( AztecCode marker ) {\n\t\tmarker.corrected = new byte[0];\n\t\tmarker.message = \"\";\n\t\tmarker.totalBitErrors = -1;\n\t}",
"public void reset() {\n started = false;\n flushing = false;\n moreText = true;\n headerCount = 0;\n actualLen = 0;\n }",
"private void forward() {\n index++;\n column++;\n if(column == linecount + 1) {\n line++;\n column = 0;\n linecount = content.getColumnCount(line);\n }\n }",
"public void reset()\n {\n // put your code here\n position = 0;\n order = \"\";\n set[0] = 0;\n set[1] = 0;\n set[2] = 0;\n }",
"private void rewind() {\n currentPos = markPos;\n }",
"public void setBeginColumnNumber(int beginColumn) {\n this.beginColumn = beginColumn;\n }",
"public final Marking clearLineWidth()\n {\n clear( LINE_WIDTH_KEY );\n return this;\n }",
"public void reset() {\n this.index = this.startIndex;\n }",
"@Override\n public void clearLineColors() {\n assemblyView.clearLinesColor();\n }",
"public void setLine(int line);",
"public void reset(BacktrackingTokenizerMark mark) {\n\t\tposition = mark.getPosition(tokens);\n\t}",
"public void setStartLineNumber(int foo) { startLineNumber = foo; }",
"public void beforeFirst() throws TuplesException {\n if (logger.isDebugEnabled()) {\n logger.debug(\"Resetting \" + getRowCount() + \" rows of \" +\n tuples.getClass() + \" with columns \" +\n Arrays.asList(tuples.getVariables()));\n }\n \n tuples.beforeFirst();\n beforeEnd = true;\n }",
"public void resetPosition()\n {\n resetPosition(false);\n }",
"private void backward() {\n index--;\n if(column == 0) {\n line--;\n linecount = column = content.getColumnCount(line);\n }else{\n column--;\n }\n }",
"void unsetOffset();",
"public void finish() {\n System.out.println();\n System.out.println(\"Line processed\");\n System.out.println(\"Reseting line...\");\n try{ Thread.sleep(5000); } catch(Exception e) { System.out.println(\"Thread exception\"); }\n this.buffer.clear();\n this.buffer.add(new ArrayList<Integer>());\n this.lineT = 0;\n this.columnT = 0;\n this.inputMode = false;\n }",
"public void clear() {\n\t\tdoily.lines.clear();\n\t\tclearRedoStack();\n\t\tredraw();\n\t}",
"public void setLine (int Line);",
"public void reset() {\n\t\tdroppedFiles.clear();\n\t\tSwingUtilities.invokeLater(new Runnable() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\t((DefaultTableModel) table.getModel()).setRowCount(0);\n\t\t\t}\n\t\t});\n\t\t\n\t\t\n\t}",
"private void resetMarked() {\n if(!data.isEmpty()) {\n data.getFirst().reset();\n }\n for(IoBuffer buf : resetCache) {\n buf.reset();\n data.addFirst(buf);\n }\n resetCache.clear();\n }",
"public void flush() {\n\t\tif ( !printing_status() ) {\n\t\t\tint sz = _platform_io.size_text( _current_word.toString() );\n\t\t\tif ( _last_column + sz >= _wrap_column ) {\n\t\t\t\tinc_line();\n\t\t\t}\n\n\t\t\t_last_column += sz;\n\t\t\t_platform_io.print_text( _current_word.toString() );\n\t\t\t_current_word.setLength( 0 );\n\t\t} else {\n\t\t\t_status_line.append( _current_word.toString() );\n\t\t\t_current_word.setLength( 0 );\n\t\t}\n\t}",
"public void resetCoordinates(){\n pos=0;\n if(this.pIndex<2){\n this.coordinates[0]=TILE_SIZE*15-DICE_SIZE;}\n else{\n this.coordinates[0]=0;}\n if(this.pIndex%3==0){\n this.coordinates[1]=0;}\n else{\n this.coordinates[1]=TILE_SIZE*15-DICE_SIZE;} \n }",
"public Builder clearStartPosition() {\n bitField0_ = (bitField0_ & ~0x00000008);\n startPosition_ = 0;\n onChanged();\n return this;\n }",
"@Override\n\tpublic int getLineType() {\n\t\treturn 0;\n\t}",
"public void reset() {\n this.setIndex(0);\n }",
"public void clear() {\n\t\tfor (int i = 0; i < 3; i++)\n\t\t\tfor (int j = 0; j < 3; j++)\n\t\t\t\ttheBoard[i][j] = SPACE_CHAR;\n\t\tmarkCount = 0;\n\t}",
"public void resetPoints() {\n points = 0;\n }",
"public void clear(){\n\t\tfor (int i=1; i<linesAndStores.length; i++){\n\t\t\tfor(int j = 0; j<32; j++){\n\t\t\t\tsetWord(i, new Word(0));\n\t\t\t\tincrement();\n\t\t\t}\n\t\t}\n\t}",
"public void reset() {\n index = 0;\n }",
"void unsetLeading();",
"public void setLineNo(int lineNo)\n\t{\n\t\tsetIntColumn(lineNo, OFF_LINE_NO, LEN_LINE_NO);\n\t}",
"private void reset() {\n // Init-values\n for (int i = 0; i < cells.length; i++) {\n cells[i] = 0;\n }\n\n // Random colors\n for (int i = 0; i < colors.length; i++) {\n colors[i] = Color.color(Math.random(), Math.random(), Math.random());\n }\n\n // mid = 1.\n cells[cells.length / 2] = 1;\n\n // Clearing canvas\n gc.clearRect(0, 0, canvasWidth, canvasHeight);\n }",
"void unsetEndPosition();",
"private void resetPosition() {\n for (int i = 0; i < board.length; i++) {\n for (int j = 0; j < board[0].length; j++) {\n if (!board[i][j]) {\n rowPos = i;\n columnPos = j;\n return;\n }\n }\n }\n }",
"public void clearLastMarker(){\n lastMarker.remove();\n }",
"public static void clearXY()\r\n{\r\n\tx = 0;\r\n\ty = 0; \r\n\t\r\n}",
"public Builder clearEndLineNumber() {\n bitField0_ = (bitField0_ & ~0x00000040);\n endLineNumber_ = 0;\n onChanged();\n return this;\n }",
"public void clear(){\n\t\tcontenido = getName() + ':';\n\t\tindices.clear();\n\t\tindices.add(0);\n\t}",
"public Builder clearOffset() {\n \n offset_ = 0;\n onChanged();\n return this;\n }",
"void pos(final InputParser parser) {\r\n markedCol = parser.qm;\r\n // check if information has already been added\r\n if(line != 0) return;\r\n \r\n file = parser.file;\r\n line = 1;\r\n col = 1;\r\n final int len = Math.min(parser.qm, parser.ql);\r\n for(int i = 0, ch; i < len; i += Character.charCount(ch)) {\r\n ch = parser.qu.codePointAt(i);\r\n if(ch == 0x0A) { line++; col = 1; } else if(ch != 0x0D) { col++; }\r\n }\r\n }",
"public final void Reset()\n\t{\n\t\t_curindex = -1;\n\t}",
"public void clear() {\n this.updateComment(\"\");\n this.mdlCtrlr.clearTable();\n this.repaint();\n }",
"private void reinit() {\n \tthis.showRowCount = false;\n this.tableCount = 0;\n this.nullString = \"\";\n\t}",
"public com.opentext.bn.converters.avro.entity.ContentErrorEvent.Builder clearPosition() {\n fieldSetFlags()[7] = false;\n return this;\n }",
"void unsetBegin();",
"private void prepareLine(int line){\n int length = mText.getColumnCount(line);\n if(length >= mChars.length){\n mChars = new char[length + 100];\n }\n for(int i = 0;i < length;i++){\n mChars[i] = mText.charAt(line, i);\n }\n }",
"void positionToStart () {\n currentRow = 0 - currentPiece.getOffset();\n currentColumn = board.columns / 2 - currentPiece.width / 2;\n }",
"public static void reset(){\r\n\t\tx=0;\r\n\t\ty=0;\r\n\t}",
"protected void fixLineNumbers() {\n int prevLn = -1;\n for (DexlibAbstractInstruction instruction : instructions) {\n Unit unit = instruction.getUnit();\n int lineNumber = unit.getJavaSourceStartLineNumber();\n if (lineNumber < 0) {\n if (prevLn >= 0) {\n unit.addTag(new LineNumberTag(prevLn));\n unit.addTag(new SourceLineNumberTag(prevLn));\n }\n } else {\n prevLn = lineNumber;\n }\n }\n }",
"public void newBufLine() {\n this.buffer.add(new ArrayList<Integer>());\n this.columnT = 0;\n this.lineT++;\n }",
"void setLineNumber(int lineNumber) {}",
"public void SetBackToBeginning() {\n // starting word\n this.mStartWord = 0;\n // the words count that is displaying\n this.mDisplayWord = 0;\n this.mDisplayCount = 0;\n // reset index.\n this.mTextIndex = 0;\n // to enable to read and draw.\n this.mReadingF = true;\n this.mDisplayF = true;\n this.mWaitingF = false;\n // font size back default\n this.mFontSize = this.mFontDefaultSize;\n // font color back to default\n this.mFontColor = this.mFontDefaultColor;\n }",
"public int getIncline() { return incline; }",
"public void reset() {\n\t\tpos.tijd = 0;\r\n\t\tpos.xposbal = xposstruct;\r\n\t\tpos.yposbal = yposstruct;\r\n\t\tpos.hoek = Math.PI/2;\r\n\t\tpos.start = 0;\r\n\t\topgespannen = 0;\r\n\t\tpos.snelh = 0.2;\r\n\t\tbooghoek = 0;\r\n\t\tpos.geraakt = 0;\r\n\t\tgeraakt = 0;\r\n\t\t\r\n\t}"
] | [
"0.75887734",
"0.71087223",
"0.6986753",
"0.6925525",
"0.66859263",
"0.65507334",
"0.6546158",
"0.64605683",
"0.64375544",
"0.64181936",
"0.63517845",
"0.6315665",
"0.62945104",
"0.62284577",
"0.62063915",
"0.6202762",
"0.6155561",
"0.6146362",
"0.6141518",
"0.6096555",
"0.6084286",
"0.60825413",
"0.60784096",
"0.6058993",
"0.6053594",
"0.60483974",
"0.6039345",
"0.60257596",
"0.6014822",
"0.60094047",
"0.6007402",
"0.5996605",
"0.5961983",
"0.5956149",
"0.59521836",
"0.59241277",
"0.59156936",
"0.59110904",
"0.5884551",
"0.5878196",
"0.5877724",
"0.5868371",
"0.5860696",
"0.5816371",
"0.5806019",
"0.5804617",
"0.5800057",
"0.5790447",
"0.5786277",
"0.57636523",
"0.5749583",
"0.57446223",
"0.5743743",
"0.57330155",
"0.5722098",
"0.57113135",
"0.5700776",
"0.5692276",
"0.5659229",
"0.5647296",
"0.562761",
"0.56210124",
"0.5618",
"0.5617462",
"0.56165403",
"0.5602769",
"0.5595777",
"0.55850625",
"0.5573938",
"0.5571183",
"0.5545882",
"0.55384046",
"0.5537147",
"0.5534631",
"0.5532508",
"0.55289817",
"0.5518057",
"0.5514698",
"0.55143315",
"0.55117136",
"0.5511565",
"0.5510135",
"0.5507284",
"0.55070126",
"0.55038327",
"0.5494222",
"0.5487816",
"0.5484113",
"0.54840684",
"0.548036",
"0.5476079",
"0.5468006",
"0.5463674",
"0.5454768",
"0.5453114",
"0.54499507",
"0.5448563",
"0.54397297",
"0.543868",
"0.54300886",
"0.54273176"
] | 0.0 | -1 |
abort all output hiding/capturing | public void cancel_outhiding() {
_outcaptures.removeAllElements();
_outhides.removeAllElements();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void halt();",
"void suspendOutput();",
"public void suppress() {\n\t\tstop = true;\n\t}",
"public void abort() {\n isAborted = true;\n cancelCommands();\n cancel(true);\n }",
"public void halt ( )\n\t{\n\t\tthis.running = false;\n\t}",
"private void exit() {\n audrey.setExtractingSample(false);\n // If we just extracted argument samples, let the following event know that we're done with\n // arguments.\n instrumentationContext.setLookingForFirstStatement(false);\n }",
"public void stop() {\n System.setErr(saveErr);\n System.setOut(saveOut);\n running = false;\n try {\n flushThread.join();\n } catch (InterruptedException e) {\n }\n }",
"@Override\n public void abort() { \n abortFlag = true ;\n }",
"void stopPumpingEvents();",
"protected void interrupted() {\n\t\tRobot.cubeCollector.setCubeCollector(ControlMode.PercentOutput, 0);\n\t}",
"@Override\n\t\t\tpublic void cancel() {\n\t\t\t\tSystem.exit(0);\n\t\t\t}",
"void halt() {\n this.ws.stop = true;\n this.wr.stop = true;\n }",
"public void stopProcessing() {\n interrupted = true;\n }",
"public void abort() throws IOException;",
"public void aborted() {\n System.out.println(\"Aborted\");\n }",
"private void abortFeedbackLoop() {\n if (circuit.isDisabled()) return;\n \n if (circuit.hasListeners()) {\n ChatColor errorColor = circuit.getPlugin().getPrefs().getErrorColor();\n ChatColor debugColor = circuit.getPlugin().getPrefs().getDebugColor();\n circuit.debug(errorColor + \"Possible infinite feedback loop \" + debugColor + \"detected in input \" + errorColor + index + debugColor + \".\");\n circuit.debug(\"Use /rcenable to reactivate the circuit after solving the problem or destroy it normally.\");\n }\n \n circuit.disable();\n }",
"private void cancel() {\n\t\tfinish();\n\t}",
"public void stopEchoTester();",
"protected void stopAllRedirectors() {\n _stdOutRedirector.setStopFlag();\n _stdErrRedirector.setStopFlag();\n }",
"public void abort()\n\t{\n\t\tif(process != null)\n\t\t\tprocess.destroy();\n\t}",
"private void processQuit() {\n System.exit(0);\n }",
"void resetOutput(){\n\t\tSystem.setOut(oldOut);\n\t}",
"public void turnOffSystemOutput() {\n if (originalSystemOut != null) {\n System.setOut(originalSystemOut);\n originalSystemOut = null;\n\n // WARNING: It is not possible to reconfigure the logger here! This\n // method is called in the UI thread, so reconfiguring the logger\n // here would mean that the UI thread waits for the logger, which\n // could cause a deadlock.\n }\n }",
"private static void kill() {\n if (redirectErr != null) {\n redirectErr.close();\n redirectErr.interrupt();\n redirectErr = null;\n }\n\n if (redirectOut != null) {\n redirectOut.close();\n redirectOut.interrupt();\n redirectOut = null;\n }\n\n if (JVM != null) {\n JVM.destroy();\n JVM = null;\n }\n\n JVMrunning = false;\n\n println(\"JVM reset on \" + java.util.Calendar.getInstance().getTime().toString(), progErr);\n }",
"public void stop() {\n intake(0.0);\n }",
"public void abort() {\n reservedSpace.clear();\n this.abortRequested = true;\n stop();\n }",
"public void killExecution() {\n \n \t\tcancelOrKillExecution(false);\n \t}",
"static public void exit() {\n // We close our printStream ( can be a log so we do things properly )\n out.flush();\n System.exit(0);\n }",
"public void stopListener(){\r\n\t\tcontinueExecuting = false;\r\n\t\tglobalConsoleListener.interrupt();\r\n\t}",
"public void quit(){\n this.println(\"Bad news!!! The library has been cancelled!\");\n System.exit(0);\n\n }",
"public void halt() {\n\t\t// Task can not currently be halted.\n\t}",
"final private static void abort (final String message) {\n\t\tSystem.out.println(message) ;\n\t\tSystem.exit (1) ;\n }",
"private void ending() {\n\t\tstartView.ending();\n\t\tSystem.exit(-1);\n\t}",
"private void exit() {\n this.isRunning = false;\n }",
"public void stop() {\n System.out.println(\"stop\");\n }",
"public void cancelStdInStream() {\n\t\tstdInLatch.countDown();\n\t\tif(pipeOut!=null) {\n\t\t\tlog.debug(\"Closing PipeOut\");\n\t\t\ttry { pipeOut.flush(); } catch (Exception e) {}\n\t\t\ttry { pipeOut.close(); } catch (Exception e) {}\n\t\t\tlog.debug(\"Closed PipeOut\");\n\t\t}\n\t\tpipeOut = null;\n\t\tif(pipeIn!=null) try { \n\t\t\tlog.debug(\"Closing PipeIn\");\n\t\t\tpipeIn.close(); \n\t\t\tlog.debug(\"Closed PipeIn\");\n\t\t} catch (Exception e) {}\n\t\tpipeIn = null;\t\t\n\t}",
"private static void exit()\n {\n System.out.println(\"Graceful exit\");\n System.exit(0);\n }",
"void stopAll();",
"protected void end() {\n\t\tRobot.cubeCollector.setCubeCollector(ControlMode.PercentOutput, 0);\n\n\t}",
"public void cancelarIniciarSesion(){\n System.exit(0);\n }",
"protected void finalizeSystemOut() {}",
"@Override\n public void scanAborted() {\n this.mplLiveData.stopAll();\n this.mplLiveData.emptyPool(); // CKA April 25, 2014\n }",
"private static void exit(){\n\t\t\n\t\tMain.run=false;\n\t\t\n\t}",
"protected void exit() throws IOException {\r\n\t\tstop();\r\n\t\tkeepRunning = false;\r\n\t}",
"@Override\n public void bailOut() {\n debug.println(\"bailOut: called\");\n\n UpdateThread upt = getUpdateThread();\n if (upt != null) upt.endLoop();\n\n // When we are stealing a previous RtDisplay's connection, we don't\n // want to shut it down. The makeRtDisplay() \"steal\" version handles\n // setting this to null.\n if (ss != null)\n ss.close();\n\n timeThread.kill();\n if (audioThread != null)\n audioThread.kill();\n\n setVisible(false);\n\n // inform all the children window that the parent has died (plots/lists)\n for (RtStatusListener i : watchers) {\n i.sourceDied();\n }\n\n // kill the parent frame\n if (parentFrame != null)\n parentFrame.dispose();\n\n // notify the RTDManager that we're dead\n manager.removeDisplay(this);\n }",
"public void silence() {\r\n\t\tif (debugLevel > 1)\r\n\t\t\tSystem.out.println(\" ... silence\");\r\n\t\tif (clip != null && clip.isRunning()) {\r\n\t\t\tclip.stop();\r\n\t\t\tclip = null;\r\n\t\t}\r\n\t}",
"public void stop(){\n return;\n }",
"public void stop() {}",
"private void terminateAnimation() {\n doRun = false;\n }",
"private void onCancel() {\n System.exit(0);\r\n dispose();\r\n }",
"public void cancelExecution() {\n \n \t\tcancelOrKillExecution(true);\n \t}",
"@Override\n public void abort(RuntimeStep exe) {\n }",
"public void stop(){\n quit = true;\n }",
"protected void interrupted() {\n \tRobot.lift.hold();\n \tRobot.debug.Stop();\n }",
"public void stop() {\n\t\texec.stop();\n\t}",
"public void stop() {\n\t\tthis.stopper = true;\n\t}",
"public void cancel() {\r\n\t\tbStop = true;\r\n\t}",
"public void stop() {\n\t\tSystem.out.println(\"结束系统1\");\r\n\t}",
"void cancelEof() {\n\t\tthis.eofSeen = false;\n\t}",
"protected void end() {\r\n motorWithEncoder.disable();\r\n }",
"public void cancel();",
"public void cancel();",
"public void cancel();",
"public void cancel();",
"public void cancel();",
"public void cancel();",
"public boolean doQuit() {\n return false;\n }",
"public void interrupted() {\n\t\taccumulatorController.systems.getAccumulatorMotors().setSpeed(0);\n\t\taccumulatorController.setState(AccumulatorState.IDLE);\n\t}",
"void cancel();",
"void cancel();",
"void cancel();",
"void cancel();",
"void cancel();",
"public void cancel() {\r\n\t\tcanceled = true;\r\n\t\ttry {\r\n\t\t\tThread.sleep(51);\r\n\t\t} catch (InterruptedException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"public void cancel() {\n\t\tinterrupt();\n\t}",
"private boolean no_output() {\n\t\treturn _outcaptures.size() > 0 || _outhides.size() > 0;\n\t}",
"protected void interrupted() {\n\t\tloadLeftBuffer.stop();\n\t\tresetTalon(rightTalon, ControlMode.PercentOutput, 0);\n\t\tresetTalon(leftTalon, ControlMode.PercentOutput, 0);\n\t}",
"protected void end() {\n \tpid.disable();\n }",
"void exit( boolean enabled ) ;",
"@AfterClass\n public static void finalise()\n {\n System.setOut(SYSTEM_OUT_ORIGINAL);\n }",
"public void shutdown()\n {\n this.filter.interrupt();\n this.ui.shutdown();\n }",
"void discard();",
"void discard();",
"@Override\n\tpublic void stopProcessing() {\n\n\t}",
"protected void end() {\n\t\tpid.disable();\n\t}",
"public static void delay(){\n System.out.print(\"\");\r\n System.out.print(\"\");\r\n }",
"public void stop() {\n setClosedLoopControl(false);\n }",
"@After\n\tpublic void backOutput() {\n\t\tSystem.setOut(this.stdout);\n\t}",
"public void quit() {\r\n\t\trunning = false;\r\n\t\tt= null;\r\n\t}",
"public void cancel() {\n\t\tcancel(false);\n\t}",
"@Override\n public void close() {\n try {\n stdIn.write(\"exit;\");\n stdIn.flush();\n } catch (IOException ioe) {\n // ignore\n } finally {\n silentlyCloseStdIn();\n }\n\n stdOut.interrupt();\n stdErr.interrupt();\n shell.destroy();\n }",
"public void discard();",
"void stop() throws IOException;",
"private void stop() {\n\t\tif (null == this.sourceRunner || null == this.channel) {\n\t\t\treturn;\n\t\t}\n\t\tthis.sourceRunner.stop();\n\t\tthis.channel.stop();\n\t\tthis.sinkCounter.stop();\n\t}",
"public void stop() {\n\t\tthis.flag = false;\n\t\t\n\t\t\n\t}",
"public static void exitAll() {\r\n\t\tSystem.exit(0);\r\n\t}",
"public void intakeStop()\n {\n intake_up.set(ControlMode.PercentOutput, 0.0f);\n intake_down.set(ControlMode.PercentOutput, 0.0f);\n }",
"public void stop() {\n\tanimator = null;\n\toffImage = null;\n\toffGraphics = null;\n }",
"public void stopping();",
"public void stop();"
] | [
"0.6863185",
"0.6767065",
"0.6647831",
"0.6617326",
"0.6484687",
"0.6422548",
"0.64141554",
"0.6409144",
"0.6360323",
"0.634652",
"0.6338261",
"0.63227934",
"0.631952",
"0.62413764",
"0.62172395",
"0.61972165",
"0.6162128",
"0.612603",
"0.61126447",
"0.6103961",
"0.60620856",
"0.6059752",
"0.605587",
"0.6045995",
"0.60350573",
"0.6032622",
"0.6011189",
"0.599642",
"0.59953296",
"0.5991064",
"0.59827644",
"0.5962725",
"0.5961962",
"0.5952563",
"0.59511036",
"0.59435904",
"0.5942444",
"0.59399706",
"0.5929936",
"0.5924951",
"0.5918177",
"0.591124",
"0.59094185",
"0.59062916",
"0.5898846",
"0.58914405",
"0.5886658",
"0.58816904",
"0.5881395",
"0.58792186",
"0.5873892",
"0.5868722",
"0.5828276",
"0.58276397",
"0.5826502",
"0.5808453",
"0.58051527",
"0.58029604",
"0.5799418",
"0.5798518",
"0.57930255",
"0.57930255",
"0.57930255",
"0.57930255",
"0.57930255",
"0.57930255",
"0.57883465",
"0.57850105",
"0.57799435",
"0.57799435",
"0.57799435",
"0.57799435",
"0.57799435",
"0.5767653",
"0.5760287",
"0.57552004",
"0.5748689",
"0.5745051",
"0.5742476",
"0.57322836",
"0.572747",
"0.57268363",
"0.57268363",
"0.57218677",
"0.5720502",
"0.5714059",
"0.5709886",
"0.57071394",
"0.5706512",
"0.5705058",
"0.5702053",
"0.5701815",
"0.56996804",
"0.56987864",
"0.56965977",
"0.5695049",
"0.569284",
"0.56908387",
"0.5686315",
"0.56833714"
] | 0.58926386 | 45 |
returns true if output is not being displayed | private boolean no_output() {
return _outcaptures.size() > 0 || _outhides.size() > 0;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"boolean hasOutput();",
"@Override\r\n\tpublic boolean getOutput() {\n\t\treturn false;\r\n\t}",
"public boolean hasOutput() {\n return output_ != null;\n }",
"public boolean getOutput(){\n if (output){\n System.out.println(\"Archivo Cocol/R Aceptado\");\n return true;\n }\n else{\n System.out.println(\"Archivo Cocol/R no aceptado, tiene errores de estructura\");\n return false;\n }\n }",
"public boolean hasOutput() {\n return outputBuilder_ != null || output_ != null;\n }",
"public abstract boolean getOutput();",
"static boolean shouldOutput(Configuration conf) {\n return conf.getBoolean(OUTPUT_FLAG, true);\n }",
"@Override\n public boolean isTerminal() {\n return false;\n }",
"public boolean printOutput(){\n output = \"<html>\";\n output += \"Thank you for your evaluation<br><br>\"; \n output += \"Name: \" + name.getText() + \"<br>\";\n output += \"Matric: \" + matric.getText() + \"<br>\";\n if(code_selection.equals(\"[Select]\") || code.getSelectedItem().equals(\"\") || \n name.getText().equals(\"\") || matric.getText().equals(\"\") || \n rb_selection.equals(\"\") || cb_selection.equals(\"\")){\n \n JOptionPane.showMessageDialog(null, \"All field must be fill, Thank you..\");\n return false;\n }\n output += \"Course: \" + code_selection + \"<br>\";\n output += \"Rating: \" + rb_selection + \"<br>\";\n output += \"Outcome: \" + cb_selection + \"<br>\";\n output += \"</html>\"; \n lbl_output.setText(output);\n jsp.getViewport().revalidate();\n return true;\n }",
"boolean hasDelegatedOutput();",
"public boolean processOutput();",
"boolean hasOutputConfig();",
"@Override\n\tpublic boolean getPrint() {\n\t\treturn false;\n\t}",
"boolean hasOutputPartialsBeforeLanguageDecision();",
"public boolean isterminal() {\n\t\tif(isTerminal)\r\n\t\t\treturn true;\r\n\t\treturn false;\r\n\t}",
"boolean hasOutputParams();",
"public boolean printExecutionTime(){\r\n return false;\r\n }",
"private boolean printing_status() {\n\t\treturn _status_line != null;\n\t}",
"public boolean isNonTerminal(){\n return false;\n }",
"public boolean isCaptureOutput()\r\n\t{\r\n\t\treturn captureOutput;\r\n\t}",
"boolean isDisplay();",
"boolean isDisplay();",
"private boolean exportResult(){\n System.out.println(\"Writing to \" + \"out_\" + inputFile);\n return true;\n }",
"public abstract boolean shouldPrintWorkerString();",
"public boolean getNoDisplay() {\n\t\treturn false;\n\t}",
"@Override\n protected boolean isAppropriate() {\n return true; // always show\n }",
"public boolean wasScriptOutputAnalyzed() {\n return scriptHistory != null && scriptHistory.isOutputAnalyzed();\n }",
"boolean getOutputPartialsBeforeLanguageDecision();",
"public abstract boolean isFileOutput();",
"@Override\n public boolean isExit() {\n return false;\n }",
"@Override\n public boolean isExit() {\n return false;\n }",
"@Override\n public boolean isExit() {\n return false;\n }",
"@Override\n public boolean isExit() {\n return false;\n }",
"@Override\n public boolean isExit() {\n return false;\n }",
"boolean isNoExport();",
"public void showOutput(boolean b) {\n setSelected(shellBot.checkBox(\"Show browser stdout and stderr output\"), b);\n }",
"private boolean noMessage() {\n\t\treturn nbmsg==0;\n\t}",
"public boolean hasDelegatedOutput() {\n return delegatedOutput_ != null;\n }",
"public boolean isMismatchToConsole() {\n return mismatchToConsole;\n }",
"@java.lang.Override\n public boolean getOutputPartialsBeforeLanguageDecision() {\n return outputPartialsBeforeLanguageDecision_;\n }",
"default boolean shouldDisplayPossibleMoves() {\n return false;\n }",
"@java.lang.Override\n public boolean getOutputPartialsBeforeLanguageDecision() {\n return outputPartialsBeforeLanguageDecision_;\n }",
"public void setHideRenderedOutput(boolean hideRenderedOutput) {\r\n this.hideRenderedOutput = hideRenderedOutput;\r\n }",
"private boolean isOutputAsRealMin() {\n return outputAsRealMin;\n }",
"public boolean isQuiet() {\n\t\treturn false;\n\t}",
"public boolean isVerbose() {\n \n // return it\n return showVerboseOutput;\n }",
"@Override\n\tprotected boolean showOpenNFCLog() {\n\t\treturn false;\n\t}",
"private boolean isDisplay(JPiereIADTabpanel tabPanel)\n {\n String logic = tabPanel.getDisplayLogic();\n if (logic != null && logic.length() > 0)\n {\n boolean display = Evaluator.evaluateLogic(tabPanel, logic);\n if (!display)\n {\n log.info(\"Not displayed - \" + logic);\n return false;\n }\n }\n return true;\n }",
"private static boolean showTrinket(Trinket t, OutputType outputType) {\n\t\tswitch (outputType) {\n\t\t\tcase POSSESS:\n\t\t\t\tif (t.count > 0) { return true; }\n\t\t\t\tbreak;\n\t\t\tcase POSSESS_WITH_DUPLICATES:\n\t\t\t\tif (t.count >= MINIMUM_DUPLICATE_NUMBER) { return true; }\n\t\t\t\tbreak;\n\t\t\tcase DO_NOT_POSSESS:\n\t\t\t\tif (t.count == 0) { return true; }\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tbreak;\n\t\t}\n\t\treturn false;\n\t}",
"public boolean isExit() {\n return false;\n }",
"boolean hasConsole();",
"public boolean okToDisplay() {\n return this.mDisplayId == 0 ? !this.mWmService.mDisplayFrozen && this.mWmService.mDisplayEnabled && this.mWmService.mPolicy.isScreenOn() : this.mDisplayInfo.state == 2;\n }",
"protected boolean isFinished()\n\t{\n\t\treturn !Robot.oi.respoolWinch.get();\n\t}",
"public boolean needsProcessing() {\r\n return !INTL_NODE.getOutMarbles().isEmpty();\r\n }",
"@java.lang.Override\n public boolean hasDisplay() {\n return display_ != null;\n }",
"public boolean existsOutputMissingValues(){\r\n\t\treturn anyMissingValue[1];\r\n\t}",
"public abstract boolean terminal();",
"public boolean getHasOutput()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(HASOUTPUT$18, 0);\n if (target == null)\n {\n return false;\n }\n return target.getBooleanValue();\n }\n }",
"private static void prompt(boolean isTestRun) {\n if (!isTestRun)\n System.out.print(\"> \");\n }",
"private final boolean hasBufferedOutputSpace() {\n return !reading && buffer.hasRemaining();\n }",
"public void outputWhyNot ()\n\t{\n\t\toutput (\"\\n> (why-not)\\n\");\n\t\tif (model!=null) model.outputWhyNot();\n\t}",
"private void sentOutputAsRealMin() {\n outputAsRealMin = true;\n }",
"@Test\n\tpublic void testDisplay1() {\n\t\t\n\t\t\n\t\tSystem.setOut(new PrintStream(Actualout));\n\t\t\n\t\tcircularlist.display();\n\t\t\n\t\tassertEquals(\"List : Empty List.\\r\\n\", Actualout.toString());\n\t}",
"private void outputMe() {\n\t\tif (changeCount > 2) changeCount = 4 - (changeCount & 1);\n\t\tif (outputValue) {\n\t\t\tSystem.out.append( trueArray[ changeCount ] );\n\t\t} else {\n\t\t\tSystem.out.append( falseArray[ changeCount ] );\n\t\t}\n\t\tchangeCount = 0;\n\t}",
"public boolean isOut() {\n return out;\n }",
"@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\t\t\n\t}",
"@Override\n public boolean isExit() {\n return true;\n }",
"public boolean isPrintBlankLine()\n\t{\n\t\treturn printBlankLine;\n\t}",
"boolean isQuiet();",
"public boolean printUsedBy() {\n return !matchMajorVersionOnly;\n }",
"void printout() {\n\t\tprintstatus = idle;\n\t\tanyprinted = false;\n\t\tfor (printoldline = printnewline = 1;;) {\n\t\t\tif (printoldline > oldinfo.maxLine) {\n\t\t\t\tnewconsume();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (printnewline > newinfo.maxLine) {\n\t\t\t\toldconsume();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (newinfo.other[printnewline] < 0) {\n\t\t\t\tif (oldinfo.other[printoldline] < 0)\n\t\t\t\t\tshowchange();\n\t\t\t\telse\n\t\t\t\t\tshowinsert();\n\t\t\t} else if (oldinfo.other[printoldline] < 0)\n\t\t\t\tshowdelete();\n\t\t\telse if (blocklen[printoldline] < 0)\n\t\t\t\tskipold();\n\t\t\telse if (oldinfo.other[printoldline] == printnewline)\n\t\t\t\tshowsame();\n\t\t\telse\n\t\t\t\tshowmove();\n\t\t}\n\t\tif (anyprinted == true)\n\t\t\tprintln(\">>>> End of differences.\");\n\t\telse\n\t\t\tprintln(\">>>> Files are identical.\");\n\t}",
"protected boolean isFinished() {\n\t\treturn false;\r\n\t}",
"public boolean lockOutput() {\n return output.setStation(this);\n }",
"protected boolean isFinished() {\r\n\treturn false;\r\n }",
"public boolean visualizeLastGeneration ();",
"private void skipConsoleLine(){\n\t\tSystem.out.println();\n\t}",
"public void ex02() {\n\n boolean hasFinished = false;\n\n\n if (hasFinished==true) {\n printResults();\n }\n\n\n }",
"@Override\r\n\tprotected boolean isFinished() {\n\t\treturn false;\r\n\t}",
"@Override\r\n\tprotected boolean isFinished() {\n\t\treturn false;\r\n\t}",
"protected boolean isFinished() {\n\t\treturn false;\n\t}",
"protected boolean isFinished() {\n\t\treturn false;\n\t}",
"protected boolean isFinished() {\n\t\treturn false;\n\t}",
"protected boolean isFinished() {\n\t\treturn false;\n\t}",
"protected boolean isFinished() {\n\t\treturn false;\n\t}",
"protected boolean isFinished() {\n\t\treturn false;\n\t}",
"public void clearOutput ()\n\t{\n\t\toutputArea.setText (\"\");\n\t}",
"protected boolean isFinished()\n\t{\n\t\treturn false;\n\t}",
"public boolean hasDelegatedOutput() {\n return delegatedOutputBuilder_ != null || delegatedOutput_ != null;\n }",
"public boolean outputText(String incomingText)\n\t{\n\t\ttxtArea.append(\"[\"+getTimeStamp()+\"] \"+ incomingText +\"\\n\");\n\t\tSystem.out.println(\"[\"+getTimeStamp()+\"] \"+ incomingText +\"\\n\");//##testing##\n\t\treturn true;\n\t}",
"public boolean isUsefulReport() {\n if (metadata_ == null) {\n return false;\n }\n return capturedLogContent_ != null && !capturedLogContent_.isEmpty();\n }",
"@Override\r\n\tprotected boolean isFinished() {\r\n\t\treturn false;\r\n\t}",
"@Override\r\n\tprotected boolean isFinished() {\r\n\t\treturn false;\r\n\t}",
"public boolean canDisplay(){\n if(title.isEmpty() && body.isEmpty()){\n return false;\n }\n\n return true;\n }",
"void reportOutput()\n {\n while(state.get().ordinal() < SimulationState.TEARING_DOWN.ordinal())\n {\n FBUtilities.sleepQuietly(csvUpdatePeriodMs);\n doReportOutput(false);\n }\n\n doReportOutput(true);\n }",
"public boolean execDisplay(){\r\n\t\tboolean result = true;\r\n\t\t\r\n\t\tRuntime run = Runtime.getRuntime();\r\n\t\ttry {\r\n\t\t\tProcess p = run.exec(cmdDisplay);\r\n\t\t\t\r\n\t\t\t/**必须要处理外部命令的标准输入输出**/\r\n\t\t\tBufferedInputStream in = new BufferedInputStream(p.getInputStream()); \r\n BufferedReader inBr = new BufferedReader(new InputStreamReader(in)); \r\n String lineStr; \r\n while ((lineStr = inBr.readLine()) != null) \r\n System.out.println(lineStr);\r\n\t\t\t\r\n\t\t\tif(p.waitFor() != 0){\r\n\t\t\t\tresult = false;\r\n\t\t\t}\r\n\t\t}\r\n\t\tcatch (IOException e) {\r\n\t\t\tSystem.out.println(\"IOException when executing display cmd\");\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\tcatch (InterruptedException e) {\r\n\t\t\tSystem.out.println(\"InterruptedException when executing display cmd\");\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t\r\n\t\treturn result;\r\n\t}",
"@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}",
"@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}",
"@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}",
"@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}",
"@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}"
] | [
"0.775425",
"0.74648744",
"0.7278991",
"0.6931494",
"0.6863898",
"0.6726795",
"0.66335267",
"0.6544673",
"0.654414",
"0.6533904",
"0.65247715",
"0.64794654",
"0.6409133",
"0.6401458",
"0.63840944",
"0.6366521",
"0.635726",
"0.6350808",
"0.63453656",
"0.62528384",
"0.6244749",
"0.6244749",
"0.6218748",
"0.6216071",
"0.6204885",
"0.6195749",
"0.6119257",
"0.6112999",
"0.61103714",
"0.6100973",
"0.6100973",
"0.6100973",
"0.6100973",
"0.6100973",
"0.60756874",
"0.6072678",
"0.60378665",
"0.6036693",
"0.6022756",
"0.6013786",
"0.598702",
"0.5985288",
"0.5973222",
"0.59696335",
"0.5964942",
"0.59598607",
"0.59549195",
"0.5946705",
"0.59419405",
"0.5936839",
"0.59354526",
"0.5931217",
"0.59068274",
"0.5905745",
"0.58987004",
"0.5889549",
"0.5880487",
"0.58796906",
"0.5876489",
"0.5876188",
"0.58735615",
"0.586125",
"0.5858477",
"0.5855967",
"0.58484405",
"0.5846119",
"0.58201116",
"0.5819609",
"0.5818927",
"0.5813376",
"0.58133656",
"0.581285",
"0.5811767",
"0.58072203",
"0.5791827",
"0.5775839",
"0.5752188",
"0.5751055",
"0.5751055",
"0.57451767",
"0.57451767",
"0.57451767",
"0.57451767",
"0.57451767",
"0.57451767",
"0.57437986",
"0.57389295",
"0.5727964",
"0.5716196",
"0.5716126",
"0.57152927",
"0.57152927",
"0.5714449",
"0.57144475",
"0.5704344",
"0.56989485",
"0.56989485",
"0.56989485",
"0.56989485",
"0.56989485"
] | 0.8246935 | 0 |
returns true if we're printing the status line | private boolean printing_status() {
return _status_line != null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void printStatus();",
"private void printTestingStatus(final boolean status) {\n this.out.println();\n this.print(\n new If<Text>(\n () -> status,\n () -> new GreenText(\"Testing successful.\"),\n () -> new RedText(\"Testing failed.\")\n ).value().text()\n );\n this.out.println();\n }",
"boolean isSetStatus();",
"StatusLine getStatusLine();",
"public void print_statusline( boolean start, boolean left ) {\n\t\tif ( start ) {\n\t\t\tflush();\n\t\t\t_status_line = new StringBuffer( 10 );\n\t\t\t_status_line.append( _last_printed ); // store this here\n\t\t\treturn;\n\t\t}\n\n\t\t// this always prints to the statusline and is not affected by\n\t\t// outhide() or outcapture()\n\t\tflush();\n\t\t_platform_io.set_status_string( _status_line.toString().substring( 1 ), left );\n\t\t_last_printed = _status_line.charAt( 0 ); // and restore it\n\t\t_status_line = null;\n\t}",
"public boolean isPrintBlankLine()\n\t{\n\t\treturn printBlankLine;\n\t}",
"public boolean isSetStatus() {\n return this.status != null;\n }",
"public boolean isSetStatus() {\n return this.status != null;\n }",
"public boolean isSetStatus() {\n return this.status != null;\n }",
"public boolean isSetStatus() {\n return this.status != null;\n }",
"public boolean isSetStatus() {\n return this.status != null;\n }",
"public void printStatus(){\n System.out.println();\n System.out.println(\"Status: \");\n System.out.println(currentRoom.getLongDescription());\n currentRoom.printItems();\n System.out.println(\"You have made \" + moves + \" moves so far.\");\n }",
"public boolean status(){\n if(this.nbObj == 0)\n {\n try{\n writer.write(\"Stack is empty!\\n\",0,16);\n }\n catch(IOException e){\n printStream.println(\"I/O exception!!!\");\n }\n }\n if(this.nbObj == this.objTab.length)\n {\n try{\n writer.write(\"Stack is full!\\n\",0,15);\n }\n catch(IOException e){\n printStream.println(\"I/O exception!!!\");\n }\n return true;\n }\n return false;\n }",
"public String getStatusLine() {\r\n\t\t\r\n\t\treturn statusLine;\r\n\t\r\n\t}",
"boolean getStatus();",
"boolean getStatus();",
"boolean getStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasStatus();",
"boolean hasExitStatus();",
"private static boolean isStatusOK(StatusLine statusLine) {\n // If the status is 200 (OK) or greater but less than 300 (Multiple Choices) we're good\n return statusLine.getStatusCode() >= HttpStatus.SC_OK\n && statusLine.getStatusCode() < HttpStatus.SC_MULTIPLE_CHOICES;\n }",
"public static boolean presentLine() {\n\t\treturn presentLine(\"\\n\");\n\t}",
"public String showStatus();",
"public boolean isStatus() {\n\t\treturn status;\n\t}",
"public static boolean presentLine (String logMessage) {\n\n\t\t// Add the message if logging is enabled. \n\t\ttry {\n\t\t\tif (logging) {\n\t\t\t\ttrail.append(logMessage + \"\\n\");\n\t\t\t\tSystem.out.println(logMessage);\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\treturn false;\n\t\t}\n\n\t\t// Return whether the logging actually occurred.\n\t\treturn logging;\n\n\t}",
"public boolean isStatus() {\r\n return status;\r\n }",
"public boolean isSprinting ( ) {\n\t\treturn extract ( handle -> handle.isSprinting ( ) );\n\t}",
"public void printStatus() {\n printBranches();\n printAllStages();\n printModified();\n printUntracked();\n }",
"public boolean isStatus() {\n return status;\n }",
"public boolean isStatus() {\n return status;\n }",
"public void printStatus() {\n\t\tSystem.out.println(\"Current : \"+current+\"\\n\"\n\t\t\t\t+ \"Tour restant : \"+nb_rounds+\"\\n\"\n\t\t\t\t\t\t+ \"Troupe restant : \"+nb_to_train);\n\t}",
"public String getStatus() {\n\t\tString result = getName() + \"\\n-----------------------------\\n\\n\";\n\t\tfor(int i = 0; i < lines.size(); i++) {\n\t\t\tresult = result + lines.get(i).getStatus() + \"\\n\";\n\t\t}\n\t\t\n\t\treturn result;\n\t}",
"public boolean getStatus() {\n return status_;\n }",
"public boolean getStatus() {\n return status_;\n }",
"public boolean getStatus() {\n return status_;\n }",
"public boolean getStatus() {\n\t\treturn status;\n\t}",
"public boolean isVerbose() {\n \n // return it\n return showVerboseOutput;\n }",
"public abstract boolean shouldPrintWorkerString();",
"boolean hasConsole();",
"public boolean getStatus(){\r\n\t\treturn status;\r\n\t}",
"public boolean getStatus() {\n return status_;\n }",
"public boolean getStatus() {\n return status_;\n }",
"public boolean getStatus() {\n return status_;\n }",
"public boolean isSetStatusPsw() {\n\t\treturn org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __STATUSPSW_ISSET_ID);\n\t}",
"public boolean getStatus() {\n\treturn status;\n }",
"public boolean isSetStatusname() {\n return this.statusname != null;\n }",
"public boolean isPrintHeader()\n\t{\n\t\treturn printHeader;\n\t}",
"public boolean isTermine() {\n\t\treturn getStatut().equals(StatusBonPreparation.TERMINER);\n\t}",
"public static void printTestStatus(boolean passed) {\n if (passed) {\n System.out.println(\"Test passed!\\n\");\n } else {\n System.out.println(\"Test failed!\\n\");\n }\n }",
"java.lang.String getStatus();",
"java.lang.String getStatus();",
"java.lang.String getStatus();",
"java.lang.String getStatus();",
"public boolean isSprinting(){\n return this.sprint;\n }",
"@DISPID(15)\n\t// = 0xf. The runtime will prefer the VTID if present\n\t@VTID(25)\n\tjava.lang.String status();",
"private String getStatusMessage() {\n\t\treturn (m_isTestPassed == true) ? \" successfully...\" : \" with failures...\";\n\t}",
"public boolean getStatus()\n\t{\n\t\treturn getBooleanIOValue(\"Status\", false);\n\t}",
"public abstract boolean terminal();",
"public boolean isSetStatus() {\n return EncodingUtils.testBit(__isset_bitfield, __STATUS_ISSET_ID);\n }",
"public boolean isSetStatus() {\n return EncodingUtils.testBit(__isset_bitfield, __STATUS_ISSET_ID);\n }",
"@Override\n\tpublic boolean isStatus() {\n\t\treturn _candidate.isStatus();\n\t}",
"public boolean status() {\n return status;\n }",
"public boolean isSetStatus() {\n\t\treturn org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __STATUS_ISSET_ID);\n\t}",
"public StatusLine getStatusLine() {\n return statusLine;\n }",
"String status();",
"String status();",
"public boolean isOutputLine(String line) {\n int count = 0;\n for (int i = 0; i < line.length(); i++) {\n if (line.charAt(i) == '<' || line.charAt(i) == '>') {\n count++;\n }\n }\n if (count == 4) {\n return true;\n }\n return false;\n }",
"public boolean hasStatus() {\n return result.hasStatus();\n }",
"public boolean hasStatus() {\n return result.hasStatus();\n }",
"public boolean hasStatus() {\n return result.hasStatus();\n }",
"public boolean hasStatus() {\n return result.hasStatus();\n }",
"public boolean isterminal() {\n\t\tif(isTerminal)\r\n\t\t\treturn true;\r\n\t\treturn false;\r\n\t}",
"@java.lang.Override\n public boolean hasStatus() {\n return status_ != null;\n }",
"@java.lang.Override\n public boolean hasStatus() {\n return status_ != null;\n }",
"@Override\n\tpublic boolean status() {\n\t\treturn false;\n\t}",
"@Override\n\tpublic boolean status() {\n\t\treturn false;\n\t}",
"public boolean checkStatus() {\r\n return isTiling;\r\n }",
"public boolean hasStatus() {\n return statusBuilder_ != null || status_ != null;\n }",
"public boolean hasStatus() {\n return statusBuilder_ != null || status_ != null;\n }",
"public String getStatusLine() {\n\n StringBuilder builder = new StringBuilder(SL_11_START.length() + 4 + message.length());\n builder.append(SL_11_START).append(code).append(' ').append(message);\n return builder.toString();\n }"
] | [
"0.6997846",
"0.6744095",
"0.66022736",
"0.6567389",
"0.6379448",
"0.6263842",
"0.6225436",
"0.6225436",
"0.6225436",
"0.6225436",
"0.6225436",
"0.6213701",
"0.5997988",
"0.596804",
"0.5961676",
"0.5961676",
"0.5961676",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.59499496",
"0.5937104",
"0.5926195",
"0.58852684",
"0.5855822",
"0.58519137",
"0.57978684",
"0.5788722",
"0.5764131",
"0.5763403",
"0.5760593",
"0.5760593",
"0.57224333",
"0.5713262",
"0.57049423",
"0.57049423",
"0.57049423",
"0.570054",
"0.56891185",
"0.5685149",
"0.56733125",
"0.5630749",
"0.5625619",
"0.5625619",
"0.5625619",
"0.5611739",
"0.5609976",
"0.56090176",
"0.5588332",
"0.55757666",
"0.5559004",
"0.5547851",
"0.5547851",
"0.5547851",
"0.5547851",
"0.5543075",
"0.55384606",
"0.553793",
"0.553006",
"0.55283856",
"0.55280143",
"0.55280143",
"0.5525926",
"0.55235565",
"0.55162066",
"0.55154073",
"0.55116135",
"0.55116135",
"0.5507678",
"0.5489521",
"0.5489521",
"0.5489521",
"0.5489521",
"0.5488022",
"0.5483699",
"0.5483699",
"0.5475239",
"0.5475239",
"0.547009",
"0.5458644",
"0.5458644",
"0.5456048"
] | 0.882086 | 0 |
Gets the next hop IP address of this route entry. | public InetAddress getNextHop() {
return nextHop;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Address getNextHop()\n {\n return (Address)route.get(getHopCount()+1);\n }",
"public IpAddress nextHop() {\n return nextHop;\n }",
"public IPv4Address nextHop(IPv4Address ip){\n\t\tIterator<RouteEntry> it = routeTable.iterator();\n\t\twhile(it.hasNext()){\n\t\t\tRouteEntry r = it.next();\n\t\t\tSubnetUtils.SubnetInfo si = new SubnetUtils(r.dstNet.toString()).getInfo();\n\t\t\tif(si.isInRange(ip.toString()))\n\t\t\t\treturn r.nextHop;\n\t\t}\n\t\treturn null;\n\t}",
"java.lang.String getDestinationIp();",
"public Integer getNextHopAddress(Integer LL3PNetworknumber) {\n\t\tIterator<RouteTableEntry> tableIterator=table.iterator();\n\t\tRouteTableEntry tmp=null;\n\t\t//boolean found=false;\n\t\tInteger nextHop=null;\n\t\twhile(tableIterator.hasNext()){\n\t\t\ttmp=tableIterator.next();\n\t\t\tif (tmp.getNetworkDistancePair().getNetworkNumber().equals(LL3PNetworknumber)){\n\t\t\t\tnextHop=tmp.getNextHOP();\n\t\t\t}\n\t\t}\n\t\treturn nextHop;\n\t }",
"public LinkAddress getInitialLinkAddress() {\n if (mIpConfiguration != null && mIpConfiguration.getStaticIpConfiguration() != null) {\n return mIpConfiguration.getStaticIpConfiguration().ipAddress;\n } else {\n return null;\n }\n }",
"public String getNextMulticastIP() {\n String currentMulticastIP = possibleMulticastIPs[nextMulticastIPIndex];\n nextMulticastIPIndex++;\n return currentMulticastIP;\n }",
"public Ipv6AddressAndPrefixLength getNextHopIpv6GwAddr1Value()\n throws JNCException {\n return (Ipv6AddressAndPrefixLength)getValue(\"next-hop-ipv6-gw-addr1\");\n }",
"public com.vmware.converter.HostIpRouteEntry getRoute() {\r\n return route;\r\n }",
"public int getPreviousHop() {\n return previousHop;\n }",
"public short get_hop() {\n return (short)getUIntElement(offsetBits_hop(), 8);\n }",
"public static int offset_hop() {\n return (48 / 8);\n }",
"public Ipv4AddressAndPrefixLength getNextHopIpv4GwAddr1Value()\n throws JNCException {\n return (Ipv4AddressAndPrefixLength)getValue(\"next-hop-ipv4-gw-addr1\");\n }",
"public int getAddr() {\n return addr_;\n }",
"public int getAddr() {\n return addr_;\n }",
"public int getIp() {\n return instance.getIp();\n }",
"public int getIp() {\n return instance.getIp();\n }",
"public String getIp() {\n return (String) get(24);\n }",
"public int getInIp() {\n return instance.getInIp();\n }",
"public int getInIp() {\n return instance.getInIp();\n }",
"int getNextHopPort(Message next) {\n\t\tif (next instanceof ExchangeMessage) {\n\t\t\tExchange destinationExchange = ((ExchangeMessage)next).getDestination();\n\t\t\treturn getExchangeNextPort(destinationExchange);\n\t\t}\n\t\telse {\n\t\t\tContinent destinationContinent = ((SuperPeerMessage) next).getDestination();\n\t\t\tif (destinationContinent == null) {\n\t\t\t\tSystem.out.println(\"no destination?\");\n\t\t\t\tnext.print();\n\t\t\t}\n\n\t\t\treturn getContinentNextPort(destinationContinent);\n\t\t}\n\t}",
"public Ipv4AddressAndPrefixLength getNextHopIpv4GwAddr2Value()\n throws JNCException {\n return (Ipv4AddressAndPrefixLength)getValue(\"next-hop-ipv4-gw-addr2\");\n }",
"public Ipv6AddressAndPrefixLength getNextHopIpv6GwAddr2Value()\n throws JNCException {\n return (Ipv6AddressAndPrefixLength)getValue(\"next-hop-ipv6-gw-addr2\");\n }",
"public String getIp() {\n return getIpString(inetAddress);\n }",
"public InetAddress getInitialGateway() {\n if (mIpConfiguration != null && mIpConfiguration.getStaticIpConfiguration() != null) {\n return mIpConfiguration.getStaticIpConfiguration().gateway;\n } else {\n return null;\n }\n }",
"public int get_addr() {\n return (int)getUIntElement(offsetBits_addr(), 16);\n }",
"private myPoint getNextRoute(){\n\t\ttry {\n\t\t\treturn this.Route.take();\n\t\t} catch (InterruptedException e) {\n\t\t\treturn null;\n\t\t}\n\t}",
"public int getIp() {\n return ip_;\n }",
"public int getIp() {\n return ip_;\n }",
"public int getIp() {\n return ip_;\n }",
"public int getIp() {\n return ip_;\n }",
"public CrossRoad getNextIntermediateDestination()\n\t{\n\t\treturn this.getHead().getIntermediate();\n\t}",
"public InetAddress getIP();",
"public String destinationIPAddress() {\n return this.destinationIPAddress;\n }",
"public int getInIp() {\n return inIp_;\n }",
"public int getInIp() {\n return inIp_;\n }",
"public java.lang.String getDestinationIp() {\n java.lang.Object ref = destinationIp_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n destinationIp_ = s;\n return s;\n }\n }",
"public Neighbour findNextJump(String destinationIp) {\n if (!isFinalDestination(destinationIp)) {\n Iterator it = routes.entrySet().iterator();\n while (it.hasNext()) {\n Map.Entry<Neighbour, Neighbour> pair = (Map.Entry)it.next();\n if (destinationIp.equals(pair.getKey().getAddress())) {\n return pair.getValue();\n }\n it.remove(); // Avoids a ConcurrentModificationException\n }\n }\n return null;\n }",
"public java.lang.String getDestinationIp() {\n java.lang.Object ref = destinationIp_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n destinationIp_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }",
"public String ipv6LinkLocalAddress() {\n return this.ipv6LinkLocalAddress;\n }",
"public InetAddress getGatewayIPAddress()\n {\n return gatewayIPAddress;\n }",
"private Addr nextPC() {\n if (inDelaySlotQueue()) {\n // Next address\n return currentAddr.inc();\n }\n\n // If there is a jump scheduled, return it\n if (jump != null) {\n var jumpAddr = jump;\n jump = null;\n return jumpAddr;\n }\n\n // Next address\n return currentAddr.inc();\n }",
"int getAddr();",
"int getInIp();",
"int getInIp();",
"public String getIP() {\n return this.IP;\n }",
"public int getSqAnDestination() {\n if (packetHeader == null)\n return PacketHeader.BROADCAST_ADDRESS;\n return packetHeader.getDestination();\n }",
"public String getIPAddress () {\n\t\treturn _ipTextField.getText();\n\t}",
"public String getIpAddress()\n\t{\n\t\t/* TODO: The IP address returned is in this format: /127.0.0.1:9845\n\t\t * Rewrite to remove the unnessecary data. */\n\t\treturn getSession().getIpAddress();\n\t}",
"public int getNextDest() {\n\t\treturn nextDestination;\n\t}",
"int getIp();",
"int getIp();",
"int getIp();",
"public InetAddress getIP()\r\n\r\n {\r\n InetAddress ip=null;\r\n try{\r\n WifiManager wifi = (WifiManager) context.getSystemService(Context.WIFI_SERVICE);\r\n DhcpInfo dhcp = wifi.getDhcpInfo();\r\n int dip=dhcp.ipAddress;\r\n byte[] quads = new byte[4];\r\n for (int k = 0; k < 4; k++)\r\n quads[k] = (byte) (dip >> (k * 8));\r\n ip= InetAddress.getByAddress(quads);\r\n } catch (UnknownHostException e) {\r\n e.printStackTrace();\r\n }\r\n return ip;\r\n }",
"public static String getGateWayIp() {\n try {\n for (Enumeration<NetworkInterface> en = NetworkInterface\n .getNetworkInterfaces(); en.hasMoreElements();) {\n NetworkInterface intf = en.nextElement();\n for (Enumeration<InetAddress> ipAddr = intf.getInetAddresses(); ipAddr\n .hasMoreElements();) {\n InetAddress inetAddress = ipAddr.nextElement();\n if (!inetAddress.isLoopbackAddress()) {\n if (inetAddress.getHostAddress().length() <= 16) {\n return inetAddress.getHostAddress();\n }\n }\n }\n }\n } catch (SocketException ex) {\n ex.printStackTrace();\n } catch (Exception e) {\n e.printStackTrace();\n }\n return \"\";\n }",
"@Nullable\n Inet6Address getAddress();",
"public Integer getDestination() {\n\t\treturn new Integer(destination);\n\t}",
"public String getIPAddress()\n {\n return fIPAddress;\n }",
"public String getIP(Integer nodeID) {\n return this.IPmap.get(nodeID);\n }",
"java.lang.String getIp();",
"java.lang.String getIp();",
"java.lang.String getIp();",
"java.lang.String getIp();",
"java.lang.String getIp();",
"java.lang.String getIp();",
"java.lang.String getIp();",
"java.lang.String getIp();",
"public java.lang.String getIP() {\r\n return IP;\r\n }",
"public Waypoint getNextWaypoint() {\n if (waypoints.isEmpty()) {\n return null;\n } else {\n Waypoint waypoint = waypoints.remove(0);\n return waypoint;\n }\n }",
"public V getDestination() {\r\n\r\n\t\tV result = null;\r\n\t\tif ((counter <= links.size()) && (counter > 0)) {\r\n\t\t\tresult = succNodes.get(counter - 1);\r\n\t\t}\r\n\t\treturn result;\r\n\t}",
"public IPAddress getIPAddress() {\n return iPAddress;\n }",
"java.lang.String getAgentIP();",
"public InetAddress getIPAddress ( ) { return _IPAddress; }",
"public static String getIP() {\n\t\treturn ip;\r\n\t}",
"private int relayPayloadDestination(OverlayNodeSendsData event) {\n\t\tint destination = event.getDestID();\n\t\tif (nodesToSendTo.getConnections().containsKey(destination))\n\t\t\treturn destination;\n\t\telse { // determine which routing entry to send it to\n\t\t\tint bestHopLen = 128;\n\t\t\tint bestHop = 0;\n\t\t\tboolean increasedHopDist = false;\n\t\t\tboolean finalFlag = false;\n\t\t\tif (event.getDestID() < myAssignedID)\n\t\t\t\tdestination += 128; // previously 127\n\t\t\tfor (Map.Entry<Integer, TCPConnection> entry : nodesToSendTo.getConnections()\n\t\t\t\t\t.entrySet()) {\n\t\t\t\tint possibleHop = entry.getKey();\n\t\t\t\tif (possibleHop < myAssignedID) {\n\t\t\t\t\tpossibleHop += 128;\n\t\t\t\t\tincreasedHopDist = true;\n\t\t\t\t} else {\n\t\t\t\t\tincreasedHopDist = false;\n\t\t\t\t}\n\t\t\t\tif (possibleHop < destination\n\t\t\t\t\t\t&& ((destination - possibleHop) < bestHopLen)) {\n\t\t\t\t\tbestHopLen = destination - possibleHop;\n\t\t\t\t\tbestHop = possibleHop;\n\t\t\t\t\tfinalFlag = increasedHopDist;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (finalFlag)\n\t\t\t\tbestHop -= 128;\n\t\t\treturn bestHop;\n\t\t}\n\t}",
"public long getAddress() {\n return origin + originOffset;\n }",
"public InetAddress getIpAddress() \n\t{\n\t\treturn ipAddress;\n\t}",
"public String getRemoteIPAddress() {\n String xForwardedFor = getRequestHeader(\"X-Forwarded-For\");\n\n if (!Utils.isEmpty(xForwardedFor)) {\n System.out.println(\"The xForwardedFor address is: \" + xForwardedFor + \"\\n\");\n return xForwardedFor.split(\"\\\\s*,\\\\s*\", 2)[0]; // The xForwardFor is a comma separated string: client,proxy1,proxy2,...\n }\n\n return getRequest().getRemoteAddr();\n }",
"@Override\n public InetAddress getIp() {\n this.ip =\n maybeHostname\n .map(\n hostname -> {\n try {\n return InetAddress.getByName(hostname);\n } catch (final UnknownHostException e) {\n return ip;\n }\n })\n .orElse(ip);\n return ip;\n }",
"public int getS1Ip() {\n return instance.getS1Ip();\n }",
"public InetAddress getAddress() {\n return ip;\n }",
"public Inet4Address getGatewayAddress() {\n\t\tbyte[] rawGatewayAddr = Arrays.copyOf(subnetAddress.getAddress(), 4);\n\t\trawGatewayAddr[3] = 1;\n\n\t\ttry {\n\t\t\treturn (Inet4Address) Inet4Address.getByAddress(rawGatewayAddr);\n\t\t} catch (UnknownHostException e) {\n\t\t\t//Weird shouldn't happen\n\t\t\te.printStackTrace();\n\t\t\treturn null;\n\t\t}\n\t}",
"public String get_ipaddress() throws Exception {\n\t\treturn this.ipaddress;\n\t}",
"public ForwardedIPConfig getForwardedIPConfig() {\n return this.forwardedIPConfig;\n }",
"com.google.protobuf.ByteString\n getDestinationIpBytes();",
"public void addNextHopIpv6GwAddr1() throws JNCException {\n setLeafValue(Routing.NAMESPACE,\n \"next-hop-ipv6-gw-addr1\",\n null,\n childrenNames());\n }",
"public String startIP() {\n return this.startIP;\n }",
"public IpAddress getIpAddressValue() throws JNCException {\n return (IpAddress)getValue(\"ip-address\");\n }",
"public Integer nextOffset() {\n return this.nextOffset;\n }",
"public InetAddress getSuggestedExternalIpAddress() {\n return suggestedExternalIpAddress;\n }",
"public int getReturnAddressOffset();",
"public static String getServerIP() { return tfJoinIP.getText(); }",
"public Location getNextLocation() {\n\n\t\treturn this.nextLoc;\n\n\t}",
"public java.lang.String getSwitchIpAddress() {\r\n return switchIpAddress;\r\n }",
"public String sourceIPAddress() {\n return this.sourceIPAddress;\n }",
"public Tile getNext(){\n\t\treturn this.next;\n\t}",
"public InetSocketAddress getAddress ( ) {\n\t\treturn extract ( handle -> handle.getAddress ( ) );\n\t}",
"public InetAddress getInetAddress()\n {\n return addr;\n }",
"public String getAddr() {\n\t\treturn addr;\n\t}",
"public void addNextHopIpv4GwAddr1() throws JNCException {\n setLeafValue(Routing.NAMESPACE,\n \"next-hop-ipv4-gw-addr1\",\n null,\n childrenNames());\n }"
] | [
"0.7842046",
"0.75475824",
"0.68794423",
"0.6100319",
"0.6045413",
"0.6040402",
"0.5988154",
"0.5974946",
"0.5933811",
"0.593037",
"0.5914276",
"0.59010935",
"0.5892044",
"0.58215433",
"0.579115",
"0.57416993",
"0.57416993",
"0.5711695",
"0.569022",
"0.569022",
"0.56850725",
"0.56779546",
"0.5627656",
"0.55962807",
"0.558951",
"0.557088",
"0.5544917",
"0.55358076",
"0.5534879",
"0.5534879",
"0.5534879",
"0.553454",
"0.55263233",
"0.55098367",
"0.55021924",
"0.55021924",
"0.5490587",
"0.5480329",
"0.5477433",
"0.5446725",
"0.5434989",
"0.5416053",
"0.54032797",
"0.5390008",
"0.5390008",
"0.53702277",
"0.536746",
"0.53659844",
"0.5359204",
"0.53497213",
"0.5336294",
"0.5336294",
"0.5336294",
"0.5318128",
"0.53066367",
"0.53016543",
"0.5299878",
"0.5295299",
"0.52930725",
"0.5288531",
"0.5288531",
"0.5288531",
"0.5288531",
"0.5288531",
"0.5288531",
"0.5288531",
"0.5288531",
"0.5286498",
"0.52828896",
"0.52732575",
"0.5271727",
"0.52673244",
"0.5265203",
"0.52532184",
"0.52500516",
"0.5249312",
"0.5248579",
"0.5238137",
"0.5235639",
"0.52027166",
"0.5199121",
"0.51732886",
"0.517321",
"0.5172861",
"0.516652",
"0.51518965",
"0.5149496",
"0.51385206",
"0.5137607",
"0.51348853",
"0.5134848",
"0.51333845",
"0.51309776",
"0.512264",
"0.5105819",
"0.50947225",
"0.5092135",
"0.50912416",
"0.5090717",
"0.5086841"
] | 0.77845067 | 1 |
Gets the sysuptime parameter sent with the update from BGPd. | public long getSysUpTime() {
return sysUpTime;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"final public long getSysUpTime() {\n return sysUpTime ;\n }",
"public int getUptime() {\n return (int) _uptime;\n }",
"public long getUptime() {\n return uptime;\n }",
"public long getUptime() {\n\t\treturn System.currentTimeMillis()-uptime;\n\t}",
"public abstract long getUptime();",
"private long getSystemTime() {\n ThreadMXBean bean = ManagementFactory.getThreadMXBean();\n return bean.isCurrentThreadCpuTimeSupported() ? (bean.getCurrentThreadCpuTime() - bean.getCurrentThreadUserTime()) : 0L;\n }",
"@GET\n @Produces(MediaType.TEXT_PLAIN)\n public String calculateUptime() {\n return this.calculateUptime(99.95);\n }",
"public int getUpSeconds() {\n return (int)((_uptime % 60000) / 1000);\n }",
"public static long getSystemTime( ) {\n ThreadMXBean bean = ManagementFactory.getThreadMXBean( );\n return bean.isCurrentThreadCpuTimeSupported( ) ?\n (bean.getCurrentThreadCpuTime( ) - bean.getCurrentThreadUserTime( )) : 0L;\n\n }",
"public static long getSystemTime () {\n\n ThreadMXBean bean = ManagementFactory.getThreadMXBean();\n return bean.isCurrentThreadCpuTimeSupported()?\n (bean.getCurrentThreadCpuTime() - bean.getCurrentThreadUserTime()): 0L;\n }",
"public long getSystemTime( ) {\n ThreadMXBean bean = ManagementFactory.getThreadMXBean( );\n return bean.isCurrentThreadCpuTimeSupported( ) ?\n (bean.getCurrentThreadCpuTime( ) - bean.getCurrentThreadUserTime( )) : 0L;\n}",
"final public synchronized SnmpTimeticks getTimeTicks() {\n if (uptimeCache == null)\n uptimeCache = new SnmpTimeticks((int)sysUpTime) ;\n return uptimeCache ;\n }",
"public int getSystemTime() {\n\t\treturn this.systemTime;\n\t}",
"public void setUptime(long uptime) {\n this.uptime = uptime;\n }",
"public int getUpMinutes() {\n return (int)((_uptime % 3600000) / 60000);\n }",
"public double getSystemTimeSec() {\n\treturn getSystemTime() / Math.pow(10, 9);\n}",
"public synchronized int getUPS() {\n return ups;\n }",
"private long getAppProcessTime(int pid) {\n FileInputStream in = null;\n String ret = null;\n try {\n in = new FileInputStream(\"/proc/\" + pid + \"/stat\");\n byte[] buffer = new byte[1024];\n ByteArrayOutputStream os = new ByteArrayOutputStream();\n int len = 0;\n while ((len = in.read(buffer)) != -1) {\n os.write(buffer, 0, len);\n }\n ret = os.toString();\n os.close();\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n } catch (IOException e) {\n e.printStackTrace();\n } finally {\n if (in != null) {\n try {\n in.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n\n if (ret == null) {\n return 0;\n }\n\n String[] s = ret.split(\" \");\n if (s == null || s.length < 17) {\n return 0;\n }\n\n long utime = string2Long(s[13]);\n long stime = string2Long(s[14]);\n long cutime = string2Long(s[15]);\n long cstime = string2Long(s[16]);\n\n return utime + stime + cutime + cstime;\n }",
"private long getAppProcessTime(int pid) {\n FileInputStream in = null;\n String ret = null;\n try {\n in = new FileInputStream(\"/proc/\" + pid + \"/stat\");\n byte[] buffer = new byte[1024];\n ByteArrayOutputStream os = new ByteArrayOutputStream();\n int len = 0;\n while ((len = in.read(buffer)) != -1) {\n os.write(buffer, 0, len);\n }\n ret = os.toString();\n os.close();\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n } catch (IOException e) {\n e.printStackTrace();\n } finally {\n if (in != null) {\n try {\n in.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n\n if (ret == null) {\n return 0;\n }\n\n String[] s = ret.split(\" \");\n if (s == null || s.length < 17) {\n return 0;\n }\n\n long utime = string2Long(s[13]);\n long stime = string2Long(s[14]);\n long cutime = string2Long(s[15]);\n long cstime = string2Long(s[16]);\n\n return utime + stime + cutime + cstime;\n }",
"public java.lang.String getSystemlogtime () {\n\t\treturn systemlogtime;\n\t}",
"public String getUpdatetime() {\n\t\treturn updatetime;\n\t}",
"public String getUpdatetime() {\n\t\treturn updatetime;\n\t}",
"private long getSleepTime()\n {\n return sleepTime;\n }",
"private long getUserTime() {\n ThreadMXBean bean = ManagementFactory.getThreadMXBean();\n return bean.isCurrentThreadCpuTimeSupported() ? bean.getCurrentThreadUserTime() : 0L;\n }",
"public int getUpDays() {\n return (int)(_uptime / 86400000);\n }",
"public int getwaitTime(){\r\n\t\t String temp=rb.getProperty(\"waitTime\");\r\n\t\t return Integer.parseInt(temp);\r\n\t}",
"public long getJVMCpuTime( ) {\n OperatingSystemMXBean bean =\n ManagementFactory.getOperatingSystemMXBean( );\n if ( ! (bean instanceof\n com.sun.management.OperatingSystemMXBean) )\n return 0L;\n return ((com.sun.management.OperatingSystemMXBean)bean)\n .getProcessCpuTime( );\n}",
"long getTsUpdate();",
"@Override\n protected String exec(HashMap<String, String> params) {\n return Math.round(poller.getTps() * 100) / 100.0 + \"\";\n }",
"public static long getUserTime( ) {\n ThreadMXBean bean = ManagementFactory.getThreadMXBean( );\n return bean.isCurrentThreadCpuTimeSupported( ) ?\n bean.getCurrentThreadUserTime( ) : 0L;\n }",
"private double pingGetLatency(){\n\t\t int NUMBER_OF_PACKTETS=10;\n\t String pingCommand = \"/system/bin/ping -c \" + NUMBER_OF_PACKTETS + \" \" + ip;\n\t String inputLine = \"\";\n\t double avgRtt = 0;\n\n\t try {\n\t // execute the command on the environment interface\n\t Process process = Runtime.getRuntime().exec(pingCommand);\n\t // gets the input stream to get the output of the executed command\n\t BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(process.getInputStream()));\n\n\t inputLine = bufferedReader.readLine();\n\t while ((inputLine != null)) {\n\t if (inputLine.length() > 0 && inputLine.contains(\"avg\")) { // when we get to the last line of executed ping command\n\t break;\n\t }\n//\t \t if (inputLine.length()>0) inputLine = bufferedReader.readLine();\n\t inputLine = bufferedReader.readLine();\n\t }\n\t }\n\t catch (IOException e){\n\t \t pingParameters=\"Error in ping\";\n\t e.printStackTrace();\n\t }\n\n\t // Extracting the average round trip time from the inputLine string\n\t String afterEqual = inputLine.substring(inputLine.indexOf(\"=\"), inputLine.length()).trim();\n\t String afterFirstSlash = afterEqual.substring(afterEqual.indexOf('/') + 1, afterEqual.length()).trim();\n\t String strAvgRtt = afterFirstSlash.substring(0, afterFirstSlash.indexOf('/'));\n\t avgRtt = Double.valueOf(strAvgRtt);\n\t pingParameters=inputLine;\n\t return avgRtt;\n\t }",
"public String getUpdateUserip() {\r\n\t\treturn updateUserip;\r\n\t}",
"public java.lang.Long getTsUpdate() {\n return ts_update;\n }",
"public String getUpdTime() {\n return updTime;\n }",
"@MavlinkFieldInfo(\n position = 1,\n unitSize = 4,\n description = \"Timestamp (time since system boot).\"\n )\n public final long timeBootMs() {\n return this.timeBootMs;\n }",
"public static long getUserTime () {\n\n ThreadMXBean bean = ManagementFactory.getThreadMXBean();\n return bean.isCurrentThreadCpuTimeSupported()?\n bean.getCurrentThreadUserTime(): 0L;\n }",
"public long getUserTime( ) {\n ThreadMXBean bean = ManagementFactory.getThreadMXBean( );\n return bean.isCurrentThreadCpuTimeSupported( ) ?\n bean.getCurrentThreadUserTime( ) : 0L;\n}",
"public long getSleepTime() {\n return sleepTime;\n }",
"public java.lang.Long getTsUpdate() {\n return ts_update;\n }",
"final public String toString() {\n StringBuffer buf = new StringBuffer() ;\n buf.append(\"{SysUpTime = \" + SnmpTimeticks.printTimeTicks(sysUpTime)) ;\n buf.append(\"} {Timestamp = \" + getDate().toString() + \"}\") ;\n return buf.toString() ;\n }",
"public YangUInt8 getRequestTimerValue() throws JNCException {\n YangUInt8 requestTimer = (YangUInt8)getValue(\"request-timer\");\n if (requestTimer == null) {\n requestTimer = new YangUInt8(\"5\"); // default\n }\n return requestTimer;\n }",
"public Integer getUpdateDateMachine() {\r\n return updateDateMachine;\r\n }",
"protected Color getUptimeColor() {\n\t\tfinal long uptime = System.currentTimeMillis()\n\t\t\t\t- Activator.getDefault().getStartTime();\n\t\tif (uptime < 7200000)\n\t\t\treturn display.getSystemColor(SWT.COLOR_DARK_GREEN);\n\t\telse if (uptime < 14400000)\n\t\t\treturn display.getSystemColor(SWT.COLOR_BLUE);\n\t\telse\n\t\t\treturn display.getSystemColor(SWT.COLOR_RED);\n\t}",
"@Override\r\n\tpublic String gettime() {\n\t\treturn user.gettime();\r\n\t}",
"public void doSyncUptime() {\n long timestamp = System.nanoTime();\n uptime += timestamp - lastUptimeSyncTimestamp;\n lastUptimeSyncTimestamp = timestamp;\n lastCpuTimeSyncTimestamp = cpu.getTime();\n long uptimeCpuTimeDifference = getCpuTimeNanos() - uptime;\n uptimeCpuTimeDifference = (uptimeCpuTimeDifference > 0) ? uptimeCpuTimeDifference : 1L;\n long uptimeCpuTimeDifferenceMillis = uptimeCpuTimeDifference / NANOSECS_IN_MSEC;\n int uptimeCpuTimeDifferenceNanos = (int) (uptimeCpuTimeDifference % NANOSECS_IN_MSEC);\n try {\n this.wait(uptimeCpuTimeDifferenceMillis, uptimeCpuTimeDifferenceNanos);\n } catch (InterruptedException e) {\n }\n }",
"public String getCurrentThreadTimeInfo() {\n\t\t\n\t\tStringBuffer sb = new StringBuffer();\n\t\tThreadMXBean bean = ManagementFactory.getThreadMXBean();\n\t\tif(!bean.isCurrentThreadCpuTimeSupported())\n\t\t\treturn timeInfo;\n\t\tlong userTime = bean.getCurrentThreadUserTime();\n\t\tlong cpuTime = bean.getCurrentThreadCpuTime();\n\n\t\tsb.append(userTime).append(\"#\").append(cpuTime);\n\t\ttimeInfo = sb.toString();\n//\t\tSystem.out.println(\"lib: \" + timeInfo);\n\t\treturn timeInfo;\n\t}",
"public long getTsUpdate() {\n return tsUpdate_;\n }",
"public int getUpHours() {\n return (int)((_uptime % 86400000) / 3600000);\n }",
"public String privilegedProcessorTime() {\n return this.privilegedProcessorTime;\n }",
"public long getCurrentSystemTime() {\n return getSystemTime() - startSystemTimeNano;\n }",
"public double getUpdateWaitDuration()\r\n {\r\n return updateWait;\r\n }",
"public static int getSleepTime()\n {\n int result = SLEEP_TIME;\n SLEEP_TIME += SLEEP_TIME_INTERVAL;\n if (SLEEP_TIME > SLEEP_TIME_MAX)\n {\n SLEEP_TIME = 0;\n }\n return result;\n }",
"@MavlinkFieldInfo(\n position = 1,\n unitSize = 8,\n description = \"Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.\"\n )\n public final BigInteger timeUsec() {\n return this.timeUsec;\n }",
"public long getTsUpdate() {\n return tsUpdate_;\n }",
"public String getSystemdatum() {\n\t\treturn systemdatum;\n\t}",
"int getCPU_time();",
"@Override\n public java.lang.Number getDisplayUpdateInterval() throws G2AccessException {\n java.lang.Object retnValue = getAttributeValue (SystemAttributeSymbols.DISPLAY_UPDATE_INTERVAL_);\n return (java.lang.Number)retnValue;\n }",
"public Date getUpdatetime() {\r\n return updatetime;\r\n }",
"public long getCurrentThreadKernelTime() {\n\t\tThreadMXBean bean = ManagementFactory.getThreadMXBean();\n\t\treturn bean.isCurrentThreadCpuTimeSupported() ? bean.getCurrentThreadCpuTime() - bean.getCurrentThreadUserTime() : -1L;\n\t}",
"String getSwstatus();",
"public double getUserTimeSec() {\n\treturn getUserTime() / Math.pow(10, 9);\n}",
"public Date getUpdatetime() {\n return updatetime;\n }",
"public Date getUpdatetime() {\n return updatetime;\n }",
"public Float getSysGsmSucc() {\r\n return sysGsmSucc;\r\n }",
"@CheckForNull\n GlobalUpdateStatus getUpdateStatus();",
"public String getSystemVer() {\n return systemVer;\n }",
"protected long parseAvailabilityTimeOffsetUs(\n XmlPullParser xpp, long parentAvailabilityTimeOffsetUs) {\n String value = xpp.getAttributeValue(/* namespace= */ null, \"availabilityTimeOffset\");\n if (value == null) {\n return parentAvailabilityTimeOffsetUs;\n }\n if (\"INF\".equals(value)) {\n return Long.MAX_VALUE;\n }\n return (long) (Float.parseFloat(value) * C.MICROS_PER_SECOND);\n }",
"public String determinePing(String ip) {\r\n if(ip.isEmpty()) {\r\n System.out.println(\"PING NOT AVAILABLE\");\r\n ping = \"Not Available\";\r\n return ping;\r\n }\r\n \r\n String command = \"ping \" + ip;\r\n\r\n try{\r\n Process proc = Runtime.getRuntime().exec(command);\r\n BufferedReader input = new BufferedReader(new InputStreamReader(proc.getInputStream()));\r\n String line;\r\n while((line = input.readLine()) != null) {\r\n if(line.length() > 0 && line.contains(\"time=\")) {\r\n System.out.println(line);\r\n input.close();\r\n String timeString = line.substring(line.indexOf(\"time\"));\r\n String time = timeString.substring(timeString.indexOf(\"=\") + 1, timeString.indexOf(\"ms\") + 2);\r\n ping = time;\r\n return ping;\r\n }\r\n }\r\n }\r\n catch(Exception e){\r\n System.out.println(e);\r\n }\r\n\r\n return \"SERVERS ON FIRE\";\r\n }",
"public double getCpuTimeSec() {\n\treturn getCpuTime() / Math.pow(10, 9);\t\t\n}",
"public String getTimeToLiveSeconds() {\n return timeToLiveSeconds+\"\";\n }",
"@Override\n\tpublic int getGraphRefreshMinute() {\n\t\ttry {\n\t\t\tProperties p = new Properties();\n\t\t\tInputStream is=this.getClass().getResourceAsStream(\"/system.properties\"); \n\t\t\tp.load(is); \n\t\t\tis.close();\n\t\t\treturn Integer.parseInt(p.getProperty(\"graph_refresh_millisecond\"));\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t\treturn 0;\n\t\t}\n\t}",
"@java.lang.Override\n public long getUpdateIntervalInSec() {\n return updateIntervalInSec_;\n }",
"public Date getUpdate_time() {\n return update_time;\n }",
"public Date getUpdate_time() {\n return update_time;\n }",
"public static String getGTSVersion()\n {\n return SystemProps.getGTSVersion(\"\");\n }",
"String getSleepTime(long totalSleepTime) {\n\t\tString sleep = String.format(\"%d hr(s), %d min(s)\", \n\t\t\t TimeUnit.MILLISECONDS.toHours(totalSleepTime),\n\t\t\t (TimeUnit.MILLISECONDS.toMinutes(totalSleepTime) - \n\t\t\t TimeUnit.HOURS.toMinutes(TimeUnit.MILLISECONDS.toHours(totalSleepTime)))\n\t\t\t);\n\t\treturn sleep;\n\t}",
"private static int getAjaxLoadWaitTime()\n\t{\n\t\tString ajaxLoadWaitTime = System.getProperty(AJAX_LOAD_TIME_KEY);\n\t\t\n\t\tif (ajaxLoadWaitTime == null || ajaxLoadWaitTime.isEmpty())\n\t\t{ \n\t\t\treturn ajaxWaitDefaultTime;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn Integer.parseInt(ajaxLoadWaitTime);\n\t\t}\n\t}",
"public long getSystemStartTime() {\n return (this.systemStartTime);\n }",
"public Integer getUpdateTime() {\n return updateTime;\n }",
"int getSchedulingValue();",
"@java.lang.Override\n public long getUpdateIntervalInSec() {\n return updateIntervalInSec_;\n }",
"public long get_infos_timestamp() {\n return (long)getUIntBEElement(offsetBits_infos_timestamp(), 32);\n }",
"@Override\n\tpublic Long getDownTime(String ip, Integer port) throws Exception {\n\t\treturn null;\n\t}",
"public String userProcessorTime() {\n return this.userProcessorTime;\n }",
"java.lang.String getServerTime();",
"private long getCpuTime() {\n ThreadMXBean bean = ManagementFactory.getThreadMXBean();\n return bean.isCurrentThreadCpuTimeSupported() ? bean.getCurrentThreadCpuTime() : 0L;\n }",
"public Number getLastUpdateLogin()\n {\n return (Number)getAttributeInternal(LASTUPDATELOGIN);\n }",
"private double getSystemCallStatistics()\n {\n return(-1);\n }",
"public int getBungeePingInterval() {\n return getInt(\"bungee-ping-interval\", 60);\n }",
"public static String getDMTPVersion()\n {\n return SystemProps.getDMTPVersion(\"\");\n }",
"public long getInformationSystem() {\n return informationSystem;\n }",
"protected double NetworkServiceTime()\r\n\t{\r\n\t\treturn 25.0;\r\n\t}",
"private float getCpuUsage() {\n\t\tString processName = ManagementFactory.getRuntimeMXBean().getName();\n\t\tString processId = processName.split(\"@\")[0];\n\n\t\tlong utimeBefore, utimeAfter, totalBefore, totalAfter;\n\t\tfloat usage = 0;\n\t\ttry {\n\t\t\tBufferedReader br = new BufferedReader(new FileReader(\"/proc/\" + processId + \"/stat\"));\n\t\t\tString line = br.readLine();\n\t\t\tutimeBefore = Long.parseLong(line.split(\" \")[13]);\n\t\t\tbr.close();\n\n\t\t\ttotalBefore = 0;\n\t\t\tbr = new BufferedReader(new FileReader(\"/proc/stat\"));\n\t\t\tline = br.readLine();\n\t\t\twhile (line != null) {\n\t\t\t\tString[] items = line.split(\" \");\n\t\t\t\tif (items[0].equals(\"cpu\")) {\n\t\t\t\t\tfor (int i = 1; i < items.length; i++)\n\t\t\t\t\t\tif (!items[i].trim().equals(\"\") && items[i].matches(\"[0-9]*\"))\n\t\t\t\t\t\t\ttotalBefore += Long.parseLong(items[i]);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tbr.close();\n\n\t\t\tThread.sleep(1000);\n\n\t\t\tbr = new BufferedReader(new FileReader(\"/proc/\" + processId + \"/stat\"));\n\t\t\tline = br.readLine();\n\t\t\tutimeAfter = Long.parseLong(line.split(\" \")[13]);\n\t\t\tbr.close();\n\n\t\t\ttotalAfter = 0;\n\t\t\tbr = new BufferedReader(new FileReader(\"/proc/stat\"));\n\t\t\tline = br.readLine();\n\t\t\twhile (line != null) {\n\t\t\t\tString[] items = line.split(\" \");\n\t\t\t\tif (items[0].equals(\"cpu\")) {\n\t\t\t\t\tfor (int i = 1; i < items.length; i++)\n\t\t\t\t\t\tif (!items[i].trim().equals(\"\") && items[i].matches(\"[0-9]*\"))\n\t\t\t\t\t\t\ttotalAfter += Long.parseLong(items[i]);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tbr.close();\n\n\t\t\tusage = 100f * (utimeAfter - utimeBefore) / (totalAfter - totalBefore);\n\t\t} catch (Exception e) {}\n\t\treturn usage;\n\t}",
"@Override\n\tpublic String getUsedWalltime() {\n\t\treturn model.getUsedWalltime();\n\t}",
"public long getSleeping() { return sleeping; }",
"public String getSystem() {\r\n return this.system;\r\n }",
"public long getCurrentThreadUserTime() {\n\t\tThreadMXBean bean = ManagementFactory.getThreadMXBean();\n\t\treturn bean.isCurrentThreadCpuTimeSupported() ? bean.getCurrentThreadUserTime() : -1L;\n\t}",
"public String getLastUpdTime() {\n return lastUpdTime;\n }",
"public void processAppBatteryUsage() {\n create();\n\n SensorManager sensorManager = (SensorManager) mContext\n .getSystemService(Context.SENSOR_SERVICE);\n final int which = mStatsType;\n final int speedSteps = mPowerProfile.getNumSpeedSteps();\n final double[] powerCpuNormal = new double[speedSteps];\n final long[] cpuSpeedStepTimes = new long[speedSteps];\n for (int p = 0; p < speedSteps; p++) {\n powerCpuNormal[p] = mPowerProfile.getAveragePower(PowerProfile.POWER_CPU_ACTIVE, p);\n }\n final double averageCostPerByte = getAverageDataCost();\n long uSecTime = mStats.computeBatteryRealtime(SystemClock.elapsedRealtime() * 1000, which);\n long appWakelockTime = 0;\n // BatterySipper osApp = null;\n mStatsPeriod = uSecTime;\n SparseArray<? extends Uid> uidStats = mStats.getUidStats();\n final int NU = uidStats.size();\n for (int iu = 0; iu < NU; iu++) {\n Uid u = uidStats.valueAt(iu);\n double power = 0;\n double highestDrain = 0;\n String packageWithHighestDrain = null;\n //mUsageList.add(new AppUsage(u.getUid(), new double[] {power}));\n Map<String, ? extends BatteryStats.Uid.Proc> processStats = u.getProcessStats();\n long cpuTime = 0;\n long cpuFgTime = 0;\n long wakelockTime = 0;\n long gpsTime = 0;\n if (processStats.size() > 0) {\n // Process CPU time\n for (Map.Entry<String, ? extends BatteryStats.Uid.Proc> ent : processStats\n .entrySet()) {\n Log.print(\"Process name = \" + ent.getKey());\n Uid.Proc ps = ent.getValue();\n final long userTime = ps.getUserTime(which);\n final long systemTime = ps.getSystemTime(which);\n final long foregroundTime = ps.getForegroundTime(which);\n cpuFgTime += foregroundTime * 10; // convert to millis\n final long tmpCpuTime = (userTime + systemTime) * 10; // convert to millis\n int totalTimeAtSpeeds = 0;\n // Get the total first\n for (int step = 0; step < speedSteps; step++) {\n cpuSpeedStepTimes[step] = ps.getTimeAtCpuSpeedStep(step, which);\n totalTimeAtSpeeds += cpuSpeedStepTimes[step];\n }\n if (totalTimeAtSpeeds == 0)\n totalTimeAtSpeeds = 1;\n // Then compute the ratio of time spent at each speed\n double processPower = 0;\n for (int step = 0; step < speedSteps; step++) {\n double ratio = (double) cpuSpeedStepTimes[step] / totalTimeAtSpeeds;\n processPower += ratio * tmpCpuTime * powerCpuNormal[step];\n }\n cpuTime += tmpCpuTime;\n power += processPower;\n if (packageWithHighestDrain == null || packageWithHighestDrain.startsWith(\"*\")) {\n highestDrain = processPower;\n packageWithHighestDrain = ent.getKey();\n } else if (highestDrain < processPower && !ent.getKey().startsWith(\"*\")) {\n highestDrain = processPower;\n packageWithHighestDrain = ent.getKey();\n }\n }\n Log.print(\"Max drain of \" + highestDrain + \" by \" + packageWithHighestDrain);\n }\n if (cpuFgTime > cpuTime) {\n if (cpuFgTime > cpuTime + 10000) {\n Log.print(\"WARNING! Cputime is more than 10 seconds behind Foreground time\");\n }\n cpuTime = cpuFgTime; // Statistics may not have been gathered yet.\n }\n power /= 1000;\n\n // Process wake lock usage\n Map<String, ? extends BatteryStats.Uid.Wakelock> wakelockStats = u.getWakelockStats();\n for (Map.Entry<String, ? extends BatteryStats.Uid.Wakelock> wakelockEntry : wakelockStats\n .entrySet()) {\n Uid.Wakelock wakelock = wakelockEntry.getValue();\n // Only care about partial wake locks since full wake locks\n // are canceled when the user turns the screen off.\n BatteryStats.Timer timer = wakelock.getWakeTime(BatteryStats.WAKE_TYPE_PARTIAL);\n if (timer != null) {\n wakelockTime += timer.getTotalTimeLocked(uSecTime, which);\n }\n }\n wakelockTime /= 1000; // convert to millis\n appWakelockTime += wakelockTime;\n\n // Add cost of holding a wake lock\n power += (wakelockTime * mPowerProfile.getAveragePower(PowerProfile.POWER_CPU_AWAKE)) / 1000;\n\n // Add cost of data traffic\n long tcpBytesReceived = u.getTcpBytesReceived(mStatsType);\n long tcpBytesSent = u.getTcpBytesSent(mStatsType);\n power += (tcpBytesReceived + tcpBytesSent) * averageCostPerByte;\n\n // Add cost of keeping WIFI running.\n long wifiRunningTimeMs = u.getWifiRunningTime(uSecTime, which) / 1000;\n mAppWifiRunning += wifiRunningTimeMs;\n power += (wifiRunningTimeMs * mPowerProfile.getAveragePower(PowerProfile.POWER_WIFI_ON)) / 1000;\n\n // Process Sensor usage\n Map<Integer, ? extends BatteryStats.Uid.Sensor> sensorStats = u.getSensorStats();\n for (Map.Entry<Integer, ? extends BatteryStats.Uid.Sensor> sensorEntry : sensorStats\n .entrySet()) {\n Uid.Sensor sensor = sensorEntry.getValue();\n int sensorType = sensor.getHandle();\n BatteryStats.Timer timer = sensor.getSensorTime();\n long sensorTime = timer.getTotalTimeLocked(uSecTime, which) / 1000;\n double multiplier = 0;\n switch (sensorType) {\n case Uid.Sensor.GPS:\n multiplier = mPowerProfile.getAveragePower(PowerProfile.POWER_GPS_ON);\n gpsTime = sensorTime;\n break;\n default:\n android.hardware.Sensor sensorData = sensorManager.getDefaultSensor(sensorType);\n if (sensorData != null) {\n multiplier = sensorData.getPower();\n Log.print(\"Got sensor \" + sensorData.getName() + \" with power = \"\n + multiplier);\n }\n }\n power += (multiplier * sensorTime) / 1000;\n }\n\n // Log.print(\"UID \" + u.getUid() + \": power=\" + power);\n Log.print(\"PACKAGE \" + packageWithHighestDrain + \": power=\" + power);\n\n // // Add the app to the list if it is consuming power\n // if (power != 0 || u.getUid() == 0) {\n // BatterySipper app = new BatterySipper(getActivity(), mRequestQueue, mHandler,\n // packageWithHighestDrain, DrainType.APP, 0, u,\n // new double[] {power});\n // app.cpuTime = cpuTime;\n // app.gpsTime = gpsTime;\n // app.wifiRunningTime = wifiRunningTimeMs;\n // app.cpuFgTime = cpuFgTime;\n // app.wakeLockTime = wakelockTime;\n // app.tcpBytesReceived = tcpBytesReceived;\n // app.tcpBytesSent = tcpBytesSent;\n // if (u.getUid() == Process.WIFI_UID) {\n // mWifiSippers.add(app);\n // } else if (u.getUid() == Process.BLUETOOTH_GID) {\n // mBluetoothSippers.add(app);\n // } else {\n // mUsageList.add(app);\n // }\n // if (u.getUid() == 0) {\n // osApp = app;\n // }\n // }\n // if (u.getUid() == Process.WIFI_UID) {\n // mWifiPower += power;\n // } else if (u.getUid() == Process.BLUETOOTH_GID) {\n // mBluetoothPower += power;\n // } else {\n // if (power > mMaxPower) mMaxPower = power;\n // mTotalPower += power;\n // }\n // if (DEBUG) Log.i(TAG, \"Added power = \" + power);\n }\n\n // The device has probably been awake for longer than the screen on\n // time and application wake lock time would account for. Assign\n // this remainder to the OS, if possible.\n // if (osApp != null) {\n // long wakeTimeMillis = mStats.computeBatteryUptime(\n // SystemClock.uptimeMillis() * 1000, which) / 1000;\n // wakeTimeMillis -= appWakelockTime - (mStats.getScreenOnTime(\n // SystemClock.elapsedRealtime(), which) / 1000);\n // if (wakeTimeMillis > 0) {\n // double power = (wakeTimeMillis\n // * mPowerProfile.getAveragePower(PowerProfile.POWER_CPU_AWAKE)) / 1000;\n // osApp.wakeLockTime += wakeTimeMillis;\n // osApp.value += power;\n // osApp.values[0] += power;\n // if (osApp.value > mMaxPower) mMaxPower = osApp.value;\n // mTotalPower += power;\n // }\n // }\n }",
"public String getSysNo() {\n return sysNo;\n }"
] | [
"0.67059034",
"0.66914207",
"0.6566337",
"0.65222096",
"0.6510367",
"0.60343605",
"0.6007771",
"0.59296495",
"0.592819",
"0.5766334",
"0.57614565",
"0.5757509",
"0.5673269",
"0.5672381",
"0.5638015",
"0.55841285",
"0.554198",
"0.5502302",
"0.5502302",
"0.5491878",
"0.54711217",
"0.54711217",
"0.54448956",
"0.54342425",
"0.5338802",
"0.5325685",
"0.53231764",
"0.53077585",
"0.5307324",
"0.53052706",
"0.5289381",
"0.5278729",
"0.52663094",
"0.52653354",
"0.52578074",
"0.5252748",
"0.52512556",
"0.523416",
"0.52339554",
"0.5229578",
"0.5198538",
"0.51579124",
"0.5155042",
"0.5148766",
"0.5141981",
"0.51353604",
"0.5106592",
"0.51014596",
"0.51010275",
"0.5099171",
"0.50904715",
"0.5080107",
"0.5077111",
"0.5072013",
"0.50713444",
"0.50694585",
"0.50410515",
"0.50341374",
"0.5033318",
"0.5019544",
"0.501391",
"0.5005553",
"0.5005553",
"0.4993393",
"0.49885634",
"0.49816096",
"0.49782282",
"0.497736",
"0.49719238",
"0.49693894",
"0.49326852",
"0.49317068",
"0.49303448",
"0.49303448",
"0.49298298",
"0.49169162",
"0.49165592",
"0.4916228",
"0.4915375",
"0.49144325",
"0.49114144",
"0.49107403",
"0.49065062",
"0.49016482",
"0.48991498",
"0.48921636",
"0.4887268",
"0.4886885",
"0.48842534",
"0.48764142",
"0.4875643",
"0.48750147",
"0.48732388",
"0.4870886",
"0.48708472",
"0.48706684",
"0.48705438",
"0.4856797",
"0.48479602",
"0.4845032"
] | 0.66820484 | 2 |
Gets the sequencenum parameter sent with the update from BGPd. | public long getSequenceNum() {
return sequenceNum;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"long getSeqnum();",
"long getSeqnum();",
"long getSeqnum();",
"long getSeqnum();",
"long getSeqnum();",
"long getSeqnum();",
"long getSeqnum();",
"public int getSeqNo();",
"public int getSeqNo();",
"public int getSeqNumber() {\n return buffer.getShort(2) & 0xFFFF;\n }",
"@MavlinkFieldInfo(\n position = 1,\n unitSize = 2,\n description = \"sequence number (starting with 0 on every transmission)\"\n )\n public final int seqnr() {\n return this.seqnr;\n }",
"public int getSeqNbr() {\n return seqNbr;\n }",
"public final Integer getRequestSeq() {\n return requestSeq;\n }",
"int getSeq();",
"int getSeq();",
"int getSeq();",
"public byte get_seqnum() {\n return (byte)getSIntElement(offsetBits_seqnum(), 8);\n }",
"public Integer getSeq() {\n return seq;\n }",
"public Integer getSeq() {\n return seq;\n }",
"public Integer getSeq() {\n return seq;\n }",
"public int getSeq() {\n return seq_;\n }",
"public int getSeq() {\n return seq_;\n }",
"public int getSeq() {\n return -1;\n }",
"public String getSEQN() {\n return SEQN;\n }",
"public long getSeqNo() {\n return seqNo;\n }",
"long getSeq() {\n return seq;\n }",
"public int getSeq() {\n return seq_;\n }",
"public int getSeq() {\n return seq_;\n }",
"String getAcctgTransEntrySeqId();",
"int getSequenceNumber();",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"private long getSeqNum() throws Exception {\n\t\tSystem.out.println(\"seq: \" + seq);\n\t\tif (seq == 256) {\n\t\t\tseq = 0;\n\t\t}\n\t\treturn seq++;\n\t}",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public long getSeqnum() {\n return seqnum_;\n }",
"public int getCSeqNumber() {\n return cSeqHeader.getSequenceNumber();\n }",
"public Number getSequenceNo() {\n return (Number)getAttributeInternal(SEQUENCENO);\n }",
"public String getConteIdseq() {\n return (String) getAttributeInternal(CONTEIDSEQ);\n }",
"public Integer getCocSeqNo() {\n\t\treturn cocSeqNo;\n\t}",
"public int getSequence() {\n return sequence;\n }",
"public java.lang.Integer getSeqNo () {\n\t\treturn seqNo;\n\t}",
"public int getSequenceNumber(){\n return sequenceNumber;\n }",
"public int getSequenceNumber();",
"long getSequenceNumber();",
"public int getTakeupSeqNo() {\n\t\treturn takeupSeqNo;\n\t}",
"public long getSequenceNo() {\n\treturn sequenceNo;\n }",
"@Field(3) \n\tpublic int SequenceNo() {\n\t\treturn this.io.getIntField(this, 3);\n\t}",
"public String getEventSeq() {\r\n\t\treturn eventSeq;\r\n\t}",
"public long sequenceNumber() {\n return sequenceNumber;\n }",
"public INT getSequenceNumber() { return _sequenceNumber; }",
"public String getCQcIdseq() {\n return (String) getAttributeInternal(CQCIDSEQ);\n }",
"public String getPQcIdseq() {\n return (String) getAttributeInternal(PQCIDSEQ);\n }",
"public int getSequenceNumber() {\r\n return sequenceNumber;\r\n }",
"public String getCardgroupSeq() {\r\n return (String) getAttributeInternal(CARDGROUPSEQ);\r\n }",
"public Integer getSequence()\n {\n return sequence;\n }",
"long getSequenceNum() {\n return sequenceNum;\n }",
"public String getQcIdseq() {\n return (String) getAttributeInternal(QCIDSEQ);\n }",
"static synchronized long getNextSeqNumber() {\n return seqNumber++;\n }",
"public int getSequenceNumber() {\n return sequenceNumber;\n }",
"public int getSequenceNumber() {\n\t\treturn fSequenceNumber;\n\t}",
"void requestSequenceNumber() {\r\n\t\t// 부모가 가지고있는 메시지의 순서번호(시작 ~ 끝)를 요청 \r\n\t}",
"long getOriginseqnum();",
"public long getSequenceNumber();",
"@Override\r\n\tpublic int getSeq() {\n\t\treturn pdsdao.getSeq();\r\n\t}",
"public String getSequenceId() {\n return this.placement.getSeqId();\n }",
"public Integer getSequence() {\n return sequence;\n }",
"public String getSequence()\r\n\t{\r\n\t\treturn sequence;\r\n\t}",
"public String getSequence()\n\t{\n\t\treturn this.sequence;\n\t}",
"public void getInteger(int seqid);",
"public int getSequenceNum() {\n\t\treturn sequenceNumber;\n\t}",
"protected int getSeqIndex()\n {\n return seqIndex;\n }",
"public String consensus_sequence () {\n return(current_contig.consensus.sequence.toString());\r\n }",
"public String getPModIdseq() {\n return (String) getAttributeInternal(PMODIDSEQ);\n }",
"public int getSequenceNumber() {\n return this.sequenceNumber;\n }",
"public int getSequenceNumber() {\r\n\t\treturn sequenceNumber;\r\n\t}",
"private Integer getSequence() {\r\n\t\t\tInteger seq;\r\n\t\t\tString sql = \"select MAX(vendorid)from vendorTable\";\r\n\t\t\tseq = template.queryForObject(sql, new Object[] {}, Integer.class);\r\n\t\t\treturn seq;\r\n\t\t}",
"public String getSequence() \n\t{\n\t\treturn sequence;\n\t\t\n\t}",
"public String getQrIdseq() {\n return (String) getAttributeInternal(QRIDSEQ);\n }",
"public String getOrderSeqNo() {\n return orderSeqNo;\n }",
"public String getSequence() {\r\n return sequence;\r\n }",
"public int get_infos_seq_num() {\n return (int)getUIntBEElement(offsetBits_infos_seq_num(), 16);\n }",
"public Integer getACTIVITY_SEQ_ID() {\n return ACTIVITY_SEQ_ID;\n }",
"public long getSequenceNumber() {\n return sequenceNumber;\n }",
"public java.lang.String getSeq() {\n java.lang.Object ref = seq_;\n if (!(ref instanceof java.lang.String)) {\n java.lang.String s = ((com.google.protobuf.ByteString) ref)\n .toStringUtf8();\n seq_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }",
"public AtomicInteger getSerialNo() {\n return serialNo;\n }",
"public java.lang.String getSeq() {\n java.lang.Object ref = seq_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n seq_ = s;\n }\n return s;\n }\n }",
"public String getSequence() {\n\t\treturn sequence;\n\t}",
"public String getSequence() {\n\t\treturn sequence;\n\t}",
"public String getSR_SEQ() {\n\t\treturn SR_SEQ;\n\t}",
"public BigInteger getSeqCurrentVal(String sequence) {\r\n\t\treturn this.crudDAO.getSeqCurrentVal(sequence);\r\n\t}"
] | [
"0.6679556",
"0.6679556",
"0.6679556",
"0.6679556",
"0.6679556",
"0.6679556",
"0.6679556",
"0.652751",
"0.652751",
"0.64704764",
"0.643962",
"0.6352093",
"0.6341182",
"0.6317732",
"0.6317732",
"0.6317732",
"0.63150746",
"0.6241829",
"0.6241829",
"0.6241829",
"0.62267214",
"0.62267214",
"0.6192622",
"0.61833215",
"0.61812633",
"0.6168812",
"0.61630327",
"0.61630327",
"0.6147421",
"0.6147034",
"0.6116667",
"0.6116667",
"0.6116667",
"0.6116667",
"0.6116667",
"0.6116667",
"0.6116667",
"0.6079232",
"0.60775244",
"0.60775244",
"0.60775244",
"0.60775244",
"0.60775244",
"0.60775244",
"0.60775244",
"0.6076602",
"0.6050448",
"0.60484076",
"0.6040255",
"0.6032323",
"0.6017154",
"0.60035837",
"0.5993419",
"0.5978624",
"0.5974407",
"0.5946034",
"0.59336585",
"0.5930165",
"0.59222174",
"0.59155697",
"0.5902635",
"0.5899554",
"0.5887259",
"0.5870434",
"0.5866121",
"0.5858426",
"0.58558446",
"0.5836942",
"0.58304024",
"0.5830014",
"0.5824674",
"0.5814217",
"0.5804686",
"0.580013",
"0.57887924",
"0.57738686",
"0.57651275",
"0.5763617",
"0.5763273",
"0.5761192",
"0.5752958",
"0.57496333",
"0.57357305",
"0.5720551",
"0.5720461",
"0.5716173",
"0.5714726",
"0.5713495",
"0.57110345",
"0.5699185",
"0.5690645",
"0.56787264",
"0.56468016",
"0.56357926",
"0.5634404",
"0.56335336",
"0.56308264",
"0.56308264",
"0.56179523",
"0.5591493"
] | 0.5845663 | 67 |
UnifedMain implements this interface and uses listener to recieve updates from the dialog | public interface StationFragmentListener{
public void onDialogPositiveClick(DialogFragment dialog);
public void onDialogNegativeClick(DialogFragment dialog);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface DialogListener {\n\n /**\n * Called when a dialog completes.\n *\n * Executed by the thread that initiated the dialog.\n *\n * @param values\n * Key-value string pairs extracted from the response.\n */\n public void onComplete(Bundle values);\n\n \n /**\n * Called when a dialog is canceled by the user.\n *\n * Executed by the thread that initiated the dialog.\n *\n */\n public void onCancel();\n}",
"@Override\n public void run() {\n new ExpenseDaoImpl().init();\n new PopupDescDaoImpl().init();\n new ScheduleDaoImpl().init();\n\n Main dialog = new Main(new javax.swing.JFrame(), true);\n dialog.addWindowListener(new java.awt.event.WindowAdapter() {\n @Override\n public void windowClosing(java.awt.event.WindowEvent e) { \n System.exit(0);\n }\n });\n dialog.setVisible(true);\n }",
"ListenerForPopupToPayWithAmmoOrPUCArd(JDialog dialog, MainFrame mainFrame, ServerEvent event) {\n this.dialog = dialog;\n this.mainFrame = mainFrame;\n this.event = event;\n }",
"public interface DialogListener { void onQuit(); }",
"public interface NewProjectDialogListener {\n void onDialogOK(Bundle myData);\n void onDialogCancel();\n }",
"public void update() {\n menu = new PopupMenu();\n\n final MenuItem add = new MenuItem(Messages.JOINCHANNEL);\n\n final MenuItem part = new MenuItem(Messages.PARTCHANNEL);\n\n final MenuItem reload = new MenuItem(Messages.RELOAD);\n\n final Menu language = new Menu(Messages.LANGUAGE);\n\n final MenuItem eng = new MenuItem(Messages.ENGLISH);\n\n final MenuItem fr = new MenuItem(Messages.FRENCH);\n\n final MenuItem sp = new MenuItem(Messages.SPANISH);\n\n final MenuItem debug = new MenuItem(Messages.DEBUG);\n\n final MenuItem about = new MenuItem(Messages.ABOUT);\n\n final MenuItem exit = new MenuItem(Messages.EXIT);\n exit.addActionListener(e -> Application.getInstance().disable());\n about.addActionListener(e -> JOptionPane.showMessageDialog(null,\n Messages.ABOUT_MESSAGE));\n add.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(final ActionEvent e) {\n if (Application.getInstance().getChrome().getToolbar()\n .getButtonCount() < 10) {\n Application.getInstance().getChrome().getToolbar().parent\n .actionPerformed(new ActionEvent(this, e.getID(),\n \"add\"));\n } else {\n JOptionPane.showMessageDialog(null,\n \"You have reached the maximum amount of channels!\");\n }\n }\n });\n part.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(final ActionEvent e) {\n Application.getInstance().getChrome().getToolbar().parent\n .actionPerformed(new ActionEvent(this,\n ActionEvent.ACTION_PERFORMED, \"remove\"\n + \".\"\n + Application.getInstance().getChrome()\n .getToolbar().getCurrentTab()));\n }\n });\n debug.addActionListener(e -> {\n if (!LoadScreen.getDebugger().isVisible()) {\n LoadScreen.getDebugger().setVisible(true);\n } else {\n LoadScreen.getDebugger().setVisible(true);\n }\n });\n\n eng.addActionListener(arg0 -> {\n Messages.setLanguage(Language.ENGLISH);\n Application.getInstance().getTray().update();\n });\n\n fr.addActionListener(arg0 -> {\n Messages.setLanguage(Language.FRENCH);\n Application.getInstance().getTray().update();\n });\n\n sp.addActionListener(arg0 -> {\n Messages.setLanguage(Language.SPANISH);\n Application.getInstance().getTray().update();\n });\n\n if (eng.getLabel().equalsIgnoreCase(Messages.CURR)) {\n eng.setEnabled(false);\n }\n\n if (fr.getLabel().equalsIgnoreCase(Messages.CURR)) {\n fr.setEnabled(false);\n }\n\n if (sp.getLabel().equalsIgnoreCase(Messages.CURR)) {\n sp.setEnabled(false);\n }\n\n if (Application.getInstance().getChrome().getToolbar().getCurrentTab() == -1) {\n part.setEnabled(false);\n }\n if (!Application.getInstance().getChrome().getToolbar().isAddVisible()) {\n add.setEnabled(false);\n }\n\n language.add(eng);\n language.add(fr);\n language.add(sp);\n\n menu.add(add);\n menu.add(part);\n menu.add(reload);\n menu.addSeparator();\n menu.add(language);\n menu.addSeparator();\n menu.add(debug);\n menu.add(about);\n menu.addSeparator();\n menu.add(exit);\n Tray.sysTray.setPopupMenu(menu);\n }",
"void successUiUpdater();",
"@Override\n\t\t\t\t\tpublic void run(){\n\t\t\t\t\t\t//status of 1 is success\n\t\t\t\t\t\tif (status==1){\n\t\t\t\t\t\t\tmainDialog.dispose();\n\t\t\t\t\t\t\tbuildSuccessDialog();\n\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//else error\n\t\t\t\t\t\telse{\n\t\t\t\t\t\t\tmainDialog.dispose();\n\t\t\t\t\t\t\tbuildErrorDialog(status);\n\t\t\t\t\t\t}\n\t\t\t\t\t}",
"private void process() {\n final PluginsDialog dialog = new PluginsDialog();\n dialog.show();\n }",
"@FXML\n public final void buttonListener() {\n final String str = GameContext.instance().toStringUniverse();\n Dialogs.create()\n .title(\"Planet list\")\n .message(str)\n .showInformation();\n }",
"public void runInUi(ElexisEvent ev){}",
"private void initDialog() {\n }",
"public abstract void initUiAndListener();",
"@Override\n public void executeUpdate() {\n EventBus.publish(new DialogCraftingReceivedEvent(requestId, title, groups, craftItems));\n }",
"private void updateUI() {\n\t\t\tfinal TextView MessageVitesse = (TextView) findViewById(R.id.TextView01);\r\n\t\t\tfinal ProgressBar Progress = (ProgressBar) findViewById (R.id.ProgressBar01);\r\n\t\t\tfinal TextView MessageStatus = (TextView)findViewById (R.id.TextView02);\r\n\t\t\t\t\t\r\n\t\t\t//on affecte des valeurs aux composant\r\n\t\t\tMessageVitesse.setText(\"Vitesse Actuelle : \"+ Vitesse + \" Ko/s\");\r\n\t\t\tProgress.setProgress(Pourcent);\r\n\t\t\tMessageStatus.setText (Status);\r\n\t\t\tif (Status.equals(\"Télèchargement terminé!!!\")&&NotifDejaLancée==false){\r\n\t\t\t\tlanceNotification();\r\n\t\t\t\tNotifDejaLancée=true;\r\n\t\t\t}\r\n\t\t\t}",
"public void run() {\n\t\t\t\t\tShell useParent = (parent != null && !parent.isDisposed()) ? parent : GDE.shell;\r\n\t\t\t\t\tMessageBox messageDialog = new MessageBox(useParent, SWT.OK | SWT.ICON_WARNING);\r\n\t\t\t\t\tmessageDialog.setText(GDE.NAME_LONG);\r\n\t\t\t\t\tmessageDialog.setMessage(message);\r\n\t\t\t\t\tmessageDialog.open();\r\n\t\t\t\t}",
"public void run(){\n\n if(!initProxy()){\n //Check if we have been aborted\n if(mode != OK_MODE) return;\n if(net_thread != Thread.currentThread()) return;\n\n mode = COMMAND_MODE;\n warning_label.setText(\"Look up failed.\");\n warning_label.invalidate();\n return;\n }\n\n //System.out.println(\"Done!\");\n while(!warning_dialog.isShowing())\n ; /* do nothing*/;\n\n warning_dialog.dispose();\n //dispose(); //End Dialog\n }",
"public interface DialogObserver {\n\n public void notfiy(String message);\n}",
"public interface MainInteractor {\n interface MainListener{\n void campoVazio();\n void sucess();\n void navigationToHome();\n }\n void valida(String texto,MainListener listener);\n}",
"interface ViewListener extends OnToolBarNavigationListener {\n\n /**\n * On build queue\n *\n * @param isPersonal - Is personal flag\n * @param queueToTheTop - Queue to the top\n * @param cleanAllFiles - Clean all files in the checkout directory\n */\n void onBuildQueue(boolean isPersonal,\n boolean queueToTheTop,\n boolean cleanAllFiles);\n\n /**\n * On agent selected in the dialog list\n *\n * @param agentPosition - item position which was selected\n */\n void onAgentSelected(int agentPosition);\n\n /**\n * On add parameter button click\n */\n void onAddParameterButtonClick();\n\n /**\n * On clear all parameters button click\n */\n void onClearAllParametersButtonClick();\n\n /**\n * On parameter added\n *\n * @param name - parameter name\n * @param value - parameter value\n */\n void onParameterAdded(String name, String value);\n }",
"public static void run()\n {\n JFrame invisibleFrame = new InvisibleFrame(TITLE);\n try {\n MainDialog mainDialog = new MainDialog(invisibleFrame);\n mainDialog.setVisible(true);\n } finally {\n invisibleFrame.dispose();\n }\n }",
"public void updateUI(){}",
"public abstract void initDialog();",
"@Override\r\n\t\tpublic void handleMessage(Message msg) {\n\t\t\tsuper.handleMessage(msg);\r\n\t\t\tswitch (msg.what) {\r\n\t\t\tcase REFRESH_VIEW:\r\n\t\t\t\tif (onSelectingListener != null)\r\n\t\t\t\t\tonSelectingListener.selecting(true);\r\n\t\t\t\tbreak;\r\n\t\t\tcase GETUNIT:\r\n\t\t\t\tunitPicker.setUnit(unit);\r\n\t\t\t\tunitPicker.setDefault(0);\r\n\t\t\t\tif (onInitdataedListener != null && unit != null && unit.size() > 0) {\r\n\t\t\t\t\tonInitdataedListener.Initdataed(unit.get(0));\r\n\t\t\t\t}\r\n\t\t\t\tbreak;\r\n\t\t\tcase SETUNIT:\r\n\t\t\t\tunitPicker.setUnit(unit);\r\n\t\t\t\tunitPicker.setDefault(0);\r\n\t\t\t\t// if(onInitdataedListener!=null&&unit!=null&&unit.size()>0) {\r\n\t\t\t\t// onInitdataedListener.Initdataed(unit.get(0));\r\n\t\t\t\t// }\r\n\t\t\t\tbreak;\r\n\t\t\tcase CLEAR_VIEW:\r\n\t\t\t\tunit = new ArrayList<Unit>();\r\n\t\t\t\tunitPicker.setUnit(unit);\r\n\t\t\t\tonInitdataedListener.Initdataed(null);\r\n\t\t\t\tinvalidate();\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}",
"public interface GetDialogResultListener {\n void getDialogResult(int mode, String result);\n}",
"public interface FrequencyDLGCallBackListener {\n\n void onDismiss(int which);\n}",
"public void update(Main main);",
"public interface OnDialogListener {\n void onPositiveListener();\n void onNegativeListener();\n }",
"public void run() {\n\t\t\t\tfinal Dialog dialog = new Dialog(Main.this);\n\t\t\t\tdialog.setContentView(R.layout.dialog);\n\t\t\t\tdialog.setTitle(\"Test completes!\");\n\t\t\t\tdialog.setCancelable(true);\n\t\t\t\tdialog.setCanceledOnTouchOutside(true);\n\n\t\t\t\t//set up text\n\t\t\t\tTextView text = (TextView) dialog.findViewById(R.id.TextView01);\n\t\t\t\tDecimalFormat df = new DecimalFormat(\"#.##\");\n\t\t\t\ttext.setText(\"Average downlink speed\\n\"+ df.format(down) + \" kbps\\n\\nAverage uplink speed\\n\" + \n\t\t\t\t\t\tdf.format(up) + \" kbps\\n\\nLatency\\n\" + df.format(rtt) + \" ms\"); \n\n\n\t\t\t\t//Create the button \n\t\t\t\tButton button = (Button) dialog.findViewById(R.id.Button01);\n\t\t\t\tbutton.setOnClickListener(new OnClickListener() {\n\t\t\t\t\t//When the button is clicked, call up android test menu\n\t\t\t\t\t//@Override\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\tdialog.dismiss();\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tdialog.show();\n\n\t\t\t}",
"public interface Listener {\n void onClose(ConfirmDialog dialog);\n }",
"@Override\n\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\tupdateUI();\n\t\t\t\t\t\t}",
"public void createEvents(){\r\n\t\tbtnCurrent.addActionListener((ActionEvent e) -> JLabelDialog.run());\r\n\t}",
"@Override\n\tpublic void init() {\n//\t\tSystem.out.println(\"init UIAgent\");\n\n//\t\tSystem.out.println(\"closing old dialog of \");\n\t\tif (ui != null) {\n\t\t\tui.dispose();\n\t\t\tui = null;\n\t\t}\n//\t\tSystem.out.println(\"old dialog closed. Trying to open new dialog. \");\n\t\ttry {\n\t\t\tui = new EnterBidDialog(this, null, true,\n\t\t\t\t\t(AdditiveUtilitySpace) utilitySpace, null);\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"Problem in UIAgent2.init:\" + e.getMessage());\n\t\t\te.printStackTrace();\n\t\t}\n//\t\tSystem.out.println(\"finished init of UIAgent2\");\n\t}",
"@Override\n public void run() {\n showDialog(ZDisMainActivity.this,\"dialog\");\n }",
"@Override\n\t\t\tpublic void onStartInMainThread(Object result)\n\t\t\t{\n\t\t\t\tsuper.onStartInMainThread(result);\n\t\t\t\tif (mStartType == 1)\n\t\t\t\t{\n\t\t\t\t\tnDialog = SDDialogUtil.showLoading(\"正在检测新版本...\");\n\t\t\t\t}\n\t\t\t}",
"public interface DialogInteractionListener {\n /**\n * Handles the click on the discard changes button.\n */\n void onDiscardChangesSelected();\n }",
"@Override\n public void run() {\n showDialog(ZDisMainActivity.this,\"dialog\");\n }",
"private void dialogChanged() {\n\t\tString teamNumber = getTeamNumber();\n\t\tif (listener != null) listener.stateChanged(null); \n\t\tif (!teamNumber.matches(\"^([1-9][0-9]*)$\")) {\n\t\t\tupdateStatus(\"Team number must be a valid integer without leading zeroes.\");\n\t\t\treturn;\n\t\t}\n\t\tupdateStatus(null);\n\t}",
"@Override\n\t\t\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t\t\twait = new waittingDialog();\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\texit = new ExitDialog();\n\t\t\t\t\t\t\t}",
"void run() {\n System.out.println(\"PC Visual application run\");\n data = new Data(this);\n window = new Window(this);\n window.setup();\n mote = new MoteIF(PrintStreamMessenger.err);\n mote.registerListener(new OscilloscopeMsg(), this);\n }",
"public void run() {\n\t\t\t\t\t\t\tProposal p = getSelectedProposal();\n\t\t\t\t\t\t\tif (p != null) {\n\t\t\t\t\t\t\t\tString description = p.getDescription();\n\t\t\t\t\t\t\t\tif (description != null) {\n\t\t\t\t\t\t\t\t\tif (infoPopup == null) {\n\t\t\t\t\t\t\t\t\t\tinfoPopup = new InfoPopupDialog(getShell());\n\t\t\t\t\t\t\t\t\t\tinfoPopup.open();\n\t\t\t\t\t\t\t\t\t\tinfoPopup.getShell()\n\t\t\t\t\t\t\t\t\t\t\t\t.addDisposeListener(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tnew DisposeListener() {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tpublic void widgetDisposed(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tDisposeEvent event) {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tinfoPopup = null;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tinfoPopup.setContents(p.getDescription());\n\t\t\t\t\t\t\t\t} else if (infoPopup != null) {\n\t\t\t\t\t\t\t\t\tinfoPopup.close();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tpendingDescriptionUpdate = false;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}",
"private void attachListeners(){\n\t\t//Add window listener\n\t\tthis.removeWindowListener(this);\n\t\tthis.addWindowListener(this); \n\n\t\tbuttonCopyToClipboard.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\ttry {\n\t\t\t\t\tOS.copyStringToClipboard( getMessagePlainText() );\n\t\t\t\t} catch (BadLocationException e) {\n\t\t\t\t\tshowErrorMessage(e.getMessage());\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tsetMessage( translations.getMessageHasBeenCopied() );\n\t\t\t}\n\t\t});\n\t\t\n\t\tbuttonChooseDestinationDirectory.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\tchooseDirectoryAction();\n\t\t\t}\n\t\t});\n\t\t\n\t\tbuttonChangeFileNames.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\tchangeFileNamesAction(false);//false => real file change\n\t\t\t}\n\t\t});\n\t\t\n\t\tbuttonSimulateChangeFileNames.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\tchangeFileNamesAction(true);//true => only simulation of change with log\n\t\t\t\tif(DebuggingConfig.debuggingOn){\n\t\t\t\t\tshowTextAreaHTMLInConsole();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\t\n\t\tbuttonExample.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\tsetupInitialValues();\n\t\t\t\t//if it's not debugging mode\n\t\t\t\tif(!DebuggingConfig.debuggingOn){\n\t\t\t\t\tshowPlainMessage(translations.getExampleSettingsPopup());\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\t\n\t\tbuttonClear.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\ttextArea.setText(textAreaInitialHTML);\n\t\t\t}\n\t\t});\n\t\t\n\t\tbuttonResetToDefaults.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\tif( deleteSavedObject() ) {\n\t\t\t\t\tsetMessage( translations.getPreviousSettingsRemovedFromFile().replace(replace, getObjectSavePath()) );\n\t\t\t\t\tsetMessage( translations.getPreviousSettingsRemoved() );\n\t\t\t\t\t//we have to delete listener, because it's gonna save settings after windowClosing, we don't want that\n\t\t\t\t\tFileOperationsFrame fileOperationsFrame = (FileOperationsFrame) getInstance();\n\t\t\t\t\tfileOperationsFrame.removeWindowListener(fileOperationsFrame);\n\t\t\t\t\tresetFields();\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tshowWarningMessage( translations.getFileHasNotBeenRemoved().replace(replace, getObjectSavePath()) + BR + translations.getPreviousSettingsHasNotBeenRemoved() );\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\tcomboBox.addActionListener(new ActionListener() {\n\t\t\t@SuppressWarnings(\"unchecked\")\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\tJComboBox<String> obj = (JComboBox<String>) arg0.getSource();\n\t\t\t\tselectedLanguage = AvailableLanguages.getByName( (String)obj.getSelectedItem() ) ;\n\t\t\t\tselectLanguage(selectedLanguage);\n\t\t\t\tsetComponentTexts();\n\t\t\t};\n\t\t});\t\n\t\t\n\t\t//for debug \n\t\tif(DebuggingConfig.debuggingOn){\n\t\t\tbuttonExample.doClick();\n\t\t}\n\t\t\n\t\t\n\t}",
"@Override\r\n public void updateUI() {\r\n }",
"public interface DialogListener {\r\n public void handleYesButton();\r\n}",
"private void updateGUIStatus() {\r\n\r\n }",
"public abstract void update(UIReader event);",
"public JoinListener (MainHG mainclass){\n\t\tplugin = mainclass;\n\t\tmainclass.getServer().getPluginManager().registerEvents(this, mainclass);\n\t}",
"public interface OnBaseUIListener {\n}",
"public Dialog onCreateDialogSingleChoice() {\n\t\tAlertDialog.Builder builder = new AlertDialog.Builder(this);\n\t\t// Source of the data in the DIalog\n\t\tfinal String[] arr = new String[] { \"Completed\", \"Pending\",\n\t\t\t\t\"In progress\", \"Cancelled\" };\n\n\t\tfinal List<String> str1 = new ArrayList<String>();\n\n\t\t// Set the dialog title\n\t\tbuilder.setTitle(\"UpdateStatus\")\n\t\t\t\t// Specify the list array, the items to be selected by default\n\t\t\t\t// (null for none),\n\t\t\t\t// and the listener through which to receive callbacks when\n\t\t\t\t// items are selected\n\t\t\t\t.setSingleChoiceItems(arr, 0,\n\t\t\t\t\t\tnew DialogInterface.OnClickListener() {\n\n\t\t\t\t\t\t\t@Override\n\t\t\t\t\t\t\tpublic void onClick(DialogInterface dialog,\n\t\t\t\t\t\t\t\t\tint which) {\n\t\t\t\t\t\t\t\tLog.d(Config.TAG,\n\t\t\t\t\t\t\t\t\t\t\"insdie onclick dialog interface which pos\"\n\t\t\t\t\t\t\t\t\t\t\t\t+ which);\n\t\t\t\t\t\t\t\tfor (String str : arr) {\n\t\t\t\t\t\t\t\t\tif(which>=0){\n\t\t\t\t\t\t\t\t\tstr = arr[which];\n\t\t\t\t\t\t\t\t\tstr1.add(str);\n\t\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t\tstr = arr[2];\n\t\t\t\t\t\t\t\t\t\tstr1.add(str);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t})\n\n\t\t\t\t// Set the action buttons\n\t\t\t\t.setPositiveButton(\"Ok\", new DialogInterface.OnClickListener() {\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void onClick(DialogInterface dialog, int id) {\n\t\t\t\t\t\tLog.d(Config.TAG,\n\t\t\t\t\t\t\t\t\"insdie onclick dialog interface which pos okay button\"\n\t\t\t\t\t\t\t\t\t\t+ id+\"STR! = \"+str1);\n\t\t\t\t\t\tif(id==-1){\n\t\t\t\t\t\t\tif(str1.size()>0){\n\t\t\t\t\t\tString str = str1.get(0);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\tLog.d(Config.TAG, \"@@@@@@@@@@@@@@\"+str);\n\t\t\t\t\t\tnew UpdateStatus(str).execute();\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\tString str = \"Completed\";\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tLog.d(Config.TAG, \"@@@@@@@@@@@@@@\"+str);\n\t\t\t\t\t\t\t\tnew UpdateStatus(str).execute();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t\t.setNegativeButton(\"Cancel\",\n\t\t\t\t\t\tnew DialogInterface.OnClickListener() {\n\t\t\t\t\t\t\t@Override\n\t\t\t\t\t\t\tpublic void onClick(DialogInterface dialog, int id) {\n\t\t\t\t\t\t\t\tLog.d(Config.TAG,\n\t\t\t\t\t\t\t\t\t\t\"insdie onclick dialog interface which pos cancel button\"\n\t\t\t\t\t\t\t\t\t\t\t\t+ id);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tdialog.cancel();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\n\t\treturn builder.create();\n\t}",
"void onHisNotify();",
"public static interface MenuDialogListener {\n\n /** Invoked when the dialog is shown. */\n public void onShow(Context context);\n\n /** Invoked when the dialog is dismissed. */\n public void onDismiss(Context context);\n\n /** Invoked when \"Show Input Method Picker\" item is selected. */\n public void onShowInputMethodPickerSelected(Context context);\n\n /** Invoked when \"Launch Preference Activity\" item is selected. */\n public void onLaunchPreferenceActivitySelected(Context context);\n\n /** Invoked when \"Launch Mushroom\" item is selected. */\n public void onShowMushroomSelectionDialogSelected(Context context);\n }",
"@Override\n\t\tpublic void run() {\n\t\t\tArrayListPointer dataTaskListPointer = new ArrayListPointer(); \n dataTaskListPointer.setPointer(dataTaskList);\n\t\t\tString message = mMainLogic.process(AppConst.COMMAND_TYPE.REMIND, dataTaskListPointer);\n\t\t\t\n\t\t\tif (message != null) {\t\t\t\t\n\t\t\t\t\n\t\t\t\tdataTaskList = dataTaskListPointer.getPointer();\n\t\t\t\tmTableRowCount = dataTaskList.size();\n\t\t\t\tuserScrollCount = 0;\n\t\t\t\tmTableHelper.setDataListForTable(dataTaskList);\n\t\t\t\tmTableHelper.createTableToDisplayTasks();\n\t\t\t\toutput.setText(\"\");\n\t\t\t\tdisplayMessage(message);\n\t\t\t\t\n\t\t\t\t// show notification to users\n\t\t\t\t// option pane with no buttons.\n\t\t\t\tJOptionPane opt = new JOptionPane(\tAppConst.MESSAGE.NOTIFICATIONS, \n\t\t\t\t\t\t\t\t\t\t\t\t\tJOptionPane.INFORMATION_MESSAGE, \n\t\t\t\t\t\t\t\t\t\t\t\t\tJOptionPane.DEFAULT_OPTION, \n\t\t\t\t\t\t\t\t\t\t\t\t\tnull, \n\t\t\t\t\t\t\t\t\t\t\t\t\tnew Object[]{AppConst.UI_CONST.OK_BUTTON}); \n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t \t\tfinal JDialog dlg = opt.createDialog(AppConst.UI_CONST.NOTIFICATION);\n\t\t \t\tnew Thread(new Runnable() {\n\t\t\t\t\tpublic void run() {\t\t\n\t\t \t\t\t\ttry {\n\t\t \t\t\t\t\t/* \n\t\t \t\t\t\t\t* Turn on the notification\n\t\t \t\t\t\t\t* User can turn off by press ENTER\n\t\t \t\t\t\t\t* If not, after timeDismiss seconds, the notification will be turned off\n\t\t \t\t\t\t\t*/\n\t\t\t\t\t\t\tThread.sleep(AppConst.UI_CONST.DEFAULT_TIME_DISMISS);\n\t\t\t\t\t\t\tdlg.dispose();\n\t\t\t\t\t\t} catch (Throwable th) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t \t\t\t}\n\t\t \t\t}).start();\n\t\t \t\tdlg.setVisible(true);\n\t\t\t}\n\t\t\t//toolkit.beep();\n\t\t}",
"public void run() {\n\t\t\tshowSystemDialog(ResultMsg);\r\n\t\t}",
"@Override\r\n\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\tList<User> l=new ArrayList<User>();\r\n\t\t\t\t\t\t\ttv.setInput(l);\r\n\t\t\t\t\t\t\tMessageDialog.openWarning(Display.getDefault().getActiveShell(), \"wain\", \"Without this user \");\r\n\t\t\t\t\t\t}",
"private void dialogAbout() {\n\t\tGraphicalUserInterfaceAbout.start();\r\n\t}",
"@Override\n\tpublic void onGuiClosed()\n {\n }",
"public void onGuiClosed()\r\n\t{\r\n\t\tif (this.realmsNotification != null)\r\n\t\t{\r\n\t\t\tthis.realmsNotification.onGuiClosed();\r\n\t\t}\r\n\t}",
"public interface IMainView {\n void registeButtonClicked();\n void destroyButtonClicked();\n void updateClientStatus(boolean registered, String registrationId);\n void showProgress();\n void hideProgress();\n void showToast(String msg);\n}",
"@Subscribe(threadMode = ThreadMode.MAIN)\n public void onDialogEvent(DialogEvent event){\n EventBus.getDefault().post(new ReconizeStatusEvent(\"重新识别\"));\n EventBus.getDefault().post(new ReconizeResultEvent(\"\"));\n EventBus.getDefault().post(new NluEvent(\"\"));\n EventBus.getDefault().post(new AsrTimeEvent(\"\"));\n// LightManager.getInstance().lightWakeup();\n //EventBus.getDefault().post(new ReconizeStatusEvent(\"开始识别\"));\n //开始识别\n // RecordModel.getInstance().startRecord();//sdk mode\n startBaiduAsr();//sdk mode\n\n /*scheduledThreadPool.schedule(new Runnable() {\n\n @Override\n public void run() {\n// RecordModel.getInstance().stopRecord(); //sdk mode\n RecordModel.getInstance().stopBaiduAsr(); //sdk mode\n }\n }, Const.RECONIZE_INTERVAL, TimeUnit.SECONDS);*/\n\n }",
"public AbstractListenerDialog() {\n\t\tlisteners = new ArrayList<>();\n\t}",
"@Nullable\n @Override\n public Void run() {\n DataManager.getInstanse().updateDialog(mString,mDate);\n return null;\n }",
"public MainView() {\n initComponents();\n addWindowListener(new AreYouSure());\n }",
"public interface MainScreeInteractionListener {\n // TODO: Update argument type and name\n void onFragmentInteractionMain();\n }",
"public interface IGetEntryPresenter {\n\n /**\n * Method to load the entry presenter screen\n * \n * @param responseDTO An instance of GetEntryResponseDTO which contains\n * variables that determine the loading/handling of\n * entry canvas.\n */\n void load(GetEntryResponseDTO responseDTO);\n \n void rotateScreen(boolean isLandScape);\n\n /**\n * Unloads the view\n */\n void unLoad();\n\n /**\n * Method to remove a menu item from the view\n * \n * @param itemId Item Id of the menu item\n * @param itemName Item Name of the menu item\n */\n void removeMenuItem(int itemId, String itemName);\n\n /**\n * Method to rename the menu item. Method adds the item edit box to the view\n * \n * @param itemId Item Id of the menu item\n * @param itemName Item Name of the menu item\n */\n //#if KEYPAD\n //|JG| void renameMenuItem(int itemId, String itemName);\n //#endif\n\n /**\n * Method to change a menu item name\n * \n * @param itemId Item id of the menu item whose name needs to be changed\n * @param itemName New item name\n */\n void changeMenuItemName(String itemId, String itemName);\n\n /**\n * Method to load message box\n * @param type\n * <li> 1 - Smartpopup without any options that last for \n * predefined time </li>\n * <li> 2,3,5 - Message box with options menu </li>\n * <li> 4,6 - Notification window </li>\n * @param msg Message\n */\n// void loadMessageBox(byte type, String msg);\n\n /**\n * Method to select the last accessed menu item\n * \n * @param iName Item name to be selected\n */\n void selectLastAccessedItem(String itemId);\n\n /**\n * Method to copy the text to the text box\n * \n * @param txt Text to be copied\n */\n void copyTextToTextBox(String text,boolean isMaxSet);\n\n /**\n * Method to show notification. This function internally calls the the\n * handlesmartpopup with the type defined for notification window\n * \n * @param isGoTo Boolean to indicate whether the notification window should\n * have \"Goto\" option or not\n * \n * @param dmsg Notification message\n * \n * @param param String Array which consists of two elements\n * <li> Element 0 - To represents whether the notification\n * is raised for message arrival or scheduler invocation\n * </li>\n * <li> Element 1 - Gives you the message id incase of \n * message or sequence name in case of scheduler\n * <li>\n */\n// void showNotification(byte isGoto);\n \n void keyPressed(int keycode);\n \n void paintGameView(Graphics g);\n \n byte commandAction(byte priority);\n \n// void displayMessageSendSprite();\n \n boolean pointerPressed(int x, int y, boolean isPointed, boolean isReleased, boolean isPressed);\n\n// //CR 12318\n// public void updateChatNotification(String[] msg);\n\n //CR 12118\n //bug 14155\n //bug 14156\n void changeMenuItemName(String itemName, byte type, String msgPlus);\n\n //CR 14672, 14675\n void refreshList(String[] contacts, int[] contactId);\n\n void setImage(ByteArrayOutputStream byteArrayOutputStream); //CR 14694\n}",
"public void run() {\n\t\t\t\t\tif (_uiContainer.isDisposed()) {\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tsetStatusMessage(UI.EMPTY_STRING);\r\n\t\t\t\t}",
"public void updateUI()\n\t{\n\t\tif( isRunning() == false) \n\t\t{\n\t\t\tupdateButton(\"Run\");\n\t\t\tbutton.setClickable(true);\n\t\t\tupdateTextView(Feedback.getMessage(Feedback.TYPE.NEW_TEST, null));\n\t\t}else\n\t\t{\n\t\t\tbutton.setClickable(true);\n\t\t\tupdateButton( \"Stop\" );\n\t\t\tupdateTextView(\"Tests are running.\");\n\n\t\t}\n\t}",
"private void postInitGUI(final String inputFilePath) {\r\n\t\tfinal String $METHOD_NAME = \"postInitGUI\"; //$NON-NLS-1$\r\n\t\ttry {\r\n\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"init tabs\"); //$NON-NLS-1$\r\n\t\t\tthis.statisticsTabItem = new StatisticsWindow(this.displayTab, SWT.NONE);\r\n\t\t\tthis.statisticsTabItem.create();\r\n\r\n\t\t\t// initialization of table, digital, analog and cell voltage are done while initializing the device\r\n\r\n\t\t\tthis.fileCommentTabItem = new FileCommentWindow(this.displayTab, SWT.NONE);\r\n\t\t\tthis.fileCommentTabItem.create();\r\n\r\n\t\t\t//createCompareWindowTabItem();\r\n\r\n\t\t\tthis.setObjectDescriptionTabVisible(this.menuToolBar.isObjectoriented());\r\n\r\n\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"init listener\"); //$NON-NLS-1$\r\n\t\t\tGDE.shell.addListener(SWT.Close, new Listener() {\r\n\t\t\t\tpublic void handleEvent(Event evt) {\r\n\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, GDE.shell.getLocation().toString() + \"event = \" + evt); //$NON-NLS-1$\r\n\r\n\t\t\t\t\t// checkk all data saved - prevent closing application\r\n\t\t\t\t\tevt.doit = getDeviceSelectionDialog().checkDataSaved();\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\tthis.addDisposeListener(new DisposeListener() {\r\n\t\t\t\tpublic void widgetDisposed(DisposeEvent evt) {\r\n\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, \"widgetDisposed\", GDE.shell.getLocation().toString() + \"event = \" + evt); //$NON-NLS-1$ //$NON-NLS-2$\r\n\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, \"widgetDisposed\", GDE.shell.getSize().toString()); //$NON-NLS-1$\r\n\t\t\t\t\t//cleanup\r\n\t\t\t\t\t// if help browser is open, dispose it\r\n\t\t\t\t\tif (DataExplorer.this.helpDialog != null && !DataExplorer.this.helpDialog.isDisposed()) {\r\n\t\t\t\t\t\tDataExplorer.this.helpDialog.dispose();\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (DataExplorer.application.getActiveDevice() != null) {\r\n\t\t\t\t\t\tDataExplorer.application.getActiveDevice().storeDeviceProperties();\r\n\r\n\t\t\t\t\t\t//close open communication ports\r\n\t\t\t\t\t\tIDeviceCommPort port = DataExplorer.application.getActiveDevice().getCommunicationPort();\r\n\t\t\t\t\t\tif (port != null) {// if communication port still open, close it\r\n\t\t\t\t\t\t\ttry {\r\n\t\t\t\t\t\t\t\tif (port.getClass().getName().toLowerCase().contains(\"usb\")) //USB port\r\n\t\t\t\t\t\t\t\t\tport.closeUsbPort(null);\r\n\t\t\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\t\t\tport.close(); //serial port\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tcatch (Exception e) {\r\n\t\t\t\t\t\t\t\tlog.log(Level.WARNING, e.getMessage(), e);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tDataExplorer.application.getActiveDevice().storeDeviceProperties();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (DataExplorer.application.getDeviceDialog() != null && !DataExplorer.application.getDeviceDialog().isDisposed()) {// if a device tool box is open, dispose it\r\n\t\t\t\t\t\tDataExplorer.application.getDeviceDialog().forceDispose();\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t// query the item definition to save it for restore option \r\n\t\t\t\t\tDataExplorer.this.order = DataExplorer.this.menuCoolBar.getItemOrder();\r\n\t\t\t\t\tDataExplorer.this.wrapIndices = DataExplorer.this.menuCoolBar.getWrapIndices();\r\n\t\t\t\t\tif (DataExplorer.this.wrapIndices.length > 0) {\r\n\t\t\t\t\t\tif (DataExplorer.this.wrapIndices[0] != 0) {\r\n\t\t\t\t\t\t\tint[] newWraps = new int[DataExplorer.this.wrapIndices.length + 1];\r\n\t\t\t\t\t\t\tfor (int i = 0; i < DataExplorer.this.wrapIndices.length; i++) {\r\n\t\t\t\t\t\t\t\tnewWraps[i + 1] = DataExplorer.this.wrapIndices[i];\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tDataExplorer.this.wrapIndices = newWraps;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tDataExplorer.this.sizes = DataExplorer.this.menuCoolBar.getItemSizes();\r\n\t\t\t\t\tDataExplorer.application.settings.setCoolBarStates(DataExplorer.this.order, DataExplorer.this.wrapIndices, DataExplorer.this.sizes);\r\n\r\n\t\t\t\t\tif (DataExplorer.this.objectDescriptionTabItem != null && !DataExplorer.this.objectDescriptionTabItem.isDisposed()) {\r\n\t\t\t\t\t\tDataExplorer.this.objectDescriptionTabItem.checkSaveObjectData(); // check if data needs to be saved\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t// finally save application settings\r\n\t\t\t\t\tDataExplorer.application.settings.store();\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\tthis.menuCoolBar.addControlListener(new ControlAdapter() {\r\n\t\t\t\t@Override\r\n\t\t\t\tpublic void controlResized(ControlEvent evt) {\r\n\t\t\t\t\tif (log.isLoggable(Level.FINEST)) log.logp(Level.FINEST, $CLASS_NAME, $METHOD_NAME, \"menuCoolBar.controlResized, event=\" + evt); //$NON-NLS-1$\r\n\t\t\t\t\t// menuCoolBar.controlResized signals collBar item moved\r\n\t\t\t\t\tif (DataExplorer.this.displayTab != null && getSize().y != 0) {\r\n\t\t\t\t\t\tPoint fillerSize = DataExplorer.this.filler.getSize();\r\n\t\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"filler.size = \" + fillerSize); //$NON-NLS-1$\r\n\t\t\t\t\t\tPoint menuCoolBarSize = DataExplorer.this.menuCoolBar.getSize();\r\n\t\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"menuCoolBar.size = \" + menuCoolBarSize); //$NON-NLS-1$\r\n\t\t\t\t\t\tPoint shellSize = new Point(getClientArea().width, getClientArea().height);\r\n\t\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"shellClient.size = \" + shellSize); //$NON-NLS-1$\r\n\t\t\t\t\t\tPoint statusBarSize = DataExplorer.this.statusComposite.getSize();\r\n\t\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"statusBar.size = \" + statusBarSize); //$NON-NLS-1$\r\n\t\t\t\t\t\tDataExplorer.this.displayTab.setBounds(0, menuCoolBarSize.y + fillerSize.y, shellSize.x, shellSize.y - menuCoolBarSize.y - statusBarSize.y - fillerSize.y);\r\n\t\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"displayTab.bounds = \" + DataExplorer.this.displayTab.getBounds()); //$NON-NLS-1$\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\tthis.displayTab.addPaintListener(new PaintListener() {\r\n\t\t\t\tpublic void paintControl(PaintEvent evt) {\r\n\t\t\t\t\tif (log.isLoggable(Level.FINER) && DataExplorer.this.displayTab.getSelectionIndex() >= 0)\r\n\t\t\t\t\t\tlog.logp(Level.FINER, $CLASS_NAME, $METHOD_NAME, \"displayTab.paintControl \" + DataExplorer.this.displayTab.getItems()[DataExplorer.this.displayTab.getSelectionIndex()].getText() //$NON-NLS-1$\r\n\t\t\t\t\t\t\t\t+ GDE.STRING_MESSAGE_CONCAT + DataExplorer.this.displayTab.getSelectionIndex() + GDE.STRING_MESSAGE_CONCAT + evt);\r\n\t\t\t\t\tif (isRecordSetVisible(GraphicsType.NORMAL)) {\r\n\t\t\t\t\t\tif (DataExplorer.this.graphicsTabItem.isCurveSelectorEnabled())\r\n\t\t\t\t\t\t\tDataExplorer.this.graphicsTabItem.setSashFormWeights(DataExplorer.this.graphicsTabItem.getCurveSelectorComposite().getSelectorColumnWidth());\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tDataExplorer.this.graphicsTabItem.setSashFormWeights(0);\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if (isRecordSetVisible(GraphicsType.COMPARE) && DataExplorer.this.compareTabItem != null) {\r\n\t\t\t\t\t\tDataExplorer.this.compareTabItem.setSashFormWeights(DataExplorer.this.compareTabItem.getCurveSelectorComposite().getSelectorColumnWidth());\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if (isRecordSetVisible(GraphicsType.UTIL) && DataExplorer.this.utilGraphicsTabItem != null) {\r\n\t\t\t\t\t\tDataExplorer.this.utilGraphicsTabItem.setSashFormWeights(DataExplorer.this.utilGraphicsTabItem.getCurveSelectorComposite().getSelectorColumnWidth());\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if (isRecordSetVisible(GraphicsType.HISTO)) {\r\n\t\t\t\t\t\tif (DataExplorer.this.histoGraphicsTabItem.isCurveSelectorEnabled())\r\n\t\t\t\t\t\t\tDataExplorer.this.histoGraphicsTabItem.setSashFormWeights(DataExplorer.this.histoGraphicsTabItem.getCurveSelectorComposite().getCompositeWidth());\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tDataExplorer.this.histoGraphicsTabItem.setSashFormWeights(0);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (DataExplorer.this.objectDescriptionTabItem != null) {\r\n\t\t\t\t\t\tif (DataExplorer.this.objectDescriptionTabItem.isVisible()) {\r\n\t\t\t\t\t\t\tif (log.isLoggable(Level.FINER)) log.logp(Level.FINER, $CLASS_NAME, $METHOD_NAME, \"displayTab.focusGained \" + evt); //$NON-NLS-1$\r\n\t\t\t\t\t\t\tDataExplorer.this.isObjectWindowVisible = true;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse if (DataExplorer.this.isObjectWindowVisible) {\r\n\t\t\t\t\t\t\tif (log.isLoggable(Level.FINER)) log.logp(Level.FINER, $CLASS_NAME, $METHOD_NAME, \"displayTab.focusLost \" + evt); //$NON-NLS-1$\r\n\t\t\t\t\t\t\tDataExplorer.this.checkSaveObjectData();\r\n\t\t\t\t\t\t\tDataExplorer.this.isObjectWindowVisible = false;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (log.isLoggable(Level.FINE) && DataExplorer.this.displayTab != null && DataExplorer.this.filler != null && DataExplorer.this.menuCoolBar != null\r\n\t\t\t\t\t\t\t&& DataExplorer.this.statusComposite != null && getSize().y != 0) {\r\n\t\t\t\t\t\tlog.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"filler.size = \" + DataExplorer.this.filler.getSize()); //$NON-NLS-1$\r\n\t\t\t\t\t\tlog.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"menuCoolBar.size = \" + DataExplorer.this.menuCoolBar.getSize()); //$NON-NLS-1$\r\n\t\t\t\t\t\tlog.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"shellClient.size = \" + new Point(getClientArea().width, getClientArea().height)); //$NON-NLS-1$\r\n\t\t\t\t\t\tlog.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"statusBar.size = \" + DataExplorer.this.statusComposite.getSize()); //$NON-NLS-1$\r\n\t\t\t\t\t\tlog.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"displayTab.bounds = \" + DataExplorer.this.displayTab.getBounds()); //$NON-NLS-1$\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\tthis.displayTab.addSelectionListener(new SelectionAdapter() {\r\n\t\t\t\t@Override\r\n\t\t\t\tpublic void widgetSelected(SelectionEvent evt) {\r\n\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"addSelectionListener, event=\" + evt); //$NON-NLS-1$\r\n\t\t\t\t\tCTabFolder tabFolder = (CTabFolder) evt.widget;\r\n\t\t\t\t\tint tabSelectionIndex = tabFolder.getSelectionIndex();\r\n\t\t\t\t\tif (tabSelectionIndex == 0) {\r\n\t\t\t\t\t\tDataExplorer.this.menuToolBar.enableScopePointsCombo(true);\r\n\t\t\t\t\t\tDataExplorer.this.enableZoomMenuButtons(true);\r\n\t\t\t\t\t\tDataExplorer.this.updateGraphicsWindow();\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if (tabSelectionIndex > 0) {\r\n\t\t\t\t\t\tif ((DataExplorer.this.displayTab.getItem(tabSelectionIndex) instanceof GraphicsWindow) && DataExplorer.this.isRecordSetVisible(GraphicsType.COMPARE)) {\r\n\t\t\t\t\t\t\tDataExplorer.this.menuToolBar.enableScopePointsCombo(false);\r\n\t\t\t\t\t\t\tDataExplorer.this.enableZoomMenuButtons(true);\r\n\t\t\t\t\t\t\tDataExplorer.this.updateGraphicsWindow();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse if ((DataExplorer.this.displayTab.getItem(tabSelectionIndex) instanceof GraphicsWindow) && DataExplorer.this.isRecordSetVisible(GraphicsType.UTIL)) {\r\n\t\t\t\t\t\t\tDataExplorer.this.menuToolBar.enableScopePointsCombo(false);\r\n\t\t\t\t\t\t\tDataExplorer.this.enableZoomMenuButtons(false);\r\n\t\t\t\t\t\t\tDataExplorer.this.updateGraphicsWindow();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse if (DataExplorer.this.displayTab.getItem(tabSelectionIndex) instanceof HistoGraphicsWindow) {\r\n\t\t\t\t\t\t\tlog.log(Level.FINER, \"HistoGraphicsWindow in displayTab.widgetSelected, event=\" + evt); //$NON-NLS-1$\r\n\t\t\t\t\t\t\tDataExplorer.this.updateHistoTabs(DataExplorer.this.rebuildStepInvisibleTab, true); // saves some time compared to HistoSet.RebuildStep.E_USER_INTERFACE\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse if (DataExplorer.this.displayTab.getItem(tabSelectionIndex) instanceof HistoTableWindow) {\r\n\t\t\t\t\t\t\tlog.log(Level.FINER, \"HistoTableWindow in displayTab.widgetSelected, event=\" + evt); //$NON-NLS-1$\r\n\t\t\t\t\t\t\tDataExplorer.this.updateHistoTabs(HistoSet.RebuildStep.E_USER_INTERFACE, true); // ensures rebuild after trails change or record selector change\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\t// drag filePath support\r\n\t\t\tthis.target = new DropTarget(this, DND.DROP_COPY | DND.DROP_DEFAULT);\r\n\t\t\tthis.target.setTransfer(this.types);\r\n\t\t\tthis.target.addDropListener(new DropTargetAdapter() {\r\n\t\t\t\t@Override\r\n\t\t\t\tpublic void dragEnter(DropTargetEvent event) {\r\n\t\t\t\t\tif (event.detail == DND.DROP_DEFAULT) {\r\n\t\t\t\t\t\tif ((event.operations & DND.DROP_COPY) != 0) {\r\n\t\t\t\t\t\t\tevent.detail = DND.DROP_COPY;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\tevent.detail = DND.DROP_NONE;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tfor (TransferData element : event.dataTypes) {\r\n\t\t\t\t\t\tif (DataExplorer.this.fileTransfer.isSupportedType(element)) {\r\n\t\t\t\t\t\t\tevent.currentDataType = element;\r\n\t\t\t\t\t\t\tif (event.detail != DND.DROP_COPY) {\r\n\t\t\t\t\t\t\t\tevent.detail = DND.DROP_NONE;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\t@Override\r\n\t\t\t\tpublic void dragOperationChanged(DropTargetEvent event) {\r\n\t\t\t\t\tif (event.detail == DND.DROP_DEFAULT) {\r\n\t\t\t\t\t\tif ((event.operations & DND.DROP_COPY) != 0) {\r\n\t\t\t\t\t\t\tevent.detail = DND.DROP_COPY;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\tevent.detail = DND.DROP_NONE;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (DataExplorer.this.fileTransfer.isSupportedType(event.currentDataType)) {\r\n\t\t\t\t\t\tif (event.detail != DND.DROP_COPY) {\r\n\t\t\t\t\t\t\tevent.detail = DND.DROP_NONE;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\t@Override\r\n\t\t\t\tpublic void drop(DropTargetEvent event) {\r\n\t\t\t\t\tif (DataExplorer.this.fileTransfer.isSupportedType(event.currentDataType)) {\r\n\t\t\t\t\t\tString[] files = (String[]) event.data;\r\n\t\t\t\t\t\tfor (String filePath : files) {\r\n\t\t\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"dropped file = \" + filePath); //$NON-NLS-1$\r\n\t\t\t\t\t\t\tif (filePath.toLowerCase().endsWith(GDE.FILE_ENDING_OSD)) {\r\n\t\t\t\t\t\t\t\tDataExplorer.this.fileHandler.openOsdFile(filePath);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\telse if (filePath.toLowerCase().endsWith(GDE.FILE_ENDING_LOV)) {\r\n\t\t\t\t\t\t\t\tDataExplorer.this.fileHandler.openLovFile(filePath);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t\tapplication.openMessageDialog(Messages.getString(MessageIds.GDE_MSGI0022));\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"init help listener\"); //$NON-NLS-1$\r\n\t\t\tthis.menuCoolBar.addHelpListener(new HelpListener() {\r\n\t\t\t\tpublic void helpRequested(HelpEvent evt) {\r\n\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"this.helpRequested, event=\" + evt); //$NON-NLS-1$\r\n\t\t\t\t\tDataExplorer.application.openHelpDialog(GDE.STRING_EMPTY, \"HelpInfo_3.html\"); //$NON-NLS-1$\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\tthis.menu.addHelpListener(new HelpListener() {\r\n\t\t\t\tpublic void helpRequested(HelpEvent evt) {\r\n\t\t\t\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"this.helpRequested, event=\" + evt); //$NON-NLS-1$\r\n\t\t\t\t\tDataExplorer.application.openHelpDialog(GDE.STRING_EMPTY, \"HelpInfo_3.html\"); //$NON-NLS-1$\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\t//restore window settings\r\n\t\t\tthis.isRecordCommentVisible = this.settings.isRecordCommentVisible();\r\n\t\t\tif (this.isRecordCommentVisible) {\r\n\t\t\t\tthis.menuBar.setRecordCommentMenuItemSelection(this.isRecordCommentVisible);\r\n\t\t\t\tthis.enableRecordSetComment(this.isRecordCommentVisible);\r\n\t\t\t}\r\n\t\t\tthis.isGraphicsHeaderVisible = this.settings.isGraphicsHeaderVisible();\r\n\t\t\tif (this.isGraphicsHeaderVisible) {\r\n\t\t\t\tthis.menuBar.setGraphicsHeaderMenuItemSelection(this.isGraphicsHeaderVisible);\r\n\t\t\t\tthis.enableGraphicsHeader(this.isGraphicsHeaderVisible);\r\n\t\t\t}\r\n\r\n\t\t\tthis.deviceSelectionDialog = new DeviceSelectionDialog(GDE.shell, SWT.PRIMARY_MODAL, this);\r\n\r\n\t\t\tif (!this.settings.isDesktopShortcutCreated()) {\r\n\t\t\t\tthis.settings.setProperty(Settings.IS_DESKTOP_SHORTCUT_CREATED, GDE.STRING_EMPTY + OperatingSystemHelper.createDesktopLink());\r\n\t\t\t}\r\n\r\n\t\t\tif (!this.settings.isApplicationRegistered()) {\r\n\t\t\t\tthis.settings.setProperty(Settings.IS_APPL_REGISTERED, GDE.STRING_EMPTY + OperatingSystemHelper.registerApplication());\r\n\t\t\t}\r\n\r\n\t\t\tif ((GDE.IS_MAC || GDE.IS_LINUX) && !this.settings.isLockUucpHinted()) {\r\n\t\t\t\tif (GDE.IS_MAC && !OperatingSystemHelper.isUucpMember())\r\n\t\t\t\t\tthis.openMessageDialog(Messages.getString(MessageIds.GDE_MSGI0046));\r\n\t\t\t\telse if (GDE.IS_LINUX && !OperatingSystemHelper.isUucpMember()) this.openMessageDialog(Messages.getString(MessageIds.GDE_MSGI0045));\r\n\t\t\t\tthis.settings.setProperty(Settings.IS_LOCK_UUCP_HINTED, \"true\"); //$NON-NLS-1$\r\n\t\t\t}\r\n\r\n\t\t\t// check initial application settings\r\n\t\t\tif (!this.settings.isOK()) {\r\n\t\t\t\tthis.openSettingsDialog();\r\n\t\t\t}\r\n\t\t\t//wait for possible migration and delay opening for migration\r\n\t\t\tthis.settings.startMigationThread();\r\n\t\t\t// check configured device\r\n\t\t\tif (this.settings.getActiveDevice().equals(Settings.EMPTY)) {\r\n\t\t\t\tthis.deviceSelectionDialog = new DeviceSelectionDialog(GDE.shell, SWT.PRIMARY_MODAL, this);\r\n\t\t\t\tthis.deviceSelectionDialog.open();\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t// channels HashMap will filled with empty records matching the active device, the dummy content is replaced\r\n\t\t\t\tthis.deviceSelectionDialog.setupDevice();\r\n\t\t\t}\r\n\r\n\t\t\tif (inputFilePath.length() > 5) {\r\n\t\t\t\tif (inputFilePath.endsWith(GDE.FILE_ENDING_OSD))\r\n\t\t\t\t\tthis.fileHandler.openOsdFile(inputFilePath);\r\n\t\t\t\telse if (inputFilePath.endsWith(GDE.FILE_ENDING_LOV)) this.fileHandler.openLovFile(inputFilePath);\r\n\t\t\t}\r\n\t\t}\r\n\t\tcatch (Exception e) {\r\n\t\t\tlog.log(Level.SEVERE, e.getMessage(), e);\r\n\t\t\tthis.openMessageDialog(Messages.getString(MessageIds.GDE_MSGE0007) + e.getMessage());\r\n\t\t}\r\n\t\tif (log.isLoggable(Level.FINE)) log.logp(Level.FINE, $CLASS_NAME, $METHOD_NAME, \"call GDE.shell.layout()\"); //$NON-NLS-1$\r\n\t\tGDE.shell.layout();\r\n\t\tthis.updateLogger();\r\n\t}",
"public ConfigureUpdatesDialog() {\n super(StrangeEons.getWindow(), ModalityType.TOOLKIT_MODAL);\n initComponents();\n AbstractGameComponentEditor.localizeComboBoxLabels(frequencyCombo, null);\n AbstractGameComponentEditor.localizeComboBoxLabels(actionCombo, null);\n banner.setIcon(new ImageIcon(\n ResourceKit.createBleedBanner(((ImageIcon) banner.getIcon()).getImage())\n ));\n setLocationRelativeTo(getParent());\n\n Settings s = Settings.getUser();\n s.set(\"core-dialog-shown\", \"yes\");\n //doNotShowCheck.setSelected( s.getYesNo( \"core-dialog-autoinstall\" ) );\n\n frequencyCombo.setSelectedIndex(AutomaticUpdater.getUpdateFrequency());\n actionCombo.setSelectedIndex(AutomaticUpdater.getUpdateAction() == 0 ? 0 : 1);\n newPluginsCheck.setSelected(AutomaticUpdater.isShowingNewPlugins());\n appUpdateCheck.setSelected(AutomaticUpdater.isShowingAppUpdates());\n doneInit = true;\n }",
"void onListenerChanged(ListenerUpdate update);",
"public interface DialogListener {\n void onOk();\n void onCancel();\n}",
"private void initListeners() {\n comboBox.comboBoxListener(this::showProgramData);\n view.refreshListener(actionEvent -> scheduledUpdate());\n\n }",
"public void onFinishFetching() {\n\t\t\t\thideLoading();\n\t\t\t\tUiApplication.getUiApplication().invokeLater(\n\t\t\t\t\tnew Runnable() {\n\t\t\t\t\t\t\n\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\tAlertDialog.showInformMessage(message);\n\t\t\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t\t\t// TODO: handle exception\n\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tUiApplication.getUiApplication().pushScreen(new HomeScreen());\n\t\t\t\t\t\t}\n\t\t\t\t\t});\t\t\t\t\n\t\t\t}",
"@Override\n\tpublic void handleUpdateUI(String text, int code) {\n\t\t\n\t}",
"public void onEntry()\n\t{\n\t}",
"public interface UiUpdate {\n\n void onLogin(String message);\n\n void onSuccess(String message);\n\n void onActionNotValid(String errorCode);\n\n void onChooseNetwork (String message);\n\n void onTurnStart(Match match, String nickname);\n\n void onPlaceDiceNotValid(String message);\n\n void onGameUpdate(Match match, String nickname);\n\n void onGameEnd(Match match);\n\n void onSchemeToChoose(Match match, String nickname, String message);\n\n void onUseToolCardNotValid(int id, Match match, String message);\n\n //void onUseToolCard12IIStepNotValid(Match match, String e);\n\n void onOtherInfoToolCard(int id, Match match);\n\n void onPlayerDisconnection(String message, String nickname);\n\n}",
"@Override\n public void run() {\n boolean pvp_net;\n //Start with negative state:\n pvp_net_changed(false);\n \n Window win = null;\n\n while(!isInterrupted()||true) {\n //Check whether window is running\n if(win==null) {\n win = CacheByTitle.initalInst.getWindow(ConstData.window_title_part);\n //if(win==null)\n // Logger.getLogger(this.getClass().getName()).log(Level.INFO, \"Window from name failed...\");\n }\n else if(!win.isValid()) {\n win = null;\n //Logger.getLogger(this.getClass().getName()).log(Level.INFO, \"Window is invalid...\");\n }\n else if(\n main.ToolRunning() && \n main.settings.getBoolean(Setnames.PREVENT_CLIENT_MINIMIZE.name, (Boolean)Setnames.PREVENT_CLIENT_MINIMIZE.default_val) &&\n win.isMinimized()) {\n win.restoreNoActivate();\n }\n pvp_net = win!=null;\n //On an change, update GUI\n if(pvp_net!=pvp_net_running) {\n pvp_net_changed(pvp_net);\n }\n \n /*thread_running = main.ToolRunning();\n if(thread_running!=automation_thread_running)\n thread_changed(thread_running);*/\n\n try {\n sleep(900L);\n //Wait some more if paused\n waitPause();\n }\n catch(InterruptedException e) {\n break; \n }\n } \n }",
"@Override\n\tpublic void updateProgessDialog(String title, String message, boolean visible, Integer increment) {\n\t\t\n\t}",
"@Override\r\n\t\t\tpublic void run() {\n\t\t\t\tDownloadDialog dialog = new DownloadDialog(Database.currentActivity, text, list);\r\n\t\t\t\tdialog.show();\r\n\t\t\t}",
"private void onUpdateSelected() {\r\n mUpdaterData.updateOrInstallAll_WithGUI(\r\n null /*selectedArchives*/,\r\n false /* includeObsoletes */,\r\n 0 /* flags */);\r\n }",
"private void helperAcceptButtonListener() {\n refresh();\n editDialog.dispose();\n }",
"@Override\n public void onThinking() {\n toast(\"Processing\");\n showDialog();\n }",
"public void run() {\n String lg_ti = \"Test.\";\n String des_ti = \"The license valid until \";\n String ban_ti = \"Warning!\";\n getNotificationData();\n //notificationShow(des_ti,lg_ti,ban_ti);\n }",
"public void prepareBroadcast() {\r\n\t\ttheDialog.show();\r\n\t\ttry {\r\n\t\t\tthePres= new SimplePres( new QTFile( theDialog.getDirectory() + theDialog.getFile()), theCanvas );\r\n\t\t\tsetTitle(theDialog.getFile());\r\n\t\t\ttheCanvas.setClient( thePres.pDrawer, true );\r\n\r\n\t\t\tif (drawer == null)\r\n\t\t\t{\r\n\t\t\t\tdrawer = new StatDrawer(thePres);\t// draws the rate and time information\r\n\t\t\t\tdrawer.timeLabel = currTimeLabel;\r\n\t\t\t\tdrawer.rateLabel = currRateLabel;\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t\tdrawer.setPres(thePres);\r\n\t\t}\r\n\t\tcatch (QTException qte) {\r\n\t\t\tqte.printStackTrace();\r\n\t\t} \r\n\t}",
"public void doUpdate() {\n Map<String, List<String>> dataToSend = new HashMap<>();\r\n List<String> values = new ArrayList<>();\r\n values.add(String.valueOf(selectedOhsaIncident.getId()));\r\n dataToSend.put(\"param\", values);\r\n showDialog(dataToSend);\r\n }",
"private void dialogChanged() {\n\t\tIResource container = ResourcesPlugin.getWorkspace().getRoot()\n\t\t\t\t.findMember(new Path(getContainerName().get(\"ProjectPath\")));\n\n\t\tif(!containerSourceText.getText().isEmpty() && !containerTargetText.getText().isEmpty())\n\t\t{\n\t\t\tokButton.setEnabled(true);\n\t\t}\n\n\t\tif (getContainerName().get(\"ProjectPath\").length() == 0) {\n\t\t\tupdateStatus(\"File container must be specified\");\n\t\t\treturn;\n\t\t}\n\t\tif (container == null\n\t\t\t\t|| (container.getType() & (IResource.PROJECT | IResource.FOLDER)) == 0) {\n\t\t\tupdateStatus(\"File container must exist\");\n\t\t\treturn;\n\t\t}\n\t\tif (!container.isAccessible()) {\n\t\t\tupdateStatus(\"Project must be writable\");\n\t\t\treturn;\n\t\t}\n\t\tupdateStatus(null);\n\t}",
"@Override\n public void updateWindow(MessageToVirtualView update) {\n if(!update.isModelRep())\n {\n JOptionPane.showMessageDialog(lobbyWindowFrame,update.getMessage().getMessage());\n }\n }",
"public interface UiObserver {\n\n void update(String string);\n\n void updateConnection(String ip, String port);\n\n}",
"@Override\n public void onFinish() {\n WorldEdit.getInstance().getEventBus().register(new me.ddevil.mineme.mines.MineManager.WorldEditManager());\n registerBaseCommands();\n if (useMVdWPlaceholderAPI) {\n try {\n MVdWPlaceholderManager.setupPlaceholders();\n } catch (Exception ex) {\n printException(\"There was an error creting MVdWPlaceholder! Skipping\", ex);\n }\n }\n if (convertMineResetLite) {\n MineMe.instance.debug(\"Converting MineResetLite...\", true);\n MRLConverter.convert();\n MineMe.instance.debug(\"Converted MineResetLite!\", true);\n }\n debug(\"Starting metrics...\", 3);\n try {\n Metrics metrics = new Metrics(MineMe.this);\n metrics.start();\n debug(\"Metrics started!\", 3);\n } catch (IOException ex) {\n printException(\"There was an error start metrics! Skipping\", ex);\n }\n Bukkit.getScheduler().scheduleSyncDelayedTask(instance, new Runnable() {\n\n @Override\n public void run() {\n debug(\"Starting MineEditorGUI...\", 3);\n GUIManager.setup();\n debug(\"MineEditorGUI started!\", 3);\n }\n }, 2l);\n }",
"void addListeners() {\n\n loginButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n // TODO add loading bar\n String name = loginNameBox.getText();\n\n if (name.contains(\"Enter\")) {\n name = \"n00b\";\n }\n\n if(name.contains(\" \")){\n name = name.replace(' ','_');\n }\n try {\n loginBar.setVisible(true);\n //TODO add loading thread\n\n client = new Client(name);\n\n frame.setTitle(\"Player \" + client.getId() + \": (\" + client.getName() + \")\");\n frame.loginScreen.setVisible(false);\n frame.menuScreen.setVisible(true);\n\n updateThread = new Thread(new Runnable() { // TODO thread to update game state\n @Override\n public void run() {\n try {\n while (true) {\n frame.updateState();\n Thread.sleep(1000);\n }\n } catch (Exception e) {\n // e.printStackTrace();\n }\n }\n });\n\n String[] playerBall = client.whoIsBall();\n frame.ballState(false, playerBall[0]);\n updateThread.start();\n } catch (Exception error) {\n JOptionPane.showMessageDialog(null, error.getMessage());\n }\n\n }\n });\n\n loginNameBox.addKeyListener(new KeyAdapter() {\n @Override\n public void keyPressed(KeyEvent k) {\n if (loginNameBox.getText().contains(\"Enter\")) {\n loginNameBox.setText(\"\");\n }\n }\n });\n\n menuThrowButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n client.throwToPlayer(menuPlayersComboBox.getSelectedItem().toString());\n }\n });\n\n menuRefreshButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n updateComboBox();\n }\n\n });\n\n this.addWindowListener(new WindowAdapter() { // Executes when window is closed\n public void windowClosing(WindowEvent e) {\n // closes client connection if window closed\n try {\n if (updateThread.isAlive()) {\n updateThread.interrupt();\n }\n } catch (Exception ex) {\n }\n\n try {\n client.close();\n } catch (Exception ex) {\n }\n\n System.out.println(\"Goodbye\");\n }\n });\n }",
"public interface NoticeDialogListener{\n public void onDialogAlbumPhotoClick();\n public void onDialogTakePhotoClick();\n }",
"public void run() {\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\tAlertDialog.showInformMessage(message);\n\t\t\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t\t\t// TODO: handle exception\n\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tUiApplication.getUiApplication().pushScreen(new HomeScreen());\n\t\t\t\t\t\t}",
"public interface MotorActionSelectDialogListener {\n /**\n * Just a callback method.\n * @param dialog finished dialog\n * @param which dialog's id\n * @param motor selected motor\n * @param direction selected motor's direction\n */\n void onMotorActionSet(DialogInterface dialog, int which, String motor, String direction);\n }",
"@Override\n public void onUpdateCheckListener(String url) {\n AlertDialog alertDialog = new AlertDialog.Builder(this)\n .setTitle(getString(R.string.update_title))\n .setMessage(getString(R.string.update_message))\n .setPositiveButton(getString(R.string.update_option), (dialog, which) -> {\n // setting update url to retrieve later on permission grant listener\n UpdateHelper.setKeyUpdateUrl(url);\n downloadApk(url);\n }).setNegativeButton(getString(R.string.dismiss_text), (dialog, which) -> dialog.dismiss()).create();\n alertDialog.show();\n\n }",
"public interface ManagerListener extends EventListener {\r\n\t\r\n\t/**\r\n\t * Method to notify that a manager has joined the application.\r\n\t *\r\n\t * @param e the event\r\n\t */\r\n\tpublic void managerAdded(ManagerEvent e);\r\n\t\r\n\t/**\r\n\t * Method to notify that a manager's active model has been modified\r\n\t * to reflect a new design task.\r\n\t *\r\n\t * @param e the event\r\n\t */\r\n\tpublic void managerModelModified(ManagerEvent e);\r\n\t\r\n\t/**\r\n\t * Method to notify that a manager's output has been modified to \r\n\t * reflect a new set of inputs from designers.\r\n\t *\r\n\t * @param e the event\r\n\t */\r\n\tpublic void managerOutputModified(ManagerEvent e);\r\n\t\r\n\t/**\r\n\t * Method to notify that a manger has left the application.\r\n\t *\r\n\t * @param e the event\r\n\t */\r\n\tpublic void managerRemoved(ManagerEvent e);\r\n}",
"void onOpen();",
"@Override\n\tpublic void onUpdate() {\n\t\tlistener.onUpdate();\n\t}",
"private void dialogChanged() {\n\t\tString fileName = getFileName();\n\t\tString dirStr = getPathStr();\n\n\t\tif (dirStr.length() == 0) {\n\t\t\tupdateStatus(\"Directory must be specified\");\n\t\t\treturn;\n\t\t}\n\n\t\tif (fileName == null || fileName.length() == 0) {\n\t\t\tupdateStatus(\"File name must be specified\");\n\t\t\treturn;\n\t\t}\n\t\tif (fileName.replace('\\\\', '/').indexOf('/', 1) > 0) {\n\t\t\tupdateStatus(\"File name must be valid\");\n\t\t\treturn;\n\t\t}\n\t\tupdateStatus(null);\n\t}",
"public interface DialogButtonListener {\n\n void buttonClicked(String buttonText);\n\n}",
"public interface SettingsDialogListener { \n\t\tpublic void onSettingsPositiveClick(DialogFragment dialog); \n\t\tpublic void onSettingsNegativeClick(DialogFragment dialog); \n\t}",
"public void receiveData() {\n runOnUiThread(new Runnable() {\n public void run() {\n //menuBool=true;\n TextView rpm = (TextView) findViewById(R.id.rpm);\n rpm.setText(DataHandler.getInstance().getLastValue());\n int max = (pref.getBoolean(\"demo\", false)) ? 50 : 120;\n if (DataHandler.getInstance().getLastIntValue() > max &&\n !callPlaced &&\n !alert.isShowing() &&\n !ignoreHeartRate) {\n alert.show();\n\n// Hide after some seconds\n final Handler handler = new Handler();\n final Runnable runnable = new Runnable() {\n @Override\n public void run() {\n if (alert.isShowing()) {\n alert.dismiss();\n callHelp(MainActivity.this);\n callPlaced = true;\n }\n }\n };\n\n alert.setOnDismissListener(new DialogInterface.OnDismissListener() {\n @Override\n public void onDismiss(DialogInterface dialog) {\n handler.removeCallbacks(runnable);\n }\n });\n\n handler.postDelayed(runnable, 15000);\n }\n }\n });\n }"
] | [
"0.63924456",
"0.6272692",
"0.62588984",
"0.6194653",
"0.61095226",
"0.6094304",
"0.599431",
"0.5987251",
"0.59410673",
"0.5904902",
"0.5901505",
"0.5886782",
"0.5883253",
"0.58678716",
"0.58462036",
"0.58377475",
"0.5835879",
"0.58311945",
"0.58193594",
"0.5818849",
"0.5816775",
"0.5803185",
"0.57824916",
"0.57679266",
"0.5763478",
"0.57631147",
"0.5734406",
"0.5732551",
"0.5721045",
"0.5713635",
"0.57132196",
"0.5712206",
"0.56966716",
"0.56806844",
"0.56769556",
"0.56596816",
"0.56571835",
"0.5656731",
"0.56548595",
"0.56540906",
"0.56537586",
"0.5652758",
"0.56524754",
"0.56499577",
"0.56425554",
"0.5630398",
"0.56298774",
"0.56175786",
"0.5607886",
"0.5601042",
"0.5592121",
"0.5584337",
"0.55832607",
"0.5572297",
"0.5566703",
"0.55660367",
"0.55642515",
"0.5563366",
"0.55533767",
"0.5550738",
"0.5547893",
"0.5509787",
"0.55059",
"0.5505614",
"0.5501314",
"0.5490253",
"0.54885995",
"0.548724",
"0.5485884",
"0.5484839",
"0.5483934",
"0.5475223",
"0.547507",
"0.5474366",
"0.54705447",
"0.546964",
"0.54693335",
"0.5460778",
"0.5454975",
"0.5454018",
"0.54489213",
"0.5442124",
"0.54403144",
"0.5438307",
"0.5433335",
"0.54317766",
"0.54221135",
"0.5419946",
"0.54198796",
"0.54187244",
"0.54158187",
"0.5410555",
"0.5400942",
"0.5400724",
"0.53959",
"0.53900623",
"0.5384972",
"0.538391",
"0.5381797",
"0.53800386",
"0.5378993"
] | 0.0 | -1 |
attempts to initialize the listener that UnifedMain will eventually use onAttach uses Context and converts to Activity par Android's depreciating direct usage of Activity in onAttach | @Override
public void onAttach(Context context){
super.onAttach(context);
Activity activity = (Activity) context;
if (context instanceof Activity){
activity = (Activity) context;
}
try{
listener = (StationFragmentListener) activity;
}
catch(ClassCastException e){
throw new ClassCastException(activity.toString()
+ " must implement NoticeDialogListener");
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n\n if (context instanceof MainActivity) {\n this.mainActivity = (MainActivity) context;\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n\n //Log.d(\"DEBUGAPP\", TAG + \" onAttach\");\n\n if (activity instanceof MainActivity) {\n mainActivity = (MainActivity) activity;\n }\n }",
"@Override\n public void onAttach(@NonNull Context context) {\n super.onAttach(context);\n\n try {\n dListener = (dialogListener) context; // dialog interface is equal to activity instance\n } catch (ClassCastException e) {\n // in case dialogListener didnt implemented\n throw new ClassCastException(context.toString() + \"must Implement dialogListener interface to MainActivity First\");\n }\n }",
"@Override\n public void onAttach(@NonNull Context context) {\n super.onAttach(context);\n mIMainActivity = (IMainActivity) getActivity();\n }",
"protected void onAttachToContext(Context context) {\n if (context instanceof Activity) {\n this.listener = (FragmentActivity) context;\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n\n // This makes sure that the host activity has implemented the callback interface\n // If not, it throws an exception\n try {\n mCallback = (OnStepClickListener) context;\n } catch (ClassCastException e) {\n throw new ClassCastException(context.toString()\n + \" must implement OnStepClickListener\");\n }\n }",
"@SuppressWarnings(\"deprecation\")\n @Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n if (Build.VERSION.SDK_INT < Build.VERSION_CODES.M) {\n onAttachToContext(activity);\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n if (context instanceof MainActivity){\n mA =(MainActivity) context;\n }\n }",
"@SuppressWarnings(\"deprecation\")\n @Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n if (Build.VERSION.SDK_INT < 23) {\n onAttachToContext(activity);\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n this.vsMain = (VsMainActivity) activity;\n }",
"@SuppressWarnings(\"deprecation\")\n @Override public void onAttach(Activity activity) {\n super.onAttach(activity);\n if (Build.VERSION.SDK_INT < 23) {\n onAttachToContext(activity);\n }\n }",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t\tcontext = activity;\n\t}",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n this.context = activity;\n }",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\n\t\tcontext = activity;\n\t}",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n mMesasListListener = (MesasListListener) getActivity();\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the SelectPetDialogListener so we can send events to the host\n listener = (SelectPetDialogListener) context;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(\"Activity must implement AddPetDialogListener\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n // get a reference to the hosting activity in listener, works bc host activity must implement interface\n listener = (OnFragmentInteractionListener) context;\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n // Ensure attached activity has implemented the callback interface.\n try {\n // Acquire the implemented callback\n mLoginFinishBtnClickListener = (onLoginFinishBtnClickListener) context;\n } catch (ClassCastException e) {\n // If not, it throws an exception\n throw new ClassCastException(context.toString() + \" must implement onLoginFinishBtnClickListener\");\n }\n }",
"private void myOnAttach(Context context) {\n\n if (context instanceof LoginFragmentInteractionListener) {\n mListener = (LoginFragmentInteractionListener) context;\n } else {\n throw new RuntimeException(context.toString()\n + \" must implement LoginFragmentInteractionListener\");\n }\n }",
"@SuppressWarnings(\"deprecation\")\n @Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n if (Build.VERSION.SDK_INT < Build.VERSION_CODES.M) {\n commonOnAttach(activity);\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n\n Log.v(TAG, \"on attach\");\n callback = (Callback)activity;\n }",
"@TargetApi(23)\n @Override\n public void onAttach(Context context) {\n super.onAttach(context);\n onAttachToContext(context);\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n if (context instanceof ComposeTweetListener) {\n mTweetListener = (ComposeTweetListener) context;\n } else {\n throw new ClassCastException(context.toString()\n + \" must implement ComposeTweetFragment.ComposeTweetListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n context=activity;\n userPreferences = new UserPreferences(context);\n jobManager = new JobManager(context);\n }",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t\tmyContext=(FragmentActivity) activity;\n\t}",
"@Override\r\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\r\n\t\tmActivity = activity;\r\n\t\tstartAppAd = new StartAppAd(activity);\r\n\t}",
"public void activityCreated(Context ctx){\n //set Activity context - in this case there is only MainActivity\n mActivityContext = ctx;\n }",
"@Override\n\tpublic void initContext(Activity act) {\n\t\tthis._activity = act;\n\t}",
"@SuppressWarnings(\"deprecation\")\n @Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n callEvents = (MesiboVideoCallFragment.OnCallEvents) activity;\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n\n // This makes sure that the host activity has implemented the callback interface\n // If not, it throws an exception\n try {\n mOnClickHandler = (RecipeDetailFragmentStepAdapter.OnRecipeStepClickHandler) context;\n mRecipeDetailHandler = (RecipeDetailHandler) context;\n } catch (ClassCastException e) {\n throw new ClassCastException(context.toString()\n + \" must implement RecipeDetailFragmentStepAdapter.OnRecipeStepClickHandler AND RecipeDetailHandler\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n if (callbackManager != null) callbackManager.setActivity(activity);\n }",
"@Override\r\n public void onAttach(Context context) {\r\n super.onAttach(context);\r\n }",
"public abstract void onAttach();",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t\tif (getActivity() == null)\n\t\t\tcontext = activity;\n\t\telse\n\t\t\tcontext = getActivity();\n\n\t}",
"@Override\r\n public void onAttach(Activity activity) {\n super.onAttach(activity);\r\n\r\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n fragmentCallBack = (MainActivity) activity;// ActivityʵfragmentCallBack\n }",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t}",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t}",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t}",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n if (context instanceof ParadasFragment.FragmentFromFragment) {\n fragmentFromFragmentListener = (ParadasFragment.FragmentFromFragment) context;\n } else {\n throw new ClassCastException(context.toString() + \" must implements MainScreenFragment.OnNewSurveyClicked\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n Activity activity = getActivity();\n try {\n appBarHandler = ((HasAppBarHandler) activity).getAppBarHandler();\n } catch (ClassCastException e) {\n throw new ClassCastException(activity + \" must implement HasAppBarHandler\");\n }\n PLYAndroidHolder plyAndroidHolder;\n try {\n plyAndroidHolder = ((HasPLYAndroidHolder) activity).getPLYAndroidHolder();\n } catch (ClassCastException e) {\n throw new ClassCastException(activity + \" must implement HasPLYAndroidHolder\");\n }\n client = plyAndroidHolder.getPLYAndroid();\n if (client == null) {\n throw new RuntimeException(\"PLYAndroid must bet set before creating fragment \" + this);\n }\n // execute some of the queries sequentially (i.e. creating product, uploading image and info)\n sequentialClient = client.copyForOrderedThreadExecution();\n }",
"@Override\r\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\r\n\t}",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n mContext = getActivity();\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n try{\n// mCallback = (FragmentIterationListener) activity;\n// }catch(CastClassException ex){\n }catch(Exception ex){\n Log.e(MovimientoListFragment.TAG, \"El Activity debe implementar la interfaz FragmentIterationListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n \tthis.activity = activity;\n \t\n \tsuper.onAttach(activity);\n \n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the NoticeDialogListener so we can send events to the host\n mListener = (NoticeDialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement NoticeDialogListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity)\n {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try\n {\n // Instantiate the RestartGameDialogListener so we can send events\n // to the host\n mListener = (RestartGameDialogListener)activity;\n }\n catch (ClassCastException e)\n {\n throw new ClassCastException(activity.toString()\n + \" must implement RestartGameDialogListener\");\n }\n }",
"private void initiateActivity() {\r\n\t\tif (application == null) {\r\n\t\t\tthis.application = SmartApplication.REF_SMART_APPLICATION;\r\n\t\t}\r\n\r\n\t\ttry {\r\n\t\t\tif (application.attachedCrashHandler)\r\n\t\t\t\tCrashReportHandler.attach(this);\r\n\t\t} catch (Throwable e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfinish();\r\n\t\t}\r\n\r\n\t\tif (setLayoutView() != null) {\r\n\t\t\tsetContentView(setLayoutView());\r\n\t\t} else {\r\n\t\t\tsetContentView(setLayoutId());\r\n\t\t}\r\n\r\n\t}",
"@Override\n public void onAttach(Activity activity) {\n \tsuper.onAttach(activity);\n \tthis.act=activity;\n \t\n try{\n mCallback = (FragmentIterationListener) activity;\n }catch(ClassCastException ex){\n Log.e(\"ExampleFragment\", \"El Activity debe implementar la interfaz FragmentIterationListener\");\n }\n }",
"@Override\r\n public void onAttach(Activity activity) {\n super.onAttach(activity);\r\n act = (BaseActivity) activity;\r\n\r\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the NoticeDialogListener so we can send events to the host\n mListener = (Listener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement NoticeDialogListener\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n if (context instanceof ProgrammingLangC_BookmarkFragmentProgram.OnFragmentInteractionListener) {\n mListener = (ProgrammingLangC_BookmarkFragmentProgram.OnFragmentInteractionListener) context;\n } else {\n throw new RuntimeException(context.toString()\n + \" must implement OnFragmentInteractionListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n\n try {\n mListener = (IFragmentListener) activity;\n } catch (ClassCastException e) {\n throw new ClassCastException(activity.toString() + \" must implement IFragmentListener\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n mcontext = context;\n super.onAttach( context );\n }",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t\tlistenr = (CheckStateListener) getActivity();\n\t}",
"@Override\n\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the listener so we can send events to the host\n mListener = (TrackPlayerDialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement TrackPlayerDialogListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the NoticeDialogListener so we can send events to the host\n mListener = (NewProjectDialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement NoticeDialogListener\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n\n Log.d(TAG, \"onAttach\");\n\n if(context instanceof SurveyVoteListener){\n mVoteListener = (SurveyVoteListener) context;\n Log.d(TAG, \"On attach survey vote listener set \" + mVoteListener);\n } else {\n throw new RuntimeException(context.toString() + \" must implement SurveyVoteListener\");\n }\n }",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t\tmContext = getActivity();\n\t}",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n\n // This makes sure that the host activity has implemented the callback interface\n // If not, it throws an exception\n try {\n paginationHandler = (PaginationHandler) context;\n } catch (ClassCastException e) {\n Timber.d(\"PaginationHandler is not set. Must be a tablet then.\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n if (context instanceof FragmentTwo.fragmentTwoInterface) {\n listener = (FragmentTwo.fragmentTwoInterface) context;\n }\n else {\n throw new RuntimeException();\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the NoticeDialogListener so we can send events to the host\n mListener = (DialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement NoticeDialogListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the NoticeDialogListener so we can send events to the host\n mListener = (VoidReasonDialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement VoidReasonDialogListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the NoticeDialogListener so we can send events to the host\n mListener = (NoticeDialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement NoticeDialogListener\");\n }\n }",
"@Override\r\n\t\tpublic void onAttach(Activity activity) {\n\t\t\tsuper.onAttach(activity);\r\n\t\t\tmCallback=(Fragment_Listener)activity;\r\n\t\t\t\r\n\t\t}",
"@Override\r\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\r\n\t\tthis.mActivity = activity;\r\n\t}",
"@Override\n\tpublic void onAttach(Context context) {\n\t\tsuper.onAttach(context);\n\t\tmContext = getActivity();\n\t}",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tthis.activity = activity;\n\t\tsuper.onAttach(activity);\n\t}",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the NoticeDialogListener so we can send events to the host\n dialogListener = (AddContractDialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString() + \" must implement AddContractDialogListener\");\n }\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the SetPasswordDialogListener so we can send events to the host\n deleteUserPromptListener = (DeleteUserPrompt.DeleteUserPromptListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement DeleteUserPromptListener\");\n }\n }",
"@Override\n\tpublic void onAttach(final Activity activity) {\n\t\tsuper.onAttach(activity);\n\t\t// Verify that the host activity implements the callback interface\n\t\ttry {\n\t\t\t// Instantiate the NoticeDialogListener so we can send events to the\n\t\t\t// host\n\t\t\tmListener = (NoticeDialogListener) activity;\n\t\t} catch (final ClassCastException e) {\n\t\t\t// The activity doesn't implement the interface, throw exception\n\t\t\tthrow new ClassCastException(activity.toString()\n\t\t\t\t\t+ \" must implement NoticeDialogListener\");\n\t\t}\n\t}",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n // Verify that the host activity implements the callback interface\n try {\n // Instantiate the SettingsManualInputDialogListener so we can send events to the host\n mListener = (SettingsManualInputDialogListener) activity;\n } catch (ClassCastException e) {\n // The activity doesn't implement the interface, throw exception\n throw new ClassCastException(activity.toString()\n + \" must implement SettingsManualInputDialogListener\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n if (context instanceof OnFragmentInteractionListener) {\n mListener = (OnFragmentInteractionListener) context;\n } else {\n throw new RuntimeException(context.toString()\n + \" must implement OnFragmentInteractionListener\");\n }\n }",
"@Override\r\n public void onAttach(Context context) {\r\n super.onAttach(context);\r\n if (context instanceof OnFragmentInteractionListener) {\r\n mListener = (OnFragmentInteractionListener) context;\r\n } else {\r\n throw new RuntimeException(context.toString()\r\n + \" must implement OnFragmentInteractionListener\");\r\n }\r\n }",
"@Override\n public void onAttach(Activity activity){\n super.onAttach(activity);\n\n //refer the listener variable declared above to the host activity when the fragment is attached\n listener = (AddEditCardListener) activity;\n }",
"public interface ActivityAware<E> {\r\n E getContextActivity();\r\n}",
"@Override\n public void onAttach(@NotNull Context context) {\n AndroidSupportInjection.inject(this);\n super.onAttach(context);\n }",
"@Override\n public void onAttach(@NotNull Context context) {\n AndroidSupportInjection.inject(this);\n super.onAttach(context);\n }",
"public void onAttach(Activity activity){\n super.onAttach(activity);\n\n try{\n ENVIAR = (Enviar) activity;\n }\n catch (ClassCastException e ){\n throw new ClassCastException(\"necesitas el msg\");\n }\n\n\n }",
"@Override\n public void onAttach(@NonNull final Context context) {\n AndroidSupportInjection.inject(this);\n super.onAttach(context);\n }",
"@Override\n public void onAttach(@NonNull final Context context) {\n AndroidSupportInjection.inject(this);\n super.onAttach(context);\n }",
"@Override\r\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\r\n\t\tfbcl=(fragmentBtnClickListener) activity;\r\n\t}",
"@Override\n\tpublic void onActivityCreated(Bundle savedInstanceState) {\n\t\tsuper.onActivityCreated(savedInstanceState);\n\n\t\tmContext = (LFActivity) getActivity();\n\t\tinit();\n\t}",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n if(context instanceof OnMap){\n mOnMap = (OnMap) context;\n }\n }",
"@Override\n\tprotected void onAttachedToActivity() {\n\t\tsuper.onAttachedToActivity();\n\t}",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n\n // This makes sure that the container activity has implemented\n // the callback interface. If not, it throws an exception\n try {\n mCallback = (OnFriendSelectedListener) activity;\n } catch (ClassCastException e) {\n throw new ClassCastException(activity.toString()\n + \" must implement OnHeadlineSelectedListener\");\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n // mHost=(NetworkDialogListener)context;\n }",
"@Override\n public void onAttach(Activity activity) {\n super.onAttach(activity);\n if (activity instanceof LoadingListener) {\n loadingListener = (LoadingListener) activity;\n } else {\n throw new ClassCastException(activity.toString() + \" must implement LoadingListener\");\n }\n }",
"@Override\n public void onAttach(Context context){\n super.onAttach(context);\n if(context instanceof OnFragmentInteractionListener) {\n mListener = (OnFragmentInteractionListener) context;\n } else {\n throw new ClassCastException(context.toString()\n + getResources().getString(R.string.exception_message));\n }\n }",
"@Override\n public void onAttach(Context context) {\n super.onAttach(context);\n listener = (LoginFragment.LoginFragmentListener) context;\n }",
"@Override\n\tpublic void onAttach(Activity activity) {\n\t\tsuper.onAttach(activity);\n\t\tLog.d(\"Fragment02\",\"onAttach\");\n\t}",
"@Override\n public void onAttach(Activity activity) {\n //super.onAttach(context);\n\n super.onAttach(activity);\n try{\n EM = (EnviarMensaje) activity;\n } catch (ClassCastException e) {\n throw new ClassCastException(\"Necesitas implementar un mensaje\");\n }\n }",
"@Override\r\n\tpublic void onAttach(Activity activity) {\r\n\t\tLog.d(TAG, \"onAttach\");\r\n\t\tsuper.onAttach(activity);\r\n\t\tmActivity = activity;\r\n\t\ttry{\r\n\t\t\tCallBackLocalUserListFragmentListener listener = (CallBackLocalUserListFragmentListener)activity;\r\n\t\t\tlistener.getLocalUserListFragment(this);\r\n\t\t}catch (ClassCastException e) {\r\n\t\t\tLog.d(TAG, activity.toString() + \"must implement CallBackLocalUserListFragmentListener\");\r\n\t\t}\r\n\t}",
"private void init() {\n sensorEnabled = false;\n activityManager = (ActivityManager) context.getSystemService(Context.ACTIVITY_SERVICE);\n contextEventHistory = new ArrayList<ContextEvent>(CONTEXT_EVENT_HISTORY_SIZE);\n }",
"protected void onAttachToContext(Context context) {\n if (context instanceof OnItemSelectedListener) {\n listener = (OnItemSelectedListener) context;\n } else {\n throw new ClassCastException(context.toString()\n + \" must implement MyListFragment.OnItemSelectedListener\");\n }\n }",
"@Override\n public void onAttach(Activity context) {\n super.onAttach(context);\n if (!busIsRegistered) {\n BusService.getBus().register(this);\n busIsRegistered = true;\n }\n this.context = context;\n }",
"@Override\n public void onCreate(Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\n context=getContext();\n\n }"
] | [
"0.7052331",
"0.69153243",
"0.68751025",
"0.6829609",
"0.67725855",
"0.6705177",
"0.66541797",
"0.66300124",
"0.6535174",
"0.6534456",
"0.6500873",
"0.6487565",
"0.64752305",
"0.6464475",
"0.64550626",
"0.64462525",
"0.6417279",
"0.6412567",
"0.6367258",
"0.63641626",
"0.6359084",
"0.6342514",
"0.63154066",
"0.6314049",
"0.62975335",
"0.62953913",
"0.6284029",
"0.62644815",
"0.6263389",
"0.62612844",
"0.62535596",
"0.6241964",
"0.6235723",
"0.62263197",
"0.6225374",
"0.62210953",
"0.62207127",
"0.62207127",
"0.62207127",
"0.62002844",
"0.6199366",
"0.61853296",
"0.6176753",
"0.6176753",
"0.6173378",
"0.6171468",
"0.61321276",
"0.6122738",
"0.6112524",
"0.6108768",
"0.6108743",
"0.61043423",
"0.6100615",
"0.60975283",
"0.60732704",
"0.60711235",
"0.60664773",
"0.60453796",
"0.6030588",
"0.602459",
"0.6021967",
"0.59994256",
"0.59946597",
"0.59885436",
"0.5970703",
"0.5961565",
"0.595833",
"0.59566605",
"0.5952143",
"0.5949698",
"0.5946",
"0.5938631",
"0.59354526",
"0.5912053",
"0.5911904",
"0.59083796",
"0.58933604",
"0.58877784",
"0.5880529",
"0.5876453",
"0.5876453",
"0.58733475",
"0.58612126",
"0.58612126",
"0.5854276",
"0.5847665",
"0.58362085",
"0.5818628",
"0.5815909",
"0.5814459",
"0.5810093",
"0.5804814",
"0.57894564",
"0.5784937",
"0.5782846",
"0.5738363",
"0.5730239",
"0.57190114",
"0.5705909",
"0.56973135"
] | 0.64524394 | 15 |
creates the actual dialog the listener is called such that UnifedMain is notified that the user has tapped | public Dialog onCreateDialog(Bundle savedInstanceState){
AlertDialog.Builder sample_builder = new AlertDialog.Builder(getActivity());
sample_builder.setView("activity_main");
sample_builder.setMessage("This is a sample prompt. No new networks should be scanned while this prompt is up");
sample_builder.setCancelable(true);
sample_builder.setPositiveButton("Ok", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
listener.onDialogPositiveClick(StationFragment.this);
}
});
sample_builder.setNegativeButton("Cancel", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
listener.onDialogNegativeClick(StationFragment.this);
}
});
return sample_builder.create();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void initDialog() {\n }",
"@Override\n\tprotected void onCreate(Bundle arg0) {\n\t\tsuper.onCreate(arg0);\n\t\trequestWindowFeature(Window.FEATURE_NO_TITLE);\n\t\t\n\t\tIntent intent = getIntent();\n\t\tfinal DatabaseUtil mDatabaseUtil = new DatabaseUtil(this); \n\t\tfinal UiManager mUiManager = new UiManager(this);\n\t\t\n\t\tCustomDialog mCustomDialog = new CustomDialog(this);\n final CustomDialog customDialog = mCustomDialog;\n mCustomDialog = null;\n \n final ViewInfo viewInfo = new ViewInfo();\n\t\tviewInfo.panelNum = intent.getStringExtra(\"panelNum\");\n\t\tviewInfo.cellNum = intent.getStringExtra(\"cellNum\");\n\t\tviewInfo.viewId = \"shortcut\" + viewInfo.cellNum;\n\t\t\n customDialog.show();\n customDialog.setOnDismissListener(new OnDismissListener(){\n\n\t\t\tpublic void onDismiss(DialogInterface arg0) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\n\t\t\t\tTempActivity.this.finish();\n\t\t\t}\n });\n \n\t\tcustomDialog.setItemBackground(getResources().getDrawable(R.drawable.btn_default_normal_disable_focused));\n\t\t\n\t\tcustomDialog.loadingAllApp();\n\t\t\n\t\tcustomDialog.setOnSelectedItemsListener(new OnSelectedItemsListener(){\n\t\t\tpublic void onSelectedItems(Map<String,Integer> selectedMapPo) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\n\t\t\t}\n\t\t\tpublic void onSelectedItem(int position) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\n\t\t\t\tviewInfo.intentUri = customDialog.mAppList.get(position).intentUri;\n\t\t\t\t\n\t\t\t\tviewInfo.icon = customDialog.mAppList.get(position).icon;\n\t\t\t\tviewInfo.label = customDialog.mAppList.get(position).label;\n\t\t\t\t\n\t\t\t\tmUiManager.addItemToPanel(null\n\t\t\t\t,viewInfo\n\t\t\t\t,mDatabaseUtil);\n\t\t\t}\n\t\t});\n\t}",
"@Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\n LayoutInflater inflater = requireActivity().getLayoutInflater();\n final View view = inflater.inflate(R.layout.on_click_dialog, null);\n builder.setView(view);\n\n\n\n\n\n\n\n\n return builder.create();\n }",
"@Override\r\n\t\t\t\tpublic void onDialogMenuPressed() {\n\r\n\t\t\t\t}",
"private void startMealToDatabaseAlert() {\n AlertDialog.Builder dialogBuilder = new AlertDialog.Builder(this);\n TextView dialogTitle = new TextView(this);\n int blackValue = Color.parseColor(\"#000000\");\n dialogTitle.setText(R.string.title_dialog_meal);\n dialogTitle.setGravity(Gravity.CENTER_HORIZONTAL);\n dialogTitle.setPadding(0, 30, 0, 0);\n dialogTitle.setTextSize(25);\n dialogTitle.setTextColor(blackValue);\n dialogBuilder.setCustomTitle(dialogTitle);\n View dialogView = getLayoutInflater().inflate(R.layout.dialog_add_meal, null);\n\n this.startEditTexts(dialogView);\n this.startLocationSpinner(dialogView);\n this.startAddPhotoButton(dialogView);\n this.startMealDialogButtonListeners(dialogBuilder);\n\n dialogBuilder.setView(dialogView);\n AlertDialog permission_dialog = dialogBuilder.create();\n permission_dialog.show();\n }",
"void makeDialog()\n\t{\n\t\tfDialog = new ViewOptionsDialog(this.getTopLevelAncestor());\n\t}",
"@Override\n public void onClick(DialogInterface dialogInterface, int i) {\n\n mainActivity();\n }",
"public abstract void initDialog();",
"private void openCreateAccountDialog()\n {\n testDialog();\n\n }",
"public void setup() {\n self.getWindow().setBackgroundDrawable(new ColorDrawable(Color.TRANSPARENT));\n // make dialog background unselectable\n self.setCanceledOnTouchOutside(false);\n }",
"@Override\n public void onClick(View view) {\n DialogAddEvent();\n }",
"@Override\n\tprotected Dialog onCreateDialog(int id) {\n\t\treturn buildDialog(MainActivity.this);\n\t\t\n\t}",
"@SuppressWarnings(\"deprecation\")\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tAlertDialog alertDialog = new AlertDialog.Builder(GameInitializerActivity.this).create();\n\t\t\t\tLayoutInflater factory = LayoutInflater.from(GameInitializerActivity.this);\n\t\t\t\tfinal View view = factory.inflate(R.layout.activity_about_popupwindow, null);\n\t\t\t\talertDialog.setView(view);\n\t\t\t\talertDialog.setButton3(\"OK. I Got this !!\", dialogClickListener);\n\t\t\t\talertDialog.show();\t\t\t\t\n\t\t\t\t\n\t\t\t}",
"private void initDialog() {\n Window subWindow = new Window(\"Sub-window\");\n \n FormLayout nameLayout = new FormLayout();\n TextField code = new TextField(\"Code\");\n code.setPlaceholder(\"Code\");\n \n TextField description = new TextField(\"Description\");\n description.setPlaceholder(\"Description\");\n \n Button confirm = new Button(\"Save\");\n confirm.addClickListener(listener -> insertRole(code.getValue(), description.getValue()));\n\n nameLayout.addComponent(code);\n nameLayout.addComponent(description);\n nameLayout.addComponent(confirm);\n \n subWindow.setContent(nameLayout);\n \n // Center it in the browser window\n subWindow.center();\n\n // Open it in the UI\n UI.getCurrent().addWindow(subWindow);\n\t}",
"private void initDialog() {\n dialog = new Dialog(context);\n dialog.requestWindowFeature(Window.FEATURE_NO_TITLE);\n dialog.setContentView(R.layout.dialog_custom_ok);\n }",
"@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\tdialog();\n\t\t\t\t\t\n\t\t\t\t}",
"@NonNull\n @Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\n builder.setTitle(getArguments().getString(\"title\"))\n .setMessage(getArguments().getString(\"message\"))\n .setCancelable(false)\n .setPositiveButton(R.string.OK, new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n // FIRE ZE MISSILES!\n // call callback method\n // mListener.onInfoDialogOKClick(InfoDialog.this);\n }\n });\n // Create the AlertDialog object and return it\n return builder.create();\n }",
"@Override\n\t\t\tpublic void onClick(DialogInterface dialog, int which)\n\t\t\t{\n\t\t\t\tswitch(which)\n\t\t\t\t{\n\t\t\t\t\tcase 0:\n\t\t\t\t\t\tshowCreateDialog();\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 1:\n\n\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tshowVibrationDialog(which-2);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}",
"@Override\n public void onStart() {\n pDialog.show();\n }",
"@Override\n public void onClick(View view) {\n if (mAddDialog == null) {\n mAddDialog = new XPopup.Builder(MainActivity.this)\n .asInputConfirm(getString(R.string.add_random_title)\n , getString(R.string.add_random_content)\n , new OnInputConfirmListener() {\n @Override\n public void onConfirm(String text) {\n if (mAdapter != null) {\n mAdapter.addData(new BaseModel(text, 1));\n }\n }\n }).show();\n } else {\n mAddDialog.show();\n }\n }",
"private OnClickListener aboutApplication() {\n\t\tOnClickListener listener = new OnClickListener() {\n\t\t\t final DialogInterface.OnClickListener dialogClickListener = new DialogInterface.OnClickListener() {\n\t\t @Override\n\t\t public void onClick(DialogInterface dialog, int which) {\n\t\t switch (which){\n\t\t //Cancel the current popup dialog\n\t\t\t case DialogInterface.BUTTON_NEUTRAL:\n\t\t\t dialog.cancel();\n\t\t\t break;\n\t\t\t }\n\t\t }\n\t\t };\n\t\t\t@SuppressWarnings(\"deprecation\")\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t//Show details on a popup window\n\t\t\t\tAlertDialog alertDialog = new AlertDialog.Builder(GameInitializerActivity.this).create();\n\t\t\t\tLayoutInflater factory = LayoutInflater.from(GameInitializerActivity.this);\n\t\t\t\tfinal View view = factory.inflate(R.layout.activity_about_popupwindow, null);\n\t\t\t\talertDialog.setView(view);\n\t\t\t\talertDialog.setButton3(\"OK. I Got this !!\", dialogClickListener);\n\t\t\t\talertDialog.show();\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t};\n\t\treturn listener;\n\t}",
"@FXML\n public final void buttonListener() {\n final String str = GameContext.instance().toStringUniverse();\n Dialogs.create()\n .title(\"Planet list\")\n .message(str)\n .showInformation();\n }",
"@Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n\n View view = getActivity().getLayoutInflater().inflate(R.layout.rollback_detail_dialog, new LinearLayout(getActivity()), false);\n\n initUI(view);\n // clickEvents();\n\n /*\n assert getArguments() != null;\n voucherTypes = (ArrayList<VoucherType>) getArguments().getSerializable(\"warehouses\");\n voucherType=\"\";\n*/\n\n Dialog builder = new Dialog(getActivity());\n builder.requestWindowFeature(Window.FEATURE_NO_TITLE);\n builder.setContentView(view);\n return builder;\n\n\n }",
"@Override\n\tprotected Dialog onCreateDialog(int id)\n\t{\n\t\tif(id == DLG_ABOUT)\n\t\t{\n\t\tAlertDialog.Builder builder = new AlertDialog.Builder(this);\n\t\tbuilder.setMessage(R.string.app_about);\n\t\t\tbuilder.setPositiveButton(\"返回\", new DialogInterface.OnClickListener(){\n\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void onClick(DialogInterface p1, int p2)\n\t\t\t\t\t{\n\t\t\t\t\t\t// TODO: Implement this method\n\n\t\t\t\t\t}\n\n\n\t\t\t\t}\n\t\t\t);\n\t\treturn builder.create();\n\t\t}\n\t\t\n\t\tif(id == DLG_HELP)\n\t\t{\n\t\t\tAlertDialog.Builder builder = new AlertDialog.Builder(this);\n\t\t\tbuilder.setMessage(R.string.app_help);\n\t\t\tbuilder.setPositiveButton(\"返回\", new DialogInterface.OnClickListener(){\n\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void onClick(DialogInterface p1, int p2)\n\t\t\t\t\t{\n\t\t\t\t\t\t// TODO: Implement this method\n\n\t\t\t\t\t}\n\n\n\t\t\t\t}\n\t\t\t);\n\t\t\treturn builder.create();\n\t\t}\n\t\t\n\t\tif(id == DLG_UNPACKER)\n\t\t{\n\t\t\tView view = ViewTool.getView(this,R.layout.dlg_unpack);\n\t\t\tfinal EditText edit_png = (EditText) view.findViewById(R.id.edit_pngpath);\n\t\t\tfinal EditText edit_undir = (EditText) view.findViewById(R.id.edit_undir);\n\t\t\tAlertDialog.Builder builder = new AlertDialog.Builder(this);\n\t\t\t\n\t\t\tbuilder.setView(view);\n\t\t\tbuilder.setPositiveButton(\"确定\", new DialogInterface.OnClickListener(){\n\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void onClick(DialogInterface p1, int p2)\n\t\t\t\t\t{\n\t\t\t\t\t\t// TODO: Implement this method\n UnPacker unpacker = new UnPacker();\n\t\t String path_png = edit_png.getText().toString();\n\t\t String path_atlas = null;\n\t\t String path_output = edit_undir.getText().toString();\n\t\t int index = path_png.lastIndexOf('.');\n\t\t if(index>0){\n\t\t\t path_atlas = path_png.substring(0,index)+\".atlas\";\n\t\t }\n\t\t unpacker.unPNG( path_atlas,path_png, path_output);\n\t\t Toast.makeText(MainActivity.this,\"解包完成\",Toast.LENGTH_SHORT).show();\n\t\t\t\t\t}\n\n\n\t\t\t\t}\n\t\t\t);\n\t\t\tbuilder.setNegativeButton(\"返回\", new DialogInterface.OnClickListener(){\n\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void onClick(DialogInterface p1, int p2)\n\t\t\t\t\t{\n\t\t\t\t\t\t// TODO: Implement this method\n\n\t\t\t\t\t}\n\n\n\t\t\t\t}\n\t\t\t);\n\t\t\treturn builder.create();\n\t\t}\n\t\t\n\t\t\n\t\treturn super.onCreateDialog(id);\n\t}",
"@Override\r\n\t protected void onPrepareDialog(int id, Dialog dialog) {\n\t switch(id){\r\n\t case(ID_SCREENDIALOG):\r\n\t \tdialog.setTitle(\"Job Details\");\r\n\t \tButton myButton = new Button(this);\r\n\t \tmyButton.setText(\"Cancel\");\r\n\t \tmyButton.setBackgroundColor(Color.parseColor(\"#ff4c67\"));\r\n\t \tmyButton.setTextColor(Color.parseColor(\"#ffffff\"));\r\n\t \tRelativeLayout datlis = (RelativeLayout)screenDialog.findViewById(R.id.datalist01);\r\n\t \tLayoutParams lp = new LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.WRAP_CONTENT);\r\n\t \tlp.addRule(RelativeLayout.BELOW, list.getId());\r\n\t \tdatlis.addView(myButton, lp);\r\n\t \tmyButton.setOnClickListener(dismissscreen);\r\n\t \t\r\n\t break;\r\n\t }\r\n\t }",
"private void initializeUI() {\r\n this.parentFrame = game.getFrame();\r\n parentFrame.setEnabled(false); // Disable main game UI during the ending dialog.\r\n createResultPopup();\r\n }",
"public void createEvents(){\r\n\t\tbtnCurrent.addActionListener((ActionEvent e) -> JLabelDialog.run());\r\n\t}",
"private void InitUI() \n\t{\n\n\t\tRelativeLayout rel_abt = (RelativeLayout) rootView.findViewById(R.id.rel_abt);\n\t\tRelativeLayout rel_chgpass = (RelativeLayout) rootView.findViewById(R.id.rel_chgpass);\n\t\tRelativeLayout rel_tc = (RelativeLayout) rootView.findViewById(R.id.rel_tc);\n\t\tRelativeLayout rel_pp = (RelativeLayout) rootView.findViewById(R.id.rel_pp);\n\n\t\trel_abt.setOnClickListener(new OnClickListener() {\n\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\n\n\t\t\t}\n\t\t});\n\n\t\trel_chgpass.setOnClickListener(new OnClickListener() \n\t\t{\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\t\t\t\n\t\t\t\n\t\t\t\tshowdialog();\n\n\t\t\t}\n\t\t});\n\n\t\trel_tc.setOnClickListener(new OnClickListener() {\n\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\n\n\t\t\t}\n\t\t});\n\n\t\trel_pp.setOnClickListener(new OnClickListener() {\n\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t/*\n\t\t\t\tFragment fragment = new PrivacyPolicy();\n\t\t\t\tFragmentManager fmanager = getActivity().getSupportFragmentManager();\n\t\t\t\tFragmentTransaction ftans = fmanager.beginTransaction();\n\t\t\t\tftans.replace(R.id.frame_container, fragment);\n\t\t\t\tftans.commit();\n*/\n\t\t\t}\n\t\t});\n\n\t}",
"@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\n\t\t\t\tfinal Dialog dialog = new Dialog(MainActivity.this);\n\t\t\t\tdialog.setTitle(\"About this App\");\n\t\t\t\tdialog.setContentView(R.layout.custom_dialog);\n\t\t\t\tButton btnOkay = (Button)dialog.findViewById(R.id.btnOkay);\n\t\t\t\t\n\t\t\t\tdialog.show();\n\t\t\t\t\n\t\t\t\tbtnOkay.setOnClickListener(new OnClickListener() {\n\t\t\t\t\t\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\t\n\t\t\t\t\t\tdialog.dismiss();\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}",
"@Override\n public void onClick(View v) {\n new AlertDialog.Builder(MainActivity.this)\n .setIcon(android.R.drawable.ic_menu_gallery)\n .setTitle(\"Complete Boundary\")\n .setMessage(\"Are you sure you want to complete your croft boundary?\")\n .setPositiveButton(\"Yes\", new DialogInterface.OnClickListener()\n {\n\n @Override\n public void onClick(DialogInterface dialog, int which) {\n\n completePolygon();\n\n }\n\n })\n .setNegativeButton(\"No\", null)\n .show();\n\n }",
"@Override\n public void onDismiss(DialogInterface dialog) {\n setupUi();\n }",
"private void dialog() {\n\t\tGenericDialog gd = new GenericDialog(\"Bildart\");\n\t\t\n\t\tgd.addChoice(\"Bildtyp\", choices, choices[0]);\n\t\t\n\t\t\n\t\tgd.showDialog();\t// generiere Eingabefenster\n\t\t\n\t\tchoice = gd.getNextChoice(); // Auswahl uebernehmen\n\t\t\n\t\tif (gd.wasCanceled())\n\t\t\tSystem.exit(0);\n\t}",
"@Override\n public void onClick(View v) {\n CustomAddItemDialog customAddItemDialog = new CustomAddItemDialog(MainActivity.this);\n customAddItemDialog.show();\n }",
"ListenerForPopupToPayWithAmmoOrPUCArd(JDialog dialog, MainFrame mainFrame, ServerEvent event) {\n this.dialog = dialog;\n this.mainFrame = mainFrame;\n this.event = event;\n }",
"@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\n\t\t\t\t\tdialog.show();\n\t\t\t\t}",
"@Override\n public void onClick(View view) {\n final Dialog dialog = new Dialog(context);\n dialog.setTitle(\"FIRE ASSISTANCE\");\n dialog.setContentView(R.layout.zdialog_fire);\n\n WindowManager.LayoutParams lp1 = new WindowManager.LayoutParams();\n lp1.copyFrom(dialog.getWindow().getAttributes());\n lp1.width = WindowManager.LayoutParams.MATCH_PARENT;\n lp1.height = WindowManager.LayoutParams.WRAP_CONTENT;\n lp1.gravity = Gravity.CENTER;\n\n dialog.getWindow().setAttributes(lp1);\n\n fire1 = (LinearLayout) dialog.findViewById(R.id.fire1);\n fire2 = (LinearLayout) dialog.findViewById(R.id.fire2);\n fire3 = (LinearLayout) dialog.findViewById(R.id.fire3);\n fire4 = (LinearLayout) dialog.findViewById(R.id.fire4);\n fire5 = (LinearLayout) dialog.findViewById(R.id.fire5);\n fire6 = (LinearLayout) dialog.findViewById(R.id.fire6);\n\n fireRanked1 = (TextView) dialog.findViewById(R.id.fireRank1);\n fireRanked2 = (TextView) dialog.findViewById(R.id.fireRank2);\n fireRanked3 = (TextView) dialog.findViewById(R.id.fireRank3);\n fireRanked4 = (TextView) dialog.findViewById(R.id.fireRank4);\n fireRanked5 = (TextView) dialog.findViewById(R.id.fireRank5);\n fireRanked6 = (TextView) dialog.findViewById(R.id.fireA);\n\n fireRanked1.setText(agencyNameFire[0] + \"\" + statusFire[0]);\n fireRanked2.setText(agencyNameFire[1] + \"\" + statusFire[1]);\n fireRanked3.setText(agencyNameFire[2] + \"\" + statusFire[2]);\n fireRanked4.setText(agencyNameFire[3] + \"\" + statusFire[3]);\n fireRanked5.setText(agencyNameFire[4] + \"\" + statusFire[4]);\n fireRanked6.setText(agencyNameFire[5]);\n\n fire1.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n callDialog(contLandlineFire[0].toString(), contCpFire[0].toString(), regFire[0], \"Fire\");\n\n }\n });\n\n fire2.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n callDialog(contLandlineFire[1].toString(), contCpFire[1].toString(), regFire[1], \"Fire\");\n\n }\n });\n\n fire3.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n callDialog(contLandlineFire[2].toString(), contCpFire[2].toString(), regFire[2], \"Fire\");\n\n }\n });\n\n fire4.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n callDialog(contLandlineFire[3].toString(), contCpFire[3].toString(), regFire[3], \"Fire\");\n\n }\n });\n\n fire5.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n callDialog(contLandlineFire[4].toString(), contCpFire[4].toString(), regFire[4], \"Fire\");\n\n }\n });\n fire6.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n callDialog(contLandlineCrime[5].toString(), contCpCrime[5].toString(), \"L0LucU9RMgOtV1MwVCGUR6oyhy62\", \"Fire\");\n\n }\n });\n\n // set the custom dialog components - text, image and button\n\n dialog.show();\n\n }",
"@Override\r\n\t protected Dialog onCreateDialog(int id) {\n\t \r\n\t screenDialog = null;\r\n\t switch(id){\r\n\t case(ID_SCREENDIALOG):\r\n\t screenDialog = new Dialog(this);\r\n\t screenDialog.setContentView(R.layout.message);\r\n\t messageText=(EditText)screenDialog.findViewById(R.id.messagetext1);\r\n\t send=(Button)screenDialog.findViewById(R.id.button1);\r\n\t send.setOnClickListener(sendmessage);\r\n\t cancel=(Button)screenDialog.findViewById(R.id.button2);\r\n\t cancel.setOnClickListener(cancelmessage);\r\n\t }\r\n\t return screenDialog;\r\n\t }",
"@Override\n\t\t\tpublic void onClick(View arg0) {\n\t\t\t\t\n\t\t\t\tdialog.show();\n\t\t\t\t//alert.show();\n\t\t\t\t\n\t\t\t}",
"@Override\n\tpublic void setListener() {\n\t\t\n\t\tsetFingerButton.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\ttextViewName2.setText(\"添加普通指纹用户\");\n\t\t\t\t//textViewName3.setText(\" ID : \");\n\t\t\t\t//editTextName1.setText(\"\");\n\t\t\t\teditTextName.setText(\"\");\n\t\t\t\tWindow w=menuDialogName.getWindow();\n\t\t\t\tWindowManager.LayoutParams lp =w.getAttributes();\n\t\t\t\tlp.x=0;\n\t\t\t\tlp.y=-200;\n\t\t\t\tw.setAttributes(lp); \n\t\t\t\t\n\t\t\t\tbuttonState = 1;\n\t\t\t\tmenuDialogName.show();\n\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_INPUT_NAME);\n\t\t\t\tResetChangeTime();\n\t\t} \n });\n\t\t\n\t\taddAdminUser.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tResetChangeTime();\n\t\t\t\ttextViewName2.setText(\"添加管理员指纹用户\");\n\t\t\t\t//textViewName3.setText(\" ID : \");\n\t\t\t\t//editTextName1.setText(\"\");\n\t\t\t\teditTextName.setText(\"\");\n\t\t\t\tWindow w=menuDialogName.getWindow();\n\t\t\t\tWindowManager.LayoutParams lp =w.getAttributes();\n\t\t\t\tlp.x=0;\n\t\t\t\tlp.y=-100;\n\t\t\t\tw.setAttributes(lp); \n\t\t\t\tbuttonState = 2;\n\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_INPUT_NAME);\n\t\t\t\tmenuDialogName.show();\n\t\t\t\tResetChangeTime();\n\t\t} \n }); \n \n\t\n\n\t\taddNormalCurButton1.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif(buttonState == 3)\n\t\t\t\t{\n\t\t\t\t\tResetChangeTime();\n\t\t\t\t\tIntent intent = new Intent();\n\t\t\t\t\tintent.setAction(MessageAction.MESSAGE_DELETE_FINGER);\n\t\t\t\t\t\n\t\t\t\t\tif(\"\".equals(editText1.getText().toString().trim()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"ID号不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\tint id= Integer.parseInt(editText1.getText().toString());\n\t\t\t\t\t\tif(id >= 4 && id<=499)\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\tintent.putExtra(\"id\", id);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tmenuDialog.dismiss();\n\t\t\t\t\t\t\tsendBroadcast(intent);\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_DELLIMIT_SOUND);\n\t\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"普通用户有效ID号范围为4-499,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if(buttonState == 4)\n\t\t\t\t{\n\t\t\t\t\tResetChangeTime();\n\t\t\t\t\tIntent intent = new Intent();\n\t\t\t\t\tintent.setAction(MessageAction.MESSAGE_DELETE_FINGER);\n\t\t\t\t\t\n\t\t\t\t\tif(\"\".equals(editText1.getText().toString().trim()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"ID号不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tint id= Integer.parseInt(editText1.getText().toString());\n\t\t\t\t\t\tif(id >= 1 && id<=3)\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\tintent.putExtra(\"id\", id);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tmenuDialog.dismiss();\n\t\t\t\t\t\t\tsendBroadcast(intent);\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_DELLIMIT_SOUND);\n\t\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"管理员有效ID号范围为1-3,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t} \n }); \n\t\t\n\t\taddNormalCurButton2.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tResetChangeTime();\n\t\t\t\tmenuDialog.dismiss();\n\t\t\t} \n }); \n\t\t\n\t\taddNormalNameCurButton1.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif(buttonState == 1)\n\t\t\t\t{\n\t\t\t\t\tResetChangeTime();\n\t\t\t\t\tIntent intent = new Intent();\n\t\t\t\t\tintent.setAction(MessageAction.MESSAGE_SET_FINGER);\n\t\t\t\t\tm_admin = 1;\n\t\t\t\t\tintent.putExtra(\"msg\", m_admin);\n\t\t\t\t\t//id \n\t\t\t\t\t/*\n\t\t\t\t\tif(\"\".equals(editTextName1.getText().toString().trim()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"ID号不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tint id= Integer.parseInt(editTextName1.getText().toString());\t\t\t\t\t\n\t\t\t\t\t\tif(id <= 3 || id>999)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"普通用户有效ID号范围为4-999,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tintent.putExtra(\"fingerID\", id);\n\t\t\t\t\t}\n\t\t\t\t\t*/\n\t\t\t\t\t//姓名\n\t\t\t\t\tif(\"\".equals(editTextName.getText().toString()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"姓名不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{//System.out.println(editTextName.getText().toString());\n\t\t\t\t\t\tintent.putExtra(\"fingerID\", -1);\n\t\t\t\t\t\tintent.putExtra(\"Name\", editTextName.getText().toString());\n\t\t\t\t\t\t/*\n\t\t\t\t\t\t //反射\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tField field = menuDialogName.getClass().getSuperclass().getDeclaredField(\"mShowing\");\n\t\t\t\t\t\t\tfield.setAccessible(true);\n\t\t\t\t\t\t\tfield.set(menuDialogName, false);\n\t\t\t\t\t\t} catch (NoSuchFieldException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t} catch (IllegalArgumentException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t} catch (IllegalAccessException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t*/\n\t\t\t\t\t\tmenuDialogName.dismiss();\n\t\t\t\t\t\tsendBroadcast(intent);\t\n\t\t\t\t\t}\t\t\n\t\t\t\t}\n\t\t\t\telse if(buttonState == 2)\n\t\t\t\t{\n\t\t\t\t\tResetChangeTime();\n\t\t\t\t\tm_admin = 0;\n\t\t\t\t\tIntent intent = new Intent();\n\t\t\t\t\tintent.setAction(MessageAction.MESSAGE_SET_FINGER);\n\t\t\t\t\tintent.putExtra(\"msg\", m_admin);\n\t\t\t\t\t//id \n\t\t\t\t\t/*\n\t\t\t\t\tif(\"\".equals(editTextName1.getText().toString().trim()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"ID号不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tint id= Integer.parseInt(editTextName1.getText().toString());\n\t\t\t\t\t\tif(id >= 1 && id<=3)\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\tintent.putExtra(\"fingerID\", id);\n\t\t\t\t\t\t\t\n\t\t\t\t\t//\t\tmenuDialog.dismiss();\n\t\t\t\t\t//\t\tsendBroadcast(intent);\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"管理员有效ID号范围为1-3,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t*/\n\t\t\t\t\tintent.putExtra(\"fingerID\", -2);\n\t\t\t\t\t//姓名\n\t\t\t\t\tif(\"\".equals(editTextName.getText().toString()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"姓名不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tintent.putExtra(\"Name\", editTextName.getText().toString());\n\t\t\t\t\t\t\n\t\t\t\t\t\tmenuDialogName.dismiss();\n\t\t\t\t\t\tsendBroadcast(intent);\t\n\t\t\t\t\t}\t\n\t\t\t\t}\n\t\t\t\telse if(buttonState == 3)\n\t\t\t\t{\n\t\t\t\t\tResetChangeTime();\n\t\t\t\t\tIntent intent = new Intent();\n\t\t\t\t\tintent.setAction(MessageAction.MESSAGE_DELETE_FINGER);\n\t\t\t\t\t\n\t\t\t\t\tif(\"\".equals(editText1.getText().toString().trim()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"ID号不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tint id= Integer.parseInt(editText1.getText().toString());\n\t\t\t\t\t\tif(id >= 4 && id<=499)\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\tintent.putExtra(\"id\", id);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tmenuDialogName.dismiss();\n\t\t\t\t\t\t\tsendBroadcast(intent);\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_DELLIMIT_SOUND);\n\t\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"普通用户有效ID号范围为4-499,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if(buttonState == 4)\n\t\t\t\t{\n\t\t\t\t\tResetChangeTime();\n\t\t\t\t\tIntent intent = new Intent();\n\t\t\t\t\tintent.setAction(MessageAction.MESSAGE_DELETE_FINGER);\n\t\t\t\t\t\n\t\t\t\t\tif(\"\".equals(editText1.getText().toString().trim()))\n\t\t\t\t\t{\n\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"ID号不能为空,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tint id= Integer.parseInt(editText1.getText().toString());\n\t\t\t\t\t\tif(id >= 1 && id<=3)\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\tintent.putExtra(\"id\", id);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tmenuDialogName.dismiss();\n\t\t\t\t\t\t\tsendBroadcast(intent);\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_DELLIMIT_SOUND);\n\t\t\t\t\t\t\tToastUtil.showToast(getApplicationContext(), \"管理员有效ID号范围为1-3,请重新输入!\", Toast.LENGTH_SHORT);\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t} \n }); \n\t\taddNormalNameCurButton2.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tResetChangeTime();\n\t\t\t\tmenuDialogName.dismiss();\n\t\t\t} \n }); \n\t\t\n\t\t\n\t\t\t\n\t\tclearNormalUserButton.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tResetChangeTime();\n\t\t\t\ttextView2.setText(\"删除普通指纹用户\");\n\t\t\t\ttextView3.setText(\"普通用户 ID : \");\n\t\t\t\teditText1.setText(\"\");\n\t\t\t\tWindow w=menuDialog.getWindow();\n\t\t\t\tWindowManager.LayoutParams lp =w.getAttributes();\n\t\t\t\tlp.x=0;\n\t\t\t\tlp.y=-100;\n\t\t\t\tw.setAttributes(lp); \n\t\t\t\tbuttonState = 3;\n\t\t\t\tmenuDialog.show();\n\t\t\t\t\n\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_INPUTID_SOUND);\n\t\t} \n }); \n\t\t\n\t\tclearAdminUserButton.setOnClickListener(new OnClickListener(){ \n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tResetChangeTime();\n\t\t\t\ttextView2.setText(\"删除管理员指纹用户\");\n\t\t\t\ttextView3.setText(\"管理员 ID : \");\n\t\t\t\teditText1.setText(\"\");\n\t\t\t\tWindow w=menuDialog.getWindow();\n\t\t\t\tWindowManager.LayoutParams lp =w.getAttributes();\n\t\t\t\tlp.x=0;\n\t\t\t\tlp.y=-100;\n\t\t\t\tw.setAttributes(lp); \n\t\t\t\tbuttonState = 4;\n\t\t\t\tmenuDialog.show();\n\t\t\t\tSendSoundMsg(MessageAction.MESSAGE_PLAY_INPUTID_SOUND);\n\t\t} \n }); \n\t\t\t\t\t\t\n\t\tm_btnCancel.setOnClickListener(new OnClickListener(){\n\t\t\tpublic void onClick(View v){\n\t\t\t\tResetChangeTime();\n\t\t\t\tfinish();\n\t\t\t}\n\t\t});\n\t\t\n\t}",
"@Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\n\n builder.setMessage(R.string.dialog_internet_eng_text).setPositiveButton\n (R.string.ok, new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n System.exit(1);\n /*\n Intent homeIntent= new Intent(getContext(), MainCardActivity.class);\n homeIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n startActivity(homeIntent);\n */\n }\n });\n return builder.create();\n }",
"private void showCustomDialog() {\n final Dialog dialog = new Dialog(getContext());\n dialog.requestWindowFeature(Window.FEATURE_NO_TITLE); //before\n // Include dialog.xml file\n dialog.setContentView(R.layout.success_dialog);\n TextView btn_home = dialog.findViewById(R.id.btn_home);\n dialog.setCanceledOnTouchOutside(false);\n dialog.setOnCancelListener(new DialogInterface.OnCancelListener() {\n @Override\n public void onCancel(DialogInterface dialog) {\n startActivity(new Intent(getContext(), MainActivity.class));\n getActivity().finish();\n }\n });\n btn_home.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n startActivity(new Intent(getContext(), MainActivity.class));\n getActivity().finish();\n }\n });\n // Set dialog title\n\n dialog.show();\n }",
"@Override\n protected void onPrepareDialog(int id, Dialog dialog) {\n \tToast.makeText(this, dialog.toString(), Toast.LENGTH_SHORT).show();\n }",
"@Override\n\tpublic OnClickListener setPositiveClickListener(final AlertDialog dialog,\n\t\t\tint layoutId, String id) {\n\t\tif (id.equals(\"menu\")) {\n\t\t\tdialog.findViewById(R.id.parent).setOnClickListener(\n\t\t\t\t\tnew OnClickListener() {\n\n\t\t\t\t\t\t@Override\n\t\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\t\tdialog.dismiss();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\tif (collect.getMtype() != null\n\t\t\t\t\t&& collect.getMtype().equals(\"1\")) {\n\t\t\t\tdialog.findViewById(R.id.dialog_transmit).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider2).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_colllect).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider3).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t} else if (collect.getMtype() != null\n\t\t\t\t\t&& collect.getMtype().equals(\"2\")) {\n\t\t\t\tdialog.findViewById(R.id.dialog_copy).setVisibility(View.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_transmit).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider2).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_colllect).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider3).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t} else if (collect.getMtype() != null\n\t\t\t\t\t&& collect.getMtype().equals(\"3\")) {\n\t\t\t\tdialog.findViewById(R.id.dialog_copy).setVisibility(View.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_transmit).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider2).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_colllect).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t\tdialog.findViewById(R.id.dialog_divider3).setVisibility(\n\t\t\t\t\t\tView.GONE);\n\t\t\t}\n\t\t\tdialog.findViewById(R.id.dialog_copy).setOnClickListener(\n\t\t\t\t\tnew OnClickListener() {\n\n\t\t\t\t\t\t@Override\n\t\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\t\tif (collect == null)\n\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\tTools.copy(collect.getContent(), getContext());\n\t\t\t\t\t\t\tMyToast.getToast().showToast(getContext(),\n\t\t\t\t\t\t\t\t\tR.string.copyed);\n\t\t\t\t\t\t\tdialog.dismiss();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\tdialog.findViewById(R.id.dialog_delete).setOnClickListener(\n\t\t\t\t\tnew OnClickListener() {\n\n\t\t\t\t\t\t@Override\n\t\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\t\tIntent intent = getIntent();\n\t\t\t\t\t\t\tBundle b = new Bundle();\n\t\t\t\t\t\t\tb.putSerializable(\"collect\", collect);\n\t\t\t\t\t\t\tintent.putExtras(b);\n\t\t\t\t\t\t\tgetContext().setResult(RESULT_OK, intent);\n\t\t\t\t\t\t\tcloseOneAct(TAG);\n\t\t\t\t\t\t\tcollect = null;\n\t\t\t\t\t\t\tMyToast.getToast().showToast(getContext(), \"删除成功\");\n\t\t\t\t\t\t\tdialog.dismiss();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\n\t\t}\n\t\treturn null;\n\t}",
"@Override\n\tpublic void init() {\n//\t\tSystem.out.println(\"init UIAgent\");\n\n//\t\tSystem.out.println(\"closing old dialog of \");\n\t\tif (ui != null) {\n\t\t\tui.dispose();\n\t\t\tui = null;\n\t\t}\n//\t\tSystem.out.println(\"old dialog closed. Trying to open new dialog. \");\n\t\ttry {\n\t\t\tui = new EnterBidDialog(this, null, true,\n\t\t\t\t\t(AdditiveUtilitySpace) utilitySpace, null);\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"Problem in UIAgent2.init:\" + e.getMessage());\n\t\t\te.printStackTrace();\n\t\t}\n//\t\tSystem.out.println(\"finished init of UIAgent2\");\n\t}",
"@Override\n public void onClick(\n DialogInterface dialog,\n int which) {\n }",
"private void showDialog() {\n AlertDialog.Builder builder = new AlertDialog.Builder(this);\n builder.setTitle(\"User created successfully\");\n builder.setIcon(R.drawable.ic_shield);\n builder.setCancelable(true);\n builder.setPositiveButton(\n \"Continue\",\n new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n finish();\n }\n });\n AlertDialog alert11 = builder.create();\n alert11.show();\n Window window = alert11.getWindow();\n assert window != null;\n WindowManager.LayoutParams wlp = window.getAttributes();\n wlp.gravity = Gravity.CENTER;\n wlp.y = 270;\n wlp.flags &= ~WindowManager.LayoutParams.FLAG_DIM_BEHIND;\n window.setAttributes(wlp);\n }",
"@Override\n public void onClick(View v) {\n dialog_action();\n }",
"private void createForumDialog() {\n AlertDialog.Builder dialog = new AlertDialog.Builder(Objects.requireNonNull(this),\n R.style.AlertDialogTheme);\n dialog.setTitle(R.string.add_new_forum_title);\n dialog.setMessage(R.string.add_new_forum_description);\n\n View newForumDialog = getLayoutInflater().inflate(R.layout.new_forum_dialog, null);\n dialog.setView(newForumDialog);\n\n AlertDialog alertDialog = dialog.create();\n setAddForumButtonListener(alertDialog, newForumDialog);\n\n alertDialog.show();\n }",
"@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\n\t\t\t\tshowdialog();\n\n\t\t\t}",
"@Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\n\n builder.setItems(items, new DialogInterface.OnClickListener(){\n @Override\n public void onClick(DialogInterface dialog, int which) {\n mListener.onPinOptionsItemSelected(PinOptionsDialogFragment.this, items[which].toString());\n }\n });\n return builder.create();\n }",
"@Override\n public void run() {\n showDialog(ZDisMainActivity.this,\"dialog\");\n }",
"public abstract Dialog createDialog(DialogDescriptor descriptor);",
"@Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\n filename = getArguments().getString(\"filename\");\n username = getArguments().getString(\"username\");\n workingDIR = getArguments().getString(\"workingDIR\");\n builder.setTitle(R.string.copy_move_file_select_options_title)\n .setItems(R.array.file__move_copy_dialog_options, new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int which) {\n onSelect(which);\n }\n });\n return builder.create();\n }",
"@Override\n\t\t\tpublic void handleEvent(Event event) {\n\t\t\t\tAddNotificationWizard wizard = new AddNotificationWizard(humanInteractions,notificationPage,domain,notficationViewer);\n\t\t\t\tWizardDialog wizardDialog = new WizardDialog(Display .getCurrent().getActiveShell(),wizard);\n\t\t\t\twizardDialog.create(); \n\t\t\t\twizardDialog.open();\n\t\t\t}",
"public void onClick(DialogInterface dialog, int id) {\n Log.d(\"Message\", userInput.getText().toString());\n r.stop();\n goToHomeActivity();\n }",
"private void createDialog() {\r\n final AlertDialog dialog = new AlertDialog.Builder(getActivity()).setView(R.layout.dialog_recorder_details)\r\n .setTitle(\"Recorder Info\").setPositiveButton(\"Start\", (dialog1, which) -> {\r\n EditText width = (EditText) ((AlertDialog) dialog1).findViewById(R.id.dialog_recorder_resolution_width);\r\n EditText height = (EditText) ((AlertDialog) dialog1).findViewById(R.id.dialog_recorder_resolution_height);\r\n CheckBox audio = (CheckBox) ((AlertDialog) dialog1).findViewById(R.id.dialog_recorder_audio_checkbox);\r\n EditText fileName = (EditText) ((AlertDialog) dialog1).findViewById(R.id.dialog_recorder_filename_name);\r\n mServiceHandle.start(new RecordingInfo(Integer.parseInt(width.getText().toString()), Integer.parseInt(height.getText().toString()),\r\n audio.isChecked(), fileName.getText().toString()));\r\n dialog1.dismiss();\r\n }).setNegativeButton(\"Cancel\", (dialog1, which) -> {\r\n dialog1.dismiss();\r\n }).show();\r\n Point size = new Point();\r\n getActivity().getWindowManager().getDefaultDisplay().getRealSize(size);\r\n ((EditText) dialog.findViewById(R.id.dialog_recorder_resolution_width)).setText(Integer.toString(size.x));\r\n ((EditText) dialog.findViewById(R.id.dialog_recorder_resolution_height)).setText(Integer.toString(size.y));\r\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n \n }",
"private void onConfirmButtonPressed() {\r\n disposeDialogAndCreateNewGame();\r\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n }",
"@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif (isSelfCreate)\r\n\t\t\t\t{\r\n\t\t\t\t\tshowDialog(DIALOG_SELF);\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tshowDialog(DIALOG_OTHER);\r\n\t\t\t\t}\r\n\t\t\t}",
"protected void dialog() {\n TextInputDialog textInput = new TextInputDialog(\"\");\n textInput.setTitle(\"Text Input Dialog\");\n textInput.getDialogPane().setContentText(\"Nyt bord nr: \");\n textInput.showAndWait()\n .ifPresent(response -> {\n if (!response.isEmpty()) {\n newOrderbutton(response.toUpperCase());\n }\n });\n }",
"@Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\n builder.setMessage(R.string.dialog_leave_channel)\n .setPositiveButton(R.string.button_yes, new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n Log.v(LOGTAG, \"YES clicked\");\n getGTracker().send(MapBuilder\n .createEvent(\"ui_action\", \"channel_dialog\", \"leave_yes\", null)\n .build()\n );\n mListener.onDialogLeaveChannelConfirm(LeaveChanDialog.this);\n }\n })\n .setNegativeButton(R.string.button_no, new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n Log.v(LOGTAG, \"NO clicked\");\n getGTracker().send(MapBuilder\n .createEvent(\"ui_action\", \"channel_dialog\", \"leave_no\", null)\n .build()\n );\n }\n })\n .setTitle(R.string.dialog_signup_title);\n // Create the AlertDialog object and return it\n return builder.create();\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n BootstrapEditText et = (BootstrapEditText)v.findViewById(R.id.areaTitle);\n\n mListener.onAreaDialogPositiveClick(AreaDialogFragment.this, et.getEditableText().toString());\n\n }",
"@Override\n\t\t\t\tpublic void onClick(View arg0) {\n\t\t\t\t\tdrawView.startNew();\n\t\t\t\t\tdialog.dismiss();\n\t\t\t\t}",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n\n }",
"public void createPopupWindow() {\r\n \t//\r\n }",
"public void onClick(DialogInterface dialog, int which) {\n\n templates_addnew.this.finish();\n\n }",
"@Override\n public void onClick(View v) {\n showDialog();\n }",
"@Override\n public void onBtnClick() {\n if(testDialog!=null){\n testDialog.dismiss();\n }\n handler.sendEmptyMessage(222);\n\n }",
"private void setUpButton() {\n // Find view\n Button button = (Button) findViewById(R.id.this_weekend_dialog_match_button);\n // Set click mListener\n button.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n mListener.onMatchMadeDialogSeen();\n dismiss();\n }\n });\n }",
"private void newDialog() {\n\t\tAlertDialog.Builder builder = new AlertDialog.Builder(this);\n\t\tbuilder.setTitle(getString(R.string.addmark));\n\t\tfinal EditText input = new EditText(this);\n\t\tinput.setHint(getString(R.string.pleasemark));\n\t\tbuilder.setView(input);\n\t\tbuilder.setPositiveButton(getString(R.string.yes),\n\t\t\t\tnew OnClickListener() {\n\t\t\t\t\tpublic void onClick(DialogInterface dialog, int which) {\n\t\t\t\t\t\tif (input.getText().toString().trim().length() > 0) {\n\t\t\t\t\t\t\taddTag(input.getText().toString());\n\t\t\t\t\t\t\tdialog.dismiss();\n\t\t\t\t\t\t\tToast.makeText(ArchermindReaderActivity.this,\n\t\t\t\t\t\t\t\t\tgetString(R.string.successaddmark),\n\t\t\t\t\t\t\t\t\tToast.LENGTH_SHORT).show();\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tToast.makeText(ArchermindReaderActivity.this,\n\t\t\t\t\t\t\t\t\tgetString(R.string.pleasemark),\n\t\t\t\t\t\t\t\t\tToast.LENGTH_SHORT).show();\n\t\t\t\t\t\t\tnewDialog();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\tbuilder.setNegativeButton(getString(R.string.no),\n\t\t\t\tnew OnClickListener() {\n\t\t\t\t\tpublic void onClick(DialogInterface dialog, int which) {\n\t\t\t\t\t\tdialog.dismiss();\n\t\t\t\t\t}\n\t\t\t\t});\n\t\tbuilder.show();\n\t}",
"private void popupCalibratingDialog() {\n AlertDialog.Builder builder = new AlertDialog.Builder(this);\n builder.setTitle(R.string.motion_calibrating);\n builder.setCancelable(false);\n builder.setMessage(R.string.motion_calibrating_message);\n\n calibratingDialog = builder.create();\n calibratingDialog.show();\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n }",
"private void showDialogPolygon1() {\n LayoutInflater inflater = getLayoutInflater();\n CardView cardView = (CardView) getLayoutInflater().inflate(R.layout.dialog_root,null);\n LinearLayout root = (LinearLayout) cardView.findViewById(R.id.linearLayout_root);\n //inflate each row that should be contained in the dialog box\n View rowAmount = inflater.inflate(R.layout.row_amount,null);\n View rowTelephone = inflater.inflate(R.layout.row_telephone,null);\n View rowText = inflater.inflate(R.layout.row_text,null);\n View rowButtons = inflater.inflate(R.layout.row_buttons,null);\n //add each row to the root\n root.addView(rowAmount);\n root.addView(rowTelephone);\n root.addView(rowText);\n root.addView(rowButtons);\n\n customDialog = new Dialog(getActivity());\n customDialog.requestWindowFeature(Window.FEATURE_NO_TITLE); // before\n customDialog.setContentView(cardView);\n customDialog.getWindow().setBackgroundDrawable(new ColorDrawable(android.graphics.Color.TRANSPARENT));\n customDialog.setCancelable(true);\n\n\n final EditText editTextAmount = customDialog.findViewById(R.id.edit_text_amount);\n final EditText editTextNumber = customDialog.findViewById(R.id.edit_text_mobileNumber);\n ImageButton imageButton = customDialog.findViewById(R.id.selec_contact_ImageBtn);\n imageButton.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n contactPicker();\n }\n });\n\n\n ((Button) customDialog.findViewById(R.id.bt_okay)).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n Intent hoverIntent = new HoverParameters.Builder(getActivity())\n .request(\"e0d94aec\")\n .style(R.style.BaseTheme)\n .extra(\"MobileNumber\", editTextNumber.getText().toString())\n .extra(\"Amount\", editTextAmount.getText().toString())\n .buildIntent();\n startActivityForResult(hoverIntent, 0);\n }\n\n });\n\n ((Button) customDialog.findViewById(R.id.bt_cancel)).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n customDialog.dismiss();\n }\n });\n\n\n customDialog.show();\n }",
"@NonNull\n @Override\n public Dialog onCreateDialog(Bundle savedInstanceState) {\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\n LayoutInflater inflater = getActivity().getLayoutInflater();\n View rootView = inflater.inflate(R.layout.fragment_message_dialog, null);\n msg = rootView.findViewById(R.id.msg);\n submit = rootView.findViewById(R.id.msg_submit);\n final int code = getTargetRequestCode();\n builder.setView(rootView);\n builder.setTitle(\"Enter a message:\");\n\n submit.setOnClickListener(new View.OnClickListener(){\n @Override\n public void onClick(View view) {\n\n sendResult(code);\n dismiss();\n\n\n }\n\n });\n\n return builder.create();\n }",
"@Override\n public void run() {\n showDialog(ZDisMainActivity.this,\"dialog\");\n }",
"public void onClick(DialogInterface dialog, int id) {\n promptName = (userInput.getText()).toString();\n if(promptName==null || promptName.equals(\"\"))\n {\n starterPrompt();\n }\n }",
"@Override\n public void onItemClick(View view, Medal obj, int position) {\n TextView txt;\n final Dialog dialog = new Dialog(getContext());\n dialog.requestWindowFeature(Window.FEATURE_NO_TITLE); // before\n dialog.setContentView(R.layout.popup_medals);\n txt = dialog.findViewById(R.id.titlePop);\n txt.setText(obj.title);\n dialog.getWindow().setBackgroundDrawable(new ColorDrawable(android.graphics.Color.TRANSPARENT));\n dialog.setCancelable(true);\n dialog.show();\n }",
"public void showOptions() {\n this.popupWindow.showAtLocation(this.layout, 17, 0, 0);\n this.customview.findViewById(R.id.dialog).setOnClickListener(new View.OnClickListener() {\n public void onClick(View view) {\n DiscussionActivity.this.popupWindow.dismiss();\n }\n });\n this.pdf.setOnClickListener(new View.OnClickListener() {\n public void onClick(View view) {\n DiscussionActivity discussionActivity = DiscussionActivity.this;\n discussionActivity.type = \"pdf\";\n discussionActivity.showPdfChooser();\n DiscussionActivity.this.popupWindow.dismiss();\n }\n });\n this.img.setOnClickListener(new View.OnClickListener() {\n public void onClick(View view) {\n DiscussionActivity discussionActivity = DiscussionActivity.this;\n discussionActivity.type = ContentTypes.EXTENSION_JPG_1;\n discussionActivity.showImageChooser();\n DiscussionActivity.this.popupWindow.dismiss();\n }\n });\n this.cancel.setOnClickListener(new View.OnClickListener() {\n public void onClick(View view) {\n DiscussionActivity.this.popupWindow.dismiss();\n }\n });\n }",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n }",
"public void popUpDialogBox(View passedView, int code) {\n mBuilder = new AlertDialog.Builder(TrailActivity.this);\n if(code == 0) {\n Date editedTrailDt = null;\n editedView = passedView;\n editedTrailName = (EditText) editedView.findViewById(R.id.TrailNametxt);\n editedTrailModule = (EditText) editedView.findViewById(R.id.Moduletxt);\n editedTrailCode = (EditText) editedView.findViewById(R.id.TrailCodetxt);\n editedTrailDate = (EditText) editedView.findViewById(R.id.datetxt);\n try { editedTrailDt = new SimpleDateFormat(\"dd-MM-yyyy\", Locale.ENGLISH).parse(editedTrailDate.getText().toString().trim()); }\n catch (ParseException e) { e.printStackTrace(); }\n editedTrailId = geTrailId(editedTrailCode.getText().toString(), editedTrailDt);\n }\n else editedView = null;\n initDialogBoxViews(passedView);\n setDateClickListener();\n setTrailDateClickListener();\n setAddtrailBtnClickListener();\n mBuilder.setView(passedView);\n dialog = mBuilder.create();\n dialog.show();\n }",
"@Override\n\tpublic Dialog onCreateDialog(Bundle savedInstanceState) {\n\t\t\n\t\t// get data from arguments\n\t\tBundle bundle = getArguments();\n\t\tString[] ids = bundle.getStringArray(\"ids\");\n\t\tString[] names = bundle.getStringArray(\"names\");\n\t\tboolean dismiss = bundle.getBoolean(\"dismiss\");\n\t\t\n\t\tif(ids.length!=names.length) return null;\n\t\t\n\t\tPopUpRow[] rows = new PopUpRow[ids.length];\n\t\tfor(int i=0; i<ids.length; i++) {\n\t\t\trows[i] = new PopUpRow(ids[i], names[i]);\n\t\t}\n\t\t\n\t\tPopUpAdapter adapter = new PopUpAdapter(this.getActivity(), R.layout.fragment_dialog, rows);\n\t\t\n\t\t// format and build and return the dialog\n\t\tAlertDialog.Builder builder = new AlertDialog.Builder( getActivity(), AlertDialog.THEME_DEVICE_DEFAULT_DARK);\n\t\tbuilder.setTitle(\"PROXIMITY UPDATE\");\n\t\tbuilder.setNeutralButton(\"DISMISS\",\n\t\t\t\t(new DialogInterface.OnClickListener() {\n\t\t\t\t\t\n\t\t\t\t\tprivate boolean closeActivity;\n\t\t\t\n\t\t\t\t\tpublic void onClick(DialogInterface dialog, int id) {\n\t\t\t\t\t\tbuttonSelected(closeActivity);\n\t\t\t\t\t}\n\n\t\t\t\t\tpublic boolean getCloseActivity() {\n\t\t\t\t\t\treturn closeActivity;\n\t\t\t\t\t}\n\n\t\t\t\t\tpublic DialogInterface.OnClickListener setCloseActivity(boolean closeActivity) {\n\t\t\t\t\t\tthis.closeActivity = closeActivity;\n\t\t\t\t\t\treturn this;\n\t\t\t\t\t}\n\t\t\t\t}).setCloseActivity(dismiss));\n\t\t\n\t\tbuilder.setAdapter(adapter, new DialogInterface.OnClickListener() {\n\t\t\t@Override\n\t\t\tpublic void onClick(DialogInterface dialog, int which) {\n\t\t\t\tLog.d(TAG, dialog.toString()+\" ::: \"+which); // TODO make useful\n\t\t\t\t\n\t\t\t}\n\t\t});\n\t\tdialog = builder.create();\n\t\treturn dialog;\n\t}",
"public void working() {\n\t\t Dialog d = new Dialog(this);\r\n\t\t d.setTitle(\"hech yea!\");\r\n\t\t TextView tv = new TextView(this);\r\n\t\t tv.setText(\"Success\");\r\n\t\t d.setContentView(tv);\r\n\t\t d.show();\t\r\n\t}",
"@Override\n\t\tpublic void onClick(View arg0) {\n\t\t\tAlertDialog fuck = builder.create();\n\t\t\tfuck.show();\n\t\t}",
"@Override\n public void onClick(DialogInterface dialog, int id) {\n\n String chat = chat_field.getText().toString();\n\n\n LandingActivity current_activity = (LandingActivity)getActivity();\n if(current_activity != null){\n new Chat(chat, current_user.getUsername(), getActivity());\n }\n //Construct the new Object\n\n }",
"@Override\n public void onClick(DialogInterface dialog, int which) {\n Message msg = new Message();\n msg.what = 1;\n set_handler.sendMessage(msg);\n }",
"@Override\n public void onClick(View v) {\n materialDialog.dismiss();\n if (mListenner != null) {\n mListenner.onNagativeClick();\n }\n }",
"@Override\n public void onClick(View v) {\n materialDialog.dismiss();\n if (mListenner != null) {\n mListenner.onNagativeClick();\n }\n }",
"@Listen(\"onClick=#createEntryButton\")\n public void createEntryButtonOnClick(){\n Window window = (Window) Executions.createComponents(\"entry.zul\", phonePageWindow, new HashMap());\n window.doModal();\n }",
"@FXML\r\n\tvoid help_btn_clicked(MouseEvent event) {\r\n\t\tDialog<String> dia = new Dialog<>();\r\n\t\tStage stage = (Stage) dia.getDialogPane().getScene().getWindow();\r\n\t\tDialogPane dialogPane = dia.getDialogPane();\r\n\t\tdialogPane.getStylesheets().add(getClass().getResource(\"/client/boundry/dialog.css\").toExternalForm());\r\n\t\tdialogPane.getStyleClass().add(\"dialog\");\r\n\t\tdia.setTitle(\"Help Dialog\");\r\n\t\tdia.setHeaderText(\"Guide:\");\r\n\t\tdia.setGraphic(new ImageView(this.getClass().getResource(\"/icons8-info-48.png\").toString()));\r\n\t\t// Add a custom icon.\r\n\t\tstage.getIcons().add(new Image(this.getClass().getResource(\"/icons8-help-24.png\").toString()));\r\n\t\tdia.getDialogPane().getButtonTypes().addAll(ButtonType.OK);\r\n\t\tdia.setContentText(\r\n\t\t\t\t\"Main Sale Pattern Screen\\nIn this screen you can choose sale from table,add sale, delete and open\\n\"\r\n\t\t\t\t\t\t+ \"for full information, click on specific sale and choose an action, in addition you can click\"\r\n\t\t\t\t\t\t+ \"on \\\"Statistics\\\" for statistic inforamtion\");\r\n\t\tdia.show();\r\n\t}",
"@Override\n public void onClick(DialogInterface dialog, int id)\n {\n }",
"private Dialogs () {\r\n\t}",
"@Override\r\n public Dialog onCreateDialog(Bundle savedInstanceState) {\r\n //use the builder class for convenient dialog construction\r\n AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());\r\n //get the layout inflater\r\n LayoutInflater inflater = getActivity().getLayoutInflater();\r\n View rootView = inflater.inflate(R.layout.dialog_room, null);\r\n mRoomNumber = rootView.findViewById(R.id.roomNumberEditText);\r\n mAllergy = rootView.findViewById(R.id.allergyEditText);\r\n mPlateType = rootView.findViewById(R.id.plateTypeEditText);\r\n mChemicalDiet = rootView.findViewById(R.id.chemicalDietEditText);\r\n mTextureDiet = rootView.findViewById(R.id.textureDietEditText);\r\n mLiquidDiet = rootView.findViewById(R.id.liquidDietEditText);\r\n mLikes = rootView.findViewById(R.id.likesEditText);\r\n mDislikes = rootView.findViewById(R.id.dislikesEditText);\r\n mNotes = rootView.findViewById(R.id.notesEditText);\r\n mMeal = rootView.findViewById(R.id.mealEditText);\r\n mDessert = rootView.findViewById(R.id.dessertEditText);\r\n mBeverage = rootView.findViewById(R.id.beverageEditText);\r\n\r\n mBeverage.setOnEditorActionListener(new TextView.OnEditorActionListener() {\r\n @Override\r\n public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {\r\n if (i == EditorInfo.IME_ACTION_DONE || keyEvent.getAction() == KeyEvent.ACTION_DOWN){\r\n addRoom();\r\n }\r\n return true;\r\n }\r\n });\r\n\r\n //inflate and set the layout for the dialog\r\n //pass null as the parent view cause its going in the dialog layout.\r\n builder.setView(rootView).setPositiveButton(R.string.button_done, new DialogInterface.OnClickListener() {\r\n @Override\r\n public void onClick(DialogInterface dialogInterface, int i) {\r\n addRoom();\r\n }\r\n });\r\n\r\n return builder.create();\r\n }",
"private void callEventListener(){\n //Listener for Button add service\n btn_Appointment.setOnClickListener(\n new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n dialogCreateAppointment();\n }\n }\n );\n\n }",
"@Override\n public void onClick(DialogInterface dialog, int which) {\n\n }",
"@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t\n\t\t\t\tshowDialog();\n\t\t\t}"
] | [
"0.654332",
"0.6539097",
"0.6435143",
"0.6364623",
"0.6335545",
"0.6317723",
"0.631396",
"0.63137895",
"0.627607",
"0.62716186",
"0.62420565",
"0.6232228",
"0.621411",
"0.6198495",
"0.6197982",
"0.6191343",
"0.6190843",
"0.6185656",
"0.61812705",
"0.6134826",
"0.61271834",
"0.60737306",
"0.60549533",
"0.6051684",
"0.60449535",
"0.60416675",
"0.6041325",
"0.60391575",
"0.6032193",
"0.60272753",
"0.6026429",
"0.602298",
"0.60198027",
"0.60142285",
"0.6005064",
"0.5998163",
"0.59923905",
"0.5991283",
"0.59819937",
"0.59645295",
"0.59639996",
"0.59495604",
"0.59440213",
"0.594352",
"0.5934226",
"0.59296674",
"0.5920911",
"0.5884323",
"0.5878289",
"0.58774847",
"0.5867765",
"0.58613265",
"0.5860774",
"0.5859896",
"0.58518785",
"0.58492506",
"0.5843791",
"0.584086",
"0.58380276",
"0.5837714",
"0.5834813",
"0.58343744",
"0.583094",
"0.5830727",
"0.5827771",
"0.5827771",
"0.5822493",
"0.58172834",
"0.5808103",
"0.5805433",
"0.58042556",
"0.5803783",
"0.5801459",
"0.5800115",
"0.5800115",
"0.5800115",
"0.5800115",
"0.5798189",
"0.57957155",
"0.5792766",
"0.57893866",
"0.57816446",
"0.57806736",
"0.5779442",
"0.57790565",
"0.5776377",
"0.5775372",
"0.5772241",
"0.57670724",
"0.57583547",
"0.57570094",
"0.57570094",
"0.57557166",
"0.5755658",
"0.57550216",
"0.57548124",
"0.57527226",
"0.57527184",
"0.57510394",
"0.57398736"
] | 0.6181439 | 18 |
TODO Autogenerated method stub /System.out.println("Hiiii"); System.out.println("Hiiii"); | public static void main(String[] args) {
HelloWorld.init();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void haha(){\n System.out.println(\"thavasi\");\n }",
"@Override\n\tpublic void juxing() {\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t\tSystem.out.println(\"***************\");\n\t}",
"@Override\n\tpublic void falar() {\n\t\tSystem.out.println(\"Kuack\");\n\t}",
"private void sysout() {\nSystem.out.println(\"pandiya\");\n}",
"public void test() {\n\t\tSystem.out.println(\"Still here, keep going dude.\");\n\t}",
"@Override\r\n\tpublic void alimentar() {\n\t\tSystem.out.print(\" como carne, yummy, yummy\");\r\n\t}",
"static void print (){\n \t\tSystem.out.println();\r\n \t}",
"@Test\n\tpublic static void m() {\n\t\tSystem.out.println();\n\t\tSystem.out.println();\n\t\tSystem.out.println(\"Sample 3 added in eclipse\");\n\t\tSystem.out.println(\"to test upstream\");\n\t\tSystem.out.println(\"Sample 3 added in eclipse new line in system locally\");\n\t}",
"public void test() {\n\t\tSystem.out.println(\"Test\");\r\n\t}",
"private void syso() {\nSystem.out();\r\n}",
"private static void Secondcommentary() {\n\t\tSystem.out.println(\" Ind Scored very Good \");\n\t\t\n\t}",
"void vorbereiten(){\n\t\tSystem.out.println(\"vorbereiten \");\n\t}",
"public void t(){\n System.out.println( \"Some text \"); \n }",
"private void mian()\r\n {\n System.out.println(\"Hello World222222221111\");\n System.out.println(\"12345\");\n }",
"public void test() {\n\t\tSystem.out.println(\"test\");\n\t}",
"@Override\n public void tests() {\n System.out.println(\"222222222222222222\"); \n }",
"@Override\r\n\tpublic void simpleOperation() {\n\t\tSystem.out.println(\"I'm building house\");\r\n\r\n\t}",
"@Override\n public void comunicar() {\n System.out.println(\"miauuuu\");\n\n }",
"private void sout() {\n\t\t\n\t}",
"@Override\n\tpublic void display() {\n\t\tSystem.out.println(\"Hyunjun\");\n\t}",
"@Override\r\n\tpublic void fly() {\n\t\tSystem.out.println(\"오리날다\");\r\n\t}",
"@Override\n\tpublic void maasHesapla() {\n\t\tSystem.out.println(\"isciler icin maas 5000 tl \");\n \t\t\n\t}",
"public void sing() {\n\t\t System.out.println(lyric);\n\t}",
"private void oops(){\n\t\tSystem.out.println(\"Oops! \" +getCandyName() +\" is delicious! I ate that one.\");\n\t}",
"@Override\r\n\t\tpublic void doDomething() {\r\n\t\t\tSystem.out.println(\"I am here\");\r\n\t\t\t\r\n\t\t}",
"@Override\r\n\tpublic void breathe() {\n\t\tSystem.out.println(\"#gasp#\");\r\n\t}",
"@Override\r\n\tpublic void hacerSonido() {\n\t\tSystem.out.print(\"miau,miau -- o depende\");\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n System.out.println(\"kkkjhhdjh\");\r\n System.out.println(\"pppppppppppppppp\");\r\n System.out.println(\"Overwriden\");\r\n\t}",
"public void printYourself(){\n\t}",
"@Override\n public void print() {\n System.out.println(\"Hello World Old Style!!\");\n }",
"@Override\r\n\t\t\tpublic void print() {\n\t\t\t\t\r\n\t\t\t}",
"public void schnattern() {\n\t\tSystem.out.println(\"Schnatter\");\n\t}",
"public void Makan()\n\t{\n\tSystem.out.println(\"Harimau Makan Daging dan minum susu\");\n\tSystem.out.println();\n\t}",
"@Override\n\t\t\tpublic void print() {\n\t\t\t\t\n\t\t\t}",
"@Override\r\n\tvoid poop() {\n\t\tSystem.out.println(\"stinky\");\r\n\t}",
"@Override\n\tpublic void cry() \n\t{\n\t\tSystem.out.println(\"喵喵喵\");\n\t\t\n\t}",
"@Override\n\tpublic void printOne() {\n\t\tSystem.out.println(\"D's printOne\");\n\t}",
"private void methodOne() {\n\t\tSystem.out.println(\"I am method one\");\n\t}",
"@Override\n\tpublic void habla() {\n\t\tSystem.out.println(\"Miau, Miau!!\");\n\t}",
"@Override\r\n\tpublic void trunOn() {\n\t\tSystem.out.println(\"끄다\");\r\n\t}",
"private static void FinalIndVsPAk() {\n\t\tSystem.out.println(\"Pak Lost The Match\");\n\t\t\n\t}",
"@Override\r\n\tpublic void doThing() {\n\t\tSystem.out.print(\"ÎäÆ÷ÊDZ¦½£,\");\r\n\t}",
"void comer() {\n\t\tSystem.out.println(\"comiendo\");\n\t}",
"@Override\n\tpublic void happyWithMan() {\n\t\tSystem.out.println(\"ÕýÄÇɶĨ¡£¡£¡£\");\n\t}",
"public void purr() {\n\t\tSystem.out.println(\"Brrrrrrrrrrrrr\");\n\t}",
"public void comer(){\r\n\t\tSystem.out.println(\"He comido\");\r\n\t}",
"public static void schreibHallo() {\n System.out.println(\"Hallo\");\n }",
"public void breathe(){\n\n System.out.println(\"Through big nostrills\");\n }",
"@Override\n\tpublic void 숨쉰다() {\n\t\tSystem.out.println(\"허파로 숨을 쉰다.\");\n\t\t\n\t}",
"public static void main(String[] args) {\nSystem.out.println(\"hello\");\r\nSystem.out.println(\"world\");\r\nSystem.out.println(\"haaai\");\r\nSystem.out.println(\"hell\");\r\n\t}",
"private void printLine()\r\n\t{\r\n\t}",
"public void mo97908d() {\n }",
"private void psvm() {\n\t\tSystem.out.println(\"test\");\r\n\t}",
"void crie(){\n\t\tSystem.out.println(\"miolement\");\n\t}",
"@Override\n\tvoid show() {\n\t\tSystem.out.println(\"Test\");\n\t}",
"public void test2() {\n\t\tSystem.out.println(\"I am Test 2\");\n\t}",
"default void trip() {\n\t\tSystem.out.println(\"Oh no you fell! :(\");\n\t}",
"public void Practice1(){\n System.out.println(\"Hello\");\n }",
"public void test( ){\n\t\t\tSystem.out.println(\"test method\"); //no input, no output\n\t\t}",
"public void barking()\r\n {\r\n \tSystem.out.println (\"Woof Woof\");\r\n }",
"public void test(){//no input no output\n System.out.println(\"test method\");\n\n }",
"public static void main(String[] args) {\nSystem.out.println(\"hi\");\r\nSystem.out.println(\"neelu\");\r\nSystem.out.println(\"change qu kiya\");\r\nSystem.out.println(\"neeraj...\");\r\nSystem.out.println(\"push\");\r\nSystem.out.println(\"push again\");\r\nSystem.out.println(\"changes done again\");\r\n\t}",
"public void test01() {\n\t\tSystem.out.println(\"I am in test01() method\");\n\t}",
"@Override\n\tpublic void prepare() {\n\t\tSystem.out.println(\"i am in ShanTou,i like the pork,so i add the pork\");\n\n\t}",
"public static void hi() {\n System.out.println(\"Hi\");\n }",
"public void bad(){\n\t\tSystem.out.println(\"you mom's a beautiful woman\");\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"public void hello(){\n\t\t\r\n \t\r\n\t\t\r\n\t}",
"@Override\n\tpublic void HowtoEat() {\n\t\tSystem.out.println(\"Fırında Ye!!\");\n\t}",
"public void printStatement() {\n\t\t\n\t}",
"@Override\n\t\tpublic void print() {\n\n\t\t}",
"@Override\r\n\tpublic void hello() {\n\t\tSystem.out.println(\"in Hello\");\r\n\t}",
"@Override\n\tpublic void cry() {\n\t\tSystem.out.println(\"黄种人-哭\");\n\t}",
"@Override\n\tpublic void print() {\n\t\t\n\t}",
"public void furyo ()\t{\n }",
"@Override\r\n\tpublic void 먹기() {\n\t\tSystem.out.println(\"다람쥐,도토리를 먹는다.\");\r\n\t}",
"private void test() {\n\n\t}",
"public static void hvitetest1w(){\r\n\t}",
"public void display2(){\n System.out.println(\"codegym\");\n }",
"public void mo38117a() {\n }",
"public void test5() {\n\t\t\n\t}",
"@Override\n\tpublic void bolumSoyle() {\n\t\tSystem.out.println(\"Benim Bölümüm Psi\");\n\t}",
"public void operation() {\n\t\tSystem.out.println(\"B\");\n\t}",
"@Override\r\n\tpublic void 자기() {\n\t\tSystem.out.println(\"잠을 잔다\");\r\n\t}",
"@Override\n\tvoid showMsg() {\n\t\tSystem.out.println(\"Sample\");\n\t}",
"@Override\r\n\tpublic void print() {\n\t}",
"void miau() {\r\n\t\tSystem.out.println(\"Miauuuu!\");\r\n\t}",
"String print() {\n\t\treturn \"Hi\";\n\t}",
"public static void main(String[] args) {\n\t\tSystem.out.println(\"iiAIDI\");\r\nSystem.out.println(\"jka\");\r\n\t}",
"public void mo97906c() {\n }",
"public static void Method()\n {\n System.out.println(\"No. 1\");\n }",
"public void h() {\n }",
"private void printGoodbye()\n {\n System.out.println(\"Nice talking to you. Bye...\");\n }",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n\tpublic void Examinar() {\n\t\tSystem.out.println(\"\\nEsta preguiça emite o som tec tec tec ao ser examinada\\n\");\t\n\t}",
"private void kk12() {\n\n\t}",
"public static void thisDemo() {\n\t}",
"@Override\n\tpublic void print() {\n\n\t}",
"public void println()\n\t{\n\t\tSystem.out.println();\n\t}",
"void rajib () {\n\t\t \n\t\t System.out.println(\"Rajib is IT Eng\");\n\t }",
"public void stg() {\n\n\t}"
] | [
"0.7244117",
"0.7208302",
"0.7019177",
"0.6997366",
"0.69719136",
"0.6888461",
"0.6873664",
"0.68495256",
"0.681639",
"0.6772099",
"0.6752139",
"0.67517656",
"0.6742545",
"0.67337734",
"0.6733137",
"0.67102796",
"0.67016923",
"0.66960216",
"0.6669317",
"0.66379154",
"0.6623333",
"0.6615868",
"0.6598669",
"0.6597398",
"0.6576817",
"0.6576158",
"0.65732455",
"0.6558126",
"0.65570587",
"0.6537993",
"0.65286994",
"0.6522329",
"0.6514598",
"0.6514027",
"0.6497012",
"0.6494771",
"0.649084",
"0.64865834",
"0.64845294",
"0.6483088",
"0.6482626",
"0.6482496",
"0.6457275",
"0.64410204",
"0.6439217",
"0.6434368",
"0.642986",
"0.6421083",
"0.64200795",
"0.64176893",
"0.640098",
"0.63993603",
"0.6390507",
"0.638968",
"0.6374192",
"0.6355353",
"0.6347844",
"0.6338267",
"0.63319707",
"0.63311744",
"0.6329838",
"0.6327227",
"0.63175994",
"0.63169557",
"0.63119173",
"0.630954",
"0.63086694",
"0.63059896",
"0.63016444",
"0.6301509",
"0.6299487",
"0.6288972",
"0.62885493",
"0.6283548",
"0.6280878",
"0.62792283",
"0.62770957",
"0.6275186",
"0.62710965",
"0.62629414",
"0.6262442",
"0.62592304",
"0.62549764",
"0.62511265",
"0.6250402",
"0.6249907",
"0.6238886",
"0.6235435",
"0.6233944",
"0.62330914",
"0.623173",
"0.621899",
"0.6216062",
"0.6215979",
"0.62084603",
"0.62082946",
"0.6206046",
"0.6205382",
"0.62009144",
"0.6200107",
"0.6198153"
] | 0.0 | -1 |
Contructor de la Clase | public Ventana(){
super.setTitle("Operaciones");
super.setSize(320, 480);
super.setDefaultCloseOperation(EXIT_ON_CLOSE); //para el botón de cerrar
cargarControles();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Clade() {}",
"Constructor() {\r\n\t\t \r\n\t }",
"public Constructor(){\n\t\t\n\t}",
"public Pasien() {\r\n }",
"public Coche() {\n super();\n }",
"public Carrera(){\n }",
"public Curso() {\r\n }",
"public Chauffeur() {\r\n\t}",
"public Alojamiento() {\r\n\t}",
"public AntrianPasien() {\r\n\r\n }",
"public CyanSus() {\n\n }",
"public Cohete() {\n\n\t}",
"public PSRelation()\n {\n }",
"public SgaexpedbultoImpl()\n {\n }",
"public Lanceur() {\n\t}",
"public Classe() {\r\n }",
"private Instantiation(){}",
"public Carrinho() {\n\t\tsuper();\n\t}",
"private TMCourse() {\n\t}",
"public Livro() {\n\n\t}",
"public Corso() {\n\n }",
"public CSSTidier() {\n\t}",
"public SlanjePoruke() {\n }",
"public Cgg_jur_anticipo(){}",
"public Funcionario() {\r\n\t\t\r\n\t}",
"public Libro() {\r\n }",
"public TCubico(){}",
"public JSFOla() {\n }",
"protected Asignatura()\r\n\t{}",
"public Implementor(){}",
"public prueba()\r\n {\r\n }",
"public Caso_de_uso () {\n }",
"public Achterbahn() {\n }",
"public StudentChoresAMImpl() {\n }",
"public Odontologo() {\n }",
"protected Approche() {\n }",
"public Phl() {\n }",
"public Catelog() {\n super();\n }",
"public Rol() {}",
"public Pitonyak_09_02() {\r\n }",
"public ClaseJson() {\n }",
"public Aritmetica(){ }",
"private BaseDatos() {\n }",
"public Chick() {\n\t}",
"private UsineJoueur() {}",
"public Chant(){}",
"public Supercar() {\r\n\t\t\r\n\t}",
"protected abstract void construct();",
"public Ctacliente() {\n\t}",
"defaultConstructor(){}",
"public Propuestas() {}",
"public CCuenta()\n {\n }",
"public ChaCha()\n\t{\n\t\tsuper();\n\t}",
"public Cable() {\r\n }",
"public contrustor(){\r\n\t}",
"public Plato(){\n\t\t\n\t}",
"public Troco() {\n }",
"public Vehiculo() {\r\n }",
"public Contato() {\n }",
"public TTau() {}",
"public Mitarbeit() {\r\n }",
"public Orbiter() {\n }",
"public Data() {\n \n }",
"public Anschrift() {\r\n }",
"private Composite() {\n }",
"public Ov_Chipkaart() {\n\t\t\n\t}",
"public Exercicio(){\n \n }",
"public Parameters() {\n\t}",
"public DetArqueoRunt () {\r\n\r\n }",
"public _355() {\n\n }",
"private Marinator() {\n }",
"private Marinator() {\n }",
"public ValorVariavel() {\r\n }",
"private LOCFacade() {\r\n\r\n\t}",
"private ATCres() {\r\n // prevent to instantiate this class\r\n }",
"public AvaliacaoRisco() {\n }",
"public Funcionaria(){\n\n }",
"public FiltroMicrorregiao() {\r\n }",
"private ControleurAcceuil(){ }",
"public Candidatura (){\n \n }",
"public Aktie() {\n }",
"private SimpleRepository() {\n \t\t// private ct to disallow external object creation\n \t}",
"private Rekenhulp()\n\t{\n\t}",
"public FicheConnaissance() {\r\n }",
"public Demo() {\n\t\t\n\t}",
"private Ex() {\n }",
"public lo() {}",
"public Kullanici() {}",
"public Valvula(){}",
"public Data() {\n }",
"public Data() {\n }",
"public Respuesta() {\n }",
"public MPaciente() {\r\n\t}",
"public Mannschaft() {\n }",
"public Postoj() {}",
"public Tigre() {\r\n }",
"private SingleObject()\r\n {\r\n }",
"public OOP_207(){\n\n }",
"public OVChipkaart() {\n\n }",
"public Prova() {}",
"public Facturacion() {\n }"
] | [
"0.83088136",
"0.7941088",
"0.7861839",
"0.752394",
"0.7496708",
"0.7469222",
"0.742694",
"0.74126345",
"0.74062765",
"0.73980707",
"0.7383979",
"0.73755157",
"0.73509103",
"0.73065877",
"0.7295485",
"0.7284737",
"0.7227689",
"0.72232014",
"0.7209255",
"0.7200684",
"0.7180614",
"0.71669495",
"0.71648",
"0.7163929",
"0.71250045",
"0.71198493",
"0.7115987",
"0.7105551",
"0.7101412",
"0.7078879",
"0.7077085",
"0.7066844",
"0.705161",
"0.70455337",
"0.70422226",
"0.7040836",
"0.7014238",
"0.7010373",
"0.6997687",
"0.6976355",
"0.6976084",
"0.6973888",
"0.6957917",
"0.6957428",
"0.69534624",
"0.6950053",
"0.693502",
"0.69340396",
"0.69318676",
"0.692508",
"0.6924804",
"0.6921726",
"0.6919909",
"0.6919595",
"0.69193184",
"0.69170755",
"0.69123167",
"0.6900854",
"0.6898094",
"0.68976927",
"0.6891123",
"0.6885816",
"0.68840647",
"0.68826795",
"0.68706155",
"0.6870068",
"0.6851769",
"0.68512976",
"0.68468386",
"0.68444735",
"0.6841469",
"0.6841469",
"0.6841216",
"0.6839674",
"0.6838203",
"0.6837563",
"0.6837248",
"0.6835543",
"0.6833429",
"0.6829367",
"0.6828479",
"0.68112993",
"0.6806815",
"0.6805048",
"0.6803416",
"0.68010277",
"0.6793525",
"0.67920935",
"0.67915905",
"0.67903835",
"0.67903835",
"0.67884696",
"0.6787442",
"0.6786393",
"0.6783296",
"0.67830694",
"0.67748773",
"0.67722255",
"0.67710227",
"0.67647976",
"0.6760152"
] | 0.0 | -1 |
se declaran los objetos | private void cargarControles() {
c.setLayout(null); //acomodar los objetos como yo quiera
lbN1.setBounds(10, 10, 280, 30);
c.add(lbN1); //se asigna al contenedor
txtN1.setBounds(10, 40, 280,30);
c.add(txtN1);
lbN2.setBounds(10,80,300,30);
c.add(lbN2);
txtN2.setBounds(10,110, 280,30);
c.add(txtN2);
btnCalcular.setBounds(10, 150, 280, 30);
c.add(btnCalcular);
lbResultado.setBounds(120,180, 280, 30);
c.add(lbResultado);
//evento en el botón
btnCalcular.addActionListener(this);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void init() {\r\n\t\tlog.info(\"init()\");\r\n\t\tobjIncidencia = new IncidenciaSie();\r\n\t\tobjObsIncidencia = new ObservacionIncidenciaSie();\r\n\t\tobjCliente = new ClienteSie();\r\n\t\tobjTelefono = new TelefonoPersonaSie();\r\n\t}",
"private void initObjects() {\n inputValidation = new InputValidation(activity);\n databaseHelper = new DatabaseHelper(activity);\n user = new User();\n }",
"public void limpiarCampos() {\n\t\ttema = new Tema();\n\t\ttemaSeleccionado = new Tema();\n\t\tmultimedia = new Multimedia();\n\t}",
"public void inicialisation(){\r\n\t\t\r\n\t\tgoods = new AutoParts[0];\r\n\t\tclient = new Client[0];\r\n\t\t\r\n\t\tshop = new Shopping[0];\r\n\t\tsale = new Sale[0];\r\n\t\ttransaction = new Document[0];\r\n\t\t\r\n\t\tbalancesAutoParts = new BalancesAutoParts[0];\r\n\t\t\r\n\t\tprices = new Prices[0];\r\n\t\t\r\n\t\tagriment = new Agreement[0];\r\n\t\t\r\n\t}",
"private void prepare()\n {\n Victoria victoria = new Victoria();\n addObject(victoria,190,146);\n Salir salir = new Salir();\n addObject(salir,200,533);\n Volver volver = new Volver();\n addObject(volver,198,401);\n }",
"public void init(){\n\t\tEmployee first = new Employee(\"Diego\", \"Gerente\", \"bebexitaHemoxita@gmail.com\");\n\t\tHighSchool toAdd = new HighSchool(\"Santiago Apostol\", \"4656465\", \"cra 33a #44-56\", \"3145689879\", 30, 5000, \"Jose\", new Date(1, 3, 2001), 3, \"Servicios educativos\", \"451616\", 15, \"Piedrahita\", 45, 1200, 500);\n\t\ttoAdd.addEmployee(first);\n\t\tProduct pilot = new Product(\"jet\", \"A00358994\", 1.5, 5000);\n\t\tFood firstFood = new Food(\"Colombina\", \"454161\", \"cra 18\", \"454611313\", 565, 60000, \"Alberto\", new Date(1, 8, 2015), 6, \"Manufactura\", 4);\n\t\tfirstFood.addProduct(pilot);\n\t\ttheHolding = new Holding(\"Hertz\", \"15545\", \"cra 39a #30a-55\", \"3147886693\", 80, 500000, \"Daniel\", new Date(1, 2, 2015), 5);\n\t\ttheHolding.addSubordinate(toAdd);\n\t\ttheHolding.addSubordinate(firstFood);\n\t}",
"public Controlador() {\n\t\t// m\n\t\tdatosPrueba1 = new ListaEnlazada();\n\t\t// m\n\t\tdatosPrueba2 = new ListaEnlazada();\n\t\t// add\n\t\tdatosPrueba3 = new ListaEnlazada();\n\t\tdatosPrueba4 = new ListaEnlazada();\n\t\tprueba1 = new Estadisticas(datosPrueba1);\n\t\tprueba2 = new Estadisticas(datosPrueba2);\n\t\tprueba3 = new Estadisticas(datosPrueba3);\n\t\tprueba4 = new Estadisticas(datosPrueba4);\n\t\t// finAdd\n\t}",
"private void crearObjetos() {\n // crea los botones\n this.btnOK = new CCButton(this.OK);\n this.btnOK.setActionCommand(\"ok\");\n this.btnOK.setToolTipText(\"Confirmar la Operación\");\n \n this.btnCancel = new CCButton(this.CANCEL);\n this.btnCancel.setActionCommand(\"cancel\");\n this.btnCancel.setToolTipText(\"Cancelar la Operación\");\n \n // Agregar los eventos a los botones\n this.btnOK.addActionListener(this);\n this.btnCancel.addActionListener(this);\n }",
"@PostConstruct\n\tprivate void init() {\n\t\tEntrada entr = new Entrada(\n\t\t\t\tnew Persona(\"Manuel\",\"Jimenex\",\"52422\",\"100000\",\"Cra 340\"),\n\t\t\t\t(new PreFactura(1l,new Date())), itemsService.lista());\n\t\t\n\t\tlistaEntrada.add(entr);\n\t}",
"private void init()\n\t{\n\t\tsetModel(new Model(Id.model, this, null));\n\t\tsetEnviroment(new Enviroment(Id.enviroment, this, model()));\n\t\tsetVaccinationCenter(new VaccinationCenter(Id.vaccinationCenter, this, model()));\n\t\tsetCanteen(new Canteen(Id.canteen, this, vaccinationCenter()));\n\t\tsetRegistration(new Registration(Id.registration, this, vaccinationCenter()));\n\t\tsetExamination(new Examination(Id.examination, this, vaccinationCenter()));\n\t\tsetVaccination(new Vaccination(Id.vaccination, this, vaccinationCenter()));\n\t\tsetWaitingRoom(new WaitingRoom(Id.waitingRoom, this, vaccinationCenter()));\n\t\tsetSyringes(new Syringes(Id.syringes, this, vaccination()));\n\t}",
"public void inicializar();",
"private void init() {\n this.listaObjetos = new ArrayList();\n this.root = null;\n this.objeto = new Tblobjeto();\n this.pagina = new Tblpagina();\n this.selectedObj = null;\n this.menus = null;\n this.subMenus = null;\n this.acciones = null;\n this.nodes = new ArrayList<TreeNode>();\n this.selectedObjeto = null;\n this.selectedTipo = null;\n this.renderPaginaForm = null;\n this.renderGrupoForm = null;\n this.selectedGrupo = null;\n this.populateTreeTable();\n }",
"private void initObjects() {\n databaseHelper = new DatabaseHelper(activity);\n dbHelper = new DBHelper(activity);\n inputValidation = new InputValidation(activity);\n progress = new ProgressDialog(activity);\n user=new User();\n }",
"private void init() {\n\t\tthis.model = ModelFactory.createOntologyModel(OntModelSpec.OWL_MEM);\n\t\tthis.model.setNsPrefixes(INamespace.NAMSESPACE_MAP);\n\n\t\t// create classes and properties\n\t\tcreateClasses();\n\t\tcreateDatatypeProperties();\n\t\tcreateObjectProperties();\n\t\t// createFraktionResources();\n\t}",
"private Parser() {\n objetos = new ListaEnlazada();\n }",
"public void initObjects() {\n /*\n using findViewById references to the todoTitleEdittext,todoDateEditText,todoDescriptionEditText,saveTodoButton to from layout\n */\n todoTitleEditText = (EditText) findViewById(R.id.editText_todo_title);\n todoDateEditText = (EditText) findViewById(R.id.editText_todo_date);\n todoDescriptionEditText = (EditText) findViewById(R.id.editText_todo_description);\n saveTodoButton = (Button) findViewById(R.id.button_save_todo);\n }",
"public void crearAutomovil(){\r\n automovil = new Vehiculo();\r\n automovil.setMarca(\"BMW\");\r\n automovil.setModelo(2010);\r\n automovil.setPlaca(\"TWS435\");\r\n }",
"@PostConstruct\r\n public void inicializar() {\r\n try {\r\n anioDeclaracion = 0;\r\n existeDedPatente = false;\r\n deducciones = false;\r\n detaleExoDedMul = new ArrayList<String>();\r\n activaBaseImponible = 0;\r\n verBuscaPatente = 0;\r\n inicializarValCalcula();\r\n datoGlobalActual = new DatoGlobal();\r\n patenteActual = new Patente();\r\n patenteValoracionActal = new PatenteValoracion();\r\n verPanelDetalleImp = 0;\r\n habilitaEdicion = false;\r\n numPatente = \"\";\r\n buscNumPat = \"\";\r\n buscAnioPat = \"\";\r\n catDetAnio = new CatalogoDetalle();\r\n verguarda = 0;\r\n verActualiza = 0;\r\n verDetDeducciones = 0;\r\n verBotDetDeducciones = 0;\r\n listarAnios();\r\n } catch (Exception ex) {\r\n LOGGER.log(Level.SEVERE, null, ex);\r\n }\r\n }",
"private void inicializarcomponentes() {\n Comunes.cargarJList(jListBecas, becasFacade.getTodasBecasVigentes());\n \n }",
"public Propuestas() {}",
"@Before\n public void setUpTheObjects() {\n mh.setMessageDate(new Date());\n mr.setMessageHeader(mh);\n mr.getVaccinations().add(v);\n v.setAdministered(true);\n v.setAdminCvxCode(\"143\");\n }",
"public void crearPersona(){\r\n persona = new Persona();\r\n persona.setNombre(\"Jose\");\r\n persona.setCedula(12345678);\r\n }",
"public static void init()\n\t{\n\t\t\n\t\tu.creerGalaxie(\"VoieLactee\", \"spirale\", 0);\n\t\tu.creerEtoile(\"Soleil\", 0, 'F', u.getGalaxie(\"VoieLactee\")); //1\n\t\tu.creerObjetFroid(\"Terre\", 150000 , 13000 , 365 , u.getObjet(1)); //2\n\n\t\tu.creerObjetFroid(\"Lune\", 200 , 5000 , 30 , u.getObjet(2)); //3\n\n\t\tu.creerObjetFroid(\"Mars\", 200000 , 11000 , 750 , u.getObjet(1)); //4\n\n\t\tu.creerObjetFroid(\"Phobos\", 150 , 500 , 40 , u.getObjet(4)); //5\n\n\t\tu.creerObjetFroid(\"Pluton\", 1200000 , 4000 , 900 , u.getObjet(1)); //6\n\n\t\tu.creerEtoile(\"Sirius\", 2, 'B', u.getGalaxie(\"VoieLactee\")); //7\n\n\t\tu.creerObjetFroid(\"BIG-1\", 1000 , 50000 , 333 , u.getObjet(7)); //8\n\n\t\tu.creerGalaxie(\"M31\", \"lenticulaire\", 900000);\n\t\tu.creerEtoile(\"XS67\", 8, 'F', u.getGalaxie(\"M31\")); //9\n\t\tu.creerObjetFroid(\"XP88\", 160000 , 40000 , 400 , u.getObjet(9)); //10\n\t}",
"public ObjetosBeans() {\n this.init();\n }",
"private void objectInitialization(View view) {\n mbt_realizar_comentario_propietario = (Button) view.findViewById(R.id.bt_guardar_comentario_asesor);\n mbt_no_realizar_comentario = (Button) view.findViewById(R.id.bt_dialogo_cancelar_comentario_del_asesor);\n met_Comentario_del_Asesor = (EditText) view.findViewById(R.id.et_comentario_del_asesor);\n realmConfiguration = new RealmConfiguration.Builder(getActivity()).build();\n realm = Realm.getInstance(realmConfiguration);\n allEncuestas = realm.where(Encuesta.class).findAll();\n\n\n }",
"private static void LessonClassObjects() {\n Person person1 = new Person();\n Person person2 = new Person();\n\n //Set title, firstname and lastname\n person1.setTitle(\"Mr.\");\n person1.setFirstName(\"Jordan\");\n person1.setLastName(\"Walker\");\n\n person2.setTitle(\"Mrs.\");\n person2.setFirstName(\"Kelsey\");\n person2.setLastName(\"Walker\");\n\n //Print out\n System.out.println(person1.getTitle()+ \" \" + person1.getFirstName() + \" \" + person1.getLastName());\n System.out.println(person2.getTitle()+ \" \" + person2.getFirstName() + \" \" + person2.getLastName());\n\n // Set super BaseBO class\n person1.setId(7);\n System.out.println(person1.getFirstName() + \" Id is: \" + person1.getId());\n }",
"public Caso_de_uso () {\n }",
"private void inicializarTablero() {\n for (int i = 0; i < casillas.length; i++) {\n for (int j = 0; j < casillas[i].length; j++) {\n casillas[i][j] = new Casilla();\n }\n }\n }",
"private void prepare()\n {\n AmbulanceToLeft ambulanceToLeft = new AmbulanceToLeft();\n addObject(ambulanceToLeft,717,579);\n Car2ToLeft car2ToLeft = new Car2ToLeft();\n addObject(car2ToLeft,291,579);\n Car3 car3 = new Car3();\n addObject(car3,45,502);\n CarToLeft carToLeft = new CarToLeft();\n addObject(carToLeft,710,262);\n Car car = new Car();\n addObject(car,37,190);\n AmbulanceToLeft ambulanceToLeft2 = new AmbulanceToLeft();\n addObject(ambulanceToLeft2,161,264);\n }",
"public nomina()\n {\n deducidoClase = new deducido();\n devengadoClase = new devengado();\n }",
"@Override\r\n\tprotected void initVentajas() {\n\r\n\t}",
"public void inicializar() {\n\t\t// TODO Auto-generated method stub\n\t\tIDISFICHA=\"\";\n\t\tNOTAS=\"\";\n\t\tANOTACIONES=\"\";\n\t\tNOTAS_EJERCICIOS=\"\";\n\t}",
"private void inicializar() {\n\t\treporte = new Jasperreport();\n\t\tdiv = new Div();\n\t}",
"void initData() {\r\n\t\tthis.daVinci = new Artist(\"da Vinci\");\r\n\t\tthis.mona = new Painting(daVinci, \"Mona Lisa\");\r\n\t\t//this.lastSupper = new Painting(this.daVinci, \"Last Supper\");\r\n\t}",
"private void initData() {\n Author steinbeck = new Author(\"John\", \"Steinbeck\");\n Publisher p1 = new Publisher(\"Covici Friede\", \"111 Main Street\", \"Santa Cruz\", \"CA\", \"95034\");\n Book omam = new Book(\"Of Mice And Men\", \"11234\", p1);\n \n publisherRepository.save(p1);\n\n steinbeck.getBooks().add(omam);\n omam.getAuthors().add(steinbeck);\n authorRepository.save(steinbeck);\n bookRepository.save(omam);\n\n // Create Crime & Punishment\n Author a2 = new Author(\"Fyodor\", \"Dostoevsky\");\n Publisher p2 = new Publisher( \"The Russian Messenger\", \"303 Stazysky Rao\", \"Rustovia\", \"OAL\", \"00933434-3943\");\n Book b2 = new Book(\"Crime and Punishment\", \"22334\", p2);\n a2.getBooks().add(b2);\n b2.getAuthors().add(a2);\n\n publisherRepository.save(p2);\n authorRepository.save(a2);\n bookRepository.save(b2);\n }",
"public static void instanciarCreencias() {\n\t\tfor(int i =0; i < GestorPartida.getContJugadores(); i++) {\n\t\t\t\n\t\t\tGestorPartida.jugadores[i].setCreencias(new Creencias(GestorPartida.jugadores, GestorPartida.objetoJugador, GestorPartida.objetoSala, i)); \n\t\t}\n\t}",
"public Alojamiento() {\r\n\t}",
"public Oveja() {\r\n this.nombreOveja = \"Oveja\";\r\n }",
"Objet getObjetAlloue();",
"public void inicializar() {\n\t\t// TODO Auto-generated method stub\n\t\tISHORARIO_IDISHORARIO=\"\";\n\t\tISAULA_IDISAULA=\"\";\n\t\tISCURSO_IDISCURSO=\"\";\n\t\t\n\t}",
"public void initialize() {\n\n fechaDeLaVisita.set(LocalDate.now());\n\n if (medico.get() != null) {\n medico.get().clear();\n } else {\n medico.set(new Medico());\n }\n\n turnoVisita.set(\"\");\n visitaAcompanadaSN.set(false);\n lugarVisita.set(\"\");\n if (causa.get() != null) {\n causa.get().clear();\n } else {\n causa.set(new Causa());\n }\n\n if (promocion.get() != null) {\n promocion.get().clear();\n } else {\n promocion.set(new Promocion());\n }\n\n observacion.set(\"\");\n persistida.set(false);\n persistidoGraf.set(MaterialDesignIcon.SYNC_PROBLEM.graphic());\n\n fechaCreacion.set(LocalDateTime.now());\n\n }",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\r\n\tpublic void init() throws ServletException {\n\t\tsuper.init();\r\n\t\r\n\t\tpdmodel = new pedidoModel();\r\n\t\tcmodel = new clienteModel();\r\n\t\tcnmodel = new cancionModel();\r\n\t}",
"protected void setup() {\r\n \t//inizializza gli attributi dell'iniziatore in base ai valori dei parametri\r\n Object[] args = this.getArguments();\r\n \t\tif (args != null)\r\n \t\t{\r\n \t\t\tthis.goodName = (String) args[0];\r\n \t\t\tthis.price = (int) args[1];\r\n \t\t\tthis.reservePrice = (int) args[2];\r\n \t\t\tthis.dif = (int) args[3];\r\n \t\t\tthis.quantity = (int) args[4];\r\n \t\t\tthis.msWait = (int) args[5];\r\n \t\t} \t\t\r\n\r\n manager.registerLanguage(codec);\r\n manager.registerOntology(ontology);\r\n \r\n //inizializza il bene oggetto dell'asta\r\n good = new Good(goodName, price, reservePrice, quantity);\r\n \r\n //cerca ed inserisce nell'ArrayList gli eventuali partecipanti\r\n findBidders(); \r\n \r\n //viene aggiunto l'apposito behaviour\r\n addBehaviour(new BehaviourInitiator(this));\r\n\r\n System.out.println(\"Initiator \" + this.getLocalName() + \" avviato\");\r\n }",
"private void initBefore() {\n // Crear Modelo\n model = new Model();\n\n // Crear Controlador\n control = new Controller(model, this);\n\n // Cargar Propiedades Vista\n prpView = UtilesApp.cargarPropiedades(FICHERO);\n\n // Restaurar Estado\n control.restaurarEstadoVista(this, prpView);\n\n // Otras inicializaciones\n }",
"public CianetoClass() {\r\n this.cianetoMethods = new Hashtable<String, Object>();\r\n this.cianetoAttributes = new Hashtable<String, Object>();\r\n }",
"private static void initObjectProperties() {\n OntModel ontologie = ModelFactory.createOntologyModel();\n OntologyFactory.readOntology(ontologyPath, ontologie);\n objectProperties.addAll(ontologie.listObjectProperties().toList());\n }",
"public Artefato() {\r\n\t\tthis.membros = new ArrayList<Membro>();\r\n\t\tthis.servicos = new ArrayList<IServico>();\r\n\t}",
"@Override\r\n\tprotected void init() {\r\n\t\tList<Configuracao> configs = servico.listarTodos();\r\n\t\tif (!configs.isEmpty()) {\r\n\t\t\tentidade = configs.get(0);\t// deve haver apenas um registro\r\n\t\t} else {\r\n\t\t\tcreateConfiguracao();\r\n\t\t}\r\n\t\t\r\n carregarTemas();\r\n\t}",
"public void inicializar() {\n\t\tarestas.forEach(aresta -> {\n\t\t\taresta.getOrigin().atribuirPesoInicial();\n\t\t\taresta.getTarget().atribuirPesoInicial();\n\t\t});\n\t}",
"private void init() {\n FieldWrapper id = new FieldWrapper();\n id.fieldDescription = new HashMap<String, Object>();\n id.fieldDescription.put(\"fullName\", \"Id\");\n id.fieldDescription.put(\"type\", \"Text\");\n\n FieldWrapper name = new FieldWrapper();\n name.fieldDescription = new HashMap<String, Object>();\n name.fieldDescription.put(\"fullName\", \"Name\");\n\n FieldWrapper createdBy = new FieldWrapper();\n createdBy.fieldDescription = new HashMap<String, Object>();\n createdBy.fieldDescription.put(\"fullName\", \"CreatedBy\");\n createdBy.fieldDescription.put(\"type\", \"Lookup\");\n\n FieldWrapper lastModifiedBy = new FieldWrapper();\n lastModifiedBy.fieldDescription = new HashMap<String, Object>();\n lastModifiedBy.fieldDescription.put(\"fullName\", \"LastModifiedBy\");\n lastModifiedBy.fieldDescription.put(\"type\", \"Lookup\");\n\n FieldWrapper owner = new FieldWrapper();\n owner.fieldDescription = new HashMap<String, Object>();\n owner.fieldDescription.put(\"fullName\", \"Owner\");\n owner.fieldDescription.put(\"type\", \"Lookup\");\n\n fieldDescribe = new HashMap<String, FieldWrapper>();\n\n fieldDescribe.put((String) id.fieldDescription.get(\"fullName\"), id);\n fieldDescribe.put((String) name.fieldDescription.get(\"fullName\"), name);\n fieldDescribe.put((String) createdBy.fieldDescription.get(\"fullName\"), createdBy);\n fieldDescribe.put((String) lastModifiedBy.fieldDescription.get(\"fullName\"), lastModifiedBy);\n fieldDescribe.put((String) owner.fieldDescription.get(\"fullName\"), owner);\n }",
"private void saveObjects() {\n\t\tgo.setMeteors(meteors);\n\t\tgo.setExplosions(explosions);\n\t\tgo.setTargets(targets);\n\t\tgo.setRockets(rockets);\n\t\tgo.setCrosses(crosses);\n\t\tgo.setEarth(earth);\n\t}",
"public Persona(){\n \n }",
"public Persona(){\n \n }",
"public Sobre() {\n\t\tsuper();\n\t\tinitialize();\n\t}",
"public Principal() {\n initComponents();\n empresaControlador = new EmpresaControlador();\n clienteControlador = new ClienteControlador();\n vehiculoControlador = new VehiculoControlador();\n servicioControlador = new ServicioControlador();\n archivoObjeto = new ArchivoObjeto(\"/home/diego/UPS/56/ProgramacionAplicada/Parqueadero/src/archivo/ClienteArchivo.obj\");// Ruta Absolojuta\n archivosBinarios = new ArchivosBinarios();\n archivosBinariosAleatorio = new ArchivosBinariosAleatorio(\"ServicioArchivo.dat\");//Ruta relativa\n }",
"public void inicializarListaMascotas()\n {\n //creamos un arreglo de objetos y le cargamos datos\n mascotas = new ArrayList<>();\n mascotas.add(new Mascota(R.drawable.elefante,\"Elefantin\",0));\n mascotas.add(new Mascota(R.drawable.conejo,\"Conejo\",0));\n mascotas.add(new Mascota(R.drawable.tortuga,\"Tortuga\",0));\n mascotas.add(new Mascota(R.drawable.caballo,\"Caballo\",0));\n mascotas.add(new Mascota(R.drawable.rana,\"Rana\",0));\n }",
"void setTvAttrib() {\r\n obj1.brandname = \"PANASONIC\"; //setting brandname for obj1\r\n obj1.size = 65; //setting size for obj1\r\n vendor.add(obj1); //adding to arraylist vendor\r\n\r\n obj2.brandname = \"KELVIN\"; //setting brandname for obj2\r\n obj2.size = 51; //setting size for obj2\r\n vendor.add(obj2); //adding to arraylist vendor\r\n\r\n obj3.brandname = \"SONY\"; //setting size for obj2\r\n obj3.size = 42; //setting size for obj2\r\n vendor.add(obj3); //adding to arraylist vendor\r\n\r\n }",
"private void limpiarDatos() {\n\t\t\n\t}",
"public cola_de_un_banco(){// se crea nuestro metodo costructor \r\n primero=null;//se crea el tipo de indicaciones con valor a null\r\n ultimo=null;\r\n}",
"public VPacientes() {\n initComponents();\n inicializar();\n }",
"public static void main(String[] args) {\n\r\n clsAlumno alumno1 = new clsAlumno();\r\n\r\n alumno1.setNombre(\"Eneko\");\r\n\r\n alumno1.setApellido(\"Galdos\");\r\n\r\n alumno1.setDNI(\"72826873H\");\r\n\r\n alumno1.setCreditos(60);\r\n\r\n alumno1.mostrarPersona();\r\n\r\n alumno1.mostrarCreditos();\r\n\r\n System.out.println();\r\n\r\n clsProfesor profesor1 = new clsProfesor();\r\n\r\n profesor1.setNombre(\"Javier\");\r\n\r\n profesor1.setApellido(\"Cerro\");\r\n\r\n profesor1.setDNI(\"11111111A\");\r\n\r\n profesor1.setDepartamento(\"Informática\");\r\n\r\n profesor1.mostrarPersona();\r\n\r\n profesor1.mostrarDepartamento();\r\n\r\n }",
"public Empresa()\n\t{\n\t\tclientes = new HashMap<String, Cliente>();\n\t\tplanes = new ArrayList<Plan>();\n\t\t\n\t}",
"private void guardarEstadoObjetosUsados() {\n }",
"public Funcionalidad() {\n Cajero cajero1 = new Cajero(\"Pepe\", 2);\n empleados.put(cajero1.getID(), cajero1);\n Reponedor reponedor1 = new Reponedor(\"Juan\", 3);\n empleados.put(reponedor1.getID(), reponedor1);\n Producto producto1 = new Producto(\"Platano\", 10, 8);\n productos.add(producto1);\n Perecedero perecedero1 = new Perecedero(LocalDateTime.now(), \"Yogurt\", 10, 8);\n }",
"public void initForAddNew() {\r\n\r\n\t}",
"@PostConstruct\r\n\tpublic void init() {\n\t\ttexto=\"Nombre : \";\r\n\t\topcion = 1;\r\n\t\tverPn = true;\r\n\t\ttipoPer = 1;\r\n\t\tsTipPer = \"N\";\r\n\t\tverGuar = true;\r\n\t\tvalBus = \"\";\r\n\t\tverCampo = true;\r\n\t\tread = false;\r\n\t\tgrabar = 0;\r\n\t\tcodCli = 0;\r\n\t\tcargarLista();\r\n\t}",
"private void inicializarVariablesControlRonda() {\n\t\ttieneAs = new int[4];\n\t\tfor(int i=0;i<tieneAs.length;i++) {\n\t\t\ttieneAs[i]=0;\n\t\t}\n\t\tidJugadores = new String[3];\n\t\tvalorManos = new int[4];\n\t\t\n\t\tmazo = new Baraja();\n\t\tCarta carta;\n\t\tganador = new ArrayList<String>();\n\t\tapuestasJugadores = new int[3];\n\t\tmanoJugador1 = new ArrayList<Carta>();\n\t\tmanoJugador2 = new ArrayList<Carta>();\n\t\tmanoJugador3 = new ArrayList<Carta>();\n\t\tmanoDealer = new ArrayList<Carta>();\n\t\tparejaNombreGanancia = new ArrayList<Pair<String,Integer>>(); \n\t\t\n\t\t// gestiona las tres manos en un solo objeto para facilitar el manejo del hilo\n\t\tmanosJugadores = new ArrayList<ArrayList<Carta>>(4);\n\t\tmanosJugadores.add(manoJugador1);\n\t\tmanosJugadores.add(manoJugador2);\n\t\tmanosJugadores.add(manoJugador3);\n\t\tmanosJugadores.add(manoDealer);\n\t\t// reparto inicial jugadores 1 y 2\n\t\tfor (int i = 1; i <= 2; i++) {\n\t\t\tcarta = mazo.getCarta();\n\t\t\tmanoJugador1.add(carta);\n\t\t\tcalcularValorMano(carta, 0);\n\t\t\tcarta = mazo.getCarta();\n\t\t\tmanoJugador2.add(carta);\n\t\t\tcalcularValorMano(carta, 1);\n\t\t\tcarta = mazo.getCarta();\n\t\t\tmanoJugador3.add(carta);\n\t\t\tcalcularValorMano(carta, 2);\n\t\t}\n\t\t// Carta inicial Dealer\n\t\tcarta = mazo.getCarta();\n\t\tmanoDealer.add(carta);\n\t\tcalcularValorMano(carta, 3);\n\n\t\t\n\t}",
"@Override\r\n\tpublic void inicializar() {\n\t\tproveedorDatamanager.setProveedorSearch(new Tcxpproveedor());\r\n\t\tproveedorDatamanager.getProveedorSearch().setTsyspersona(new Tsyspersona());\r\n\t\tproveedorDatamanager.setTipoIdColl(bunsysService.buscarObtenerCatalogos(proveedorDatamanager.getLoginDatamanager().getLogin().getPk().getCodigocompania(), ContenidoMessages.getInteger(\"cod_catalogo_tipoid_persona\")));\r\n\t\tproveedorDatamanager.setGrupoProvColl(bunsysService.buscarObtenerCatalogos(proveedorDatamanager.getLoginDatamanager().getLogin().getPk().getCodigocompania(), ContenidoMessages.getInteger(\"cod_catalogo_grupo_prov\")));\r\n\t\tproveedorDatamanager.setEstadoProvColl(bunsysService.buscarObtenerCatalogos(proveedorDatamanager.getLoginDatamanager().getLogin().getPk().getCodigocompania(), ContenidoMessages.getInteger(\"cod_catalogo_estado_persona\")));\r\n\t\tproveedorDatamanager.setProveedorComponente(new ProveedorComponent(proveedorDatamanager.getLoginDatamanager().getLogin().getPk().getCodigocompania()));\r\n\t}",
"public void creoVehiculo() {\n\t\t\n\t\tAuto a= new Auto(false, 0);\n\t\ta.encender();\n\t\ta.setPatente(\"saraza\");\n\t\ta.setCantPuertas(123);\n\t\ta.setBaul(true);\n\t\t\n\t\tSystem.out.println(a);\n\t\t\n\t\tMoto m= new Moto();\n\t\tm.encender();\n\t\tm.frenar();\n\t\tm.setManubrio(true);\n\t\tm.setVelMax(543);\n\t\tm.setPatente(\"zas 241\");\n\t\tVehiculo a1= new Auto(true, 0);\n\t\ta1.setPatente(\"asd 423\");\n\t\t((Auto)a1).setBaul(true);\n\t\t((Auto)a1).setCantPuertas(15);\n\t\tif (a1 instanceof Auto) {\n\t\t\tAuto autito= (Auto) a1;\n\t\t\tautito.setBaul(true);\n\t\t\tautito.setCantPuertas(531);\n\t\t\t\n\t\t}\n\t\tif (a1 instanceof Moto) {\n\t\t\tMoto motito=(Moto) a1;\n\t\t\tmotito.setManubrio(false);\n\t\t\tmotito.setVelMax(15313);\n\t\t\t\n\t\t\t\n\t\t}\n\t\tif (a1 instanceof Camion) {\n\t\t\tCamion camioncito=(Camion) a1;\n\t\t\tcamioncito.setAcoplado(false);\n\t\t\tcamioncito.setPatente(\"ge\");\n\t\t\t\n\t\t\t\n\t\t}\n\t\tVehiculo a2= new Moto();\n\t\tSystem.out.println(a2);\n\t\ta1.frenar();\n\t\t\n\t\tArrayList<Vehiculo>listaVehiculo= new ArrayList<Vehiculo>();\n\t\tlistaVehiculo.add(new Auto(true, 53));\n\t\tlistaVehiculo.add(new Moto());\n\t\tlistaVehiculo.add(new Camion());\n\t\tfor (Vehiculo vehiculo : listaVehiculo) {\n\t\t\tSystem.out.println(\"clase:\" +vehiculo.getClass().getSimpleName());\n\t\t\tvehiculo.encender();\n\t\t\tvehiculo.frenar();\n\t\t\tSystem.out.println(\"=======================================\");\n\t\t\t\n\t\t}\n\t}",
"private void Initialize()\n {\n \tEcran = new Rectangle(Framework.gauche, Framework.haut, Framework.frameWidth\n\t\t\t\t- Framework.droite - Framework.gauche, Framework.frameHeight - Framework.bas\n\t\t\t\t- Framework.haut);\n\t\tCentreEcranX = (int)(Ecran.getWidth()/2);\n\t\tCentreEcranY = (int)(Ecran.getHeight()/2);\n\t\twidth = Ecran.getWidth();\n\t\theight = Ecran.getHeight();\t\t\n\t\tpH=height/768;\t\t\n\t\tpW=width/1366;\n\t\tObjets = new ArrayList<Objet>(); // Créer la liste chainée en mémoire\n\t\tMissiles = new ArrayList<Missile>(); // Créer la liste chainée en mémoire\n\t\tStations = new ArrayList<Station>(); // Créer la liste chainée en mémoire\n\t\tJoueurs = new ArrayList<Joueur>();\n\t\tlastTrajectoires = new ArrayList<Trajectoire>();\n\n\t\tDisposeAstres(Framework.niveauChoisi);\n\t\tstationCourante = Stations.get(0);\n\n\t\tetat = ETAT.PREPARATION;\n\t\tmouseClicked = mousePressed = mouseReleased = false;\n\t}",
"public void iniciar() {\n\t\tcrearElementos();\n\t\tcrearVista();\n\n\t}",
"private void initializeObjects() {\r\n mName = view.findViewById(R.id.name);\r\n mEmail = view.findViewById(R.id.email);\r\n mPassword = view.findViewById(R.id.password);\r\n Button mRegister = view.findViewById(R.id.register);\r\n\r\n mRegister.setOnClickListener(this);\r\n }",
"BaseDatosMemoria() {\n baseDatos = new HashMap<>();\n secuencias = new HashMap<>();\n }",
"public Documento() {\n\n\t}",
"private void setAllAttributesFromController() {\n obsoData.setSupplier(supplier);\n \n obsoData.setEndOfOrderDate(endOfOrderDate);\n obsoData.setObsolescenceDate(obsolescenceDate);\n \n obsoData.setEndOfSupportDate(endOfSupportDate);\n obsoData.setEndOfProductionDate(endOfProductionDate);\n \n obsoData.setCurrentAction(avlBean.findAttributeValueListById(\n ActionObso.class, actionId));\n obsoData.setMtbf(mtbf);\n \n obsoData.setStrategyKept(avlBean.findAttributeValueListById(\n Strategy.class,\n strategyId));\n obsoData.setContinuityDate(continuityDate);\n \n obsoData.setManufacturerStatus(avlBean.findAttributeValueListById(\n ManufacturerStatus.class, manufacturerStatusId));\n obsoData.setAirbusStatus(avlBean.findAttributeValueListById(\n AirbusStatus.class, airbusStatusId));\n \n obsoData.setLastObsolescenceUpdate(lastObsolescenceUpdate);\n obsoData.setConsultPeriod(avlBean.findAttributeValueListById(\n ConsultPeriod.class, consultPeriodId));\n \n obsoData.setPersonInCharge(personInCharge);\n obsoData.setCommentOnStrategy(comments);\n }",
"private final void inicializarListas() {\r\n\t\t//Cargo la Lista de orden menos uno\r\n\t\tIterator<Character> it = Constantes.LISTA_CHARSET_LATIN.iterator();\r\n\t\tCharacter letra;\r\n\t\twhile (it.hasNext()) {\r\n\t\t\tletra = it.next();\r\n\t\t\tthis.contextoOrdenMenosUno.crearCharEnContexto(letra);\r\n\t\t}\r\n\t\t\r\n\t\tthis.contextoOrdenMenosUno.crearCharEnContexto(Constantes.EOF);\r\n\t\t\r\n\t\tthis.contextoOrdenMenosUno.actualizarProbabilidades();\r\n\t\t\r\n\t\t//Cargo las listas de ordenes desde 0 al orden definido en la configuración\r\n\t\tOrden ordenContexto;\r\n\t\tfor (int i = 0; i <= this.orden; i++) {\r\n\t\t\tordenContexto = new Orden();\r\n\t\t\tthis.listaOrdenes.add(ordenContexto);\r\n\t\t}\r\n\t}",
"@Override\r\n\tprotected void agregarObjeto() {\r\n\t\t// opcion 1 es agregar nuevo justificativo\r\n\t\tthis.setTitle(\"PROCESOS - PERMISOS INDIVIDUALES (AGREGANDO)\");\r\n\t\tthis.opcion = 1;\r\n\t\tactivarFormulario();\r\n\t\tlimpiarTabla();\r\n\t\tthis.panelBotones.habilitar();\r\n\t}",
"public Corso() {\n\n }",
"public Cobra()\r\n {\r\n super();\r\n corpo = new ArrayList<CorpoCobra>();\r\n\r\n porCrescer = 0;\r\n ovosComidos = 0;\r\n vidas = 3;\r\n tonta = 0;\r\n }",
"private void prepare()\n {\n addObject(new TempoLimite(), 432, 207);\n addObject(new NumeroVidas(), 395, 278);\n\n Cliqueparajogar clique = new Cliqueparajogar();\n addObject(clique, getWidth()/2, getHeight()/2);\n\n Som som = new Som();\n addObject(som, getWidth() - 37, getHeight()-57);\n \n umMin ummin = new umMin();\n addObject(ummin,630,206);\n\n doisMin doismin = new doisMin();\n addObject(doismin,670,206);\n \n tresMin tresmin = new tresMin();\n addObject(tresmin,710,206);\n \n quatroMin quatromin = new quatroMin();\n addObject(quatromin,750,206);\n \n cincoMin cincomin = new cincoMin();\n addObject(cincomin,790,206);\n \n umaVida umavida = new umaVida();\n addObject(umavida,630,280);\n \n duasVidas duasvidas = new duasVidas();\n addObject(duasvidas,670,280);\n \n tresVidas tresvidas = new tresVidas();\n addObject(tresvidas,710,280);\n \n quatroVidas quatrovidas = new quatroVidas();\n addObject(quatrovidas,750,280);\n \n cincoVidas cincovidas = new cincoVidas();\n addObject(cincovidas,790,280);\n \n voltaratras voltar = new voltaratras();\n addObject(voltar, getWidth() -37, 428);\n }",
"protected void inicializar(){\n kr = new CreadorHojas(wp);\n jPanel1.add(wp,0); // inserta el workspace en el panel principal\n wp.insertarHoja(\"Hoja 1\");\n //wp.insertarHoja(\"Hoja 2\");\n //wp.insertarHoja(\"Hoja 3\");\n }",
"public Controller(){\r\n\t\tthis.fabricaJogos = new JogoFactory();\r\n\t\tthis.loja = new Loja();\r\n\t\tthis.preco = 0;\r\n\t\tthis.desconto = 0;\r\n\t}",
"Foco createFoco();",
"private void makeObject() {\n\t\t\n\t\tItem I1= new Item(1,\"Cap\",10.0f,\"to protect from sun\");\n\t\tItemMap.put(1, I1);\n\t\t\n\t\tItem I2= new Item(2,\"phone\",100.0f,\"Conversation\");\n\t\tItemMap.put(2, I2);\n\t\t\n\t\tSystem.out.println(\"Objects Inserted\");\n\t}",
"public Saida() {\n initComponents();\n defaults();\n preencherTabela();\n \n }",
"public Propiedad() {\n bdPropiedad = new DaoPropiedad();\n bdComentario = new DaoComentario();\n }",
"public TipoDocumentoMB() {\n tipoDoc = new TipoDocPersona();\n }",
"public Kullanici() {}",
"public void inici() {\n\t\n if (filename == null) {\n \t//System.err.println(Resources.getResource(\"./modelo/cube.obj\"));\n \t filename = Resources.getResource(\"./modelo/cube.obj\");\n if (filename == null) {\n System.err.println(\"modelo/cube.obj nots found\");\n System.exit(1);\n }\n\t}\n\t}",
"@Before\n\tpublic void init() {\n\t\t\n\n\t\tCalendar cal = Calendar.getInstance();\n\t\t\n\t cal.add(Calendar.DATE, -2); \n\t \n\t fechaOperacion = LocalDate.of(cal.get(Calendar.YEAR), cal.get(Calendar.MONTH), cal.get(Calendar.DAY_OF_MONTH));\n\t \n\n\t\t\n\t\tCiudad buenos_aires = new Ciudad(new Provincia(\"Argentina\", \"Buenos Aires\"), \"Capital Federal\");\n\t \t\n \tProvincia prov_buenos_aires = new Provincia(\"Ciudad Autonoma de Buenos Aires\",\"Capital Federal\");\n \t\n \tDireccionPostal direccionPostal = new DireccionPostal( \"lacarra 180\", buenos_aires, prov_buenos_aires, \"argentina\", new Moneda(\"$\",\"Peso argentino\" ));\n\t\n\t\t\n\t\t entidad1 = new EntidadJuridica(\"chacho bros\", \"grupo chacho\", \"202210\", direccionPostal, new Categoria(\"ONG\"),TipoEmpresa.EMPRESA);\n\n\t\t\n\t\t\n\t}",
"@Override\n public void init() {\n this.shapes = new DatabaseShape();\n }",
"private void prepare() {\n Menu menu = new Menu();\n addObject(menu, 523, 518);\n }",
"@PostConstruct\n public void loadData()\n {\n try \n {\n usu = new RhUsuario();\n \n rol = new RhRol();\n \n uc = new UsuController();\n \n usuList = uc.findAll(usu);\n \n encrypter = new Encryption();\n } \n catch (Exception ex) \n {\n Logger.getLogger(UsuarioManager.class.getName()).log(Level.SEVERE, null, ex);\n }\n }",
"public void init() {\n\t\tTypedQuery<Personne> query = em.createQuery(\"SELECT p FROM Personne p\", Personne.class);\n\t\tList<Personne> clients = query.getResultList();\n\t\tif (clients.size()==0) {\n\t\t\tSqlUtils.executeFile(\"exemple.sql\", em);\n\t\t}\n\t}",
"Obligacion createObligacion();",
"public Persona()\n\t{\n\t\tnombre = \"--\"; //DEFINES POR DEFAULT LAS VARIABLES;\n\t\tapellido = \"--\"; //DEFINES POR DEFAULT LAS VARIABLES;\n\t\tedad = 0; //DEFINES POR DEFAULT LAS VARIABLES;\n\t\talias = \"--\"; //DEFINES POR DEFAULT LAS VARIABLES;\t\t\n\t}",
"public Datos(){\n }",
"public BeanDatosAlumno() {\r\n bo = new BoPrestamoEjemplarImpl();\r\n verEjemplares(\"ABC0001\"); \r\n numerodelibrosPrestados();\r\n }",
"public void init(){\n \n }",
"private void populaObjetivoCat()\n {\n objetivoCatDAO.insert(new ObjetivoCat(\"Hipertrofia\", \"weight\"));\n objetivoCatDAO.insert(new ObjetivoCat(\"Saude\", \"apple\"));\n objetivoCatDAO.insert(new ObjetivoCat(\"Emagrecer\", \"gloves\"));\n }"
] | [
"0.69599575",
"0.6931502",
"0.68728673",
"0.68502825",
"0.68464863",
"0.6743485",
"0.6663418",
"0.6650304",
"0.6586089",
"0.65802157",
"0.65750897",
"0.65539163",
"0.6553552",
"0.64956176",
"0.64636016",
"0.6450821",
"0.6359968",
"0.63454556",
"0.6344946",
"0.63323045",
"0.6308655",
"0.62953097",
"0.6294919",
"0.6240964",
"0.6235523",
"0.6233844",
"0.6215663",
"0.6193959",
"0.61886865",
"0.6177913",
"0.6167055",
"0.61658454",
"0.6135607",
"0.6120211",
"0.61189294",
"0.61132485",
"0.61049235",
"0.6083576",
"0.60834676",
"0.6076072",
"0.60723966",
"0.6065203",
"0.6045674",
"0.60404366",
"0.60354227",
"0.6029615",
"0.60273105",
"0.6020587",
"0.60157776",
"0.6013191",
"0.60127974",
"0.6006949",
"0.6001755",
"0.6001755",
"0.5989911",
"0.5982869",
"0.5980605",
"0.5979292",
"0.59722525",
"0.596771",
"0.5964621",
"0.5959778",
"0.59579825",
"0.5954426",
"0.59528565",
"0.59502035",
"0.594707",
"0.5939805",
"0.59349734",
"0.5928492",
"0.5917495",
"0.59088004",
"0.5904598",
"0.5903938",
"0.58984697",
"0.58978885",
"0.5884428",
"0.5883188",
"0.58767885",
"0.58712834",
"0.5866111",
"0.58621144",
"0.58620036",
"0.5859727",
"0.5857752",
"0.585681",
"0.58542657",
"0.5845641",
"0.58438635",
"0.5843028",
"0.5841388",
"0.5837587",
"0.5837373",
"0.58340853",
"0.5833649",
"0.5833286",
"0.5829978",
"0.5827903",
"0.582601",
"0.5816046",
"0.5815644"
] | 0.0 | -1 |
Solicita al manejador activar el sensor requerido. | public void requestSensor(String sensorType){
switch(sensorType){
case "SENSOR_ACC":
accelerometer = phoneSensorsMan.getDefaultSensor(Sensor.TYPE_ACCELEROMETER);
phoneSensorsMan.registerListener(sel,accelerometer, SensorManager.SENSOR_DELAY_GAME);
break;
case "SENSOR_GYRO":
gyro = phoneSensorsMan.getDefaultSensor(Sensor.TYPE_GYROSCOPE);
phoneSensorsMan.registerListener(sel,gyro, SensorManager.SENSOR_DELAY_GAME);
break;
case "SENSOR_MAGNET":
magnet = phoneSensorsMan.getDefaultSensor(Sensor.TYPE_MAGNETIC_FIELD);
phoneSensorsMan.registerListener(sel,magnet, SensorManager.SENSOR_DELAY_GAME);
break;
case "SENSOR_GPS":
phoneLocationMan.requestLocationUpdates(LocationManager.GPS_PROVIDER,100,1,locListener);
break;
case "SENSOR_ORIENTATION":
orientation = phoneSensorsMan.getDefaultSensor(Sensor.TYPE_ROTATION_VECTOR);
phoneSensorsMan.registerListener(sel,orientation, SensorManager.SENSOR_DELAY_GAME);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void handleSensorActivated() {\n if (securityRepository.getArmingStatus() == ArmingStatus.DISARMED) {\n return; //no problem if the system is disarmed\n }\n switch (securityRepository.getAlarmStatus()) {\n case NO_ALARM -> setAlarmStatus(AlarmStatus.PENDING_ALARM);\n case PENDING_ALARM -> setAlarmStatus(AlarmStatus.ALARM);\n }\n }",
"public void onTriggerChange() {\n findViewById(R.id.temp).post(new Runnable() {\n public void run() {\n ConsumerIrManager mCIR = ScaryUtil.getConsumerIRService(getApplicationContext());\n if (m_Inst.power) {\n TransmissionCode data = ScaryUtil.getIRCode(m_Inst.sequence, m_Inst.temp); // (TransmissionCode)samsung.get(m_Inst.temp);\n ScaryUtil.transmit(getApplicationContext(),data);\n }\n }\n });\n }",
"public void setSensorOn() {\n\n }",
"public void accionProximidad(SensorEvent sensorEvent){\n String valProximidad = String.valueOf(sensorEvent.values[0]);\n Float valor = Float.parseFloat(valProximidad);\n tviewProx.setText(Float.toString(valor));\n\n //VALOR ES LO QUE ME DA EL SENSOR ES EL DE PROXIMIDAD\n if(valor == 1){\n sm.unregisterListener(this);\n if(PuertaLecAppEscRas.getLed().getEstado().equals(\"on\")){\n Toast toast = Toast.makeText(getApplicationContext(), \"TRATANDO DE APAGAR LA LUZ\", Toast.LENGTH_LONG);\n toast.show();\n baseDatosSoaRef.child(\"PuertaEscAppLecRas\").child(\"Led\").child(\"estado\").setValue(\"off\");\n PuertaEscAppLecRas.setLed(\"off\");\n }else {\n Toast toast = Toast.makeText(getApplicationContext(), \"TRATANDO DE ENCENDER LA LUZ\", Toast.LENGTH_LONG);\n toast.show();\n baseDatosSoaRef.child(\"PuertaEscAppLecRas\").child(\"Led\").child(\"estado\").setValue(\"on\");\n PuertaEscAppLecRas.setLed(\"on\");\n }\n TareaLed tareaLed = new TareaLed();\n tareaLed.execute();\n }\n }",
"private void enableSensor() {\n if (DEBUG) Log.d(TAG, \">>> Sensor \" + getEmulatorFriendlyName() + \" is enabled.\");\n mEnabledByEmulator = true;\n mValue = null;\n\n Message msg = Message.obtain();\n msg.what = SENSOR_STATE_CHANGED;\n msg.obj = MonitoredSensor.this;\n notifyUiHandlers(msg);\n }",
"public void changeSensorActivationStatus(Sensor sensor, Boolean active) {\n // The logic hasn't to be checked when alarm is active\n // Modify the logic to meet the request for test 6\n if (securityRepository.getAlarmStatus() != AlarmStatus.ALARM) {\n if (active) {\n handleSensorActivated();\n } else if (sensor.getActive()) {\n handleSensorDeactivated();\n }\n }\n sensor.setActive(active);\n securityRepository.updateSensor(sensor);\n }",
"@Override\n public void onSensorChanged(SensorEvent event) {\n if (event.sensor.getType() == SENS_ACCELEROMETER && event.values.length > 0) {\n float x = event.values[0];\n float y = event.values[1];\n float z = event.values[2];\n\n latestAccel = (float)Math.sqrt(Math.pow(x,2.)+Math.pow(y,2)+Math.pow(z,2));\n //Log.d(\"pow\", String.valueOf(latestAccel));\n\n }\n // send heartrate data and create new intent\n if (event.sensor.getType() == SENS_HEARTRATE && event.values.length > 0 && event.accuracy >0) {\n\n Log.d(\"Sensor\", event.sensor.getType() + \",\" + event.accuracy + \",\" + event.timestamp + \",\" + Arrays.toString(event.values));\n\n int newValue = Math.round(event.values[0]);\n long currentTimeUnix = System.currentTimeMillis() / 1000L;\n long nSeconds = 30L;\n \n if(newValue!=0 && lastTimeSentUnix < (currentTimeUnix-nSeconds)) {\n lastTimeSentUnix = System.currentTimeMillis() / 1000L;\n currentValue = newValue;\n Log.d(TAG, \"Broadcast HR.\");\n Intent intent = new Intent();\n intent.setAction(\"com.example.Broadcast\");\n intent.putExtra(\"HR\", event.values);\n intent.putExtra(\"ACCR\", latestAccel);\n intent.putExtra(\"TIME\", event.timestamp);\n intent.putExtra(\"ACCEL\", latestAccel);\n\n\n Log.d(\"change\", \"send intent\");\n\n sendBroadcast(intent);\n\n client.sendSensorData(event.sensor.getType(), latestAccel, event.timestamp, event.values);\n }\n }\n\n }",
"@Override\n public void teleopPeriodic() {\n Scheduler.getInstance().run();\n // ros_string = workingSerialCom.read();\n // yavuz = workingSerialCom.StringConverter(ros_string, 2);\n // Inverse.Inverse(yavuz);\n\n // JoystickDrive.execute();\n\n\n\n // ros_string = workingSerialCom.read();\n // alt_yurur = workingSerialCom.StringConverter(ros_string, 1);\n // robot_kol = workingSerialCom.StringConverter(ros_string, 2);\n Full.Full(yavuz);\n \n }",
"public void iniciarJuego ( View view )\n {\n if( gameOn)\n {\n sensorManag.unregisterListener(sensorListener);\n Toast.makeText(this, \"Ok reiniciemos el juego.\", Toast.LENGTH_SHORT).show();\n }\n //// SE BUSCA EL SENSOR DE PROXIMIDAD\n\n sensorManag=(SensorManager)getSystemService(SENSOR_SERVICE);\n sensor= sensorManag.getDefaultSensor(Sensor.TYPE_PROXIMITY);\n /// SIN NO HAY SENSOR DE PROXIMIDAD SE LO INFORMA CON UN MENSAJE Y SE SALE\n if(sensor == null)\n {\n Toast.makeText(this, \"No se pudo encontrar un sensor de proximidad, el cual es necesario para jugar.\", Toast.LENGTH_SHORT);\n return;\n }\n //// SE INFORMA QUE ES LO QUE SE DEBE HACER CUANDO HAY CAMBIOS EN EL SENSOR DE PROXIMIDAD\n sensorListener= new SensorEventListener() {\n @Override\n public void onSensorChanged(SensorEvent event) {\n //// SI EL SENSOR PUDO DETECTAR UN OBJETO APROXIMANDOSE\n if( event.values[0] < sensor.getMaximumRange() )\n {\n //// SI LA PANTALLA NO FUE TAPADA ANTERIORMENTE -> GUARDO EL MOMENTO DE INICIO DEL JUEGO\n if( !pantallaEstabaTapada )\n {\n tiempoDeInicio= SystemClock.uptimeMillis();\n pantallaEstabaTapada=true;\n getWindow().getDecorView().setBackgroundColor(Color.RED);\n }\n }\n else\n {\n //// SI LA PANTALLA ESTABA TAPADA Y AHORA NO LO ESTA --> CALCULO LOS SEGUNDOS TRANSCURRIDOS Y DESTRUYO EL LISTENER DEL SENSOR\n if( pantallaEstabaTapada )\n {\n segundosTranscurridos= pasarMilisegundoASegundo(SystemClock.uptimeMillis() - tiempoDeInicio);\n pantallaEstabaTapada=false;\n getWindow().getDecorView().setBackgroundColor(Color.WHITE);\n\n ServicePOST comunicacionApiRest = new ServicePOST(getApplicationContext());\n comunicacionApiRest.registrarEvento(String.valueOf(event.values[0]), \"SENSOR DE PROXIMIDAD\");\n\n sensorManag.unregisterListener(sensorListener);\n\n }\n }\n guardarInfoEnSharedPreference(event.values[0]);\n }\n /// NO ES NECESARIO TOCARLO PERO LA IMPLEMENTACION ME PIDE QUE POR LO MENOS LO DECLARE\n @Override\n public void onAccuracyChanged(Sensor sensor, int accuracy) {\n }\n };\n /// REGISTRO EL LISTENER PARA QUE EMPIESE A ESCUCHAR\n sensorManag.registerListener(sensorListener, sensor, MILISEGUNDOS_EN_SEGUNDO/6);\n //// FLAG PARA SABER QUE SE ESTA PREPARADO PARA JUGAR ///////\n gameOn=true;\n }",
"@Override\r\n\tpublic void arrancar() {\n\t\tSystem.out.println(\"Arrancar motor electrico adaptador\");\r\n\t\tthis.motorElectrico.conectar();\r\n\t\tthis.motorElectrico.activar();\r\n\t}",
"public void sensorSystem() {\n\t}",
"public void message1Pressed() {\n // display\n TextLCD.print(MESSAGE1);\n // current sensor state?\n boolean sensorState = fSensorState[0];\n // activate/passivate sensor\n if(sensorState)\n Sensor.S1.passivate();\n else\n Sensor.S1.activate();\n // change sensor state\n fSensorState[0] = !sensorState;\n }",
"private void activeSensor(Sensor sensor) {\n selectedSensor = sensor;\n// selectedSensor.debug(true);\n// if (start) {\n// view = (DrawingView) findViewById(R.id.surface);\n// bitmap = Bitmap.createBitmap(view.getWidth(), view.getHeight(), Bitmap.Config.RGB_565);\n// canvas = new Canvas(bitmap);\n// view.setDrawer(new DrawingView.Drawer() {\n// @Override\n// public void draw(Canvas canvas) {\n// canvas.drawBitmap(bitmap, 0, 0, null);\n// }\n// });\n// }\n }",
"public void activate(){\n callback.action();\n }",
"public void activate()\n\t{\n\t\tlineNow = 0f;\n\t\tamp = begAmp;\n\t\tisActivated = true;\n\t}",
"public void trigger() {\n\t\t\n//\t\t #ifdef DEBUG\n\t\t // The sensor should not have been scheduled if it has a NULL\n\t\t // callback function. Be safe and test here.\n\t\t if (func == null) {\n\t\t SoDebugError.post(\"SoSensor::trigger\",\n\t\t \"Cannot trigger a sensor with NULL callback\");\n\t\t return;\n\t\t }\n//\t\t #endif /* DEBUG */\n\t\t \n\t\t // Call the sensor function\n\t\t func.run(funcData, this);\n\t\t \n\t\t }",
"@Override\n public void onSensorChanged(SensorEvent event) {\n if( event.values[0] < sensor.getMaximumRange() )\n {\n //// SI LA PANTALLA NO FUE TAPADA ANTERIORMENTE -> GUARDO EL MOMENTO DE INICIO DEL JUEGO\n if( !pantallaEstabaTapada )\n {\n tiempoDeInicio= SystemClock.uptimeMillis();\n pantallaEstabaTapada=true;\n getWindow().getDecorView().setBackgroundColor(Color.RED);\n }\n }\n else\n {\n //// SI LA PANTALLA ESTABA TAPADA Y AHORA NO LO ESTA --> CALCULO LOS SEGUNDOS TRANSCURRIDOS Y DESTRUYO EL LISTENER DEL SENSOR\n if( pantallaEstabaTapada )\n {\n segundosTranscurridos= pasarMilisegundoASegundo(SystemClock.uptimeMillis() - tiempoDeInicio);\n pantallaEstabaTapada=false;\n getWindow().getDecorView().setBackgroundColor(Color.WHITE);\n\n ServicePOST comunicacionApiRest = new ServicePOST(getApplicationContext());\n comunicacionApiRest.registrarEvento(String.valueOf(event.values[0]), \"SENSOR DE PROXIMIDAD\");\n\n sensorManag.unregisterListener(sensorListener);\n\n }\n }\n guardarInfoEnSharedPreference(event.values[0]);\n }",
"@Override\n public void onSensorChanged(SensorEvent event) {\n if (event.sensor.getType() == Sensor.TYPE_ACCELEROMETER) {\n // Send data to phone\n if (count == 5) {\n count = 0;\n// Log.d(\"hudwear\", \"send accel data to mobile...\"\n// + \"\\nx-axis: \" + event.values[0]\n// + \"\\ny-axis: \" + event.values[1]\n// + \"\\nz-axis: \" + event.values[2]\n// );\n// Log.d(\"hudwear\", \"starting new task.\");\n\n if (connected)\n Log.d(\"atest\", \"values: \" + event.values[0] + \", \" + event.values[1] + \", \" + event.values[2]);\n// new DataTask().execute(new Float[]{event.values[0], event.values[1], event.values[2]});\n }\n else count++;\n }\n }",
"public void enableReading(){\n active = true;\n registerBroadcastReceiver();\n }",
"private void updateLightSensorValues()\n {\n sendMessage((byte)Constants.LIGHTSENSVAL,(byte)Constants.REQ);\n try {\n Thread.sleep(4000);\n } catch(InterruptedException ex) {\n Thread.currentThread().interrupt();\n }\n sendMessage((byte)Constants.POTVAL, (byte)Constants.REQ);\n if(progPotToggleButton.isChecked())\n {\n int x =0;\n try {\n x = Integer.parseInt(progValueEditText.getText().toString());\n if(x>=0 && x<256)\n sendMessage((byte)Constants.PROGVAL,(byte)x);\n try {\n Thread.sleep(4000);\n } catch(InterruptedException ex) {\n Thread.currentThread().interrupt();\n }\n sendMessage((byte)Constants.USEPOT,(byte)Constants.NO);\n } catch (NumberFormatException e) {\n messageView.append(\"int för helvete\");\n }\n }else\n sendMessage((byte)Constants.USEPOT,(byte)Constants.YES);\n\n }",
"public void active(View v){\n Intent intent = new Intent(DevicePolicyManager.ACTION_ADD_DEVICE_ADMIN);\n\n ComponentName mDeviceAdminSample = new ComponentName(this,MyDeviceAdminReceiver.class);\n intent.putExtra(DevicePolicyManager.EXTRA_DEVICE_ADMIN,mDeviceAdminSample );\n intent.putExtra(DevicePolicyManager.EXTRA_ADD_EXPLANATION,\n \"hello,kitty\");\n startActivityForResult(intent, 100);\n\n }",
"private void doActivation() {\n OnFieldActivated activateEvent = new OnFieldActivated(this::finishReset);\n activateEvent.beginTask();\n DefenceField.getShrineEntity().send(activateEvent);\n activateEvent.finishTask();\n }",
"private void dormirSensor() {\n\ttry {\n\t Thread.sleep(sens.getFrec_lect()\n\t\t * IrrisoftConstantes.DELAY_FREC_LECT);\n\t} catch (InterruptedException e) {\n\t if (logger.isErrorEnabled()) {\n\t\tlogger.error(\"Hilo interrumpido: \" + e.getMessage());\n\t }\n\t}\n }",
"protected void onResume(){\n super.onResume();\n //sensorManager.registerListener(this, barometro, SensorManager.SENSOR_DELAY_FASTEST);\n }",
"public void onClick(View v) {\n\t\t\t\tsensorEnable = !sensorEnable;\n\t\t\t\tif( CarDataService.obdSensor == null ){\n\t\t\t\t\tCarDataService.obdSensor = new OBDSensor(baseAct);\n\t\t\t\t}\n\t\t\t\tif (sensorEnable) {\n//\t\t\t\t\tif( mBtStat == 3 ){\n\t\t\t\t\tLogRecord.SaveLogInfo2File(Base.OperateInfo, TAG+\"sensor enable\");\n\t\t\t\t\tsensorSwt.setImageResource(R.drawable.icon_radio_enable);\n//\t\t\t\t\tCarDataService.obdSensor.initData();\n\t\t\t\t\tCarDataService.obdSensor.registSensor();\t\t\t\t\t\n\t\t\t\t\tBase.OBDApp.sensorState = true;//start write sensor data\n//\t\t\t\t\t}else{\n//\t\t\t\t\t\tToast.makeText(baseAct, \"OBD未连接,请先连接OBD\", 1).show();\n//\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tLogRecord.SaveLogInfo2File(Base.OperateInfo, TAG+\"sensor disable\");\n\t\t\t\t\tsensorSwt.setImageResource(R.drawable.icon_radio_disable);\t\t\t\t\t\n\t\t\t\t\tCarDataService.obdSensor.unRegistSensor();\n\t\t\t\t\tBase.OBDApp.sensorState = false;//stop write sensor data and tell service upload data if wifi enable\n\t\t\t\t}\t\t\t\t\n\t\t\t}",
"protected void onResume() {\n sensorManager.registerListener(this, acelerometro, SensorManager.SENSOR_DELAY_NORMAL);\n sensorManager.registerListener(this, magnetometro, SensorManager.SENSOR_DELAY_NORMAL);\n }",
"public void onSensorChanged() {\n\t\tsensorChanged();\n\t}",
"private void enableBotonAceptar()\r\n\t{\r\n\t\t\r\n\t}",
"public void activate() throws MMDeviceException;",
"public void powerOn() { //power_on\n String json = new Gson().toJson(new TelevisionModel(TelevisionModel.Action.ON));\n String a = sendMessage(json);\n TelevisionModel teleM = new Gson().fromJson(a, TelevisionModel.class);\n System.out.println(\"Client Received \" + json);\n\n if (teleM.getAction() == TelevisionModel.Action.ON) {\n isTurningOn = teleM.getValue();\n ui.updateArea(teleM.getMessage());\n }\n }",
"public void activateSensorsActionListener(ActionListener listener) {\n\t\tactivateSensorsButton.addActionListener(listener);\n\n\t}",
"public void activate(){\r\n\t\tactive=true;\r\n\t}",
"public void startSensors() {\n // Register listeners for each sensor\n sensorManager.registerListener(sensorEventListener, accelerometer, SensorManager.SENSOR_DELAY_GAME);\n }",
"@JavascriptInterface\n public void VIA() {\n sensorManager.registerListener(c, accelerometer, SensorManager.SENSOR_DELAY_NORMAL);\n sensorManager.registerListener(c, giroscopio, SensorManager.SENSOR_DELAY_NORMAL);\n sensorManager.registerListener(c, gravità, SensorManager.SENSOR_DELAY_NORMAL);\n misC=0; // sovrascrivo le vecchie.\n }",
"@Override\n public void onSensorChanged(SensorEvent sensorEvent) {\n if (sensorEvent.sensor.getType() == Sensor.TYPE_ACCELEROMETER && s.equals(\"Accelerometre\")) {\n float Ax = sensorEvent.values[0];\n float Ay = sensorEvent.values[1];\n float Az = sensorEvent.values[2];\n\n acce = \" TimeAcc = \" + sensorEvent.timestamp + \"\\n Ax = \" + Ax + \" \" + \"\\n Ay = \" + Ay + \" \" + \"\\n Az = \" + Az + \"\\n\";\n\n // Do something with this sensor value .\n sensorTxt.setText(acce);\n Log.d(TAG, \" TimeAcc = \" + sensorEvent.timestamp + \" Ax = \" + Ax + \" \" + \" Ay = \" + Ay + \" \" + \" Az = \" + Az);\n }\n\n //LUMIERE\n if (sensorEvent.sensor.getType() == Sensor.TYPE_LIGHT && s.equals(\"Lumiere\")) {\n // La valeur de la lumière\n float lv = sensorEvent.values[0];\n\n light = \" TimeAcc = \" + sensorEvent.timestamp + \"\\n Light value = \" + lv + \"\\n\";\n //On affiche la valeur\n sensorTxt.setText(light);\n }\n\n //PROXIMITE\n if (sensorEvent.sensor.getType() == Sensor.TYPE_PROXIMITY && s.equals(\"Proximite\")) {\n // La valeur de proximité\n float p = sensorEvent.values[0];\n\n proxi = \" TimeAcc = \" + sensorEvent.timestamp + \"\\n Proximite value = \" + p + \"\\n\";\n //On affiche la valeur\n sensorTxt.setText(proxi);\n }\n\n //GYROSCOPE\n if (sensorEvent.sensor.getType() == Sensor.TYPE_GYROSCOPE && s.equals(\"Gyroscope\")) {\n // Les valeurs du gyroscope\n float xGyroscope = sensorEvent.values[0];\n float yGyroscope = sensorEvent.values[1];\n float zGyroscope = sensorEvent.values[2];\n\n gyro = \" TimeAcc = \" + sensorEvent.timestamp + \"\\n Valeur du gyroscope \\n Valeur en x = \" + xGyroscope + \" \" + \"\\n Valeur en y = \" + yGyroscope + \" \" + \"\\n Valeur en z = \" + zGyroscope + \"\\n\";\n //On affiche la valeur\n sensorTxt.setText(gyro);\n }\n\n }",
"RegisterSensor() {\n }",
"public void start() {\n if (mSensorManager.getDefaultSensor(Sensor.TYPE_ROTATION_VECTOR)==null){ // check if rotation sensor present\n if (mSensorManager.getDefaultSensor(Sensor.TYPE_MAGNETIC_FIELD)==null\n || mSensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER)==null){ // check if acc & mag sensors are present\n noSensorAlert(); // alert if no sensors are present\n }\n else { // use acc & mag sensors\n mAccelerometer = mSensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER);\n mMagnetometer = mSensorManager.getDefaultSensor(Sensor.TYPE_MAGNETIC_FIELD);\n haveSensor = mSensorManager.registerListener(this,mAccelerometer,SensorManager.SENSOR_DELAY_UI);\n haveSensor2 = mSensorManager.registerListener(this,mMagnetometer,SensorManager.SENSOR_DELAY_UI);\n }\n }\n else { // use rotation sensor\n mRotationV = mSensorManager.getDefaultSensor(Sensor.TYPE_ROTATION_VECTOR);\n haveSensor = mSensorManager.registerListener(this,mRotationV,SensorManager.SENSOR_DELAY_UI);\n }\n }",
"public void activate() {\n\t\tactivated = true;\n\t}",
"@Override\n public void onSensorChanged(SensorEvent event) {\n\n long currentTimeUnix = System.currentTimeMillis() / 1000L;\n long nSeconds = 30L;\n\n // send heartrate data and create new intent\n if (event.sensor.getType() == SENS_HEARTRATE && event.values.length > 0 && event.accuracy > 0) {\n int newValue = Math.round(event.values[0]);\n\n if(newValue!=0 && lastTimeSentUnixHR < (currentTimeUnix-nSeconds)) {\n lastTimeSentUnixHR = System.currentTimeMillis() / 1000L;\n currentValue = newValue;\n\n Log.d(TAG, \"Broadcast HR.\");\n Intent intent = new Intent();\n intent.setAction(\"com.example.Broadcast\");\n intent.putExtra(\"HR\", event.values);\n intent.putExtra(\"ACCR\", event.accuracy);\n intent.putExtra(\"TIME\", event.timestamp);\n sendBroadcast(intent);\n\n client.sendSensorData(event.sensor.getType(), event.accuracy, event.timestamp, event.values);\n\n }\n }\n // also send motion/humidity/step data to know when NOT to interpret hr data\n\n if (event.sensor.getType() == SENS_STEP_COUNTER && event.values[0]-currentStepCount!=0) {\n\n if(lastTimeSentUnixSC < (currentTimeUnix-nSeconds)){\n lastTimeSentUnixSC = System.currentTimeMillis() / 1000L;\n currentStepCount = event.values[0];\n client.sendSensorData(event.sensor.getType(), event.accuracy, event.timestamp, event.values);\n }\n\n }\n\n if (event.sensor.getType() == SENS_ACCELEROMETER) {\n\n if(lastTimeSentUnixACC < (currentTimeUnix-nSeconds)){\n lastTimeSentUnixACC = System.currentTimeMillis() / 1000L;\n\n client.sendSensorData(event.sensor.getType(), event.accuracy, event.timestamp, event.values);\n }\n }\n\n }",
"@Override\r\n\tpublic void apagar() {\n\t\tSystem.out.println(\"Apagar motor electrico adaptador\");\r\n\t\tthis.motorElectrico.detener();\r\n\t\tthis.motorElectrico.desconectar();\r\n\t}",
"public void start() {\n sensorManager.registerListener(this, gyroscope, SENSOR_DELAY);\n sensorManager.registerListener(this, rotationVector, SENSOR_DELAY);\n //sender = new UDPSender();\n }",
"public void onClick(View v) {\n mConnectedThread.write(\"1\"); // Send \"1\" via Bluetooth\n Toast.makeText(getBaseContext(), \"Turn on LED\", Toast.LENGTH_SHORT).show();\n }",
"public void activateShield() {\n shield.activate();\n }",
"public void activate(){\r\n\r\n\t}",
"@Override\n public void enable() {\n if (!sensorEnabled) {\n //Log.d(TAG, \"start app tracking\");\n sensorEnabled = true;\n new AppObserver().executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);\n }\n }",
"@Override\n\tpublic void execute() {\n\t\tlight.on();\n\t}",
"@Override\n protected void onResume() {\n super.onResume();\n sensorManager.registerListener(this, senorAccelerometer, sensorManager.SENSOR_DELAY_NORMAL);\n }",
"public void activar(){\n\n }",
"@Override\n public void onSensorChanged(SensorEvent sensorEvent) {\n if(sensorEvent.sensor.getType()== Sensor.TYPE_ACCELEROMETER){\n if(rBtnPuerta.isChecked()){\n accionShake(sensorEvent);\n }\n }else{\n if(sensorEvent.sensor.getType() == Sensor.TYPE_PROXIMITY){\n if(rBtnLed.isChecked()){\n accionProximidad(sensorEvent);\n }\n }else{\n if(sensorEvent.sensor.getType() == Sensor.TYPE_LIGHT){\n if(rBtnLuminosidad.isChecked()){\n accionLuminosidad(sensorEvent);\n }\n }\n }\n }\n }",
"public void enable(){\r\n\t\tthis.activ = true;\r\n\t}",
"public void activate()\n {\n }",
"public AccelerometerButtonsActivity()\r\n\t{\r\n\t\tLog.d(TAG,\"AccelerometerActivity()\");\r\n\t\tbbHWSensorInitialized=false;\r\n\t\tsetCOMStatus (null,false);\r\n\t\t\t\t\r\n\t\tglobal = new Globals();\r\n\t\tMsgQueue = new android.os.Handler (this);\r\n\t\t\r\n\t\tlast_sent_ms=0;\r\n\t\tuitoken=0;\r\n\t\t_bbStartSend=false;\r\n\t\tsm=null;\r\n\t\tacc_val= new accVal();\r\n\t\tlast_sent_ms=0;\r\n\t\tnAccVal=0;\r\n\t\tformatter = new DecimalFormat(\"#000.00\");\r\n\t\t\r\n\t\tformatter3 = new DecimalFormat(\"#00\");\r\n\t\tts_connection=0;\r\n\t\tlast_nAccVal=0;\r\n\t}",
"@Override\n public void execute() {\n light.on();\n }",
"public void onSensorChanged(SensorEvent event) {\n synchronized (this) {\n\n //((TextView) findViewById(R.id.texto_prueba2)).setText(Boolean.toString(status));\n\n getInicio(event);\n\n if(status){\n\n if(!(limitarEje(event) && limitarTiempo(event.timestamp, m.getCurrentTime()))){\n ((TextView) findViewById(R.id.texto_prueba)).setText(\"Acelerómetro X, Y , Z: \" + event.values[0] +\" , \"+ event.values[1] +\" , \"+ event.values[2]);\n return;\n }\n\n action=m.isMovement(event.values[0], event.values[1], event.values[2], event.timestamp);\n if(action>=0){\n if(action==10){\n Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);\n startActivity(intent);\n status=false;\n }\n\n if(action==12){\n //context.getPackageManager().hasSystemFeature(PackageManager.FEATURE_CAMERA_FLASH);\n if(cam==null){\n cam = Camera.open();\n p = cam.getParameters();\n p.setFlashMode(android.hardware.Camera.Parameters.FLASH_MODE_TORCH);\n cam.setParameters(p);\n cam.startPreview();\n }\n else{\n p.setFlashMode(android.hardware.Camera.Parameters.FLASH_MODE_OFF);\n cam.setParameters(p);\n cam.release();\n cam = null;\n\n }\n }\n if(action==13){\n /* if(mPlayer==null){\n\n recorder.setAudioSource(MediaRecorder.AudioSource.MIC);\n recorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP);\n recorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB);\n recorder.setOutputFile(path);\n recorder.prepare();\n recorder.start();\n }\n else{\n recorder.stop();\n recorder.reset();\n recorder.release();\n\n recorder = null;\n }\n*/\n }\n }\n\n ((TextView) findViewById(R.id.texto_prueba2)).setText(Integer.toString(action));\n\n ((TextView) findViewById(R.id.texto_prueba1)).setText(Long.toString((event.timestamp-m.getCurrentTime())/500000000));\n }\n //((TextView) findViewById(R.id.texto_prueba)).setText(\"Acelerómetro X, Y , Z: \" + curX +\" , \"+ curY +\" , \"+ curZ);\n }\n }",
"@Override\n public void trigger() {\n output.addNewEvent(\"Suspender Assinante \" + subscriber.getId() + \" da Central \" + central.getId());\n this.sucess = this.network.suspendSubscriberFromCentral(this.subscriber.getId(), this.central.getId());\n if (sucess) {\n output.addNewSignal(\"Assinante \" + this.subscriber.getId() + \" suspendida da Central \" + central.getId());\n } else {\n output.addNewSignal(\"Assinante \" + this.subscriber.getId() + \" não está conectado ou ativo à Central \" + central.getId());\n }\n }",
"public void onResume() {\n sensorManager.registerListener(this, accelerometer, SensorManager.SENSOR_DELAY_NORMAL);\n }",
"public void connectSensor() {\n mReleaseHandle = mSensorHandler.getReleaseHandle(mSensorResultReceiver, mSensorStateChangeReceiver);\n }",
"public void triggerAlarm() throws IOException {\n\t\tSystem.out.print(\"feu au coord :\");\n\t\tSystem.out.print(this.alerte + \"\\n\");\n\t\t\n\t\tthis.sendInformation();\n\t\t//this.sendMeasures();\n\t}",
"public void resume() {\n mSensorMgr = (SensorManager) mContext.getSystemService(Context.SENSOR_SERVICE);\n if (mSensorMgr == null) {\n throw new UnsupportedOperationException(\"Sensors not supported\");\n }\n mAccelerometer = mSensorMgr.getDefaultSensor(Sensor.TYPE_ACCELEROMETER);\n if (!mSensorMgr.registerListener(this, mAccelerometer, SensorManager.SENSOR_DELAY_UI)) { // if not supported\n mSensorMgr.unregisterListener(this);\n throw new UnsupportedOperationException(\"Accelerometer not supported\");\n }\n }",
"private void initSensor(){\n sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE);\n\n registerListeners();\n }",
"public void run() {\n\t\ttry {\n\n\t\t\tString input = in.readLine();\n\t\t\tSystem.out.println(input);\n\t\t\t\n\t\t\tif (input.equalsIgnoreCase(\"a\")) {\n\t\t\t\t//input = in.readLine();\n\t\t\t\tsensor.changeState(input);\n\t\t\t\t//out.println(sensor.getOutputValue());\n\t\t\t\t// out.println(\"led settato correttamente\");\n\t\t\t\t//out.flush();\n\t\t\t} else if (input.equals(\"Presenze\")) {\n\t\t\t\t//input = in.readLine();\n\t\t\t\tString attendences = sensor.returnAttendences();\n\t\t\t\tSystem.out.println(attendences);\n\t\t\t\tout.println(attendences);\n\t\t\t\tout.flush();\n\t\t\t}\n\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void activate();",
"public void startSensors() {\r\n\t\tsensorManager.registerListener(this, accelerometer,\r\n\t\t\t\tSensorManager.SENSOR_DELAY_UI);\r\n\t\tsensorManager.registerListener(this, magneticField,\r\n\t\t\t\tSensorManager.SENSOR_DELAY_UI);\r\n\r\n\t\tLog.d(TAG, \"Called startSensors\");\r\n\t}",
"@Override\n public void activate(boolean status) {\n godPower.activate(status);\n }",
"@Override\n public void activate() {\n \n }",
"@Override\n\t\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t\tTXZPowerManager\n\t\t\t\t\t\t\t\t\t\t.getInstance()\n\t\t\t\t\t\t\t\t\t\t.notifyPowerAction(\n\t\t\t\t\t\t\t\t\t\t\t\tPowerAction.POWER_ACTION_WAKEUP);\n\t\t\t\t\t\t\t\tLog.d(\"RituNavi\", \"ͬ������������\");\n\t\t\t\t\t\t\t\tToast.makeText(MainTestActivity.this,\n\t\t\t\t\t\t\t\t\t\t\"ͬ������������\", Toast.LENGTH_SHORT).show();\n\t\t\t\t\t\t\t\t// showProgress();\n\t\t\t\t\t\t\t}",
"public void setOn(){\n state = true;\n //System.out.println(\"Se detecto un requerimiento!\");\n\n }",
"@Override\n protected void execute() {\n Robot.jack.setJackMotor(Robot.oi.gamePad.getLeftJoystickY()/3);\n Robot.jack.setJackDriveMotor(Robot.oi.gamePad.getRightJoystickY()/3);\n \n SmartDashboard.putString(\"Currently Running Diagnostic\", \"Jack\");\n }",
"public void handleSensorEvents(){\n\t}",
"@Override\n\tpublic void actionPerformed(ActionEvent arg0) {\n\t\tif (settingTonic) {\n\t\t\tif (setTonicLed.isHigh())\n\t\t\t\tsetTonicLed.low();\n\t\t\telse\n\t\t\t\tsetTonicLed.high();\n\t\t}\n\t\tif (settingHarmonicInterval) {\n\t\t\tif (setHarmIntLed.isHigh())\n\t\t\t\tsetHarmIntLed.low();\n\t\t\telse\n\t\t\t\tsetTonicLed.high();\n\t\t}\n\t\tif (settingScaleType) {\n\t\t\tif (setScaleLed.isHigh())\n\t\t\t\tsetScaleLed.low();\n\t\t\telse\n\t\t\t\tsetScaleLed.high();\n\t\t}\n\n\t}",
"@Override\n public void robotPeriodic() {\n\n enabledCompr = pressBoy.enabled();\n //pressureSwitch = pressBoy.getPressureSwitchValue();\n currentCompr = pressBoy.getCompressorCurrent();\n //SmartDashboard.putBoolean(\"Pneumatics Loop Enable\", closedLoopCont);\n SmartDashboard.putBoolean(\"Compressor Status\", enabledCompr);\n //SmartDashboard.putBoolean(\"Pressure Switch\", pressureSwitch);\n SmartDashboard.putNumber(\"Compressor Current\", currentCompr);\n }",
"@Override\n public void teleopPeriodic() {\n CommandScheduler.getInstance().run();\n OI.getInstance().getPilot().run();\n SmartDashboard.putNumber(\"gyro\", getRobotContainer().getTecbotSensors().getYaw());\n SmartDashboard.putBoolean(\"isSpeed\", getRobotContainer().getDriveTrain().getTransmissionMode() == DriveTrain.TransmissionMode.speed);\n SmartDashboard.putString(\"DT_MODE\", getRobotContainer().getDriveTrain().getCurrentDrivingMode().toString());\n SmartDashboard.putNumber(\"x_count\", getRobotContainer().getClimber().getxWhenPressedCount());\n\n }",
"public void activate() {\n\t\t// set cooldown counter\n\t}",
"public void setSensorOff() {\n\n }",
"private void handleSensorDeactivated() {\n if (securityRepository.getAlarmStatus() == AlarmStatus.PENDING_ALARM) {\n setAlarmStatus(AlarmStatus.NO_ALARM);\n }\n// switch (securityRepository.getAlarmStatus()) {\n// case PENDING_ALARM -> setAlarmStatus(AlarmStatus.NO_ALARM);\n// case ALARM -> setAlarmStatus(AlarmStatus.PENDING_ALARM);\n// }\n }",
"@Override\n\tpublic void teleopPeriodic() {\n\n\t\tif (Joy.getRawButtonPressed(1)) {\n\t\t\ttriggerValue = !triggerValue;\n\n\t\t\tif (triggerValue) {\n\t\t\t\tairCompressor.start();\n\t\t\t\tSystem.out.println(\"Compressor ON\");\n\n\t\t\t} else if (!triggerValue) {\n\t\t\t\tairCompressor.stop();\n\t\t\t\tSystem.out.println(\"Compressor OFF\");\n\t\t\t}\n\t\t}\n\n\t\tif (Joy.getRawButtonPressed(2)) {\n\t\t\ttriggerValue = !triggerValue;\n\n\t\t\tif (triggerValue) {\n\t\t\t\ts1.set(DoubleSolenoid.Value.kForward);\n\t\t\t\tTimer.delay(1);\n\t\t\t\ts2.set(DoubleSolenoid.Value.kForward);\n\t\t\t\tSystem.out.println(\"Solenoid Forward\");\n\n\t\t\t} else if (!triggerValue) {\n\t\t\t\ts1.set(DoubleSolenoid.Value.kReverse);\n\t\t\t\tTimer.delay(1);\n\t\t\t\ts2.set(DoubleSolenoid.Value.kReverse);\n\t\t\t\tSystem.out.println(\"Solenoid Reversed\");\n\n\t\t\t}\n\t\t}\n\t}",
"public void Activate() {\n state.Activate();\n }",
"ExternalSensor createExternalSensor();",
"public void onSensorChanged(SensorEvent event) {\n try {\n Thread.sleep(16);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n //called when accelerometer senses directional change\n sensorX = event.values[0];\n sensorY = event.values[1];\n }",
"public void changeStatus()\n {\n if(this.isActivate == false)\n {\n this.isActivate = true;\n switchSound.play();\n //this.dungeon.updateSwitches(true); \n }\n else{\n this.isActivate = false;\n switchSound.play(1.75, 0, 1.5, 0, 1);\n //this.dungeon.updateSwitches(false); \n }\n notifyObservers();\n\n }",
"public void alertMonitor(Sensor sensor) throws RemoteException;",
"private void timerEngine(){\n SensorController me = this;\n //generate new value or send existing to server\n if(isValueGeneratorRunning()){\n logger.trace(\"Generating new sensor value\");\n //create new values\n try{\n getModel().getValues().stream()\n .filter(Value::isGenerateValue) //if new value should be generated\n .forEach(v -> {\n Object next = v.nextValue();\n if (next != null) {\n Platform.runLater(() -> v.setValue(next));\n }\n }); //do it\n }catch (IllegalArgumentException e){\n adapterController.sendError(toString() + \" -> cannot generate new value!\",e,false);\n }\n logger.trace(\"Building sensor message\");\n //create XML message with new values\n XMLmessage = adapterController.getAdapter().getProtocol()\n .buildSensorMessage(adapterController.getAdapter().getProtocol().buildAdapterMessage(adapterController.getAdapter()), getModel());\n //change engine to send message mod\n setRunValueGenerator(false);\n }else if(getModel().getStatus()){\n //if sensor's message doesn't exist, error is showed\n if(XMLmessage == null){\n adapterController.sendError(toString() + \" doesn't have XML message to send\",null,false);\n return;\n }\n //if we have means to send message and adapter is registered, send message to adapter\n if(adapterController.getServerReceiver() != null || adapterController.getAdapter().getRegistered()){\n //full message contains information about adapter\n if(isFullMessage()){\n //used in \"Performance simulation\"\n adapterController.sendMessage(me.toString() + \" --> data sent\",XMLmessage,me, OutMessage.Type.SENSOR_MESSAGE);\n }else{\n //short message contains information only about sensor\n //used in \"Detailed simulation\"\n adapterController.sendMessage(\"Sensor \" + me.toString() + \" trying to send message.\");\n adapterController.sendMessage(\"Sensor \" + me.toString() + \" --> data sent\",XMLmessage,me, OutMessage.Type.SENSOR_MESSAGE);\n }\n //change engine to generate value mod\n setRunValueGenerator(true);\n }\n }\n }",
"@Override\n public void onConnected(Bundle bundle) {\n Intent gARIntent = new Intent(getApplicationContext(), Algorithm.class);\n PendingIntent gARPending = PendingIntent.getService(getApplicationContext(), 0, gARIntent, PendingIntent.FLAG_UPDATE_CURRENT);\n\n //do AR per 6 secs\n ActivityRecognition.ActivityRecognitionApi.requestActivityUpdates(gARClient, 6000, gARPending);\n\n }",
"public void raise(){\r\n elevatorTalon1.set(basePWM);\r\n elevatorTalon2.set(basePWM * pwmModifier);\r\n }",
"public void onSensorChanged(SensorEvent event) {\n\t\tif(event.sensor.getType() == Sensor.TYPE_PROXIMITY){\n\t\tproxview.setText(\"\\n\\n\"+\"PROXIMITY\"+\"\\n\"+String.valueOf(event.values[0]));\n\t\t\n\t\t\n\t\t}\n\t\tif(event.sensor.getType() == Sensor.TYPE_ACCELEROMETER){\n\t\t\t\n\t\taccview.setText(\"ACCELEROMETER\"+\"\\n\"+\"X: \"+event.values[0]+\"\\nY: \"+event.values[1]+\"\\nZ: \"+event.values[2]);\n\t\t\n\t\tdouble p = event.values[0];\n\t\tif(p<0.0)\n\t\t{mp.pause();}\n\t\telse{\n\t\t\tif(mp.isPlaying())\n\t\t\t{\n\t\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{mp.start();}\n\t\t}\n\t\t\n\t}\n\t\tif(event.sensor.getType() == Sensor.TYPE_LIGHT){\n\t\t\t\n\t\t\tliview.setText(\"LIGHT\"+\"\\n\"+String.valueOf(event.values[0]));\n\t\t\t\n\t\t}\n}",
"public void turn_on () {\n this.on = true;\n }",
"public void act() \r\n {\r\n addDrone();\r\n if(droneTimer>0)\r\n {\r\n droneTimer--;\r\n }\r\n }",
"public void on() {\n\t\tSystem.out.println(\"Tuner is on\");\n\n\t}",
"@Override\n public void trigger() {\n output.addNewEvent(\"Assinante \" + subscriberReconnect.getId() + \" deseja reconectar sua última ligação\");\n if (this.subscriberReconnect.isFree()) {\n takePhone();\n reestablishConnection();\n }\n }",
"public void sensorReader() {\n try {\n Log.i(TAG, \"wants to read from Arduino\");\n this.inputStream = socket.getInputStream();\n this.inputStreamReader = new InputStreamReader(inputStream);\n Log.i(TAG, \"inputstream ready\");\n this.bufferedReader = new BufferedReader(inputStreamReader);\n Log.i(TAG, \"buffered reader ready\");\n } catch (IOException e) {\n e.printStackTrace();\n }\n }",
"@Override\n\tpublic void teleopPeriodic() {\n\t\tScheduler.getInstance().run();\n\t\tisAutonomous = false;\n\t\tisTeleoperated = true;\n\t\tisEnabled = true;\n\t\tupdateLedState();\n\t\t//SmartDashboard.putNumber(\"Gyro\", Robot.drivebase.driveGyro.getAngle());\n\t\tSmartDashboard.putNumber(\"Climber Current Motor 1\", Robot.climber.climberTalon.getOutputCurrent());\n\t\tSmartDashboard.putNumber(\"Climber Current motor 2\", Robot.climber.climberTalon2.getOutputCurrent());\n\t\t//visionNetworkTable.getGearData();\n\t//\tvisionNetworkTable.showGearData();\n\t\tSmartDashboard.putNumber(\"GM ACTUAL POSITION\", Robot.gearManipulator.gearManipulatorPivot.getPosition());\n\n\t\tif(Robot.debugging){\t\t\t\n\t\t\tSmartDashboard.putNumber(\"Shooter1RPM Setpoint\", shooter.shooter1.getSetpoint());\n\t \tSmartDashboard.putNumber(\"Intake Pivot Encoder Position\", Robot.gearManipulator.gearManipulatorPivot.getPosition());\n\t\n\t\t\tSmartDashboard.putNumber(\"Gear Manipulator Setpoint\", gearManipulator.gearManipulatorPivot.getSetpoint());\n\t\t}\n\t\t//\tvisionNetworkTable.getGearData();\n\t\t//visionNetworkTable.getHighData();\n\t}",
"public void teleopPeriodic() \r\n {\r\n Watchdog.getInstance().feed();\r\n Scheduler.getInstance().run();\r\n \r\n //Polls the buttons to see if they are active, if they are, it adds the\r\n //command to the Scheduler.\r\n if (mecanumDriveTrigger.get()) \r\n Scheduler.getInstance().add(new MechanumDrive());\r\n \r\n else if (tankDriveTrigger.get())\r\n Scheduler.getInstance().add(new TankDrive());\r\n \r\n else if (OI.rightJoystick.getRawButton(2))\r\n Scheduler.getInstance().add(new PolarMechanumDrive());\r\n \r\n resetGyro.get();\r\n \r\n //Puts the current command being run by DriveTrain into the SmartDashboard\r\n SmartDashboard.putData(DriveTrain.getInstance().getCurrentCommand());\r\n \r\n SmartDashboard.putString(ERRORS_TO_DRIVERSTATION_PROP, \"Test String\");\r\n \r\n \r\n }",
"@Override\n public void runOpMode() throws InterruptedException{\n\n LeftWheel = hardwareMap.dcMotor.get(\"LeftWheel\");\n RightWheel = hardwareMap.dcMotor.get(\"RightWheel\");\n LLAMA = hardwareMap.dcMotor.get(\"LLAMA\");\n RightWheel.setDirection(DcMotor.Direction.REVERSE);\n beaconFlagSensor = hardwareMap.i2cDevice.get(\"color sensor\");\n LeftWheel.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n RightWheel.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n\n buttonPusher = hardwareMap.servo.get(\"Button Pusher\");\n buttonPusher.setDirection(Servo.Direction.REVERSE);\n\n LeftWheel.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n RightWheel.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n LLAMA.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n\n beaconFlagReader= new I2cDeviceSynchImpl(beaconFlagSensor, I2cAddr.create8bit(0x3c), false);\n beaconFlagReader.engage();\n\n double PUSHER_MIN = 0;\n double PUSHER_MAX = 1;\n buttonPusher.scaleRange(PUSHER_MIN,PUSHER_MAX);\n\n if(beaconFlagLEDState){\n beaconFlagReader.write8(3, 0); //Set the mode of the color sensor using LEDState\n }\n else{\n beaconFlagReader.write8(3, 1); //Set the mode of the color sensor using LEDState\n }\n\n\n waitForStart();\n //Go forward to position to shoot\n long iniForward = 0;\n //Shoot LLAMA\n long shootLLAMA=0 ;\n //Turn towards Wall\n long turnToWall= 0;\n //Approach Wall\n long wallApproach= 0;\n //Correct to prepare for button\n long correctForButton= 0;\n long correctForButton2=0 ;\n //Use sensors to press button\n /** This is sensor*/\n //Go forward\n long toSecondButton= 0;\n //Use Sensors to press button\n /** This is sensor*/\n //turn to center\n\n //charge\n long chargeTime= 0;\n\n //Go forward to position to shoot\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(iniForward);\n\n STOP();\n\n //Shoot LLAMA\n LLAMA.setPower(1);\n\n sleep(shootLLAMA);\nSTOP();\n //Turn towards Wall\n LeftWheel.setPower(-1);\n RightWheel.setPower(1);\n\n sleep(turnToWall);\n\n STOP();\n //Approach Wall\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(wallApproach);\n\n STOP();\n //Correct to prepare for button\n\n LeftWheel.setPower(1);\n RightWheel.setPower(-1);\n\n sleep(correctForButton);\n\n STOP();\n\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(correctForButton2);\n\n STOP();\n topCache = beaconFlagReader.read(0x04, 1);\n //Use sensors to press button\n if ((topCache[0] & 0xFF) <=4 && (topCache[0] & 0xFF) > 0 &&(topCache[0] & 0xFF) <16) {\n while (((topCache[0] & 0xFF) <=4 && (topCache[0] & 0xFF) > 0 &&\n (topCache[0] & 0xFF) <16) && opModeIsActive()) {\n\n\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n sleep(100);\n LeftWheel.setPower(0);\n RightWheel.setPower(0);\n topCache = beaconFlagReader.read(0x04, 1);\n\n if ((topCache[0] & 0xFF) >=7 && (topCache[0] & 0xFF) >= 0){\n telemetry.addLine(\"Color Detected, Pressing Button...\");\n telemetry.update();\n buttonPusher.setPosition(PUSHER_MAX);\n\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(100);\n\n STOP();\n break;\n }\n }\n\n }\n\n else if ((topCache[0] & 0xFF) >=7 && (topCache[0] & 0xFF) >= 0) {\n telemetry.addLine(\"Color Detected, Pressing Button...\");\n telemetry.update();\n buttonPusher.setPosition(PUSHER_MAX);\n\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(100);\n\n STOP();\n }\n\n //Go forward\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(toSecondButton);\n\n STOP();\n //Use Sensors to press button\n topCache = beaconFlagReader.read(0x04, 1);\n //Use sensors to press button\n if ((topCache[0] & 0xFF) <=4 && (topCache[0] & 0xFF) > 0 &&(topCache[0] & 0xFF) <16) {\n while (((topCache[0] & 0xFF) <=4 && (topCache[0] & 0xFF) > 0 &&\n (topCache[0] & 0xFF) <16) && opModeIsActive()) {\n\n\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n sleep(100);\n LeftWheel.setPower(0);\n RightWheel.setPower(0);\n topCache = beaconFlagReader.read(0x04, 1);\n\n if ((topCache[0] & 0xFF) >=7 && (topCache[0] & 0xFF) >= 0){\n telemetry.addLine(\"Color Detected, Pressing Button...\");\n telemetry.update();\n buttonPusher.setPosition(PUSHER_MAX);\n\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(100);\n\n STOP();\n break;\n }\n }\n\n }\n\n else if ((topCache[0] & 0xFF) >=7 && (topCache[0] & 0xFF) >= 0) {\n telemetry.addLine(\"Color Detected, Pressing Button...\");\n telemetry.update();\n buttonPusher.setPosition(PUSHER_MAX);\n\n LeftWheel.setPower(1);\n RightWheel.setPower(1);\n\n sleep(100);\n\n STOP();\n }\n\n //turn to center\n\n\n //charge\n }",
"public int cameraOn() {\r\n System.out.println(\"hw- ligarCamera\");\r\n return serialPort.enviaDados(\"!111O*\");//camera ON \r\n }",
"void activate();",
"void activate();",
"public void onSensorPlug(String idSensor) // evento que se genera al conectar el lector de huella\n {\n objpantprincipal.writeLog(\"Lector \"+idSensor+\": Conectado.\");\n try {\n //Start capturing from plugged sensor.\n GrFingerJava.startCapture(idSensor, this, this);\n } catch (GrFingerJavaException e) {\n //write error to log\n objpantprincipal.writeLog(e.getMessage());\n }\n }",
"public void activarAceptar() {\n aceptar = false;\n }",
"public void servoOn() throws DeviceException {\n \t\ttry {\n \t\t\tcontroller.caput(svonChannel, 1, 2.0);\n \t\t} catch (Throwable e) {\n \t\t\tthrow new DeviceException(\"failed to turn servos on\", e);\n \t\t}\n \t}",
"private void enableNextSensor(BluetoothGatt gatt) {\n BluetoothGattCharacteristic characteristic;\n switch (mState) {\n case 0:\n Log.d(TAG, \"Enabling pressure cal\");\n characteristic = gatt.getService(PRESSURE_SERVICE)\n .getCharacteristic(PRESSURE_CONFIG_CHAR);\n characteristic.setValue(new byte[] {0x02});\n break;\n case 1:\n Log.d(TAG, \"Enabling pressure\");\n characteristic = gatt.getService(PRESSURE_SERVICE)\n .getCharacteristic(PRESSURE_CONFIG_CHAR);\n characteristic.setValue(new byte[] {0x01});\n break;\n case 2:\n Log.d(TAG, \"Enabling humidity\");\n characteristic = gatt.getService(HUMIDITY_SERVICE)\n .getCharacteristic(HUMIDITY_CONFIG_CHAR);\n characteristic.setValue(new byte[] {0x01});\n break;\n default:\n mHandler.sendEmptyMessage(MSG_DISMISS);\n Log.i(TAG, \"All Sensors Enabled\");\n return;\n }\n\n gatt.writeCharacteristic(characteristic);\n }",
"protected void ap() {\n Object object = this.li;\n synchronized (object) {\n if (this.lz != null) {\n return;\n }\n IntentFilter intentFilter = new IntentFilter();\n intentFilter.addAction(\"android.intent.action.SCREEN_ON\");\n intentFilter.addAction(\"android.intent.action.SCREEN_OFF\");\n this.lz = new BroadcastReceiver(){\n\n public void onReceive(Context context, Intent intent) {\n ab.this.d(false);\n }\n };\n this.lp.registerReceiver(this.lz, intentFilter);\n return;\n }\n }"
] | [
"0.68671995",
"0.65612864",
"0.6420422",
"0.64073384",
"0.6317842",
"0.6246352",
"0.6244884",
"0.6164428",
"0.6159508",
"0.6140017",
"0.6132721",
"0.6127805",
"0.6113042",
"0.6095382",
"0.6085696",
"0.6085176",
"0.60597426",
"0.60334855",
"0.59576964",
"0.5942244",
"0.5922196",
"0.59122473",
"0.5910223",
"0.5908343",
"0.5890087",
"0.58841836",
"0.5865714",
"0.5864842",
"0.5859781",
"0.5853232",
"0.5847478",
"0.5842024",
"0.5833517",
"0.5832068",
"0.5828763",
"0.5822471",
"0.5815998",
"0.5802326",
"0.578403",
"0.57769084",
"0.5768297",
"0.5762807",
"0.5759901",
"0.57582664",
"0.5753715",
"0.5745405",
"0.573304",
"0.5713865",
"0.5699523",
"0.56897473",
"0.5673969",
"0.5667314",
"0.56530607",
"0.5640685",
"0.5619427",
"0.56181234",
"0.56159997",
"0.5609709",
"0.56044406",
"0.56015134",
"0.5599936",
"0.55943227",
"0.5585115",
"0.5581569",
"0.5581351",
"0.557917",
"0.5566666",
"0.5561981",
"0.5557655",
"0.555214",
"0.5548422",
"0.5546601",
"0.5545394",
"0.5535696",
"0.55333626",
"0.5528726",
"0.5521914",
"0.5521154",
"0.55210584",
"0.55199736",
"0.5515279",
"0.5512927",
"0.55040264",
"0.5491584",
"0.54862577",
"0.5483244",
"0.5474415",
"0.54721296",
"0.5465287",
"0.5462867",
"0.54594177",
"0.5451816",
"0.54464567",
"0.544626",
"0.5445534",
"0.5445534",
"0.54372907",
"0.5435084",
"0.54326797",
"0.54300255",
"0.5428366"
] | 0.0 | -1 |
DListNode2() constructor(one parameter) this sets vertex1 to its corresponding vertex. | DListNode2(Object vertex1) {
vertex = vertex1;
list = null;
prev = null;
next = null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public AdjListNode(int n) {\n\t\tvertexIndex = n;\n\t}",
"DListNode() {\n item[0] = 0;\n item[1] = 0;\n item[2] = 0;\n prev = null;\n next = null;\n }",
"public Edge(T node_1, T node_2,S label) {\n\t\tparent = node_1;\n\t\tchild = node_2;\n\t\tl = label;\n\t\tcheckRep();\n\t}",
"public ListNode(E d, ListNode<E> node)\n { \n nextNode = node;\n data = d;\n }",
"public ListNode(Object d, ListNode n) {\n\t\tdata = d;\n\t\tnext = n;\n\t}",
"public DirectedEdge(Graph g, Vertex v1, Vertex v2){\n\t\tsuper(g, v1, v2);\n\t\tthis.source = v1;\n\t}",
"public void setVertex(Object vertex2){\r\n this.vertex = vertex2;\r\n }",
"public Node(int y1, int y2, int x1, int x2, int level) {\r\n\t\tsuper();\r\n\t\tthis.y1 = y1;\r\n\t\tthis.y2 = y2;\r\n\t\tthis.x1 = x1;\r\n\t\tthis.x2 = x2;\r\n\t\tthis.level = level;\r\n\t}",
"public ListNode(Object d) {\n\t\tdata = d;\n\t\tnext = null;\n\t}",
"public LinkedElement(T t2){\n//\t\tassigning value to instance variable\n\t\tt=t2;\n\t}",
"public void setNext(DListNode2 next1){\r\n this.next = next1;\r\n }",
"public ListNode(E d)\n {\n nextNode = null;\n data = d;\n }",
"public Edge(int x, int y) {\n\t\tsuper(x, y);\n\t\tthis.x2 = x;\n\t\tthis.y2 = y;\n\t}",
"public LinkedList () {\n\t\tMemoryBlock dummy;\n\t\tdummy = new MemoryBlock(0,0);\n\t\ttail = new Node(dummy);\n\t\tdummy = new MemoryBlock(0,0);\n\t\thead = new Node(dummy);\n\t\ttail.next = head;\n\t\thead.previous = tail;\n\t\tsize = 2;\n\t}",
"public Edge(Object vertex1, Object vertex2, int w){\n v1 = vertex1;\n v2 = vertex2;\n weight = w;\n }",
"public SortedDoubleLinkedList(java.util.Comparator<T> comparator2) {\n\t\t// Initialize comparator\n\t\tcomp = comparator2;\n\t}",
"public void setList(DList2 list1){\r\n list = list1;\r\n }",
"public DirectedEdge(Graph g, Vertex v1, Vertex v2, Vertex source){\n\t\tsuper(g, v1, v2);\n\t\tthis.source = source;\n\t}",
"public DListNode2 next(){\r\n return this.next;\r\n }",
"public ListNode(Object newItem){\n\t\tlistItem = newItem;\n\t\tnext = null;\n\t}",
"GData2(Vertex v1, Vertex v2, GData1 parent, GColour c, boolean isLine) {\n super(parent);\n this.colourNumber = c.getColourNumber();\n this.r = c.getR();\n this.g = c.getG();\n this.b = c.getB();\n this.a = c.getA();\n this.x1 = v1.x;\n this.y1 = v1.y;\n this.z1 = v1.z;\n this.x2 = v2.x;\n this.y2 = v2.y;\n this.z2 = v2.z;\n this.X1 = v1.X;\n this.Y1 = v1.Y;\n this.Z1 = v1.Z;\n this.X2 = v2.X;\n this.Y2 = v2.Y;\n this.Z2 = v2.Z;\n this.isLine = isLine;\n this.lGeom = null;\n }",
"protected LineaAbstract(Point2D p1,Point2D p2){\n super(p1,p2);\n this.ColorRelleno=Color.BLACK;\n ColorRelleno=null;\n this.width=1.0F;\n isRelleno=false;\n isContinuo=true;\n isGradiente=false;\n }",
"public Pair(T v1, V v2) {\r\n this.v1 = v1;\r\n this.v2 = v2;\r\n }",
"public Line(final Line source, final Point endPoint2) {\n this.endPoint2 = endPoint2;\n }",
"public Pair(double v1, double v2) {\n\t\t\n\t\tsuper(v1, v2);\n\t}",
"public EdgeListGraph(int V) {\n\t\t// TODO Auto-generated constructor stub\n\t\tthis.V = V;\n\t\tthis.edgeList = new ArrayList<>();\n\t}",
"public Vector2(int x, int y) {\n this.x = x;\n this.y = y;\n }",
"public DoubleLinkedList(){\n this.head = null;\n this.tail = null;\n this.size = 0;\n this.selec = null;\n }",
"public ListNode() {\n\t\tthis(0, null);\n\t}",
"public VoltageSource(double value, Node node1, Node node2) {\n super(node1, node2);\n this.VS_ID=++No_of_VS;\n setValue(value);\n }",
"LList2(int size) {\r\n\t\tthis();\r\n\t}",
"public Edge(Vertex in_pointOne, Vertex in_pointTwo){\n\t\tthis.pointOne = in_pointOne;\n\t\tthis.pointTwo = in_pointTwo;\n\t}",
"public Point2D(int x1,int y1) {\n\t\tx= x1;\n\t\ty=y1;\n\t}",
"public ListNode(int mark)\r\n {\r\n // initialise instance variables\r\n this.mark = mark;\r\n this.next = null;\r\n }",
"public ListNode(Object newItem, ListNode nextNode){\n\t\tlistItem = newItem;\n\t\tnext = nextNode;\n\t}",
"public PolytopeEdge(PolytopePoint s1, PolytopePoint s2){\n\t\t\tstart = s1;\n\t\t\tend = s2;\n\t\t}",
"public Day2() {\n entry = new LinkedList[INITIAL_CAPACITY];\n }",
"public void addTwoWayVertex(String node1, String node2) {\r\n addEdge(node1, node2);\r\n addEdge(node2, node1);\r\n }",
"public Vec2(int x, int y) {\n\t\t// Store position\n\t\tthis.x = x;\n\t\tthis.y = y;\n\t}",
"public Node(D d){\n\t\tdata = d;\n\t\tnext = null;\n\t}",
"public Pair(S n1, S n2) {\n\t\tkey1 = n1;\n\t\tkey2 = n2;\n\t}",
"public ListNode(E data, ListNode next) {\r\n\t\t\t//this.data = data;\r\n\t\t\tthis(data);\r\n\t\t\tthis.next = next;\r\n\t\t}",
"public Line(Point p1, Point p2) {\n super(p1, p2);\n this.p1 = p1;\n this.p2 = p2;\n }",
"public ObjectListNode (Object o, ObjectListNode p) {\n info = o;\n next = p;\n }",
"public Tuple2() {\n }",
"public Vector2() {\n\t\tthis(0.0f, 0.0f);\n\t}",
"public ListGraph(int numV, boolean directed) {\r\n super(numV, directed);\r\n edges = new List[numV];\r\n for (int i = 0; i < numV; i++) {\r\n edges[i] = new LinkedList < Edge > ();\r\n }\r\n }",
"public LinkedList(Object item) {\n\t\tif (item != null) {\n\t\t\tcurrent = end = start = new ListItem(item);// item is the start and end\n\t\t}\n\t}",
"Edge(Vertex first, Vertex second, Integer cost) {\n this.first = first;\n this.second = second;\n this.cost = cost;\n }",
"public Node(D d, Node<D> n){\n\t\tdata = d;\n\t\tnext = n;\n\t}",
"public InternalNode (int d, Node p0, String k1, Node p1, Node n, Node p){\n\n super (d, n, p);\n ptrs [0] = p0;\n keys [1] = k1;\n ptrs [1] = p1;\n lastindex = 1;\n\n if (p0 != null) p0.setParent (new Reference (this, 0, false));\n if (p1 != null) p1.setParent (new Reference (this, 1, false));\n }",
"public EdgeOperation(T t1, T t2) {\n\t\tthis.t1 = t1;\n\t\tthis.t2 = t2;\n\t}",
"public void addUndirectedEdge(int v1, int v2) {\r\n addUndirectedEdge(v1, v2, null);\r\n }",
"public void addUndirectedEdge(int v1, int v2, Object edgeInfo) {\r\n \tmyAdjLists[v1].add(new Edge(v1, v2, edgeInfo));\r\n \tmyAdjLists[v2].add(new Edge(v2, v1, edgeInfo));\r\n }",
"public LinkedList() {\r\n front = new ListNode(null);\r\n back = new ListNode(null, front, null);\r\n front.next = back;\r\n size = 0;\r\n }",
"ListNode(T datum) {\n\t\t\tthis.datum = datum;\n\t\t\tthis.next = null;\n\t\t}",
"public Node(Point p) //is this needed\n\t{\n\t\tpoint = p;\n\t\tnext = null;\n\t}",
"public MyLinkedList() {\n this.size = 0;\n this.head = new ListNode(0);\n }",
"public void setPrev(DListNode2 prev1){\r\n this.prev = prev1;\r\n }",
"public DoubleLinkedList(DoubleLinkedList other) {\n\n\t\tDoubleLinkedList l = other.clone();\n\t\tDLNode n = l.head;\n\n\t\twhile (n != null) {\n\t\t\tif (n.val != Integer.MIN_VALUE) {\n\t\t\t\tthis.pushBack(n.val);\n\t\t\t} else {\n\t\t\t\tthis.pushBackRecursive(n.list);\n\t\t\t}\n\t\t\tn = n.next;\n\t\t}\n\t\tl.elements = this.elements;\n\n\t}",
"public Person2(String fname, String lname) {\n this.fname = fname;\n this.lname = lname;\n }",
"public Node(int x, int y, Node n, Node p){\n super(x, y);\n this.nextNode = n;\n this.prevNode = p;\n }",
"public GraphEdge(GraphNode u, GraphNode v, char busLine){\r\n first = u;\r\n second = v;\r\n this.busLine = busLine;\r\n }",
"public void addUndirectedEdge(int v1, int v2) {\n addUndirectedEdge(v1, v2, null);\n }",
"public void addUndirectedEdge(int v1, int v2) {\n addUndirectedEdge(v1, v2, null);\n }",
"public InternalNode(int d, Node p0, int k1, Node p1, Node n, Node p) {\n\t\tsuper (d, n, p);\n\t\tptrs[0] = p0;\n\t\tkeys[1] = k1;\n\t\tptrs[1] = p1;\n\t\tlastindex = 1;\n\t\tif (p0 != null) {\n\t\t\tp0.setParent(new Reference (this, 0, false));\n\t\t}\n\t\tif (p1 != null) {\n\t\t\tp1.setParent(new Reference (this, 1, false));\n\t\t}\n\t}",
"public void setNode_2(String node_2);",
"public Point2d() {\r\n\t // Call two-argument constructor and specify the origin.\r\n\t\t this(0, 0);\r\n\t\t System.out.println(\"Point2d default initiializing\");\r\n\t }",
"public void addEdge(int v1, int v2) {\r\n addEdge(v1, v2, null);\r\n }",
"protected DirectProductNodeModel() {\n\t\tsuper(2, 1);\n\t}",
"public ArgList(Object arg1, Object arg2) {\n super(2);\n addElement(arg1);\n addElement(arg2);\n }",
"public SideConnection(Side side1, Side side2) {\r\n\t\tthis.side1 = side1;\r\n\t\tthis.side2 = side2;\r\n\t}",
"public void addEdge(int v1, int v2) {\r\n\t\tadjList[v1].add(v2);\r\n\t}",
"public Graph()\r\n {\r\n this( \"x\", \"y\" );\r\n }",
"public DoubleLinkedList() {\n head = null;\n tail = null;\n }",
"public DoubleLinkedList()\n {\n \tfirst=last=null;\n }",
"public MyLinkedList()\n {\n head = new Node(null, null, tail);\n tail = new Node(null, head, null);\n }",
"public void addEdge(int v1, int v2, Object edgeInfo) {\r\n myAdjLists[v1].add(new Edge(v1, v2, edgeInfo));\r\n }",
"public\nBLine2D(double x2, double y2)\n{\n\tsuper (0.0, 0.0, x2, y2);\n}",
"public void setEdge(int n1, int n2){\n\t\tif(outOfBounds(n1) || outOfBounds(n2))// if node indexes are bad return\n\t\t\treturn ;\n\t\t\n if((dGraph.getElement(n1, n2)) == 1){\n\t\t\treturn;\n\t}\n\t\tdGraph.setElement(n1, n2, 1); //shows that there is an edge going from n1 to n2\n\t\tdGraphin.setElement(n2, n1, 1);// show the edges going into n2\n\t\toutdegree[n1]++;\n\t\tindegree[n2]++;\n\t\t\n\t}",
"Graph(int v) {\n V = v;\n adj = new LinkedList[v];\n for (int i = 0; i < v; ++i)\n adj [i] = new LinkedList();\n }",
"public ObjectListNode (Object o) {\n info = o;\n next = null;\n }",
"void addEdge(int vertex1, int vertex2){\n adjList[vertex1].add(vertex2);\n adjList[vertex2].add(vertex1);\n }",
"Graph(int n){\r\n numberOfVertices = n;\r\n adjacentVertices = new LinkedList[numberOfVertices];\r\n for (int i = 0; i < numberOfVertices; i++){\r\n adjacentVertices[i] = new LinkedList<>();\r\n }\r\n }",
"public EntityPair(int entity1, int entity2) {\n\t \n\t this.entity1 = entity1;\n\t this.entity2 = entity2;\n }",
"public List(E value) {\n\t\thead = new ListNode(value, null);\n\t}",
"public Line(TwoDPoint p1, TwoDPoint p2) throws Exception\n {\n this(p1.x, p1.y, p2.x, p2.y);\n }",
"public void addEdge(int v1, int v2) {\n addEdge(v1, v2, null);\n }",
"public void addEdge(int v1, int v2) {\n addEdge(v1, v2, null);\n }",
"public LinearRenderer2D() {\n\t}",
"public ListNode(int data) {\n\t\tthis(data, null);\n\t}",
"public GraphEdge()\r\n {\r\n cost = 1.0;\r\n indexFrom = -1;\r\n indexTo = -1;\r\n }",
"public Edge(Vertex<VV> from, Vertex<VV> to)\r\n {\r\n this.from = from;\r\n this.to = to;\r\n from.addEdge(this);\r\n to.addEdge(this);\r\n }",
"public Node(Point p, Node n)\n\t{\n\t\tpoint = p;\n\t\tnext = n;\n\t}",
"void graph2() {\n\t\tconnect(\"1\", \"7\");\n\t\tconnect(\"1\", \"8\");\n\t\tconnect(\"1\", \"9\");\n\t\tconnect(\"9\", \"1\");\n\t\tconnect(\"9\", \"0\");\n\t\tconnect(\"9\", \"4\");\n\t\tconnect(\"4\", \"8\");\n\t\tconnect(\"4\", \"3\");\n\t\tconnect(\"3\", \"4\");\n\t}",
"public SListNode(Object item, SListNode next) {\n this.item = item;\n this.next = next;\n }",
"public DoubleLinkedList() {\r\n header.next = header.previous = header;\r\n//INSTRUMENTATION BEGIN\r\n //initializates instrumentation fields for concrete objects\r\n _initialSize = this.size;\r\n _minSize = 0;\r\n//INSTRUMENTATION END\r\n }",
"public Line(double x1, double y1, double x2, double y2) {\r\n this(new Point(x1, y1), new Point(x2, y2));\r\n }",
"public BSPLine(float x1, float y1, float x2, float y2) {\n setLine(x1, y1, x2, y2);\n }",
"@Override\n\tpublic void setNode_2(java.lang.String node_2) {\n\t\t_dictData.setNode_2(node_2);\n\t}"
] | [
"0.64440304",
"0.6350428",
"0.6346573",
"0.63447994",
"0.625479",
"0.6238969",
"0.6220903",
"0.621804",
"0.61809045",
"0.6136964",
"0.61078143",
"0.61054564",
"0.60596085",
"0.60056365",
"0.59687483",
"0.5931966",
"0.59172934",
"0.5899608",
"0.58941686",
"0.58737606",
"0.58732176",
"0.5849517",
"0.5824994",
"0.58188677",
"0.5799621",
"0.5789353",
"0.57743865",
"0.5761816",
"0.5748677",
"0.5736311",
"0.5732871",
"0.57288986",
"0.5725367",
"0.5718271",
"0.56981236",
"0.56932145",
"0.5690727",
"0.56823385",
"0.56799436",
"0.5673071",
"0.5628861",
"0.5625903",
"0.5624001",
"0.56141096",
"0.56039727",
"0.5602957",
"0.5602799",
"0.5592492",
"0.55911446",
"0.5588973",
"0.5576028",
"0.5571475",
"0.5562843",
"0.55562216",
"0.55482805",
"0.5547329",
"0.55392975",
"0.5537035",
"0.5537035",
"0.55037224",
"0.55028117",
"0.549085",
"0.5489822",
"0.5488924",
"0.5488924",
"0.54879695",
"0.5484442",
"0.547239",
"0.54699016",
"0.5467695",
"0.54619235",
"0.54589635",
"0.5456439",
"0.5455361",
"0.5440152",
"0.54330385",
"0.54318523",
"0.5426356",
"0.54258484",
"0.5422531",
"0.5418794",
"0.54059553",
"0.53992635",
"0.5394927",
"0.53941894",
"0.5392102",
"0.53902227",
"0.5389912",
"0.5389912",
"0.53834003",
"0.5381908",
"0.5379389",
"0.53784245",
"0.5377627",
"0.53765255",
"0.53748256",
"0.53733754",
"0.53694564",
"0.5366668",
"0.53654456"
] | 0.88870454 | 0 |
getVertex() gets the correcsponding vertex | public Object getVertex(){
return this.vertex;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Vertex getVertex();",
"Vertex getVertex(int index);",
"public V getVertex(int index);",
"public V getVertex()\r\n/* */ {\r\n/* 198 */ return (V)this.vertex;\r\n/* */ }",
"public Vertex getVertex() {\n return curr;\n }",
"public int getvertex() {\n\t\treturn this.v;\n\t}",
"public String getVertex() {\n\t\treturn vertices.get(0);\n\t}",
"private Vertex getVertexFor(Agent ag) {\n return getDataFor(ag).vertex;\n }",
"public V getParent(V vertex);",
"public VertexObject getReferenceVertex() {\n return referenceVertex;\n }",
"private E3DTexturedVertex getVertexA(){\r\n\t\treturn vertices[0];\r\n\t}",
"public native GLatLng getVertex(GPolyline self, int index)/*-{\r\n\t\treturn self.getVertex(index);\r\n\t}-*/;",
"public E3DTexturedVertex getVertex(int index){\r\n if(index >= 0 && index < 3)\r\n return vertices[index];\r\n else\r\n return null;\r\n }",
"public E getParentEdge(V vertex);",
"public Vertex getVertex(int name) {\n\t\treturn vertices.get(name);\n\t}",
"public int getBaseVertex() {\n return baseVertex;\n }",
"public Vertex getVertex(String name) {\n return mVertices.get(name);\n }",
"private Vertice getVertex(String name) {\r\n Vertice v = (Vertice) vertices.get(name);\r\n if (v == null) {\r\n v = new Vertice(name);\r\n vertices.put(name, v);\r\n }\r\n return v;\r\n }",
"public ExecutionVertexID getVertexID() {\n \n \t\treturn this.vertexID;\n \t}",
"abstract public Vertex getReadIn();",
"@Override\n public Vertex getSource() {\n return sourceVertex;\n }",
"public HitVertex getVertex(String id) {\n\t\treturn hitVertices.get(id);\n\t}",
"public Vertex getVertex(String place)\n\t{\n\t\treturn vertices.get(place);\n\t}",
"public String vertexName();",
"@Override\n\tpublic Vertex getElement() {\n\t\tFramedGraph fg = Tx.getActive().getGraph();\n\t\tif (fg == null) {\n\t\t\tthrow new RuntimeException(\n\t\t\t\t\t\"Could not find thread local graph. The code is most likely not being executed in the scope of a transaction.\");\n\t\t}\n\n\t\tVertex vertexForId = fg.getVertex(id);\n\t\tif (vertexForId == null) {\n\t\t\tthrow new RuntimeException(\"No vertex for Id {\" + id + \"} could be found within the graph\");\n\t\t}\n\t\tElement vertex = ((WrappedVertex) vertexForId).getBaseElement();\n\n\t\t// Unwrap wrapped vertex\n\t\tif (vertex instanceof WrappedElement) {\n\t\t\tvertex = (Vertex) ((WrappedElement) vertex).getBaseElement();\n\t\t}\n\t\treturn (Vertex) vertex;\n\t}",
"public int getVertexNumber() {\n\t\treturn _vertexId;\n\t}",
"public int getStartVertex() {\n\t\treturn startVertex;\n\t}",
"Vertex createVertex();",
"public Vertex getFrom() {\r\n\r\n return from;\r\n }",
"Vertex getOtherVertex(Vertex v) {\n\t\t\tif(v.equals(_one)) return _two;\n\t\t\telse if(v.equals(_two)) return _one;\n\t\t\telse return null;\n\t\t}",
"private Vertex getVertex( String vertexName )\n {\n Vertex v = vertexMap.get( vertexName );\n if( v == null )\n {\n v = new Vertex( vertexName );\n vertexMap.put( vertexName, v );\n }\n return v;\n }",
"public String getVertexName()\n\t{\n\t\treturn vertexName ;\n\t}",
"public Vertex getSource() {\n return source;\n }",
"VertexType getOtherVertexFromEdge( EdgeType r, VertexType oneVertex );",
"public void addVertex();",
"public abstract Proximity2DResult getNearestVertex(Geometry geom,\n\t\t\tPoint inputPoint);",
"public E3DVector3F getVertexPosC(){\r\n return vertices[2].getVertexPos();\r\n }",
"public native VertexNode first();",
"@Override\r\n\tpublic E getVertexAtGivenDistance(E src, int distance) {\r\n\t\treturn graphForWarshall.getVertexAtGivenDistance(src, distance);\r\n\t}",
"public int getVertexVal()\r\n\t{\r\n\t\treturn this.value;\r\n\t}",
"@Override\n public Vertex getTarget() {\n return targetVertex;\n }",
"public Vertex getPrevious(){\n return previous;\n }",
"public int getColor(Vertex v);",
"public E3DVector3F getVertexPosA(){\r\n return vertices[0].getVertexPos();\r\n }",
"public int getVertexIdentity(Agent ag) {\n return getVertexFor(ag).identity().intValue();\n }",
"public Vertex getStart()\n\t{\n\t\treturn start.copy();\n\t}",
"public Vertex<VV> getFrom()\r\n { return from; }",
"public ProcessVertex getInVertex() {\n\t\treturn this.inVertex;\n\t}",
"public E3DVector3F getVertexPosB(){\r\n return vertices[1].getVertexPos();\r\n }",
"private void getVertex(int x, int y, Vector3f vertex) {\n\t\tfloat height = getRawHeightFieldValue(x, y);\n\n\t\tswitch (m_upAxis) {\n\t\tcase 0: {\n\t\t\tvertex.set(height - m_localOrigin.x, (-m_width / 2.0f) + x, (-m_length / 2.0f) + y);\n\t\t\tbreak;\n\t\t}\n\t\tcase 1: {\n\t\t\tvertex.set((-m_width / 2.0f) + x, height - m_localOrigin.y, (-m_length / 2.0f) + y);\n\t\t\tbreak;\n\t\t}\n\n\t\tcase 2: {\n\t\t\tvertex.set((-m_width / 2.0f) + x, (-m_length / 2.0f) + y, height - m_localOrigin.z);\n\t\t\tbreak;\n\t\t}\n\t\t}\n\n\t\tvertex.x = vertex.x * m_localScaling.x;\n\t\tvertex.y = vertex.y * m_localScaling.y;\n\t\tvertex.z = vertex.z * m_localScaling.z;\n\t}",
"@Override\r\n\tpublic Color getVertexColor(E key) {\r\n\t\tif(containsVertex(key)) {\r\n\t\t\treturn vertices.get(key).getColor();\r\n\t\t}\r\n\t\treturn null;\r\n\t}",
"public int getDegree(V vertex);",
"private Optional<Vertex> getVertexByIndex(GraphTraversalSource source, UUID id, String collectionName) {\n Optional<Vertex> vertexOpt = indexHandler.findById(id);\n\n // Return if the neo4j Node ID matches no vertex (extreme edge case)\n if (!vertexOpt.isPresent()) {\n LOG.error(Logmarkers.databaseInvariant,\n \"Vertex with tim_id {} is found in index with id {}L but not in graph database\", id);\n return Optional.empty();\n }\n\n // Get the latest version of the found Vertex\n Vertex foundVertex = vertexOpt.get();\n int infinityGuard = 0;\n while (foundVertex.vertices(Direction.OUT, \"VERSION_OF\").hasNext()) {\n // The neo4j index Node is one version_of behind the actual node\n foundVertex = foundVertex.vertices(Direction.OUT, \"VERSION_OF\").next();\n if (++infinityGuard >= MAX_VERSION_OF_DEPTH) {\n LOG.error(Logmarkers.databaseInvariant, \"Vertices with tim_id {} might have circular VERSION_OF\", id);\n return Optional.empty();\n }\n }\n\n // Only if this latest version is truly registered as latest return this as a successful hit\n if (foundVertex.value(\"isLatest\")) {\n return Optional.of(foundVertex);\n } else {\n LOG.error(Logmarkers.databaseInvariant,\n \"Last version of vertex with tim_id {} is not marked as isLatest=true\", id);\n }\n\n // Failed to find vertex in lucene index, so return\n return Optional.empty();\n }",
"public Vector2D getLocalVertex(int i){\n\t\treturn localVertices.get(i%localVertices.size());\n\t}",
"public Town getVertex(String name) {\n\t\tfor (Town t : towns) {\n\t\t\tif (t.getName().equals(name)) {\n\t\t\t\treturn t;\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}",
"public Vertex getPrev() {\n return prev;\n }",
"public int degreeOf(V vertex);",
"int getVertices();",
"List<V> getVertexList();",
"protected int indexOf (E vertex)\n {\n int indexOfVertex = -1;\n for (int index = 0; index <= lastIndex; index++)\n {\n if (vertex.equals(vertices[index]))\n {\n indexOfVertex = index;\n break;\n }\n }\n\n return indexOfVertex;\n }",
"public abstract String getVertexSymbol(int vertexIndex);",
"Vertex findVertex(char v) {\r\n\t\tfor (int i = 0; i < vertices.size(); i++) {\r\n\t\t\tif (vertices.get(i).label == v)\r\n\t\t\t\treturn vertices.get(i);\r\n\t\t}\r\n\t\treturn null; // return null if not found.\r\n\t}",
"public VDataT getVertexData( VKeyT key ) throws NoSuchVertexException;",
"public int other(int vertex) {\n if (vertex == v) return w;\n else if (vertex == w) return v;\n else throw new IllegalArgumentException(\"Illegal endpoint\");\n }",
"public int other(int vertex) {\n if (vertex == v) return w;\n else if (vertex == w) return v;\n else throw new IllegalArgumentException(\"Illegal endpoint\");\n }",
"public String toString(){\n\t\treturn vertex.toString();\n\t}",
"@Test\n public void testGetVertexIndex() throws GeoTessException {\n posLinear.set(8, new double[]{0., 0., -1.}, 6300.);\n assertEquals(11, posLinear.getVertexIndex());\n\n // set position to x, which does not coincide with a\n // model vertex.\n posLinear.set(8, x, R);\n assertEquals(-1, posLinear.getVertexIndex());\n }",
"public JobVertexID getJobVertexID() {\n\t\treturn jobVertexID;\n\t}",
"abstract public Vertex getClone();",
"private CityByDegrees getStartingVertexCity() {\r\n\t\treturn this.startingVertexCity;\r\n\t}",
"public Agent getVertexPropertiesOwner(Vertex v) {\n\treturn lockedVertices.get(v);\n }",
"public Graph<VLabel, ELabel>.Vertex finalVertex() {\n return _finalVertex;\n }",
"void add(int vertex);",
"public abstract int[] getConnected(int vertexIndex);",
"private static Vector3f nextVertex(Vector3f normal, Vector3f vertex) {\n Vector3f next = new Vector3f();\n Vector3f.cross(normal, vertex, next);\n Vector3f.add(normal, next, next);\n return next;\n }",
"private Polygon2D getTriByVertex(Point2D vertex) {\n \t\tPolygon2D tri = new Polygon2D();\n \t\tdouble y = vertex.getY();\n \t\ttri.append(vertex);\n \t\ttri.append(250+y*Math.sqrt(3)/2, 250*Math.sqrt(3)-y/2);\n \t\ttri.append(750-y*Math.sqrt(3)/2, 250*Math.sqrt(3)-y/2);\n \t\treturn tri;\n }",
"public ProcessVertex getOutVertex() {\n\t\treturn this.outVertex;\n\t}",
"public Vertex getDestination() {\n return destination;\n }",
"public Vertex getAnyVertex()\n {\n for (GraphElement element : elements) {\n if(element instanceof Vertex) {\n return (Vertex) element;\n }\n }\n return null;\n }",
"public E3DVector4F getVertexColorC(){\r\n\t\treturn vertices[2].getVertexColor();\r\n\t}",
"public Vertex getTo() {\r\n\r\n return to;\r\n }",
"protected void processVertex(Vertex w){\n\t}",
"public V addVertex(V v);",
"Set<Vertex> getVertices();",
"public List<wVertex> getVertices(){\r\n return vertices;\r\n }",
"public Vertex getVertexFromList(int rank) {\r\n\t\treturn listVertex.get(rank);\r\n\t}",
"Vertex(){}",
"public Vertex toVertex() {\n return new Vertex(\n getX(),\n getY(),\n getZ()\n );\n }",
"public HashMap<Integer, Vertex> getVertices() {\n\t\treturn vertices;\n\t}",
"public Vertex next() {\n nodeIndex++;\n return iterV[nodeIndex];\n }",
"@Override\r\n\tpublic VertexInterface<T> getPredecessor() {\n\t\treturn null;\r\n\t}",
"private List<E> get(V vertex) {\n return this.data.getOrDefault(vertex, new BinarySearchTree<>()).getTreeByInOrder_depthFirst();\n }",
"public E3DVector4F getVertexColorA(){\r\n\t\treturn vertices[0].getVertexColor();\r\n\t}",
"public Vertex<VV> getTo()\r\n { return to; }",
"@Override\n public VertexCollection getVertexCollection() {\n return this.vertices.copy();\n }",
"public E3DVector4F getVertexColorB(){\r\n\t\treturn vertices[1].getVertexColor();\r\n\t}",
"public short getVertexType() {\n return REQUIRED_VERTEX;\n }",
"void addVertex(Vertex v);",
"public ArrayList<Point3D> getVertex(Block bl) {\r\n\t\tArrayList<Point3D> pivot = new ArrayList<Point3D>();\r\n\t\tpivot.add(bl.getpoint_BlockTopLeft());\r\n\t\tpivot.add(bl.getpoint_BlockTopRight());\r\n\t\tpivot.add(bl.getPoint_BlockDownRight());\r\n\t\tpivot.add(bl.getpoint_BlockDownleft());\r\n\t\treturn pivot;\r\n\t}",
"private int vertexIndex(T obj){\n for (int i = 0; i < n; i++){\n if (obj.equals(vertices[i])){\n return i;\n }\n }\n return NOT_FOUND;\n }"
] | [
"0.8772969",
"0.8285322",
"0.78824043",
"0.7774464",
"0.7657529",
"0.76104844",
"0.75517446",
"0.74839044",
"0.74307114",
"0.7353803",
"0.72341293",
"0.71912616",
"0.7163185",
"0.7108085",
"0.7090032",
"0.70617247",
"0.7019972",
"0.69913703",
"0.68717045",
"0.6838569",
"0.68247503",
"0.682262",
"0.6804464",
"0.6804233",
"0.6789617",
"0.6775118",
"0.6765501",
"0.6750389",
"0.6750364",
"0.668172",
"0.6679973",
"0.6662605",
"0.66474664",
"0.65991074",
"0.65822285",
"0.65662456",
"0.6555469",
"0.65012735",
"0.64736056",
"0.6471168",
"0.6467783",
"0.645342",
"0.6445698",
"0.6408699",
"0.6407408",
"0.6407352",
"0.6405568",
"0.64055574",
"0.64050883",
"0.64025855",
"0.63801384",
"0.6373777",
"0.6356326",
"0.63551885",
"0.6332577",
"0.6331454",
"0.6299003",
"0.6276455",
"0.62590766",
"0.62509435",
"0.62475413",
"0.62212944",
"0.6211183",
"0.62077165",
"0.6192027",
"0.61712873",
"0.61592484",
"0.61206746",
"0.611786",
"0.6117079",
"0.61139965",
"0.60860807",
"0.60855913",
"0.6082851",
"0.6075034",
"0.6074542",
"0.60716546",
"0.60559493",
"0.6054355",
"0.6048724",
"0.6047542",
"0.60446614",
"0.6030416",
"0.60223997",
"0.6022012",
"0.6017475",
"0.60171217",
"0.60133666",
"0.6003619",
"0.5997686",
"0.5990367",
"0.59859484",
"0.59770525",
"0.59639746",
"0.59588647",
"0.59528047",
"0.59399843",
"0.59331876",
"0.59274644",
"0.59262985"
] | 0.80935717 | 2 |
next() gets the next that corresponds to this. | public DListNode2 next(){
return this.next;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public T next() {\n return cur.next();\n }",
"@Override\n public Integer next() {\n if (next != null) {\n Integer next = this.next;\n this.next = null;\n return next;\n\n }\n\n return iterator.next();\n }",
"public T next()\n {\n T data = current.item;\n current = current.next;\n return data;\n }",
"@Override\n public T next() {\n current = current.next;\n return current.data;\n }",
"@Override\n\t\tpublic Item next() {\n\t\t\tItem item=current.item;\n\t\t\tcurrent=current.next;\n\t\t\treturn item;\n\t\t}",
"@Override\n public Integer next() {\n Integer res = next;\n advanceIter();\n return res;\n }",
"private E next() {\n\t\tif (hasNext()) {\n\t\t\tE temp = iterator.data;\n\t\t\titerator = iterator.next;\n\t\t\treturn temp;\n\t\t} else {\n\t\t\treturn null;\n\t\t}\n\t}",
"public Object next()\n {\n return _iterator.next();\n }",
"@Override\n public Integer next() {\n Integer result = null;\n if (checkCurrentIterator(this.currentIterator) && this.currentIterator.hasNext()) {\n while (this.currentIterator.hasNext()) {\n return this.currentIterator.next();\n }\n } else if (it.hasNext()) {\n this.currentIterator = getIterator(it);\n return this.next();\n }\n return result;\n }",
"@Override\n public Object next() {\n Object retval = this.nextObject;\n advance();\n return retval;\n }",
"public E next() {\r\n\r\n\t\tE result = null;\r\n\t\tif (hasNext()) {\r\n\t\t\tresult = links.get(counter);\r\n\t\t\tcounter++;\r\n\t\t}\r\n\t\treturn result;\r\n\t}",
"public T next()\r\n { \r\n if (next == null)\r\n throw new NoSuchElementException(\"Attempt to\" +\r\n \" call next when there's no next element.\");\r\n\r\n prev = next;\r\n next = next.next;\r\n return prev.data;\r\n }",
"@Override\n public T next() {\n T n = null;\n if (hasNext()) {\n // Give it to them.\n n = next;\n next = null;\n // Step forward.\n it = it.next;\n stop -= 1;\n } else {\n // Not there!!\n throw new NoSuchElementException();\n }\n return n;\n }",
"public T next() {\n T temp = this.curr.next.getData();\n this.curr = this.curr.next;\n return temp;\n }",
"public K next()\n {\n\tif (hasNext()) {\n\t K element = current.data();\n\t current = current.next(0);\n\t return element; \n\t} else {\n\t return null; \n\t}\n }",
"public T next() {\n T temp = this.curr.getData();\n this.curr = this.curr.getNext();\n return temp;\n }",
"public Object next()\n {\n if(!hasNext())\n {\n throw new NoSuchElementException();\n //return null;\n }\n previous= position; //Remember for remove;\n isAfterNext = true; \n if(position == null) \n {\n position = first;// true == I have not called next \n }\n else\n {\n position = position.next;\n }\n return position.data;\n }",
"public Object next();",
"public Object next();",
"@Override\n public Item next() {\n if(!hasNext()) throw new NoSuchElementException(\"Failed to perform next because hasNext returned false!\");\n Item item = current.data;\n current = current.next;\n return item;\n }",
"@Override\n\tpublic Integer next() {\n\t return iterator.next();\n\t}",
"public E next() {\r\n current++;\r\n return elem[current];\r\n }",
"@Override\r\n\t\tpublic Key next() {\n\t\t\tKey i=current.item;\r\n\t\t\tcurrent=current.next;\r\n\t\t\treturn i;\r\n\t\t}",
"@Override\n\t\tpublic T1 next() {\n\t\t\treturn (T1)_items[getindex(++_current)];\n\t\t}",
"@Override\n public Node next() {\n if (next == null) {\n throw new NoSuchElementException();\n }\n Node current = next;\n next = next.getNextSibling();\n return current;\n }",
"@Override\n\tpublic Item next() {\n\t\tindex = findNextElement();\n\n\t\tif (index == -1)\n\t\t\treturn null;\n\t\treturn items.get(index);\n\t}",
"@Override\n E next();",
"public void next() {\n\t\titerator.next();\n\t}",
"@Override\n public E next() {\n if (this.hasNext()) {\n curr = curr.nextNode;\n return curr.getData();\n }\n else {\n throw new NoSuchElementException();\n }\n }",
"public Item next(){\n if(current==null) {\n throw new NoSuchElementException();\n }\n\n Item item = (Item) current.item;\n current=current.next;\n return item;\n }",
"@Override\r\n public T next() {\r\n if (hasNext()) {\r\n node = node.next();\r\n nextCalled = true;\r\n return node.getData();\r\n }\r\n else {\r\n throw new NoSuchElementException(\"Illegal call to next(); \"\r\n + \"iterator is after end of list.\");\r\n }\r\n }",
"@Override\n public Integer next() {\n if (next == null) {\n throw new NoSuchElementException();\n }\n Integer toReturn = next;\n next = null;\n if (peekingIterator.hasNext()) {\n next = peekingIterator.next();\n }\n return toReturn;\n }",
"public ListElement<T> getNext()\n\t{\n\t\treturn next;\n\t}",
"public Nodo getnext ()\n\t\t{\n\t\t\treturn next;\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic T next() throws NoSuchElementException{\n\t\tif (hasNext()) {\r\n\t\t\tT curr = next.getData();\r\n\t\t\tnext = next.getNext();\r\n\t\t\treturn curr;\r\n\t\t}\r\n\t\telse throw new NoSuchElementException();\r\n\t\t\r\n\t}",
"@Override\n public Integer next() {\n if (cur != null) {\n int temp = cur.intValue();\n cur = null;\n return temp;\n }\n\n if (iter.hasNext()) {\n return iter.next();\n }\n\n return null;\n }",
"public BSCObject next()\n {\n if (ready_for_fetch)\n {\n // the next sibling is waiting to be returned, so just return it\n ready_for_fetch = false;\n return sibling;\n }\n else if (hasNext())\n {\n // make sure there is a next sibling; if so, return it\n ready_for_fetch = false;\n return sibling;\n }\n else\n throw new NoSuchElementException();\n }",
"public T next(){\n return (T)data[ci++];\n }",
"public MyNode<? super E> getNext()\n\t{\n\t\treturn this.next;\n\t}",
"@Override\r\n\tpublic String next() {\n\t\tString nx;\r\n\r\n\t\tnx = p.getNext();\r\n\r\n\t\tif (nx != null) {\r\n\t\t\tthisNext = true;\r\n\t\t\tinput(nx);\r\n\t\t}\r\n\t\treturn nx;\r\n\t}",
"@Override\r\n\t\tpublic T next() {\r\n\t\t\tNode<T> temp = currentNode;\r\n\t\t\tcurrentNode = currentNode.nextNode;\r\n\t\t\treturn temp.content;\r\n\t\t}",
"public final T next()\n {\n return skip(1);\n }",
"public Node<T> next() {\r\n return next;\r\n }",
"public void _next() {\n Object o;\n try {\n o = iter.next();\n } catch (NoSuchElementException e) {\n has_next = 0;\n return;\n }\n // resolve object\n if (o == null) {\n has_next = 1;\n next = null;\n } else if (o instanceof IdentityIF) {\n try {\n o = txn.getObject((IdentityIF)o, true);\n if (o == null) {\n _next();\n } else {\n has_next = 1;\n next = (F) o;\n }\n } catch (Throwable t) {\n has_next = -1;\n next = null;\n }\n } else {\n has_next = 1;\n next = (F) o;\n }\n }",
"public Item next() {\n\t\t\tif (!hasNext())\n\t\t\t\treturn null;\n lastAccessed = current;\n Item item = current.item;\n current = current.next; \n index++;\n return item;\n\t\t}",
"@Override\n\t\tpublic int next() {\n\t\t\treturn current++;\n\t\t}",
"public Node<E> getNext() { return next; }",
"public T next()\n {\n // TODO: implement this method\n return null;\n }",
"public abstract T next();",
"@Override\n public Object next()\n {\n if (current != null && current.next != null)\n {\n current = current.next; // Move to the next element in bucket\n }\n else // Move to next bucket\n {\n do\n {\n bucketIndex++;\n if (bucketIndex == buckets.length)\n {\n throw new NoSuchElementException();\n }\n current = buckets[bucketIndex];\n }\n while (current == null);\n }\n return current.data;\n }",
"public void next() {\n\t\t}",
"public Node<S> getNext() { return next; }",
"@Override\n public Integer next() {\n if (hasTop) {\n hasTop = false;\n return top;\n }\n return it.next();\n }",
"public Node getNext() { return next; }",
"public E next()\n\t{\n\t\treturn (vector.get(curr++));\n\t}",
"public T next();",
"public T next();",
"public T next()\n\t\t{\n\t\t\tif(hasNext())\n\t\t\t{\n\t\t\t\tT currentData = current.getData(); //the data that will be returned\n\t\t\t\t\n\t\t\t\t// must continue to keep track of the Node that is in front of\n\t\t\t\t// the current Node whose data is must being returned , in case\n\t\t\t\t// its nextNode must be reset to skip the Node whose data is\n\t\t\t\t// just being returned\n\t\t\t\tbeforePrevious = previous;\n\t\t\t\t\n\t\t\t\t// must continue keep track of the Node that is referencing the\n\t\t\t\t// data that was just returned in case the user wishes to remove()\n\t\t\t\t// the data that was just returned\n\t\t\t\t\n\t\t\t\tprevious = current; // get ready to point to the Node with the next data value\n\t\t\t\t\n\t\t\t\tcurrent = current.getNext(); // move to next Node in the chain, get ready to point to the next data item in the list\n\t\t\t\t\n\t\t\t\tthis.removeCalled = false;\n\t\t\t\t// it's now pointing to next value in the list which is not the one that may have been removed\n\t\t\t\t\n\t\t\t\treturn currentData;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tthrow new NoSuchElementException();\n\t\t\t}\n\t\t}",
"public AIter next() {\n int p;\n return (p = start + 1) < size ? new Iter(p) : null;\n }",
"@Override\r\n\t\tpublic Package next() {\r\n\t\t\tif (first.next == null)\r\n\t\t\t\treturn null;\r\n\t\t\telse\r\n\t\t\t\treturn first.next;\r\n\r\n\t\t}",
"@Override\n public Integer next() {\n if (!isPeeked && hasNext())\n return iterator.next();\n int toReturn = peekedElement;\n peekedElement = -1;\n isPeeked = false;\n return toReturn;\n }",
"public ListElement getNext()\n\t {\n\t return this.next;\n\t }",
"@Override\n\t\tpublic T next() {\n\t\t\treturn null;\n\t\t}",
"@Override\n public Resource next() {\n if (wrapped == null || !wrapped.hasNext()) {\n throw new NoSuchElementException();\n }\n failFast(this);\n try {\n return wrapped.next();\n } finally {\n if (!wrapped.hasNext()) {\n wrapped = null;\n remove(this);\n }\n }\n }",
"public LLNode<T> getNext() {\n return next;\n }",
"@Override\r\n\t\t\t\t\tpublic K next() {\r\n\t\t\t\t\t\treturn nextEntry().getKey();//next() returns the key\r\n\t\t\t\t\t}",
"public Object getNext() { \t\n\t\t\tcurrIndex++;\t \n\t\t\treturn collection.elementAt(currIndex);\n\t\t}",
"public void next();",
"public void next();",
"@Override\n\t\tpublic Node next() {\n\t\t\tif (this.next == null) {\n\t\t\t\treturn null;\n\t\t\t} else {\n\t\t\t\tNode element = this.next;\n\t\t\t\tthis.next = (Node) this.next.getNextNode();\n\t\t\t\treturn (Node) element;\n\t\t\t}\n\t\t}",
"public Object getNext() {\n\t\tif (current != null) {\n\t\t\tcurrent = current.next; // Get the reference to the next item\n\t\t}\n\t\treturn current == null ? null : current.item;\n\t}",
"public E getNext() {\n\t\tif (!super.isEmpty()) {\n\t\t\tif (index >= this.size() - 1)\n\t\t\t\tindex = -1;\n\t\t\treturn this.get(++index);\n\t\t}\n\t\treturn null;\n\t}",
"public Node getNext(){\n\t\t\treturn next;\n\t\t}",
"public abstract T next() throws NoSuchElementException;",
"public Question next() {\n\t\tif (this.questions.size() == this.iter) {\n\t\t\treturn null;\n\t\t}\n\t\tQuestion q = this.questions.get(this.iter);\n\t\tthis.iter++;\n\t\treturn q;\n\t}",
"void next();",
"@Override\n\tpublic Object next() {\n\t\treturn null;\n\t}",
"@Override\r\n public BankAccount next() {\r\n \t//check if the list of the bank accounts is empty \r\n if(!hasNext())\r\n \tthrow new NoSuchElementException();\r\n //if the list is not empty remove the first link and return it \r\n else {\r\n \tcurrent = bankAccounts.get(0);\r\n \tbankAccounts.remove(0);\r\n \treturn current;\r\n }\r\n }",
"public E next(){\r\n E data = node.getData();\r\n node = node.getNext();\r\n return data;\r\n }",
"@Override\r\n\t\tpublic E next() {\n\t\t\tcaret = caret.next();\r\n\t\t\tif (caret == null)\r\n\t\t\t\tthrow new NoSuchElementException();\r\n\t\t\tnextIndex++;\r\n\t\t\treturn caret.n.data[caret.idx];\r\n\t\t}",
"T next();",
"public DNode getNext() { return next; }",
"public ListNode getNext()\r\n {\r\n return next;\r\n }",
"public T next() {\n return array[current++];\n }",
"public Record next() {\n if (hasNext()) {\n if (nextRecord != null) {\n Record out = nextRecord;\n nextRecord = null;\n return out;\n }\n }\n throw new NoSuchElementException();\n //throw new UnsupportedOperationException(\"hw3: TODO\");\n }",
"public Node getNext(){\n\t\treturn next;\n\t}",
"public ListNode<Item> getNext() {\n return this.next;\n }",
"@Override\n public Map.Entry<K, V> next() {\n if (iter.hasNext()) {\n \n lastItemReturned = iter.next();\n return lastItemReturned;\n } else {\n throw new NoSuchElementException();\n }\n }",
"public Item next() {\r\n if (!hasNext()) throw new NoSuchElementException();\r\n lastAccessed = current;\r\n Item item = current.item;\r\n current = current.next;\r\n index++;\r\n return item;\r\n }",
"public abstract void next();",
"@SuppressWarnings(\"unchecked cast\")\n @Override\n public T next() {\n if (!hasNext()) {\n throw new NoSuchElementException();\n }\n lastNext = heap[cursor++];\n return (T) lastNext;\n }",
"public Node getNext()\n {\n return this.next;\n }",
"public Node<E> getNext() {\r\n\t\treturn next;\r\n\t}",
"public node getNext() {\n\t\t\treturn next;\n\t\t}",
"public Node<T> getNext() {\n return this.next;\n }",
"public SlideNode getNext() {\n\t\treturn next;\n\t}",
"public R next(){\n return (R) listR.get(index++);\n }",
"public Node<T> getNext() {\n\t\treturn next;\n\t}",
"public Node<T> getNext()\n\t{\treturn this.next; }",
"public HL7DataTree next() {\n final int size = Util.size(this.list), i = this.next == null ? size : this.list.indexOf(this.next) + 1;\n final HL7DataTree curr = this.next;\n \n this.next = i == size ? more() : this.list.get(i);\n \n return curr;\n }",
"@Override public T next() {\n T elem = null;\n if (hasNext()) {\n Nodo<T> nodo = pila.pop();\n elem = nodo.elemento;\n nodo = nodo.derecho;\n while(nodo != null){\n pila.push(nodo);\n nodo = nodo.izquierdo;\n }\n return elem;\n }\n return elem;\n }"
] | [
"0.81542426",
"0.8041521",
"0.79856265",
"0.79847777",
"0.7944997",
"0.79245496",
"0.7916355",
"0.79003906",
"0.78778064",
"0.78626174",
"0.7844902",
"0.7824325",
"0.7794654",
"0.7794401",
"0.7773138",
"0.77446",
"0.7723263",
"0.76597846",
"0.76597846",
"0.76454574",
"0.76224315",
"0.7603126",
"0.7592803",
"0.7573012",
"0.75702405",
"0.7569883",
"0.7561284",
"0.7560526",
"0.75601363",
"0.7550236",
"0.7549999",
"0.75456065",
"0.7525235",
"0.75102717",
"0.7505419",
"0.7497479",
"0.74964154",
"0.7496028",
"0.7495445",
"0.7464",
"0.7462247",
"0.7454751",
"0.7445247",
"0.74241304",
"0.7421392",
"0.741849",
"0.7401493",
"0.7400246",
"0.73970413",
"0.7387752",
"0.73870075",
"0.7385196",
"0.736169",
"0.73398906",
"0.7338664",
"0.7329419",
"0.7329419",
"0.7320223",
"0.7318304",
"0.7317713",
"0.7305698",
"0.7304888",
"0.7296791",
"0.72894526",
"0.72859514",
"0.72856075",
"0.7285004",
"0.72846013",
"0.72846013",
"0.7276933",
"0.72759795",
"0.72612405",
"0.72556114",
"0.72547305",
"0.72539324",
"0.7252335",
"0.7241535",
"0.7236521",
"0.7236277",
"0.72355515",
"0.72348577",
"0.7229307",
"0.72269595",
"0.72260386",
"0.72222817",
"0.7210882",
"0.7204162",
"0.7203336",
"0.72006994",
"0.71974087",
"0.719023",
"0.7188705",
"0.7188021",
"0.71868575",
"0.71861506",
"0.7185899",
"0.7182752",
"0.7179086",
"0.71790004",
"0.71786076",
"0.71762526"
] | 0.0 | -1 |
prev() gets the previous DListNode that corresponds to this. | public DListNode2 prev(){
return this.prev;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public DNode getPrev() { return prev; }",
"public Node getPrev()\r\n\t{\r\n\t\treturn prev;\r\n\t}",
"public Node getPrev()\n {\n return this.prev;\n }",
"public Node getPrev() {\n return prev;\n }",
"public ListElement<T> getPrev()\n\t{\n\t\treturn prev;\n\t}",
"public DoublyLinkedNode<E> getPrevious() {\n return prevNode;\n }",
"public Node<T> getPrev() {\n\t\treturn prev;\n\t}",
"public Node<S> getPrev() { return prev; }",
"public SlideNode getPrev() {\n\t\treturn prev;\n\t}",
"public void prev() {\r\n\t\tif (curr == head)\r\n\t\t\treturn; // No previous element\r\n\t\tLink<E> temp = head;\r\n\t\t// March down list until we find the previous element\r\n\t\twhile (temp.next() != curr)\r\n\t\t\ttemp = temp.next();\r\n\t\tcurr = temp;\r\n\t}",
"public Node getPrev() {\n return null;\n }",
"public Node<T> getPrevNode() {\n\t\treturn prevNode;\n\t}",
"public NodeD getSelecPrev(){\n if (this.selec == this.head){\n return this.head;\n }else{\n this.selec = this.selec.getPrev();\n return selec;\n }\n }",
"public int getPrevNode() {\n\t\treturn this.previousNode;\n\t}",
"public Node getPrevious() {\n return previous;\n }",
"public node getPrevious() {\n\t\t\treturn previous;\n\t\t}",
"public ListElement getPrevious()\n\t {\n\t return this.previous;\n\t }",
"public E previous(){\n\t\t\tE e = tail.element;\n\t\t\tcurrent = current.next;\n\t\t\treturn e;\n\t\t}",
"public Object getPrev() {\n\t\tif (current != null) {\n\t\t\tcurrent = current.prev;\n\t\t} else {\n\t\t\tcurrent = start;\n\t\t}\n\t\treturn current == null ? null : current.item; //Ha nincs még start, akkor null adjon vissza\n\t}",
"public IDLink<T> getPrev(){\n \treturn ppointer;\n }",
"public Node<T> previous() {\r\n return previous;\r\n }",
"public DSAGraphNode<E> getPrevious()\n {\n return previous;\n }",
"public DependencyElement previous() {\n\t\treturn prev;\n\t}",
"public Vertex getPrev() {\n return prev;\n }",
"public List getPrevList() {\n\t\treturn prevList;\n\t}",
"int getPrev(int node_index) {\n\t\treturn m_list_nodes.getField(node_index, 1);\n\t}",
"public MyNode<? super E> getPrevious()\n\t{\n\t\treturn this.previous;\n\t}",
"public DoubleNode<T> getPrevious()\n {\n\n return previous;\n }",
"@Override\n public E previous() throws NoSuchElementException\n { \n if(hasPrevious() == false)\n {\n throw new NoSuchElementException();\n }\n idx = idx - 1;\n Node theNode = getNth(idx);\n left = left.prev;\n right = left;\n canRemove = false;\n forward = false;\n return theNode.getElement(); \n }",
"@Override\r\n\t\tpublic E previous() {\n\t\t\tcaret = caret.prev();\r\n\t\t\tif (caret == null)\r\n\t\t\t\tthrow new NoSuchElementException();\r\n\t\t\tnextIndex--;\r\n\t\t\treturn caret.n.data[caret.idx];\r\n\t\t}",
"public T prev() {\n cursor = ((Entry<T>) cursor).prev;\n ready = true;\n return cursor.element;\n }",
"@Override\r\n\tpublic String prev() {\n\t\tString pre;\r\n\r\n\t\tpre = p.getPrev();\r\n\r\n\t\tif (pre != null) {\r\n\t\t\tthisPrevious = true;\r\n\t\t\tinput(pre);\r\n\t\t}\r\n\t\treturn pre;\r\n\t}",
"public void setPrev(DListNode2 prev1){\r\n this.prev = prev1;\r\n }",
"public AStarNode getPrevious() {\n return previous;\n }",
"@Override\r\n\t\tpublic Node getPreviousSibling()\r\n\t\t\t{\n\t\t\t\treturn null;\r\n\t\t\t}",
"public void setPrev(ListElement<T> prev)\n\t{\n\t\tthis.prev = prev;\n\t}",
"HNode getPreviousSibling();",
"public Node setPrevNode(Node node);",
"public TreeNode getPreviousSibling ()\r\n {\r\n if (parent != null) {\r\n int index = parent.children.indexOf(this);\r\n\r\n if (index > 0) {\r\n return parent.children.get(index - 1);\r\n }\r\n }\r\n\r\n return null;\r\n }",
"protected abstract D getPrevious(D d);",
"@Override\n\tpublic Node getPreviousSibling() {\n\t\treturn null;\n\t}",
"public void prev();",
"public K prev();",
"public void setPrev(ListEntry prev) {\n if (prev != null)\n this.prev = prev;\n else\n this.prev = null;\n }",
"public void setPrevious(DoublyLinkedNode<E> prev) {\n this.prevNode = prev;\n }",
"public E previous() {\r\n current--;\r\n return elem[current];\r\n }",
"public Layer getPrevLayer() {\r\n\t\treturn this.prevLayer;\r\n\t}",
"public void setPrev(Node prev) {\n this.prev = prev;\n }",
"public T previous()\n {\n // TODO: implement this method\n return null;\n }",
"public void setPrev(DNode newPrev) { prev = newPrev; }",
"public void setPrev(Node prev)\r\n\t{\r\n\t\tthis.prev = prev;\r\n\t}",
"public void setPrev(Node<T> prev) {\n\t\tthis.prev = prev;\n\t}",
"public void Prev();",
"public IndexRecord getIteratorPrev() {\n iter = (iter == 0 ? -1 : iter - 1);\n return (iter == -1 ? null : data[iter]);\n }",
"public static Player getPrevPlayer(){\n\t\tif(players.get(curr).getPnum()==1)\n\t\t\treturn players.get(players.size()-1);\n\t\telse return players.get(curr-1);\n\t}",
"public Content getNavLinkPrevious() {\n Content li;\n if (prev != null) {\n Content prevLink = getLink(new LinkInfoImpl(configuration,\n LinkInfoImpl.Kind.CLASS, prev)\n .label(prevclassLabel).strong(true));\n li = HtmlTree.LI(prevLink);\n }\n else\n li = HtmlTree.LI(prevclassLabel);\n return li;\n }",
"public Object getPrev (Object o) {\n DoubleLinkedList e = (DoubleLinkedList) dictionary.get(o);\n if ((e == null) || (e.getPrev() == null))\n return null;\n return e.getPrev().getInfo();\n }",
"@Override\n public E getPrevious() {\n if (isCurrent() && prev != null) { return prev.getData(); }\n else { throw new IllegalStateException(\"There is no previous element.\"); }\n }",
"public ExtremeEntry previous() {\n\n\t\tsetLastReturned(getLastReturned().getPrevious());\n//\t\tnextIndex--;\n\t\tcheckForComodification();\n\t\treturn getLastReturned();\n\t}",
"private Cell findPrev(ArrayList<Cell> list, Cell current) {\r\n\t\t\tint index = isInList(list, current);\r\n\t\t\treturn list.get(index).prev;\r\n\t\t}",
"Optional<Node<UnderlyingData>> prevNode(Node<UnderlyingData> node);",
"public void setPrevious(Node p) {\n previous = p;\n }",
"private Node locatePrevNode(K key) { \n\t\tNode p = null; \n\t\tNode current = first; \n\t\twhile (current != null && current.getData().getKey().compareTo(key) < 0) {\n\t\t\tp = current; \n\t\t\tcurrent = current.getNext(); \n\t\t}\n\t\treturn p; \n\t}",
"public Vertex getPrevious(){\n return previous;\n }",
"public void previous()\n {\n if (size != 0)\n {\n current = current.previous();\n }\n\n }",
"public void setPrevious(ListElement previous)\n\t {\n\t this.previous = previous;\n\t }",
"@Field(0) \n\tpublic Pointer<uvc_processing_unit > prev() {\n\t\treturn this.io.getPointerField(this, 0);\n\t}",
"@Override\r\n public int previousIndex() {\r\n if (previous == null) {\r\n return -1;\r\n }\r\n return previousIndex;\r\n }",
"public void setPrev(Node p)\n {\n p.next = this.prev.next;\n p.prev = this.prev;\n this.prev.next = p;\n this.prev = p;\n }",
"public int getPrevious() {\n\t\treturn this.previous;\n\t}",
"public Version getPrev(){\n\t\treturn prev;\n\t}",
"public AbstractPathElement<V, E> getPrevPathElement()\r\n/* */ {\r\n/* 188 */ return this.prevPathElement;\r\n/* */ }",
"public E getPrevious() {\n\t\tif (!super.isEmpty()) {\n\t\t\tif (index <= 0)\n\t\t\t\tindex = this.size();\n\t\t\treturn this.get(--index);\n\t\t}\n\t\treturn null;\n\t}",
"public void setPrevNode(Node<T> prevNode) {\n\t\tthis.prevNode = prevNode;\n\t}",
"public T previous() {\n\t\t\tif(hasPrevious()) {\n\t\t\t\tT temp = vector.elementAt(previousPosition);\n\t\t\t\tpreviousPosition++;\n\t\t\t\tnextPosition++;\n\t\t\t\treturn temp;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tthrow new NoSuchElementException();\n\t\t\t}\n\t\t}",
"@Field(0) \n\tpublic uvc_processing_unit prev(Pointer<uvc_processing_unit > prev) {\n\t\tthis.io.setPointerField(this, 0, prev);\n\t\treturn this;\n\t}",
"public E getPrevEdge()\r\n/* */ {\r\n/* 178 */ return (E)this.prevEdge;\r\n/* */ }",
"protected D getPreviousOrSame(D d) {\n\t\t\tD prev = getPrevious(d);\n\t\t\tif (prev == null) {\n\t\t\t\treturn d;\n\t\t\t}\n\t\t\treturn prev;\n\t\t}",
"private Token previous() {\n return tokens.get(current-1);\n }",
"public Color getPrevColor(){\n\t\treturn prevColor;\n\t}",
"public E previousStep() {\r\n\t\tthis.current = this.values[Math.max(this.current.ordinal() - 1, 0)];\r\n\t\treturn this.current;\r\n\t}",
"public int previousIndex() {\r\n \treturn index - 1; \r\n }",
"public void setPrevNode(int node) {\n\t\tthis.previousNode = node;\n\t}",
"public void setPrev(SlideNode node) {\n\t\tthis.prev = node;\n\t}",
"@Nonnull\n public Optional<ENTITY> previous()\n {\n currentItem = Optional.of(items.get(--index));\n update();\n return currentItem;\n }",
"public T previous() {\r\n\t\t// aktu == null ist dann, wenn aktu einen schritt zuvor first war;\r\n\t\tif (aktu == null) {\r\n\t\t\treturn null;\r\n\t\t} else if (first.equals(aktu)) {\r\n\t\t\t// wir sind am Ende, deswegen setzen wir aktu auf null (für die\r\n\t\t\t// Abfrage oberhalb) und geben den ersten Wert zurück;\r\n\t\t\taktu = null;\r\n\t\t\treturn (T) first.getData();\r\n\t\t} else if (first.equals(aktu.getPrevious())) {\r\n\t\t\t// überprüft, ob der Knoten vor dem aktuellen der letzte ist, dass\r\n\t\t\t// hat den Grund, dass beim letzten die Methode .getPrevios eine\r\n\t\t\t// NullPointerException wirft;\r\n\t\t\taktu = first;\r\n\t\t\treturn (T) first.getNext().getData();\r\n\t\t} else {\r\n\t\t\t// das ist der Standardfall solange der nicht beim vorletzten Knoten\r\n\t\t\t// angekommen ist.\r\n\t\t\taktu = aktu.getPrevious();\r\n\t\t\treturn (T) aktu.getNext().getData();\r\n\t\t}\r\n\r\n\t}",
"private T getPredecessor(BSTNode<T> current) {\n while (current.getRight() != null) {\n current = current.getRight();\n }\n return current.getData();\n }",
"private T getPredecessor (BSTNode<T> current) {\n\t\twhile(current.getRight() != null) {\n\t\t\tcurrent = current.getRight();\n\t\t}\n\t\treturn current.getData();\n\n\t}",
"public void setPrevious(Node<T> previous) {\r\n this.previous = previous;\r\n }",
"ComponentAgent getPreviousSibling();",
"public Node getPrevNode(String hostname)\n\t{\n\t\treturn this.nodeManager.getPrevNode(hostname);\n\t}",
"public void setPrevious(DSAGraphNode<E> inPrevious)\n {\n previous = inPrevious;\n }",
"Object previous();",
"public void setPrev(String prev){\n\t\tthis.prev = prev;\n\t}",
"public void previous() {\n if (hasPrevious()) {\n setPosition(position - 1);\n }\n }",
"public Node getPrev(Node root, int key, Node prev){\n\t\tif(root==nil){\n\t\t\treturn nil;\n\t\t}\n\t\t\n\t\tif(key==root.id){\n\t\t\tif(root.left != nil){\n\t\t\t\tNode temp = root.left;\n\t\t\t\twhile(temp.right != nil){\n\t\t\t\t\ttemp = temp.right;\n\t\t\t\t}\n\t\t\t\tprev = temp;\n\t\t\t}\n\t\t\treturn prev;\n\t\t}\n\t\t\n\t\tif(key>root.id){\n\t\t\tprev = root;\n\t\t\tprev = getPrev(root.right,key,prev);\n\t\t}else{\n\t\t\tprev = getPrev(root.left,key,prev);\n\t\t}\n\t\t\n\t\treturn prev;\n\t}",
"private Tab getPrevTab() {\n int pos = mTabControl.getCurrentPosition() - 1;\n if (pos < 0) {\n pos = mTabControl.getTabCount() - 1;\n }\n return mTabControl.getTab(pos);\n }",
"public void setPrevious()\n {\n\tint currentIndex = AL.indexOf(currentObject);\n\t currentObject = AL.get(currentIndex -1);\n\t\n\t// never let currentNode be null, wrap to head\n\tif (currentObject == null)\n\t\tcurrentObject = lastObject;\n }",
"public int previousIndex()\n {\n // TODO: implement this method\n return -1;\n }",
"@Basic\n\tpublic String getPrevMove() {\n\t\treturn prev_move;\n\t}"
] | [
"0.85450405",
"0.83357096",
"0.8291084",
"0.8234557",
"0.80533034",
"0.8034113",
"0.80181223",
"0.7971181",
"0.79621375",
"0.794406",
"0.7929377",
"0.7882817",
"0.7850862",
"0.7815919",
"0.77602524",
"0.77426153",
"0.7724679",
"0.7678657",
"0.7673709",
"0.7642869",
"0.76381797",
"0.75788593",
"0.7563831",
"0.75606376",
"0.74542975",
"0.7452223",
"0.7451769",
"0.7410902",
"0.7404563",
"0.7308176",
"0.730613",
"0.7285876",
"0.72607154",
"0.721477",
"0.72048056",
"0.7200961",
"0.71817267",
"0.7175055",
"0.7155409",
"0.71147615",
"0.7092481",
"0.7071928",
"0.706917",
"0.70587915",
"0.7050291",
"0.7048173",
"0.70022017",
"0.6985491",
"0.6949205",
"0.6946222",
"0.69303393",
"0.6921933",
"0.6885285",
"0.68835306",
"0.6871132",
"0.6867113",
"0.68499327",
"0.6821423",
"0.6805849",
"0.67630804",
"0.6744278",
"0.67417324",
"0.6727747",
"0.6706573",
"0.67039365",
"0.6691829",
"0.66853166",
"0.6679935",
"0.66726583",
"0.6647145",
"0.66373265",
"0.6623716",
"0.66014105",
"0.65712327",
"0.65604204",
"0.6556762",
"0.65380883",
"0.6523184",
"0.65164286",
"0.65025985",
"0.64831895",
"0.64519334",
"0.644486",
"0.6426337",
"0.64256614",
"0.64163476",
"0.64038247",
"0.63850963",
"0.637919",
"0.6372864",
"0.63675386",
"0.63522434",
"0.6352032",
"0.63439643",
"0.63284385",
"0.6297485",
"0.6269384",
"0.62677956",
"0.6254334",
"0.62536395"
] | 0.8790844 | 0 |
setNext() sets a DListNode next1 as the next node to this. | public void setNext(DListNode2 next1){
this.next = next1;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setNext(ListNode next)\r\n {\r\n this.next = next;\r\n }",
"public void setNext(ListNode<E> next)\n {\n nextNode = next;\n }",
"public void setNext(ListNode<Item> next) {\n this.next = next;\n }",
"public void setNext(DNode newNext) { next = newNext; }",
"public void setNext(Node next) {\n this.next = next;\n }",
"public void setNext(LLNode<T> next) {\n this.next = next;\n }",
"public void setNext(SortedLinkedListNode pNode) {\n next = pNode;\n }",
"public void setNext(Node next)\r\n\t{\r\n\t\tthis.next = next;\r\n\t}",
"public void setNext(Node next){\n\t\tthis.next = next;\n\t}",
"public void setNext(Node<T> next) {\r\n this.next = next;\r\n }",
"public void setNext(Node next) {\n\t\tthis.next = next;\n\t}",
"public void setNext(Node next)\n\t{\n\t\tthis.next = next;\n\t}",
"public void setNext(SimpleNode next) {\n this.next = next;\n }",
"public void setNext(Node<T> next) {\n this.next = next;\n }",
"public void setNext(Node<T> next) {\n\t\tthis.next = next;\n\t}",
"public void setNext(ListElement next)\n\n\t {\n\t this.next = next;\n\t }",
"public void setNext(DoublyLinkedNode<E> next) {\n this.nextNode = next;\n }",
"public void setNextNode(Node<T> next) {\n itsNext = next;\n }",
"public void setNext(Node<T> another)\n\t{\tthis.next = another; }",
"public void setNext(Node<E> next) { this.next = next; }",
"public void setNext(ListEntry next) {\n if (next != null)\n this.next = next;\n else\n this.next = null;\n }",
"public void setNext(ListElement<T> next)\n\t{\n\t\tthis.next = next;\n\t}",
"public void setNext(GameNode next) {\n this.next = next;\n }",
"public void setNextNode(Node nextNode) {\n this.nextNode = nextNode;\n }",
"public void setNext(Node n) { next = n; }",
"public void setNext(Node<D> n){\n\t\tnext = n;\n\t}",
"public void setNext(Node newNode){\n\t\t\tnext = newNode;\n\t\t}",
"public void setNextNode(Node<T> nextNode) {\n\t\tthis.nextNode = nextNode;\n\t}",
"public void setNext(Node n) {\n next = n;\n }",
"public void setNext(ObjectListNode p) {\n next = p;\n }",
"void setNext (ListNode newNext) { /* package access */ \n\t\tnext = newNext;\n\t}",
"public void setNext(Node n)\r\n\t{\r\n\t\tnext = n;\r\n\t}",
"public void setNext(LinearNode<T> node) {\r\n\t\t\r\n\t\tnext = node;\r\n\t\t\r\n\t}",
"public void setNext(final LinkedNode<T> theNode) {\n\t myNextNode = theNode;\n }",
"public boolean setNext (\n\t\t\tfinal ListNode<V> next)\n\t\t{\n\t\t\t_next = next;\n\t\t\treturn true;\n\t\t}",
"public void setNextNode(Node newnext)\n {\n next = newnext;\n }",
"public void setNext(DoubleNode<T> node)\n {\n\n next = node;\n }",
"public void setNext(Node node)\n\t{\n\t\tnodeLinks.setNext(node);\n\t}",
"public void setNext(MyNode<? super E> _next)\n\t{\n\t\tthis.next = _next;\n\t\t//this.next = _next;\n\t}",
"public Node setNextNode(Node node);",
"public void setNext(Version next){\n\t\tif (next == null){\n\t\t\tLog.e(NAME, \"Invalid parameters for 'setNext' method!\");\n\t\t\treturn;\n\t\t}\n\t\tthis.next = next;\n\t}",
"public void setNext(Linkable nextObject);",
"public void setNext(Vertex next) {\n\t\tthis.next = next;\n\t}",
"private void setNext(Node n) {\n\t\t\tnext = n;\n\t\t}",
"void setNext(Cell next) {\n if (this.next == null) {\n this.next = next;\n }\n }",
"@Override\n public void setNextElement(helpDesk next) {\n this.next = next;\n }",
"void setNext(HashNode newNext){\n\t\tnext = newNext; \n\t}",
"public DListNode2 next(){\r\n return this.next;\r\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }",
"public boolean SetNext(List v_next){\n\tnext = v_next ;\n\treturn true ;\n }"
] | [
"0.76578563",
"0.754305",
"0.7504752",
"0.7456251",
"0.74450475",
"0.7400928",
"0.73983747",
"0.739708",
"0.73311424",
"0.73281944",
"0.73142433",
"0.73042995",
"0.7302645",
"0.72955626",
"0.7251533",
"0.7229072",
"0.7223858",
"0.7176413",
"0.7155717",
"0.7108662",
"0.7096032",
"0.70726323",
"0.70502335",
"0.7044313",
"0.7008296",
"0.70006526",
"0.69990355",
"0.68779147",
"0.686786",
"0.68590575",
"0.6854304",
"0.68401545",
"0.6804528",
"0.6796334",
"0.67713803",
"0.6757298",
"0.67360586",
"0.67062753",
"0.6700161",
"0.66758126",
"0.664742",
"0.66109174",
"0.66107213",
"0.66031796",
"0.65187347",
"0.64163977",
"0.64127886",
"0.639643",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6308466",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944",
"0.6307944"
] | 0.8456417 | 0 |
setPrev() sets a DListNode prev1 as the prev node to this. | public void setPrev(DListNode2 prev1){
this.prev = prev1;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setPrev(Node prev) {\n this.prev = prev;\n }",
"public void setPrev(Node prev)\r\n\t{\r\n\t\tthis.prev = prev;\r\n\t}",
"public void setPrev(DNode newPrev) { prev = newPrev; }",
"public void setPrev(Node<T> prev) {\n\t\tthis.prev = prev;\n\t}",
"public void setPrev(ListEntry prev) {\n if (prev != null)\n this.prev = prev;\n else\n this.prev = null;\n }",
"public void setPrev(ListElement<T> prev)\n\t{\n\t\tthis.prev = prev;\n\t}",
"public void setPrevious(DoublyLinkedNode<E> prev) {\n this.prevNode = prev;\n }",
"public void setPrevNode(Node<T> prevNode) {\n\t\tthis.prevNode = prevNode;\n\t}",
"public void setPrev(Node p)\n {\n p.next = this.prev.next;\n p.prev = this.prev;\n this.prev.next = p;\n this.prev = p;\n }",
"public Node setPrevNode(Node node);",
"public void setPrev(SlideNode node) {\n\t\tthis.prev = node;\n\t}",
"public void setPrev(Version prev){\n\t\tif (prev == null){\n\t\t\tLog.e(NAME, \"Invalid parameters for 'setPrev' method!\");\n\t\t\treturn;\n\t\t}\n\t\tthis.prev = prev;\n\t}",
"public void setPrev(String prev){\n\t\tthis.prev = prev;\n\t}",
"public\tvoid setprevious (SNode previous) {\r\n\t\tthis.previous=previous;\r\n\t}",
"public void setPrevious(ListElement previous)\n\t {\n\t this.previous = previous;\n\t }",
"public void setPrevNode(int node) {\n\t\tthis.previousNode = node;\n\t}",
"public void setPrevious(Node p) {\n previous = p;\n }",
"public void setPrevious(Node<T> previous) {\r\n this.previous = previous;\r\n }",
"public void setPrevCell(Cell prev)\r\n {\r\n this.prev = prev;\r\n }",
"public void setPrev(Level previous) {\n\t\tthis.prev = previous;\n\t}",
"public void setPrev(Position pos) {\n prev = pos;\n }",
"public void setPrevList(List prevList) {\n\t\tthis.prevList = prevList;\n\t}",
"public void prev() {\r\n\t\tif (curr == head)\r\n\t\t\treturn; // No previous element\r\n\t\tLink<E> temp = head;\r\n\t\t// March down list until we find the previous element\r\n\t\twhile (temp.next() != curr)\r\n\t\t\ttemp = temp.next();\r\n\t\tcurr = temp;\r\n\t}",
"public DListNode2 prev(){\r\n return this.prev;\r\n }",
"public void setPrevious(DSAGraphNode<E> inPrevious)\n {\n previous = inPrevious;\n }",
"public void setPrev(IDLink<T> c){\n \tppointer = c;\n }",
"public void setPrevious(MyNode<? super E> _previous)\n\t{\n\t\tthis.previous = _previous;\n\t\t//this.previous = _previous;\n\t}",
"public DNode getPrev() { return prev; }",
"public void setPrevious(AStarNode previous) {\n this.previous = previous;\n }",
"public void setPrevious(DoubleNode<T> node)\n {\n\n previous = node;\n }",
"public void setPrevColor(Color prevColor){\n\t\tthis.prevColor=prevColor;\n\t}",
"public void setPrevious(Vertex v){\n previous = v;\n }",
"public void setPrevious()\n {\n\tint currentIndex = AL.indexOf(currentObject);\n\t currentObject = AL.get(currentIndex -1);\n\t\n\t// never let currentNode be null, wrap to head\n\tif (currentObject == null)\n\t\tcurrentObject = lastObject;\n }",
"void prevSet(Entry e) {\r\n\t\t\tprev = e;\r\n\t\t}",
"public SlideNode getPrev() {\n\t\treturn prev;\n\t}",
"@Field(0) \n\tpublic uvc_processing_unit prev(Pointer<uvc_processing_unit > prev) {\n\t\tthis.io.setPointerField(this, 0, prev);\n\t\treturn this;\n\t}",
"public Node getPrev() {\n return prev;\n }",
"public void setPrevHashValue(String prevHashValue) {\n this.prevHashValue = prevHashValue;\n }",
"public Node getPrev()\r\n\t{\r\n\t\treturn prev;\r\n\t}",
"public void setPreviousState(State prevState)\r\n\t{\r\n\t\tthis.previousState = new State();\r\n\t\tthis.previousState = prevState;\r\n\t}",
"public Node getPrev()\n {\n return this.prev;\n }",
"@Model \n\tprotected void setPrevMove(String prev_move) {\n\t\tassert((prev_move == \"\") || (prev_move == \"left\") || (prev_move == \"right\"));\n\t\t\n\t\tthis.prev_move = prev_move;\n\t}",
"public void setPreviousElement(Element<T> previousElement) \n\t{\n\t\tthis.previousElement = previousElement;\n\t}",
"public void setPrev_guestgui(Guest_GUI prev_guestgui) {\n this.prev_guestgui = prev_guestgui;\n }",
"public Node<S> getPrev() { return prev; }",
"public void prev();",
"public void prevSlide() {\n\t\tif (currentSlideNumber > 0) {\n\t\t\tsetSlideNumber(currentSlideNumber - 1);\n\t }\n\t}",
"public Node<T> getPrev() {\n\t\treturn prev;\n\t}",
"public void prev()\n {\n if (mHistoryIdx == 0) {\n return;\n }\n\n mCommandList.get(--mHistoryIdx).undo();\n this.setChanged();\n this.notifyObservers(mHistoryIdx);\n }",
"public Node getPrev() {\n return null;\n }",
"public Node<T> getPrevNode() {\n\t\treturn prevNode;\n\t}",
"public Vertex getPrev() {\n return prev;\n }",
"@Override\r\n\tpublic String prev() {\n\t\tString pre;\r\n\r\n\t\tpre = p.getPrev();\r\n\r\n\t\tif (pre != null) {\r\n\t\t\tthisPrevious = true;\r\n\t\t\tinput(pre);\r\n\t\t}\r\n\t\treturn pre;\r\n\t}",
"public void setPrev_hostgui(Host_GUI prev_hostgui) {\n this.prev_hostgui = prev_hostgui;\n }",
"public void previous() {\n if (hasPrevious()) {\n setPosition(position - 1);\n }\n }",
"public final double setPrev\r\n ( DataID dID // input\r\n , double value // input\r\n )\r\n {\r\n double result = 0.0;\r\n \r\n // &&& There must be a better way than this...\r\n switch ( dID )\r\n {\r\n case DATA_A:\r\n result = set( DataID.DATA_B, value );\r\n break;\r\n case DATA_B:\r\n result = set( DataID.DATA_C, value );\r\n break;\r\n case DATA_C:\r\n result = set( DataID.DATA_A, value );\r\n break;\r\n default:\r\n System.out.printf( \"TriangleData.setPrev() called with %d\\n\"\r\n , dID.ordinal()\r\n ); \r\n } // switch\r\n\r\n return result;\r\n \r\n }",
"public void Prev();",
"void setPrevPos(Vec3 pos);",
"public List getPrevList() {\n\t\treturn prevList;\n\t}",
"public void setPrevWeek()\n\t{\n\t\tm_calendar.set(Calendar.WEEK_OF_MONTH,getWeekOfMonth()-1);\n\n\t}",
"public void previous()\n {\n if (size != 0)\n {\n current = current.previous();\n }\n\n }",
"public NodeD getSelecPrev(){\n if (this.selec == this.head){\n return this.head;\n }else{\n this.selec = this.selec.getPrev();\n return selec;\n }\n }",
"public void setNext(DListNode2 next1){\r\n this.next = next1;\r\n }",
"public ListElement<T> getPrev()\n\t{\n\t\treturn prev;\n\t}",
"public Object getPrev() {\n\t\tif (current != null) {\n\t\t\tcurrent = current.prev;\n\t\t} else {\n\t\t\tcurrent = start;\n\t\t}\n\t\treturn current == null ? null : current.item; //Ha nincs még start, akkor null adjon vissza\n\t}",
"public int getPrevNode() {\n\t\treturn this.previousNode;\n\t}",
"public DoublyLinkedNode<E> getPrevious() {\n return prevNode;\n }",
"public DependencyElement previous() {\n\t\treturn prev;\n\t}",
"public IDLink<T> getPrev(){\n \treturn ppointer;\n }",
"public void setLinkedNodes(Node prevNode, Node nextNode)\n\t{\n\t\tnodeLinks.setPrev(prevNode);\n\t\tnodeLinks.setNext(nextNode);\n\t}",
"public final void setPredecessor(final Rule r) {\n //ELM: in again!\n m_pred = r;\n }",
"void movePrev()\n\t{\n\t\tif (cursor != null) \n\t\t{\n\t\t\tif (cursor == front) \n\t\t\t{\n\t\t\t\tcursor = null;\n index = -1; //added this because i kept failing the test cases on the grading script\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tcursor = cursor.prev; //moves cursor toward front of the list\n index--; //added this because i kept failing the test cases on the grading script\n\t\t\t}\n\t\t}\n\t}",
"public Version getPrev(){\n\t\treturn prev;\n\t}",
"public void setPreviousValue(final String previousValue);",
"public void setFront(Node front){\n this.front = front;\n }",
"@Override\r\n\tpublic void setPredecessor(VertexInterface<T> predecessor) {\n\r\n\t}",
"public Node<T> previous() {\r\n return previous;\r\n }",
"public void setPreviousPosition(int previousPosition)\n\t{\n\t\tsomethingChanged = true;\n\t\tthis.previousPosition = previousPosition;\n\t}",
"private final void setPredecessor(_Node end, _Node start)\r\n {\r\n \tList<_Node> listNodes = null;\r\n \tif(predecessors.containsKey(end))\r\n \t{\r\n \t\tif(!predecessors.get(end).contains(start))\r\n \t\t{\r\n \t\t\tpredecessors.get(end).add(start);\r\n \t\t\tlistNodes = predecessors.get(end);\r\n \t\t\tpredecessors.put(end, listNodes);\r\n \t\t}\r\n \t}\r\n \telse\r\n \t{\r\n \t\tlistNodes = new ArrayList<_Node>();\r\n \t\tlistNodes.add(start);\r\n \t\tpredecessors.put(end, listNodes);\r\n \t}\r\n }",
"public node getPrevious() {\n\t\t\treturn previous;\n\t\t}",
"public Node getPrevious() {\n return previous;\n }",
"public Layer(Layer prevLayer) {\r\n\t\tthis.prevLayer = prevLayer; //Set the previous layer\r\n\t}",
"public void removeSelf(){\n\t\tif(prev != null){\n\t\t\tprev.next = next;\n\t\t\tnext.prev = prev;\n\t\t\tprev = null;\n\t\t\tnext = null;\n\t\t}\n\t}",
"public void setPath(int sender, Stack<Integer> prevPath)\n { \n if (prevPath.isEmpty() || prevPath.peek()!=sender)\n prevPath.push(sender);\n path = (Stack)prevPath.clone();\n }",
"public void setPreviousHop(int previousHop) {\n this.previousHop = previousHop;\n }",
"private void prevPage()\n {\n if(currentPage - 1 >= 1)\n {\n nextPageButton.setEnabled(true);\n if(currentPage -2 < 1)\n prevPageButton.setEnabled(false);\n \n paginate(--currentPage, getResultsPerPage());\n updatePageLabel(currentPage, maxPage);\n }\n }",
"public void setPriorNode(Node<T> prior) {\n\t\t\titsPrior = prior;\n }",
"int getPrev(int node_index) {\n\t\treturn m_list_nodes.getField(node_index, 1);\n\t}",
"public Layer getPrevLayer() {\r\n\t\treturn this.prevLayer;\r\n\t}",
"public void pushFront(DoubleLinkedList other) {\n\n\t\tDoubleLinkedList l = other.clone();\n\t\tDLNode n = l.tail;\n\n\t\tfor (int i = 0; i < l.nodeCounter(); i++) {\n\n\t\t\tif (n.val != Integer.MIN_VALUE) {\n\t\t\t\tthis.pushFront(n.val);\n\t\t\t} else {\n\t\t\t\tthis.pushFrontRecursive(n.list);\n\t\t\t}\n\t\t\tn = n.prev;\n\t\t}\n\t}",
"public ListElement getPrevious()\n\t {\n\t return this.previous;\n\t }",
"public void setNext(Node n)\n {\n n.prev = this.next.prev;\n n.next = this.next;\n this.next.prev = n;\n this.next = n;\n }",
"public Node getPrev(Node root, int key, Node prev){\n\t\tif(root==nil){\n\t\t\treturn nil;\n\t\t}\n\t\t\n\t\tif(key==root.id){\n\t\t\tif(root.left != nil){\n\t\t\t\tNode temp = root.left;\n\t\t\t\twhile(temp.right != nil){\n\t\t\t\t\ttemp = temp.right;\n\t\t\t\t}\n\t\t\t\tprev = temp;\n\t\t\t}\n\t\t\treturn prev;\n\t\t}\n\t\t\n\t\tif(key>root.id){\n\t\t\tprev = root;\n\t\t\tprev = getPrev(root.right,key,prev);\n\t\t}else{\n\t\t\tprev = getPrev(root.left,key,prev);\n\t\t}\n\t\t\n\t\treturn prev;\n\t}",
"public void prev() {\n\t\tsynchronized (this) {\n\t\t\tint pos = getPreShuffledPos();\n\t\t\tif (pos > 0) {\n\t\t\t\tmPlayPos = mPlayOrder[pos - 1];\n\t\t\t} else {\n\t\t\t\tmPlayPos = mPlayOrder[mPlayListLen - 1];\n\t\t\t}\n\t\t\tstop(false);\n\t\t\tprepareAndPlayCurrent();\n\t\t}\n\t}",
"public void setNext(Vertex next) {\n\t\tthis.next = next;\n\t}",
"public Item setFront(Item item) {\n // check if list is not empty:\n if(isEmpty()) throw new NoSuchElementException(\"Failed to setFront, because DList is empty!\");\n // update the data of the first actual node (first itself is a sentinel node)\n Item oldValue = first.next.data;\n first.next.data = item;\n return oldValue;\n }",
"public K prev();",
"public void previousSlide() {\r\n\t\tpresentation.prevSlide();\r\n\t}",
"public DequeNode(DequeNode<T> next, T value, DequeNode<T> prev) {\n this.next = next;\n this.value = value;\n this.prev = prev;\n }",
"public DSAGraphNode<E> getPrevious()\n {\n return previous;\n }"
] | [
"0.83510107",
"0.83268785",
"0.8157075",
"0.80953974",
"0.8022872",
"0.79652846",
"0.7901918",
"0.757924",
"0.753811",
"0.74881655",
"0.72969997",
"0.7266988",
"0.7250001",
"0.72157323",
"0.72030765",
"0.7169839",
"0.70970535",
"0.7074867",
"0.70605135",
"0.70130265",
"0.69677705",
"0.69529325",
"0.6855741",
"0.67885435",
"0.6783102",
"0.6758052",
"0.6569677",
"0.6565062",
"0.6546043",
"0.64641905",
"0.63556015",
"0.62680995",
"0.6254938",
"0.615319",
"0.61470497",
"0.6144688",
"0.6132194",
"0.61175615",
"0.6110998",
"0.6092889",
"0.60566205",
"0.60204506",
"0.6006053",
"0.5862364",
"0.5836677",
"0.580493",
"0.5790521",
"0.5772877",
"0.5760987",
"0.5736707",
"0.5736266",
"0.5716167",
"0.5710772",
"0.57096416",
"0.5695494",
"0.5676703",
"0.5656991",
"0.56529784",
"0.5604777",
"0.5591852",
"0.5581067",
"0.55783576",
"0.55680346",
"0.5564063",
"0.55554634",
"0.55395097",
"0.55202454",
"0.55182135",
"0.5497621",
"0.54748094",
"0.5467552",
"0.54636204",
"0.5440658",
"0.5412113",
"0.5405289",
"0.5375577",
"0.5355402",
"0.5344601",
"0.5308556",
"0.530034",
"0.5294308",
"0.5205675",
"0.5197825",
"0.5193735",
"0.5192858",
"0.51906276",
"0.5178806",
"0.51574016",
"0.5157185",
"0.5156429",
"0.51372796",
"0.5125909",
"0.5115588",
"0.510887",
"0.5105857",
"0.51051706",
"0.50976616",
"0.50935626",
"0.50825256",
"0.5054643"
] | 0.891098 | 0 |
This sets the corresponding list field to list1. | public void setList(DList2 list1){
list = list1;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setListData(int list, int data) {\n\t\tm_lists.setField(list, 5, data);\n\t}",
"public void setList(DOCKSList param) {\r\n localListTracker = param != null;\r\n\r\n this.localList = param;\r\n }",
"public static void fillArrayList(List<String> list1){\n\t\tlist1.add(new String(\"Will\"));\n\t\tlist1.add(new String(\"John\"));\n\t\tlist1.add(new String(\"James\"));\n\t\tlist1.add(new String(\"Frank\"));\n\t\tlist1.add(new String(\"Fred\"));\n\t\tlist1.add(new String(\"Jake\"));\n\t\tlist1.add(new String(\"Winston\"));\n\t\tlist1.add(new String(\"Wally\"));\n\t\tlist1.add(new String(\"Karen\"));\n\t\tlist1.add(new String(\"Mary\"));\n\t\tlist1.add(new String(\"Michelle\"));\n\t\tlist1.add(new String(\"Micheal\"));\n\t\tlist1.add(new String(\"Mick\"));\n\t\tlist1.add(new String(\"Valdez\"));\n\t}",
"public void setList(List<Integer> list) {\n this.list = list;\n }",
"void setListProperty(Object name, List<Object> list) throws JMSException;",
"public final void accept(List<l> list) {\n com.iqoption.core.data.b.c a = this.dlr.dlm;\n kotlin.jvm.internal.h.d(list, \"it\");\n a.setValue(list);\n }",
"public void setList(List<ListItem> list) {\n this.items = list;\n\n Log.d(\"ITEMs\",items+\"\");\n }",
"public void setListProperty(List<Integer> t) {\n\n\t\t}",
"public void setList_Base (String List_Base);",
"public void setAs(ElementList<E> list) {\r\n\t\tthis.makeEmpty();\r\n\t\theader.next = list.first();\r\n\t\tlast = list.last;\r\n\t}",
"private void modify(List listString){\n\t}",
"public MultiList(int listType){\n this.listType = listType;\n }",
"public void setItems(List<T> value) {\n getElement().setItems(SerDes.mirror(value).cast());\n }",
"public void setList(java.util.List newAktList) {\n\t\tlist = newAktList;\n\t}",
"public void setListItems(List<String> lit) { mItems = lit; }",
"public void setListName(java.lang.String listName) {\r\n this.listName = listName;\r\n }",
"public void setUpList(List upList) {\n\t\tthis.upList = upList;\n\t}",
"public abstract java.util.Vector setDB2ListItems();",
"public void asignar_Lista(Lista<Lado> l) {\n\t\tthis.list = l;\n\t}",
"public abstract void setList(List<T> items);",
"public Immutable(int field1, MutableField field3, List<String> list) {\n this.field1 = field1;\n this.field3 = field3;\n this.list = Collections.unmodifiableList(list);\n //this.list.add(\"\"); // UnsupportedOperationException\n }",
"public void setList(ArrayList<CounterModel> list) {\n\t\tthis.list = list;\n\t}",
"public void setListCounter(int listCounter) {\n this.listCounter = listCounter;\n }",
"public void m(List<?> list) {\n\t}",
"public void setTypeBoundList(List<Access> list) {\n setChild(list, 2);\n }",
"public DocumentBodyBlock list(DocumentBodyList list) {\n this.list = list;\n return this;\n }",
"public void setListOfTimes(ArrayList<Long> list)\r\n {\r\n //Check if the new list times is empty before setting the new list of times\r\n if(list.isEmpty())\r\n {\r\n //Outputs a warning message \r\n System.out.println(\"WARNING: You cannot assign a empty list of times\");\r\n }\r\n else \r\n {\r\n if(this.listOfTimes.isEmpty())\r\n {\r\n this.listOfTimes.addAll(list);\r\n }\r\n else \r\n {\r\n this.listOfTimes.clear();\r\n this.listOfTimes.addAll(0, list);\r\n }//end if \r\n }//end if\r\n }",
"public void updateList(List<?> listOfObjects){\n this.radioObjects = listOfObjects;\n }",
"public void updateItemsList(List<Image> list) {\n\n\t\tthis.itemsList = list;\n\n\t}",
"public static void setList(CustomerList list){\n\t\tUserInterface.list = list;\n\t}",
"private static void m2800a(List list, List list2) {\n for (int i = 0; i < list.size(); i++) {\n Uri uri = ((bcd) list.get(i)).f3233a;\n if (uri != null && !list2.contains(uri)) {\n list2.add(uri);\n }\n }\n }",
"public void setAddressList(List addressList) {\r\n this.addressList = addressList;\r\n }",
"public void setListLatLon(java.lang.String listLatLon)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(LISTLATLON$0, 0);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(LISTLATLON$0);\n }\n target.setStringValue(listLatLon);\n }\n }",
"public List getList1(List<String> list,String a) {\n\t\tlist.add(a);\r\n\t\treturn list;\r\n\t}",
"public void setNewFieldOrder(List<Field> newOrder)\n\t{\n\t\tif (newOrder.size()!=fieldList.size())\n\t\t\tthrow new IllegalArgumentException(\"Field lists have different sizes\");\n\t\tfor (Field f: newOrder)\n\t\t\tif (!fieldList.contains(f))\n\t\t\t\tthrow new IllegalArgumentException(\"New field list has unexpected field: \"+f);\n\t\tfieldList=newOrder;\n\t}",
"@Test\r\n public void testListPropertyBindingToListProperty() {\r\n ObservableList<String> list = createObservableList(true);\r\n ListProperty<String> p1 = new SimpleListProperty<>(list);\r\n ListProperty<String> p2 = new SimpleListProperty<>(list);\r\n p2.bind(p1);\r\n assertSame(\"sanity, same list bidi-bound\", list, p2.get());\r\n ObservableList<String> other = createObservableList(true);\r\n ChangeReport report = new ChangeReport(p2);\r\n p1.set(other);\r\n assertEquals(\"RT-38770 - bind 2 ListProperties\", 1, report.getEventCount());\r\n }",
"public void mo9493a(List<String> list) {\n this.f1513b = list;\n }",
"public void updateList(List<DiscountDTO> list) {\n\t\tthis.discountRegister = list;\n\t}",
"public void setWeitereVerwendungszwecke(String[] list) throws RemoteException;",
"public void resetListId( )\n {\n _listIdRefCertificationLevels = new ArrayList<>( );\n }",
"private List<View> m9533a(List<View> list, List<View> list2) {\n LinkedList linkedList = new LinkedList();\n if (list != null && !list.isEmpty()) {\n int size = list.size();\n for (int i = 0; i < size; i++) {\n linkedList.add(list.get(i));\n }\n }\n if (list2 != null && !list2.isEmpty()) {\n int size2 = list2.size();\n for (int i2 = 0; i2 < size2; i2++) {\n linkedList.add(list2.get(i2));\n }\n }\n return linkedList;\n }",
"public void setEditList(List<StepModel> stepList){\n //Guardamos el tamaña de la lista a modificar\n int prevSize = this.stepModelList.size();\n //Limpiamos la lista\n this.stepModelList.clear();\n //Si la lista que me pasan por parámtro es nula, la inicializo a vacia\n if(stepList == null) stepList = new ArrayList<>();\n //Añado la lista que me pasan por parámetro a la lista vaciada\n this.stepModelList.addAll(stepList);\n //Notifico al adaptador que el rango de item se ha eliminado\n notifyItemRangeRemoved(0, prevSize);\n //Notifico que se ha insertado un nuevo rango de items\n notifyItemRangeInserted(0, stepList.size());\n }",
"void setList(ArrayList<UserContactInfo> contactDeatailsList);",
"public static final void setWhitelist(final WhiteList listType, final String list) {\n setWhitelist(p(), listType, list);\n }",
"public void setList(List<Product> list) {\n\t\tcellTable.setList(list);\n\t}",
"@Override\n\tpublic void setField1(java.lang.String field1) {\n\t\t_second.setField1(field1);\n\t}",
"public void setPriceList(long value) {\r\n this.priceList = value;\r\n }",
"public void replaceListOfArticles(List<Article> list) {\n this.listOfArticles = list;\n }",
"protected void setRefList( ReferenceList refList )\n {\n _refList = refList;\n }",
"@SuppressWarnings(\"unchecked\")\n\tpublic void set_List_Of_Product_Type_Of_Store_One()\n\t{\n\t\tArrayList<Product> Product_Of_Store_One = new ArrayList<Product>(); /* ArrayList Of Product */\n\t\tArrayList<String> String_Product_Of_Store_One = new ArrayList<String>(); /* ArrayList Of The String Of The Product */\n\t\tArrayList<Product> temp_Product_Of_Store_One = (ArrayList<Product>)CompanyManagerUI.Object_From_Comparing_For_Store_1.get(4);\t\n\t\t\n\t\tfor(int i = 0 ; i < temp_Product_Of_Store_One.size() ; i++)\n\t\t{\n\t\t\tProduct_Of_Store_One.add(temp_Product_Of_Store_One.get(i));\n\t\t}\n\t\t\n\t\tfor(int i = 0 ; i < Product_Of_Store_One.size() ; i++)\n\t\t{\n\t\t\tString_Product_Of_Store_One.add(String.valueOf(Product_Of_Store_One.get(i).getQuantity()) + \" ---> \" + String.valueOf(Product_Of_Store_One.get(i).getpType()));\n\t\t}\n\t\t\n\t\tProduct_Of_Store_1 = FXCollections.observableArrayList(String_Product_Of_Store_One);\n\t\tListViewQuantity_Store_1.setItems(Product_Of_Store_1);\n\t}",
"public Builder setIsList(boolean value) {\n\n isList_ = value;\n bitField0_ |= 0x00000008;\n onChanged();\n return this;\n }",
"public void setListData(List<MessageListItem> listData) {\n if (DEBUG) Timber.v(\"setListData, Size: %s\", listData == null ? \"null\" : listData.size());\n this.listData = listData;\n notifyDataSetChanged();\n }",
"public Builder setIsList(boolean value) {\n\n isList_ = value;\n bitField0_ |= 0x00000004;\n onChanged();\n return this;\n }",
"public void setList(ArrayList<Song> theSongs) {\n songs1 = theSongs;\n songsNumber = songs1.size();\n }",
"public void xsetListLatLon(gov.weather.graphical.xml.dwmlgen.schema.dwml_xsd.ListLatLonType listLatLon)\n {\n synchronized (monitor())\n {\n check_orphaned();\n gov.weather.graphical.xml.dwmlgen.schema.dwml_xsd.ListLatLonType target = null;\n target = (gov.weather.graphical.xml.dwmlgen.schema.dwml_xsd.ListLatLonType)get_store().find_element_user(LISTLATLON$0, 0);\n if (target == null)\n {\n target = (gov.weather.graphical.xml.dwmlgen.schema.dwml_xsd.ListLatLonType)get_store().add_element_user(LISTLATLON$0);\n }\n target.set(listLatLon);\n }\n }",
"@Override\n public void refreshList(ArrayList<String> newList){\n }",
"private void m1088a(List<Integer> list) {\n this.f688c = list;\n }",
"public void setUserList(CopyOnWriteArrayList<User> userList) {\r\n\t\tBootstrap.userList = userList;\r\n\t}",
"public static void setFriendsList(FriendsList fl) {\r\n\t\tfriendsList = fl; \r\n\t}",
"public DList2 list(){\r\n return this.list;\r\n }",
"void m6863a(List<Venue> list) {\n this.f5238i = list;\n }",
"public void setListId(int listId) throws ItemException\n {\n if (listId > 0)\n {\n this.listId = listId;\n }\n else\n {\n Throwable t = new Throwable(\n \"ERROR setListId: the listId value is not a valid positive integer.\");\n throw new ItemException(\"There was a problem with the listId value to be set.\", t);\n }\n }",
"public void setCurrentListToBeUndoneList();",
"public void setCommentsList(EList newValue);",
"public void setCommentsList(EList newValue);",
"public void addListObject(List<Student> list2)\r\n\t{\r\n\t\tlist2.add(s7);\r\n\t\tSystem.out.println();\r\n\t\tSystem.out.println(\"after adding\");\r\n\t\tfor(Student e:list2)\r\n\t\t{\r\n\t\t\tSystem.out.println(e);\r\n\t\t}\r\n\t}",
"public void updateList(List<T> ListObject) throws DaoException;",
"private void actualizarLista(ArrayList<Producto> p2) {\n\t\tString[] str = new String[p2.size()];\n\t\tfor (int i = 0; i < p2.size(); i++) {\n\t\t\tstr[i] = p2.get(i).get_nombre();\n\t\t}\n\t\tstr.clone();\n\t\tlistaProductos.setModel(new javax.swing.AbstractListModel<String>() {\n\t\t\tString[] strings = str.clone();\n\n\t\t\tpublic int getSize() {\n\t\t\t\treturn strings.length;\n\t\t\t}\n\n\t\t\tpublic String getElementAt(int i) {\n\t\t\t\treturn strings[i];\n\t\t\t}\n\t\t});\n\t\t/*informacion.setText(\"Precio:\\t\" + p2.get(0).get_nombre() + \"\\n\"\n\t\t\t\t+ \"Plataforma:\\t\" + p2.get(0).get_genero() + \"\\nPrecio:\\t\"\n\t\t\t\t+ Double.toString(p2.get(0).get_precio()));*/\n\t\tlistaProductos.addListSelectionListener(new ListSelectionListener() {\n\n\t\t\t@Override\n\t\t\tpublic void valueChanged(ListSelectionEvent e) {\n\t\t\t\tif (!e.getValueIsAdjusting()) {\n\t\t\t\t\tinformacion.setText(obtenerInfo(listaProductos.getSelectedValue().toString()));\n\t\t\t\t\ttextoValoraciones.setText(obtenerValoraciones(listaProductos.getSelectedValue().toString()));\n\t\t\t\t\t\n\t\t\t\t}\n\n\t\t\t}\n\t\t});\n\t}",
"@Override\n\tpublic final void setListUsers(final IntListUsers list) {\n\t\tthis.listUsers = list;\n\t}",
"int getListData(int list) {\n\t\treturn m_lists.getField(list, 5);\n\t}",
"public void setData(java.util.List data) {\r\n this.data = data;\r\n }",
"@Override\n\t\tpublic void onUserListUpdate(User arg0, UserList arg1) {\n\t\t\t\n\t\t}",
"public void setListNodes (ArrayList<Node> list){\r\n this.listNodes = list;\r\n }",
"protected void setListContext(MessageListContext listContext) {\n if (Objects.equal(listContext, mListContext)) {\n return;\n }\n\n if (Email.DEBUG && Logging.DEBUG_LIFECYCLE) {\n Log.i(Logging.LOG_TAG, this + \" setListContext: \" + listContext);\n }\n mListContext = listContext;\n }",
"private void fillList(JList aListComponent,ArrayList<String> theList) {\n DefaultListModel itsModel = new DefaultListModel();\n aListComponent.setModel(itsModel);\n for(String anItem : theList){\n itsModel.addElement(anItem);\n }\n aListComponent.setModel(itsModel);\n }",
"public void setListSynchronsprecher( List<Person> listSynchronsprecher ) {\n\t\tthis.listSynchronsprecher.clear();\n\t\tthis.listSynchronsprecher.addAll( listSynchronsprecher );\n\t}",
"public void mo9497b(List<String> list) {\n this.f1514c = list;\n }",
"public void setRoles(RoleList list) {\n if (list != null) {\n\n roleList = new RoleList();\n\n for (Iterator<?> roleIter = list.iterator();\n roleIter.hasNext();) {\n Role currRole = (Role)(roleIter.next());\n roleList.add((Role)(currRole.clone()));\n }\n } else {\n roleList = null;\n }\n return;\n }",
"@Test\r\n public void testListPropertyAdapterSetEqualListOnObjectProperty() {\r\n ObservableList<String> list = createObservableList(true);\r\n ObjectProperty<ObservableList<String>> objectProperty = new SimpleObjectProperty<>(list);\r\n ListProperty<String> listProperty = listProperty(objectProperty);\r\n ObservableList<String> otherList = createObservableList(true);\r\n ChangeReport report = new ChangeReport(listProperty);\r\n objectProperty.set(otherList);\r\n assertEquals(\"must fire change on setting list to objectProperty\", 1, report.getEventCount());\r\n }",
"public void updateListView(List<Event> list) {\n this.eventsList = list;\n notifyDataSetChanged();\n }",
"public UnmodifiableFloatList(FloatList l) {\r\n super(l);\r\n }",
"public void setPrevList(List prevList) {\n\t\tthis.prevList = prevList;\n\t}",
"public void setRoomList(ArrayList<RoomList> RoomList) {\r\n this.RoomList = RoomList;\r\n }",
"static void swap(List l, int i1, int i2) {\n\t\tObject tmp=l.get(i1);\n\t\tl.set(i1, l.get(i2));\n\t\tl.set(i2, tmp);\n\t}",
"private void setListAndResetSelection(JList list, List<String> items, java.util.List selection) {\n Map<String,Integer> str_to_i = new HashMap<String,Integer>();\n String as_str[] = new String[items.size()]; for (int i=0;i<as_str.length;i++) { as_str[i] = items.get(i); str_to_i.put(as_str[i], i); }\n list.setListData(as_str);\n if (selection.size() > 0) {\n List<Integer> ints = new ArrayList<Integer>(); \n // Find the indices for the previous settings\n for (int i=0;i<selection.size();i++)\n if (str_to_i.containsKey(selection.get(i))) \n\t ints.add(str_to_i.get(selection.get(i)));\n // Convert back to ints\n int as_ints[] = new int[ints.size()];\n for (int i=0;i<as_ints.length;i++) as_ints[i] = ints.get(i);\n list.setSelectedIndices(as_ints);\n }\n }",
"public void setCurrentListToBeDoneList();",
"public void setListImplementation(String list) {\n if (list == null) {\n throw new IllegalStateException(\"Internal error - list implementation class cannot be null\");\n } else {\n m_listImplClass = list;\n }\n }",
"@SuppressWarnings(\"unchecked\")\n\tpublic void set_List_Of_Product_Type_Of_Store_Two()\n\t{\n\t\tArrayList<Product> Product_Of_Store_Two = new ArrayList<Product>(); /* ArrayList Of Product */\n\t\tArrayList<String> String_Product_Of_Store_Two = new ArrayList<String>(); /* ArrayList Of The String Of The Product */\n\t\tArrayList<Product> temp_Product_Of_Store_Two = (ArrayList<Product>)CompanyManagerUI.Object_From_Comparing_For_Store_2.get(4);\t\n\t\t\n\t\tfor(int i = 0 ; i < temp_Product_Of_Store_Two.size() ; i++)\n\t\t{\n\t\t\tProduct_Of_Store_Two.add(temp_Product_Of_Store_Two.get(i));\n\t\t}\n\t\t\n\t\tfor(int i = 0 ; i < Product_Of_Store_Two.size() ; i++)\n\t\t{\n\t\t\tString_Product_Of_Store_Two.add(String.valueOf(Product_Of_Store_Two.get(i).getQuantity()) + \" ---> \" + String.valueOf(Product_Of_Store_Two.get(i).getpType()));\n\t\t}\n\t\t\n\t\tProduct_Of_Store_2 = FXCollections.observableArrayList(String_Product_Of_Store_Two);\n\t\tListViewQuantity_Store_2.setItems(Product_Of_Store_2);\n\t}",
"public void setRoomList (ArrayList<ItcRoom> roomList)\r\n\t {\r\n\t //this.roomList = roomList;\r\n\t }",
"public static <C> void SFIRST(LIST<C> L, C a) {\n if ( ! isNull( L ) ) {\n L.list.set(0,a);\n }\n }",
"protected void updateTypeList() {\n\t sequenceLabel.setText(\"Sequence = \" + theDoc.theSequence.getId());\n\t typeList.setListData(theDoc.theTypes);\n\t signalList.setListData(nullSignals);\n\t valueField.setEnabled(false);\n\t valueList.setEnabled(false);\n }",
"public void setListaTipoComprobanteSRI(List<TipoComprobanteSRI> listaTipoComprobanteSRI)\r\n/* 356: */ {\r\n/* 357:345 */ this.listaTipoComprobanteSRI = listaTipoComprobanteSRI;\r\n/* 358: */ }",
"public void upDateListView(List<FlightInfoTemp> list) {\n adapter.setData(list);\n adapter.notifyDataSetChanged();\n }",
"public void setListTitle(String listTitle) {\n this.listTitle = listTitle;\n }",
"@Override\n\tpublic void onUserListUpdate(User listOwner, UserList list) {\n\n\t}",
"@Override\r\n\tpublic void update(List<GroupMember> list) {\n\t\tif(list == null) return;\r\n\t\tfor(int i=0;i<list.size();i++)\r\n\t\t\tupdate(list.get(i));\r\n\t}",
"public void setTeam1 (ArrayList<PlayerData> Team1, PlayerData Player) {\n\t\tthis.Team1 = Team1;\n\t\tTeam1.add(Player);\n\t}",
"public ListADTImpl(ImmutableListADTImpl<T> listToMakeMutable) {\r\n this.head = new GenericEmptyNode();\r\n for (int i = 0; i < listToMakeMutable.getSize(); i++) {\r\n T value = listToMakeMutable.get(i);\r\n this.head = this.head.addBack(value);\r\n }\r\n }",
"public void setListRegisseure( List<Person> listRegisseure ) {\n\t\tthis.listRegisseure.clear();\n\t\tthis.listRegisseure.addAll( listRegisseure );\n\t}",
"public final void mo81945a(List<MediaModel> list) {\n C7573i.m23587b(list, \"list\");\n if (!C7573i.m23585a((Object) mo81943a(), (Object) list)) {\n super.mo81945a(list);\n }\n }"
] | [
"0.66595423",
"0.6442549",
"0.63892287",
"0.63738006",
"0.636686",
"0.6361863",
"0.63402843",
"0.6335449",
"0.6304103",
"0.62943",
"0.622411",
"0.6185776",
"0.61565137",
"0.61506397",
"0.6090158",
"0.6073473",
"0.59956837",
"0.5979374",
"0.5935225",
"0.5915317",
"0.59093446",
"0.58662957",
"0.584105",
"0.5823935",
"0.58127916",
"0.5803445",
"0.579641",
"0.57684964",
"0.5761145",
"0.5749356",
"0.57470876",
"0.5723613",
"0.5721832",
"0.5700504",
"0.5696024",
"0.5695192",
"0.5691949",
"0.56889945",
"0.5682391",
"0.56769645",
"0.5670574",
"0.5667429",
"0.5662745",
"0.56477946",
"0.563877",
"0.5615063",
"0.560441",
"0.5600019",
"0.55891764",
"0.5572016",
"0.5563103",
"0.5559787",
"0.5555493",
"0.5555332",
"0.55501",
"0.55457187",
"0.5543896",
"0.55432004",
"0.5535173",
"0.5531452",
"0.5531417",
"0.55290097",
"0.55164814",
"0.5508592",
"0.5508592",
"0.5504973",
"0.550054",
"0.5499084",
"0.5486916",
"0.54752713",
"0.5473985",
"0.54660124",
"0.5464149",
"0.54640764",
"0.5451727",
"0.5443514",
"0.54386175",
"0.54324394",
"0.5424183",
"0.5408656",
"0.5406974",
"0.539427",
"0.5386837",
"0.53825563",
"0.5382378",
"0.5381444",
"0.5381232",
"0.53807235",
"0.53763545",
"0.53687876",
"0.53682685",
"0.53659797",
"0.53636765",
"0.53619367",
"0.53598446",
"0.5356883",
"0.53439635",
"0.53352094",
"0.5332477",
"0.53251785"
] | 0.82599974 | 0 |
setVertex() sets the corresponding vertex of the DListNode to the object vertex2. | public void setVertex(Object vertex2){
this.vertex = vertex2;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"DListNode2(Object vertex1) {\r\n vertex = vertex1;\r\n list = null;\r\n prev = null;\r\n next = null;\r\n }",
"public void setEdge(int v1, int v2, int weight) {\n LinkedList<Integer> tmp = adjList.elementAt(v1);\n if(adjList.elementAt(v1).contains(v2) == false) {\n tmp.add(v2);\n adjList.set(v1, tmp);\n totalEdges ++;\n LinkedList<Integer> tmp2 = adjWeight.elementAt(v1);\n tmp2.add(weight);\n adjWeight.set(v1, tmp2);\n }\n }",
"public void setEdge(int n1, int n2){\n\t\tif(outOfBounds(n1) || outOfBounds(n2))// if node indexes are bad return\n\t\t\treturn ;\n\t\t\n if((dGraph.getElement(n1, n2)) == 1){\n\t\t\treturn;\n\t}\n\t\tdGraph.setElement(n1, n2, 1); //shows that there is an edge going from n1 to n2\n\t\tdGraphin.setElement(n2, n1, 1);// show the edges going into n2\n\t\toutdegree[n1]++;\n\t\tindegree[n2]++;\n\t\t\n\t}",
"public void setPrev(DListNode2 prev1){\r\n this.prev = prev1;\r\n }",
"public void setNext(Vertex next) {\n\t\tthis.next = next;\n\t}",
"public void setNext(DListNode2 next1){\r\n this.next = next1;\r\n }",
"public void connect(int first, int second) {\n\t\tvertex.get(first).add(second);\n\t}",
"public void addTwoWayVertex(String node1, String node2) {\r\n addEdge(node1, node2);\r\n addEdge(node2, node1);\r\n }",
"public void setNode_2(String node_2);",
"public void setList(DList2 list1){\r\n list = list1;\r\n }",
"EdgeNode(VertexNode correspondingVertex){\n setCorrespondingVertex(correspondingVertex);\n }",
"public void addVertex (){\t\t \n\t\tthis.graph.insert( new MyList<Integer>() );\n\t}",
"public void setTo(Vertex<VV> vertex)\r\n { this.to = vertex; }",
"public void setEdge(int start, int target){\n\t\tthis.graph.elementAt(start).insert(target);\n\t}",
"@Override\n public void connect(T value1, T value2, int weight) {\n Vertex<T> from = vertices.get(value1);\n Vertex<T> to = vertices.get(value2);\n from.addNeighbor(to, weight);\n\n }",
"public void setDirectedEdge(Vertex start, Vertex end, int weight) \n\t{\n\t\ttry {\n\t\t\tint vI = vertices.indexOf(start);\n\t\t\tint uI = vertices.indexOf(end);\n\t\t\tedges[vI][uI] = weight;\n\t\t} \n\t\tcatch (Exception e) {\n\t\t\treturn;\n\t\t}\n\t\t\n\n\t}",
"@Override\n\tpublic void setNode_2(java.lang.String node_2) {\n\t\t_dictData.setNode_2(node_2);\n\t}",
"void addEdge(int vertex1, int vertex2){\n adjList[vertex1].add(vertex2);\n adjList[vertex2].add(vertex1);\n }",
"public void updateGraphVertices(Vertex[] vertexList) {\n graph.updateVertices(vertexList);\n }",
"void setVertices(int vertices);",
"public Edge(Object vertex1, Object vertex2, int w){\n v1 = vertex1;\n v2 = vertex2;\n weight = w;\n }",
"public void setPoint2(Point3D point2) {\r\n this.point2 = point2;\r\n }",
"public void setNext(Node<T> another)\n\t{\tthis.next = another; }",
"public void setFrom(Vertex<VV> vertex)\r\n { this.from = vertex; }",
"public AdjListNode(int n) {\n\t\tvertexIndex = n;\n\t}",
"public void setNext(ListNode next)\r\n {\r\n this.next = next;\r\n }",
"public void setPrev(DNode newPrev) { prev = newPrev; }",
"public void addUndirectedEdge(int v1, int v2) {\r\n addUndirectedEdge(v1, v2, null);\r\n }",
"public void addEdge(int v1, int v2) {\r\n\t\tadjList[v1].add(v2);\r\n\t}",
"public void setContainingListNode(DoublyLinkedList<T> lst,\r\n \t\t\t\t\t\t\t\t DoublyLinkedList<T>.ListNode node);",
"public V addVertex(V v);",
"public void setNext(DNode newNext) { next = newNext; }",
"public void addVertex();",
"public void setGraph(Graphics2D g2D) {\n\t\tthis.g2D = g2D;\n\t\tg2D.setColor(Color.RED);\n\t\tmodel.loadPoints();\n\t\tfor (Model.Point point : model.loadPointList()) {\n\t\t\tpoint.xValue = point.xValue;\n\t\t\tpoint.yValue = point.yValue;\n\t\t\tg2D.fillRect((int) point.xValue, (int) point.yValue, 4, 4);\n\t\t}\n\t}",
"public void setVertexB(E3DTexturedVertex vertex){\r\n\t\tthis.vertices[1] = vertex;\r\n\t\tneedNormalRecalc = true;\r\n\t\tneedPlaneEquationRecalc = true;\r\n\t}",
"public DirectedEdge(Graph g, Vertex v1, Vertex v2){\n\t\tsuper(g, v1, v2);\n\t\tthis.source = v1;\n\t}",
"public void setEdge(Student curr, Student neighbor, Integer price) {\n curr.setNeighborAndPrice(neighbor, price);\n }",
"public void set(DEPNode node, String label)\n\t{\n\t\tthis.node = node;\n\t\tthis.label = label;\n\t}",
"public void setNext(DoubleNode<T> node)\n {\n\n next = node;\n }",
"void setNode(int nodeId, double lat, double lon);",
"public void setVertexNumber(Integer num) {\n\t\t_vertexId = num;\n\t}",
"@Override\r\n public void addEdge(Vertex v1, Vertex v2) {\r\n adjacencyList.get(v1).add(v2); //put v2 into the LinkedList of key v1.\r\n adjacencyList.get(v2).add(v1); //put v1 into the LinkedList of key v2.\r\n }",
"@Override\r\n public void connectDirected(T value, T neighbor) {\r\n Vertex<T> v = vertices.get(value);\r\n Vertex<T> n = vertices.get(neighbor);\r\n v.addNeighbor(n);\r\n }",
"private void swap(int index1, int index2){\r\n ListNode c = head;\r\n ListNode swapNode = head;\r\n \r\n E tmp = null, tmp1 = null;\r\n \r\n for(int i = 0; i < index1; i++) c = c.getLink();\r\n tmp = (E) c.getData();\r\n \r\n for(int i = 0; i < index2; i++) swapNode = swapNode.getLink();\r\n tmp1 = (E) swapNode.getData();\r\n c.setData(tmp1);\r\n swapNode.setData(tmp);\r\n }",
"public void addUndirectedEdge(int v1, int v2) {\n addUndirectedEdge(v1, v2, null);\n }",
"public void addUndirectedEdge(int v1, int v2) {\n addUndirectedEdge(v1, v2, null);\n }",
"public void set(Vector3f v1, Vector3f v2) {\n this.setOrigin(v1);\n this.setDirection(v2.subtract(v1));\n }",
"public void addEdge(int v1, int v2) {\r\n addEdge(v1, v2, null);\r\n }",
"void addVertex(Vertex v);",
"public void setItem2(Object item) throws InvalidNodeException {\n\t\tif (!isValidNode()) {\n\t\t\tthrow new InvalidNodeException();\n\t\t}\n\t\tthis.item2 = item;\n\t}",
"private void connectVertex(IndoorVertex indoorV1, IndoorVertex indoorV2)\n {\n XYPos firstPos = indoorV1.getPosition();\n XYPos secondPos = indoorV2.getPosition();\n\n //Change in only X position means that the vertex's are East/West of eachother\n //Change in only Y position means that the vertex's are North/South of eachother\n if(firstPos.getX() > secondPos.getX() && Math.floor(firstPos.getY() - secondPos.getY()) == 0.0)\n {\n indoorV1.addWestConnection(indoorV2);\n indoorV2.addEastConnection(indoorV1);\n }\n else if(firstPos.getX() < secondPos.getX() && Math.floor(firstPos.getY() - secondPos.getY()) == 0.0)\n {\n indoorV1.addEastConnection(indoorV2);\n indoorV2.addWestConnection(indoorV1);\n }\n else if(firstPos.getY() > secondPos.getY() && Math.floor(firstPos.getX() - secondPos.getX()) == 0.0)\n {\n indoorV1.addSouthConnection(indoorV2);\n indoorV2.addNorthConnection(indoorV1);\n }\n else if(firstPos.getY() < secondPos.getY() && Math.floor(firstPos.getX() - secondPos.getX()) == 0.0)\n {\n indoorV1.addNorthConnection(indoorV2);\n indoorV2.addSouthConnection(indoorV1);\n }\n\n\n indoorV1.addConnection(indoorV2);\n indoorV2.addConnection(indoorV1);\n }",
"public void setNode_3(String node_3);",
"public void setGraph(Graph<V,E> graph);",
"public void setHead(ListNode node)\n {\n head = node;\n }",
"public Edge(Vertex in_pointOne, Vertex in_pointTwo){\n\t\tthis.pointOne = in_pointOne;\n\t\tthis.pointTwo = in_pointTwo;\n\t}",
"public void edgeMake(int vertex1, int vertex2) {\n addVertex(vertex1); // both vertices added to the set\n addVertex(vertex2);\n adjacencyMap.get(vertex1).add(vertex2); // both vertices receive the edge\n adjacencyMap.get(vertex2).add(vertex1);\n }",
"private void setNodeConnectionList(ArrayList<Pair<String, Integer>> nodeConnectionList)\n\t{\n\t\totherNodes = nodeConnectionList; // set this field.\n\t}",
"public void addUndirectedEdge(int v1, int v2, Object edgeInfo) {\r\n \tmyAdjLists[v1].add(new Edge(v1, v2, edgeInfo));\r\n \tmyAdjLists[v2].add(new Edge(v2, v1, edgeInfo));\r\n }",
"public void addEdge(int v1, int v2) {\n addEdge(v1, v2, null);\n }",
"public void addEdge(int v1, int v2) {\n addEdge(v1, v2, null);\n }",
"public Edge(T node_1, T node_2,S label) {\n\t\tparent = node_1;\n\t\tchild = node_2;\n\t\tl = label;\n\t\tcheckRep();\n\t}",
"public void setNext(ListNode<E> next)\n {\n nextNode = next;\n }",
"public void setVertices(ProcessVertex inVertex, ProcessVertex outVertex) {\n\t\tthis.inVertex = inVertex;\n\t\tthis.outVertex = outVertex;\n\t}",
"public Position insertVertex(Object o);",
"public Node setNextNode(Node node);",
"void setNode(int nodeId, double lat, double lon, double ele);",
"void addEdge(Vertex v1, Vertex v2, Double w) throws VertexNotInGraphException;",
"public DSAGraphVertex(String inLabel, Object inValue)\n\t\t{\n\t\t\tlabel = inLabel;\n\t\t\tvalue = inValue;\n\t\t\tlinks = new DSALinkedList();\n\t\t\tvisited = false;\n\t\t}",
"public EdgeListGraph(int V) {\n\t\t// TODO Auto-generated constructor stub\n\t\tthis.V = V;\n\t\tthis.edgeList = new ArrayList<>();\n\t}",
"void setNext (ListNode newNext) { /* package access */ \n\t\tnext = newNext;\n\t}",
"public void addEdge(int v1, int v2, Object edgeInfo) {\r\n myAdjLists[v1].add(new Edge(v1, v2, edgeInfo));\r\n }",
"public void setNode_4(String node_4);",
"public void setNext(LinearNode<T> node) {\r\n\t\t\r\n\t\tnext = node;\r\n\t\t\r\n\t}",
"public void setPnode(Node<T1> pNode) {\r\n\t\tthis.pnode = pNode;\r\n\t\tcheckRep();\r\n\t}",
"public void setNode_1(String node_1);",
"public void addUndirectedEdge(int vertexOne, int vertexTwo) {\n\t\tGraphNode first = nodeList.get(vertexOne - 1);\n\t\tGraphNode second = nodeList.get(vertexTwo - 1);\n\t\tfirst.getNeighbors().add(second);//Neighbour of first is second. Store it.\n\t\tsecond.getNeighbors().add(first);//Neighbour of second is first. Store it.\n\t\tSystem.out.println(first.getNeighbors());\n\t\tSystem.out.println(second.getNeighbors());\n\t}",
"public void set(Vec2 v) {\r\n\t\tx = v.x;\r\n\t\ty = v.y;\r\n\t}",
"public void setVertexC(E3DTexturedVertex vertex){\r\n\t\tthis.vertices[2] = vertex;\r\n\t\tneedNormalRecalc = true;\r\n\t\tneedPlaneEquationRecalc = true;\r\n\t}",
"public void setOb2(CPointer<BlenderObject> ob2) throws IOException\n\t{\n\t\tlong __address = ((ob2 == null) ? 0 : ob2.getAddress());\n\t\tif ((__io__pointersize == 8)) {\n\t\t\t__io__block.writeLong(__io__address + 8, __address);\n\t\t} else {\n\t\t\t__io__block.writeLong(__io__address + 4, __address);\n\t\t}\n\t}",
"public void addEdge(int v1, int v2, Object edgeInfo) {\n //your code here\n \tfor (Edge e : myAdjLists[v1]) {\n \t\tif (e.to() == v2) {\n \t\t\te.setObjectInfo(edgeInfo);\n \t\t\treturn;\n \t\t}\n \t}\n \tEdge toAdd = new Edge(v1, v2, edgeInfo);\n \tmyAdjLists[v1].add(toAdd);\t\n }",
"public ListNode(Object d, ListNode n) {\n\t\tdata = d;\n\t\tnext = n;\n\t}",
"public Node setPrevNode(Node node);",
"public void setAdjacent(int city1, int city2){\r\n\t\tcheckCityNoRange(city1);\r\n\t\tcheckCityNoRange(city2);\r\n\t\tif(city1 == city2)\r\n\t\t\tthrow new IllegalArgumentException(\"must be 2 different cities\");\r\n\t\t\r\n\t\tcity1 --;\r\n\t\tcity2 --;\r\n\t\tcities[city1].addAdjcentNode(city2);\r\n\t\tcities[city2].addAdjcentNode(city1);\r\n\t}",
"public void moveVertex() {\r\n\t\tPriorityQueue<Vertex2D> pq = new PriorityQueue<Vertex2D>(3,(a,b) -> a.id - b.id);\r\n\t\tpq.add(this); pq.add(this.previous); pq.add(this.next);\r\n\t\t\r\n\t\tsynchronized(pq.poll()) {\r\n\t\t\tsynchronized(pq.poll()) {\r\n\t\t\t\tsynchronized(pq.poll()) {\r\n\t\t\t\t\t//Actually move the vertex \"this\"\r\n\t\t\t\t\tdouble r1 = Star.rnd.nextDouble();\r\n\t\t\t\t\tdouble r2 = Star.rnd.nextDouble();\r\n\t\t\t\t\tdouble newX = (1 - Math.sqrt(r1)) * previous.x + (Math.sqrt(r1) * (1 - r2)) * this.x + (Math.sqrt(r1) * r2) * next.x;\r\n\t\t\t\t\tdouble newY = (1 - Math.sqrt(r1)) * previous.y + (Math.sqrt(r1) * (1 - r2)) * this.y + (Math.sqrt(r1) * r2) * next.y;\r\n\t\t\t\t\tthis.x = newX;\r\n\t\t\t\t\tthis.y = newY;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"@Override\r\n\tpublic void setPredecessor(VertexInterface<T> predecessor) {\n\r\n\t}",
"public Vertex(int label) {\r\n isVisited = false;\r\n this.label = label;\r\n }",
"public void setNext(SortedLinkedListNode pNode) {\n next = pNode;\n }",
"public void setPrevious(Vertex v){\n previous = v;\n }",
"public DirectedEdge(Graph g, Vertex v1, Vertex v2, Vertex source){\n\t\tsuper(g, v1, v2);\n\t\tthis.source = source;\n\t}",
"public void setLink( IntNode _node ) {\r\n\t\t\tlink = _node;\r\n\t\t}",
"public void setNext(ObjectListNode p) {\n next = p;\n }",
"public void setParent(Node node) {\n\n\t\tif (this.parent != null) {\n\t\t\t// if there's a current parent node, unlink the 2 nodes\n\t\t\tthis.parent.children.remove(this);\n\t\t} else {\n\t\t\t// the parent is the root graph\n\t\t\tthis.graph.childNodes.remove(this.getId());\n\t\t}\n\n\t\tthis.parent = node;\n\n\t\tif (node != null) {\n\t\t\t// link the 2 nodes\n\t\t\tnode.children.add(this);\n\t\t} else {\n\t\t\t// the parent is the root graph\n\t\t\tthis.graph.childNodes.put(this.getId(), this);\n\t\t}\n\t}",
"public void swapNodes(int data1, int data2) {\n\t\tif(head == null || size == 1) {\n\t\t\tSystem.out.println(\"List is empty or only one node present!!\");\n\t\t\treturn;\n\t\t}\n\t\tNode node1 = null;\n\t\tNode node1Prev = null;\n\t\tNode node2 = null;\n\t\tNode node2Prev = null;\n\t\tNode start = head;\n\t\tif(start.data == data1) {\n\t\t\tnode1Prev = null;\n\t\t\tnode1 = start;\n\t\t}\n\t\tif(start.data == data2) {\n\t\t\tnode2Prev = null;\n\t\t\tnode2 = start;\n\t\t}\n\t\twhile(start.next != null) {\n\t\t\tif(start.next.data == data1) {\n\t\t\t\tnode1Prev = start;\n\t\t\t\tnode1 = start.next;\n\t\t\t}\n\t\t\tif(start.next.data == data2) {\n\t\t\t\tnode2Prev = start;\n\t\t\t\tnode2 = start.next;\n\t\t\t}\n\t\t\tstart = start.next;\n\t\t}\n\n\t\tif(node1 != null && node2 != null) {\n\t\t\tif(node1Prev == null) {\n\t\t\t\thead = node2;\n\t\t\t}\n\t\t\tif(node2Prev == null) {\n\t\t\t\thead = node1;\n\t\t\t}\n\t\t\tNode tempNext = node2.next;\n\t\t\tif(node1Prev != null)\n\t\t\t\tnode1Prev.next = node2;\n\t\t\tnode2.next = node1.next;\n\n\t\t\tif(node2Prev != null)\n\t\t\t\tnode2Prev.next = node1;\n\t\t\tnode1.next = tempNext;\n\t\t}\n\t}",
"public void addVertex(T vertLabel) {\n\t\tvertCount++;\n\t\tLinkedList[] tempList = new LinkedList[vertCount];\n\t\tLinkedList newVert = new LinkedList((String)vertLabel);\n\t\t\n\t\tif(verts.length==0){\n\t\t\ttempList[0] = newVert;\n\t\t}\n\t\t\n\t\telse{\n\t\t\tfor(int x=0; x<verts.length; x++){\n\t\t\t\t\ttempList[x] = verts[x];\n\t\t\t}\n\t\t\ttempList[verts.length] = newVert;\n\t\t}\n\tverts = tempList;\n }",
"public void setGraph(Graph2D graph) {\n mBI = null;\n mGraph = graph;\n updateUI();\n }",
"public final void zza(zzk zzk, zzk zzk2) {\n zzk.next = zzk2;\n }",
"@PortedFrom(file = \"Taxonomy.h\", name = \"setVisited\")\n public void setVisited(TaxonomyVertex node) {\n node.setChecked(visitedLabel);\n }",
"public void setNext(Node<D> n){\n\t\tnext = n;\n\t}",
"public void setNext(ListNode<Item> next) {\n this.next = next;\n }",
"public Vertex(final Vertex vertex){\n\t\tID = vertex.getID();\n\t}"
] | [
"0.69426626",
"0.61946666",
"0.583091",
"0.57722324",
"0.57111055",
"0.5709168",
"0.568533",
"0.5653076",
"0.55505145",
"0.55411386",
"0.55343217",
"0.55123717",
"0.5421155",
"0.5360641",
"0.5320913",
"0.5242012",
"0.5235718",
"0.5231566",
"0.52307576",
"0.52194196",
"0.5208988",
"0.5200174",
"0.51852137",
"0.51741534",
"0.51730543",
"0.5167314",
"0.51478356",
"0.5145552",
"0.5140686",
"0.5140502",
"0.51357913",
"0.5127567",
"0.51221627",
"0.51183856",
"0.5117543",
"0.5109077",
"0.50973237",
"0.509483",
"0.5093243",
"0.50920045",
"0.50837696",
"0.5081744",
"0.5075102",
"0.50737715",
"0.5065557",
"0.5065557",
"0.50606537",
"0.5059133",
"0.5055857",
"0.50493354",
"0.5043639",
"0.5039365",
"0.5027994",
"0.5019286",
"0.5018516",
"0.50158966",
"0.49826849",
"0.4981943",
"0.49694768",
"0.49694768",
"0.49636185",
"0.49632698",
"0.4960803",
"0.49567953",
"0.49567115",
"0.49510518",
"0.4949097",
"0.49424502",
"0.4938289",
"0.49360123",
"0.49313205",
"0.49307948",
"0.49243072",
"0.49195784",
"0.49152276",
"0.49149436",
"0.49098366",
"0.49081963",
"0.49027303",
"0.48989996",
"0.48985466",
"0.4893598",
"0.4883686",
"0.48830143",
"0.48809257",
"0.48804685",
"0.48721373",
"0.48712477",
"0.48645207",
"0.48629895",
"0.48621932",
"0.48619193",
"0.48551473",
"0.4854367",
"0.4838503",
"0.4829992",
"0.4829581",
"0.48281616",
"0.48255512",
"0.4821992"
] | 0.7964433 | 0 |
list() returns the DList that the DListNode is pointing to. | public DList2 list(){
return this.list;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public DOCKSList getList() {\r\n return localList;\r\n }",
"public final List getList()\n {\n return this.list;\n }",
"public LinkedList getList() {\n\treturn this.roomList;\n}",
"public java.util.List getList() {\n\t\treturn list;\n\t}",
"public JList obtenirList() {\r\n\t\treturn list;\r\n\t}",
"public List<T> getList() {\n\t\treturn list;\n\t}",
"public List<Node> getPillList();",
"public List<Object> getList() {\n List<Object> returnList = new ArrayList<Object>();\n ListNode<String, Object> n = front;\n while(n != null) {\n returnList.add(n.value);\n n = n.next;\n }\n Collections.reverse(returnList);\n return returnList;\n }",
"public List getList();",
"public PacketLinkedList<SimplePacket> getListBuffer() {\n\t\treturn list;\n\t}",
"public Lista<Lado> obtener_Lista() {\n\t\treturn this.list;\n\t}",
"public ArrayList getList() {\n \t\treturn list;\n \t}",
"public List<NetworkNode> listNetworkNode();",
"List<String> d();",
"Object getTolist();",
"public abstract List<T> getList();",
"public interface DList {\n}",
"public ArrayList<Node> getList(){\n \treturn this.children;\n }",
"@Override\n public List<E> asList() {\n ArrayList<E> result = null;\n\n while (top.next != null) {\n top = top.next;\n result.add(top.data);\n }\n return result;\n }",
"protected abstract List<E> getList();",
"protected List ensureDisplayList()\n {\n if (m_listDisplay == null)\n {\n m_listDisplay = new LinkedList();\n }\n return m_listDisplay;\n }",
"protected List getList() {\n/* 88 */ return (List)getCollection();\n/* */ }",
"public String getElement()\n\t{\n\t\treturn \"list\";\n\t}",
"public List<New> list();",
"public SinglyLinkedList getPublicList() {\n return this.publicList;\n }",
"private List getList() {\n if(itemsList == null) {\n itemsList = new ArrayList<>();\n }\n return itemsList;\n }",
"protected Object[] getList() {\n return list;\n }",
"public ArrayList<Node> getListNodes(){\r\n return listNodes;\r\n }",
"public ListIterator listIterator() {\n\t\treturn new ItrListaDE();\n\t}",
"public List getDownList() {\n\t\treturn downList;\n\t}",
"public List<Node> toList() {\n return tree.toList();\n }",
"public List getAddressList() {\r\n System.out.println(\"List Elements :\" + addressList);\r\n return addressList;\r\n }",
"public List<Article> getList() {\n return list;\n }",
"public Item[] getList() {\n\t\treturn list;\n\t}",
"public com.google.protobuf.ProtocolStringList\n getListList() {\n return list_.getUnmodifiableView();\n }",
"LinkedList<SuperCardToast> getList() {\n\n return mList;\n\n }",
"public List list() throws Exception {\n\t\treturn null;\r\n\t}",
"private List<SimpleComponent> list() {\n\t\treturn this.list(null);\n\t}",
"interface List { // List ADT\npublic void clear(); // Remove all Objects from list\npublic void insert(Object item); // Insert Object at curr position\npublic void append(Object item); // Insert Object at tail of list\npublic Object remove(); // Remove/return current Object\npublic void setFirst(); // Set current to first position\npublic void next(); // Move current to next position\npublic void prev(); // Move current to prev position\npublic int length(); // Return current length of list\npublic void setPos(int pos); // Set current to specified pos\npublic void setValue(Object val); // Set current Object's value\npublic Object currValue(); // Return value of current Object\npublic boolean isEmpty(); // Return true if list is empty\npublic boolean isInList(); // True if current is within list\npublic void print(); // Print all of list's elements\n}",
"@Override\n public List<Object> list() {\n return null;\n }",
"public List getList() {\n return Arrays.asList(toJavaArray()); \n }",
"public List<T> list()\n\t{\n\t\tfinal List<T> list = this.dao.findAll();\n\t\treturn list;\n\t}",
"List<?> getList();",
"public XSListSimpleType asList() {\n // This method could not be decompiled.\n // \n // Original Bytecode:\n // \n // 0: idiv \n // 1: laload \n // LocalVariableTable:\n // Start Length Slot Name Signature\n // ----- ------ ---- ---- ------------------------------------------\n // 0 2 0 this Lcom/sun/xml/xsom/impl/ListSimpleTypeImpl;\n // \n // The error that occurred was:\n // \n // java.lang.ArrayIndexOutOfBoundsException\n // \n throw new IllegalStateException(\"An error occurred while decompiling this method.\");\n }",
"public List getList() throws HibException;",
"public List hardList() {\r\n List result = new ArrayList();\r\n\r\n for (int i=0; i < size(); i++) {\r\n Object tmp = get(i);\r\n\r\n if (tmp != null)\r\n result.add(tmp);\r\n }\r\n\r\n return result;\r\n }",
"@NonNull\n public List<T> getList() {\n return data;\n }",
"public List<Node> getPowerPillList();",
"public DrawList getDrawList()\n {\n return(drawList);\n }",
"public LinkedList<Cycle> getList(LinkedList<Cycle> list){\n\t\txml=new ProcessXML();\n\t\tlist=(LinkedList<Cycle>) xml.ReadXML().clone();\n\t\tgetName(list);\n\t\treturn list;\n\t}",
"public com.google.protobuf.ProtocolStringList\n getListList() {\n return list_;\n }",
"abstract void makeList();",
"@DISPID(10)\n\t// = 0xa. The runtime will prefer the VTID if present\n\t@VTID(19)\n\t@ReturnValue(type = NativeType.Dispatch)\n\tcom4j.Com4jObject list();",
"public Node getList(Vertex lim){\r\n p = list;\r\n nOut= new Node(null,null);\r\n q=nOut;\r\n\r\n while(p.next!=null) {\r\n p = p.next;\r\n q.next = new Node(p.item, null);\r\n q = q.next;\r\n if (p.item.name == lim.name)\r\n break;\r\n }\r\n return nOut;\r\n }",
"@Override\n\tpublic List<N> getNodeList()\n\t{\n\t\treturn new ArrayList<N>(nodeList);\n\t}",
"public DListNode2 next(){\r\n return this.next;\r\n }",
"public UserList list();",
"public LinkedList<String> getList(){\n return phoneNums;\n }",
"private List<DataContainer> getDataContainerList() {\r\n if (dataContainerList == null) {\r\n parse();\r\n }\r\n return this.dataContainerList;\r\n }",
"@SuppressWarnings(\"unchecked\")\r\n public List<DomainObject> getList() {\r\n Session session = getSession();\r\n try {\r\n session.flush();\r\n return session.createQuery(\"from \" + getPersistentClass().getName()).list();\r\n } catch (HibernateException e) {\r\n LOG.error(MODULE + \"Exception in getList() Method:\" + e, e);\r\n throw e;\r\n }\r\n }",
"public List<GeneralItem> getList() {\n return stList;\n }",
"@Override\n public String getName() {\n return \"list\";\n }",
"public List<LayoutNode> getNodeList() {\n\treturn nodeList;\n }",
"public List<ToDoList> getToDoListList() {\n return toDoListList;\n }",
"public static ArrayList getList() {\r\n return ListeElem;\r\n }",
"public DoublyLinkedList getAdjacencyList()\n \t{\n\t return adjacencyList ;\n \t}",
"public List<Ent> getChildList(){\n\t\tif(this.childList != null){\n\t\t\treturn Collections.unmodifiableList(this.childList);\n\t\t}else{\n\t\t\treturn new ArrayList<Ent>();\n\t\t}\n\t}",
"public LinkedList<Tuple> getStatementList(){\n\t\tsynchronized(statementList){\n\t\t\tLinkedList<Tuple> statementsListCopy = new LinkedList<Tuple>();\n\t\t\tstatementsListCopy.addAll(statementList);\n\t\t\treturn statementsListCopy;\n\t\t}\n\t}",
"int createList(int listData) {\n\t\tint list = newList_();\n\t\t// m_lists.set_field(list, 0, null_node());//head\n\t\t// m_lists.set_field(list, 1, null_node());//tail\n\t\t// m_lists.set_field(list, 2, null_node());//prev list\n\t\tm_lists.setField(list, 3, m_list_of_lists); // next list\n\t\tm_lists.setField(list, 4, 0);// node count in the list\n\t\tm_lists.setField(list, 5, listData);\n\t\tif (m_list_of_lists != nullNode())\n\t\t\tsetPrevList_(m_list_of_lists, list);\n\n\t\tm_list_of_lists = list;\n\t\treturn list;\n\t}",
"@SuppressWarnings({ \"unchecked\" })\n public LinkedList<n501070324_PedidoAssistencia> getList() {\n return listPedidosAssistencia;\n }",
"public List<Object> toList() {\n int i = this.capacityHint;\n int i2 = this.size;\n ArrayList arrayList = new ArrayList(i2 + 1);\n Object[] head2 = head();\n int i3 = 0;\n while (true) {\n int i4 = 0;\n while (i3 < i2) {\n arrayList.add(head2[i4]);\n i3++;\n i4++;\n if (i4 == i) {\n head2 = head2[i];\n }\n }\n return arrayList;\n }\n }",
"public LinkedList<T> toLinkedList() {\n LinkedList<T> out = new LinkedList<>();\n int currentTreeIndex = this.indexCorrespondingToTheFirstElement;\n while (currentTreeIndex != -1) {\n Node<T> currentNode = getHelper(currentTreeIndex);\n out.add(currentNode.data);\n currentTreeIndex = currentNode.nextIndex;\n }\n return out;\n }",
"java.util.List<io.netifi.proteus.admin.om.Node> \n getNodesList();",
"public List<MessageListItem> getListData() {\n return listData;\n }",
"public List<String> getList() {\n return Collections.unmodifiableList(_model.getList());\n }",
"public List<Dept> list() {\n try {\n List<Dept> dept = new ArrayList<Dept>();\n PreparedStatement stmt = this.connection\n .prepareStatement(\"select * from dept_sr\"); //here\n\n ResultSet rs = stmt.executeQuery();\n\n while (rs.next()) {\n // adiciona a tarefa na lista\n dept.add(populateDept(rs));\n }\n\n rs.close();\n stmt.close();\n\n return dept;\n } catch (SQLException e) {\n throw new RuntimeException(e);\n }\n }",
"public List<Integer> getList() {\n return list;\n }",
"public static <T> List<T> createList() {\n\t\treturn Collections.emptyList();\n\t}",
"public ReferenceList getRefList( )\n {\n return _refList;\n }",
"int getListData(int list) {\n\t\treturn m_lists.getField(list, 5);\n\t}",
"List<T> readList();",
"public java.util.List<People> getFriendListList() {\n return java.util.Collections.unmodifiableList(\n instance.getFriendListList());\n }",
"List<E> list();",
"public List<Rectangulo> getLista() {\n return (lista);\n }",
"@Override\r\n\tpublic List<PdsDto> getpdsList(int parent) {\n\t\treturn pdsdao.getpdsList(parent);\r\n\t}",
"public List getList(String name) {\n if (lists.contains(name)) return lists.get(name);\n throw new IllegalArgumentException(\"The list with this id isn't contained in the ListSet\");\n }",
"@Override\n public String toString() {\n return list.toString();\n }",
"public List<Node> getNodes();",
"public List<String> getMemberList()\n\t{\n\t\treturn source.getMemberList();\n\t}",
"TaskList getList();",
"private JList getLogList() {\n\t\tif (logList == null) {\n\t\t\tlogList = new JList();\n\t\t\tlogList.setBounds(new Rectangle(124, 313, 300, 100));\n\t\t}\n\t\treturn logList;\n\t}",
"public com.newco.ofac.webservice.SDN[] getSDNLists() {\r\n return SDNLists;\r\n }",
"ListIterator listIterator() {\n\t\treturn list.listIterator();\n\t}",
"public ListIterator<E> listIterator() {\n\t\treturn new LinkedListItr();\r\n\t}",
"@java.lang.Override\n public boolean getIsList() {\n return isList_;\n }",
"@java.lang.Override\n public boolean getIsList() {\n return isList_;\n }",
"List<Node> nodes();",
"@Override\r\n public List<Dept> deptList() {\n return sqlSession.selectList(\"deptDAO.deptList\");\r\n }",
"Object get()\n\t{\n\t\tif (length == 0 ) \n\t\t{\t\n\t\t\tthrow new RuntimeException(\"List Error: cannot call get() on empty List\");\n\t\t}\n\t\tif (cursor == null\t) \n\t\t{\n\t\t\tthrow new RuntimeException(\"List Error: cannot call get() on cursor that is off the list\");\n\t\t\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn cursor.data;\n\t\t}\n\t}",
"public Lista listar() {\n Lista listaAux = new Lista();\r\n if (this.raiz != null) {\r\n listaAux = listarAux(this.raiz, listaAux);\r\n }\r\n return listaAux;\r\n }"
] | [
"0.72557575",
"0.68750626",
"0.68680245",
"0.68161935",
"0.67291427",
"0.6658374",
"0.6545863",
"0.651792",
"0.6480127",
"0.6470668",
"0.6364845",
"0.63419956",
"0.62937456",
"0.62616456",
"0.6221443",
"0.62129325",
"0.62023294",
"0.61347204",
"0.61187595",
"0.6099762",
"0.6095165",
"0.60739046",
"0.6045045",
"0.602463",
"0.60179144",
"0.6006873",
"0.59997153",
"0.5966833",
"0.59618324",
"0.594905",
"0.5942949",
"0.5927717",
"0.59214586",
"0.5913397",
"0.58911026",
"0.58833283",
"0.5864126",
"0.5860821",
"0.58607465",
"0.58596605",
"0.5855911",
"0.5855498",
"0.5841147",
"0.58374274",
"0.5835851",
"0.58297926",
"0.5820903",
"0.5816294",
"0.58115536",
"0.58066815",
"0.5804352",
"0.58024025",
"0.5797054",
"0.5778692",
"0.577648",
"0.5757544",
"0.5757114",
"0.57464486",
"0.5733458",
"0.5720649",
"0.5720339",
"0.5718282",
"0.57116336",
"0.5703751",
"0.5703499",
"0.5696359",
"0.5695633",
"0.56835115",
"0.5679195",
"0.56785583",
"0.5669114",
"0.5669003",
"0.5667039",
"0.5665889",
"0.5664587",
"0.5654179",
"0.56540114",
"0.5648338",
"0.5628543",
"0.56273085",
"0.5622945",
"0.5622287",
"0.562138",
"0.56172746",
"0.56138736",
"0.56127286",
"0.56089836",
"0.5607685",
"0.55987173",
"0.5589831",
"0.5560999",
"0.556038",
"0.5559444",
"0.5556595",
"0.5548502",
"0.5548502",
"0.5546638",
"0.5546268",
"0.5544557",
"0.55410576"
] | 0.7696434 | 0 |
correspondingPair() returns the DListNode that the current node is pointing to. | public DListNode2 correspondingPair(){
return this.correspondingPair;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public synchronized Pair getPair() {\n\t\treturn new Pair(pair.getX(), pair.getY());\n\t}",
"@Override\n\tpublic Pair getPair() {\n\t\tlock.lock();\n\t\ttry {\n\t\t\treturn new Pair(pair.getX(), pair.getY());\n\t\t} finally {\n\t\t\tlock.unlock();\n\t\t}\t\t\n\t}",
"public String getPairName() {\n return \"(\" + this.source.getName() + \",\" + this.destination.getName() + \")\";\n }",
"public List<Pair> getPairList()\n\t{\n\t\tList<Pair> pairs = new ArrayList<>();\n\t\tfor (Map.Entry<String, AbstractNode> entry : this.pairs.entrySet())\n\t\t\tpairs.add(new Pair(entry.getKey(), entry.getValue()));\n\t\treturn pairs;\n\t}",
"@NotNull\n default GenericPair getPair() {\n return GenericPair.of(this.getLeftType(), this.getRightType());\n }",
"public DListNode2 next(){\r\n return this.next;\r\n }",
"public ListNode<T> getNext();",
"public ListNode getNext()\r\n {\r\n return next;\r\n }",
"private static Pair closest_pair(ArrayList<Point> pointset){\n\t\treturn null;\n\t}",
"public Iterator<Map.Entry<String, AbstractNode>> getPairIterator()\n\t{\n\t\treturn pairs.entrySet().iterator();\n\t}",
"public ListNode<E> getNext()\n {\n return nextNode;\n }",
"public String getType() {return \"Pair\";}",
"public ListNode getNode(ListNode node){\n\t\tif(firstNode == null) return null;\n\t\tListNode temp = firstNode;\n\t\twhile(temp!=null){\n\t\t\tif(temp.equals(node)) return temp;\n\t\t\ttemp = temp.getNextNode();\n\t\t}\n\t\treturn null;\n\t}",
"@Override\r\n\t\tpublic K getKey() {\n\t\t\treturn pair.getFirst();\r\n\t\t}",
"Pair<Integer, Integer> getPosition();",
"public Pair get()\n {\n return this.MapItr.element;\n }",
"ListNode getNext() { /* package access */ \n\t\treturn next;\n\t}",
"public T lookup(T item){\n if (head.next == tail && tail.prev == head){\n return null;\n }\n else {\n MyDoubleNode<T> counter = head.next;\n boolean shouldContinue = true;\n while (shouldContinue){\n if (counter.next != tail){\n if (counter.data.equals(item)){\n return counter.data;\n }\n counter = counter.next;\n shouldContinue = true;\n }\n else{\n if (counter.data.equals(item)){\n return counter.data;\n }\n shouldContinue = false;\n }\n }\n return null;\n }\n }",
"@Override\r\n\t\tpublic S getSecond() {\n\t\t\treturn pair.getSecond();\r\n\t\t}",
"public static Optional<Pair<Integer, Integer>> twoPointers(List<Integer> sorted, int targetSum) {\n return twoPointers(sorted, targetSum, 0, sorted.size() - 1);\n }",
"private Node find(String key) {\n Node now = head;\n while (now != null) {\n if (now.pairStringString.getKey().equals(key)) {\n return now;\n }\n now = now.next;\n }\n return null;\n }",
"public ColourPair getColorPair() {\n return colour;\n }",
"public SAMRecord getSecondPair() throws CloneNotSupportedException {\n\t\treturn (SAMRecord) crosslinkedRecord2.clone();\n\t}",
"public DListNode2 prev(){\r\n return this.prev;\r\n }",
"public Node<D> getNext(){\n\t\treturn next;\n\t}",
"@Override\r\n\t\tpublic E getSecond() {\n\t\t\treturn pair.getSecond();\r\n\t\t}",
"@Override\r\n\t\tpublic E getSecond() {\n\t\t\treturn pair.getSecond();\r\n\t\t}",
"public Strand getPairStrand() throws BaseException\n {\n return getPairStrand(false);\n }",
"protected D getNextOrSame(D d) {\n\t\t\tD next = getNext(d);\n\t\t\tif (next == null) {\n\t\t\t\treturn d;\n\t\t\t}\n\t\t\treturn next;\n\t\t}",
"@Override\r\n\t\tpublic V getValue() {\n\t\t\treturn pair.getSecond();\r\n\t\t}",
"private Hand getPair(Hand handToCheck){\n\t\tHand hand = new FiveCardHand(handToCheck); //Make copy of the object so original doesn't get modified\n\t\tlog.debug(\"getPair(hand = \"+hand+\")\");\n\t\tif(hand == null){\n\t\t\tlog.debug(\"Hand was null. Returning null\");\n\t\t\treturn null;\n\t\t}\n\t\tArrayList<Card> cards = hand.getCards();\n\t\tif(cards == null){\n\t\t\tlog.debug(\"The ArrayList<Card> inside the Hand Object was NULL. Returning null\");\n\t\t\treturn null;\n\t\t}\n\t\tlog.trace(\"Number of cards in Hand: \"+cards.size());\n\t\tfor (int i =0; i< cards.size(); i++){\n\t\t\tCard c1= cards.remove(0);\n\t\t\ti--; //Update index\n\t\t\tfor (Card c2: cards){\n\t\t\t\tlog.trace(\"Are '\"+c1.getShortName()+\"' and '\"+c2.getShortName()+\"' a pair?\");\n\t\t\t\tif(c1.getNumber().equals(c2.getNumber())){\n\t\t\t\t\tlog.trace(\"\\tYes!\");\n\t\t\t\t\tlog.debug(\"A pairs found!\");\n\t\t\t\t\tArrayList<Card> ca = new ArrayList<Card>();\n\t\t\t\t\tca.add(c1);\n\t\t\t\t\tca.add(c2);\n\t\t\t\t\treturn new FiveCardHand(ca);\n\t\t\t\t}\n\t\t\t\tlog.trace(\"\\tNo.!\");\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t\tlog.debug(\"returning null\");\n\t\treturn null;\n\t}",
"@Override\r\n\t\tpublic E getFirst() {\n\t\t\treturn pair.getFirst();\r\n\t\t}",
"@Override\r\n\t\tpublic E getFirst() {\n\t\t\treturn pair.getFirst();\r\n\t\t}",
"public Tuple getNext(RID rid) {\n\t\treturn null;\r\n\t}",
"@Override\n public String toString() {\n return \"Pair[\" + first + \", \" + second + \"]\";\n }",
"public abstract Tuple getNext();",
"public Object getNext (Object o) {\n DoubleLinkedList e = (DoubleLinkedList) dictionary.get(o);\n if ((e == null) || (e.getNext() == null))\n return null;\n return e.getNext().getInfo();\n }",
"@Override\r\n\t\tpublic hust.idc.util.pair.UnorderedPair<E> convertPair() {\n\t\t\tsynchronized (mutex) {\r\n\t\t\t\treturn synchronizedPair(pair.convertPair(), mutex);\r\n\t\t\t}\r\n\t\t}",
"public Pair getRandomPair() {\n Shirt shirt = getRandomShirt();\n Trouser trouser = getRandomTrouser();\n\n if (trouser != null && shirt != null)\n return new Pair(shirt, trouser);\n else {\n return null;\n }\n }",
"private ListNode findNodeWith(T aData){\r\n ListNode temp = head;\r\n while(temp != null){\r\n if (temp.data == aData)\r\n return temp;\r\n temp = temp.link;\r\n }\r\n return null;\r\n }",
"public ListNode<V> next()\n\t\t{\n\t\t\treturn _next;\n\t\t}",
"private Pair getFirstOccurrence(Object o) {\n\t\tNode p;\n\t\tint k;\n\n\t\tif (o != null) {\n\t\t\tfor (k = 0, p = mHead.next; k < mSize; p = p.next, k++)\n\t\t\t\tif (o.equals(p.data))\n\t\t\t\t\treturn new Pair(p, k);\n\t\t} else {\n\t\t\tfor (k = 0, p = mHead.next; k < mSize; p = p.next, k++)\n\t\t\t\tif (p.data == null)\n\t\t\t\t\treturn new Pair(p, k);\n\t\t}\n\t\treturn new Pair(null, NOT_FOUND);\n\t}",
"public MinesNode getCorrespondingNode() {\r\n\t\treturn correspondingNode;\r\n\t}",
"@Override\n\tpublic Tuple next(){\n currTupleInd++;\n if (currTupleInd >= numOfTuples) return null;\n return tuples.get(currTupleInd);\n\t}",
"private Pair getLastOccurrence(Object o) {\n\t\tNode p, q = null;\n\t\tint k, qK = -1;\n\n\t\tif (o != null) {\n\n\t\t\tfor (k = 0, p = mHead.next; k < mSize; p = p.next, k++)\n\t\t\t\tif (o.equals(p.data)) {\n\t\t\t\t\tq = p;\n\t\t\t\t\tqK = k;\n\t\t\t\t}\n\t\t} else {\n\t\t\tfor (k = 0, p = mHead.next; k < mSize; p = p.next, k++)\n\t\t\t\tif (o.equals(p.data)) {\n\t\t\t\t\tq = p;\n\t\t\t\t\tqK = k;\n\t\t\t\t}\n\t\t}\n\n\t\treturn new Pair(q, qK);\n\n\t}",
"@Override\r\n\t\tpublic T getFirst() {\n\t\t\treturn pair.getFirst();\r\n\t\t}",
"public ListNode swapPairs(ListNode head) {\n if(head == null)\n return head;\n \n \n int count = 0;\n ListNode h = head;\n ListNode end = head;\n ListNode preH = null;\n\n // we prefer to track a linked list using a head and a tail\n ListNode newHead = null;\n ListNode newTail = null;\n \n while(end != null)\n {\n count = 0;\n while(count < 2 && end != null)\n {\n count++;\n end = end.next;\n }\n \n if(count == 2)\n {\n ListNode temp = helper(preH, h, end);\n if(newHead == null)\n {\n newHead = temp;\n newTail = h;\n }else\n {\n newTail.next = temp; //link to the existing linked list\n }\n \n newTail = h; // !!! update tail pointer\n h = end;\n \n }\n if(count < 2 && end == null)\n {\n break;\n }\n \n /*\n if(count == 2 && end == null)\n {\n ListNode temp = helper(preH, h, end);\n if(newHead == null)\n {\n newHead = temp;\n newTail = h;\n }else\n {\n newTail.next = temp;\n \n }\n \n newTail = h; \n h = end;\n }\n */\n }\n \n if(newHead != null)\n return newHead;\n return head;\n }",
"public ListNode<Item> getNext() {\n return this.next;\n }",
"@Override\r\n\tpublic Tuple getNextTuple() {\r\n\t\tTuple t = next;\r\n\t\tTuple tempNext = next;\r\n\t\twhile (tempNext != null && tempNext.sameAs(t))\r\n\t\t\ttempNext = child.getNextTuple();\r\n\t\tnext = tempNext;\r\n\t\treturn t;\r\n\t}",
"private Optional<Pair<S, S>> getCrossingPair(final Node<S> node, final Pair<S, S>[] map) {\n Pair<S, S> result = null;\n if(node.hasNext()) {\n //aX ?\n if(node.getElement().isTerminal()) {\n // ab\n if(!node.getNext().getElement().isTerminal()) {\n S a = node.getElement();\n S b = map[node.getNext().getElement().getId()].a;\n result = !a.equals(b) ? new Pair<S, S>(a,b) : null;\n }\n } // Ax or AX\n else {\n S a = map[node.getElement().getId()].b;\n S b = node.getNext().getElement();\n // Ab?\n if(b.isTerminal()) {\n result = !a.equals(b) ? new Pair<S, S>(a, b) : null;\n } //AB\n else {\n result = !a.equals(map[b.getId()].a) ? new Pair<S, S>(a, map[b.getId()].a) : null;\n }\n }\n }\n return Optional.ofNullable(result);\n }",
"public ListNode swapPairs(ListNode head) {\n if (head == null || head.next == null) {\n return head;\n }\n ListNode result = head.next;\n ListNode tempNode = null;\n while (swapTwoNodes(head, tempNode)) {\n tempNode = head;\n head = head.next;\n }\n return result;\n }",
"public Pair<Currency, Currency> getCurrencyPair() {\n return _currencyPair;\n }",
"public Pair<Currency, Currency> getCurrencyPair() {\n return _currencyPair;\n }",
"public NodeD getSelecNext(){\n if (this.selec == this.tail){\n return this.tail;\n }else{\n this.selec = this.selec.getNext();\n return selec;\n }\n }",
"public SAMRecord getFirstPair() throws CloneNotSupportedException {\n\t\treturn (SAMRecord) crosslinkedRecord1.clone();\n\t}",
"public static ListNode swapPairs(ListNode node) {\r\n\t\tif (node == null || node.next == null) {\r\n\t\t\treturn node;\r\n\t\t}\r\n\t\tListNode first = node;\r\n\t\tListNode second = node.next;\r\n\t\tListNode third = node.next.next;\r\n\t\tListNode ret = second;\r\n\t\tret.next = first;\r\n\t\tret.next.next = swapPairs(third);\r\n\t\treturn ret;\r\n\t}",
"public SortedLinkedListNode getNext() {\n return next;\n }",
"@Override\r\n\t\tpublic S getSecond() {\n\t\t\tsynchronized (mutex) {\r\n\t\t\t\treturn pair.getSecond();\r\n\t\t\t}\r\n\t\t}",
"object_detection.protos.Calibration.XYPairs.XYPair getXYPair(int index);",
"private Pair<View, ChatsStruct> getChatPairWithTag(Object chatWindowTag) {\n Logger.d(TAG, \"getChatPairWithTag() entry the chatwindowTag is \"\n + chatWindowTag);\n if (null == chatWindowTag) {\n Logger.d(TAG, \"getChatPairWithTag() The chatWindowTag is null\");\n return null;\n }\n if (mData.isEmpty()) {\n Logger.d(TAG, \"getChatPairWithTag() The mData is empty\");\n return null;\n }\n Set<View> viewSet = mData.keySet();\n Iterator<View> viewIterator = viewSet.iterator();\n if (viewIterator == null) {\n Logger.d(TAG, \"getChatPairWithTag() The viewIterator is null\");\n return null;\n }\n while (viewIterator.hasNext()) {\n View view = viewIterator.next();\n if (view == null) {\n Logger.d(TAG, \"getChatPairWithTag() The view is null\");\n } else {\n Object obj = mData.get(view);\n if (obj == null) {\n Logger.d(TAG, \"getChatPairWithTag() The value is null\");\n } else {\n if (obj instanceof ChatsStruct) {\n ChatsStruct chatStruct = (ChatsStruct) obj;\n Object windowTag = chatStruct.getWindowTag();\n if (null != windowTag && chatWindowTag == windowTag) {\n Logger.d(TAG,\n \"getChatPairWithTag() find the specific window Tag\");\n Pair<View, ChatsStruct> tempPair = new Pair<View, ChatsStruct>(\n view, chatStruct);\n return tempPair;\n }\n }\n }\n }\n }\n return null;\n }",
"public Pair GetHead() {\n return snake.get(head);\n }",
"public static int getPairId(int id) {\n Connection sqlConnection = null;\n PreparedStatement preparedStatement = null;\n ResultSet resultSet = null;\n\n try {\n sqlConnection = Dao.getStorage().getConnection();\n preparedStatement = Dao.getStorage().prepare(\"SELECT * FROM item_teleporter_links WHERE item_one = ? OR item_two = ? LIMIT 1;\", sqlConnection);\n preparedStatement.setInt(1, id);\n preparedStatement.setInt(2, id);\n resultSet = preparedStatement.executeQuery();\n\n if (resultSet.next()) {\n\n if (resultSet.getInt(\"item_two\") != id) {\n return resultSet.getInt(\"item_two\");\n } else {\n return resultSet.getInt(\"item_one\");\n }\n \n }\n } catch (Exception e) {\n Storage.logError(e);\n } finally {\n Storage.closeSilently(resultSet);\n Storage.closeSilently(preparedStatement);\n Storage.closeSilently(sqlConnection);\n }\n\n return -1;\n }",
"MethodElement getLinkedElement();",
"public String getType() {\n\t\treturn \"Pair\";\n\t}",
"public static Noun getPairNoun(final Noun noun1, final NounType nounType2) {\r\n\t\tMark mark = noun1.pairs[nounType2.num - 1];\r\n\t\tif (mark == null) return null;\r\n\t\treturn mark.noun1 == noun1 ? mark.noun2 : mark.noun1;\r\n\t}",
"GraphNode secondEndpoint() \n\t {\n\t\treturn this.secondEndpoint;\n\t\t \n\t }",
"public DNode getNext() { return next; }",
"Pair<Integer, Integer> getInitialPosition();",
"private ListNode find(K key) {\r\n\t\t\tif (key == null) throw new NullPointerException();\r\n\t\t\tListNode current = header;\r\n\t\t\twhile (current != null) {\r\n\t\t\t\tif (current.key.equals(key)) return current;\r\n\t\t\t\tcurrent = current.next;\r\n\t\t\t}\r\n\t\t\treturn null;\r\n\t\t}",
"public ListNode swapPairs2(ListNode head) {\n if ((head == null)||(head.next == null))\n return head;\n ListNode n = head.next;\n head.next = swapPairs2(head.next.next);\n n.next = head;\n return n;\n }",
"public Object lookup(int par1)\n {\n int j = computeHash(par1);\n\n for (IntHashMapEntry inthashmapentry = this.slots[getSlotIndex(j, this.slots.length)]; inthashmapentry != null; inthashmapentry = inthashmapentry.nextEntry)\n {\n if (inthashmapentry.hashEntry == par1)\n {\n return inthashmapentry.valueEntry;\n }\n }\n\n return null;\n }",
"public ListNode swapPairs(ListNode head) {\n if (head == null || head.next == null) {\n return head;\n }\n ListNode dummy = new ListNode(0);\n ListNode l1 = dummy;\n ListNode l2 = head;\n while (l2 != null && l2.next != null) {\n ListNode nextStart = l2.next.next;\n l1.next = l2.next;\n l2.next.next = l2;\n l2.next = nextStart;\n l1 = l2;\n l2 = nextStart;\n }\n return dummy.next;\n }",
"private ForeignKeyElement getMatchingFK (List pairNames, \n\t\t\t\tTableElement table)\n\t\t\t{\n\t\t\t\tForeignKeyElement[] foreignKeys = (table != null) ? \n\t\t\t\t\ttable.getForeignKeys() : null;\n\t\t\t\tint count = ((foreignKeys != null) ? foreignKeys.length : 0);\n\n\t\t\t\tfor (int i = 0; i < count; i++)\n\t\t\t\t{\n\t\t\t\t\tif (matchesFK(pairNames, foreignKeys[i]))\n\t\t\t\t\t\treturn foreignKeys[i];\n\t\t\t\t}\n\n\t\t\t\treturn null;\n\t\t\t}",
"public ListElement getNext()\n\t {\n\t return this.next;\n\t }",
"private Node<Pair<K, V>> search(\n BiDirectionalNullTerminatedTailedLinkedList<Pair<K, V>> list,\n K key) {\n\n for (Node<Pair<K, V>> i = list.getHead().getNext(); i != list.getTail();\n i = i.getNext()) {\n if (i.getData().key.equals(key)) {\n return i;\n }\n }\n\n return null;\n }",
"public Pair(Node s, Node d) {\n this.source = s;\n this.destination = d;\n requestGenerators = new ArrayList<RequestGenerator>();\n }",
"private int find(int p1, int p2) {\n return id[p1 - 1][p2 - 1]; // find the current value of a node\n }",
"@Override\r\n\t\tpublic Pair<S, T> convertPair() {\n\t\t\tsynchronized (mutex) {\r\n\t\t\t\treturn synchronizedPair(pair.convertPair(), mutex);\r\n\t\t\t}\r\n\t\t}",
"public synchronized Pair<K, V> next() throws IOException {\n\t\t\treturn data.next();\n\t\t}",
"public V get(K key) {\n int hashCode = scaledHashCode(key);\n OwnLinkedList<K, V> list = table[hashCode];\n if (list == null) {\n return null;\n }\n PairNode<K, V> result = list.search(key);\n if (result == null) {\n return null;\n }\n return result.getValue();\n }",
"public ObjectListNode getNext() {\n return next;\n }",
"public Node getNext(){\n\t\t\treturn next;\n\t\t}",
"public PartialPairList getPartialPairForOneQuery(RankList rl)// rl holds all\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// documents\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// for one\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// query\n\t{\n\t\tPartialPairList ppl = new PartialPairList();\n\t\tfor (int i = 0; i < rl.size(); i++) {\n\t\t\tfor (int j = i + 1; j < rl.size(); j++) {\n\t\t\t\tif (rl.get(i).getLabel() != (rl.get(j).getLabel())) {\n\t\t\t\t\tppl.add(new PartialPair(rl.get(i), rl.get(j)));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn ppl;\n\n\t}",
"public KeyPair getKeyPair() {\r\n\t\treturn keyPair;\r\n\t}",
"public Node getNext(){\n\t\treturn next;\n\t}",
"@JsonProperty(\"pairingCode\")\n @JsonInclude(JsonInclude.Include.NON_DEFAULT)\n public String getPairingCode() {\n return this.pairingCode;\n }",
"@Override\r\n\t\tpublic T getFirst() {\n\t\t\tsynchronized (mutex) {\r\n\t\t\t\treturn pair.getFirst();\r\n\t\t\t}\r\n\t\t}",
"public ListNode getNode(int nodeID){\n\t\treturn getNode(new ListNode(nodeID, 0));\n\t}",
"public Node<E> get(E e){\n Node<E> current = head.getNext();\n while (current != tail) {\n if (current.getValue() == e) {\n return current;\n }\n current = current.getNext();\n }\n return null;\n }",
"public Point nearestNeighbor(Point p) {\n\t\tif (p == null) {\n System.out.println(\"Point is null\");\n }\n if (isEmpty()) {\n return null;\n }\n\n return nearest(head, p, head).item;\n\t}",
"private RDFPairs getRDFPairs() {\n return this.rdfPairs;\n }",
"public V getDestination() {\r\n\r\n\t\tV result = null;\r\n\t\tif ((counter <= links.size()) && (counter > 0)) {\r\n\t\t\tresult = succNodes.get(counter - 1);\r\n\t\t}\r\n\t\treturn result;\r\n\t}",
"public T lookupHead(){\n if (head.next == tail && tail.prev == head){\n return null;\n }\n else {\n return head.next.data;\n }\n }",
"@Override\n\tpublic Tuple next(){\n\t\t//Delete the lines below and add your code here\n\t\tTuple temp;\n\t\tTuple t = child.next();\n\t\tint s = -1;\n\t\tString s1;\n\t\tString s2;\n\t\tif(sorted==false){\n\t\t\tif(t!=null){\n\t\t\t\tfor(s=0; s<t.attributeList.size(); s++){\n\t\t\t\t\tif(t.attributeList.get(s).attributeName.equals(orderPredicate)){\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\twhile(t!=null){\n\t\t\t\ttuplesResult.add(t);\n\t\t\t\tt = child.next();\n\t\t\t}\n\t\t\tfor(int i=0; i<tuplesResult.size(); i++){\n\t\t\t\ts1 = tuplesResult.get(i).attributeList.get(s).attributeValue.toString();\n\t\t\t\tfor(int j=i+1; j<tuplesResult.size(); j++){\n\t\t\t\t\ts2 = tuplesResult.get(j).attributeList.get(s).attributeValue.toString();\n\t\t\t\t\tif(s1.compareTo(s2) > 0){\n\t\t\t\t\t\ttemp=tuplesResult.get(i);\n\t\t\t\t\t\ttuplesResult.set(i, tuplesResult.get(j));\n\t\t\t\t\t\ttuplesResult.set(j, temp);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tsorted=true;\n\t\t}\n\t\tif(tuplesResult.size()>0){\n\t\t\treturn tuplesResult.remove(0);\n\t\t}\n\t\telse{\n\t\t\treturn null;\n\t\t}\n\t}",
"public String get(Triple<Integer, Integer, String> e) {\n String label = propLabels.get(e);\n if (label != null) {\n return label;\n } else if (!propsByPair.containsKey(new Pair<>(e.get1(), e.get2()))) {\n return SprlLabelConverter.nil();\n } else {\n throw new IllegalArgumentException(\n String.format(\"The requested property has not been labeled for the given pair: %s\", e));\n }\n }",
"public MapElement getNextElement(Direction dir) {\n //System.out.println(\"Le lett kérve a következő palyaelem.\");\n return neighbours[dir.getValue()];\n }",
"public ListElement<T> getNext()\n\t{\n\t\treturn next;\n\t}",
"public LinearNode<T> getNext() {\r\n\t\t\r\n\t\treturn next;\r\n\t\r\n\t}",
"public Protein getOtherProteine(Protein p) {\n\t\tif (p == p1) {\n\t\t\treturn p2;\n\t\t}\n\t\tif (p == p2) {\n\t\t\treturn p1;\n\t\t}\n\t\treturn null;\n\t}",
"public TupleDesc getTupleDesc();"
] | [
"0.6336382",
"0.59359574",
"0.5686506",
"0.5668219",
"0.55408627",
"0.5487483",
"0.54874206",
"0.54512537",
"0.54179466",
"0.5343117",
"0.53106815",
"0.529453",
"0.527752",
"0.5273919",
"0.5272585",
"0.52485895",
"0.52342933",
"0.5206522",
"0.5191527",
"0.5188395",
"0.518511",
"0.5171117",
"0.5163279",
"0.5155221",
"0.5152563",
"0.5100308",
"0.5100308",
"0.50896275",
"0.50849026",
"0.50661063",
"0.5034231",
"0.50237036",
"0.50237036",
"0.50196993",
"0.5016209",
"0.49988416",
"0.49808306",
"0.4977263",
"0.4962424",
"0.49595115",
"0.49472886",
"0.49400356",
"0.493936",
"0.49380913",
"0.4935311",
"0.49253985",
"0.49156561",
"0.4901776",
"0.4899094",
"0.48986945",
"0.48986503",
"0.48868752",
"0.48868752",
"0.4872823",
"0.48717564",
"0.48691782",
"0.48527747",
"0.48516843",
"0.4851158",
"0.4846007",
"0.4845949",
"0.48252591",
"0.4822197",
"0.48183966",
"0.48028746",
"0.48018214",
"0.479815",
"0.47931457",
"0.47865415",
"0.47861436",
"0.4774521",
"0.47677597",
"0.4758357",
"0.47535977",
"0.47509944",
"0.47490054",
"0.47453785",
"0.47291526",
"0.47288647",
"0.47070175",
"0.47068134",
"0.47045943",
"0.4693009",
"0.4687742",
"0.4684812",
"0.46806407",
"0.4680089",
"0.46794042",
"0.4673079",
"0.46710753",
"0.46682295",
"0.46612847",
"0.46523866",
"0.46521127",
"0.46516076",
"0.4650117",
"0.4649336",
"0.46492085",
"0.46440428",
"0.46430314"
] | 0.8697003 | 0 |
toString() method for debugging purposes. | public String toString(){
String result = "[ ";
result = result + vertex + " ]";
return result;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String toString() ;",
"@Override\n public final String toString() {\n return asString(0, 4);\n }",
"public String toString() { return stringify(this, true); }",
"public String toDebugString();",
"public String toString()\n\t{\n\t\treturn Printer.stringify(this, false);\n\t}",
"@Override()\n public String toString()\n {\n final StringBuilder buffer = new StringBuilder();\n toString(buffer);\n return buffer.toString();\n }",
"@Override\n\tpublic String toString() {\n\t\treturn toStringBuilder(new StringBuilder()).toString();\n\t}",
"@Override\r\n\tpublic String toString();",
"public String toString() {\n\t}",
"@Override\n public String toString() {\n return toString(false, true, true, null);\n }",
"@Override public String toString();",
"@Override\r\n public String toString();",
"@Override\r\n String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"public String toString();",
"@Override\n\tpublic String toString();",
"@Override\n String toString();",
"@Override\n String toString();",
"@Override\n public String toString() {\n // TODO: Using Serializer\n return Serializer.toByteArray(this).toString();\n }",
"public String toDebugString() {\n StringBuffer str = new StringBuffer(mySelf()+\"\\n\");\n return super.toDebugString()+str.toString();\n }",
"@Override\n\tString toString();",
"@Override\n public String toString();",
"@Override\n public String toString();",
"public String toString() {\n\t\treturn toString(this);\n\t}",
"public String toString() {\n\t\treturn toString(true);\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn toText();\n\t}",
"@Override\r\n\t\tpublic String toString() {\n\t\t\treturn super.toString();\r\n\t\t}",
"public String toDebugString() {\n StringBuffer str = new StringBuffer(mySelf()+\"\\n\");\n return str.toString();\n }",
"public String toString() {\n\t\treturn super.toString();\n\t\t// This gives stack overflows:\n\t\t// return ToStringBuilder.reflectionToString(this);\n\t}",
"public String toString() {\n return ToStringBuilder.reflectionToString(this);\n }",
"@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}",
"@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}",
"@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}",
"@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}",
"@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}",
"@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}",
"@Override\r\n\tpublic String toString() {\n\t\tString str = \"\";\r\n\t\treturn str;\r\n\t}",
"public String toString() {\n return toDisplayString();\n }",
"@Override\n\t\tpublic String toString() {\n\t\t\treturn super.toString();\n\t\t}",
"@Override\n String toString();",
"public java.lang.String toDebugString () { throw new RuntimeException(); }",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}",
"@Override\n\tpublic String toStringDebug() {\n\t\treturn null;\n\t}",
"public String toString() {\r\n\t\t\r\n\t\treturn super.toString();\r\n\t\t\r\n\t}",
"public String toString() { return \"\"; }",
"public String toString() { return \"\"; }",
"public String toString() {\n \t\treturn super.toString();\n \t}",
"public String toString() {\n\t\treturn toString(0, 0);\n\t}",
"@Override\n public String toString(){\n return toString(false);\n }",
"@Override String toString();",
"public String toString() {\t\t\t\t\t\r\n\t\treturn super.toString();\r\n\t}",
"@Override\n public String toString()\n {\n return Arrays.toString(this.toArray());\n }",
"@Override\r\n\tpublic String toString() {\n\t\treturn \"\";\r\n\t}",
"@Override\n public String toString() {\n ByteArrayOutputStream bs = new ByteArrayOutputStream();\n PrintStream out = new PrintStream(bs);\n output(out, \"\");\n return bs.toString();\n }",
"public String toString() {\n StringWriter writer = new StringWriter();\n this.write(writer);\n return writer.toString();\n }",
"public String toString() {\n\t\treturn super.toString();\n\t}",
"public String toString() {\n\t\treturn super.toString();\n\t}",
"public String toString(){\n \treturn \"todo: use serialize() method\";\r\n }",
"@Override\n public String toString()\n {\n return this.toLsString();\n }",
"@Override\n public String toString() {\n String str = \"\";\n\n //TODO: Complete Method\n\n return str;\n }",
"@Override\n\tpublic String toString() {\n\t\treturn \"\";\n\t}",
"@Override\n public String toString() {\n return value();\n }",
"public String toString() {\n\t\treturn this.toJSON().toString();\n\t}"
] | [
"0.84261656",
"0.8401338",
"0.8385066",
"0.83607477",
"0.83131295",
"0.8283722",
"0.82588863",
"0.82576704",
"0.8249275",
"0.8241425",
"0.82045346",
"0.8202796",
"0.8194334",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.819351",
"0.8185803",
"0.8181581",
"0.8181581",
"0.8170137",
"0.8155375",
"0.8152307",
"0.8147379",
"0.8147379",
"0.8143508",
"0.8125709",
"0.8124546",
"0.81244963",
"0.8118024",
"0.81094116",
"0.8097875",
"0.80855334",
"0.80855334",
"0.80855334",
"0.80855334",
"0.80855334",
"0.80855334",
"0.8077124",
"0.80678594",
"0.8065784",
"0.8062269",
"0.8061054",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8041193",
"0.8037738",
"0.7986804",
"0.7985333",
"0.7985333",
"0.79848415",
"0.7980549",
"0.7972453",
"0.7969365",
"0.79612267",
"0.7956528",
"0.7937012",
"0.7936073",
"0.7935009",
"0.79243153",
"0.79243153",
"0.79184395",
"0.79051137",
"0.78796786",
"0.7877876",
"0.78688884",
"0.78655446"
] | 0.0 | -1 |
For schedule job / (nonJavadoc) | @Asynchronous
@TransactionTimeout(value = 30000, unit = TimeUnit.SECONDS)
public void executeTask(Timer timer)
{
try
{
//setType("SCP_TO_SAP");
run();
}
catch(Exception e)
{
String msg = MessageFormatorUtil.getParameterizedStringFromException(e);
logger.log(Level.SEVERE, "Exception occured in CustomerLoadingJob#executeTask for Timer: "+timer.getInfo()+", Task: "+this.processId + "(" + this.jobName +")" +", Reason for failure: "+msg, e);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void scheduleJob() {\n\n }",
"void schedule(ScheduledJob job);",
"void deschedule(ScheduledJob job);",
"public void scheduleJobs();",
"public void generateSchedule(){\n\t\t\n\t}",
"public abstract void schedule();",
"Schedule createSchedule();",
"abstract public void computeSchedule();",
"private void beginSchedule(){\n\t\tDivaApp.getInstance().submitScheduledTask(new RandomUpdater(this), RandomUpdater.DELAY, RandomUpdater.PERIOD);\n\t}",
"@Override\n public void mySchedule(String date) {\n FastJsonRequest request = new FastJsonRequest(SystemUtils.mainUrl + MethodCode.CLASSSCHEDULE + MethodType.MYSCHEDULEV2, RequestMethod.POST);\n request.add(\"username\", application.getSystemUtils().getDefaultUsername());\n request.add(\"token\", application.getSystemUtils().getToken());\n request.add(\"date\", date);\n request.add(MethodCode.DEVICEID, application.getSystemUtils().getSn());\n request.add(MethodCode.DEVICETYPE, SystemUtils.deviceType);\n request.add(MethodCode.APPVERSION, SystemUtils.getVersionName(context));\n addQueue(MethodCode.EVENT_MYSCHEDULE, request);\n\n\n// startQueue();\n }",
"public schedulerJob() {\n }",
"public void scheduleJob() {\n JobInfo.Builder builder = null;\n if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.LOLLIPOP) {\n builder = new JobInfo.Builder(mJobId++, mServiceComponent);\n builder.setMinimumLatency(1000);\n builder.setRequiredNetworkType(JobInfo.NETWORK_TYPE_ANY);\n // Extras, work duration.\n PersistableBundle extras = new PersistableBundle();\n extras.putLong(WORK_DURATION_KEY, Long.valueOf(1) * 1000);\n extras.putString(\"gsonData\", gsonDataa);\n extras.putInt(\"servicetype\", 1);\n builder.setExtras(extras);\n // Schedule job\n Log.d(TAG, \"Scheduling job\");\n JobScheduler tm = (JobScheduler) getSystemService(Context.JOB_SCHEDULER_SERVICE);\n tm.schedule(builder.build());\n\n }\n\n\n\n }",
"public abstract void maintenanceSchedule() ;",
"java.lang.String getSchedule();",
"private static \tvoid schedule(IMirror mirror) throws SchedulerException, ParseException {\n\n String mirrorID = \"none\";\n\t\ttry {\n\t\t\tmirrorID = mirror.getMirrorID();\n\t \n\t\t} catch (ConfigException e) {\n\t\t\tlogger.error(\"At this point the mirror must have a mirrorID which it has not: \" + e.getMessage());\n\t\t}\n\t\t\n\t\tString jobNameAKAMirrorID = mirrorID;\n\t\tString downloaderGroupName = DOWNLOADER;\n\t\tString diffGeneratorGroupName = DIFF_GENERATOR;\n\t\tString deltaGeneratorGroupName = DELTA_GENERATOR;\n\t\t\n\t\t/*\n\t\t * DELTA job\n\t\t */\n\t\tJobDetail deltaJobDetail = new JobDetail(jobNameAKAMirrorID,\n\t\t\t\t\t\t\t\tdeltaGeneratorGroupName, // default group\n\t\t\t\t\t\t\t\tDOMDeltaGeneratorJob.class); // the diff job\n\t\t\n\t\t/*\n\t\t * DIFF job\n\t\t */\n\t\tJobDetail diffJobDetail = new JobDetail(jobNameAKAMirrorID,\n\t\t\t\t\t\t\t\tdiffGeneratorGroupName, // default group\n\t\t\t\t\t\t\t\tDOMDiffGeneratorJob.class); // the diff job\n\t\t\n\t\t/*\n\t\t * DOWNLOADER job\n\t\t * This job is the point of entry in the workflow.\n\t\t * It needs to know about the 2 jobs which are next (see above).\n\t\t */\n\t\tJobDetail jobDetail = new JobDetail(jobNameAKAMirrorID, downloaderGroupName,\n\t\t\t\t\t\t\t\t\tDownloaderJob.class); // the job\n\t\t\n\t\tjobDetail.getJobDataMap().put(MIRROR, mirror);\n\t\tjobDetail.getJobDataMap().put(DELTA_GENERATOR, deltaJobDetail);\n\t\tjobDetail.getJobDataMap().put(DIFF_GENERATOR, diffJobDetail);\n\t\t\n\t\tCronTrigger trigger = new CronTrigger(\"CronTrigger for \" + mirror,\n\t\t\t\t\t\t\t\t\tdownloaderGroupName, jobNameAKAMirrorID, downloaderGroupName,\n\t\t\t\t\t\t\t\t\tmirror.getCronExpression() );\n\t\t// TODO remove below!\n\t\t//Trigger trigger = TriggerUtils.makeMinutelyTrigger(intervalHours);\n\t\t//Trigger trigger = TriggerUtils.makeHourlyTrigger(intervalHours);\n\t\ttrigger.setStartTime(new java.util.Date());\n\t\ttrigger.setName(\"Download Job for \" + mirror);\n\t\tsched.scheduleJob(jobDetail, trigger);\n\t\t\n\t\tlogger.info(\"Scheduled job for \" + mirror \n\t\t\t\t+ \" with cron expression '\" + mirror.getCronExpression() + \"'\");\n\t\t\n\t}",
"public interface JobScheduleService {\n void addJobScheduleHistory(JobContext jobInfo, ScheduleStatusEnum scheduleStatus);\n}",
"public Schedule() {\n\t\t// TODO Auto-generated constructor stub\n\t}",
"public void run() {\n\t\t\t\tIMSScheduleManager.super.startCron();\r\n\t\t\t\t\r\n\t\t\t}",
"public static void scheduleJob() {\n Set<JobRequest> jobRequests = JobManager.instance().getAllJobRequestsForTag(MobssJob.TAG);\n if (!jobRequests.isEmpty()) {\n return;\n }\n\n new JobRequest.Builder(MobssJob.TAG)\n .setPeriodic(AlarmManager.INTERVAL_DAY)\n .setUpdateCurrent(true) // cancel any preexisting job with the same tag while being scheduled.\n// .setRequiredNetworkType(JobRequest.NetworkType.CONNECTED) // since the sync service needs network connection\n// .setRequirementsEnforced(true) // makes sure that all the requirements are met before starting the sync service, if at least one of the requirements is not met then the sync service will be rescheduled and not run\n .build()\n .schedule();\n }",
"@Test\n public void testSchedule() throws IOException, InterruptedException {\n Note note = notebook.createNote(\"note1\", anonymous);\n Paragraph p = note.addNewParagraph(ANONYMOUS);\n Map config = new HashMap<>();\n p.setConfig(config);\n p.setText(\"p1\");\n Date dateFinished = p.getDateFinished();\n Assert.assertNull(dateFinished);\n // set cron scheduler, once a second\n config = note.getConfig();\n config.put(\"enabled\", true);\n config.put(\"cron\", \"* * * * * ?\");\n note.setConfig(config);\n notebook.refreshCron(note.getId());\n Thread.sleep((2 * 1000));\n // remove cron scheduler.\n config.put(\"cron\", null);\n note.setConfig(config);\n notebook.refreshCron(note.getId());\n Thread.sleep((2 * 1000));\n dateFinished = p.getDateFinished();\n Assert.assertNotNull(dateFinished);\n Thread.sleep((2 * 1000));\n Assert.assertEquals(dateFinished, p.getDateFinished());\n notebook.removeNote(note.getId(), anonymous);\n }",
"@Override\r\n\tpublic void doInitialSchedules() {\n\t}",
"@Scheduled(cron = \"0 * * * * ?\")\r\n public void cronJobSch() {\r\n SimpleDateFormat sdf = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss.SSS\");\r\n Date now = new Date();\r\n String strDate = sdf.format(now);\r\n System.out.println(\"Java cron job expression:: \" + strDate);\r\n }",
"@Override\n public void reportScheduler() {\n }",
"public void execute(JobExecutionContext context) throws JobExecutionException {\n\t\t\n\t\tint scheduler_id=(Integer)context.getJobDetail().getJobDataMap().get(\"scheduler_id\");\t\t\n \tString taskuid=(String)context.getJobDetail().getJobDataMap().get(\"taskuid\");\n \tString invoked_by=(String)context.getJobDetail().getJobDataMap().get(SchedulerEngine.JOBDATA_INVOKED_BY);\n \tString updatedtime=(String)context.getJobDetail().getJobDataMap().get(SchedulerEngine.JOBDATA_UPDATED_TIME);\n \tNumber trigger_row_id=(Number)context.getJobDetail().getJobDataMap().get(SchedulerEngine.JOBDATA_TRIGGER_ROW_ID);\n \t//System.out.println(\"ScheduledTaskJob.execute() 2be removed later:taskuid:\"+taskuid+\" scheduler_id:\"+scheduler_id);\n \t\n \t\n \t\n \ttry{\n \t\t\n\t \t//Map data=getSchedulerData(scheduler_id);\n \t\tSchedulerDB sdb=SchedulerDB.getSchedulerDB();\n \t\tMap data=null;\n \t\tString inject_code=null;\n \t\ttry{\n \t\t\tsdb.connectDB();\n \t\t\tdata=sdb.getScheduler(scheduler_id); \n \t\t\tif(trigger_row_id!=null){\n \t\t\t\tMap trig=sdb.getOneRowTriggerData(trigger_row_id.longValue());\n \t\t\t\tinject_code=(String)trig.get(\"inject_code\");\n \t\t\t}\n \t\t}catch(Exception e){\n \t\t\tthrow e;\n \t\t}finally {\n \t\t\tsdb.closeDB();\n \t\t}\n \t\t\n \t\tif(data.get(\"deleted\")!=null && ((Number)data.get(\"deleted\")).intValue()==1){\n \t\t\tthrow new Exception(\"Deleted Task can't be executed\");\n \t\t}\n \t\t\n \t\tlog.debug(\"trigger_row_id:\"+trigger_row_id+\" inject_code:\"+inject_code);\n\t \t\n\t \tScheduledTask task=new ScheduledTaskFactory().getTask(taskuid);\n\t \tif(task==null) {\n\t \t\tthrow new Exception(\"Task Group not found for the task:\"+scheduler_id);\n\t \t}\n\t \tStackFrame sframe=new StackFrame(task,data);\n\t \tif(invoked_by!=null && !invoked_by.equals(\"\")) {\n\t \t\tsframe.setInvokedby(invoked_by);\n\t \t}else{\n\t \t\tif(updatedtime!=null){\n\t \t\t\tsframe.setInvokedby(\"Scheduler (\"+updatedtime+\")\");\n\t \t\t}else{\n\t \t\t\tsframe.setInvokedby(\"Scheduler\");\n\t \t\t}\n\t \t}\n\t\t\t\n\t\t\tif(context.getTrigger().getPreviousFireTime()!=null){\n\t\t\t\tsframe.setTrigger_time(context.getTrigger().getPreviousFireTime().getTime());\n\t\t\t}else{\n\t\t\t\tsframe.setTrigger_time(new Date().getTime());\n\t\t\t}\n\t\t\t\n\t\t\tif(context.getTrigger().getNextFireTime()!=null){\n\t\t\t\tsframe.setNexttrigger_time(context.getTrigger().getNextFireTime().getTime());\n\t\t\t}\t\t\t\n\t\t\n\t\t\t\n\t\t\tif(Config.getValue(\"load_balancing_server\")!=null && Config.getValue(\"load_balancing_server\").equals(P2PService.getComputerName())){\n\t\t\t\tLoadBalancingQueueItem li=new LoadBalancingQueueItem();\n\t\t\t\tli.setSf(sframe);\n\t\t\t\tInteger id=(Integer)data.get(\"id\");\n\t\t\t\tli.setInject_code(inject_code);\n\t\t\t\tli.setSchedulerid(id);\n\t\t\t\tLoadBalancingQueue.getDefault().add(li);\n\t\t\t\t\n\t\t\t}else{\n\t\t\t\t/*ScheduledTaskQueue.add(sframe);*/\n\t\t\t}\n\t\t\t\n\t\t\tlog.debug(\"adding task to queue: task:\"+data.get(\"name\"));\n \t}catch(Exception e){\n \t\te.printStackTrace(); \t\t\n \t\t//ClientErrorMgmt.reportError(e, \"Error while triggering task\");\n \t} \n\t\t \n\t\t//String status=null;\n\t\t//try{\t\t\n\t\t\t//task.execute();\n\t\t\t//status=task.EXCECUTION_SUCCESS;\n\t\t//}catch(Exception e){\n\t\t//\tstatus=task.EXCECUTION_FAIL;\t\t\t\n\t\t//\tClientErrorMgmt.reportError(e, null);\n\t\t//}finally{\n\t\t//\ttry{\n\t\t//\t\taddLog(sdate,data,status);\n\t\t//\t}catch(Exception e){\n\t\t//\t\tClientErrorMgmt.reportError(e, null);\n\t\t//\t}\t\t\t\n\t\t//}\n\t\t\n \t\n \t\n\t}",
"public void update(Schedule arg0) {\n\t\t\n\t}",
"public interface Scheduler {\n\n void schedule();\n\n}",
"@Override\n\tpublic boolean isScheduled();",
"public void execute(JobExecutionContext context) throws JobExecutionException {\n \tSystem.out.println(\"This is a scheduled job for HRIS using Quartz 2.2.1 running every 10 minutes\");\n \tSystem.out.println(\"Change QuartzListener class to change schedule of execution\");\n \t\n \t/*\n \ttry {\n\t\t\t\tloanEntryList = loanEntryService.getAllActiveLoanEntry();\n\t\t\t\tfor (LoanEntry le: loanEntryList) {\n\t\t\t\t\tSystem.out.println(\"LoanEntry: \" + le.getEmpId());\n\t\t\t\t}\n\t\t\t} catch (SQLException e) {\n\t\t\t\tSystem.out.println(\"Exception encountered when trying to get all active loan entry..\");\n\t\t\t\te.printStackTrace();\n\t\t\t} catch (Exception e) {\n\t\t\t\tSystem.out.println(\"Exception encountered when trying to get all active loan entry..\");\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\t*/ \n \n }",
"public boolean generateSchedule(){\r\n return true;\r\n }",
"private void schedule() {\n service.scheduleDelayed(task, schedulingInterval);\n isScheduled = true;\n }",
"@Override\npublic void run() {\n\tCalendar oFecha = Calendar.getInstance();\n \n\tint minuto = 25;\n\t\n\tSystem.out.println(\n\t\t\toFecha.getTime().toLocaleString() + \n\t\t\t\" MinJob trigged by scheduler - \" + minuto );\n\t\n\ttry {\n\t\tSystem.out.println(Configuracion.getInstance().getProperty(\"clave\") );\n\t} catch(Exception e) {\n\t\te.printStackTrace();\n\t}\n\t\n\tif (oFecha.get(Calendar.MINUTE) == minuto)\t\n\t\tHourlyJob.realizarBackup();\n \n }",
"public void scheduleJob(JobInfo t) {\n Log.d(TAG, \"Scheduling job\");\n try {\n JobScheduler tm = (JobScheduler) appContext.getSystemService(appContext.JOB_SCHEDULER_SERVICE);\n tm.schedule(t);\n int i = 0;\n } catch (Exception e) {\n e.printStackTrace();\n int i = 0;\n }\n }",
"protected abstract String scheduler_next();",
"private void scheduleJob() {\n Log.d(TAG, \"Long lived task is done.\");\n }",
"@Override\r\n\tpublic void startCron() {\n\t\tlog.info(\"Start Schedule Manager.\");\r\n\t\tmainThread = new Thread(new Runnable() {\r\n\t\t\t\r\n\t\t\tpublic void run() {\r\n\t\t\t\t// TODO Auto-generated method stub\r\n\t\t\t\tIMSScheduleManager.super.startCron();\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t});\r\n\t\tmainThread.start();\r\n\t}",
"void cronScheduledProcesses();",
"private static void scheduleJob(Context context, JobInfo job) {\n JobScheduler jobScheduler =\n (JobScheduler) context.getSystemService(Context.JOB_SCHEDULER_SERVICE);\n int result = jobScheduler.schedule(job);\n Assert.assertEquals(JobScheduler.RESULT_SUCCESS, result);\n if (DEBUG) {\n Log.d(TAG, \"Scheduling result is \" + result);\n }\n }",
"public abstract boolean isScheduled();",
"public void setSchedule(Schedule schedule) {\r\n\t\tthis.schedule = schedule;\r\n\t}",
"@Scheduled(fixedRateString = \"PT120M\")\n\tvoid someJob(){\n//\t\tString s = \"Testing message.\\nNow time is : \"+new Date();\n////\t\tSystem.out.println(s);\n//\t\tPushNotificationOptions.sendMessageToAllUsers(s);\n//\n\t\t//get all schedules in current dayOfWeek\n\t\tCollection<Notification> notifications = notificationService.findAllByDayOfWeekAndTime();\n\t\tfor(Notification notification : notifications){\n//\t\t\tSystem.out.println(notification.toString());\n//\t\t\tSystem.out.println(!notification.getStatus());\n////\t\t\tSystem.out.println(check(notification.getStartTime()));\n//\t\t\t//check for already not sent notifications , also check for time difference < TIME_CONSTANT\n//\t\t\tif(!notification.getStatus() && check(notification.getStartTime())){\n//\t\t\t\t//send push notification\n//\t\t\t\tPushNotificationOptions.sendMessageToAllUsers(notification.getMessage());\n//\t\t\t\t//mark the notification as sent\n//\t\t\t\tnotificationService.setStatus(notification.getNotificationId());\n//\t\t\t}\n\t\t\tif(checkForDayTime()){\n\t\t\t\tPushNotificationOptions.sendMessageToAllUsers(notification.getMessage());\n\t\t\t\tnotificationService.setStatus(notification.getNotificationId());\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t}",
"public interface JcrontabScheduler {\n\n\t/** Avalon Role Name */\n\tString ROLE = JcrontabScheduler.class.getName();\n\t\n\t/** The Key to use in your .properties file for relative urls.\n\t * This will be replaced with the actual application root.\n\t * \n\t */\n\tpublic static final String APPLICATION_ROOT_KEY=\"applicationRoot\";\n\t\n\t/**\n\t * Gets the scheduler attribute of the JCrontabScheduler object\n\t *\n\t *@return The scheduler value\n\t */\n\tpublic Crontab getCrontab();\n\t\n\t/** \n\t * Get the CrontabEntryDAO for looking at tasks\t \n\t *\n\t *@return The CrontabEntryDAO.\n\t */\n\tpublic CrontabEntryDAO getContrabEntryDAO();\n\t\n\t/** \n\t * Report whether JCrontab instance is actually\n\t * running or not.\t \n\t *\n\t *@return Whether it is running or not.\n\t */\n\tpublic boolean isRunning();\n}",
"@Override\n\tpublic void execute(JobExecutionContext arg0) throws JobExecutionException {\n\t\t new SchoolMsgService().writeIntoSchoolMsg_ReceivedStu();\n//\t\t System.out.println(\"just test: \" + new Date());\n\t}",
"public void scheduleJob(ConversionJob tjob, Trigger trig){\n\t\tjobscheduler.scheduleJob(tjob,trig);\n\t\tjlog.info(\"Schedule Job \"+tjob.getFullName()+\"/\"+trig.getFullName());\n\t}",
"@Override\n public void run() {\n\n\n\n System.out.println(\"run scheduled jobs.\");\n\n\n checkBlackOutPeriod();\n\n\n\n checkOfficeActionPeriod1();\n\n checkAcceptedFilings();\n\n checkNOAPeriod();\n checkFilingExtensions();\n\n\n\n }",
"TimerSchedule createTimerSchedule();",
"public void schedule(String id, String[] schedule) {\n\t}",
"@Test\n public void testTask() throws InterruptedException {\n\n SchedulingRunnable task1 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task1, \"0/15 * * * * ?\");\n Thread.sleep(10000);\n\n SchedulingRunnable task2 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task2, \"0/8 * * * * ?\");\n // 便于观察\n\n Thread.sleep(3000000);\n }",
"void setSchedule(java.lang.String schedule);",
"public static void main(String[] args) {\n\t SimpleDateFormat DateFormat = new SimpleDateFormat(\"yyyyMMddHHmmss\"); \n\t Date d = new Date(); \n\t String returnstr = DateFormat.format(d); \n\t \n\t QuartzPush job = new QuartzPush(); \n\t String job_name =\"11\"; \n\t try {\n\t\t\t\tSystem.out.println(\"★★★★★★★★★★★ \"+\"The QuartzPush Strat,Date is \" +returnstr +\" ★★★★★★★★★★★\");\n\t\t\t\tClass jobClass = Class.forName(\"com.tinytree.job.QuartzPush\");\n\t\t\t\tMap<String ,Object> map = new HashMap<>();\n\t\t\t\tmap.put(\"name\",\"testname\");\n\t\t\t\tmap.put(\"jobName\",\"testname\");\n\t\t\t\tmap.put(\"jobGroup\",\"group\");\n\t\t\t\tmap.put(\"group\",\"group\");\n\t\t\t\tmap.put(\"jobClass\",\"com.tinytree.job.QuartzPush\");\n\t\t\t\t//String cronExpression = \"0 37 16 ? * *\";\n\t\t\t\tString cronExpression = \"0/10 * * * * ?\";//\"0 37 16 ? * *\"\n\t\t\t\tmap.put(\"cronExpression\",cronExpression);\n\n\t QuartzManager.addJob(map);\n\n\t \n\t } catch (Exception e) { \n\t e.printStackTrace(); \n\t } \n\t }",
"void sendScheduledNotifications(JobProgress progress);",
"@Override\n public void run() {\n schedule();\n }",
"public boolean isScheduled();",
"@Scheduled(cron = \"*/10 * * * * *\")\n\tpublic void startJob() {\n\n\t\tBooleanBuilder booleanIssuer = new BooleanBuilder();\n\t\tbooleanIssuer.and(QIssuer.issuer.status.eq(Issuer.Status.ACTIVE));\n\n\t\tQIssuer qIssuer = QIssuer.issuer;\n\t\tJPAQuery<?> query = new JPAQuery<Void>(entityManager);\n\t\tList<Issuer> listIssuer = query.select(qIssuer).from(qIssuer).where(booleanIssuer).fetch();\n\n\t\tfor (Issuer issuer : listIssuer) {\n\t\t\tSystem.out.println(issuer.toString());\n\t\t}\n\n\t\tFileWriter fileWirter = null;\n\t\tif (!(CollectionUtils.isEmpty(listIssuer))) {\n\t\t\ttry {\n\t\t\t\tfileWirter = new FileWriter(\"test.csv\");\n\t\t\t\tfileWirter.append(FILE_HEADER.toString());\n\t\t\t\tfileWirter.append(NEW_LINE_SEPARATOR);\n\n\t\t\t\tfor (Issuer issuer : listIssuer) {\n\n\t\t\t\t\tfileWirter.append(String.valueOf(issuer.getId()));\n\t\t\t\t\tfileWirter.append(COMMA_DELIMITER);\n\n\t\t\t\t\tfileWirter.append(issuer.getIssuerCode());\n\t\t\t\t\tfileWirter.append(COMMA_DELIMITER);\n\n\t\t\t\t\tfileWirter.append(issuer.getName());\n\t\t\t\t\tfileWirter.append(COMMA_DELIMITER);\n\n\t\t\t\t\tfileWirter.append(String.valueOf(issuer.getStatus()));\n\t\t\t\t\tfileWirter.append(COMMA_DELIMITER);\n\t\t\t\t\tfileWirter.append(String.valueOf(issuer.getLastUpdate()));\n\t\t\t\t\tfileWirter.append(NEW_LINE_SEPARATOR);\n\n\t\t\t\t}\n\n\t\t\t\tSystem.out.println(\"writer successfully !\");\n\n\t\t\t} catch (IOException e) {\n\t\t\t\tslackService.send(\" \" + e.getMessage());\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\n\t}",
"public Job getJob();",
"public interface SchedulerService {\n\n /**\n * Schedule cron jobs.\n */\n void scheduleCronJobs() throws WorkflowException;\n\n}",
"@Scheduled(cron = \"0 0 10 17 8 ?\")\n\tpublic void scheduleTaskYearly() {\n\t\tlog.info(\"Cron Task :: Execution Time Every 10:00 o'clock in 17 August - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"public AutomaticJob() {\r\n \r\n }",
"public interface SchedulerProvider {\n Scheduler background();\n Scheduler ui();\n}",
"public String getSchedule() {\n return schedule;\n }",
"public Scheduler getScheduler()\r\n/* 30: */ {\r\n/* 31: 73 */ return this.scheduler;\r\n/* 32: */ }",
"protected abstract void scheduler_init();",
"@Override\n protected Scheduler createScheduler() {\n return new JLScheduler(this) {\n @Override\n public List<Goal> goals(Job job) {\n List<Goal> goals= super.goals(job);\n Goal endGoal = goals.get(goals.size()-1);\n if (!(endGoal.name().equals(\"End\"))) {\n throw new IllegalStateException(\"Last goal is not an End goal?\");\n }\n endGoal.addPrereq(new IRGoal(job, fSourceLoader));\n return goals;\n }\n };\n }",
"@Override\n public void execute(JobExecutionContext context) {\n\n JobDataMap dataMap = context.getJobDetail().getJobDataMap();\n\n Long dataSourceId = dataMap.getLong(DataVinesConstants.DATASOURCE_ID);\n\n LocalDateTime scheduleTime = DateUtils.date2LocalDateTime(context.getScheduledFireTime());\n LocalDateTime fireTime = DateUtils.date2LocalDateTime(context.getFireTime());\n\n logger.info(\"scheduled fire time :{}, fire time :{}, dataSource id :{}\", scheduleTime, fireTime, dataSourceId);\n logger.info(\"scheduled start work , dataSource id :{} \", dataSourceId);\n\n CatalogMetaDataFetchTaskService catalogMetaDataFetchTaskService = getJobExternalService().getCatalogTaskService();\n CatalogRefresh catalogRefresh = new CatalogRefresh();\n catalogRefresh.setDatasourceId(dataSourceId);\n\n DataSource dataSource = getJobExternalService().getDataSourceService().getDataSourceById(dataSourceId);\n if (dataSource == null) {\n logger.warn(\"dataSource {} is null\", dataSourceId);\n return;\n }\n\n catalogMetaDataFetchTaskService.refreshCatalog(catalogRefresh);\n }",
"public Schedule() {\r\n }",
"public void scheduleItem(IItem itemToSchedule, BankFusionEnvironment env) {\n }",
"@SystemAPI\npublic interface ScheduleEvent extends IOperation {\n\t/**\n\t * \n\t * @return\tDe duur van de planbare actie (in Millis)\n\t */\n\tpublic TimeDuration getDuration();\n\t\n\t/**\n\t * \n\t * @return\tDe periode waarop de actie gescheduled is\n\t * \t\t\tDit wordt ingesteld door de Scheduler\n\t */\n\t@SystemAPI\n\tpublic TimePeriod getScheduledPeriod(); \n\t\n\t/**\n\t * Als de schedulable specifieke resources nodig heeft, bv. een bepaalde \n\t * dokter of verpleegster, dan komen deze in de onderstaande List.\n\t * @return\t\tDe lijst met specifieke resources die nodig zijn.\n\t */\n\tpublic List<ScheduleResource> neededSpecificResources();\n\t\n\t/**\n\t * \n\t * @return\tEen lijst met de nodige resources.\n\t */\n\tpublic List<ResourceType> neededResources();\n\t\n\t/**\n\t * Zet de periode wanneer de actie gescheduled is.\n\t * @param scheduledPeriod\tDe nieuwe geplande periode\n\t * @param usesResources\tDe resources die gebruikt worden bij het plannen\n\t * @param campus De campus die gebruikt wordt bij het plannen\n\t * @throws SchedulingException Als er niet gepland kan worden\n\t */\n\tpublic void schedule(TimePeriod scheduledPeriod, List<ScheduleResource> usesResources, Campus campus) throws SchedulingException;\n\t\t\n\t/**\n\t * Een methode om te controleren of de events behorende bij een warenhuis gepland kunnen worden.\n\t * @param warehouse\n\t * \t\t Het warenhuis waar gepland moet worden\n\t * @return true\n\t * \t\t Als er gepland kan worden\n\t * @return false\n\t * \t\t Als er niet gepland kan worden\n\t */\n\tpublic boolean canBeScheduled(Warehouse warehouse) ;\n\t\n\t/**\n\t * Een methode om een warehuis te updaten. Met de booleanse waarde\n\t * kan de actie ongedaan gemaakt worden.\n\t * \n\t * @param warehouse\n\t * \t\t Het warenhuis geupdate moet worden\n\t * @param inverse\n\t * \t\t De soort update\n\t */\n\tpublic void updateWarehouse(Warehouse warehouse, boolean inverse) ;\n\t\n\t/**\n\t * Een methode om de prioriteit op te vragen.\n\t * @return\n\t */\n\tpublic Priority getPriority() ;\t\n\t\n\t/**\n\t * Methode die de campus waarop deze actie wordt uitgevoerd opslaat, zodat\n\t * ze later kan gereproduceerd worden wanneer er geannuleerd werd.\n\t * @param \tcampus\n\t * \t\t\tDe CampusId van de campus die moet opgeslagen worden\n\t */\n\tpublic void setHandlingCampus(CampusId campus) ;\n\t\n\t/**\n\t * Methode die de opgeslagen campus terug opvraagt.\n\t * @return\tDe opgeslagen campus\n\t */\n\tpublic CampusId getHandlingCampus();\n\t\n\t/**\n\t * \n\t * @return event type\n\t */\n\t@SystemAPI\n\tpublic EventType getEventType();\n\t\n\t/**\n\t * @return start event\n\t */\n\tpublic Event getStart();\n\t\n\t/**\n\t * \n\t * @return stop event\n\t */\n\tpublic Event getStop();\n}",
"public String runPesertaBatchJobScheduled() {\n try {\n JobParameters parameters = new JobParametersBuilder()\n .addString(\"JobId\", \"50\") //mengirim parameter ke job\n .toJobParameters();\n jobLauncher.run(importDataPesertaFromCsv, parameters);\n\n } catch (Exception ex) {\n logger.error(\"ERROR LAUNCH importDataPesertaFromCsvJob : \", ex.getMessage(), ex);\n return \"ERROR LAUNCH importDataPesertaFromCsvJob : \" + ex.getMessage();\n }\n return \"JOB DONE !!\";\n }",
"public interface ScheduledBillService {\n\tpublic void scheduleTaskWithCronExpression();\n}",
"public void setSchedule(CanaryScheduleOutput schedule) {\n this.schedule = schedule;\n }",
"@Override\n public String getEndPoint() {\n return \"/v1/json/schedule\";\n }",
"@Override\n public String getType() {\n return Const.JOB;\n }",
"public int getScheduleMethod() {\n return scheduleMethod;\n }",
"java.lang.String getSnapshotCreationSchedule();",
"public synchronized void schedule(SchedulerTask schedulerTask, SchedulerTaskState initialState)\n {\n ScheduleIterator iterator = schedulerTask.iterator();\n if (timer == null)\n\t\t\tthrow new IllegalStateException(\"Scheduler '\" + getId() + \"' has already been canceled\");\n \n if (this.scheduledTimerTasks.containsKey(schedulerTask.getKey()))\n throw new IllegalStateException(\"Task '\" + schedulerTask.getKey() + \"' has already been scheduled by scheduler '\" + getId() + \"'\");\n \n // register task to be scheduled\n schedulerTask.schedule(this, initialState);\n\n // determine the next execution time\n Date nextExecution = getNextExecution(iterator);\n if (nextExecution == null)\n {\n // no execution desired -> cancel\n schedulerTask.setState(SchedulerTaskState.CANCELED);\n return;\n }\n \n // register for HSQL\n if (schedulerTask.isVisible())\n {\n IDataAccessor accessor = AdminApplicationProvider.newDataAccessor();\n IDataTransaction transaction = accessor.newTransaction();\n try\n {\n // ensure to create an entry in dapplication because of relation constraint\n // Note: Currently this is only needed for ReportRollOutTask since there might\n // exist scheduled reports related to undeployed applications!\n //\n String applName = schedulerTask.getApplicationName();\n Version applVersion = schedulerTask.getApplicationVersion();\n if (applName != null)\n DeployManager.ensureTransientApplication(accessor, transaction, applName);\n else\n {\n // assign tasks with no specific application to the admin application\n //\n applName = DeployManager.ADMIN_APPLICATION_NAME;\n applVersion = Version.ADMIN;\n }\n \n IDataTable table = accessor.getTable(Enginetask.NAME);\n IDataTableRecord record = table.newRecord(transaction);\n record.setValue(transaction, Enginetask.schedulerid, getId());\n record.setValue(transaction, Enginetask.taskid, schedulerTask.getKey());\n // because of long task names (e.g. R\n record.setStringValueWithTruncation(transaction, Enginetask.name, schedulerTask.getName());\n if (schedulerTask.getScope() != null)\n record.setValue(transaction, Enginetask.scope, schedulerTask.getScope().toString());\n record.setStringValueWithTruncation(transaction, Enginetask.taskdetails, schedulerTask.getTaskDetails());\n record.setValue(transaction, Enginetask.ownerid, schedulerTask.getTaskOwner());\n record.setValue(transaction, Enginetask.applicationname, applName);\n record.setValue(transaction, Enginetask.applicationversion, applVersion);\n record.setValue(transaction, Enginetask.taskstatus, schedulerTask.getState().getName());\n record.setValue(transaction, Enginetask.nextexecution, nextExecution);\n transaction.commit();\n } \n catch (Exception ex)\n {\n // just release a warning since the task itself has been registered for the timer\n if (logger.isWarnEnabled())\n\t\t\t\t{\n\t\t\t\t\tlogger.warn(\"Could not register task in DB: \" + schedulerTask, ex);\n\t\t\t\t}\n }\n finally\n {\n transaction.close();\n }\n }\n \n // Schedule the new task the first time\n //\n SchedulerTimerTask timerTask = new SchedulerTimerTask(schedulerTask, iterator);\n scheduledTimerTasks.put(schedulerTask.getKey(), timerTask);\n timer.schedule(timerTask, nextExecution);\n }",
"public void run(){\n Timer time = new Timer(); // Instantiate Timer Object\n\n ScheduledClass st = new ScheduledClass(this.job,this.shm,time,this.stopp); // Instantiate SheduledTask class\n time.schedule(st, 0, this.periodicwait); // Create Repetitively task for every 1 secs\n }",
"@Override\n\t\t\tpublic void subTask(String name) {\n\t\t\t\t\n\t\t\t}",
"private void registerCallHomeJob() {\n String callHomeQuarzExpression = CallHomeJob.buildRandomQuartzExp();\n TaskBase callHomeJob = TaskUtils.createCronTask(\n CallHomeJob.class,\n callHomeQuarzExpression\n );\n log.debug(\"Scheduling CallHomeJob to run at '{}'\", callHomeQuarzExpression);\n taskService.startTask(callHomeJob, false);\n }",
"public Schedule getSchedule() {\r\n\t\treturn schedule;\r\n\t}",
"@Override\n public void fetchScheduled(RuleKey ruleKey) {\n }",
"boolean newWorkingSchedule(WorkingScheduleRequest workingSchedule);",
"public interface Job {\n\n /** unique id for this job that is used as a reference in the service methods */\n String getId();\n\n /** job executor identification that has acquired this job and is going to execute it */\n String getLockOwner();\n\n /** in case this is a timer, it is the time that the timer should fire, in case this \n * is a message, it is null. */\n Date getDueDate();\n\n /** in case this is a timer, it is the time that the timer should fire, in case this \n * is a message, it is null.\n * @deprecated call {@link #getDueDate()} instead */\n @Deprecated\n Date getDuedate();\n\n /** exception that occurred during the last execution of this job. The transaction \n * of the job execution is rolled back. A synchronization is used to create \n * a separate transaction to update the exception and decrement the retries. */\n String getException();\n\n /** number of retries left. This is only decremented when an exception occurs during job \n * execution. The transaction of the job execution is rolled back. A synchronization is used to create \n * a separate transaction to update the exception and decrement the retries. */\n int getRetries();\n\n /** indicates if this job should be executed separate from any other job \n * in the same process instance */\n boolean isExclusive();\n\n /** the related execution */\n Execution getExecution();\n\n /** the related process instance */\n Execution getProcessInstance();\n\n Date getLockExpirationTime();\n\n}",
"@Scheduled(cron = \"0 0/30 8-9 * * *\")\n\tpublic void scheduleTaskCustomHourly() {\n\t\tlog.info(\"Cron Task :: Execution Time Every 8:00, 8:30, 9:00, 9:30 O'clock Every Day - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"public String create(Schedule arg0) {\n\t\treturn null;\n\t}",
"@Override\n public Void run() throws Exception {\n Callable<Job> jobCreator = ReflectionUtils.newInstance(jobConfig.getJobCreator(), jobConfiguration);\n Job job = jobCreator.call();\n job.submit();\n\n // Blocking mode is only for testing\n if(waitForCompletition) {\n job.waitForCompletion(true);\n }\n\n // And generate event with further job details\n EventRecord event = getContext().createEventRecord(\"job-created\", 1);\n Map<String, Field> eventMap = ImmutableMap.of(\n \"tracking-url\", Field.create(job.getTrackingURL()),\n \"job-id\", Field.create(job.getJobID().toString())\n );\n event.set(Field.create(eventMap));\n getContext().toEvent(event);\n return null;\n }",
"public void run() {\n\t\tlog.info(\"Weekly Scheduled Asset Report Job starting >> isMasterInstance:{} and isAuthorInstance:{}.\", isMasterInstance, isAuthorInstance);\r\n\t\tSession session = null;\r\n\t\t\r\n if (isMasterInstance && isAuthorInstance) {\r\n \r\n \tif(sendWeeklyReport) {\r\n\t\t try {\r\n\t\t\t\t\t session = getSession();\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t //TODO- \r\n\t\t\t\t\t String lowerBoundDate = \"2014-06-19\";\r\n\t\t\t\t\t String upperBoundDate = \"2014-06-26\";\r\n\t\t\t\t\t \r\n\t\t\t\t\t String dateRange = lowerBoundDate + \" - \" + upperBoundDate;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t String templatePath = MISReportConstant.REPORT_EMAIL_TEMPLATE;\r\n\t\t\t\t\t Map<String, String> emailParams = MISReportUtil.buildEmailParams(reportType, reportFrequency, dateRange);\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t DataSource reportDatasource = generateReport.generateReport(lowerBoundDate, upperBoundDate, reportType, session);\r\n\t\t\t\t\t\r\n\t\t\t\t\t //Get the UserGroup name for the reporType\t\t\r\n\t\t\t\t\t String userGroup = userManagement.getUserGroup(reportType);\r\n\t\t\t\t\t\r\n\t\t\t\t\t String[] authors = userManagement.getAllUsersOfGroup(userGroup, session);\r\n\t\t\t\t\t\r\n\t\t\t\t\t for(String authorID: authors) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\temailParams.put(MISReportConstant.FIRST_NAME, userManagement.getUserName(authorID, session));\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\temailService.sendEmail(templatePath, emailParams, session, reportDatasource, userManagement.getEmailAddress(authorID, session));\r\n\t\t\t\t\t\r\n\t\t\t\t\t }\r\n\t\t\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t} catch(Exception e) {\r\n\t\t\t\t\t log.error(\"[Exception]\",e);\r\n\t\t\t\t} finally {\r\n\t\t\t\t\tif(session.isLive())\r\n\t\t\t\t\t\tsession.logout();\r\n\t\t\t\t}\r\n\t\t \r\n\t\t log.info(\"Weekly Asset Report Job finished sending {} reports\", reportType);\r\n \t}\r\n \telse {\r\n \t\tlog.info(\"Weekly Asset Report Job not executed>> Enable it from the AEM Felix console to execute\");\r\n \t}\r\n }\r\n \r\n\t}",
"@Override\n protected Scheduler scheduler() {\n return scheduler;\n }",
"public void execute(JobExecutionContext context) {\n\t\t\n\t\tProcessManagerFactoryBean pmfb = new ProcessManagerFactoryBean();\n\t\t\n\t\tCalendar now = Calendar.getInstance();\n\t\t\n\t\tList<SchedulerItem> schedulerItems = this.getAllSchedule();\n\t\t\n\t\tfor (final SchedulerItem item : schedulerItems) {\n\t\t\t\n\t\t\tif (!(item.getStartDate().getTime() <= now.getTimeInMillis())) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\tProcessManagerRemote pm = null;\n\t\t\tProcessInstance instance = null;\n\t\t\t\n\t\t\ttry {\n\t\t\t\tpm = pmfb.getProcessManager();\n\t\t\t\ttry {\n\t\t\t\t\tinstance = pm.getProcessInstance(item.getInstanceId());\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tboolean isError = true;\n\t\t\t\t\n\t\t\t\tif (instance != null) {\n\t\t\t\t\tActivity act = instance.getProcessDefinition().getActivity(item.getTracingTag());\n\n\t\t\t\t\tif (act != null && act instanceof WaitActivity) {\n\t\t\t\t\t\tString status = act.getStatus(instance);\n\t\t\t\t\t\tif (Activity.STATUS_RUNNING.equals(status) || Activity.STATUS_TIMEOUT.equals(status)) {\n\n\t\t\t\t\t\t\tinstance.getProcessTransactionContext().addTransactionListener(new TransactionListener() {\n\n\t\t\t\t\t\t\t\tpublic void beforeRollback(TransactionContext tx) throws Exception {\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tpublic void beforeCommit(TransactionContext tx) throws Exception {\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tpublic void afterRollback(TransactionContext tx) throws Exception {\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tpublic void afterCommit(TransactionContext tx) throws Exception {\n\t\t\t\t\t\t\t\t\tdeleteSchedule(item.getIdx());\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\tact.fireComplete(instance);\n\t\t\t\t\t\t\tisError = false;\n\n\t\t\t\t\t\t} else if (Activity.STATUS_FAULT.equals(status)\n\t\t\t\t\t\t\t\t|| Activity.STATUS_READY.equals(status) \n\t\t\t\t\t\t\t\t|| Activity.STATUS_STOPPED.equals(status) || Activity.STATUS_CANCELLED.equals(status) ) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (isError) {\n\t\t\t\t\tdeleteSchedule(item.getIdx());\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tpm.applyChanges();\t\n\t\t\t\n\t\t\t} catch (Exception e) {\n\t\t\t\ttry {\n\t\t\t\t\tpm.cancelChanges();\n\t\t\t\t} catch (Exception e1) {\n\t\t\t\t\te1.printStackTrace();\n\t\t\t\t}\n\t\t\t} finally{\n\t\t\t\ttry {\n\t\t\t\t\tpm.remove();\n\t\t\t\t} catch (RemoteException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} catch (RemoveException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n//\t\tSystem.out.println(\"scheduler WaitJob execute() end...\");\n\t}",
"public void storeRegularDayTripStationScheduleWithRS();",
"private void schedule( TaskKey aWorkPackage, boolean aCollectionReqBool ) throws Exception {\n ScheduleInternalTO lTO = new ScheduleInternalTO();\n lTO.setSchedDates( new Date(), new Date() );\n lTO.setWorkOrderNo( WORK_ORDER_NO, \"\" );\n lTO.setCollectionRequired( aCollectionReqBool );\n\n STaskBean staskBean = new STaskBean();\n staskBean.setSessionContext( new SessionContextFake() );\n staskBean.schedule( aWorkPackage, lTO, AUTHORIZING_HR );\n\n }",
"private void scheduleOrExecuteJob() {\n try {\n for (TaskScheduler entry : this.schedulers.values()) {\n StandardTaskScheduler scheduler = (StandardTaskScheduler) entry;\n // Maybe other thread close&remove scheduler at the same time\n synchronized (scheduler) {\n this.scheduleOrExecuteJobForGraph(scheduler);\n }\n }\n } catch (Throwable e) {\n LOG.error(\"Exception occurred when schedule job\", e);\n }\n }",
"public RunProcDefJob() {\n\t}",
"@Override\n public void run() {\n createScheduleFile();\n createWinnerScheduleFile();\n }",
"public Schedule getSchedule() {\n\n return schedule;\n }",
"public void onScheduled(long scheduledTime);",
"@Scheduled(cron = \"0 0 8-10 * * *\")\n\tpublic void scheduleTaskHourly() {\n\t\tlog.info(\"Cron Task :: Execution Time Every 8 - 10 O'clock Every Day - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"public AbstractJob(){\n \n }",
"public CronJobTrigger() {\n init();\n }",
"public interface PostExecutionThread {\n Scheduler getScheduler();\n}",
"public interface PostExecutionThread {\n Scheduler getScheduler();\n}",
"public interface PostExecutionThread {\n Scheduler getScheduler();\n}",
"public void setScheduler(Scheduler scheduler)\r\n/* 25: */ {\r\n/* 26: 65 */ this.scheduler = scheduler;\r\n/* 27: */ }"
] | [
"0.822606",
"0.7942527",
"0.7766178",
"0.7758761",
"0.7250524",
"0.7180258",
"0.6820567",
"0.6815108",
"0.6800957",
"0.67385656",
"0.66911256",
"0.6690968",
"0.6665913",
"0.66137576",
"0.6505845",
"0.65022796",
"0.6410479",
"0.64088",
"0.64030707",
"0.6400947",
"0.63785756",
"0.63760805",
"0.63657963",
"0.63645107",
"0.63615775",
"0.6357437",
"0.6335488",
"0.63272136",
"0.6326474",
"0.6316179",
"0.6305703",
"0.6285642",
"0.62796843",
"0.6265417",
"0.6263017",
"0.62383974",
"0.6232595",
"0.6224695",
"0.6198215",
"0.6185785",
"0.6176818",
"0.6171326",
"0.61681175",
"0.61612177",
"0.61584073",
"0.61473274",
"0.6146783",
"0.6136777",
"0.61204845",
"0.61188954",
"0.61185205",
"0.61180216",
"0.6100762",
"0.609473",
"0.6081391",
"0.607295",
"0.60717916",
"0.6063509",
"0.60589004",
"0.605139",
"0.60460734",
"0.6022018",
"0.6021504",
"0.5994497",
"0.5988168",
"0.5986096",
"0.598279",
"0.5974619",
"0.5963617",
"0.59589654",
"0.5953818",
"0.59516466",
"0.594953",
"0.59467894",
"0.5945068",
"0.59285027",
"0.59199756",
"0.5918214",
"0.5917444",
"0.5916734",
"0.5892851",
"0.5879298",
"0.5876245",
"0.5874966",
"0.58677787",
"0.58511955",
"0.5846126",
"0.58347994",
"0.5833942",
"0.5826976",
"0.58240193",
"0.58219576",
"0.58210695",
"0.5819919",
"0.5806874",
"0.5805377",
"0.5796654",
"0.57911265",
"0.57911265",
"0.57911265",
"0.57888997"
] | 0.0 | -1 |
Decides if the update should fail if no matching handler is found for the loaded event type. | public Builder withFailOnMissingHandler(boolean failOnMissingHandler) {
this.failOnMissingHandler = failOnMissingHandler;
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"boolean handlesEventsOfType(RuleEventType type);",
"public boolean check(EventType event);",
"public void checkHandler()\n {\n ContextManager.checkHandlerIsRunning();\n }",
"public boolean isEventUpdated(Event event) \n\t{\n\t\treturn false;\n\t}",
"@Override\n protected boolean acceptEvent(BuilderEvent event)\n {\n if (getEventType() == null)\n {\n return false;\n }\n assert event != null : \"Event is null!\";\n\n Class<?> eventClass = event.getClass();\n try\n {\n Method method = eventClass.getMethod(METHOD_TYPE);\n Object eventType = method.invoke(event);\n if (eventType instanceof Enum<?>)\n {\n return getEventType().equals(((Enum<?>) eventType).name());\n }\n }\n catch (Exception ex)\n {\n // All exceptions cause the event to be not accepted\n }\n\n return false;\n }",
"protected abstract boolean supportsForUpdate();",
"@Override\r\n\tpublic boolean handleEvent(IEvent event) {\n\t\treturn false;\r\n\t}",
"private void checkForReload(@NotNull List<? extends VFileEvent> events) {\n LOG.debug(\"Checking received events for a possible reloading\");\n boolean toReload = false;\n for (VFileEvent event : events) {\n final VirtualFile file = event.getFile();\n if (LOG.isTraceEnabled()) {\n LOG.trace(\"Checking the file \" + file);\n }\n if (file != null && file.getName().endsWith(KAMELETS_FILE_SUFFIX)) {\n String canonicalPath = file.getCanonicalPath();\n if (canonicalPath == null || canonicalPath.contains(\"/\" + KAMELETS_DIR + \"/\")) {\n LOG.debug(\"An event on a potential Kamelet has been detected\");\n toReload = true;\n }\n }\n }\n if (toReload) {\n LOG.debug(\"At least one event on a Kamelet has been detected, the Kamelets will be reloaded\");\n this.kamelets = null;\n }\n }",
"@Test\r\n\tpublic final void testTableChangedHandler() throws Exception {\t\t\r\n\t\tlistener.setLock();\r\n\t\tassertFalse(listener.tableChangedHandler(e1));\r\n\t\tlistener.unsetLock();\r\n\t\tassertTrue(listener.tableChangedHandler(e1));\r\n\t}",
"@Subscribe\n public void handleFallback(Object event) {\n if (!LOG.isVerboseEnabled()) {\n return;\n }\n if (EXPLICITLY_HANDLED_EVENT_TYPES.contains(event.getClass())) {\n return;\n }\n LOG.verbose(\"%s\", event);\n }",
"public boolean isSyntheticUpdate()\n {\n boolean fResult = false;\n\n switch (m_syntheticKind)\n {\n case JCACHE_SYNTHETIC_CLEAR:\n case JCACHE_SYNTHETIC_UPDATE:\n fResult = true;\n break;\n\n case JCACHE_SYNTHETIC_NONE:\n case JCACHE_SYNTHETHIC_LOADED:\n fResult = false;\n break;\n }\n\n return fResult;\n }",
"protected boolean _isEventForSuccessfulUpdate(final PersistenceOperationOKEvent opEvent) {\n\t\tPersistenceOperationOK opResult = opEvent.getResultAsOperationOK();\n\t\tboolean handle = _crudOperationOKEventFilter.hasTobeHandled(opEvent);\n\t\tif (!handle) return false;\n\t\t\n\t\treturn ((opResult.isCRUDOK()) \n\t\t\t && (opResult.as(CRUDOK.class).hasBeenUpdated()));\t\t\t\t\t\t\t\t// it's an update event\n\t}",
"private boolean shouldRunCallbacks(PathChildrenCacheEvent.Type type, String path) {\n if (path == null) {\n return false;\n }\n\n String runtimeIdentity = runtimeProperties.get().getRuntimeIdentity();\n String currentVersion = getContainerVersion(runtimeIdentity);\n return (path.startsWith(ZkPath.CONTAINERS.getPath()) && type.equals(PathChildrenCacheEvent.Type.CHILD_UPDATED)) ||\n path.equals(ZkPath.CONFIG_ENSEMBLES.getPath()) ||\n path.equals(ZkPath.CONFIG_ENSEMBLE_URL.getPath()) ||\n path.equals(ZkPath.CONFIG_ENSEMBLE_PASSWORD.getPath()) ||\n path.equals(ZkPath.CONFIG_CONTAINER.getPath(runtimeIdentity)) ||\n (currentVersion != null && path.equals(ZkPath.CONFIG_VERSIONS_CONTAINER.getPath(currentVersion, runtimeIdentity)));\n }",
"private void checkErrorListener(final EventType<? extends ConfigurationErrorEvent> type, final EventType<?> opType, final String key, final Object value) {\n final Throwable exception = listener.checkEvent(type, opType, key, value);\n assertInstanceOf(SQLException.class, exception);\n listener = null; // mark as checked\n }",
"public abstract boolean canHandle(Object event);",
"public void checkEvents()\n\t{\n\t\t((MBoxStandalone)events).processMessages();\n\t}",
"boolean hasUpdate();",
"boolean hasUpdate();",
"public boolean isTypeSpecificChange()\r\n {\r\n return myDTIKey != null;\r\n }",
"boolean hasEvent();",
"private boolean shouldProcessEvent(TimeSeriesEvent e) {\r\n return modCountOnLastRefresh < e.getSeriesModCount();\r\n }",
"private void verifyContainsFetchAlarm(ScheduleFetchEvent.TYPE type) {\n verify(mDefaultEventBus, atLeastOnce()).post(mPostEventCaptor.capture());\n List<Object> events = mPostEventCaptor.getAllValues();\n assertTrue(events.size() > 0);\n Log.d(Constants.TAG, \"\\n expected type: \" + type);\n boolean isContain = false;\n for (Object event : events) {\n Log.d(Constants.TAG, \"::::::\" + event);\n if (event instanceof ScheduleFetchEvent && ((ScheduleFetchEvent) event).getType() == type) {\n isContain = true;\n }\n }\n if (!isContain) {\n fail(\"Do not have FetchAlarm: \" + type);\n }\n }",
"@SuppressWarnings({ \"unused\" })\r\n\tprivate void wrongType(final @NonNull PInputEvent e, final String eventType) {\n\t}",
"private void checkDatabaseStructure(DatabaseUpdateType update) {\n }",
"public void testHandlerWithNoAction() throws Exception {\n DefDescriptor<ComponentDef> componentDefDescriptor = addSourceAutoCleanup(ComponentDef.class,\n \"<aura:component><aura:registerevent name='somename' type='handleEventTest:event'/>\"\n + \"<aura:handler name='somename' /></aura:component>\");\n try {\n componentDefDescriptor.getDef();\n fail(\"Expected InvalidDefinitionException\");\n } catch (Exception e) {\n checkExceptionFull(e, InvalidDefinitionException.class, \"aura:handler missing attribute: action=\\\"…\\\"\",\n componentDefDescriptor.getQualifiedName());\n }\n }",
"boolean hasTsUpdate();",
"@Test\n public void launchesEventhandlerUpdatelastmodificationTest() {\n // TODO: test launchesEventhandlerUpdatelastmodification\n }",
"public boolean isHandled() \n { return (eventAction != null) ? eventAction.isHandled() : false; }",
"private boolean registerHandlerImpl(Class<? extends Packet> packetType, PacketHandler handler) {\n\t\tif(handlers.containsKey(packetType)) {\n\t\t\treturn false; //Don't overwrite an existing handler\n\t\t} else {\n\t\t\thandlers.put(packetType, handler);\n\t\t\treturn true;\n\t\t}\n\t}",
"@Test\n public void testGetHandlerForInvalidContainerType() {\n ContainerProtos.ContainerType invalidContainerType =\n ContainerProtos.ContainerType.forNumber(2);\n\n Assert.assertEquals(\"New ContainerType detected. Not an invalid \" +\n \"containerType\", invalidContainerType, null);\n\n Handler dispatcherHandler = dispatcher.getHandler(invalidContainerType);\n Assert.assertEquals(\"Get Handler for Invalid ContainerType should \" +\n \"return null.\", dispatcherHandler, null);\n }",
"@Override\r\n\t\t\t\t\tpublic void changedUpdate(DocumentEvent e) {\n\t\t\t\t\t\tcheckID();\r\n\t\t\t\t\t}",
"private static boolean checkIfToUpdateAfterCreateFailed(LocalRegion rgn, EntryEventImpl ev) {\n boolean doUpdate = true;\n if (ev.oldValueIsDestroyedToken()) {\n if (rgn.getVersionVector() != null && ev.getVersionTag() != null) {\n rgn.getVersionVector().recordVersion(\n (InternalDistributedMember) ev.getDistributedMember(), ev.getVersionTag());\n }\n doUpdate = false;\n }\n if (ev.isConcurrencyConflict()) {\n if (logger.isDebugEnabled()) {\n logger.debug(\"basicUpdate failed with CME, not to retry:\" + ev);\n }\n doUpdate = false;\n }\n return doUpdate;\n }",
"public abstract void handlerCheckState(int status, Object attach);",
"boolean hasImageByHandler();",
"public boolean maybeRefreshManifestOnLoadingError(Chunk chunk) {\n if (!this.manifest.dynamic) {\n return false;\n }\n if (this.isWaitingForManifestRefresh) {\n return true;\n }\n long j = this.lastLoadedChunkEndTimeUs;\n if (!(j != -9223372036854775807L && j < chunk.startTimeUs)) {\n return false;\n }\n maybeNotifyDashManifestRefreshNeeded();\n return true;\n }",
"@Override\r\n\tpublic boolean onUpdate(Session arg0) throws CallbackException {\n\t\treturn false;\r\n\t}",
"boolean hasChangeEvent();",
"boolean hasUpdateTriggerTime();",
"protected boolean checkForMatch(NewEvent event) {\n\t\tevent.export(exporter);\n\t\treturn exporter.checkForMatch(pattern);\n\t}",
"@Test\n public void testLoadOptionalErrorEvent() throws Exception\n {\n factory.clearErrorListeners();\n ConfigurationErrorListenerImpl listener = new ConfigurationErrorListenerImpl();\n factory.addErrorListener(listener);\n prepareOptionalTest(\"configuration\", false);\n listener.verify(DefaultConfigurationBuilder.EVENT_ERR_LOAD_OPTIONAL,\n OPTIONAL_NAME, null);\n }",
"private void checkStructure() {\n for (DatabaseUpdateType updateType : DatabaseUpdateType.values()) {\n checkDatabaseStructure(updateType);\n }\n }",
"protected boolean _isEventForSuccessfulCreateUpdateOrDelete(final PersistenceOperationOKEvent opEvent) {\t\n\t\tPersistenceOperationOK opResult = opEvent.getResultAsOperationOK();\n\t\tboolean handle = _crudOperationOKEventFilter.hasTobeHandled(opEvent);\n\t\tif (!handle) return false;\n\t\t\n\t\treturn ((opResult.isCRUDOK()) \n\t\t\t && (opResult.as(CRUDOK.class).hasBeenCreated() || opResult.as(CRUDOK.class).hasBeenUpdated() || opResult.as(CRUDOK.class).hasBeenDeleted()));\t// it's a create, update or delete event\n\t}",
"private boolean checkInstructionHandler(CodeAtt attribute) {\n //todo\n return false;\n }",
"public void onUpdateFailure();",
"@Override\n public String getHandlerName() {\n return \"UpdateHandler\";\n }",
"private boolean checkHook(PluginHook name)\n\t{\n\t\tif (hooks.containsKey(name))\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}",
"public boolean canHandleOutdatedMessaged() {\n\t return false;\n\t}",
"void broken(TwoWayEvent.Broken<DM, UMD, DMD> evt);",
"boolean hasUpdateUfsMode();",
"public static void legacyCheck()\r\n {\r\n isLoaded = Loader.isModLoaded(\"dungeontweaks\");\r\n \r\n if(!isLoaded)\r\n {\r\n return;\r\n }\r\n \r\n try\r\n {\r\n Class c = Class.forName(\"com.EvilNotch.dungeontweeks.main.Events.EventDungeon$Post\");\r\n isLegacy = true;\r\n }\r\n catch (Throwable t)\r\n {\r\n\r\n }\r\n }",
"@Override\n\t\t\t\t\tpublic void loadEndFailed(int type) {\n\n\t\t\t\t\t}",
"private boolean isWholeGameEvent(String eventType){\n return eventType.equals(\"Stonks\") || eventType.equals(\"Riot\") || eventType.equals(\"Mutate\") || eventType.equals(\"WarpReality\");\n }",
"@Override\n\tpublic boolean supportsUpdate() {\n\t\treturn false;\n\t}",
"public boolean hasListener(int type) {\n assert type > 0 : \"Invalid event type: \" + type;\n\n Listeners listeners = lsnrs.get(type);\n\n return (listeners != null) && (!F.isEmpty(listeners.highPriorityLsnrs) || !F.isEmpty(listeners.lsnrs));\n }",
"public boolean tryEditingScheduledEvent();",
"@Override\r\n public boolean eventSourcing(){\n loadSnapshot();\r\n\r\n // check offsets value\r\n\r\n // rerun events\r\n\r\n // rerun commands\r\n\r\n // print es results\r\n\r\n return true;\r\n }",
"default boolean pollOnExecutionFailed() {\n return false;\n }",
"@Override\n\tprotected void isLoaded() throws Error {\n\t\t\n\t}",
"@Override\n\tprotected void isLoaded() throws Error {\n\t\t\n\t}",
"public void handle(Object e){\n\t\tif(e.getClass().equals(GetResultRequestEvent.class)){\n\t\t\tgetResults((GetResultRequestEvent)e);\n\t\t}else if(e.getClass().equals(RefreshAllDataEvent.class)){\n\t\t\ttf.getData(app);\n\t\t}else if(e.getClass().equals(ExportDataEvent.class)){\n\t\t\ttf.exportItemDB();\n\t\t}\n\t}",
"@Override\n\tprotected void isLoaded() throws Error \n\t{\n\t\t\n\t}",
"public void testEventAdditionalTypes() throws Exception\n {\n checkEventTypeRegistration(EVENT_TYPE_BUILDER,\n \"testTree -> MOUSE, testTree -> CHANGE\");\n }",
"boolean onEvent(Event event);",
"@Override\n public void changedUpdate(DocumentEvent e) {\n verifierSaisie();\n }",
"public void repair(EventType event);",
"@Override\n public boolean isHandled() {\n return handled;\n }",
"public static void enableSuggestedEvents() {\n if (models.containsKey(MODEL_SUGGESTED_EVENTS)) {\n Locale resourceLocale = Utility.getResourceLocale();\n if (resourceLocale == null || resourceLocale.getLanguage().contains(\"en\")) {\n FeatureManager.checkFeature(FeatureManager.Feature.SuggestedEvents, new FeatureManager.Callback() {\n /* class com.facebook.appevents.ml.ModelManager.AnonymousClass2 */\n\n @Override // com.facebook.internal.FeatureManager.Callback\n public void onCompleted(boolean z) {\n if (z) {\n ((Model) ModelManager.models.get(ModelManager.MODEL_SUGGESTED_EVENTS)).initialize(new Runnable() {\n /* class com.facebook.appevents.ml.ModelManager.AnonymousClass2.AnonymousClass1 */\n\n public void run() {\n SuggestedEventsManager.enable();\n }\n });\n }\n }\n });\n }\n }\n }",
"@Override\n\tpublic void update(Observable observable, Object data) {\n\t\tif(data instanceof STBEvent) {\n\t\t\t\n\t\t}\n\t}",
"public boolean match(Event e);",
"@Override\n protected void addHandlerFor( final MessageEvent eventType, final MessageEventHandler<MessageEvent> handler )\n throws HandlerRegistrationException {\n if ( containsHandlerFor( eventType ) ) {\n // if the handler already exists for the same eventType, an Exception is thrown\n final List<MessageEventHandler<MessageEvent>> handlers = getHandlersFor( eventType );\n\n // Check if another handler of the same class is already registered\n for ( MessageEventHandler<MessageEvent> tmpHandler : handlers ) {\n if ( tmpHandler.getIdentifier().equals( handler.getIdentifier() ) ) {\n throw new HandlerRegistrationException(\n \"The handler with identifier \" + tmpHandler.getIdentifier() + \" is already registered for the event \"\n + eventType );\n }\n }\n\n handlers.add( handler );\n } else {\n // if the given type doesn't already exist in the eventFilters list, we create it\n final List<MessageEventHandler<MessageEvent>> newHandlerList =\n new ArrayList<MessageEventHandler<MessageEvent>>( 10 );\n newHandlerList.add( handler );\n registeredHandlers.put( eventType, newHandlerList );\n }\n }",
"@Override\r\n\tpublic boolean isHandled() {\n\t\treturn true;\r\n\t}",
"private boolean updateCache(String type) {\n\t\treturn false;\n\t}",
"@Test\n public void testWithUndefinedSelection() {\n TestUpdateSettings settings = new TestUpdateSettings(ChannelStatus.EAP);\n UpdateStrategyCustomization customization = new UpdateStrategyCustomization();\n UpdateStrategy strategy = new UpdateStrategy(9, BuildNumber.fromString(\"IU-98.520\"), InfoReader.read(\"idea-same.xml\"), settings, customization);\n\n CheckForUpdateResult result = strategy.checkForUpdates();\n assertEquals(UpdateStrategy.State.LOADED, result.getState());\n assertNull(result.getNewBuildInSelectedChannel());\n }",
"@Override\n public boolean canUpdate() { return false; }",
"protected abstract <E extends Event> List<EventHandler<? extends Event>> lookupHandlers(final E event);",
"boolean isSetEvent();",
"@Override\n\tpublic boolean beforeHandle(BaseEvent event) {\n\t\treturn false;\n\t}",
"@Override\r\n\tprotected void processIsNotDefinedEvent(InNotDefinedEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void onUpdateReceived(Update update) {\t\t\t\r\n\t\tif (update.hasMessage() && update.getMessage().isCommand()){//Si es un comando...\r\n\t\t\thandleCommand(update.getMessage().getText(),update);\r\n\t\t} else if(update.hasMessage() && update.getMessage().hasText()){//Si es un mensaje...\r\n\t\t\thandleMessage(update.getMessage(), update);\r\n\t\t} else if (update.hasCallbackQuery()){//Si es una pulsacion de boton de un teclado...\r\n\t\t\ttry {\r\n\t\t\t\thandleCallbackQuery(update);\r\n\t\t\t} catch (TelegramApiException e) {\r\n\t\t\t\tBotLogger.error(LOGTAG, e);//Guardamos mensaje y lo mostramos en pantalla de la consola.\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t} else if (update.hasInlineQuery()){//Si es una consulta inline...\r\n\t\t\thandleInlineQuery(update);\r\n\t\t}\t\t\r\n\t}",
"public abstract boolean isLoadCompleted();",
"public boolean hasImageByHandler() {\n return ((bitField0_ & 0x00001000) == 0x00001000);\n }",
"private void checkEventClash() {\n\t\tif (isClashing()) {\n\t\t\treturnMsg += MESSAGE_EVENT_CLASH;\n\t\t}\n\t}",
"@Test(description = \"update interface with one type for non existing interface\")\n public void updateOneType4NonExisting()\n throws Exception\n {\n final DataCollection data = new DataCollection(this);\n final TypeData type = data.getType(\"TestType\");\n data.create();\n\n final InterfaceData inter = data.getInterface(\"TestInterface\").addType(type);\n this.update(inter);\n\n Assert.assertEquals(this.mql(\"print interface '\" + inter.getName() + \"' select type dump\"),\n type.getName(),\n \"check that only one type is defined\");\n }",
"public boolean handleEvent(Event e){\r\n\t\tthis.handledEvents++;\r\n\t\tif(this.ptModes.contains(super.getMode())){\r\n\t\t\thandler.handleEvent(e);\r\n\t\t\tif(this.handledEvents == this.nrOfExpEvents){\r\n\t\t\t\thandler.finish(this);\r\n\t\t\t\treturn true;\r\n\t\t\t}else{\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}else{\r\n\t\t\tif(first == null){\r\n\t\t\t\tfirst = e.getTime();\r\n\t\t\t}else{\r\n\t\t\t\tlast = e.getTime();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(this.handledEvents == nrOfExpEvents){\r\n\t\t\t\tthis.tripTTime = last - first;\r\n\t\t\t\treturn true;\r\n\t\t\t}else{\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t}",
"@Override\r\n\tpublic <T extends Evento> boolean actualizarEvento(Evento evento) {\n\t\treturn false;\r\n\t}",
"@Override\n\t\t\t\t\tpublic void onUpdateFound(boolean newVersion, String whatsNew) {\n\t\t\t\t\t}",
"private boolean checkForNewData ()\n\t{\t\t\n\t\tLOG.info(\"Checking trigger source '\" + config.getTriggerSource() + \".\" + \n\t\t\t\tconfig.getTriggerTable() + \".\" + config.getTriggerColumn() + \"'\");\n\t\t\n\t\t// get value from source\n\t\tObject newValue = null;\n\t\tint colType = -1;\n\t\ttry \n\t\t{\n\t\t\tSourceDatabase sourceDatabase = CopyToolConnectionManager.getInstance().getSourceDatabase(config.getTriggerSource());\n\t\t\t\n\t\t\tStatement selectStmt =\n\t\t\t\t\tCopyToolConnectionManager.getInstance().getSourceConnection(config.getTriggerSource()).createStatement();\n\t\t\t\n\t\t\tString triggerDate = sourceDatabase.getDatabaseType().getSelectTriggerColumnQuery(config.getTriggerTable(), config.getTriggerColumn());\n\t\t\tResultSet res = selectStmt.executeQuery(triggerDate);\n\t\t\t\n\t\t\t// no rows in table? then we cannot determine any indication\n\t\t\t// so we return indication of new data\n\t\t\tif (!res.next()) return true;\t\t\t\n\t\t\t\n\t\t\tResultSetMetaData info = res.getMetaData();\n\t\t\t\n\t\t\tcolType = info.getColumnType(1);\n\t\t\t\t\t\t\n\t\t\tif (colType == Types.BIGINT || colType == Types.INTEGER)\n\t\t\t{\n\t\t\t\tcolType = Types.BIGINT;\n\t\t\t\tnewValue = res.getLong(1);\n\t\t\t}\n\t\t\telse if (colType == Types.DATE)\n\t\t\t{\n\t\t\t\tnewValue = res.getDate(1);\n\t\t\t}\n\t\t\telse if (colType == Types.TIMESTAMP)\n\t\t\t{\n\t\t\t\tnewValue = res.getTimestamp(1);\n\t\t\t}\n\t\t\t\n\t\t\tres.close();\n\t\t\tselectStmt.close();\n\t\t}\n\t\tcatch (SQLException e)\n\t\t{\n\t\t\tLOG.warn(\"SQLException when trying to access scheduling source\", e);\n\t\t\t\n\t\t\t// return indication of new data since we don't know for sure\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\tif (newValue == null)\n\t\t{\n\t\t\t// return indication of new data since we don't know for sure\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\t// load existing value from disk\n\t\tFile jobFile = getLastRunFile();\n\t\t\n\t\tBufferedReader br = null;\n\t\tString oldValue = null;\n\t\tString oldColType = null;\n\t\tString oldConfigChecksum = null;\n\t\tif (jobFile.exists()) \n\t\t{\n\t\t\ttry {\n\t\t\t\tbr = new BufferedReader(new FileReader(jobFile));\n\t\t\t\toldValue = br.readLine();\n\t\t\t\toldColType = br.readLine();\n\t\t\t\toldConfigChecksum = br.readLine();\n\t\t\t} catch (IOException e) {\n\t\t\t\t// ignore\n\t\t\t\tLOG.warn(\"Unable to read existing lastrun info\", e);\n\t\t\t} finally {\n\t\t try {\n\t\t \tif (br != null)\n\t\t \t\tbr.close();\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t// ignore\n\t\t\t\t}\n\t\t }\n\t\t}\n\t\t\n\t\t// set last run properties\n\t\tthis.lastRunValue = newValue;\n\t\tthis.lastRunColType = colType;\n\t \n\t if (StringUtils.isEmpty(oldValue) || StringUtils.isEmpty(oldColType) || StringUtils.isEmpty(oldConfigChecksum))\n\t {\n\t \t// return indication of new data since we don't know for sure\n\t\t\treturn true;\n\t }\n\t \n\t // check if we are dealing with the same type of data\n\t if (!oldColType.equals(String.valueOf(colType)))\n\t {\n\t \t// return indication of new data since we don't know for sure\n\t \treturn true;\n\t }\n\t \n\t // check if we are dealing with the same config\n\t if (!oldConfigChecksum.equals(config.getConfigChecksum()))\n\t {\n\t \t// return indication of new data since we don't know for sure\n\t \treturn true;\n\t }\n\t \n\t LOG.info(\"Stored last run value: \" + oldValue);\n\t LOG.info(\"Current last run value: \" + newValue);\n\t \n\t // check if there is newer data\n\t if (colType == Types.BIGINT)\n\t {\n\t \tLong oldNum = Long.valueOf(oldValue);\n\t \tLong newNum = (Long) newValue;\n\t \t\n\t \t// is new ID / long bigger than current?\n\t \t// then we have new data\n\t \tif (newNum > oldNum)\n\t \t\treturn true;\n\t }\n\t else if (colType == Types.DATE)\n\t {\n\t \tDate oldDate = Date.valueOf(oldValue);\n\t \tDate newDate = (Date) newValue;\n\t \t\n\t \t// is newer date after older date?\n\t \t// then we have new data\n\t \tif (newDate.after(oldDate))\n\t \t\treturn true;\n\t }\n\t else if (colType == Types.TIMESTAMP)\n\t {\n\t \tTimestamp oldTS = Timestamp.valueOf(oldValue);\n\t \tTimestamp newTS = (Timestamp) newValue;\n\t \t\n\t \t// is newer timestamp after older timestamp?\n\t \t// then we have new data\n\t \tif (newTS.after(oldTS))\n\t \t\treturn true;\n\t }\n\t\t\n\t // no new data\n\t\treturn false;\n\t}",
"protected boolean _isEventForSuccessfulCreateOrUpdate(final PersistenceOperationOKEvent opEvent) {\t\n\t\tPersistenceOperationOK opResult = opEvent.getResultAsOperationOK();\n\t\tboolean handle = _crudOperationOKEventFilter.hasTobeHandled(opEvent);\n\t\tif (!handle) return false;\n\t\t\n\t\treturn ((opResult.isCRUDOK()) \n\t\t\t && (opResult.as(CRUDOK.class).hasBeenCreated() || opResult.as(CRUDOK.class).hasBeenUpdated()));\t// it's a create or update event\n\t}",
"@Override\n\t\t\tpublic void onFail() {\n\t\t\t\tcallBack.onCheckUpdate(-1, null); // 检查出错\n\t\t\t}",
"@Override\n\t\t\t\t\t\t\tpublic void appUpdateFaild() {\n\t\t\t\t\t\t\t\thandler.sendEmptyMessage(1);\n\t\t\t\t\t\t\t}",
"private void tryToConsumeEvent() {\n if (subscriber == null || storedEvent == null) {\n return;\n }\n sendMessageToJs(storedEvent, subscriber);\n\n }",
"private void handleUpdateProxyEvent(UpdateProxyEvent event) throws AppiaEventException {\n \n \t\tevent.loadMessage();\n \n \t\t//Get the parameters\n \t\tEndpt servertThatSentEndpt = event.getServerThatSentEndpt();\n \t\tVsGroup[] passedGroups = event.getAllGroups();\n \n \t\t//Say that the view was received (this also merges the temporary views)\n \t\tUpdateManager.addUpdateMessageReceived(servertThatSentEndpt, passedGroups);\n \n \t\t//If i have received from all live servers\n \t\tif(UpdateManager.receivedUpdatesFromAllLiveServers(vs.view) && amIleader()){\n \t\t\tSystem.out.println(\"Received an update proxy event from all alive and I am leader\");\n \n \t\t\t//Let go get our temporary view\n \t\t\tVsGroup[] newGroupList= UpdateManager.getTemporaryUpdateList();\n \n \t\t\t//Send the nre decided view to all\n \t\t\tUpdateDecideProxyEvent updateDecideProxy = new UpdateDecideProxyEvent(newGroupList);\n \t\t\tsendToOtherServers(updateDecideProxy);\n \t\t\tsendToMyself(updateDecideProxy);\t\t\n \t\t}\n \t}",
"@Override\n\tprotected boolean checkOverride(IEventInstance eventInstance, Operand operand) {\n\t\treturn false;\n\t}",
"@Override\r\n\tpublic boolean canUpdate() {\r\n\t\treturn true;\r\n\t}",
"default boolean isNeedToBeUpdated()\n {\n return getUpdateState().isUpdated();\n }",
"@Override\n public void process(WatchedEvent event) {\n if (Event.EventType.None.equals(event.getType())) {\n return;\n }\n\n Stat stat = null;\n try {\n stat = zkClient.exists(zkDir, null, true);\n } catch (KeeperException e) {\n // ignore , it is not a big deal\n } catch (InterruptedException e) {\n Thread.currentThread().interrupt();\n }\n\n boolean resetWatcher = false;\n try {\n resetWatcher = fireEventListeners(zkDir);\n } finally {\n if (Event.EventType.None.equals(event.getType())) {\n log.debug(\"A node got unwatched for {}\", zkDir);\n } else {\n if (resetWatcher) setConfWatcher(zkDir, this, stat);\n else log.debug(\"A node got unwatched for {}\", zkDir);\n }\n }\n }",
"public boolean updateModule() throws Exception {\n\t\tString newError = (String) errorsSelection.getSelectedItem();\n\t\tif (ErrorFunctionName.equals(newError)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// we have a new error function name.\n\t\tErrorFunctionName = newError;\n\t\treturn true;\n\t}",
"public boolean hasImageByHandler() {\n return ((bitField0_ & 0x00004000) == 0x00004000);\n }",
"public void testWithUndefinedSelection() {\n final TestUpdateSettings settings = new TestUpdateSettings(ChannelStatus.EAP);\n //first time load\n UpdateStrategy strategy = new UpdateStrategy(9, BuildNumber.fromString(\"IU-98.520\"), UpdatesInfoXppParserTest.InfoReader.read(\"idea-same.xml\"), settings);\n\n final CheckForUpdateResult result1 = strategy.checkForUpdates();\n Assert.assertEquals(UpdateStrategy.State.LOADED, result1.getState());\n Assert.assertNull(result1.getNewBuildInSelectedChannel());\n }",
"@Override\n\t\t\t\tpublic void onException(Exception e) {\n\t\t\t\t\tLog.d(\"SD_TRACE\", \"load api exception\" + e.toString());\n\t\t\t\t\tmLoadSuccess = false;\n\t\t\t\t}",
"@objid (\"0480e45a-6886-42c0-b13c-78b8ab8f713d\")\n boolean isIsEvent();"
] | [
"0.58645844",
"0.55981386",
"0.54549754",
"0.54314286",
"0.5362737",
"0.5317935",
"0.5186893",
"0.5154073",
"0.512362",
"0.5122732",
"0.50860316",
"0.5081372",
"0.50443274",
"0.50405514",
"0.50069314",
"0.49942508",
"0.4969595",
"0.4969595",
"0.4969376",
"0.49637142",
"0.4961595",
"0.49546632",
"0.4937941",
"0.49344367",
"0.49263066",
"0.49245414",
"0.49109992",
"0.4896975",
"0.48959458",
"0.48717114",
"0.48495775",
"0.48399627",
"0.48371717",
"0.48126578",
"0.48111403",
"0.47989076",
"0.47869667",
"0.4782373",
"0.47790775",
"0.47671118",
"0.47669432",
"0.47615737",
"0.47511187",
"0.47507587",
"0.47432306",
"0.47431034",
"0.47286782",
"0.47271723",
"0.47259763",
"0.46942675",
"0.4685164",
"0.46735662",
"0.46687883",
"0.4668746",
"0.46628138",
"0.46575063",
"0.46549454",
"0.46403518",
"0.46403518",
"0.46366104",
"0.46284682",
"0.4627965",
"0.46227026",
"0.46153885",
"0.46052343",
"0.46041095",
"0.4601592",
"0.4599982",
"0.4599917",
"0.4582283",
"0.4572347",
"0.4556833",
"0.4554373",
"0.45536807",
"0.4550969",
"0.45465618",
"0.4546416",
"0.4541334",
"0.45410037",
"0.45398647",
"0.45388234",
"0.45347995",
"0.4534653",
"0.45333397",
"0.45279092",
"0.45210716",
"0.45205",
"0.4519423",
"0.45160925",
"0.45156193",
"0.4514782",
"0.45075202",
"0.4503103",
"0.45019227",
"0.45005226",
"0.4498609",
"0.4483191",
"0.44801667",
"0.4478325",
"0.44754413",
"0.44656464"
] | 0.0 | -1 |
Created by Administrator on 2016/9/2. | @Repository
public interface MessagePushDao extends JpaRepository<MessagePush, Long> {
MessagePush findByClientId(String clientId);
MessagePush findByUserIdAndPlatform(long userId, String platform);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private stendhal() {\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"private static void cajas() {\n\t\t\n\t}",
"@Override\n public void settings() {\n // TODO Auto-generated method stub\n \n }",
"public void mo38117a() {\n }",
"public void mo4359a() {\n }",
"@Override\n protected void initialize() {\n\n \n }",
"public final void mo51373a() {\n }",
"public void gored() {\n\t\t\n\t}",
"@Override\n public void memoria() {\n \n }",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\n public void init() {\n\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"public void verarbeite() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\n protected void initialize() \n {\n \n }",
"public contrustor(){\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void autoDetails() {\n\t\t\r\n\t}",
"private Rekenhulp()\n\t{\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"Petunia() {\r\n\t\t}",
"private void init() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"public void mo55254a() {\n }",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\n\tpublic void afterInit() {\n\t\t\n\t}",
"@Override\n\tpublic void afterInit() {\n\t\t\n\t}",
"public void mo6081a() {\n }",
"@Override\n public void init() {\n\n }",
"@Override\n public void init() {\n\n }",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"private TMCourse() {\n\t}",
"public Pitonyak_09_02() {\r\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"private void poetries() {\n\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n void init() {\n }",
"@Override\n\tpublic void create () {\n\n\t}",
"@Override\n public void init() {\n }",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tpublic void create() {\n\t\t\n\t}",
"@Override\n\tprotected void initdata() {\n\n\t}",
"public void mo12930a() {\n }",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n protected void init() {\n }"
] | [
"0.62003464",
"0.6162013",
"0.6080362",
"0.606293",
"0.5987922",
"0.59828216",
"0.5971636",
"0.594515",
"0.5884756",
"0.58738285",
"0.58738285",
"0.5862111",
"0.5862111",
"0.5853303",
"0.58527356",
"0.58402795",
"0.58374065",
"0.5809253",
"0.57971567",
"0.57811105",
"0.5743505",
"0.57381",
"0.5732152",
"0.56670564",
"0.5662939",
"0.5654306",
"0.56478107",
"0.56418884",
"0.5641691",
"0.56414926",
"0.562524",
"0.5620432",
"0.56038666",
"0.55994135",
"0.558941",
"0.5585113",
"0.5583432",
"0.5583432",
"0.5583432",
"0.5583432",
"0.5583432",
"0.5583432",
"0.5583432",
"0.5582695",
"0.55717874",
"0.5567898",
"0.55667746",
"0.5556892",
"0.5556892",
"0.5556892",
"0.5556892",
"0.5556892",
"0.55412775",
"0.5540901",
"0.5526477",
"0.55259097",
"0.55248463",
"0.5521593",
"0.5518791",
"0.5518343",
"0.5518343",
"0.5518343",
"0.55156696",
"0.55156696",
"0.5513585",
"0.5507369",
"0.55048037",
"0.549782",
"0.549782",
"0.5490455",
"0.54761064",
"0.54761064",
"0.5471452",
"0.5471452",
"0.5471452",
"0.5470731",
"0.54665095",
"0.54633963",
"0.54633963",
"0.54633963",
"0.54633963",
"0.54633963",
"0.54633963",
"0.54540026",
"0.5453457",
"0.54517275",
"0.5448965",
"0.5448965",
"0.5448965",
"0.5447865",
"0.5446906",
"0.5441439",
"0.54382366",
"0.54342884",
"0.54322654",
"0.5417169",
"0.5411246",
"0.54087263",
"0.5402698",
"0.5395394",
"0.5393461"
] | 0.0 | -1 |
Get the data item for this position | @Override
public View getView(int position, View convertView, ViewGroup parent) {
Post post = getItem(position);
// Check if an existing view is being reused, otherwise inflate the view
if (convertView == null) {
convertView = LayoutInflater.from(getContext()).inflate(R.layout.item_friend_post, parent, false);
}
// Lookup view for data population
TextView tvUsername = (TextView) convertView.findViewById(R.id.ViewAllPost_Username);
TextView tvDate = (TextView) convertView.findViewById(R.id.ViewAllPost_Date);
TextView tvPlate = (TextView) convertView.findViewById(R.id.ViewAllPost_LicensePlate);
TextView tvDestination = (TextView) convertView.findViewById(R.id.ViewAllPost_Destination);
TextView tvModel = (TextView) convertView.findViewById(R.id.ViewAllPost_CarModel);
TextView tvColor = (TextView) convertView.findViewById(R.id.ViewAllPost_CarColor);
TextView tvDeparture = (TextView) convertView.findViewById(R.id.ViewAllPost_Departure);
// Populate the data into the template view using the data object
tvUsername.setText(post.getOwner());
tvDate.setText(post.getDate());
tvPlate.setText(post.getLicensePlate());
tvDestination.setText(post.getDestination());
tvModel.setText(post.getModel());
tvColor.setText(post.getColor());
tvDeparture.setText(post.getDeparture());
// Return the completed view to render on screen
return convertView;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Item getData()\r\n\t{\r\n\t\treturn theItem;\r\n\t}",
"public E getData(int pos) {\n\t\tif (pos >= 0 && pos < dataSize()) {\n\t\t\treturn data.get(pos);\n\t\t}\n\t\telse {\n\t\t\treturn null;\n\t\t}\n\t}",
"@Override\n\t\tpublic Object getItem(int position) {\n\t\t\treturn mDatas.get(position);\n\t\t}",
"@Override\n public DataItemPosition getItem(int position) {\n return mDatas.get(position);\n }",
"public Object getDataItem() {\n return this.dataItem;\n }",
"public Object getItem(int position) {\n\t\treturn data.get(position);\r\n\t}",
"public Object getItem(int position) {\n return _data.get(position);\n }",
"@Override\n public Object getItem(int position) {\n return data.get(position);\n }",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn data.get(position);\n\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn data.get(position);\n\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn data.get(position);\n\t}",
"@Override\r\n public Object getItem(int position) {\n return data.get(position);\r\n }",
"@Override\r\n\tpublic Object getItem(int position) {\n\t\treturn mData.get(position);\r\n\t}",
"public DataItem getData() {\n return data;\n }",
"@Override\n public Object getItem(int position) {\n return data.get(position);\n }",
"@Override\n public Object getItem(int position) {\n return data.get(position);\n }",
"@Override\r\n\tpublic Object getItem(int position) {\n\t\treturn datas.get(position);\r\n\t}",
"@Override\r\n\tpublic Object getItem(int position) {\n\t\treturn datas.get(position);\r\n\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn datas.get(position);\n\t}",
"@Override\n public Object getItem(int position) {\n return data;\n }",
"public Object getItem(int position) {\n return datalist.get(position);\n }",
"public Object getItem(int position) {\n return dataList.get(position);\n }",
"public GenericItemType getData() {\n return this.data;\n }",
"@Override\r\n\t\tpublic Object getItem(int position) {\n\t\t\treturn listData.get(position);\r\n\t\t}",
"@Override\n public Item getItem(int position) {\n return data.get(position);\n }",
"@Override\n\tpublic Object getItem(int arg0) {\n\t\treturn mData.get(arg0);\n\t}",
"@Override\n\t\tpublic Object getItem(int position) {\n\t\t\treturn mlistData.get(position);\n\t\t}",
"@Override\r\n\tpublic Object getItem(int arg0) {\n\t\treturn mData.get(arg0);\r\n\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn mDataList.get(position);\n\t}",
"public String get(int position) {\r\n lastDataPosition = position;\r\n return data.get(lastDataPosition);\r\n }",
"@Override\n public Object getItem(int position) {\n if(datas != null && position < datas.size() && position >= 0){\n return datas.get(position);\n }\n return null;\n }",
"@Override\r\n\tpublic Object getItem(int arg0) {\n\t\treturn data.get(arg0);\r\n\t}",
"@Override\n public Object getItem(int arg0) {\n return mData.get(arg0);\n }",
"@Override\n public Object getItem(int position) {\n return listData.get(position);\n }",
"@Override\n\tpublic SquareLiveModel getItem(int position) {\n\t\treturn listData.get(position);\n\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn datalist.get(position);\n\t}",
"public Object getItem(int arg0) {\n\t\t\treturn data.get(arg0);\n\t\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn mlvData.get(position);\n\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn dataList.get(position);\n\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn dataList.get(position);\n\t}",
"@Nullable\n public T getItem(@IntRange(from = 0) int position) {\n if (position < mData.size())\n return mData.get(position);\n else\n return null;\n }",
"private String getItem(int position) {\n return data[position - 1];\n }",
"@Override\n public Object getItem(int position) {\n return dataList.get(position);\n }",
"@Override\n\tpublic String getItem(int position) {\n\t\treturn data.get(position);\n\t}",
"public Object getItem(int position) { \n return mDataObjects.get(position); \n }",
"public ListData getItem(int position)\n {\n return values.get(position);\n }",
"public Object getData(){\n\t\treturn this.data;\n\t}",
"@Override\n public Object getItem(int item) {\n return dataList.get(item);\n }",
"@Override\n\tpublic IdValue getItem(int position) {\n\t\treturn idValues.get(position);\n\t}",
"@Override\r\n public Object getChild(int groupPosition, int childPosition) {\n return mDataList.get(\"\" + groupPosition).get(childPosition);\r\n }",
"public BoxItem.Info getItem() {\n return this.item;\n }",
"E getData(int index);",
"public Object getItem(int arg0) {\n\t\t\treturn dataList.get(arg0);\r\n\t\t}",
"public E get(int pos) {\n \t\n \tif (pos < 0 || pos > numItems) {\n throw new IndexOutOfBoundsException();\n }\n \t\n \t/*\n \tif (pos == numItems-1) {\n \t\treturn lastNode.getData();\n }\n \t*/\n \t\n \tDblListnode<E> n = items.getNext();\n for (int k = 0; k < pos; k++) {\n n = n.getNext();\n }\n return n.getData();\n }",
"public TDAPrioridad getDato(int pos) {\r\n return datos[pos];\r\n }",
"public int getData(int index) {\n return data_.get(index);\n }",
"public String get(int position)\n\t{\n\t\treturn data[position];\n\t}",
"public Object getData() {\n\t\t\treturn null;// this.element;\n\t\t}",
"public Object data() {\n return this.data;\n }",
"public T getItem() {\n return item;\n }",
"public Object getData() {\n\t\treturn data;\n\t}",
"public DatasetItem getDatasetItem() {\n return (attributes.containsKey(KEY_DATASET_ITEM) ? (DatasetItem) attributes\n .get(KEY_DATASET_ITEM) : null);\n }",
"public Object getData()\r\n\t\t{\r\n\t\t\treturn data;\r\n\t\t}",
"public Object getData() {\r\n\t\t\treturn data;\r\n\t\t}",
"public T getItem() {\n\t\treturn item;\n\t}",
"public T getItem() {\n\t\treturn item;\n\t}",
"@Override\n\t\tpublic Object getItem(int position) {\n\t\t\treturn BaseData.list.get(position);\n\t\t}",
"@Override\n\t\tpublic Object getItem(int position) {\n\t\t\treturn message.array.get(position);\n\t\t}",
"public int getTag(int position) {\r\n return dataTag.get(position);\r\n }",
"@Override\r\n\tpublic E getData() {\n\t\treturn data;\r\n\t}",
"public Object getItem(int position) {\n\t\t\treturn gnombre[position];\n\t\t}",
"public E getData(){\n\t\t\treturn data;\n\t\t}",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn dataSource.get(position);\n\t}",
"public E getData() {\r\n\t\treturn data;\r\n\t}",
"public Object getItem(int position) {\n\t\treturn events.get(position);\n\t}",
"public int getData(int index) {\n return data_.get(index);\n }",
"public BubbleData getBubbleData() { return (BubbleData)this.mData; }",
"public T getX() {\n return data;\n }",
"public Item getItem ()\n\t{\n\t\treturn item;\n\t}",
"public T getItem() {\r\n return item;\r\n }",
"public Object getData() {\n if (this.mInvitation != null) return this.mInvitation;\n else if (this.mChatMessageFragment != null) return this.mChatMessageFragment;\n else return null;\n }",
"public int getData() {\n return this.data;\n }",
"public T getData()\n\t{\n\t\treturn this.data;\n\t}",
"public Item getItem() {\n\t\treturn this.item;\n\t}",
"public Item getItem() {\n\t\treturn this.item;\n\t}",
"@Override\r\n\t\tpublic Meta_data getData() {\n\t\t\treturn this.data;\r\n\t\t}",
"public E getData() {\n return data;\n }",
"public T getData() {\n return this.data;\n }",
"public PData getData() {\n\t\treturn data;\n\t}",
"public TitleDTO getItem(int position) {\n\t\t\treturn arrTitle.get(position);\n\t\t}",
"public TitleDTO getItem(int position) {\n\t\t\treturn arrTitle.get(position);\n\t\t}",
"public E getData() { return data; }",
"public T getData(int index){\n if(index < 0 || index >= data.size())\n return null;\n\n //give back the data\n return data.get(index);\n }",
"public ArrayOfItem getItem() {\r\n return localItem;\r\n }",
"public Item getItem() {\r\n\t\treturn this.item;\r\n\t}",
"public SpItem getItem() {\n return _spItem;\n }",
"@Override\n\tpublic Object getItem(int position) {\n\t\treturn array.get(position);\n\t}",
"Object getDataValue(final int row, final int column);",
"public Object getItem(int position) {\n\t\treturn OReportOne.get(position);\n\t}",
"public Data getData() {\n return data;\n }",
"public Data getData() {\n return data;\n }"
] | [
"0.7668654",
"0.731151",
"0.72089416",
"0.71677965",
"0.7130208",
"0.7076344",
"0.70645505",
"0.70532256",
"0.7042189",
"0.7042189",
"0.7042189",
"0.70360523",
"0.7032629",
"0.6959",
"0.6956786",
"0.6956786",
"0.69467556",
"0.69467556",
"0.69104123",
"0.6871041",
"0.6827699",
"0.6812586",
"0.6802695",
"0.6801953",
"0.67860985",
"0.6752288",
"0.6732555",
"0.67268413",
"0.67054063",
"0.67026263",
"0.6679791",
"0.6672056",
"0.66684264",
"0.66492325",
"0.66461563",
"0.6645873",
"0.6625707",
"0.6589671",
"0.6572217",
"0.6572217",
"0.6571286",
"0.6549029",
"0.65464556",
"0.65058756",
"0.64889824",
"0.6462878",
"0.64314336",
"0.6383995",
"0.6353117",
"0.6351189",
"0.6335703",
"0.63236636",
"0.6320233",
"0.63196313",
"0.63037884",
"0.62979305",
"0.62950414",
"0.62738",
"0.6272995",
"0.6271909",
"0.6266127",
"0.6262787",
"0.6258756",
"0.6254655",
"0.6253725",
"0.6253725",
"0.62515825",
"0.6249249",
"0.6247676",
"0.62365335",
"0.6233035",
"0.622878",
"0.62259644",
"0.6220017",
"0.62199694",
"0.6209388",
"0.62046456",
"0.6197702",
"0.6195945",
"0.619199",
"0.61916137",
"0.61839",
"0.61789274",
"0.61788934",
"0.61788934",
"0.6175576",
"0.6173883",
"0.6173774",
"0.61694",
"0.616044",
"0.616044",
"0.6158161",
"0.61328167",
"0.6124875",
"0.6123582",
"0.612205",
"0.6121791",
"0.6121193",
"0.6120425",
"0.61148196",
"0.61148196"
] | 0.0 | -1 |
Instantiates a new index. | public Index(TokenBasedAnalyzer myAnalyzer,boolean lowercase, Set<String> stopWords) {
//Index Creation
this.lowercase = lowercase;
this.stopWords = stopWords;
this.myAnalyzer = myAnalyzer;
idx = new RAMDirectory();
IndexWriterConfig indexWriterConfiguration = new IndexWriterConfig(Version.LUCENE_34, myAnalyzer);
indexWriter = null;
try {
indexWriter = new IndexWriter(idx,indexWriterConfiguration);
} catch (CorruptIndexException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (LockObtainFailedException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public SimpleIndexFactory() {\n\t}",
"public H_index() {\n\t\tsuper();\n\t}",
"InstAssignIndex createInstAssignIndex();",
"public Index initIndex(String indexName) {\n return new Index(this, indexName);\n }",
"public Indexer() {\n }",
"public void createIndex(Configuration configuration){\n }",
"IndexCreated createIndex(String name, Index index) throws ElasticException;",
"private static RDFIndex createDefaultIndex() {\n defaultIndex = new RDFIndex(com.hp.hpl.jena.graph.Factory.createGraphMem());\n try {\n File indexFile = new File(INDEX_FILE);\n if(indexFile.exists()) {\n defaultIndex.read(new FileReader(indexFile),Constants.RESOURCE_URL);\n }\n } catch(Throwable t) {\n t.printStackTrace();\n }\n return defaultIndex;\n }",
"IndexNameReference createIndexNameReference();",
"LuceneMemoryIndex createLuceneMemoryIndex();",
"indexSet createindexSet();",
"public com.guidewire.datamodel.IndexDocument.Index addNewIndex()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n com.guidewire.datamodel.IndexDocument.Index target = null;\r\n target = (com.guidewire.datamodel.IndexDocument.Index)get_store().add_element_user(INDEX$12);\r\n return target;\r\n }\r\n }",
"public void start() throws Exception {\n\n createIndex();\n }",
"public void createIndex(Index index) {\n Span span = this.tracer.buildSpan(\"Client.CreateIndex\").start();\n try {\n String path = String.format(\"/index/%s\", index.getName());\n String body = index.getOptions().toString();\n ByteArrayEntity data = new ByteArrayEntity(body.getBytes(StandardCharsets.UTF_8));\n clientExecute(\"POST\", path, data, null, \"Error while creating index\");\n } finally {\n span.finish();\n }\n }",
"String createIndex() {\n\t\tboolean res = indexExists();\n\t\t@SuppressWarnings(\"unused\")\n\t\tint resCode;\n\t\tif (!res) {\n\t\t\tresCode = doHttpOperation(esIndexUrl, HTTP_PUT, null);\n\t\t}\n\t\treturn lastResponse;\n\t}",
"public IndexBuilder(InvertedIndex index) {\n\t\tthis.index = index;\n\t}",
"public IndexRecord()\n {\n }",
"private Indexers()\r\n {\r\n // Private constructor to prevent instantiation\r\n }",
"public void testCreIdx(){\r\n\t \r\n\t String dataDir = \"C:\\\\study\\\\Lucene\\\\Data\";\r\n\t String idxDir = \"C:\\\\study\\\\Lucene\\\\Index\";\r\n\t \r\n\t LuceneUtils.delAll(idxDir);\r\n\t \r\n\t CreateIndex ci = new CreateIndex();\r\n\t \r\n\t ci.Indexer(new File(idxDir), new File(dataDir));\r\n\t \r\n\t\t\r\n\t}",
"public generateIndex() {\n\n\t\tthis.analyzer = \"StandardAnalyzer\";\n\t}",
"@Test\n public void testCreate() throws Exception {\n System.out.println(\"create\");\n Index entity = TestUtils.getTestIndex();\n IndexResponse result = instance.create(entity);\n assertNotNull(result);\n assertEquals(entity.getDatabaseName(), result.getIndex().getDatabaseName());\n assertEquals(entity.getName(), result.getIndex().getName());\n assertEquals(entity.getTableName(), result.getIndex().getTableName());\n assertEquals(entity.getFields(), result.getIndex().getFields());\n }",
"public static Index create(String name, Path path) {\n try {\n Files.createDirectory(path.resolve(INDEX));\n return new Index(name, path);\n\n } catch (IOException e) {\n throw new IOFailureException(e);\n }\n }",
"@Override\n\tpublic ModIndexedInstance createNewInstance() {\n\t\tModIndexedInstance newInst = new ModIndexedInstance(); // create the new instance\n\t\tnewInst.setRegComp(this); // set component type of new instance\n\t\taddInstanceOf(newInst); // add instance to list for this comp\n\t\treturn newInst;\n\t}",
"public static HashIndexBuilder hashIndex(String name) {\n return new HashIndexBuilderImpl(name);\n }",
"boolean createIndex(String indexName);",
"public AutoIndexMap()\n\t\t{\n\t\t\t// Initialise instance variables\n\t\t\tindices = new IdentityHashMap<>();\n\t\t}",
"public void createIndex() {\n String indexName = INDEX_BASE + \"-\" +\n LocalDateTime.now().format(DateTimeFormatter.ofPattern(\"yyyyMMddHHmmss\"));\n\n Settings settings = Settings.builder()\n .put(\"number_of_shards\", 1)\n .put(\"number_of_replicas\", 0)\n .build();\n CreateIndexRequest request = new CreateIndexRequest(indexName, settings);\n\n String mapping = \"{\\n\" +\n \" \\\"article\\\": {\\n\" +\n \" \\\"properties\\\": {\\n\" +\n \" \\\"title\\\": {\\n\" +\n \" \\\"type\\\": \\\"text\\\"\\n\" +\n \" },\\n\" +\n \" \\\"author\\\": {\\n\" +\n \" \\\"type\\\": \\\"keyword\\\"\\n\" +\n \" },\\n\" +\n \" \\\"issue\\\": {\\n\" +\n \" \\\"type\\\": \\\"keyword\\\"\\n\" +\n \" },\\n\" +\n \" \\\"link\\\": {\\n\" +\n \" \\\"type\\\": \\\"keyword\\\"\\n\" +\n \" },\\n\" +\n \" \\\"description\\\": {\\n\" +\n \" \\\"type\\\": \\\"text\\\"\\n\" +\n \" },\\n\" +\n \" \\\"postDate\\\": {\\n\" +\n \" \\\"type\\\": \\\"date\\\",\\n\" +\n \" \\\"format\\\": \\\"yyyy-MM-dd\\\"\\n\" +\n \" }\\n\" +\n \" }\\n\" +\n \" }\\n\" +\n \" }\";\n\n request.mapping(\"article\", mapping, XContentType.JSON);\n request.alias(new Alias(INDEX_BASE));\n\n try {\n CreateIndexResponse createIndexResponse = this.client.admin().indices().create(request).get();\n if (!createIndexResponse.isAcknowledged()) {\n throw new ElasticExecutionException(\"Create java_magazine index was not acknowledged\");\n }\n } catch (InterruptedException | ExecutionException e) {\n logger.error(\"Error while creating an index\", e);\n throw new ElasticExecutionException(\"Error when trying to create an index\");\n }\n }",
"@Ignore\n @Test\n public void testCreateIndex() {\n System.out.println(\"createIndex\");\n Util.commonServiceIPs=\"127.0.0.1\";\n \n EntityManager em=Util.getEntityManagerFactory(100).createEntityManager();\n EntityManager platformEm = Util.getPlatformEntityManagerFactory().createEntityManager();\n \n Client client = ESUtil.getClient(em,platformEm,1,false);\n \n RuntimeContext.dataobjectTypes = Util.getDataobjectTypes();\n String indexName = \"test000000\";\n try {\n ESUtil.createIndex(platformEm, client, indexName, true);\n }\n catch(Exception e)\n {\n \n }\n \n\n }",
"public void createIndex(final String name) {\n createIndex(new BasicDBObject(name, 1));\n }",
"public static <T> void createIndex(Geography<T> geog, Class<T> clazz)\n\t{\n\t\tIndex<T> i = new Index<T>(geog, clazz);\n\t\tSpatialIndexManager.indices.put(geog, i);\n\t}",
"public ProductIndexQuery() {\n\t}",
"public void addIndex() throws JNCException {\n setLeafValue(Epc.NAMESPACE,\n \"index\",\n null,\n childrenNames());\n }",
"private void createIndex(final String index, int numShards, int numReplicas) throws IOException {\n LOGGER.warn(\"CREATE ES INDEX {} with {} shards and {} replicas\", index, numShards, numReplicas);\n final Settings indexSettings = Settings.builder().put(\"number_of_shards\", numShards)\n .put(\"number_of_replicas\", numReplicas).build();\n CreateIndexRequest indexRequest = new CreateIndexRequest(index, indexSettings);\n getClient().admin().indices().create(indexRequest).actionGet();\n\n final String mapping = IOUtils.toString(\n this.getClass().getResourceAsStream(\"/elasticsearch/mapping/map_person_5x_snake.json\"));\n getClient().admin().indices().preparePutMapping(index)\n .setType(getConfig().getElasticsearchDocType()).setSource(mapping, XContentType.JSON).get();\n }",
"private void createIndex(Message<JsonObject> msg, int timeout, JsonObject headers, String dbName) {\n // check required params / attributes\n \n // REQUIRED: The name of the collection for which to create the index\n String collection = helper.getMandatoryString(msg.body(), MSG_PROPERTY_COLLECTION, msg);\n if (collection == null) return;\n\n // REQUIRED: A JSON representation of the index (see ArangoDB docs for details)\n JsonObject document = helper.getMandatoryObject(msg.body(), MSG_PROPERTY_DOCUMENT, msg);\n if (document == null) return;\n\n if (!ensureAttribute(document, DOC_ATTRIBUTE_TYPE, msg)) return;\n if (!document.getString(DOC_ATTRIBUTE_TYPE).equals(TYPE_CAP)) {\n if (!ensureAttribute(document, DOC_ATTRIBUTE_FIELDS, msg)) return;\n }\n\n // prepare PATH\n StringBuilder apiPath = new StringBuilder();\n if (dbName != null) apiPath.append(\"/_db/\").append(dbName);\n apiPath.append(API_PATH);\n apiPath.append(\"/?\").append(MSG_PROPERTY_COLLECTION).append(\"=\").append(collection);\n\n httpPost(persistor, apiPath.toString(), headers, document, timeout, msg);\n }",
"public createIndex_result(createIndex_result other) {\n }",
"public static IndexExpression makeIndex(Expression instance, PropertyInfo indexer, Iterable<Expression> arguments) { throw Extensions.todo(); }",
"public IndexBeans() {\r\n }",
"public void createIndex(final DBObject keys) {\n createIndex(keys, new BasicDBObject());\n }",
"public indexing() {\n initComponents();\n }",
"private void createTokenIndex(){\n\t\tLinkedList<String> tokens = new LinkedList<>(tokenDict.keySet());\n\t\tArrayList<ArrayList<Integer>> vals = new ArrayList<>(tokenDict.values());\n\t\tint k = 8;\n\n\t\tKFront kf = new KFront(true);\n\t\tkf.createKFront(k, tokens);\n\n\t\tTokensIndex tIdx = new TokensIndex(k, this.dir);\n\t\ttIdx.insertData(kf.getTable(), vals, kf.getConcatString());\n\n\t\tsaveToDir(TOKEN_INDEX_FILE, tIdx);\n\t}",
"public Index getIndex() {\r\n // TODO: Implement this!\r\n return new WebIndex();\r\n }",
"private BrowseIndex(String baseName) {\n this(baseName, \"item\");\n }",
"private void createProductIndex() {\n\t\tLinkedList<String> ids = new LinkedList<>(productIds.keySet());\n\t\tArrayList<ArrayList<Integer>> vals = new ArrayList<>(productIds.values());\n\t\tint k = 8;\n\t\tKFront kf = new KFront();\n\t\tkf.createKFront(k, ids);\n\t\tfor (int i = 0; i < vals.size(); i++) {\n\t\t\tkf.getTable().get(i).addAll(vals.get(i));\n\t\t}\n\n\t\tProductIndex pIndex = new ProductIndex(k);\n\t\tpIndex.insertData(kf.getTable(), kf.getConcatString());\n\t\tsaveToDir(PRODUCT_INDEX_FILE, pIndex);\n\t}",
"private synchronized void criarIndice() throws Exception {\r\n\t\tIndexWriter indexWriter = getWriterPadrao(true);\r\n\t\ttry {\r\n\t\t\tindexWriter.getAnalyzer().close();\r\n\t\t\tindexWriter.close();\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"public com.guidewire.datamodel.IndexDocument.Index insertNewIndex(int i)\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n com.guidewire.datamodel.IndexDocument.Index target = null;\r\n target = (com.guidewire.datamodel.IndexDocument.Index)get_store().insert_element_user(INDEX$12, i);\r\n return target;\r\n }\r\n }",
"boolean isNewIndex();",
"public createIndex_args(createIndex_args other) {\n }",
"ByteArrayIndex createByteArrayIndex();",
"public DIndexDescription() {\n super(COMMAND);\n }",
"public InvertedIndex() {\n\t\tthis.invertedIndex = new TreeMap<>();\n\t\tthis.counts = new TreeMap<>();\n\t}",
"public BlackLabIndex open(File indexDir) throws ErrorOpeningIndex {\n IndexType indexType = determineIndexType(indexDir, false, null);\n return indexType == IndexType.INTEGRATED ?\n new BlackLabIndexIntegrated(indexDir.getName(), this, null, indexDir, false, false, null):\n new BlackLabIndexExternal(this, indexDir, false, false, (File) null);\n }",
"public void enableIndexAutoCreation() {\n client.setIndexAutoCreationEnabled(true);\n }",
"private void createInvertedIndex() {\n\t\tArrayList<Index> invertedIndex=new ArrayList<>();\n\t\ttry{\n\t\t\tBufferedReader in = new BufferedReader(new FileReader(\"E:\\\\graduate\\\\cloud\\\\project\\\\data\\\\part-r-00001\"));\n\t\t\tString line = \"\";\n\t\t\twhile ((line = in.readLine()) != null) {\n\t\t\t\tString parts[] = line.split(\"\\t\");\n\t\t\t\tparts[1]=parts[1].replace(\"{\", \"\").replace(\"}\", \"\");\n\t\t\t\tString counts[]=parts[1].split(\",\");\n\t\t\t\tHashMap<String,Integer> fileList=new HashMap<String,Integer>();\n\t\t\t\tfor (String count : counts) {\n\t\t\t\t\tString file[]=count.split(\"=\");\n\t\t\t\t\tfileList.put(file[0].trim().replace(\".txt\", \"\"), Integer.parseInt(file[1].trim()));\n\t\t\t\t}\n\t\t\t\tIndex index=new Index();\n\t\t\t\tindex.setWord(parts[0]);\n\t\t\t\tindex.setFileList(fileList);\n\t\t\t\tinvertedIndex.add(index);\n\t\t\t}\n\t\t\tin.close();\n\t\t}catch(IOException e){\n\t\t\te.printStackTrace();\n\t\t}\n\t\tDBUtil.insertIndex(invertedIndex);\n\t}",
"public void createIndex() throws IOException {\n\t\tLOGGER.info(\"creating photo index...\");\n\t\tCreateIndexRequest request = new CreateIndexRequest(\"files\");\n\t\tInputStream in = getClass().getClassLoader().getResourceAsStream(\"photo.json\");\n\t\tString mapping = new String(in.readAllBytes());\n\t\tin.close();\n\t\trequest.mapping(\"photo\", mapping, XContentType.JSON);\n\t\tCreateIndexResponse response = client.indices().create(request);\n\t\tLOGGER.info(\"photo index created: \" + response.toString());\n\t}",
"public void beforeIndexCreated(Index index) {\n\n }",
"private BrowseIndex() {\n }",
"public KrillIndex () throws IOException {\n this((Directory) new RAMDirectory());\n }",
"public void openIndex(String indexPath) throws IOException {\n\n }",
"public void start() throws Exception {\n if (!getClient().admin().indices().exists(Requests.indicesExistsRequest(INDEX_NAME)).actionGet().isExists()) {\n getClient().admin().indices().prepareCreate(INDEX_NAME).execute().actionGet().isAcknowledged();\n }\n\n //Create mapping for the key. Leave it not_analyzed so it doesn't tokenize the \"-\" delimiters\n PutMappingResponse response = getClient().admin().indices()\n .preparePutMapping(INDEX_NAME)\n .setType(TYPE_NAME)\n .setSource(buildMapping())\n .execute().actionGet();\n if (!response.isAcknowledged()) {\n throw new Exception(\"Could not define mapping.\");\n }\n }",
"public DateIndex(final String name, final String currency, final DateIndexType dateIndexType) {\n\t\tsuper(name, currency);\n\t\tthis.dateIndexType = dateIndexType;\n\t}",
"private Reindex() {}",
"private Reindex() {}",
"public void createIndex() throws IOException {\n\t\tindexWriter.commit();\n\t\ttaxoWriter.commit();\n\n\t\t// categories\n\t\tfor (Article.Facets f : Article.Facets.values()) {\n\t\t\ttaxoWriter.addCategory(new CategoryPath(f.toString()));\n\t\t}\n\t\ttaxoWriter.commit();\n\n\t\tfinal Iterable<Article> articles = articleRepository.findAll();\n\t\tint c = 0;\n\t\tfor (Article article : articles) {\n\t\t\taddArticle(indexWriter, taxoWriter, article);\n\t\t\tc++;\n\t\t}\n\t\t// commit\n\t\ttaxoWriter.commit();\n\t\tindexWriter.commit();\n\n\t\ttaxoWriter.close();\n\t\tindexWriter.close();\n\n\t\ttaxoDirectory.close();\n\t\tindexDirectory.close();\n\t\tLOGGER.debug(\"{} articles indexed\", c);\n\t}",
"public IndexWriter(String indexDir) {\n\t\t//TODO : YOU MUST IMPLEMENT THIS\n\tif (indexDir!=null)\n\t{System.setProperty(\"INDEX.DIR\",(this.indexDir=indexDir));\n\tisvaliddir=true;\n\tiutil=new IndexUtil(indexDir);\n\t}\n\t\n\t}",
"public interface IndexBuilder {\n\n /**\n * Rebuilds the index only when the existing index is not populated.\n */\n void rebuildIfNecessary();\n\n}",
"public void createIndex(final DBObject keys, final String name) {\n createIndex(keys, name, false);\n }",
"public InnodbIndexStatsExample() {\n oredCriteria = new ArrayList<Criteria>();\n }",
"@Override\n\tpublic void build(Index index) {\n\t\tthis.indexdir = index.getPath();\n\t\tLuceneIndex luceneIndex = (LuceneIndex) index;\n\t\tthis.indexSearcher = new IndexSearcher(luceneIndex.getReader());\n\n\t}",
"public TermConstant(int indexIn)\n {\n index = indexIn;\n }",
"private static void createIndex() {\n XML_Shell workFile = new XML_Shell();\n String messageFromServer = ClientService.getLastMessageFromServer();\n\n try {\n XML_Manager.stringToDom(messageFromServer, workFile);\n } catch (SAXException | ParserConfigurationException | IOException | TransformerException e) {\n e.printStackTrace();\n }\n\n }",
"public IndexableDocument() {\n\t\tthis.id=new ObjectId();\n\t}",
"public boolean createIndex() {\n RestClient client = esrResource.getClient();\n\n try {\n Response r = client.performRequest(\"HEAD\", \"/\" + index);\n\n if (r.getStatusLine().getStatusCode() != 200) {\n client.performRequest(\"PUT\", \"/\" + index);\n\n return true;\n }\n } catch (IOException ioe) {\n getMonitor().error(\"Unable to create index\", ioe);\n }\n\n return false;\n }",
"public static Index open(String name, Path path) {\n if (!Files.isDirectory(path.resolve(INDEX))) {\n throw new InvalidRepositoryPathException();\n }\n try {\n return new Index(name, path);\n\n } catch (IOException ex) {\n throw new IOFailureException(ex);\n }\n }",
"private Index(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }",
"public CreateIndex(File selectedFolder) {\n\n\t\tFile selectedFilePeople = new File(selectedFolder + Settings.nameOfPeopleFile);\n\t\tFile selectedFileEvents = new File(selectedFolder + Settings.nameOfEventsFile);\n\t\t\n\t\ttry {\n\t\t\tpeopleAndEventsCreate(selectedFolder, selectedFilePeople, Settings.nameOfLuceneIndexPeople);\n\t\t\tpeopleAndEventsCreate(selectedFolder, selectedFileEvents, Settings.nameOfLuceneIndexEvents);\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public static PrimaryIndexBuilder pkIndex() {\n return new PrimaryKeyBuilderImpl();\n }",
"private synchronized IndexService createIndexService(\n IndexService.IndexCreationContext indexCreationContext,\n IndexMetadata indexMetadata,\n IndicesQueryCache indicesQueryCache,\n IndicesFieldDataCache indicesFieldDataCache,\n List<IndexEventListener> builtInListeners,\n IndexingOperationListener... indexingOperationListeners\n ) throws IOException {\n final IndexSettings idxSettings = new IndexSettings(indexMetadata, settings, indexScopedSettings);\n if (EngineConfig.INDEX_OPTIMIZE_AUTO_GENERATED_IDS.exists(idxSettings.getSettings())) {\n throw new IllegalArgumentException(\n \"Setting [\" + EngineConfig.INDEX_OPTIMIZE_AUTO_GENERATED_IDS.getKey() + \"] was removed in version 7.0.0\"\n );\n }\n // we ignore private settings since they are not registered settings\n indexScopedSettings.validate(indexMetadata.getSettings(), true, true, true);\n logger.debug(\n \"creating Index [{}], shards [{}]/[{}] - reason [{}]\",\n indexMetadata.getIndex(),\n idxSettings.getNumberOfShards(),\n idxSettings.getNumberOfReplicas(),\n indexCreationContext\n );\n\n final IndexModule indexModule = new IndexModule(\n idxSettings,\n analysisRegistry,\n getEngineFactory(idxSettings),\n getEngineConfigFactory(idxSettings),\n directoryFactories,\n () -> allowExpensiveQueries,\n indexNameExpressionResolver,\n recoveryStateFactories\n );\n for (IndexingOperationListener operationListener : indexingOperationListeners) {\n indexModule.addIndexOperationListener(operationListener);\n }\n pluginsService.onIndexModule(indexModule);\n for (IndexEventListener listener : builtInListeners) {\n indexModule.addIndexEventListener(listener);\n }\n return indexModule.newIndexService(\n indexCreationContext,\n nodeEnv,\n xContentRegistry,\n this,\n circuitBreakerService,\n bigArrays,\n threadPool,\n scriptService,\n clusterService,\n client,\n indicesQueryCache,\n mapperRegistry,\n indicesFieldDataCache,\n namedWriteableRegistry,\n this::isIdFieldDataEnabled,\n valuesSourceRegistry,\n remoteDirectoryFactory,\n translogFactorySupplier,\n this::getClusterDefaultRefreshInterval,\n this::getClusterRemoteTranslogBufferInterval\n );\n }",
"public String createDSIndex(String dsID, String dschemaID, String attriName);",
"public InnodbIndexStats() {\n this(DSL.name(\"innodb_index_stats\"), null);\n }",
"public IndexBuilderTest(String testName) {\n super(testName);\n }",
"private void ensureIndexes() throws Exception {\n LOGGER.info(\"Ensuring all Indexes are created.\");\n\n QueryResult indexResult = bucket.query(\n Query.simple(select(\"indexes.*\").from(\"system:indexes\").where(i(\"keyspace_id\").eq(s(bucket.name()))))\n );\n\n\n List<String> indexesToCreate = new ArrayList<String>();\n indexesToCreate.addAll(Arrays.asList(\n \"def_sourceairport\", \"def_airportname\", \"def_type\", \"def_faa\", \"def_icao\", \"def_city\"\n ));\n\n boolean hasPrimary = false;\n List<String> foundIndexes = new ArrayList<String>();\n for (QueryRow indexRow : indexResult) {\n String name = indexRow.value().getString(\"name\");\n if (name.equals(\"#primary\")) {\n hasPrimary = true;\n } else {\n foundIndexes.add(name);\n }\n }\n indexesToCreate.removeAll(foundIndexes);\n\n if (!hasPrimary) {\n String query = \"CREATE PRIMARY INDEX def_primary ON `\" + bucket.name() + \"` WITH {\\\"defer_build\\\":true}\";\n LOGGER.info(\"Executing index query: {}\", query);\n QueryResult result = bucket.query(Query.simple(query));\n if (result.finalSuccess()) {\n LOGGER.info(\"Successfully created primary index.\");\n } else {\n LOGGER.warn(\"Could not create primary index: {}\", result.errors());\n }\n }\n\n for (String name : indexesToCreate) {\n String query = \"CREATE INDEX \" + name + \" ON `\" + bucket.name() + \"` (\" + name.replace(\"def_\", \"\") + \") \"\n + \"WITH {\\\"defer_build\\\":true}\\\"\";\n LOGGER.info(\"Executing index query: {}\", query);\n QueryResult result = bucket.query(Query.simple(query));\n if (result.finalSuccess()) {\n LOGGER.info(\"Successfully created index with name {}.\", name);\n } else {\n LOGGER.warn(\"Could not create index {}: {}\", name, result.errors());\n }\n }\n\n LOGGER.info(\"Waiting 5 seconds before building the indexes.\");\n\n Thread.sleep(5000);\n\n StringBuilder indexes = new StringBuilder();\n boolean first = true;\n for (String name : indexesToCreate) {\n if (first) {\n first = false;\n } else {\n indexes.append(\",\");\n }\n indexes.append(name);\n }\n\n if (!hasPrimary) {\n indexes.append(\",\").append(\"def_primary\");\n }\n\n String query = \"BUILD INDEX ON `\" + bucket.name() + \"` (\" + indexes.toString() + \")\";\n LOGGER.info(\"Executing index query: {}\", query);\n QueryResult result = bucket.query(Query.simple(query));\n if (result.finalSuccess()) {\n LOGGER.info(\"Successfully executed build index query.\");\n } else {\n LOGGER.warn(\"Could not execute build index query {}.\", result.errors());\n }\n }",
"public static Index of(int... indexes) {\n \t\treturn new Index(indexes.clone());\n \t}",
"public DateIndex(final String name, final DateIndexType dateIndexType) {\n\t\tsuper(name);\n\t\tthis.dateIndexType = dateIndexType;\n\t}",
"private Document createMapping() {\n return getIndexOperations().createMapping();\n }",
"public CreateIndexRequest prepareCreate(String index) {\n \treturn new CreateIndexRequest(hClient, index);\n }",
"public interface IIndexBuilder {\n\n public IIndex getIndex( Class<?> searchable ) throws BuilderException;\n\n public IFieldVisitor getFieldVisitor();\n\n public void setFieldVisitor( IFieldVisitor visitor );\n\n}",
"public IndexAlreadyExistsException(Index index) {\n\t\tsuper(index, \"Already exists\");\n\t}",
"public Index.Builder getIndicesBuilder(\n int index) {\n return getIndicesFieldBuilder().getBuilder(index);\n }",
"public synchronized void createIndexIfNeeded(final String index) throws NeutronCheckedException {\n try {\n if (!doesIndexExist(index)) {\n LOGGER.warn(\"ES INDEX {} DOES NOT EXIST!!\", index);\n createIndex(index, NUMBER_OF_SHARDS, NUMBER_OF_REPLICAS);\n\n // Give Elasticsearch a moment to catch its breath.\n Thread.sleep(2000); // NOSONAR\n }\n } catch (InterruptedException | IOException e) {\n throw JobLogs.checked(LOGGER, e, \"CREATE INDEX FAILED! {}\", e.getMessage());\n }\n }",
"private IndexSettings buildIndexSettings(IndexMetadata metadata) {\n return new IndexSettings(metadata, settings);\n }",
"private void indexItem(IndexDocument indexDoc) {\n if(bDebug) System.out.println(\"\\n*** document to index - \" + indexDoc);\n Indexer indexer=null;\n try {\n indexer=new Indexer(PetstoreConstants.PETSTORE_INDEX_DIRECTORY, false);\n PetstoreUtil.getLogger().log(Level.FINE, \"Adding document to index: \" + indexDoc.toString());\n indexer.addDocument(indexDoc);\n } catch (Exception e) {\n PetstoreUtil.getLogger().log(Level.WARNING, \"index.exception\", e);\n e.printStackTrace();\n } finally {\n try {\n // must close file or will not be able to reindex\n if(indexer != null) {\n indexer.close();\n }\n } catch (Exception ee) {\n ee.printStackTrace();\n }\n }\n }",
"@Test\n public void testCreateIdxOnClient() {\n getDefaultCacheOnClient().query(new SqlFieldsQuery(((\"CREATE INDEX IDX_11 ON \" + (GridCacheDynamicLoadOnClientTest.FULL_TABLE_NAME)) + \" (name asc)\"))).getAll();\n }",
"public void addIndex(){\n\t\tdbCol=mdb.getCollection(\"genericCollection\");\n\t\tstart=Calendar.getInstance().getTimeInMillis();\n\t\tdbCol.ensureIndex(new BasicDBObject(\"RandomGeo\", \"2d\"));\n\t\tstop = Calendar.getInstance().getTimeInMillis() - start;\n\t\tSystem.out.println(\"Mongo Index Timer \"+Long.toString(stop));\n\t}",
"public IndexSearchSharderManager() {\n log = LoggerFactory.getLogger(IndexSearchSharderManager.class);\n }",
"public ThreadSafeInvertedIndex() {\n\t\tsuper();\n\t\tthis.lock = new ReadWriteLock();\n\t}",
"private void createIndex(Geography<T> geog, Class<T> clazz)\n\t{\n\t\tGeometry geom;\n\t\tEnvelope bounds;\n\t\tfor (T t : geog.getAllObjects( ))\n\t\t{\n\t\t\tgeom = (Geometry) geog.getGeometry(t);\n\t\t\tbounds = geom.getEnvelopeInternal( );\n\t\t\tthis.si.insert(bounds, geom);\n\t\t\tthis.featureLookup.put(geom, t);\n\t\t}\n\t}",
"CreateIndexConstantAction(\n boolean forCreateTable,\n boolean\t\t\tunique,\n boolean\t\t\tuniqueWithDuplicateNulls,\n String\t\t\tindexType,\n String\t\t\tschemaName,\n String\t\t\tindexName,\n String\t\t\ttableName,\n UUID\t\t\ttableId,\n String[]\t\tcolumnNames,\n boolean[]\t\tisAscending,\n boolean\t\t\tisConstraint,\n UUID\t\t\tconglomerateUUID,\n Properties\t\tproperties)\n {\n super(tableId, indexName, tableName, schemaName);\n\n this.forCreateTable = forCreateTable;\n this.unique = unique;\n this.uniqueWithDuplicateNulls = uniqueWithDuplicateNulls;\n this.indexType = indexType;\n this.columnNames = columnNames;\n this.isAscending = isAscending;\n this.isConstraint = isConstraint;\n this.conglomerateUUID = conglomerateUUID;\n this.properties = properties;\n this.conglomId = -1L;\n this.droppedConglomNum = -1L;\n }",
"com.google.firestore.admin.v1beta1.Index getIndex();",
"public void ensureIndex(Index index) {\n try {\n createIndex(index);\n } catch (HttpConflict ex) {\n // pass\n }\n }",
"public TranscriptionIndexer() throws SQLException, CorruptIndexException, IOException\r\n {\r\n\r\n\r\n IndexWriter writer = null;\r\n Analyzer analyser;\r\n Directory directory;\r\n /**@TODO parameterized location*/\r\n String dest = \"/usr/indexTranscriptions\";\r\n\r\n directory = FSDirectory.getDirectory(dest, true);\r\n analyser = new StandardAnalyzer();\r\n writer = new IndexWriter(directory, analyser, true);\r\n PreparedStatement stmt=null;\r\n Connection j = null;\r\n try {\r\n j=DatabaseWrapper.getConnection();\r\n String query=\"select * from transcription where text!='' and creator>0 order by folio, line\";\r\n stmt=j.prepareStatement(query);\r\n ResultSet rs=stmt.executeQuery();\r\n while(rs.next())\r\n {\r\n int folio=rs.getInt(\"folio\");\r\n int line=rs.getInt(\"line\");\r\n int UID=rs.getInt(\"creator\");\r\n int id=rs.getInt(\"id\");\r\n Transcription t=new Transcription(id);\r\n Document doc = new Document();\r\n Field field;\r\n field = new Field(\"text\", t.getText(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"comment\", t.getComment(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"creator\", \"\" + t.UID, Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"security\", \"\" + \"private\", Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"line\", \"\" + t.getLine(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"page\", \"\" + t.getFolio(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"id\", \"\" + t.getLineID(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"manuscript\", \"\" + new Manuscript(t.getFolio()).getID(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"projectID\", \"\" + t.getProjectID(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n writer.addDocument(doc);\r\n }\r\n } catch (Exception ex) {\r\n ex.printStackTrace();\r\n if(writer!=null)\r\n {\r\n writer.commit();\r\n \twriter.close();\r\n return;\r\n }\r\n ex.printStackTrace();\r\n }\r\n finally{\r\n DatabaseWrapper.closeDBConnection(j);\r\n DatabaseWrapper.closePreparedStatement(stmt);\r\n }\r\n\r\n writer.commit();\r\n \twriter.close();\r\n}"
] | [
"0.7936821",
"0.7361606",
"0.7182701",
"0.71712434",
"0.71273607",
"0.7107343",
"0.6911286",
"0.688435",
"0.68312716",
"0.68311304",
"0.67950535",
"0.67895275",
"0.676004",
"0.6739662",
"0.6689379",
"0.66687655",
"0.66634023",
"0.6639029",
"0.6617656",
"0.65589416",
"0.6556094",
"0.64959854",
"0.64365697",
"0.6433647",
"0.6412893",
"0.6412809",
"0.63883823",
"0.63150704",
"0.62922084",
"0.6244042",
"0.62330425",
"0.6213038",
"0.61955744",
"0.619219",
"0.61890393",
"0.61864996",
"0.618614",
"0.6184341",
"0.61783123",
"0.6133874",
"0.61155283",
"0.60839623",
"0.60753864",
"0.60587525",
"0.6037136",
"0.6024573",
"0.6013402",
"0.6012391",
"0.5993151",
"0.59894836",
"0.5983835",
"0.59575856",
"0.59457237",
"0.59333116",
"0.59245163",
"0.5910416",
"0.5907653",
"0.5905261",
"0.58931476",
"0.588558",
"0.58844334",
"0.58844334",
"0.5883772",
"0.5878695",
"0.5852038",
"0.5851777",
"0.5844342",
"0.5840611",
"0.58385175",
"0.58312124",
"0.5826348",
"0.5824882",
"0.5812391",
"0.5808736",
"0.5805348",
"0.57978296",
"0.5792104",
"0.57901776",
"0.57848334",
"0.5755781",
"0.57512367",
"0.57492983",
"0.5734641",
"0.57253593",
"0.5710339",
"0.5706776",
"0.5702961",
"0.56948376",
"0.56898755",
"0.5689082",
"0.5676953",
"0.5670361",
"0.56579745",
"0.56484824",
"0.5645096",
"0.56423265",
"0.5638084",
"0.56306994",
"0.56303334",
"0.56254756"
] | 0.5945095 | 53 |
Adds the document to the index. | public void addDocument(TokenizedDocument document) {
try {
indexWriter.addDocument(createDocument(document),myAnalyzer);
} catch (CorruptIndexException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void addDocument(IDocument document) {\n if (indexedFile == null) {\n indexedFile= index.addDocument(document);\n } else {\n throw new IllegalStateException(); } }",
"private void indexItem(IndexDocument indexDoc) {\n if(bDebug) System.out.println(\"\\n*** document to index - \" + indexDoc);\n Indexer indexer=null;\n try {\n indexer=new Indexer(PetstoreConstants.PETSTORE_INDEX_DIRECTORY, false);\n PetstoreUtil.getLogger().log(Level.FINE, \"Adding document to index: \" + indexDoc.toString());\n indexer.addDocument(indexDoc);\n } catch (Exception e) {\n PetstoreUtil.getLogger().log(Level.WARNING, \"index.exception\", e);\n e.printStackTrace();\n } finally {\n try {\n // must close file or will not be able to reindex\n if(indexer != null) {\n indexer.close();\n }\n } catch (Exception ee) {\n ee.printStackTrace();\n }\n }\n }",
"public void add(Document document) {\n document.setIsAllocated();\n documents.add(document);\n }",
"public void index(final Document doc) {\t\n\t\ttry {\n\t\t\t_reopenToken = _trackingIndexWriter.addDocument(doc);\n\t\t\tlog.debug(\"document indexed in lucene\");\n\t\t} catch(IOException ioEx) {\n\t\t\tlog.error(\"Error while in Lucene index operation: {}\",ioEx.getMessage(),\n\t\t\t\t\t\t\t\t\t\t\t \t\t ioEx);\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\t_indexWriter.commit();\n\t\t\t} catch (IOException ioEx) {\n\t\t\t\tlog.error(\"Error while commiting changes to Lucene index: {}\",ioEx.getMessage(),\n\t\t\t\t\t\t\t\t\t\t\t\t \t\t \t\t\t\t\t ioEx);\n\t\t\t}\n\t\t}\n\t}",
"@Test\r\n\tpublic void indexOneLater() throws Exception {\n\t\tSolrInputDocument sd = new SolrInputDocument();\r\n\t\tsd.addField(\"id\", \"addone\");\r\n\t\tsd.addField(\"channelid\", \"9999\");\r\n\t\tsd.addField(\"topictree\", \"tptree\");\r\n\t\tsd.addField(\"topicid\", \"tpid\");\r\n\t\tsd.addField(\"dkeys\", \"测试\");\r\n\t\tsd.addField(\"title\", \"junit 标题\");\r\n\t\tsd.addField(\"ptime\", new Date());\r\n\t\tsd.addField(\"url\", \"/junit/test/com\");\r\n//\t\t\tSystem.out.println(doc);\r\n//\t\tbuffer.add(sd);\r\n\t\tdocIndexer.addDocumentAndCommitLater(sd, 1);\r\n\t}",
"private void addContentToLuceneDoc() {\n\t\t// Finish storing the document in the document store (parts of it may already have been\n\t\t// written because we write in chunks to save memory), retrieve the content id, and store\n\t\t// that in Lucene.\n\t\tint contentId = storeCapturedContent();\n\t\tcurrentLuceneDoc.add(new NumericField(ComplexFieldUtil.fieldName(\"contents\", \"cid\"),\n\t\t\t\tStore.YES, false).setIntValue(contentId));\n\n\t\t// Store the different properties of the complex contents field that were gathered in\n\t\t// lists while parsing.\n\t\tcontentsField.addToLuceneDoc(currentLuceneDoc);\n\t}",
"public void addDoc (DocFile newFile) {\n\n // Check if the file extension is valid\n if (!isValid(newFile) ) {\n return;\n }\n\n // Create the new document, add in DocID fields and UploaderID fields\n org.apache.lucene.document.Document newDocument = new Document();\n\n Field docIDField = new StringField(Constants.INDEX_KEY_ID, newFile.getId(), Store.YES);\n Field docPathField = new StringField(Constants.INDEX_KEY_PATH, newFile.getPath(), Store.YES);\n Field userIDField = new StringField(Constants.INDEX_KEY_OWNER, newFile.getOwner(), Store.YES);\n Field filenameField = new TextField(Constants.INDEX_KEY_FILENAME, newFile.getFilename(), Store.YES);\n Field isPublicField = new TextField(Constants.INDEX_KEY_STATUS, newFile.isPublic().toString(), Store.YES);\n Field titleField = new TextField(Constants.INDEX_KEY_TITLE, newFile.getTitle(), Store.YES);\n Field typeField = new TextField(Constants.INDEX_KEY_TYPE, newFile.getFileType(), Store.YES);\n Field permissionField = new TextField(Constants.INDEX_KEY_PERMISSION, Integer.toString(newFile.getPermission()), Store.YES);\n Field courseField = new TextField(Constants.INDEX_KEY_COURSE, newFile.getCourseCode(), Store.YES);\n \n \n newDocument.add(docIDField);\n newDocument.add(docPathField);\n newDocument.add(userIDField);\n newDocument.add(filenameField);\n newDocument.add(isPublicField);\n newDocument.add(titleField);\n newDocument.add(typeField);\n newDocument.add(permissionField);\n newDocument.add(courseField);\n \n //Call Content Generator to add in the ContentField\n ContentGenerator.generateContent(newDocument, newFile);\n\n // Add the Document to the Index\n try {\n writer.addDocument(newDocument);\n writer.commit();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }",
"public void addDocument(Document d) throws IndexerException {\n\t\t\n\t//if (!isvaliddir) {System.out.println(\"INVALID PATH/execution !\");return;}\n\t\n\t\n\t//Tokenizing\n\t//one thgread\n\tDocID did=new DocID(d.getField(FieldNames.FILEID),\n\t\t\td.getField(FieldNames.CATEGORY),\n\t\t\td.getField(FieldNames.AUTHOR));\n\t\n\tTokenStream stream=tokenize(FieldNames.CATEGORY,d);\n\tAnalyzer analyz=analyze(FieldNames.CATEGORY, stream);\n\tCategoryIndex.getInst().doIndexing(did.getdID(), stream);\n\t/*\t}catch(Exception e)\n\t{\n\t\tif (e instanceof NullPointerException ||e instanceof StringIndexOutOfBoundsException\n\t\t\t\t||e instanceof ArrayIndexOutOfBoundsException ||e instanceof IllegalArgumentException\n\t\t\t\t);\n\t}\n\ttry{*/TokenStream stream1=tokenize(FieldNames.AUTHOR,d);\n\tAnalyzer analyz1=analyze(FieldNames.AUTHOR, stream1);\n\tAuthorIndex.getInst().doIndexing(did.getdID(), stream1);\n\t/*}catch(Exception e)\n\t{\n\t\tif (e instanceof NullPointerException ||e instanceof StringIndexOutOfBoundsException\n\t\t\t\t||e instanceof ArrayIndexOutOfBoundsException ||e instanceof IllegalArgumentException\n\t\t\t\t);}\n\ttry{*/TokenStream stream2=tokenize(FieldNames.PLACE,d);\n\tAnalyzer analyz2=analyze(FieldNames.PLACE, stream2);\n\tPlaceIndex.getInst().doIndexing(did.getdID(), stream2);\n/*}catch(Exception e)\n\t{\n\tif (e instanceof NullPointerException ||e instanceof StringIndexOutOfBoundsException\n\t\t\t||e instanceof ArrayIndexOutOfBoundsException ||e instanceof IllegalArgumentException\n\t\t\t);}\n\ttry{*/tkizer = new Tokenizer();\n\tTokenStream stream3=tokenize(FieldNames.CONTENT,d);\n\tfactory = AnalyzerFactory.getInstance();\n\tAnalyzer analyz3=analyze(FieldNames.CONTENT, stream3);\n\tnew Indxr(IndexType.TERM).doIndexing(did, stream3);\n\t/*}\tcatch(Exception e)\n\t{\n\t\tif (e instanceof NullPointerException ||e instanceof StringIndexOutOfBoundsException\n\t\t\t\t||e instanceof ArrayIndexOutOfBoundsException ||e instanceof IllegalArgumentException\n\t\t\t\t);}\n\t*/\n\tdocs.add(did==null?\" \":did.toString());\n\t \n\t\na_indexrd= new IndexReader(System.getProperty(\"INDEX.DIR\"), IndexType.AUTHOR);\nc_indexrd= new IndexReader(System.getProperty(\"INDEX.DIR\"), IndexType.CATEGORY);\np_indexrd= new IndexReader(System.getProperty(\"INDEX.DIR\"), IndexType.PLACE);\nt_indexrd= new IndexReader(System.getProperty(\"INDEX.DIR\"), IndexType.TERM);\n\t\t}",
"public void add(PhotonDoc doc);",
"void index(IDocument document, IIndexerOutput output) throws java.io.IOException;",
"public static synchronized void indexDocument(CodeIndexDocument codeIndexDocument) throws IOException {\n Queue<CodeIndexDocument> queue = new ConcurrentLinkedQueue<CodeIndexDocument>();\n queue.add(codeIndexDocument);\n indexDocuments(queue);\n queue = null;\n }",
"public void addOrUpdate(Event event) throws SearchIndexException {\n logger.debug(\"Adding event {} to search index\", event.getIdentifier());\n\n // Add the resource to the index\n SearchMetadataCollection inputDocument = EventIndexUtils.toSearchMetadata(event);\n List<SearchMetadata<?>> resourceMetadata = inputDocument.getMetadata();\n ElasticsearchDocument doc = new ElasticsearchDocument(inputDocument.getIdentifier(),\n inputDocument.getDocumentType(), resourceMetadata);\n try {\n update(doc);\n } catch (Throwable t) {\n throw new SearchIndexException(\"Cannot write resource \" + event + \" to index\", t);\n }\n }",
"public com.guidewire.datamodel.IndexDocument.Index addNewIndex()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n com.guidewire.datamodel.IndexDocument.Index target = null;\r\n target = (com.guidewire.datamodel.IndexDocument.Index)get_store().add_element_user(INDEX$12);\r\n return target;\r\n }\r\n }",
"public Document addDocument(Document doc) {\n\t\tthis.documents.put(doc.getIdentifier(),doc);\n\t\treturn doc;\n\t}",
"public Document addDocument(Document arg0) throws ContestManagementException {\r\n return null;\r\n }",
"public void addInDocument(com.hps.july.persistence.Document arg0) throws java.rmi.RemoteException, javax.ejb.FinderException, javax.naming.NamingException {\n\n instantiateEJB();\n ejbRef().addInDocument(arg0);\n }",
"String createIndex() {\n\t\tboolean res = indexExists();\n\t\t@SuppressWarnings(\"unused\")\n\t\tint resCode;\n\t\tif (!res) {\n\t\t\tresCode = doHttpOperation(esIndexUrl, HTTP_PUT, null);\n\t\t}\n\t\treturn lastResponse;\n\t}",
"public static void add(Transcription t) throws IOException, SQLException\r\n {\r\n IndexWriter writer = null;\r\n Analyzer analyser;\r\n Directory directory;\r\n /**@TODO parameterize this location*/\r\n String dest = \"/usr/indexTranscriptions\";\r\n\r\n directory = FSDirectory.getDirectory(dest, true);\r\n analyser = new StandardAnalyzer();\r\n writer = new IndexWriter(directory, analyser, true);\r\n Document doc=new Document();\r\n Field field;\r\n field = new Field(\"text\", t.getText(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"comment\", t.getComment(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"creator\", \"\" + t.UID, Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"security\", \"\" + \"private\", Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"line\", \"\" + t.getLine(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"page\", \"\" + t.getFolio(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"id\", \"\" + t.getLineID(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"manuscript\", \"\" + new Manuscript(t.getFolio()).getID(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n field = new Field(\"projectID\", \"\" + t.getProjectID(), Field.Store.YES, Field.Index.ANALYZED);\r\n doc.add(field);\r\n writer.addDocument(doc);\r\n writer.commit();\r\n \twriter.close();\r\n\r\n }",
"public Document addDocument(Document document) throws ContestManagementException {\r\n return null;\r\n }",
"private static void addDoc(IndexWriter w, String name, String birthDate, String deathDate) {\n\t\tDocument doc = new Document();\n\t\tdoc.add(new TextField(\"name\", name, Field.Store.YES));\n\t\tdoc.add(new StringField(\"birthStartDate\", birthDate, Field.Store.YES)); \t\t\t\t// use a string field for isbn because we don't want it tokenized\n\t\tdoc.add(new StringField(\"deathEndDate\", deathDate, Field.Store.YES));\n\t\t\n\t\ttry {\n\t\t\tw.addDocument(doc);\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void indexCreate()\n {\n try{\n Directory dir = FSDirectory.open(Paths.get(\"indice/\"));\n Analyzer analyzer = new StandardAnalyzer();\n IndexWriterConfig iwc = new IndexWriterConfig(analyzer);\n iwc.setOpenMode(OpenMode.CREATE);\n IndexWriter writer = new IndexWriter(dir,iwc);\n MongoConnection mongo = MongoConnection.getMongo();\n mongo.OpenMongoClient();\n DBCursor cursor = mongo.getTweets();\n Document doc = null;\n\n while (cursor.hasNext()) {\n DBObject cur = cursor.next();\n if (cur.get(\"retweet\").toString().equals(\"false\")) {\n doc = new Document();\n doc.add(new StringField(\"id\", cur.get(\"_id\").toString(), Field.Store.YES));\n doc.add(new TextField(\"text\", cur.get(\"text\").toString(), Field.Store.YES));\n doc.add(new StringField(\"analysis\", cur.get(\"analysis\").toString(), Field.Store.YES));\n //doc.add(new StringField(\"finalCountry\",cur.get(\"finalCountry\").toString(),Field.Store.YES));\n doc.add(new StringField(\"userScreenName\", cur.get(\"userScreenName\").toString(), Field.Store.YES));\n doc.add(new StringField(\"userFollowersCount\", cur.get(\"userFollowersCount\").toString(), Field.Store.YES));\n doc.add(new StringField(\"favoriteCount\", cur.get(\"favoriteCount\").toString(), Field.Store.YES));\n\n if (writer.getConfig().getOpenMode() == OpenMode.CREATE) {\n System.out.println(\"Indexando el tweet: \" + doc.get(\"text\") + \"\\n\");\n writer.addDocument(doc);\n System.out.println(doc);\n } else {\n System.out.println(\"Actualizando el tweet: \" + doc.get(\"text\") + \"\\n\");\n writer.updateDocument(new Term(\"text\" + cur.get(\"text\")), doc);\n System.out.println(doc);\n }\n }\n }\n cursor.close();\n writer.close();\n }\n catch(IOException ioe){\n System.out.println(\" Error en \"+ ioe.getClass() + \"\\n mensaje: \" + ioe.getMessage());\n }\n }",
"void documentAdded(SingleDocumentModel model);",
"public UpdateResponse add(SolrInputDocument doc) throws SolrServerException, IOException {\n return add(doc, -1);\n }",
"public void indexDocument(String documentName, ArrayList<String> documentTokens) {\n for (String token : documentTokens) {\n if (!this.index.containsKey(token)) {\n // Create a key with that token\n this.index.put(token, new HashMap<>());\n }\n\n // Get the HashMap associated with that term\n HashMap<String, Integer> term = this.index.get(token);\n\n // Check if term has a posting for the document\n if (term.containsKey(documentName)) {\n // Increase its occurrence by 1\n int occurrences = term.get(documentName);\n term.put(documentName, ++occurrences);\n } else {\n // Create a new posting for the term\n term.put(documentName, 1);\n }\n }\n }",
"IndexedDocument indexDocument(String name, String type, String id, CharSequence document)\n throws ElasticException;",
"public boolean addDocument(Document newDocument) {\n try {\n if (searchDocumentInCourse(newDocument)) {\n throw new Exception();\n }\n\n getDocumentListInCourse().add(newDocument);\n return true;\n } catch (Exception exception) {\n System.err.println(\"This document already exists!\");\n return false;\n\n }\n\n }",
"void addWordToDoc(int doc,VocabWord word);",
"public void add( String documentKey ) {\r\n relatedDocuments.add( documentKey );\r\n relatedDocumentsCounter++;\r\n globalRelatedDocumentsCounter++;\r\n\r\n if (relatedDocumentsCounter >= MAX_TRIGRAMS_PER_REFERENCEFILE) {\r\n saveInternal();\r\n }\r\n }",
"protected static void addDocument(CloseableHttpClient httpclient, String type, String document) throws Exception {\n HttpPost httpPut = new HttpPost(urlBuilder.getIndexRoot() + \"/\" + type);\n StringEntity inputData = new StringEntity(document);\n inputData.setContentType(CONTENTTYPE_JSON);\n httpPut.addHeader(HEADER_ACCEPT, CONTENTTYPE_JSON);\n httpPut.addHeader(HEADER_CONTENTTYPE, CONTENTTYPE_JSON);\n httpPut.setEntity(inputData);\n CloseableHttpResponse dataResponse = httpclient.execute(httpPut);\n if (dataResponse.getStatusLine().getStatusCode() != EL_REST_RESPONSE_CREATED) {\n System.out.println(\"Error response body:\");\n System.out.println(responseAsString(dataResponse));\n }\n Assert.assertEquals(dataResponse.getStatusLine().getStatusCode(), EL_REST_RESPONSE_CREATED);\n }",
"public void addDocument(Document doc) {\n\t\tif(doc != null)\n\t\t\tmyDocument.add(doc);\n\t}",
"public PreApprovalHolderBuilder addDocument(Document document) {\n documents.add(document);\n return this;\n }",
"@Override\n\t\tpublic void write(Writable key, SolrInputDocument doc)\n\t\t\t\tthrows IOException, InterruptedException {\n\t\t\ttry {\n\t\t\t\tdocs.add(doc);\n\t\t\t\tif (docs.size() >= batch) {\n\t\t\t\t\tserver.add(docs);\n\t\t\t\t\tdocs.clear();\n\t\t\t\t}\n\t\t\t} catch (SolrServerException e) {\n\t\t\t\tRuntimeException exc = new RuntimeException(e.toString(), e);\n\t\t\t\texc.setStackTrace(e.getStackTrace());\n\t\t\t\tthrow exc;\n\t\t\t}\n\t\t}",
"private int addDoc(IndexWriter w, String url, File file) throws IOException, IllegalArgumentException {\n\t\t\n\t\t//TODO: needs to be able to parse HTML pages here\n\t\t//File parsing\n\t\torg.jsoup.nodes.Document html = Jsoup.parse(String.join(\"\",Files.readAllLines(file.toPath())));\n\t\t\n\t\t//If we cant parse the html\n\t\tif(html == null)\n\t\t\treturn -1;\n\t\t\n\t\t\n\t\tif(PRINT_CONTENT_STRING)\n\t\t\tSystem.out.println(\"***This is the body***\\n\" + String.join(\"\",Files.readAllLines(file.toPath())));\n\t\t\n\t\tif(PRINT_CONTENT_BODY)\n\t\t\tSystem.out.println(\"***This is the body***\\n\" + html.body());\n\t\t\n\t\tString content = null;\n\t\tElement body = html.body();\n\t\t\n\t\t//Get the rest of the text in the body\n\t\tif(body != null)\n\t\t\tcontent = body.text();\n\t\t\n\t\tif(PRINT_CONTENT_TEXT)\n\t\t\tSystem.out.println(\"***This is the BODY text***\\n\" + content);\n\n\t\tString title = null;\n\t\tElement head = html.head();\n\t\tif(head != null)\n\t\t\ttitle = head.text();\n\t\t\n\t\tif(PRINT_CONTENT_TEXT)\n\t\t\tSystem.out.println(\"***This is the TITLE***\\n\" + title);\n\t\t\t\t\n\t\t//Document Creation\n\t\tDocument doc = new Document();\n\t\tField field = null;\n\t\tFieldType type = new FieldType();\n\t\ttype.setIndexOptions(IndexOptions.DOCS_AND_FREQS_AND_POSITIONS);\n\t\ttype.setStored(true); \n\t\ttype.setStoreTermVectors(true);\n\t\ttype.setTokenized(true);\n\t\t\n\t\t//If there is text in the head, it is probably a title\n\t\tif(title != null && !title.isEmpty()){\n\t\t\tfield = new Field(\"title\", title, type);\n\t\t\tfield.setBoost(15); //Set weight for the field when query matches to string in field here\n\t\t\tdoc.add(field);\n\t\t}\n\t\t\n\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\tSystem.out.println(\"This is title: \" + title);\n\n\t\t//Grab the important text tags\n\t\tElements importantTags = body.select(\"b, strong, em\");\n\n\t\tif(importantTags != null && !importantTags.isEmpty())\n\t\t{\n\t\t\tfield = new Field(\"important\", importantTags.html(), type);\n\t\t\t\n\t\t\t//Setting the bold tag boost\n\t\t\tfield.setBoost(1); \n\t\t\tdoc.add(field);\n\t\t\t\n\t\t\t//We remove any content in these tags so there is no duplicate counting\n\t\t\timportantTags.remove();\n\t\t}\n\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\tSystem.out.println(\"This is Bolding: \" + importantTags.text());\n\n\t\t\n\t\t//Grab all heading tags\n\t\tElements headingTags = body.select(\"h1, h2, h3, h4, h5, h6\");\n\n\t\tfor(int headingNum = 0; headingNum < 6; headingNum++)\n\t\t{\n\t\t\t//Attempt to index all the heading tags\n\t\t\tElements hTags = headingTags.select(\"h\" + (headingNum + 1));\n\t\t\tif(hTags != null && !hTags.isEmpty())\n\t\t\t{\n\t\t\t\tfield = new Field(\"heading\" + headingNum, hTags.html(), type);\n\t\t\t\t\n\t\t\t\t//Setting the heading tag boost\n\t\t\t\tfield.setBoost(5); \n\t\t\t\tdoc.add(field);\n\t\t\t\t\n\t\t\t\t//We remove any content in these tags so there is no duplicate counting\n\t\t\t\thTags.remove();\n\t\t\t}\n\t\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\t\tSystem.out.println(\"This is heading: \" + headingNum + \" - \" + hTags.text());\n\n\t\t}\n\t\t\n\t\t//Need to parse the remaining content after all the important tags have been deleted \n\t\tif(content != null && !content.isEmpty()){\n\t\t\tfield = new Field(\"content\", content, type);\n\t\t\t\n\t\t\t//Setting the default boost\n\t\t\tfield.setBoost(1); \n\t\t\tdoc.add(field);\n\t\t}\n\t\tif(PRINT_INDEX_TO_PARSING)\n\t\t\tSystem.out.println(\"This is content: \" + content);\n\n\t\t//Need to make sure we have content before attempting to add a link to a document\n\t\tif(doc.getFields().size() > 0)\n\t\t{\n\t\t\t//fileID field should not be used for finding terms within document, only for uniquely identifying this doc amongst others in index\n\t\t\ttype = new FieldType();\n\t\t\ttype.setStored(true);\n\t\t\ttype.setTokenized(false);\n\t\t\ttype.setStoreTermVectors(false);\n\t\t\tdoc.add(new Field(\"url\", url, type));\n\t\t\t\n\t\t\tw.addDocument(doc);\n\t\t\t\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\treturn -1;\n\t}",
"private void addDoc(String path, SnapshotVersion readTime, String field, int value) {\n MutableDocument doc = doc(path, 10, map(field, value));\n remoteDocumentCache.add(doc, readTime);\n }",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray.add(arg0);\n\t\t\t}",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray.add(arg0);\n\t\t\t}",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray.add(arg0);\n\t\t\t}",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray.add(arg0);\n\t\t\t}",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray.add(arg0);\n\t\t\t}",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray.add(arg0);\n\t\t\t}",
"public void addIndex(){\n\t\tdbCol=mdb.getCollection(\"genericCollection\");\n\t\tstart=Calendar.getInstance().getTimeInMillis();\n\t\tdbCol.ensureIndex(new BasicDBObject(\"RandomGeo\", \"2d\"));\n\t\tstop = Calendar.getInstance().getTimeInMillis() - start;\n\t\tSystem.out.println(\"Mongo Index Timer \"+Long.toString(stop));\n\t}",
"public abstract Iterable<String> addDocument(TextDocument doc) throws IOException;",
"private void endDoc() {\n\t\ttry {\n\t\t\t// Report the end of the document to the IndexListener\n\t\t\tindexer.getListener().documentDone(currentDocumentName);\n\n\t\t\t// Store the captured document content in the content store\n\t\t\t// and add the contents of the complex field to the Lucene document\n\t\t\taddContentToLuceneDoc();\n\n\t\t\t// Add the Lucene document to the index\n\t\t\tindexer.add(currentLuceneDoc);\n\n\t\t\t// Report character progress\n\t\t\treportCharsProcessed();\n\n\t\t\t// Reset the contents field for the next document\n\t\t\tcontentsField.clear();\n\n\t\t\t// Should we continue or are we done?\n\t\t\tif (!indexer.continueIndexing())\n\t\t\t\tthrow new MaxDocsReachedException();\n\n\t\t} catch (MaxDocsReachedException e) {\n\n\t\t\t// We've reached our maximum number of documents we'd like to index.\n\t\t\t// This is okay; just rethrow it.\n\t\t\tthrow e;\n\n\t\t} catch (Exception e) {\n\n\t\t\t// Some error occurred.\n\t\t\tthrow ExUtil.wrapRuntimeException(e);\n\n\t\t}\n\t}",
"public void addDocumentToContest(long arg0, long arg1) throws ContestManagementException {\r\n }",
"public void addIndex() throws JNCException {\n setLeafValue(Epc.NAMESPACE,\n \"index\",\n null,\n childrenNames());\n }",
"public boolean shouldIndex(IDocument document);",
"private IndexResponse add(JsonObject jsonObj, String indexName, String typeName, OpType operation) {\n\t\tString identificationNo = getIdentifier(jsonObj);\n\t\tIndexResponse response = add(jsonObj, indexName, typeName, operation, identificationNo);\n\t\treturn response;\n\t}",
"public void addOrUpdate(Group group) throws SearchIndexException {\n logger.debug(\"Adding group {} to search index\", group.getIdentifier());\n\n // Add the resource to the index\n SearchMetadataCollection inputDocument = GroupIndexUtils.toSearchMetadata(group);\n List<SearchMetadata<?>> resourceMetadata = inputDocument.getMetadata();\n ElasticsearchDocument doc = new ElasticsearchDocument(inputDocument.getIdentifier(),\n inputDocument.getDocumentType(), resourceMetadata);\n try {\n update(doc);\n } catch (Throwable t) {\n throw new SearchIndexException(\"Cannot write resource \" + group + \" to index\", t);\n }\n }",
"public void addOrUpdate(Series series) throws SearchIndexException {\n logger.debug(\"Adding series {} to search index\", series.getIdentifier());\n\n // Add the resource to the index\n SearchMetadataCollection inputDocument = SeriesIndexUtils.toSearchMetadata(series);\n List<SearchMetadata<?>> resourceMetadata = inputDocument.getMetadata();\n ElasticsearchDocument doc = new ElasticsearchDocument(inputDocument.getIdentifier(),\n inputDocument.getDocumentType(), resourceMetadata);\n try {\n update(doc);\n } catch (Throwable t) {\n throw new SearchIndexException(\"Cannot write resource \" + series + \" to index\", t);\n }\n }",
"@Override\r\n\tprotected void indexDocument(PluginServiceCallbacks callbacks, JSONResponse jsonResults, HttpServletRequest request,\r\n\t\t\tIndexing indexing) throws Exception {\n\t\t\r\n\t}",
"public void addDocumenttoSolr(final SolrInputDocument document, Email email)\r\n\t\t\tthrows FileNotFoundException, IOException, SAXException, TikaException, SolrServerException {\n\t\tSystem.out.println(email.toString());\r\n/*\t\tdocument.setField(LocalConstants.documentFrom, email.getFrom());\r\n\t\tdocument.setField(LocalConstants.documentTo, email.getTo());\r\n\t\tdocument.setField(LocalConstants.documentBody, email.getBody());\r\n*/\r\n\t\tdocument.setField(\"from\", email.getFrom());\r\n\t\tdocument.setField(\"to\", email.getTo());\r\n\t\tdocument.setField(\"body\", email.getBody());\r\n\t//document.setField(\"title\", \"972-2-5A619-12A-X\");\r\n\t\t// 2. Adds the document\r\n\t\tdocs.add(document);\r\n\t\t//client.add(document);\r\n\t\t\r\n\t\t\r\n\r\n\t\t// 3. Makes index changes visible\r\n\t\t//client.commit();\r\n\t}",
"void add(int index, Object element);",
"public void addRef(char[] word) {\n if (indexedFile == null) {\n throw new IllegalStateException(); }\n index.addRef(indexedFile, word); }",
"IndexedDocument indexDocument(\n String name,\n String type,\n String id,\n CharSequence document,\n long epochMillisUtc) throws ElasticException;",
"public void addDocumentToContest(long documentId, long contestId) throws ContestManagementException {\r\n\r\n }",
"void addIndexForRepository(long repositoryId);",
"@Override\n public void postInserts() \n {\n for(IndexObject i: myIndex.values())\n {\n i.tfidf(documentData);\n }\n }",
"public void addPDFDocument(emxPDFDocument_mxJPO document)\r\n {\r\n /*\r\n * Author : DJ\r\n * Date : 02/04/2003\r\n * Notes :\r\n * History :\r\n */\r\n super.add(document);\r\n }",
"@Override\n\tpublic void add() {\n\t\tHashMap<String, String> data = new HashMap<>();\n\t\tdata.put(\"title\", title);\n\t\tdata.put(\"author\", author);\n\t\tdata.put(\"publisher\", publisher);\n\t\tdata.put(\"isbn\", isbn);\n\t\tdata.put(\"bookID\", bookID);\n\t\tHashMap<String, Object> result = null;\n\t\tString endpoint = \"bookinfo/post.php\";\n\t\ttry {\n\t\t\tresult = APIClient.post(BookInfo.host + endpoint, data);\n\t\t\tvalid = result.get(\"status_code\").equals(\"Success\");\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void addToQueue(LuceneAction action, Document document) throws Exception {\n\t\tqueue.offer(new LuceneQueueObject(action, document));\n\t\tlogger.trace(\"Added document to queue, current queue size: \" + queue.size());\n\n\t\t// queue is getting full before the regular run() is running.\n\t\tif (queue.size() >= MAXQUEUESIZE ) {\n\t\t\tlogger.error(\"Queue overflow. Can cause memory errors. Queue size = \" + queue.size());\n\t\t\tthrow new Exception(\"Queue overflow. Can cause memory errors. Queue size = \" + queue.size());\n\t\t}\n\t\tif (queue.size() >= batchSize) {\n\t\t\tlogger.trace(\"Start processing based on size\");\n\t\t\trunIndexer();\n\t\t}\n\t}",
"public void addOrUpdate(Theme theme) throws SearchIndexException {\n logger.debug(\"Adding theme {} to search index\", theme.getIdentifier());\n\n // Add the resource to the index\n SearchMetadataCollection inputDocument = ThemeIndexUtils.toSearchMetadata(theme);\n List<SearchMetadata<?>> resourceMetadata = inputDocument.getMetadata();\n ElasticsearchDocument doc = new ElasticsearchDocument(inputDocument.getIdentifier(),\n inputDocument.getDocumentType(), resourceMetadata);\n try {\n update(doc);\n } catch (Throwable t) {\n throw new SearchIndexException(\"Cannot write resource \" + theme + \" to index\", t);\n }\n }",
"public void add(int index, E obj)\r\n {\r\n listIterator(index).add(obj);\r\n }",
"private void addFile(String file){\r\n\t\ttry(\r\n\t\t\tBufferedReader reader = new BufferedReader(new FileReader(file));\r\n\t\t){\r\n\t\t\tString html = \"\";\r\n\t\t\tString line = \"\";\r\n\t\t\t// read in html from passed file argument\r\n\t\t\twhile((line=reader.readLine())!=null){\r\n\t\t\t\thtml += line;\r\n\t\t\t}\r\n\t\t\t// retrieve all text content elements from page\r\n\t\t\tElements paragraphs = Jsoup.parse(html).select(\"p\");\r\n\t\t\tString content = \"\";\r\n\t\t\tfor (Element i : paragraphs){\r\n\t\t\t\tcontent += i.text()+\" \";\r\n\t\t\t}\r\n\t\t\t// tokenize and log all unique words\r\n\t\t\tMatcher matcher = pattern.matcher(content);\r\n\t\t\tString[] results = matcher.results().map(MatchResult::group).toArray(String[]::new);\r\n\t\t\tHashMap<String, Integer> count = new HashMap<String, Integer>();\r\n\t\t\tfor (int i = 0;i<results.length;++i){\r\n\t\t\t\tString word = results[i];\r\n\t\t\t\tif (count.get(word) != null){\r\n\t\t\t\t\tcount.put(word, count.get(word)+1);\r\n\t\t\t\t}\r\n\t\t\t\telse{\r\n\t\t\t\t\tcount.put(word, 1);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t//create term objects with ids\r\n\t\t\tHashMap<Term, Integer> rCount = new HashMap<Term, Integer>();\r\n\t\t\tint id = 0;\r\n\t\t\tfor (Map.Entry<String, Integer> subset : count.entrySet()){\r\n\t\t\t\trCount.put(new Term(processWord(subset.getKey()),id), subset.getValue());\r\n\t\t\t}\r\n\t\t\t// store data from file\r\n\t\t\tindex.put(file, new IndexedDoc(rCount));\r\n\t\t\treader.close();\r\n\t\t}\r\n\t\tcatch(Exception e){\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"public void index(EntityReference reference)\n {\n logger.debug(\"Add reference to index: {}\", reference);\n if (reference != null) {\n solr.get().index(reference, false);\n }\n }",
"public void addToShared(Document doc) {\n\t\tif(doc != null)\n\t\t\tsharedToMe.add(doc);\n\t}",
"void itemAddedToIndex(Object key, Object o);",
"public void add(int index, Object element) {\r\n addBefore(element, (index == size ? header : entry(index)));\r\n }",
"public synchronized void inserirDocumento(List<Document> dosc) throws Exception {\r\n\t\tIndexWriter indexWriter = getWriterPadrao(false);\r\n\t\tfor (Document document : dosc) {\r\n\t\t\tindexWriter.addDocument(document);\r\n\t\t\t\r\n\t\t}\r\n\t\tindexWriter.close();\r\n\t}",
"public void newDocument();",
"public void add(int index, CoreResourceHandle e) {\n if (index < 0 || index > doSize()) {\n throw new IndexOutOfBoundsException();\n } else if (e != null) {\n doAdd(index, e);\n } else {\n throw new NullPointerException();\n }\n }",
"private static void peopleAndEventsCreate(File selectedFolder, File selectedFile, String nameOfLuceneIndex) throws Exception {\n\t\tStandardAnalyzer analyzer = new StandardAnalyzer();\n\n\t /* Where to store index */\n\t\tFile directoryOfIndex = new File(selectedFolder + nameOfLuceneIndex);\n\t\tdeleteDirectory(directoryOfIndex);\t\t\t\t\t\t\t\t\t\t\t\t\t\t// before creating new index, the old one is deleted\n\t Directory index = FSDirectory.open(directoryOfIndex);\n\n\t IndexWriterConfig config = new IndexWriterConfig(Version.LATEST, analyzer);\n\t IndexWriter w = new IndexWriter(index, config);\n\t \n\t\tBufferedReader in;\n\t\ttry {\n\t\t\tin = new BufferedReader(new InputStreamReader(new FileInputStream(selectedFile), \"UTF-8\"));\n\n\t\t\twhile (in.ready()) {\n\t\t\t\tString oneLine = in.readLine();\n\t\t\t\t\n\t\t\t\tString[] splittedString = oneLine.split(\";\");\n\t\t\t\t\n\t\t\t\tif(splittedString.length == 2) {\n\t\t\t\t\taddDoc(w, splittedString[0], splittedString[1], \"\");\n\t\t\t\t}\n\t\t\t\telse if(splittedString.length == 3) {\n\t\t\t\t\taddDoc(w, splittedString[0], splittedString[1], splittedString[2]);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tin.close();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t \n\t w.close();\n\t}",
"public interface BoostingIndexer {\r\n\t/**\r\n\t * Add a new {@link Document} to the Index or update an existing one.<br> \r\n\t * When adding a document, its dynamic boosts values must be set. Specifying the values is accomplished by\r\n\t * passing the dynamicBoosts parameter with a Map from the boost index (zero based) to the boost value (a <code>double</code>).\r\n\t * In this map, no index can be larger than the number of available boosts the {@link IndexEngine}'s {@link Scorer} has, minus one (since it is zero based).\r\n\t * The value for any available boost index not specified in the map is defaulted to zero. \r\n\t * \r\n\t * @param docId external (customer) identifier of the document to add\r\n\t * @param document the {@link Document} to add\r\n\t * @param timestampBoost a <code>float</code> representing the time of the document (the younger the document, the larger the boost should be)\r\n\t * @param dynamicBoosts a Map from the boost index (zero based) to the boost value (a <code>double</code>).\r\n\t * @throws {@link IllegalArgumentException} if an invalid index is passed for a boost \r\n\t */\r\n\tpublic void add(String docId, Document document, int timestampBoost, Map<Integer, Double> dynamicBoosts);\r\n\r\n\t/**\r\n\t * Remove a document from the index.\r\n\t * \r\n\t * @param docId external (customer) identifier of the document to remove\r\n\t */\r\n\tpublic void del(String docId);\r\n\t\r\n\t/**\r\n\t * Update the special boost for the timestamp\r\n\t * \r\n\t * @param docId external (customer) identifier of the document\r\n\t * @param timestampBoost a <code>float</code> representing the time of the document (the younger the document, the larger the boost should be)\r\n\t */\r\n\tpublic void updateTimestamp(String docId, int timestampBoost);\r\n\t\r\n\t/**\r\n\t * Update one or more of the dynamic boosts values.\r\n\t * \r\n\t * @param docId external (customer) identifier of the document\r\n\t * @param updatedBoosts a Map from the boost index (zero based) to the boost value (a <code>double</code>). No index can be larger than the available boosts the {@link IndexEngine}'s {@link Scorer} has, minus one (since it is zero based)\r\n\t * @throws {@link IllegalArgumentException} if an invalid index is passed for a boost \r\n\t */\r\n\tpublic void updateBoosts(String docId, Map<Integer, Double> updatedBoosts);\r\n\r\n public void updateCategories(String docId, Map<String, String> categories);\r\n\t/**\r\n\t * Promote a document to be the first result for a specific query.\r\n\t * \r\n\t * @param docId external (customer) identifier of the document\r\n\t * @param query the exact query the document must be promoted to the first result for\r\n\t */\r\n public void promoteResult(String docId, String query);\r\n\r\n /**\r\n * Dumps the current state to disk.\r\n */\r\n public void dump() throws IOException;\r\n\r\n public void addScoreFunction(int functionIndex, String definition) throws Exception;\r\n\r\n public void removeScoreFunction(int functionIndex);\r\n\r\n public Map<Integer,String> listScoreFunctions();\r\n \r\n public Map<String, String> getStats();\r\n\r\n}",
"public void createIndex() throws IOException {\n\t\tindexWriter.commit();\n\t\ttaxoWriter.commit();\n\n\t\t// categories\n\t\tfor (Article.Facets f : Article.Facets.values()) {\n\t\t\ttaxoWriter.addCategory(new CategoryPath(f.toString()));\n\t\t}\n\t\ttaxoWriter.commit();\n\n\t\tfinal Iterable<Article> articles = articleRepository.findAll();\n\t\tint c = 0;\n\t\tfor (Article article : articles) {\n\t\t\taddArticle(indexWriter, taxoWriter, article);\n\t\t\tc++;\n\t\t}\n\t\t// commit\n\t\ttaxoWriter.commit();\n\t\tindexWriter.commit();\n\n\t\ttaxoWriter.close();\n\t\tindexWriter.close();\n\n\t\ttaxoDirectory.close();\n\t\tindexDirectory.close();\n\t\tLOGGER.debug(\"{} articles indexed\", c);\n\t}",
"@Override\r\n\tprotected void saveDocument(PluginServiceCallbacks callbacks, JSONResponse jsonResults, HttpServletRequest request,\r\n\t\t\tIndexing indexing) throws Exception {\n\t\t\r\n\t}",
"@Override\n public void indexPersistable() {\n searchIndexService.indexAllResourcesInCollectionSubTreeAsync(getPersistable());\n }",
"@Transactional\n\t@Override\n\tpublic void addDocuments(Documents documents) {\n\t\tdocumentsDao.addDocuments(documents);\n\t}",
"public void add(int index, E element);",
"public void insert (Object object) throws IOException {\n assert indexWriter != null : \"IndexWriter is uninitialized. Initialize it before inserting.\";\n insert(AppUtils.getMapFromObject(object));\n }",
"public void addIndex(final PgIndex index) {\n indexes.add(index);\n }",
"private void indexDocumentHelper(HashMap<String, StringBuilder> fm)\n\t\t\tthrows IOException {\n\n\t\tIndexWriter writer = getIndexWriter();\n\n\t\tDocument doc = new Document();\n\n\t\tfor (int i = 0; i < fieldNames.length; i++) {\n\n\t\t\tif (fieldNames[i].equals(\"DOCNO\")) {\n\n\t\t\t\tdoc.add(new StringField(fieldNames[i], fm.get(fieldNames[i])\n\t\t\t\t\t\t.toString(), Field.Store.YES));\n\t\t\t}\n\n\t\t\telse {\n\t\t\t\tdoc.add(new TextField(fieldNames[i], fm.get(fieldNames[i])\n\t\t\t\t\t\t.toString(), Field.Store.YES));\n\t\t\t}\n\t\t}\n\n\t\twriter.addDocument(doc);\n\n\t}",
"public PreApprovalHolderBuilder addDocument(Builder<Document> documentBuilder) {\n return addDocument(documentBuilder.build());\n }",
"private void updateIndex() throws IOException {\n // maintain the document store (corpus) - if there is one\n if (currentMemoryIndex.containsPart(\"corpus\")) {\n // get all corpora + shove into document store\n ArrayList<DocumentReader> readers = new ArrayList<>();\n readers.add((DocumentReader) currentMemoryIndex.getIndexPart(\"corpus\"));\n for (String path : geometricParts.getAllShards().getBinPaths()) {\n String corpus = path + File.separator + \"corpus\";\n readers.add(new CorpusReader(corpus));\n }\n }\n // finally write new checkpointing data (checkpoints the disk indexes)\n Parameters checkpoint = createCheckpoint();\n this.checkpointer.saveCheckpoint(checkpoint);\n }",
"public void addMapping(XContentBuilder mapping) {\n try {\n HttpEntity entity = new StringEntity(mapping.string(), ContentType.APPLICATION_JSON);\n\n esrResource\n .getClient()\n .performRequest(\"PUT\", \"/\" + index + \"/_mapping/\" + type, Collections.emptyMap(), entity);\n } catch (IOException ioe) {\n getMonitor().error(\"Unable to add mapping to index\", ioe);\n }\n }",
"public void addIndex(String collectionName, DBObject index){\n DBCollection collection =this.getDBCollection(collectionName);\n collection.createIndex(index);\n }",
"private static void createIndexEntry(Document document, int menuId, String filename, String path) throws Exception {\r\n Indexer index = (Indexer) Context.getInstance().getBean(Indexer.class);\r\n index.deleteFile(String.valueOf(menuId), document.getLanguage());\r\n index.addDirectory(new File(path + filename), document);\r\n }",
"public boolean addOrUpdateDoc(String indice, String type, Map<String, Object> values) {\n String id = (String) values.get(\"id\");\n\n // 无 id 新增 Doc\n if (id == null || id.trim().length() == 0) {\n IndexResponse actionGet = client.prepareIndex(indice, type)\n .setSource(values).execute().actionGet();\n return actionGet.isCreated();\n } else { // Add or Update\n IndexRequest indexRequest =\n new IndexRequest(indice, type, (String) values.get(\"id\"))\n .source(values);\n UpdateRequest updateRequest =\n new UpdateRequest(indice, type, (String) values.get(\"id\"))\n .upsert(indexRequest);\n UpdateResponse updateResponse = client.update(updateRequest).actionGet();\n return updateResponse.isCreated();\n }\n }",
"public void putDocumentAfterEdit() {\r\n\t\tif(pointer < strategy.getEntireHistory().size()-1) {\r\n\t\t\tstrategy.putVersion(currentDocument);\r\n\t\t}\r\n\t}",
"void addWordsToDoc(int doc,List<VocabWord> words);",
"public void doNew() {\n\n if (!canChangeDocuments()) {\n return;\n }\n \n setDocument(fApplication.createNewDocument());\n }",
"public void addIndex(Index index) throws AppException {\n\t\taddIndex(index, false);\n\t}",
"public JestResult createNewDocument(GTData data) throws IOException {\n Gson gson = new Gson();\n String json = gson.toJson(data);\n Index request = new Index.Builder(json)\n .index(INDEX_NAME)\n .type(data.getClass().toString())\n .id(data.getObjectID())\n .build();\n\n JestResult result = client.execute(request);\n return result;\n }",
"public void indexFileOrDirectory(String fileName) {\r\n\r\n addFiles(new File(fileName));\r\n\r\n int originalNumDocs = writer.numRamDocs();\r\n for (File f : queue) {\r\n try {\r\n Document doc = new Document();\r\n\r\n // Creation of a simpledateformatter in order to print the last-modified-date of our files.\r\n SimpleDateFormat sdf = new SimpleDateFormat(\"MM/dd/yyyy HH:mm:ss\");\r\n String date = sdf.format(f.lastModified());\r\n\r\n if (f.getName().endsWith(\".html\")) {\r\n\r\n // Creation of a jsoup document to help us with our html parsing.\r\n org.jsoup.nodes.Document htmlFile = Jsoup.parse(f, null);\r\n String body = htmlFile.body().text();\r\n String title = htmlFile.title();\r\n String summary = getSummary(htmlFile);\r\n\r\n\r\n doc.add(new TextField(\"contents\", body + \" \" + title + \" \" + date, Field.Store.YES));\r\n doc.add(new TextField(\"title\", title, Field.Store.YES));\r\n doc.add(new StringField(\"path\", f.getPath(), Field.Store.YES));\r\n doc.add(new TextField(\"modified-date\", date, Field.Store.YES));\r\n doc.add(new StringField(\"summary\", summary, Field.Store.YES));\r\n\r\n }\r\n else {\r\n String content = FileUtils.readFileToString(f, StandardCharsets.UTF_8);\r\n\r\n doc.add(new TextField(\"contents\", content + \" \" + date, Field.Store.YES));\r\n doc.add(new StringField(\"path\", f.getPath(), Field.Store.YES));\r\n doc.add(new TextField(\"modified-date\", date, Field.Store.YES));\r\n }\r\n doc.add(new StringField(\"filename\", f.getName(), Field.Store.YES));\r\n\r\n writer.addDocument(doc);\r\n System.out.println(\"Added: \" + f);\r\n } catch (Exception e) {\r\n System.out.println(\"Could not add: \" + f);\r\n }\r\n }\r\n\r\n int newNumDocs = writer.numDocs();\r\n System.out.println(\"\");\r\n System.out.println(\"************************\");\r\n System.out.println((newNumDocs - originalNumDocs) + \" documents added.\");\r\n System.out.println(\"************************\");\r\n\r\n queue.clear();\r\n }",
"void add(int index, T element);",
"void add(int index, T element);",
"public void onIndexUpdate();",
"public abstract void add(int index, E e);",
"public void createIndex(Configuration configuration){\n }",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray_bp.add(arg0);\n\t\t\t}",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray_bp.add(arg0);\n\t\t\t}",
"@Override\n\t\t\tpublic void apply(Document arg0) {\n\t\t\t\tarray_bp.add(arg0);\n\t\t\t}"
] | [
"0.7694297",
"0.73839915",
"0.70007974",
"0.6926096",
"0.65725",
"0.65555537",
"0.6544636",
"0.6531199",
"0.6470441",
"0.6397763",
"0.6367806",
"0.6360126",
"0.62860364",
"0.6185825",
"0.60839516",
"0.6062179",
"0.60363734",
"0.6006108",
"0.6005824",
"0.59945846",
"0.5992627",
"0.59780467",
"0.5957227",
"0.59437716",
"0.5915484",
"0.5909112",
"0.5887056",
"0.58774513",
"0.58768266",
"0.5852573",
"0.58500814",
"0.5848289",
"0.58454454",
"0.58368635",
"0.58129305",
"0.58129305",
"0.58129305",
"0.58129305",
"0.58129305",
"0.58129305",
"0.5779349",
"0.5770188",
"0.5755583",
"0.57282364",
"0.57198167",
"0.57194453",
"0.57098347",
"0.5690683",
"0.56835586",
"0.56833464",
"0.5669345",
"0.5666625",
"0.5662847",
"0.56479156",
"0.5624602",
"0.56154174",
"0.5608264",
"0.5600479",
"0.5593787",
"0.55862147",
"0.55802894",
"0.55776536",
"0.5573666",
"0.55728793",
"0.5558227",
"0.5554611",
"0.55539757",
"0.5553421",
"0.5541673",
"0.5535127",
"0.5523855",
"0.552206",
"0.5514079",
"0.5509485",
"0.55043083",
"0.54996574",
"0.54981744",
"0.5494729",
"0.54853",
"0.5466343",
"0.54550683",
"0.5448234",
"0.5444377",
"0.54412514",
"0.5426682",
"0.5424402",
"0.5420523",
"0.5419726",
"0.54110724",
"0.5409416",
"0.5394716",
"0.53819716",
"0.5379815",
"0.5379815",
"0.53782296",
"0.53753084",
"0.53665054",
"0.5365123",
"0.5365123",
"0.5365123"
] | 0.7000517 | 3 |
Closes and optimize the index. | public void close() {
try {
indexWriter.optimize();
indexWriter.close();
IndexSearcher = new IndexSearcher(idx);
} catch (CorruptIndexException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void close() throws CorruptIndexException, IOException {\n\n\t\tidxWriter.forceMerge(1);\n\t\tidxWriter.commit();\n\t\tidxWriter.close();\n\t}",
"public void close() throws IndexException {\n }",
"public void close() throws IndexerException {\n\t\t//TODO\n\t\t\n\t}",
"@Override\n public void close()\n {\n notifyLegacyIndexOperationQueue();\n\n }",
"@Override\n public void close() throws IOException {\n flushCurrentIndexBlock();\n\n // logger.info(\"Performing final merge\");\n // try {\n //Bin finalMergeBin = geometricParts.getAllShards();\n //doMerge(finalMergeBin, getNextIndexShardFolder(finalMergeBin.size + 1));\n // check point is updated by the merge op.\n\n // } catch (IOException ex) {\n // Logger.getLogger(GeometricRetrieval.class.getName()).log(Level.SEVERE, null, ex);\n //}\n\n }",
"@Test\n public void close() throws Exception {\n ResizeRequest request = new ResizeRequest(\"target_index\", \"source_index\");\n /** 可选参数*/\n\n AcknowledgedResponse response = synchronousShrink(client, request);\n log.info(\"Shrink索引:{}成功?:{}\", Consts.INDEX_NAME, response.isAcknowledged());\n\n }",
"public void closeIndexWriter() throws IOException {\n if(indexWriter != null) {\n try {\n indexWriter.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }",
"public void close() throws IOException{\n\t\tSystem.out.println(\"Indexed \" + writer.numDocs() + \" Docs!\");\n\t\twriter.commit();\n\t\twriter.close();\n\t}",
"public void Close() throws IOException, ClassNotFoundException {\n\t\tsaveBlock(); \n\t\tmergeAllIndex();\n\t\tsaveToken();\n\t\tdocIdx.close();\n\t}",
"@Override\npublic void close() throws IOException, JoinsException, SortException, IndexException {\n\t\n}",
"void stopIndexing();",
"public void truncate() {\n\t\ttry {\n\t\t\t_reopenToken = _trackingIndexWriter.deleteAll();\n\t\t\tlog.warn(\"lucene index truncated\");\n\t\t} catch(IOException ioEx) {\n\t\t\tlog.error(\"Error truncating lucene index: {}\",ioEx.getMessage(),\n\t\t\t\t\t\t\t\t\t\t\t \t\t \t ioEx);\t\t\t\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\t_indexWriter.commit(); \n\t\t\t} catch (IOException ioEx) {\n\t\t\t\tlog.error(\"Error truncating lucene index: {}\",ioEx.getMessage(),\n\t\t\t\t\t\t\t\t\t\t\t\t \t\t\t ioEx);\n\t\t\t}\n\t\t}\n\t}",
"private synchronized void criarIndice() throws Exception {\r\n\t\tIndexWriter indexWriter = getWriterPadrao(true);\r\n\t\ttry {\r\n\t\t\tindexWriter.getAnalyzer().close();\r\n\t\t\tindexWriter.close();\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"public void optimize() {\n\t\ttry {\n\t\t\t_indexWriter.forceMerge(1);\n\t\t\tlog.debug(\"Lucene index merged into one segment\");\n\t\t} catch (IOException ioEx) {\n\t\t\tlog.error(\"Error optimizing lucene index {}\",ioEx.getMessage(),\n\t\t\t\t\t\t\t\t\t\t\t\t\t ioEx);\n\t\t}\n\t}",
"private Reindex() {}",
"private Reindex() {}",
"public void finishedDirectIndexBuild()\n\t{\n\t\tif(logger.isInfoEnabled()){\n\t\t\tlogger.info(\"flushing utf block lexicon to disk after the direct index completed\");\n\t\t}\n\t\t//only write a temporary lexicon if there are any items in it\n\t\tif (TempLex.getNumberOfNodes() > 0)\n\t\t\twriteTemporaryLexicon();\n\n\t\t//merges the temporary lexicons\n\t\tif (tempLexFiles.size() > 0)\n\t\t{\n\t\t\ttry{\n\t\t\t\tmerge(tempLexFiles);\n\t\n\t\t\t\t//creates the offsets file\n\t\t\t\tfinal String lexiconFilename = \n\t\t\t\t\tindexPath + ApplicationSetup.FILE_SEPARATOR + \n\t\t\t\t\tindexPrefix + ApplicationSetup.LEXICONSUFFIX;\n\t\t\t\tLexiconInputStream lis = getLexInputStream(lexiconFilename);\n\t\t\t\tcreateLexiconIndex(\n\t\t\t\t\tlis,\n\t\t\t\t\tlis.numberOfEntries(),\n\t\t\t\t\t/* after inverted index is built, the lexicon will be transformed into a\n\t\t\t\t\t * normal lexicon, without block frequency */\n\t\t\t\t\tUTFLexicon.lexiconEntryLength\n\t\t\t\t\t); \n\t\t\t\tTermCount = lis.numberOfEntries();\n\t\t\t\tif (index != null)\n\t\t\t\t{\n\t\t\t\t\tindex.addIndexStructure(\"lexicon\", \"uk.ac.gla.terrier.structures.UTFBlockLexicon\");\n\t\t\t\t\tindex.addIndexStructureInputStream(\"lexicon\", \"uk.ac.gla.terrier.structures.UTFBlockLexiconInputStream\");\n\t\t\t\t\tindex.setIndexProperty(\"num.Terms\", \"\"+lis.numberOfEntries());\n\t\t\t\t\tindex.setIndexProperty(\"num.Pointers\", \"\"+lis.getNumberOfPointersRead());\n\t\t\t\t}\n\t\t\t} catch(IOException ioe){\n\t\t\t\tlogger.error(\"Indexing failed to write a lexicon index file to disk\", ioe);\n\t\t\t}\t\n\t\t}\n\t\telse\n\t\t\tlogger.warn(\"No temporary lexicons to merge, skipping\");\n\t\t\n\t}",
"public void close() throws IOException {\n for (var dos : dataStreams) {\n if (dos != null) {\n dos.close();\n }\n }\n\n for (var dos : indexStreams) {\n if (dos != null) {\n dos.close();\n }\n }\n\n // Stats\n log.info(\"Number of keys: {}\", keyCount);\n log.info(\"Number of values: {}\", valueCount);\n\n var bloomFilter = config.getBoolean(Configuration.BLOOM_FILTER_ENABLED) ?\n new BloomFilter(keyCount, config.getDouble(Configuration.BLOOM_FILTER_ERROR_FACTOR, 0.01)) :\n null;\n\n\n // Prepare files to merge\n List<File> filesToMerge = new ArrayList<>();\n try {\n // Build index file\n for (int i = 0; i < indexFiles.length; i++) {\n if (indexFiles[i] != null) {\n filesToMerge.add(buildIndex(i, bloomFilter));\n }\n }\n\n //Write metadata file\n File metadataFile = new File(tempFolder, \"metadata.dat\");\n metadataFile.deleteOnExit();\n try (var metadataOutputStream = new DataOutputStream(new BufferedOutputStream(new FileOutputStream(metadataFile)))) {\n writeMetadata(metadataOutputStream, bloomFilter);\n }\n\n filesToMerge.add(0, metadataFile);\n\n // Stats collisions\n log.info(\"Number of collisions: {}\", collisions);\n\n // Add data files\n for (File dataFile : dataFiles) {\n if (dataFile != null) {\n filesToMerge.add(dataFile);\n }\n }\n\n // Merge and write to output\n checkFreeDiskSpace(filesToMerge);\n mergeFiles(filesToMerge, outputStream);\n } finally {\n outputStream.close();\n cleanup(filesToMerge);\n }\n }",
"public void afterIndexClosed(Index index) {\n\n }",
"@Deprecated\r\n\tpublic synchronized void otimizarIndice() throws Exception {\r\n\t\tIndexWriter indexWriter = getWriterPadrao(false);\r\n\t\tindexWriter.forceMerge(50);\r\n\t\tindexWriter.close();\r\n\t}",
"public void deleteIndex() throws Exception {\n\n\t\tRetryingRunnable runnable = new RetryingRunnable() \n\t\t{\t\n\t\t\tpublic void run() throws Exception \n\t\t\t{\n\t\t\t\tIndexWriter w = createIndexWriter(true); // open for writing and close (make empty)\n\t\t\t\tw.deleteAll();\n\t\t\t\tw.commit();\n\t\t\t\tw.close(true);\n\t\t\t\t\n\t\t\t\tDirectory dir = getIndexDir();\n\t\t\t\tfor(String file: dir.listAll())\n\t\t\t\t{\n\t\t\t\t\tif( dir.fileExists(file) ) // still exits\n\t\t\t\t\t{\n\t\t\t\t\t\tdir.sync(file);\n\t\t\t\t\t\tdir.deleteFile(file);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tdir.close();\n\t\t\t}\n\t\t\t\n\t\t\tpublic boolean handleException(Throwable e) \n\t\t\t{\n\t\t\t\treturn true;\n\t\t\t}\n\t\t};\n\t\t\n\t\tchangeListener.onIndexReset(); // close searcher because index is deleted\n\t\t\n\t\trunRetryingRunnable(runnable); // delete index with retry\n\t}",
"public void closeWriter () {\n try {\n writer.close();\n indexDir.close();\n indexHandler = null;\n } catch (IOException e) {\n e.printStackTrace();\n }\n }",
"public void tIndex(IndexShort < O > index) throws Exception {\n File query = new File(testProperties.getProperty(\"test.query.input\"));\n File dbFolder = new File(testProperties.getProperty(\"test.db.path\"));\n\n int cx = 0;\n\n initIndex(index);\n //search(index, (short) 3, (byte) 3);\n //search(index, (short) 7, (byte) 1);\n //search(index, (short) 12, (byte) 3);\n \n search(index, (short) 1000, (byte) 1);\n\n search(index, (short) 1000, (byte) 3);\n\n search(index, (short) 1000, (byte) 10);\n \n search(index, (short) 1000, (byte) 50);\n \n long i = 0;\n // int realIndex = 0;\n // test special methods that only apply to\n // SynchronizableIndex\n \n\n // now we delete elements from the DB\n logger.info(\"Testing deletes\");\n i = 0;\n long max = index.databaseSize();\n while (i < max) {\n O x = index.getObject(i);\n OperationStatus ex = index.exists(x);\n assertTrue(ex.getStatus() == Status.EXISTS);\n assertTrue(ex.getId() == i);\n ex = index.delete(x);\n assertTrue(\"Status is: \" + ex.getStatus() + \" i: \" + i , ex.getStatus() == Status.OK);\n assertEquals(i, ex.getId());\n ex = index.exists(x); \n assertTrue( \"Exists after delete\" + ex.getStatus() + \" i \" + i, ex.getStatus() == Status.NOT_EXISTS);\n i++;\n }\n index.close();\n Directory.deleteDirectory(dbFolder);\n }",
"@SuppressWarnings(\"unused\")\n public void buildIndex() throws IOException {\n indexWriter = getIndexWriter(indexDir);\n ArrayList <JSONObject> jsonArrayList = parseJSONFiles(JSONdir);\n indexTweets(jsonArrayList, indexWriter);\n indexWriter.close();\n }",
"void indexReset();",
"private IndexHandler (boolean test) throws IOException {\n analyzer = new StandardAnalyzer();\n indexDir = test ? new RAMDirectory() : new DistributedDirectory(new MongoDirectory(mongoClient, \"search-engine\", \"index\"));\n //storePath = storedPath;\n config = new IndexWriterConfig(analyzer);\n\n // write separate IndexWriter to RAM for each IndexHandler\n // writer will have to be manually closed with each instance call\n // see IndexWriter documentation for .close()\n // explaining continuous closing of IndexWriter is an expensive operation\n try {\n writer = new IndexWriter(indexDir, config);\n } catch (IOException e) {\n e.printStackTrace();\n }\n }",
"private void flushCurrentIndexBlock() throws IOException {\n if (currentMemoryIndex.documentsInIndex() < 1) {\n return;\n }\n\n logger.info(\"Flushing current memory Index. id = \" + indexBlockCount);\n\n final MemoryIndex flushingMemoryIndex = currentMemoryIndex;\n final File shardFolder = getNextIndexShardFolder(1);\n\n try {\n // reset the current index\n // - this makes the flush operation thread safe while continuing to add new documents.\n resetCurrentMemoryIndex();\n } catch (Exception ex) {\n throw new IOException(ex);\n }\n\n try {\n // first flush the index to disk\n FlushToDisk.flushMemoryIndex(flushingMemoryIndex, shardFolder.getAbsolutePath(), false);\n\n // indicate that the flushing part of this thread is done\n synchronized (geometricParts) {\n // add flushed index to the set of bins -- needs to be a synconeous action\n geometricParts.add(0, shardFolder.getAbsolutePath());\n updateIndex();\n flushingMemoryIndex.close();\n }\n\n } catch (IOException e) {\n logger.severe(e.toString());\n }\n }",
"public static void main(String[] args) throws CorruptIndexException, LockObtainFailedException, IOException, ParseException{\n\t\tboolean lucene_im_mem = false;\n\t\t//1. Build the Index with varying \"database size\"\n\t\tString dirName =\"/data/home/duy113/SupSearchExp/AIDSNew/\";\n//\t\tString dirName = \"/Users/dayuyuan/Documents/workspace/Experiment/\";\n\t\tString dbFileName = dirName + \"DBFile\";\n\t\tString trainQueryName= dirName + \"TrainQuery\";\n//\t\tString testQuery15 = dirName + \"TestQuery15\";\n\t\tString testQuery25 = dirName + \"TestQuery25\";\n//\t\tString testQuery35 = dirName + \"TestQuery35\";\n\t\tGraphDatabase query = new GraphDatabase_OnDisk(testQuery25, MyFactory.getSmilesParser());\n\t\tdouble[] minSupts = new double[4];\n\t\tminSupts[0] = 0.05; minSupts[1] = 0.03; minSupts[2] =0.02; minSupts[3] = 0.01;\n \t\tint lwIndexCount[] = new int[1];\n\t\tlwIndexCount[0] = 479;\t\n//\t\tSystem.out.println(\"Build CIndexFlat Left-over: \");\n//\t\tfor(int j = 3; j< 4; j++){\n//\t\t\tdouble minSupt = minSupts[j];\n//\t\t\tfor(int i = 4; i<=10; i = i+2){\n//\t\t\t\tString baseName = dirName + \"G_\" + i + \"MinSup_\" + minSupt + \"/\";\n//\t\t\t\tGraphDatabase trainingDB = new GraphDatabase_OnDisk(dbFileName + i, MyFactory.getDFSCoder());\n//\t\t\t\tGraphDatabase trainQuery = new GraphDatabase_OnDisk(trainQueryName, MyFactory.getSmilesParser());\t\t\n//\t\t\t\tif(i == 2){\n//\t\t\t\t\tSystem.out.println(baseName + \"CIndexFlat\");\n//\t\t\t\t\tCIndexExp.buildIndex(trainingDB, trainQuery, trainingDB, baseName, minSupt, lwIndexCount[0]);\n//\t\t\t\t}\n//\t\t\t\telse{\n//\t\t\t\t\tString featureBaseName = dirName + \"G_2\" + \"MinSup_\" + minSupt + \"/\";\n//\t\t\t\t\tSystem.out.println(baseName + \"CIndexFlat with Features \" + featureBaseName);\n//\t\t\t\t\tCIndexExp.buildIndex(featureBaseName, trainingDB, baseName, minSupt);\n//\t\t\t\t}\n//\t\t\t\tSystem.gc();\n//\t\t\t}\n//\t\t}\n\t\tSystem.out.println(\"Run Query Processing: \");\n\t\tfor(int j = 0; j< 4; j++){\n\t\t\tdouble minSupt = minSupts[j];\n\t\t\tfor(int i = 2; i<=10; i = i+2){\n\t\t\t\tString baseName = dirName + \"G_\" + i + \"MinSup_\" + minSupt + \"/\";\n\t\t\t\tGraphDatabase trainingDB = new GraphDatabase_OnDisk(dbFileName + i, MyFactory.getDFSCoder());\n\t\t\t\tGraphDatabase trainQuery = new GraphDatabase_OnDisk(trainQueryName, MyFactory.getSmilesParser());\t\t\n\t\t\t\tif(j!=0 || i!=2){\n\t\t\t\t\tSystem.out.println(baseName + \"LWindex\");\n\t\t\t\t\t//LWIndexExp.buildIndex(trainingDB, trainQuery, trainingDB, trainQuery.getParser(),baseName, minSupt, lwIndexCount);\n\t\t\t\t\t//System.gc();\n\t\t\t\t\tLWIndexExp.runIndex(trainingDB, trainQuery, baseName, lucene_im_mem);\n\t\t\t\t\tLWIndexExp.runIndex(trainingDB, query, baseName, lucene_im_mem);\n\t\t\t\t\tSystem.gc();\t\t\n\t\t\t\t\tSystem.out.println(baseName + \"PrefixIndex\");\n\t\t\t\t\t//PrefixIndexExp.buildIndex(trainingDB, trainingDB, baseName, minSupt);\n\t\t\t\t\t//System.gc();\n\t\t\t\t\tPrefixIndexExp.runIndex(trainingDB, trainQuery, baseName, lucene_im_mem);\n\t\t\t\t\tPrefixIndexExp.runIndex(trainingDB, query, baseName, lucene_im_mem);\n\t\t\t\t\tSystem.gc();\t\t\n\t\t\t\t\tSystem.out.println(baseName + \"PrefixIndexHi\");\n\t\t\t\t\t//PrefixIndexExp.buildHiIndex(trainingDB, trainingDB, 2, baseName, minSupt);\n\t\t\t\t\t//System.gc();\n\t\t\t\t\tPrefixIndexExp.runHiIndex(trainingDB, trainQuery, baseName, lucene_im_mem);\n\t\t\t\t\tPrefixIndexExp.runHiIndex(trainingDB, query, baseName, lucene_im_mem);\n\t\t\t\t\tSystem.gc();\n\t\t\t\t\tSystem.out.println(baseName + \"GPTree\");\n\t\t\t\t\t//GPTreeExp.buildIndex(trainingDB, trainingDB, baseName, minSupt);\n\t\t\t\t\t//System.gc();\n\t\t\t\t\tGPTreeExp.runIndex(trainingDB, trainQuery, baseName, lucene_im_mem);\n\t\t\t\t\tGPTreeExp.runIndex(trainingDB, query, baseName, lucene_im_mem);\n\t\t\t\t\tSystem.gc();\n\t\t\t\t\tSystem.out.println(baseName + \"CIndexFlat\");\n\t\t\t\t\t//CIndexExp.buildIndex(trainingDB, trainQuery, trainingDB, baseName, minSupt, lwIndexCount[0]);\n\t\t\t\t\t//System.gc();\n\t\t\t\t\tCIndexExp.runIndex(trainingDB, trainQuery, baseName, lucene_im_mem);\n\t\t\t\t\tCIndexExp.runIndex(trainingDB, query, baseName, lucene_im_mem);\n\t\t\t\t\tSystem.gc();\n\t\t\t\t}\n\t\t\t\tif(j==0&&i==2){\n\t\t\t\t\tSystem.out.println(baseName + \"CIndexTopDown: \" + lwIndexCount[0]);\n\t\t\t\t\tCIndexExp.buildIndexTopDown(trainingDB, trainQuery, trainingDB,MyFactory.getUnCanDFS(), baseName, minSupt, 2*trainQuery.getTotalNum()/lwIndexCount[0] ); // 8000 test queries\n\t\t\t\t\t//System.gc();\n\t\t\t\t}\n\t\t\t\tSystem.out.println(baseName + \"CIndexTopDown: \" + lwIndexCount[0]);\n\t\t\t\tCIndexExp.runIndexTopDown(trainingDB, trainQuery, baseName, lucene_im_mem);\n\t\t\t\tCIndexExp.runIndexTopDown(trainingDB, query, baseName, lucene_im_mem);\n\t\t\t\tSystem.gc();\n\t\t\t}\n\t\t}\n\t\tAIDSLargeExp.main(args);\n\t}",
"public synchronized void close() throws IOException {\n\t\tif (journalWriter == null) {\n\t\t\treturn; // already closed\n\t\t}\n\t\tfor (Entry entry : new ArrayList<Entry>(lruEntries.values())) {\n\t\t\tif (entry.currentEditor != null) {\n\t\t\t\tentry.currentEditor.abort();\n\t\t\t}\n\t\t}\n\t\ttrimToSize();\n\t\tjournalWriter.close();\n\t\tjournalWriter = null;\n\t}",
"@Override\n public void end(boolean interrupted) {\n index.run(0);\n }",
"public void commit () throws IOException {\n log.info(\"Internal committing index ... \");\n this.writer().commit();\n commitCounter = 0;\n this.closeReader();\n }",
"private void updateIndex() throws IOException {\n // maintain the document store (corpus) - if there is one\n if (currentMemoryIndex.containsPart(\"corpus\")) {\n // get all corpora + shove into document store\n ArrayList<DocumentReader> readers = new ArrayList<>();\n readers.add((DocumentReader) currentMemoryIndex.getIndexPart(\"corpus\"));\n for (String path : geometricParts.getAllShards().getBinPaths()) {\n String corpus = path + File.separator + \"corpus\";\n readers.add(new CorpusReader(corpus));\n }\n }\n // finally write new checkpointing data (checkpoints the disk indexes)\n Parameters checkpoint = createCheckpoint();\n this.checkpointer.saveCheckpoint(checkpoint);\n }",
"public void flush() {\n synchronized (getLock()) {\n sIndexWritersCache.flush(this);\n sIndexReadersCache.removeIndexReader(this);\n }\n }",
"private void endDoc() {\n\t\ttry {\n\t\t\t// Report the end of the document to the IndexListener\n\t\t\tindexer.getListener().documentDone(currentDocumentName);\n\n\t\t\t// Store the captured document content in the content store\n\t\t\t// and add the contents of the complex field to the Lucene document\n\t\t\taddContentToLuceneDoc();\n\n\t\t\t// Add the Lucene document to the index\n\t\t\tindexer.add(currentLuceneDoc);\n\n\t\t\t// Report character progress\n\t\t\treportCharsProcessed();\n\n\t\t\t// Reset the contents field for the next document\n\t\t\tcontentsField.clear();\n\n\t\t\t// Should we continue or are we done?\n\t\t\tif (!indexer.continueIndexing())\n\t\t\t\tthrow new MaxDocsReachedException();\n\n\t\t} catch (MaxDocsReachedException e) {\n\n\t\t\t// We've reached our maximum number of documents we'd like to index.\n\t\t\t// This is okay; just rethrow it.\n\t\t\tthrow e;\n\n\t\t} catch (Exception e) {\n\n\t\t\t// Some error occurred.\n\t\t\tthrow ExUtil.wrapRuntimeException(e);\n\n\t\t}\n\t}",
"@Override\n\t\tpublic void close(final TaskAttemptContext ctx) throws IOException,\n\t\t\t\tInterruptedException {\n\n\t\t\ttry {\n\n\t\t\t\tif (docs.size() > 0) {\n\t\t\t\t\tserver.add(docs);\n\t\t\t\t\tdocs.clear();\n\t\t\t\t}\n\n\t\t\t\tserver.commit();\n\t\t\t} catch (SolrServerException e) {\n\t\t\t\tRuntimeException exc = new RuntimeException(e.toString(), e);\n\t\t\t\texc.setStackTrace(e.getStackTrace());\n\t\t\t\tthrow exc;\n\t\t\t} finally {\n\t\t\t\tserver.close();\n\t\t\t\texec.shutdownNow();\n\t\t\t}\n\n\t\t}",
"public void close() throws IOException {\n maxStreamPos = cache.length();\n\n seek(maxStreamPos);\n flushBefore(maxStreamPos);\n super.close();\n cache.close();\n cache = null;\n cacheFile.delete();\n cacheFile = null;\n stream.flush();\n stream = null;\n StreamCloser.removeFromQueue(closeAction);\n }",
"public void destroy() {\n \n if (indexTimer != null)\n indexTimer.cancel();\n \n }",
"public void deleteIndex() throws IOException {\n synchronized (getLock()) {\n flush();\n if (ZimbraLog.index_add.isDebugEnabled()) {\n ZimbraLog.index_add.debug(\"Deleting index \" + luceneDirectory);\n }\n\n String[] files;\n try {\n files = luceneDirectory.listAll();\n } catch (NoSuchDirectoryException ignore) {\n return;\n } catch (IOException e) {\n ZimbraLog.index_add.warn(\"Failed to delete index: %s\",\n luceneDirectory, e);\n return;\n }\n\n for (String file : files) {\n luceneDirectory.deleteFile(file);\n }\n }\n }",
"public void openIndex(String indexPath) throws IOException {\n\n }",
"private void readIndex() throws IOException {\n\t\t\tif (this.keys != null)\n\t\t\t\treturn;\n\t\t\tkeys = new HashMap<K, Long>(1024);\n\t\t\ttry {\n\t\t\t\twhile (index.hasNext()) {\n\t\t\t\t\tPair<K, Long> pair;// = new Pair<K, Long>(index.getSchema());\n\t\t\t\t\tpair = index.next();\n\t\t\t\t\tkeys.put(pair.key(), pair.value());\n\t\t\t\t\tif (firstKey == null)\n\t\t\t\t\t\tfirstKey = pair.key();\n\t\t\t\t\tfinalKey = pair.key();\n\t\t\t\t\tcount++;\n\t\t\t\t}\n\n\t\t\t}finally {\n\t\t\t\tindexClosed = true;\n\t\t\t\tindex.close();\n\t\t\t}\n\t\t}",
"public void refresh() {\n getIndexOperations().refresh();\n }",
"public void clear() throws IOException {\n\t\tindexWriter.deleteAll();\n\t\tforceCommit();\n\t}",
"public long index() {\n return manager.compactIndex();\n }",
"public void close()\n throws DataOrderingException;",
"@ManagedOperation(description = \"Starts rebuilding the index\", displayName = \"Rebuild index\")\n void start();",
"public void forceUpdateSearchIndexes() throws InterruptedException {\n\t getFullTextEntityManager().createIndexer().startAndWait();\n\t}",
"public void forceFlush() throws IOException {\n flushCurrentIndexBlock();\n }",
"@Override\n public void close() throws IOException\n {\n try {\n mergingIterator.close();\n }\n finally {\n cleanup.run();\n }\n }",
"public void createIndex() throws IOException {\n\t\tindexWriter.commit();\n\t\ttaxoWriter.commit();\n\n\t\t// categories\n\t\tfor (Article.Facets f : Article.Facets.values()) {\n\t\t\ttaxoWriter.addCategory(new CategoryPath(f.toString()));\n\t\t}\n\t\ttaxoWriter.commit();\n\n\t\tfinal Iterable<Article> articles = articleRepository.findAll();\n\t\tint c = 0;\n\t\tfor (Article article : articles) {\n\t\t\taddArticle(indexWriter, taxoWriter, article);\n\t\t\tc++;\n\t\t}\n\t\t// commit\n\t\ttaxoWriter.commit();\n\t\tindexWriter.commit();\n\n\t\ttaxoWriter.close();\n\t\tindexWriter.close();\n\n\t\ttaxoDirectory.close();\n\t\tindexDirectory.close();\n\t\tLOGGER.debug(\"{} articles indexed\", c);\n\t}",
"public interface IndexBuilder {\n\n /**\n * Rebuilds the index only when the existing index is not populated.\n */\n void rebuildIfNecessary();\n\n}",
"private synchronized void saveInternal() {\n if (relatedDocumentsCounter == 0) {\r\n return;\r\n }\r\n\r\n final TrigramIndexJsonModel model = new TrigramIndexJsonModel( relatedDocuments, indexGeneration, trigram );\r\n final TrigramDocumentCountJsonModel count = new TrigramDocumentCountJsonModel( trigram, globalRelatedDocumentsCounter );\r\n\r\n indexGeneration++;\r\n relatedDocuments = new TreeSet<>();\r\n relatedDocumentsCounter = 0;\r\n\r\n // put that save action and all unnecessary path calculations into a thread pool, \r\n // no need that other word can't be indexed, because of someone's save action... \r\n\r\n Runnable runnable = new Runnable() {\r\n @Override\r\n public void run() {\r\n Path trigramsPath = TrigramSubPathCalculator.getPathForTrigram( trigramsBasePath, trigram,\r\n \".\" + model.getIndexGeneration() + TRIGRAM_REFERENCE_SUFFIX );\r\n createTargetDirectoryIfNotExist( trigramsPath.getParent() );\r\n\r\n // write content of one part of the index\r\n try (BufferedWriter writer = Files.newBufferedWriter( trigramsPath, StandardCharsets.UTF_8 )) {\r\n Gson gson = new Gson();\r\n writer.write( gson.toJson( model ) );\r\n }\r\n catch (IOException e) {\r\n System.out.println( String.format( \"saving file: '%s' caused this error...\", trigramsPath ) );\r\n e.printStackTrace();\r\n }\r\n\r\n // write+overwrite the global documents counter as well\r\n Path trigramCountPath = TrigramSubPathCalculator.getPathForTrigram( trigramsBasePath, trigram, TRIGRAM_COUNT_SUFFIX );\r\n\r\n try (BufferedWriter writer = Files.newBufferedWriter( trigramCountPath, StandardCharsets.UTF_8 )) {\r\n Gson gson = new Gson();\r\n writer.write( gson.toJson( count ) );\r\n }\r\n catch (IOException e) {\r\n System.out.println( String.format( \"saving file: '%s' caused this error...\", trigramCountPath ) );\r\n e.printStackTrace();\r\n }\r\n\r\n }\r\n };\r\n\r\n // TODO: put into task thread-pool (deque) for really saving indexing time.\r\n runnable.run();\r\n }",
"void clearAllIndexes();",
"public void WriteIndex() throws Exception {\n CorpusReader corpus = new CorpusReader();\n // initiate the output object\n IndexWriter output = new IndexWriter();\n\n // Map to hold doc_id and doc content;\n Map<String, String> doc;\n\n // index the corpus, load the doc one by one\n while ((doc = corpus.NextDoc()) != null){\n // get the doc_id and content of the current doc.\n String doc_id = doc.get(\"DOC_ID\");\n String content = doc.get(\"CONTENT\");\n\n // index the doc\n output.IndexADoc(doc_id, content);\n }\n output.close_index_writer();\n }",
"public abstract void updateIndex();",
"public void clear() {\n index.clear();\n }",
"public void close() throws IOException {\n // nothing to do with cached bytes\n }",
"@Override\n public void close() {\n backingIterator.close();\n outputBuffer.close();\n isClosed = true;\n }",
"LuceneMemoryIndex createLuceneMemoryIndex();",
"public void Close() throws IOException {\n\n\t\ttermFile = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(Path.ResultHM1+type+Path.TermDir), \"utf-8\"));\n\t\t// Write to term file\n\t\tStringBuilder sb = new StringBuilder();\n\t\tfor(String term: term2termid.keySet()){\n\t\t\tsb.append(term + \" \" + term2termid.get(term) + \"\\n\");\n\t\t}\n\t\ttermFile.write(sb.toString());\n\t\ttermFile.close();\n\t\tterm2termid.clear();\n\n\t\t// Write to docVector\n\t\tWriteDocFile();\n\t\t// Write to posting file\n\t\tWritePostingFile();\n\n\t}",
"IndexData finLastQueuedData();",
"public void indexCreate()\n {\n try{\n Directory dir = FSDirectory.open(Paths.get(\"indice/\"));\n Analyzer analyzer = new StandardAnalyzer();\n IndexWriterConfig iwc = new IndexWriterConfig(analyzer);\n iwc.setOpenMode(OpenMode.CREATE);\n IndexWriter writer = new IndexWriter(dir,iwc);\n MongoConnection mongo = MongoConnection.getMongo();\n mongo.OpenMongoClient();\n DBCursor cursor = mongo.getTweets();\n Document doc = null;\n\n while (cursor.hasNext()) {\n DBObject cur = cursor.next();\n if (cur.get(\"retweet\").toString().equals(\"false\")) {\n doc = new Document();\n doc.add(new StringField(\"id\", cur.get(\"_id\").toString(), Field.Store.YES));\n doc.add(new TextField(\"text\", cur.get(\"text\").toString(), Field.Store.YES));\n doc.add(new StringField(\"analysis\", cur.get(\"analysis\").toString(), Field.Store.YES));\n //doc.add(new StringField(\"finalCountry\",cur.get(\"finalCountry\").toString(),Field.Store.YES));\n doc.add(new StringField(\"userScreenName\", cur.get(\"userScreenName\").toString(), Field.Store.YES));\n doc.add(new StringField(\"userFollowersCount\", cur.get(\"userFollowersCount\").toString(), Field.Store.YES));\n doc.add(new StringField(\"favoriteCount\", cur.get(\"favoriteCount\").toString(), Field.Store.YES));\n\n if (writer.getConfig().getOpenMode() == OpenMode.CREATE) {\n System.out.println(\"Indexando el tweet: \" + doc.get(\"text\") + \"\\n\");\n writer.addDocument(doc);\n System.out.println(doc);\n } else {\n System.out.println(\"Actualizando el tweet: \" + doc.get(\"text\") + \"\\n\");\n writer.updateDocument(new Term(\"text\" + cur.get(\"text\")), doc);\n System.out.println(doc);\n }\n }\n }\n cursor.close();\n writer.close();\n }\n catch(IOException ioe){\n System.out.println(\" Error en \"+ ioe.getClass() + \"\\n mensaje: \" + ioe.getMessage());\n }\n }",
"private void blockCompressAndIndex(String in, String bgzfOut, boolean deleteOnExit) throws IOException {\n\t\t\n\t\t// System.err.print(\"Compressing: \" + in + \" to file: \" + bgzfOut + \"... \");\n\t\t\n\t\tFile inFile= new File(in);\n\t\tFile outFile= new File(bgzfOut);\n\t\t\n\t\tLineIterator lin= IOUtils.openURIForLineIterator(inFile.getAbsolutePath());\n\n\t\tBlockCompressedOutputStream writer = new BlockCompressedOutputStream(outFile);\n\t\tlong filePosition= writer.getFilePointer();\n\t\t\n\t\tTabixIndexCreator indexCreator=new TabixIndexCreator(TabixFormat.BED);\n\t\tBedLineCodec bedCodec= new BedLineCodec();\n\t\twhile(lin.hasNext()){\n\t\t\tString line = lin.next();\n\t\t\tBedLine bed = bedCodec.decode(line);\n\t\t\tif(bed==null) continue;\n\t\t\twriter.write(line.getBytes());\n\t\t\twriter.write('\\n');\n\t\t\tindexCreator.addFeature(bed, filePosition);\n\t\t\tfilePosition = writer.getFilePointer();\n\t\t}\n\t\twriter.flush();\n\t\t\n\t\t// System.err.print(\"Indexing... \");\n\t\t\n\t\tFile tbi= new File(bgzfOut + TabixUtils.STANDARD_INDEX_EXTENSION);\n\t\tif(tbi.exists() && tbi.isFile()){\n\t\t\twriter.close();\n\t\t\tthrow new RuntimeException(\"Index file exists: \" + tbi);\n\t\t}\n\t\tIndex index = indexCreator.finalizeIndex(writer.getFilePointer());\n\t\tindex.writeBasedOnFeatureFile(outFile);\n\t\twriter.close();\n\n\t\t// System.err.println(\"Done\");\n\t\t\n\t\tif(deleteOnExit){\n\t\t\toutFile.deleteOnExit();\n\t\t\tFile idx= new File(outFile.getAbsolutePath() + TabixUtils.STANDARD_INDEX_EXTENSION);\n\t\t\tidx.deleteOnExit();\n\t\t}\n\t}",
"@Scheduled(fixedRate = 5000)\n public void refreshAllIndex() {\n\n HashMap<String, String> dictlist = new HashMap<>();\n\n //get the file list\n try {\n dictlist = FileUtil.subFolderList(fieryConfig.getIndexpath());\n } catch (Exception e) {\n e.printStackTrace();\n }\n\n //load all index if not contain on folder\n for (Map.Entry<String, String> e : dictlist.entrySet()) {\n String foldername = e.getKey();\n String folderpath = e.getValue();\n if (!readerList.containsKey(foldername)) {\n log.info(\"start load index foldername:\" + foldername + \" abspath:\" + folderpath);\n //open index\n boolean ret = this.openIndex(foldername, folderpath);\n\n //warning this may cause bug\n //loaded fail? clean it\n if (!ret) {\n FileUtil.deleteDir(folderpath);\n }\n }\n }\n\n\n /////////////////////\n // recycle expire index\n /////////////////////\n for (Map.Entry<String, DirectoryReader> e : readerList.entrySet()) {\n String dbname = e.getKey();\n\n try {\n Long dbtime = Long.parseLong(dbname);\n\n if (dbtime < DateTimeHepler.getBeforDay(fieryConfig.getKeepdataday())) {\n //closed all\n if (analyzerList.containsKey(dbname)) {\n analyzerList.get(dbname).close();\n analyzerList.remove(dbname);\n }\n if (directorList.containsKey(dbname)) {\n directorList.get(dbname).close();\n directorList.remove(dbname);\n }\n if (readerList.containsKey(dbname)) {\n readerList.get(dbname).close();\n readerList.remove(dbname);\n }\n\n //remove the folder\n FileUtil.deleteDir(fieryConfig.getIndexpath() + \"/\" + dbname);\n }\n } catch (Exception ex) {\n ex.printStackTrace();\n }\n }\n\n\n /////////////////////\n // refresh already loaded index\n /////////////////////\n for (Map.Entry<String, DirectoryReader> e : readerList.entrySet()) {\n\n String dbname = e.getKey();\n DirectoryReader diskReader = e.getValue();\n\n try {\n Date start = new Date();\n\n DirectoryReader tmp = DirectoryReader.openIfChanged(diskReader);\n if (tmp != null) {\n diskReader.close();\n diskReader = tmp;\n readerList.put(dbname, diskReader);\n Date end = new Date();\n log.info(\"Reload Index:\" + dbname + \" cost:\" + (end.getTime() - start.getTime()) + \" totalcount:\" + diskReader.numDocs());\n }\n\n } catch (Exception exx) {\n exx.printStackTrace();\n log.error(exx.getMessage());\n }\n }\n /////////////////////\n //refresh the all in one searcher\n /////////////////////\n\n this.reloadSearch();\n\n }",
"public synchronized int resize(int newBytesPerId, int newBytesPerType, int newBytesPerPath)\n throws IOException {\n if (this.bytesPerId > newBytesPerId && this.entries > 0)\n throw new IllegalStateException(\"Cannot reduce the number of bytes per id when there are entries in the index\");\n if (this.bytesPerType > newBytesPerType && this.entries > 0)\n throw new IllegalStateException(\"Cannot reduce the number of bytes per type when there are entries in the index\");\n if (this.bytesPerPath > newBytesPerPath && this.entries > 0)\n throw new IllegalStateException(\"Cannot reduce the number of bytes per path when there are entries in the index\");\n if (this.isReadOnly)\n throw new IllegalStateException(\"This index is readonly\");\n \n int newBytesPerSlot = newBytesPerId + newBytesPerType + newBytesPerPath;\n \n logger.info(\"Resizing uri index to {} ({}) slots and {} ({}) bytes per entry\", new Object[] { slots, this.slots, newBytesPerSlot, this.bytesPerSlot });\n \n String fileName = FilenameUtils.getBaseName(idxFile.getName());\n String fileExtension = FilenameUtils.getExtension(idxFile.getName());\n String idxFilenameNew = fileName + \"_resized.\" + fileExtension;\n File idxNewFile = new File(idxFile.getParentFile(), idxFilenameNew);\n long time = System.currentTimeMillis();\n \n logger.debug(\"Creating resized index at \" + idxNewFile);\n \n // Create the new index\n RandomAccessFile idxNew = null;\n try {\n idxNew = new RandomAccessFile(idxNewFile, \"rwd\");\n } catch (FileNotFoundException e) {\n throw new IllegalArgumentException(\"Index file \" + idxNewFile + \" cannot be created: \" + e.getMessage(), e);\n }\n \n // Write header\n idxNew.seek(IDX_START_OF_HEADER);\n idxNew.writeInt(indexVersion);\n idxNew.writeInt(newBytesPerId);\n idxNew.writeInt(newBytesPerType);\n idxNew.writeInt(newBytesPerPath);\n idxNew.writeLong(slots);\n idxNew.writeLong(entries);\n \n // Position to read the whole content\n idx.seek(IDX_START_OF_CONTENT);\n \n // Write entries\n for (int i = 0; i < slots; i++) {\n byte[] bytes = new byte[newBytesPerSlot];\n if (i < this.slots) {\n idx.read(bytes, 0, this.bytesPerSlot);\n idxNew.write(bytes);\n } else {\n // Write an empty line\n idxNew.write(bytes);\n }\n }\n \n logger.debug(\"Removing old index at \" + idxFile);\n \n // Close and delete the old index\n idx.close();\n if (!idxFile.delete())\n throw new IOException(\"Unable to delete old index file \" + idxFile);\n \n // Close the new index, and move it into the old index' place\n logger.debug(\"Moving resized index into regular position at \" + idxFile);\n idxNew.close();\n if (!idxNewFile.renameTo(idxFile))\n throw new IOException(\"Unable to move new index file to \" + idxFile);\n \n try {\n idx = new RandomAccessFile(idxFile, \"rwd\");\n } catch (FileNotFoundException e) {\n throw new IllegalArgumentException(\"Index file \" + idxNewFile + \" cannot be created: \" + e.getMessage(), e);\n }\n \n this.bytesPerSlot = newBytesPerSlot;\n this.bytesPerId = newBytesPerId;\n this.bytesPerType = newBytesPerType;\n this.bytesPerPath = newBytesPerPath;\n \n time = System.currentTimeMillis() - time;\n logger.info(\"Uri index resized in {}\", ConfigurationUtils.toHumanReadableDuration(time));\n return newBytesPerSlot;\n }",
"@Override\n public void optimize() throws IOException, SolrServerException {\n getSolrClient().optimize(); //TODO: use the conncurrentupdatesolrserver instead?\n }",
"public void close() {\n\t\t}",
"public synchronized void close() {}",
"public void onIndexReset();",
"public void testCreIdx(){\r\n\t \r\n\t String dataDir = \"C:\\\\study\\\\Lucene\\\\Data\";\r\n\t String idxDir = \"C:\\\\study\\\\Lucene\\\\Index\";\r\n\t \r\n\t LuceneUtils.delAll(idxDir);\r\n\t \r\n\t CreateIndex ci = new CreateIndex();\r\n\t \r\n\t ci.Indexer(new File(idxDir), new File(dataDir));\r\n\t \r\n\t\t\r\n\t}",
"protected void disposeInternal()\r\n {\r\n if (!isAlive())\r\n {\r\n log.error(\"{0}: Not alive and dispose was called, filename: {1}\",\r\n logCacheName, fileName);\r\n return;\r\n }\r\n\r\n // Prevents any interaction with the cache while we're shutting down.\r\n setAlive(false);\r\n\r\n final Thread optimizationThread = currentOptimizationThread;\r\n if (isRealTimeOptimizationEnabled && optimizationThread != null)\r\n {\r\n // Join with the current optimization thread.\r\n log.debug(\"{0}: In dispose, optimization already in progress; waiting for completion.\",\r\n logCacheName);\r\n\r\n try\r\n {\r\n optimizationThread.join();\r\n }\r\n catch (final InterruptedException e)\r\n {\r\n log.error(\"{0}: Unable to join current optimization thread.\",\r\n logCacheName, e);\r\n }\r\n }\r\n else if (isShutdownOptimizationEnabled && this.getBytesFree() > 0)\r\n {\r\n optimizeFile();\r\n }\r\n\r\n saveKeys();\r\n\r\n try\r\n {\r\n log.debug(\"{0}: Closing files, base filename: {1}\", logCacheName,\r\n fileName);\r\n dataFile.close();\r\n dataFile = null;\r\n keyFile.close();\r\n keyFile = null;\r\n }\r\n catch (final IOException e)\r\n {\r\n log.error(\"{0}: Failure closing files in dispose, filename: {1}\",\r\n logCacheName, fileName, e);\r\n }\r\n\r\n log.info(\"{0}: Shutdown complete.\", logCacheName);\r\n }",
"private void saveindex() throws IOException {\n File dense = new File(DenseLayerPath + \"DenseLayer\" + \".class\");\n if (!dense.exists())\n dense.createNewFile();\n ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream(dense));\n oos.writeObject(this);\n oos.close();\n }",
"@Timed\n @Async\n Future<Integer> reindexSearchDatabase();",
"public static void bgfx_destroy_index_buffer(@NativeType(\"bgfx_index_buffer_handle_t\") short _handle) {\n long __functionAddress = Functions.destroy_index_buffer;\n invokeCV(_handle, __functionAddress);\n }",
"void commit() throws IndexTransactionException;",
"public void close() {\n\t\t\r\n\t}",
"public void run() {\n System.out.println(\"Running Indexing\");\n Indexer.index();\n }",
"public void close()\n\t\t{\n\t\t}",
"public void ReadIndex(int K) throws IOException {\n IndexReader indexReader = new IndexReader();\n\n // get doc frequency, termFrequency in all docs\n// int df = indexReader.getDocFreq(token);\n// long collectionTf = indexReader.getCollectionFrequency(token);\n//// System.out.println(\" The token \\\"\" + token + \"\\\" appeared in \" + df + \" documents and \" + collectionTf\n//// + \" times in total\");\n// if (df > 0) {\n// int[][] posting = indexReader.getPostingList(token);\n// for (int i = 0; i < posting.length; i++) {\n// int doc_id = posting[i][0];\n//// int term_freq = posting[i][1];\n// String doc_no = indexReader.getDocNo(doc_id);\n//// System.out.println(\"doc_no: \" + doc_id);\n//\n//// System.out.printf(\"%10s %6d %6d\\n\", doc_no, doc_id, term_freq);\n//// System.out.printf(\"%10s 10%6d %6d\\n\", doc_no, doc_id, indexReader.getTF(token, doc_id));\n// System.out.println(\"tf_idf: \" + indexReader.getTF_IDF_weight(token, doc_id));\n//\n// }\n// }\n\n\n String doc_no = indexReader.getDocNo(FileConst.query_doc_id);\n // retreived top K relevant doc ids\n System.out.println(\"=== Top 20 Most Relevant Documents and its Cosine Similarity Score ===\");\n indexReader.retrieveRank(query_tokens, Integer.parseInt(doc_no), K);\n\n indexReader.close();\n }",
"public void close() {\n\n\t}",
"public void close() {\n\n\t}",
"public void close() {\r\n\t}",
"public void addIndex(){\n\t\tdbCol=mdb.getCollection(\"genericCollection\");\n\t\tstart=Calendar.getInstance().getTimeInMillis();\n\t\tdbCol.ensureIndex(new BasicDBObject(\"RandomGeo\", \"2d\"));\n\t\tstop = Calendar.getInstance().getTimeInMillis() - start;\n\t\tSystem.out.println(\"Mongo Index Timer \"+Long.toString(stop));\n\t}",
"@Override\n public void close() throws IOException {\n isClosed = true;\n deltasAccess.close();\n }",
"public void onIndexUpdate();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public void close();",
"public static void bgfx_destroy_dynamic_index_buffer(@NativeType(\"bgfx_dynamic_index_buffer_handle_t\") short _handle) {\n long __functionAddress = Functions.destroy_dynamic_index_buffer;\n invokeCV(_handle, __functionAddress);\n }"
] | [
"0.7603",
"0.75056356",
"0.73376375",
"0.7309579",
"0.7051186",
"0.6885101",
"0.68546885",
"0.6846058",
"0.6798949",
"0.6700758",
"0.64933115",
"0.6298487",
"0.6191159",
"0.6191006",
"0.6160146",
"0.6160146",
"0.6126419",
"0.60910314",
"0.6082501",
"0.5997777",
"0.593998",
"0.59387004",
"0.5936649",
"0.5887098",
"0.5881483",
"0.5867946",
"0.58484846",
"0.58471084",
"0.5803422",
"0.57955116",
"0.57679445",
"0.57322514",
"0.5716772",
"0.5715642",
"0.5699682",
"0.569801",
"0.5684089",
"0.56497884",
"0.5629041",
"0.5599477",
"0.5587543",
"0.5587298",
"0.55843157",
"0.5572481",
"0.55630946",
"0.55531776",
"0.5536244",
"0.5515526",
"0.5508213",
"0.5475723",
"0.5445219",
"0.5424078",
"0.5421376",
"0.5415972",
"0.54023606",
"0.5396868",
"0.53950703",
"0.5377464",
"0.5371223",
"0.5358855",
"0.53448933",
"0.53405565",
"0.533651",
"0.53352165",
"0.5323032",
"0.53217083",
"0.53203374",
"0.53084457",
"0.5304017",
"0.5302998",
"0.5290995",
"0.5263559",
"0.5248062",
"0.52313733",
"0.52295023",
"0.52294666",
"0.52195317",
"0.5216039",
"0.520727",
"0.520727",
"0.52054036",
"0.520417",
"0.52001816",
"0.5197272",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194676",
"0.5194469"
] | 0.8227059 | 0 |
Search the query in the index. | public List<edu.columbia.cs.ref.model.TokenizedDocument> search(Query query, int n) {
TopDocs result = null;
try {
result = IndexSearcher.search(query, n);
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
List<TokenizedDocument> searchResults = new ArrayList<TokenizedDocument>();
ScoreDoc[] docs = result.scoreDocs;
for (int i = 0; i < docs.length; i++) {
Document document;
try {
document = IndexSearcher.doc(docs[i].doc);
searchResults.add(getDocumentTable().get(createKey(document.get(PATH), document.get(FILE_NAME))));
} catch (CorruptIndexException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
return searchResults;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@ActionTrigger(action=\"KEY-ENTQRY\", function=KeyFunction.SEARCH)\n\t\tpublic void spriden_Search()\n\t\t{\n\t\t\t\n\t\t\t\texecuteAction(\"QUERY\");\n\t\t\t\tgetTask().getGoqrpls().gCheckFailure();\n\t\t\t}",
"public void search() {\r\n \t\r\n }",
"public void search() {\n try {\n for(int i = 0; i < this.queries.size(); i++){\n search(i);\n // in case of error stop\n if(!this.searchOK(i)){\n System.out.println(\"\\t\" + new Date().toString() + \" \" + db + \" Search for rest queries cancelled, because failed for query \" + i + \" : \" + this.queries.get(i));\n break;\n }\n }\n } catch (UnsupportedEncodingException ex) {\n Logger.getLogger(EntrezSearcher.class.getName()).log(Level.SEVERE, null, ex);\n }\n }",
"private void queryIndex() {\n if (predicate == TruePredicate.INSTANCE) {\n return;\n }\n\n // get indexes\n MapService mapService = nodeEngine.getService(SERVICE_NAME);\n MapServiceContext mapServiceContext = mapService.getMapServiceContext();\n Indexes indexes = mapServiceContext.getMapContainer(name).getIndexes();\n // optimize predicate\n QueryOptimizer queryOptimizer = mapServiceContext.getQueryOptimizer();\n predicate = queryOptimizer.optimize(predicate, indexes);\n\n Set<QueryableEntry> querySet = indexes.query(predicate);\n if (querySet == null) {\n return;\n }\n\n List<Data> keys = null;\n for (QueryableEntry e : querySet) {\n if (keys == null) {\n keys = new ArrayList<Data>(querySet.size());\n }\n keys.add(e.getKeyData());\n }\n\n hasIndex = true;\n keySet = keys == null ? Collections.<Data>emptySet() : InflatableSet.newBuilder(keys).build();\n }",
"public void search() {\n }",
"abstract public void search();",
"abstract public boolean performSearch();",
"List<SearchResult> search(SearchQuery searchQuery);",
"public void search() {\n String q = this.query.getText();\n String cat = this.category.getValue();\n if(cat.equals(\"Book\")) {\n searchBook(q);\n } else {\n searchCharacter(q);\n }\n }",
"public void doSearch(String query)\n \t{\n \t\tlistener.onQueryTextSubmit(query);\n \t}",
"public void searchTest() {\n\t\ttry {\n\t\t\tString keyword = \"操作道具\";\n\t\t\t// 使用IKQueryParser查询分析器构造Query对象\n\t\t\tQuery query = IKQueryParser.parse(LogsEntry.INDEX_FILED_CONTENT, keyword);\n\n\t\t\t// 搜索相似度最高的5条记录\n\t\t\tint querySize = 5;\n\t\t\tTopDocs topDocs = isearcher.search(query, null, querySize, sort);\n\t\t\tlogger.info(\"命中:{}\", topDocs.totalHits);\n\t\t\t// 输出结果\n\t\t\tScoreDoc[] scoreDocs = topDocs.scoreDocs;\n\t\t\tfor (int i = 0; i < scoreDocs.length; i++) {\n\t\t\t\tDocument targetDoc = isearcher.doc(scoreDocs[i].doc);\n\t\t\t\tlogger.info(\"内容:{}\", targetDoc.toString());\n\t\t\t}\n\t\t} catch (IOException e) {\n\t\t\tlogger.error(e.getMessage(), e);\n\t\t}\n\t}",
"@Override\n public Data3DPlastic search() {\n return super.search();\n }",
"@Override\n\tpublic void search() {\n\t}",
"private void search()\n {\n JTextField searchField = (currentSearchView.equals(SEARCH_PANE_VIEW))? searchBar : resultsSearchBar;\n String searchTerm = searchField.getText();\n \n showTransition(2000);\n \n currentPage = 1;\n showResultsView(true);\n paginate(1, getResultsPerPage());\n\n if(searchWeb) showResultsTableView(WEB_RESULTS_PANE);\n else showResultsTableView(IMAGE_RESULTS_PANE);\n\n \n showSearchView(RESULTS_PANE_VIEW);\n resultsSearchBar.setText(searchTerm);\n }",
"@Override\r\n\tpublic void search() {\n\r\n\t}",
"public void searchIndex(Directory index) throws Exception{\n\t\tString searchString = getSearchString();\n\t\t\n\t\tSystem.out.println(\"Searching for '\" + searchString + \"'\");\n\n\t\tIndexReader indexReader = DirectoryReader.open(index);\n\t\tIndexSearcher indexSearcher = new IndexSearcher(indexReader);\n\n\t\tAnalyzer analyzer = new StandardAnalyzer();\n\t\t\n\t\tString query_string = \"title:\" + searchString + \" OR content:\" + searchString + \"OR important:\" + searchString + \"OR h1:\" + searchString +\n\t\t\t\t\"OR h2:\" + searchString + \"OR h3:\" + searchString + \"OR h4:\" + searchString + \"OR h5:\" + searchString + \"OR h6:\" + searchString;\n\t\tQueryParser queryParser = new QueryParser(\"title\", analyzer);\n\t\t\n\t\tTopDocs docs = indexSearcher.search(queryParser.parse(query_string), 10);\n\t\t\n\t\t\n//\t\tString[] fields = {\"content\", \"title\", \"important\", \"h1\", \"h2\", \"h3\", \"h4\", \"h5\", \"h6\"};\n//\t\tBooleanClause.Occur[] flags = \n//\t\t{\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n//\t\t\tBooleanClause.Occur.SHOULD,\n// };\n//\t\t\n//\t\tTopDocs docs = indexSearcher.search(MultiFieldQueryParser.parse(searchString, fields, flags, analyzer), 10);\n\n\t\tScoreDoc[] hits = docs.scoreDocs;\n\n\t System.out.println(\"Found \" + hits.length + \" hits.\");\n\t for(int i=0;i<hits.length;++i) {\n\t \tint docId = hits[i].doc;\n\t Document d = indexSearcher.doc(docId);\n\t System.out.println((i + 1) + \". \" + d.get(\"title\") + \"\\t\" + d.get(\"url\") + \"\\t\" + hits[i].score);\n\t }\n\t}",
"void search();",
"void search();",
"private ScoreDoc[] searchExec (Query query) {\n\n ScoreDoc[] hits = null;\n\n try {\n IndexReader reader = DirectoryReader.open(indexDir);\n IndexSearcher searcher = new IndexSearcher(reader);\n TopDocs docs = searcher.search(query, hitsPerPage, new Sort(SortField.FIELD_SCORE)); //search(query, docs);\n hits = docs.scoreDocs;\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n return hits;\n }",
"@Override\n\tprotected void executeSearch(String term) {\n\t\t\n\t}",
"public void search(Indexer indexer, CityIndexer cityIndexer, Ranker ranker, String query, boolean withSemantic, ArrayList<String> chosenCities, ObservableList<String> citiesByTag, boolean withStemming, String saveInPath, String queryId, String queryDescription) {\n String[] originalQueryTerms = query.split(\" \");\n String originQuery = query;\n docsResults = new HashMap<>();\n parser = new Parse(withStemming, saveInPath, saveInPath);\n HashSet<String> docsOfChosenCities = new HashSet<>();\n query = \"\" + query + queryDescription;\n HashMap<String, Integer> queryTerms = parser.parseQuery(query);\n HashMap<String, ArrayList<Integer>> dictionary = indexer.getDictionary();\n if (!withStemming){\n setDocsInfo(saveInPath + \"\\\\docsInformation.txt\");\n }\n else{\n setDocsInfo(saveInPath + \"\\\\docsInformation_stemming.txt\");\n }\n\n\n //add semantic words of each term in query to 'queryTerms'\n if(withSemantic) {\n HashMap<String,ArrayList<String>> semanticWords = ws.connectToApi(originQuery);\n }\n\n //give an ID to query if it's a regular query (not queries file)\n if(queryId.equals(\"\")){\n queryId = \"\" + Searcher.queryID;\n Searcher.queryID++;\n }\n\n String postingDir;\n if (!withStemming) {\n postingDir = \"\\\\indexResults\\\\postingFiles\";\n } else {\n postingDir = \"\\\\indexResults\\\\postingFiles_Stemming\";\n }\n int pointer = 0;\n\n //find docs that contain the terms in the query in their text\n HashMap<String, Integer> queryTermsIgnoreCase = new HashMap<>();\n for (String term : queryTerms.keySet()) {\n String originTerm = term;\n if (!dictionary.containsKey(term.toUpperCase()) && !dictionary.containsKey(term.toLowerCase())) {\n continue;\n }\n if(dictionary.containsKey(term.toLowerCase())){\n term = term.toLowerCase();\n }\n else {\n term = term.toUpperCase();\n }\n queryTermsIgnoreCase.put(term,queryTerms.get(originTerm));\n pointer = dictionary.get(term).get(2);\n String chunk = (\"\" + term.charAt(0)).toUpperCase();\n\n //get the relevant line from posting file\n BufferedReader br = null;\n try {\n br = new BufferedReader(new FileReader(new File(saveInPath + postingDir + \"\\\\posting_\" + chunk + \".txt\")));\n String line = \"\";\n int i = 1;\n while ((line = (br.readLine())) != null) {\n if (i == pointer) {\n break;\n }\n i++;\n }\n br.close();\n\n //get docs from posting line and add them to the data structure 'docsResults'\n if(line != null) {\n findDocsFromLine(line, term);\n }\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n\n //find docs that contain the chosen cities in their text\n for (String cityTerm : chosenCities) {\n if (!dictionary.containsKey(cityTerm) && !dictionary.containsKey(cityTerm.toLowerCase())) {\n continue;\n }\n if(dictionary.containsKey(cityTerm.toLowerCase())){\n cityTerm = cityTerm.toLowerCase();\n }\n pointer = dictionary.get(cityTerm).get(2);\n // char chunk = indexer.classifyToPosting(term).charAt(0);\n String chunk = (\"\" + cityTerm.charAt(0)).toUpperCase();\n\n //get the relevant line from posting file\n BufferedReader br = null;\n try {\n br = new BufferedReader(new FileReader(new File(saveInPath + postingDir + \"\\\\posting_\" + chunk + \".txt\")));\n String line = \"\";\n int i = 1;\n while ((line = (br.readLine())) != null) {\n if (i == pointer) {\n break;\n }\n i++;\n }\n br.close();\n\n //get docs from posting line and add them to the data structure 'docsOfChosenCities'\n String docs = line.substring(0, line.indexOf(\"[\") - 1); //get 'docsListStr'\n String[] docsArr = docs.split(\";\");\n for (String docInfo : docsArr) {\n String doc = docInfo.substring(0, docInfo.indexOf(\": \"));\n while(doc.charAt(0) == ' '){\n doc = doc.substring(1);\n }\n docsOfChosenCities.add(doc);\n }\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n\n //find docs that contain the chosen cities in their city tag\n if(!chosenCities.isEmpty()){\n for (String cityDicRec: chosenCities) {\n //get pointer to posting from cityDictionary\n try {\n pointer = cityIndexer.getCitiesDictionary().get(cityDicRec);\n } catch (NumberFormatException e) {\n e.printStackTrace();\n }\n //get the relevant line from posting file\n BufferedReader br = null;\n try {\n br = new BufferedReader(new FileReader(new File(saveInPath + \"\\\\cityIndexResults\" + \"\\\\posting_city\" + \".txt\")));\n String line = \"\";\n int i = 1;\n while ((line = (br.readLine())) != null) {\n if (i == pointer) {\n break;\n }\n i++;\n }\n br.close();\n\n //get docs from posting line and add them to the data structure 'docsOfChosenCities'\n String docs = line.substring(line.indexOf(\"[\") + 1, line.indexOf(\"]\")); //get 'docsListStr'\n String[] docsArr = docs.split(\"; \");\n for (String doc : docsArr) {\n docsOfChosenCities.add(doc);\n }\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n\n\n ranker.rank(docsResults, docsOfChosenCities, queryTermsIgnoreCase, dictionary, docsInfo,entities, queryId);\n }",
"@Override\r\n\t\t\tpublic List<ScoredDocument> search(Query query) {\n\t\t\t\treturn null;\r\n\t\t\t}",
"@In String search();",
"SearchResponse search(SearchRequest searchRequest) throws IOException;",
"public void performSearch() {\n History.newItem(MyWebApp.SEARCH_RESULTS);\n getMessagePanel().clear();\n if (keywordsTextBox.getValue().isEmpty()) {\n getMessagePanel().displayMessage(\"Search term is required.\");\n return;\n }\n mywebapp.getResultsPanel().resetSearchParameters();\n //keyword search does not restrict to spots\n mywebapp.addCurrentLocation();\n if (markFilterCheckbox != null) {\n mywebapp.getResultsPanel().getSearchParameters().setLicensePlate(markFilterCheckbox.getValue());\n }\n if (contestFilterCheckbox != null) {\n mywebapp.getResultsPanel().getSearchParameters().setContests(contestFilterCheckbox.getValue());\n }\n if (geoFilterCheckbox != null) {\n mywebapp.getResultsPanel().getSearchParameters().setGeospatialOff(!geoFilterCheckbox.getValue());\n }\n if (plateFilterCheckbox != null) {\n mywebapp.getResultsPanel().getSearchParameters().setLicensePlate(plateFilterCheckbox.getValue());\n }\n if (spotFilterCheckbox != null) {\n mywebapp.getResultsPanel().getSearchParameters().setSpots(spotFilterCheckbox.getValue());\n }\n String color = getValue(colorsListBox);\n mywebapp.getResultsPanel().getSearchParameters().setColor(color);\n String manufacturer = getValue(manufacturersListBox);\n if (manufacturer != null) {\n Long id = new Long(manufacturer);\n mywebapp.getResultsPanel().getSearchParameters().setManufacturerId(id);\n }\n String vehicleType = getValue(vehicleTypeListBox);\n mywebapp.getResultsPanel().getSearchParameters().setVehicleType(vehicleType);\n// for (TagHolder tagHolder : tagHolders) {\n// mywebapp.getResultsPanel().getSearchParameters().getTags().add(tagHolder);\n// }\n mywebapp.getResultsPanel().getSearchParameters().setKeywords(keywordsTextBox.getValue());\n mywebapp.getMessagePanel().clear();\n mywebapp.getResultsPanel().performSearch();\n mywebapp.getTopMenuPanel().setTitleBar(\"Search\");\n //mywebapp.getResultsPanel().setImageResources(resources.search(), resources.searchMobile());\n }",
"public void performSearch() {\n OASelect<QueryInfo> sel = getQueryInfoSearch().getSelect();\n sel.setSearchHub(getSearchFromHub());\n sel.setFinder(getFinder());\n getHub().select(sel);\n }",
"private void performSearch() {\n String text = txtSearch.getText();\n String haystack = field.getText();\n \n // Is this case sensitive?\n if (!chkMatchCase.isSelected()) {\n text = text.toLowerCase();\n haystack = haystack.toLowerCase();\n }\n \n // Check if it is a new string that the user is searching for.\n if (!text.equals(needle)) {\n needle = text;\n curr_index = 0;\n }\n \n // Grab the list of places where we found it.\n populateFoundList(haystack);\n \n // Nothing was found.\n if (found.isEmpty()) {\n Debug.println(\"FINDING\", \"No occurrences of \" + needle + \" found.\");\n JOptionPane.showMessageDialog(null, \"No occurrences of \" + needle + \" found.\",\n \"Nothing found\", JOptionPane.INFORMATION_MESSAGE);\n \n return;\n }\n \n // Loop back the indexes if we have reached the end.\n if (curr_index == found.size()) {\n curr_index = 0;\n }\n \n // Go through the findings one at a time.\n int indexes[] = found.get(curr_index);\n field.select(indexes[0], indexes[1]);\n curr_index++;\n }",
"private void searchFunction() {\n\t\t\r\n\t}",
"Search getSearch();",
"public SearchResponse search(SearchRequest request) throws SearchServiceException;",
"private void executeSearch() {\n if (!view.getSearchContent().getText().isEmpty()) {\n SearchModuleDataHolder filter = SearchModuleDataHolder.getSearchModuleDataHolder();\n //set search content text for full text search\n filter.setSearchText(view.getSearchContent().getText());\n forwardToCurrentView(filter);\n } else {\n eventBus.showPopupNoSearchCriteria();\n }\n }",
"public void onSearchSubmit(String queryTerm);",
"private void search(String querySearch) {\n searchResult = new ArrayList<>();\n for (MonitoringModel item : searchList) {\n if (item.getPROG_ID().toLowerCase().contains(querySearch) || item.getPROG_ID().contains(querySearch) ||\n item.getKEPUTUSAN().toLowerCase().contains(querySearch) || item.getKEPUTUSAN().contains(querySearch) ||\n Common.formatTgl(item.getTGL_TARGET()).toLowerCase().contains(querySearch) || Common.formatTgl(item.getTGL_TARGET()).contains(querySearch) ||\n Common.formatStatusMonitoringToString(item.getLAST_STATUS()).toLowerCase().contains(querySearch) || Common.formatStatusMonitoringToString(item.getLAST_STATUS()).contains(querySearch)) {\n searchResult.add(item);\n }\n }\n if (searchResult.isEmpty())\n tvEmptySearch.setText(\"No results found for '\" + querySearch + \"'\");\n else\n tvEmptySearch.setText(\"\");\n\n searchAdapter = new ListAdapter(getContext(), searchResult);\n rvList.setAdapter(searchAdapter);\n }",
"SearchResponse query(SearchRequest request, Map<SearchParam, String> params);",
"private void search(){\n solo.waitForView(R.id.search_action_button);\n solo.clickOnView(solo.getView(R.id.search_action_button));\n\n //Click on search bar\n SearchView searchBar = (SearchView) solo.getView(R.id.search_experiment_query);\n solo.clickOnView(searchBar);\n solo.sleep(500);\n\n //Type in a word from the description\n solo.clearEditText(0);\n solo.typeText(0, searchTerm);\n }",
"public abstract S getSearch();",
"public void search() throws SQLException;",
"@Action\r\n public String search() {\n ServiceFunctions.clearCache();\r\n\r\n if (isAdmin()) {\r\n return adminSearch();\r\n }\r\n\r\n return publicSearch();\r\n }",
"@Override\r\n\tpublic <T> SearchResult<T> search(String index, String type, String query, Class<T> clz) throws ElasticSearchException{\r\n\t\tQuery esQuery = getQuery(this.indexName, type, query);\r\n\t\tQueryResponse response = query(esQuery);\r\n\t\t\r\n\t\tSearchResult<T> result = new SearchResult<T>();\t\t\r\n\t\tresult.setHits(response.getHits(clz));\r\n\t\t\r\n\t\tif(response.hasAggregations())\r\n\t\t\tresult.setAggregations(response.getAggregations());\r\n\t\t\r\n\t\treturn result;\r\n\t}",
"@Override\n public List<SearchResult> search(String queryString, int k) {\n // TODO: YOUR CODE HERE\n\n // Tokenize the query and put it into a Set\n HashSet<String> tokenSet = new HashSet<>(Searcher.tokenize(queryString));\n\n /*\n * Section 1: FETCHING termId, termFreq and relevant docId from the Query\n */\n\n // Init a set to store Relevant Document Id\n HashSet<Integer> relevantDocIdSet = new HashSet<>();\n for (String token : tokenSet) { // Iterates thru all query tokens\n int termId;\n try {\n termId = indexer.getTermDict().get(token);\n } catch (NullPointerException e) { // In case current token is not in the termDict\n continue; // Skip this one\n }\n // Get the Posting associate to the termId\n HashSet<Integer> posting = indexer.getPostingLists().get(termId);\n relevantDocIdSet.addAll(posting); // Add them all to the Relevant Document Id set\n }\n\n /*\n * Section 2: Calculate Jaccard Coefficient between the Query and all POTENTIAL DOCUMENTS\n */\n\n // ArrayList for the Final Result\n ArrayList<SearchResult> searchResults = new ArrayList<>();\n for (Document doc : documents) { // Iterates thru all documents\n if (!relevantDocIdSet.contains(doc.getId())) { // If the document is relevant\n searchResults.add(new SearchResult(doc, 0)); // Add the document as a SearchResult with zero score\n } else {\n HashSet<String> termIdSet = new HashSet<>(doc.getTokens()); // Get the token set from the document\n\n // Calculate Jaccard Coefficient of the document\n double jaccardScore = JaccardMathHelper.calculateJaccardSimilarity(tokenSet, termIdSet);\n\n // Add the SearchResult with the computed Jaccard Score\n searchResults.add(new SearchResult(doc, jaccardScore));\n }\n }\n\n return TFIDFSearcher.finalizeSearchResult(searchResults, k);\n }",
"SearchResult<TimelineMeta> search(SearchQuery searchQuery);",
"SearchResponse search(Pageable pageable, QueryBuilder query, AggregationBuilder aggregation);",
"public NsSearchResult<RecT> search() {\n Object searchRecord = toNativeQuery();\n NsSearchResult<RecT> result = clientService.search(searchRecord);\n if (!result.isSuccess()) {\n NetSuiteClientService.checkError(result.getStatus());\n }\n return result;\n }",
"public void executeDisplaySearch(String indexfile, String queryString) {\n\t\tif (queryString.trim().length() < 1) {\n\t\t\tJOptionPane.showMessageDialog(this, \"No text given to seach!\", \"Search issues\", JOptionPane.ERROR_MESSAGE);\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//System.out.println(\"going to open: \" + indexfile);\n\n\t\t\n\t\t\n\t\t//lets see if it exists at all:\n\t\tFile test = new File(indexfile);\n\t\tif (!test.exists()) {\n\t\t\tJOptionPane.showMessageDialog(this,\n\t\t\t\t\t\"No such index file present\\nAre you sure you have created an index file?\", \"Missing Index\",\n\t\t\t\t\tJOptionPane.ERROR_MESSAGE);\n\t\t\treturn;\n\t\t}\n\n\t\tString minDate = new String(\"2020-11-11\");\n\t\tString MaxDate = new String(\"0000-00-00\");\n\t\tBusyWindow bw = new BusyWindow(\"Setup\", \"Adding results\",true);\n\t\ttry {\n\t\t\tSearcher searcher = new IndexSearcher(indexfile);\n\t\t\t//standardanalyser\n\t\t\tQueryParser qp = new QueryParser(\"contents\", analyzer);\n\t\t\tQuery query = qp.parse(queryString);\n\t\t\tSystem.out.println(\"Searching for: \" + query.toString(\"contents\"));\n\t\t\tdatecal.clear();\n\t\t\tresultHits = searcher.search(query);\n\t\t\tSystem.out.println(resultHits.length() + \" total matching documents\");\n\n\t\t\tbw.setMax(resultHits.length());\n\t\t\tbw.setVisible(true);\n\t\t\t// reset the table length\n\n\t\t\tresultTableModel.setRowCount(0);\n\n\t\t\tfor (int i = 0; i < resultHits.length(); i++) {\n\t\t\t\tbw.progress(i);\n\t\t\t\tVector rowvalue = new Vector();\n\t\t\t\tDocument doc = resultHits.doc(i);\n\t\t\t\tfloat score = resultHits.score(i);\n\t\t\t\tString path = doc.get(\"path\");\n\t\t\t\tString curDate = doc.get(\"Date\");\n\t\t\t\tdatecal.addDate(curDate);\n\t\t\t\tif (path != null) {\n\t\t\t\t\trowvalue.add(\"\" + score);\n\n\t\t\t\t\t// we need to get the date and subject from the db\n\t\t\t\t\t// based on the mailref encode in the path with a space\n\t\t\t\t\t// afterwards\n\t\t\t\t\tString mailref = doc.get(\"Mailref\");\n\t\t\t\t\trowvalue.add(curDate);\n\t\t\t\t\tif (compareDatesString(MaxDate, curDate) < 0) {\n\t\t\t\t\t\tMaxDate = curDate;\n\t\t\t\t\t} else if (compareDatesString(minDate, curDate) > 0) {\n\t\t\t\t\t\tminDate = curDate;\n\t\t\t\t\t}\n\n\t\t\t\t\ttry {\n\n\t\t\t\t\t\tString data[][] = DBConnect.getSQLData(\"select subject from email where mailref = '\" + mailref\n\t\t\t\t\t\t\t\t+ \"'\");\n\n\t\t\t\t\t\tif (data.length > 0) {\n\t\t\t\t\t\t\trowvalue.add(data[0][0]);\n\n\t\t\t\t\t\t} else {\n\n\t\t\t\t\t\t\trowvalue.add(\"subject\");\n\t\t\t\t\t\t}\n\n\t\t\t\t\t} catch (SQLException see) {\n\t\t\t\t\t\tsee.printStackTrace();\n\n\t\t\t\t\t\trowvalue.add(\"subject\");\n\t\t\t\t\t}\n\n\t\t\t\t\trowvalue.add(mailref);\n\t\t\t\t\t// System.out.println(i + \". =\"+score+\"= \" +\n\t\t\t\t\t// doc.get(\"contents\").substring(0,20));//path );\n\t\t\t\t} else {\n\t\t\t\t\tString url = doc.get(\"url\");\n\t\t\t\t\tif (url != null) {\n\t\t\t\t\t\tSystem.out.println(i + \". \" + url);\n\t\t\t\t\t\tSystem.out.println(\" - \" + doc.get(\"title\"));\n\t\t\t\t\t} else {\n\t\t\t\t\t\tSystem.out.println(i + \". \" + \"No path nor URL for this document\");\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\trowvalue.add(-1);\n\t\t\t\trowvalue.add(i);\n\t\t\t\tresultTableModel.addRow(rowvalue);\n\t\t\t}\n\n\t\t} catch (ParseException pe) {\n\t\t\tJOptionPane.showMessageDialog(SearchEMT.this, \"Problem with query \" + queryString);\n\t\t\tpe.printStackTrace();\n\t\t} catch (IOException ioe) {\n\t\t\tJOptionPane.showMessageDialog(SearchEMT.this, \"Problem opening \" + indexfile);\n\t\t\tioe.printStackTrace();\n\n\t\t}\n\t\tbw.setVisible(false);\n\t\t// System.out.println(\"Max:\" + MaxDate + \" Min:\"+ minDate);\n\n\t\tm_status.setText(\"Number of results: \" + resultHits.length() + \" From \" + minDate + \" to \" + MaxDate);\n\n\t\tdatecal.setDateRange(minDate, MaxDate);\n\t\tdatecal.paintComponent(datecal.getGraphics());\n\n\t}",
"List<DataTerm> search(String searchTerm);",
"List<Revenue> search(String query);",
"public Search() throws Exception {\n sesion = Controller.getSession();\n fullTextSesion = org.hibernate.search.Search.getFullTextSession(sesion);\n }",
"@Override\n public boolean onQueryTextSubmit(String query) {\n prepareBooks(engine.search(query.toLowerCase(),filter));\n return false;\n }",
"public void doSearch(String searchText){\n }",
"public interface IndexSearch {\n /**\n * Returns the index type.\n * @return type\n */\n IndexType type();\n\n /**\n * Returns the current token.\n * @return token\n */\n byte[] token();\n}",
"@Override\r\n public boolean onQueryTextSubmit(String query) {\n searchAdapter.setSearchResults(DataCache.getInstance().getSearchResults(query));\r\n return false;\r\n }",
"List<ShipmentInfoPODDTO> search(String query);",
"protected SearchSearchResponse doNewSearch(QueryContext queryContext) throws Exception {\n\t\t\n\t\tBooleanQuery query = _queryBuilder.buildSearchQuery(queryContext);\n\t\t\n\t\tBooleanQuery rescoreQuery = \n\t\t\t\t_queryBuilder.buildRescoreQuery(queryContext);\n\t\t\n\t\tList<Aggregation> aggregations = getAggregations(queryContext);\n\n\t\treturn execute(queryContext, query, rescoreQuery, aggregations);\n\t}",
"@Override\n\tpublic boolean isSearching() {\n\t\treturn false;\n\t}",
"@Override\n\tpublic boolean isSearching() {\n\t\treturn false;\n\t}",
"@Test\n\tpublic void testKeywordQuery(){\n\t\t//manager.getResponse(\"american football \"); //match multiple keywords\n//\t\tmanager.getResponse(\"list of Bond 007 movies\");\n//\tmanager.getResponse(\"Disney movies\");\n\t\t//manager.keywordQuery(\"Paul Brown Stadium location\");\n\t\t//manager.keywordQuery(\"0Francesco\");\n System.out.println(\"******* keyword query *******\");\n\t\t//manager.keywordQuery(\"sportspeople in tennis\");\n\t\t//manager.keywordSearch(\"list of movies starring Sean Connery\",ElasticIndex.analyzed,100 );\n//\t\tmanager.keywordSearch(\"movies starring Sean Connery\",ElasticIndex.notStemmed,100 );\n// manager.keywordSearch(\"musical movies tony award\",ElasticIndex.analyzed,100 );\n// manager.keywordSearch(\"movies directed by Woody Allen\",ElasticIndex.analyzed,100 );\n// manager.keywordSearch(\"United states professional sports teams\",ElasticIndex.analyzed,100 );\n// manager.keywordSearch(\"computer games developed by Ubisoft\",ElasticIndex.analyzed,100 );\n// manager.keywordSearch(\"computer games developed by Ubisoft\",ElasticIndex.notStemmed,100 );\n// manager.keywordSearch(\"movies academy award nominations\",ElasticIndex.notStemmed,100 );\n System.out.println(SearchResultUtil.toSummary(manager.keywordSearch(\"movies directed by Woody Allen\",ElasticIndex.notLowercased,20 )));\n //manager.keywordSearch(\"grammy best album in 2012\",ElasticIndex.notAnalyzed,100 );\n //(better than analyzed) manager.keywordSearch(\"grammy best album in 2012\",ElasticIndex.notStemmed,100 );\n System.out.println(\"*****************************\");\n\n\t\t//manager.keywordQuery(\"Disney movies\");\n\t}",
"Page<Tbc_analises_componente> search(String query, Pageable pageable);",
"public void performSearch() throws IOException {\n configuration();\n\n File fileDir = new File(queryFilePath);\n if (fileDir.isDirectory()) {\n File[] files = fileDir.listFiles();\n Arrays.stream(files).forEach(file -> performSearchUsingFileContents(file));\n }\n }",
"List<ResultDTO> search(String query);",
"public SearchResults search(String queryString) {\n\n Timer.Context ctx = m_searchTimer.time();\n\n SearchResults searchResults = new SearchResults();\n\n for (String term : s_tokenSplitter.splitToList(queryString)) {\n\n Term t = Term.parse(term);\n\n Statement searchQuery = select(Constants.Schema.C_TERMS_RESOURCE).from(Constants.Schema.T_TERMS)\n .where(eq(Constants.Schema.C_TERMS_CONTEXT, Context.DEFAULT_CONTEXT.getId()))\n .and( eq(Constants.Schema.C_TERMS_FIELD, t.getField()))\n .and( eq(Constants.Schema.C_TERMS_VALUE, t.getValue()));\n\n // TODO: Use async DB calls; Get attrs and metrics concurrently\n for (Row row : m_session.execute(searchQuery.toString())) { // FIXME: toString()?\n String id = row.getString(Constants.Schema.C_TERMS_RESOURCE);\n Optional<Map<String, String>> attrs = fetchResourceAttributes(Context.DEFAULT_CONTEXT, id);\n Collection<String> metrics = fetchMetricNames(Context.DEFAULT_CONTEXT, id);\n\n searchResults.addResult(new Resource(id, attrs), metrics);\n }\n }\n\n try {\n return searchResults;\n }\n finally {\n ctx.stop();\n }\n }",
"public void search() {\n listTbagendamentos\n = agendamentoLogic.findAllTbagendamentoByDataAndPacienteAndFuncionario(dataSearch, tbcliente, tbfuncionario);\n }",
"SearchResponse search(Pageable pageable, QueryBuilder query, Collection<AggregationBuilder> aggregations);",
"Page<T> search(Pageable pageable, QueryBuilder query);",
"private void executeSearchQuery(JsonObject json, HttpServerResponse response) {\n database.searchQuery(json, handler -> {\n if (handler.succeeded()) {\n LOGGER.info(\"Success: Search Success\");\n handleSuccessResponse(response, ResponseType.Ok.getCode(),\n handler.result().toString());\n } else if (handler.failed()) {\n LOGGER.error(\"Fail: Search Fail\");\n processBackendResponse(response, handler.cause().getMessage());\n }\n });\n }",
"public void search(String query) {\n Log.i(TAG, \"search: \" + query);\n artistInteractor.searchInItunes(query, this);\n }",
"public QueryController(String[] args){\n // Parse Args\n QueryArgs queryArgs = new QueryArgs();\n try {\n queryArgs.parseArgs(args);\n } catch (FileNotFoundException e) {\n //e.printStackTrace();\n System.err.println(\"Invalid Arguments received. Please check your arguments passed to ./search\");\n return;\n }\n\n // Run the Term Normaliser\n TermNormalizer normalizer = new TermNormalizer();\n String[] queryTerms = normalizer.transformedStringToTerms(queryArgs.queryString);\n\n //create the model\n Model model = new Model();\n model.loadCollectionFromMap(queryArgs.mapPath);\n model.loadLexicon(queryArgs.lexiconPath);\n model.loadInvertedList(queryArgs.invlistPath);\n if(queryArgs.stopListEnabled)\n {\n model.loadStopList(queryArgs.stopListPath);\n }\n if(queryArgs.printSummary && queryArgs.collectionPath != \"\")\n {\n model.setPathToCollection(queryArgs.collectionPath);\n }\n\n\n //fetch the top results from the query module\n QueryModule queryModule = new QueryModule();\n queryModule.doQuery(queryTerms, model, queryArgs.bm25Enabled);\n List<QueryResult> topResults = queryModule.getTopResult(queryArgs.maxResults);\n\n\n\n ResultsView resultsView = new ResultsView();\n if(queryArgs.printSummary)\n {\n\n DocSummary docSummary = new DocSummary();\n for(QueryResult result:topResults)\n {\n // retrieve the actualy text from the document collection\n result.setDoc(model.getDocumentCollection().getDocumentByIndex(result.getDoc().getIndex(), true));\n\n //set the summary on the result object by fetching it from the docSummary object\n result.setSummaryNQB(docSummary.getNonQueryBiasedSummary(result.getDoc(), model.getStopListModule()));\n result.setSummaryQB(docSummary.getQueryBiasedSummary(result.getDoc(), model.getStopListModule(), Arrays.asList(queryTerms)));\n }\n resultsView.printResultsWithSummary(topResults,queryArgs.queryLabel);\n }else\n {\n resultsView.printResults(topResults,queryArgs.queryLabel);\n }\n\n }",
"@Override\n public synchronized Long count(String query) {\n long count = 0L;\n String nQuery = normalizeQuery(query);\n Set<String> keys = suggestIndex.getKeys();\n Map index = suggestIndex.getIndex();\n LinkedHashSet<Long> result = new LinkedHashSet<Long>();\n\n logger.debug(\"IN SEARCH: query={}, keys={}\", query, keys);\n\n StringBuilder patternBuilder;\n List<Pattern> patterns = new ArrayList<Pattern>();\n for (String keyPart : nQuery.split(\" \")) {\n patternBuilder = new StringBuilder(\"^(?iu)\");\n patternBuilder.append(ALLOWED_CHARS_REGEXP);\n keyPart = Normalizer.normalize(keyPart, Normalizer.Form.NFD);\n patternBuilder.append(keyPart)\n .append(ALLOWED_CHARS_REGEXP)\n .append('$');\n patterns.add(Pattern.compile(patternBuilder.toString()));\n }\n\n for (String key : keys) {\n for (Pattern pattern : patterns) {\n\n if (pattern.matcher(key).matches()) {\n result.addAll((LinkedHashSet<Long>) index.get(key));\n count += ((LinkedHashSet<Long>) index.get(key)).size();\n }\n }\n }\n return Long.valueOf(result.size());\n }",
"public Result search (SpanQuery query) {\n final Krill krill = new Krill(query);\n krill.getMeta().setSnippets(true);\n return this.search(krill);\n }",
"@Override\n public void search(SearchQuery searchQuery) throws VanilaException {\n\n setKeepQuite(false);\n\n String query = searchQuery.query;\n SearchOptions options = searchQuery.options;\n\n if (isCacheHavingResults(query)) {\n searchComplete(query, mRecentSearchResultsMap.get(query), null);\n }\n else {\n if (mIsBusyInSearch) {\n mMostRecentAwaitingQuery = searchQuery;\n }\n else {\n\n mMostRecentAwaitingQuery = null;\n mIsBusyInSearch = true;\n\n FSRequestDTO request = mFSContext.buildVenueRequest(query, options);\n\n FSVenueSearchGateway gateway = mMobilePlatformFactory.getSyncAdapter()\n .getSyncGateway(FSVenueSearchGateway.CLASS_NAME);\n gateway.fireReadVenueListRequest(request);\n }\n }\n }",
"CampusSearchQuery generateQuery();",
"void searchProbed (Search search);",
"public void actionPerformed(ActionEvent e) {\n displayInfoText(\" \");\n // Turn the search string into a Query\n String queryString = queryWindow.getText().toLowerCase().trim();\n query = new Query(queryString);\n // Take relevance feedback from the user into account (assignment 3)\n // Check which documents the user has marked as relevant.\n if (box != null) {\n boolean[] relevant = new boolean[box.length];\n for (int i = 0; i < box.length; i++) {\n if (box[i] != null)\n relevant[i] = box[i].isSelected();\n }\n query.relevanceFeedback(results, relevant, engine);\n }\n // Search and print results. Access to the index is synchronized since\n // we don't want to search at the same time we're indexing new files\n // (this might corrupt the index).\n long startTime = System.currentTimeMillis();\n synchronized (engine.indexLock) {\n results = engine.searcher.search(query, queryType, rankingType);\n }\n long elapsedTime = System.currentTimeMillis() - startTime;\n // Display the first few results + a button to see all results.\n //\n // We don't want to show all results directly since the displaying itself\n // might take a long time, if there are many results.\n if (results != null) {\n displayResults(MAX_RESULTS, elapsedTime / 1000.0);\n } else {\n displayInfoText(\"Found 0 matching document(s)\");\n\n if (engine.speller != null) {\n startTime = System.currentTimeMillis();\n SpellingOptionsDialog dialog = new SpellingOptionsDialog(50);\n String[] corrections = engine.speller.check(query, 10);\n elapsedTime = System.currentTimeMillis() - startTime;\n System.err.println(\"It took \" + elapsedTime / 1000.0 + \"s to check spelling\");\n if (corrections != null && corrections.length > 0) {\n String choice = dialog.show(corrections, corrections[0]);\n if (choice != null) {\n queryWindow.setText(choice);\n queryWindow.grabFocus();\n\n this.actionPerformed(e);\n }\n }\n }\n }\n }",
"@Override\n @Transactional(readOnly = true)\n public List<PerSubmit> search(String query) {\n log.debug(\"Request to search PerSubmits for query {}\", query);\n return StreamSupport\n .stream(perSubmitSearchRepository.search(queryStringQuery(query)).spliterator(), false)\n .collect(Collectors.toList());\n }",
"public void search(IndexShort < O > index, short range, short k)\n throws Exception {\n // assertEquals(index.aDB.count(), index.bDB.count());\n // assertEquals(index.aDB.count(), index.bDB.count());\n // index.stats();\n index.resetStats();\n // it is time to Search\n int querySize = 1000; // amount of elements to read from the query\n String re = null;\n logger.info(\"Matching begins...\");\n File query = new File(testProperties.getProperty(\"test.query.input\"));\n File dbFolder = new File(testProperties.getProperty(\"test.db.path\"));\n BufferedReader r = new BufferedReader(new FileReader(query));\n List < OBPriorityQueueShort < O >> result = new LinkedList < OBPriorityQueueShort < O >>();\n re = r.readLine();\n int i = 0;\n long realIndex = index.databaseSize();\n\n while (re != null) {\n String line = parseLine(re);\n if (line != null) {\n OBPriorityQueueShort < O > x = new OBPriorityQueueShort < O >(\n k);\n if (i % 100 == 0) {\n logger.info(\"Matching \" + i);\n }\n\n O s = factory.create(line);\n if (factory.shouldProcess(s)) {\n if(i == 279){\n System.out.println(\"hey\");\n }\n index.searchOB(s, range, x);\n result.add(x);\n i++;\n }\n }\n if (i == querySize) {\n logger.warn(\"Finishing test at i : \" + i);\n break;\n }\n re = r.readLine();\n }\n \n logger.info(index.getStats().toString());\n \n int maxQuery = i;\n // logger.info(\"Matching ends... Stats follow:\");\n // index.stats();\n\n // now we compare the results we got with the sequential search\n Iterator < OBPriorityQueueShort < O >> it = result.iterator();\n r.close();\n r = new BufferedReader(new FileReader(query));\n re = r.readLine();\n i = 0;\n while (re != null) {\n String line = parseLine(re);\n if (line != null) {\n if (i % 300 == 0) {\n logger.info(\"Matching \" + i + \" of \" + maxQuery);\n }\n O s = factory.create(line);\n if (factory.shouldProcess(s)) {\n OBPriorityQueueShort < O > x2 = new OBPriorityQueueShort < O >(\n k);\n searchSequential(realIndex, s, x2, index, range);\n OBPriorityQueueShort < O > x1 = it.next();\n //assertEquals(\"Error in query line: \" + i + \" slice: \"\n // + line, x2, x1); \n \n assertEquals(\"Error in query line: \" + i + \" \" + index.debug(s) + \"\\n slice: \"\n + line + \" \" + debug(x2,index ) + \"\\n\" + debug(x1,index), x2, x1);\n\n i++;\n }\n \n }\n if (i == querySize) {\n logger.warn(\"Finishing test at i : \" + i);\n break;\n }\n re = r.readLine();\n }\n r.close();\n logger.info(\"Finished matching validation.\");\n assertFalse(it.hasNext());\n }",
"public IndexedList<Task> search() {\n\t\treturn null;\n\t}",
"public void performSearch() {\n OASelect<CorpToStore> sel = getCorpToStoreSearch().getSelect();\n sel.setSearchHub(getSearchFromHub());\n sel.setFinder(getFinder());\n getHub().select(sel);\n }",
"private static List<SearchData> booleanSearchWord(Query query, Indexer si) {\n Tokenizer tkn = new SimpleTokenizer();\n tkn.tokenize(query.getStr(), \"[a-zA-Z]{3,}\", true, true);\n List<SearchData> searchList = new ArrayList<>();\n LinkedList<Token> wordsList = tkn.getTokens();\n Iterator<Token> wordsIt = wordsList.iterator();\n HashMap<String, LinkedList<Posting>> indexer = si.getIndexer();\n int idx;\n SearchData searched_doc;\n\n while (wordsIt.hasNext()) {\n String word = wordsIt.next().getSequence();\n if (indexer.containsKey(word)) {\n\n LinkedList<Posting> posting = indexer.get(word);\n\n for (Posting pst : posting) {\n\n SearchData sd = new SearchData(query, pst.getDocId());\n\n if (!searchList.contains(sd)) {\n sd.setScore(1);\n searchList.add(sd);\n } else {\n idx = searchList.indexOf(sd);\n searched_doc = searchList.get(idx);\n searched_doc.setScore(searched_doc.getScore() + 1);\n }\n }\n\n }\n\n\n }\n\n Collections.sort(searchList);\n\n return searchList;\n }",
"SearchResult<TimelineMeta> search(SearchParameter searchParameter);",
"@Override\n\tpublic NodeIterator search(String queryString) throws Exception {\n\t\treturn null;\n\t}",
"List<Corretor> search(String query);",
"private void performSearch() {\n try {\n final String searchVal = mSearchField.getText().toString().trim();\n\n if (searchVal.trim().equals(\"\")) {\n showNoStocksFoundDialog();\n }\n else {\n showProgressDialog();\n sendSearchResultIntent(searchVal);\n }\n }\n catch (final Exception e) {\n showSearchErrorDialog();\n logError(e);\n }\n }",
"public SearchRequestBuilder getListSearch(ESQuery query, String index) {\n\n\t\t// Group Aggregation\n\t\tString dimField = query.getDimField();\n\t\tTermsBuilder termsBuilder = AggregationBuilders.terms(dimField).field(dimField);\n\n\t\t// Group Filter\n\t\t/*List<ESFilter> aggFilter = query.getAggFilter();\n\t\tif (null != aggFilter) {\n\t\t\ttermsBuilder.collectMode(mode);\n\t\t}*/\n\t\t\n\t\t// Group Sum Aggregation\n\t\tfor (ConfigColumn column : query.getIdxList()) {\n\t\t\tString field = column.getField();\n\t\t\ttermsBuilder.subAggregation(AggregationBuilders.sum(field).field(field));\n\t\t}\n\n\t\t// Group Order\n\t\tConfigColumn sortField = query.getSortField();\n\t\tif (sortField != null) {\n\t\t\tif (sortField.getDim() == 1) {\n\t\t\t\ttermsBuilder.order(Terms.Order.term(query.isAsc()));\n\t\t\t} else {\n\t\t\t\tString fieldName = sortField.getField();\n\t\t\t\ttermsBuilder.order(Terms.Order.aggregation(fieldName, query.isAsc()));\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Set Pagination\n\t\tPagination page = query.getPage();\n\t\tif (null != page) {\n\t\t\tint from = page.getFrom();\n\t\t\tint size = page.getPageSize();\n\t\t\ttermsBuilder.size(Math.max(max, from + size));\n\t\t} else {\n\t\t\ttermsBuilder.size(max);\n\t\t}\n\t\t\n\t\t// Construct Search Builder\n\t\tSearchRequestBuilder esSearch = getClient().prepareSearch(index).setTypes(type);\n\t\tesSearch.addAggregation(termsBuilder).setQuery(query.getQueryBuilder());\n\n\t\treturn esSearch;\n\t}",
"public interface SearchQuerySet extends QuerySet\n{\n\n // for AbstractSearch\n public static final int STAT_MODELS = 1;\n public static final int STAT_CLUSTERS = 2;\n public static final int STAT_GENOMES = 4;\n public static final int STAT_MODEL_CLUSTERS = 8;\n\n public String getStatsById(Collection data);\n public String getStatsByQuery(String query);\n public String getStatsById(Collection data,int stats);\n public String getStatsByQuery(String query,int stats);\n \n // for BlastSearch\n public String getBlastSearchQuery(Collection dbNames, Collection keys, KeyTypeUser.KeyType keyType);\n \n //for ClusterIDSearch\n public String getClusterIDSearchQuery(Collection input, int limit, int[] DBs, KeyTypeUser.KeyType keyType);\n \n // for ClusterNameSearch\n public String getClusterNameSearchQuery(Collection input, int limit, int[] DBs, KeyTypeUser.KeyType keyType);\n \n // for DescriptionSearch\n public String getDescriptionSearchQuery(Collection input, int limit, int[] DBs, KeyTypeUser.KeyType keyType);\n \n // for GoSearch \n public String getGoSearchQuery(Collection input, int limit, KeyTypeUser.KeyType keyType);\n \n // for GoTextSearch\n public String getGoTextSearchQuery(Collection input, int limit, KeyTypeUser.KeyType keyType);\n \n // for IdSearch\n public String getIdSearchQuery(Collection input, int limit, int[] DBs, KeyTypeUser.KeyType keyType);\n \n // for QueryCompSearch\n public String getQueryCompSearchQuery(String comp_id, String status, KeyTypeUser.KeyType keyType);\n \n // for QuerySearch\n public String getQuerySearchQuery(String queries_id, KeyTypeUser.KeyType keyType); \n \n // for SeqModelSearch\n public String getSeqModelSearchQuery(Collection model_ids, KeyTypeUser.KeyType keyType);\n \n // for UnknowclusterIdSearch\n public String getUnknownClusterIdSearchQuery(int cluster_id, KeyTypeUser.KeyType keyType);\n \n // for ProbeSetSearch\n public String getProbeSetSearchQuery(Collection input, int limit, KeyTypeUser.KeyType keyType);\n \n // for ProbeSetKeySearch\n public String getProbeSetKeySearchQuery(Collection input, int limit, KeyTypeUser.KeyType keyType);\n \n // for QueryTestSearch\n public String getQueryTestSearchQuery(String query_id, String version, String genome_id);\n \n // for QueryStatsSearch\n public String getQueryStatsSearchQuery(List query_ids,List DBs);\n \n // for PskClusterSearch\n public String getPskClusterSearchQuery(int cluster_id,KeyTypeUser.KeyType keyType);\n \n // for ClusterCorrSearch\n public String getClusterCorrSearchQuery(int cluster_id, int psk_id, KeyTypeUser.KeyType keyType);\n \n // for UnknownGenesSearch\n public String getUnknownGenesSearchQuery(Collection sources, KeyTypeUser.KeyType keyType);\n \n}",
"List<Cemetery> search(String query);",
"public void testAdvancedQuery() {\n\t\t//manager.advancedQuery(ElasticIndex.analyzed, \"metropolitan areas\", \"sports clubs\");\n\t\t//manager.advancedQuery(ElasticIndex.analyzed, \"\", \"Award\");\n\n\t//manager.advancedQuery(ElasticIndex.analyzed,\"american actor\", \"list of movies starring Sean Connery\");\n//\tmanager.categorySearch(\"Sportspeople\", \"tennis\",ElasticIndex.analyzed,30);\n\t//manager.advancedQuery(ElasticIndex.analyzed,\"Broadway musicals\", \"Grammy Award\");\n\t//manager.advancedQuery(ElasticIndex.analyzed,\"musical movies\", \"Tony Award\");\n\t//manager.advancedQuery(ElasticIndex.analyzed,\"Top level football leagues\", \"teams\");\n\t//manager.advancedQuery(ElasticIndex.analyzed,\"american movies\", \"directed by Woody Allen\");\n\t//manager.advancedQuery(ElasticIndex.analyzed,\"United states\", \"professional sports teams\");\n\t\t//manager.advancedQuery(\"musical movies\", \"tony award\");\n\t\t//manager.advancedQuery(\"grammy\", \"best album in 2012\"); \n\t\t//manager.advancedQuery(\"american movies\", \"directed by Woody Allen\"); \n\t\t//Canceled manager.advancedQuery(\"tennis\", \"international players\"); \n\t\t// canceled manager.advancedQuery(\"tennis\", \"french open\"); \n\t\t// canceled manager.advancedQuery(\"film movie\", \"1933\"); \n//\t\tmanager.advancedQuery(\"United states\", \"professional sports teams \");\n//\t\t manager.advancedQuery(\"computer games\", \"developed by Ubisoft\");\n//\t\tmanager.advancedQuery(\"movies\", \"academy award nominations\");\n //manager.advancedQuery(\"movies\", \"starring Dustin Hoffman\");\n // manager.advancedQuery(\"movies\", \"best costume design\");\n // manager.advancedQuery(\"concert tours\", \"england\");\n // manager.advancedQuery(\"sport\", \"Francesco\");\n\t\t//System.out.println(\"******* advanced query *******\");\n\t\t//manager.advancedQuery(\"sportspeople\", \"tennis\");\n//\t\tmanager.advancedQuery(ElasticIndex.analyzed, \"Broadway musicals\", \"Grammy Award\");\n //System.out.println(\"*****************************\");\n\n\n\t\t\n\t\t//manager.advancedQuery(\"football\", \"italian championship\");\n\t\t//manager.advancedQuery(\"american basketball\", \"team\");\n\t\t //manager.advancedQuery(\"Goya Award\", \"Winner and nominees from FRA\");\n\t\t//manager.advancedQuery(\"films\", \"american comedy \");\n\t\t//manager.advancedQuery(\"films\", \"american Adventure directed by James P. Hogan\");\n\t\t//manager.advancedQuery(\"NCAA Division\", \"american universities in Arkansas\");\n\t\t//manager.advancedQuery(\"Academy award\", \"winners and nominees in acting in 2011\");\n\t\t//manager.advancedQuery(\"canadian soccer\", \"Alain Rochat position \");\n\n\t}",
"private void search() {\n \t\tString searchString = m_searchEditText.getText().toString();\n \n \t\t// Remove the refresh if it's scheduled\n \t\tm_handler.removeCallbacks(m_refreshRunnable);\n \t\t\n\t\tif ((searchString != null) && (!searchString.equals(\"\"))) {\n \t\t\tLog.d(TAG, \"Searching string: \\\"\" + searchString + \"\\\"\");\n \n \t\t\t// Save the search string\n \t\t\tm_lastSearch = searchString;\n \n \t\t\t// Disable the Go button to show that the search is in progress\n \t\t\tm_goButton.setEnabled(false);\n \n \t\t\t// Remove the keyboard to better show results\n \t\t\t((InputMethodManager) this\n \t\t\t\t\t.getSystemService(Service.INPUT_METHOD_SERVICE))\n \t\t\t\t\t.hideSoftInputFromWindow(m_searchEditText.getWindowToken(),\n \t\t\t\t\t\t\t0);\n \n \t\t\t// Start the search task\n \t\t\tnew HTTPTask().execute(searchString);\n \t\t\t\n \t\t\t// Schedule the refresh\n \t\t\tm_handler.postDelayed(m_refreshRunnable, REFRESH_DELAY);\n \t\t} else {\n \t\t\tLog.d(TAG, \"Ignoring null or empty search string.\");\n \t\t}\n \t}",
"public static void main(String args[]) throws Exception{\n\t\tString path_to_index;\r\n\t\ttry{\r\n\t\t\tpath_to_index = args[0];\r\n\t\t\tSearching_query search = new Searching_query(path_to_index);\r\n\t\t\tString query;\r\n\t\t\tboolean flag = true;\r\n\t\t\twhile(flag==true){\r\n\t\t\t input_query = new Scanner(System.in);\r\n\t\t\t System.out.println(\"ENTER QUERY : \");\r\n\t\t\t query = input_query.nextLine();\r\n\t\t\t System.out.println(\"YOUR QUERY IS: \" + query);\r\n\t\t\t /*calculating the start time*/\r\n\t\t\tdouble start_time_of_query = System.currentTimeMillis();\r\n\t\t\t\tsearch.searching_query(query);\r\n\t\t\t\t/*calculating the end time*/\r\n\t\t\tdouble end_time_of_query = System.currentTimeMillis();\r\n\t\t\tdouble timetaken = end_time_of_query - start_time_of_query;\r\n\t\t\tSystem.out.println(\"SEARCH TIME : \"+ timetaken/1000 + \" sec\");\r\n\t\t\t\r\n\t\t\t System.out.print(\"Want next Query (1 for YES,0 for NO)? : \");\r\n\t\t\t if(!(input_query.nextLine()).equalsIgnoreCase(\"1\")){\r\n\t\t\t\t flag = false;\r\n\t\t\t\t System.out.println();\r\n\t\t\t }\r\n\t\t\t}\t\r\n\t\t\t\r\n\t\t\t}\r\n\t\tcatch(ArrayIndexOutOfBoundsException e){\r\n\t\t\te.printStackTrace();\r\n\t\t\tSystem.out.println(\"EXCEPTION : Enter path of the index folder.\");\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t}",
"private void search(String product) {\n // ..\n }",
"@Override\n\tpublic boolean onSearchRequested()\n\t{\n \tstartSearch(getCurSearch(), true, null, false);\n \treturn true;\n\t}",
"void searchStarted (Search search);",
"public void search(String searchText) {\n\tsearchFrame.setVisible(false);\n\tsearchPApplet.searchText=\"\";\n\tSystem.out.println(\"Searching...\");\n\tsearchedCells.clear();\n\t\n\tif(searchText==null || searchText.length()==0)\t{redraw(); return;}\n\t\n\tfor(Cell c:cells)\n\t\tsearchedCells.addAll(recursiveSearch(c, searchText, 0));\n\tSystem.out.println(\"Found \"+searchedCells.size()+\" occurrences\");\n\tredraw();\n\treturn;\n}",
"private Search() {}",
"public void searchByAccount() {\n\t\t\n\t\tlog.log(Level.INFO, \"Please Enter the account number you want to search: \");\n\t\tint searchAccountNumber = scan.nextInt();\n\t\tbankop.search(searchAccountNumber);\n\n\t}",
"private void searchforResults() {\n\n List<String> queryList = new SavePreferences(this).getStringSetPref();\n if(queryList != null && queryList.size() > 0){\n Log.i(TAG, \"Searching for results \" + queryList.get(0));\n Intent searchIntent = new Intent(Intent.ACTION_WEB_SEARCH);\n searchIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n searchIntent.putExtra(SearchManager.QUERY, queryList.get(0));\n this.startActivity(searchIntent);\n }\n }",
"public static void main(String[] args) throws IOException{\n \n List<List<String>> results;\n String query = \"ADD QUERY OR CATEGORY FOR SEARCH\";\n \n //ADD USER ID WHO SEARCHES\n Long userId = 1;\n PersonalizedSearch searchObj = new PersonalizedSearch();\n \n final CredentialsProvider credsProvider = new BasicCredentialsProvider();\n credsProvider.setCredentials(AuthScope.ANY, new UsernamePasswordCredentials(\"elastic\",\"elastic\"));\n \n \n RestHighLevelClient client = new RestHighLevelClient(\n RestClient.builder(\n new HttpHost(\"localhost\",9200),\n new HttpHost(\"localhost\",9201))\n .setHttpClientConfigCallback(new RestClientBuilder.HttpClientConfigCallback() {\n @Override\n public HttpAsyncClientBuilder customizeHttpClient(HttpAsyncClientBuilder hacb) {\n return hacb.setDefaultCredentialsProvider(credsProvider);\n }\n }));\n \n /**\n * ---------COMMENT OUT ONE OF THE FOLLOWING TO DO A PERSONALIZED SEARCH FOR A SIGNED IN OR/AND AN ANONYMOUS USER--------\n */\n\n System.out.println(\"Starting collecting queryless/queryfull submissions...\");\n System.out.println(\"\");\n// searchObj.performQuerylessSearchWithPersonalization(client);\n// searchObj.performQueryfullSearchWithPersonalization(client);\n// results = searchObj.performPharm24PersonalizedQueryfullSearch(client, userId, query);\n// results = searchObj.performPharm24PersonalizedQuerylessSearch(client, userId, query);\n \n for(int i=0; i<results.size(); i++){\n for(int j = 0; j<results.get(i).size();j++){\n System.out.println(results.get(i).get(j));\n }\n System.out.println(\"-------RERANKED---------\");\n }\n\n System.out.println(\"\");\n System.out.println(\"I\\'m done!\");\n \n \n }",
"public void performSearch() {\n final String url = String.format(BING_SEARCH_URL, Words.getRandomWord(), Words.getRandomWord());\n\n //open page with custom data\n openWebPage(url, \"Search url: \" + url);\n }",
"public void search() {\n\n lazyModel = new LazyDataModel<Pesquisa>() {\n private static final long serialVersionUID = -6541913048403958674L;\n\n @Override\n public List<Pesquisa> load(int first, int pageSize, String sortField, SortOrder sortOrder, Map<String, String> filters) {\n\n pesquisarBC.searhValidation(searchParam);\n\n int count = pesquisarBC.count(searchParam);\n lazyModel.setRowCount(count);\n\n if (count > 0) {\n if (first > count) {\n // Go to last page\n first = (count / pageSize) * pageSize;\n }\n SearchFilter parameters = new SearchFilter();\n parameters.setFirst(first);\n parameters.setPageSize(pageSize);\n List<Pesquisa> list = pesquisarBC.search(searchParam, parameters);\n\n logger.info(\"END: load\");\n return list;\n } else {\n return null;\n }\n }\n };\n\n }",
"public HashMap<String, Double> search(String query) {\n // ===================================================\n // 1. Fetch all inverted lists corresponding to terms\n // in the query.\n // ===================================================\n String[] terms = query.split(\" \");\n HashMap<String, Integer> qf = new HashMap<String, Integer>();\n // Calculate term frequencies in the query\n for (String term : terms) {\n if (qf.containsKey(term))\n qf.put(term, qf.get(term) + 1);\n else\n qf.put(term, 1);\n }\n HashMap<String, Double> docScore = new HashMap<String, Double>();\n for (Entry<String, Integer> termEntry : qf.entrySet()) {\n String term = termEntry.getKey();\n int qfi = termEntry.getValue();\n\n // ===================================================\n // 2. Compute BM25 scores for documents in the lists.\n // Make a score list for documents in the inverted\n // lists. Assume that no relevance information is \n // available. For parameters, use k1=1.2, b=0.75, \n // k2=100.\n // ===================================================\n double k1 = 1.2;\n double b = 0.75;\n double k2 = 100;\n int ni = invIndex.get(term).size();\n\n\n for (Entry<String, IndexEntry> invListEntry : invIndex.get(term).entrySet()) {\n String docID = invListEntry.getKey();\n double bm25Score;\n if (docScore.containsKey(docID))\n bm25Score = docScore.get(docID);\n else\n bm25Score = 0;\n\n // length of the document\n int dl = docStat.get(docID);\n // frequency of the term in the document\n int fi = invListEntry.getValue().getTf();\n double K = k1 * ((1 - b) + b * ((double) dl / avdl));\n\n // ===================================================\n // 3. Accumulate scores for each term in a query\n // on the score list.\n // ===================================================\n bm25Score += Math.log((N - ni + 0.5) / (ni + 0.5))\n * (((k1 + 1) * fi * (k2 + 1) * qfi) / ((K + fi) * (k2 + qfi)));\n docScore.put(docID, bm25Score);\n }\n }\n\n return docScore;\n }",
"protected final void exectute(JsonObject query) throws IOException {\n\n\t\tBuilder builder;\n\t\tJestResult jr;\n\t\t//System.out.println(\"------> exist \");\n\t\tif(CLIENT==null)\n\t\t\tCLIENT = ElasticClient.getElasticClient(((SimpleJsonStringConfig) mapConfig.get(HOST)).getValue())\n\t\t\t\t\t\t\t\t\t\t.getClient();\n\t\t\n\t\tbuilder = new Search.Builder(query.toString());\n\t\t((SimpleIndexConfig) mapConfig.get(INDEX)).process(builder);\n\t\tjr = CLIENT.execute(builder.build());\n\t\t//System.out.println(jr.getJsonObject());\n\t\tif(jr.getJsonObject().has(\"error\")){\n\t\t\tSystem.out.println(\"Exception ~ syntax elastic error : verifie your query\");\n\t\t\treturn;\n\t\t}\n//\t\tSystem.out.println(\"----------------------------------------------------\");\n//\t\tSystem.out.println(jr.getJsonObject());\n//\t\tSystem.out.println(\"----------------------------------------------------\");\n\t\telasticReturn = ElasticReturn.getElasticReturn(jr.getJsonObject());\n//\t\tSystem.out.println(elasticReturn);\n//\t\tSystem.out.println(\"----------------------------------------------------\");\n\n\t}",
"private void searchExec(){\r\n\t\tString key=jComboBox1.getSelectedItem().toString();\r\n\t\tkey=NameConverter.convertViewName2PhysicName(\"Discount\", key);\r\n\t\tString valueLike=searchTxtArea.getText();\r\n\t\tList<DiscountBean>searchResult=discountService.searchDiscountByKey(key, valueLike);\r\n\t\tjTable1.setModel(ViewUtil.transferBeanList2DefaultTableModel(searchResult,\"Discount\"));\r\n\t}",
"private void searchBook(String query) {\n String filter = this.bookFilter.getValue();\n String sort = this.sort.getValue();\n \n // Get the user defined comparator\n Comparator<Book> c = getBookComparator(filter, sort);\n\n // Create a book used for comparison\n Book book = createBookForQuery(filter, query);\n \n // Find all matches\n GenericList<Book> results = DashboardController.library.getBookTable().findAll(book, c);\n\n // Cast results to an array\n Book[] bookResults = bookResultsToArray(results, c);\n\n // Load the results in a new scene\n this.loadBookResultsView(bookResults);\n }"
] | [
"0.7114037",
"0.70888203",
"0.7007515",
"0.6898825",
"0.68955934",
"0.685382",
"0.67685795",
"0.6725217",
"0.6724627",
"0.670876",
"0.6656794",
"0.66468704",
"0.66386354",
"0.6591133",
"0.6587623",
"0.654739",
"0.6535751",
"0.6535751",
"0.65306",
"0.65280026",
"0.6522313",
"0.65023047",
"0.6501877",
"0.64891726",
"0.64601433",
"0.64218265",
"0.6420754",
"0.63773084",
"0.6364521",
"0.6335557",
"0.6334298",
"0.6328305",
"0.63186324",
"0.6292954",
"0.62927705",
"0.62877756",
"0.62580645",
"0.6220618",
"0.6205104",
"0.61856306",
"0.6179824",
"0.61691403",
"0.6160995",
"0.6160169",
"0.6157591",
"0.6144793",
"0.6142504",
"0.6137153",
"0.6126016",
"0.6116327",
"0.61156416",
"0.61093605",
"0.6097637",
"0.6090886",
"0.6090886",
"0.60890806",
"0.608213",
"0.6052073",
"0.60333896",
"0.60293615",
"0.60280603",
"0.6018806",
"0.60181844",
"0.6011531",
"0.60079664",
"0.5998968",
"0.59843194",
"0.598402",
"0.59785223",
"0.5972791",
"0.5969598",
"0.5952921",
"0.5948182",
"0.59478575",
"0.59453267",
"0.59430397",
"0.5930378",
"0.59240574",
"0.5924025",
"0.59205544",
"0.591853",
"0.5910071",
"0.59016675",
"0.5891989",
"0.58912414",
"0.58805066",
"0.5877649",
"0.5877419",
"0.58723736",
"0.58599806",
"0.58595794",
"0.58558273",
"0.58477485",
"0.5845562",
"0.58452666",
"0.5838114",
"0.58328974",
"0.58313364",
"0.5827013",
"0.58207667",
"0.58204406"
] | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public void actionPerformed(ActionEvent e) {
updateHistoryButtonText("");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
int minMakespan = 0; RKSchedule r = S.get(i).copyOf(); | public static rk getBestSolutionMax(ArrayList<rk> Sched) {
rk best = Sched.get(0).copyOf();
for (int i = 1; i < Sched.size(); i++) {
rk S = Sched.get(i).copyOf();
if (S.getFitness() > best.getFitness()) {
best = S;
}
}
return best;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void initialize(){\n// Schedule initializeList1, initializeList2, initializeList3, initializeList4,initializeList5,\n// initializeList6,initializeList7,initializeList8,initializeList9,\n// initializeList10,initializeList11,initializeList12,initializeList13,\n// initializeList14,initializeList15,initializeList16,initializeList17,\n// initializeList18,initializeList19,initializeList20,initializeList21,initializeList22;\n// initializeList1= new Schedule(\"A001\",\"LimKH\", 1629,\"A01\", \"pewdiepie\", \"0162313212\", \"Delivering\",\"5min\");\n// initializeList2= new Schedule(\"A002\",\"LimKW\", 1111,\"A02\", \"MsTingTT\", \"012432434\", \"Delivering\",\"5min\");\n// initializeList3= new Schedule(\"A003\",\"LowSK\",3456, \"A03\", \"AhLiao\", \"01312321213\", \"Delivering\",\"5min\");\n// initializeList4= new Schedule(\"A004\",\"NgWD\",9909, \"A04\", \"Kazuma\", \"015213797\", \"Delivering\",\"5min\"); \n// initializeList5= new Schedule(\"A005\",\"LooJW\",1233,\"A05\",\"Kalima\",\"01124356\",\"Delivering\",\"5min\");\n// initializeList6= new Schedule(\"A006\",\"LimJJ\",1012,\"A06\", \"LeongFoei\", \"01239909\", \"Delivering\",\"5min\");\n// initializeList7= new Schedule(\"A007\",\"MahHW\",3757,\"A07\",\"KongKong\",\"012283747\",\"Delivering\",\"5min\");\n// initializeList8= new Schedule(\"A008\",\"LoiKH\",9610,\"A08\",\"MigMing\",\"012636383\",\"Delivering\",\"5min\"); \n// initializeList9= new Schedule(\"A009\",\"LimNF\",5566,\"A09\",\"MsTing\",\"0192726363\",\"Delivering\",\"5min\");\n// initializeList10= new Schedule(\"A010\",\"LohKC\",6969,\"A10\",\"KitKat\",\"017265353\",\"Delivering\",\"5min\");\n// \n// initializeList11= new Schedule(\"A011\",\"LimKH\", 1629,\"A11\", \"Kari\", \"012213778\", \"Delivering\",\"5min\");\n// initializeList12= new Schedule(\"A012\",\"LimKW\", 1111,\"A12\", \"Yolo\", \"0162328212\", \"Delivering\",\"5min\");\n// initializeList13= new Schedule(\"A013\",\"LowSK\", 3456,\"A13\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList14= new Schedule(\"A015\",\"LowSK\", 3456,\"A14\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList15= new Schedule(\"A016\",\"LooJW\", 1233,\"A15\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList16= new Schedule(\"A017\",\"LimJJ\", 1012,\"A16\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList17= new Schedule(\"A018\",\"LimJJ\", 1012,\"A17\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList18= new Schedule(\"A019\",\"LoiKH\", 9610,\"A18\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList19= new Schedule(\"A020\",\"LimNF\", 5566,\"A19\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList20= new Schedule(\"A021\",\"LimNF\", 5566,\"A20\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// \n// //completed jobs\n// initializeList21= new Schedule(\"A022\",\"LimKH\", 1629,\"A21\", \"Doggo\", \"0198377213\", \"Completed\",\"5min\");\n// initializeList22= new Schedule(\"A023\",\"LimKH\", 1629,\"A22\", \"Cloud\", \"0198377213\", \"Completed\",\"5min\");\n// scheduleList.addSchedule(initializeList1);\n// scheduleList.addSchedule(initializeList2);\n// scheduleList.addSchedule(initializeList3);\n// scheduleList.addSchedule(initializeList4);\n// scheduleList.addSchedule(initializeList5);\n// scheduleList.addSchedule(initializeList6);\n// scheduleList.addSchedule(initializeList7);\n// scheduleList.addSchedule(initializeList8);\n// scheduleList.addSchedule(initializeList9);\n// scheduleList.addSchedule(initializeList10);\n// scheduleList.addSchedule(initializeList11);\n// scheduleList.addSchedule(initializeList12);\n// scheduleList.addSchedule(initializeList13);\n// scheduleList.addSchedule(initializeList14);\n// scheduleList.addSchedule(initializeList15);\n// scheduleList.addSchedule(initializeList16);\n// scheduleList.addSchedule(initializeList17); \n// scheduleList.addSchedule(initializeList18);\n// scheduleList.addSchedule(initializeList19);\n// scheduleList.addSchedule(initializeList20);\n// scheduleList.addSchedule(initializeList21);\n// scheduleList.addSchedule(initializeList22);\n \n \n\n for(int i = 0; i<scheduleList.getNumberOfSchedule();i++){\n int staff = scheduleList.getSchedule(i).getStaffID();\n jcbDeliveryman.addItem(staff);\n \n String order = scheduleList.getSchedule(i).getOrderID();\n jcbOrderNo.addItem(order);\n\n }\n \n \n// jcbDeliveryman.addActionListener(jcbOrderNo);\n// for(int i = 0; i<scheduleList.getNumberOfSchedule();i++){\n// jcbOrderNo.addItem(scheduleList.getSchedule(i).getOrderID());\n// }\n }",
"public Schedule getOptSchedule() \n\t{\n\t\tScheduledTask[] schedule = new ScheduledTask[tasks.length];\n\t\tbest = heuristicScheduling(); \n\t\trecursive(schedule, 0, new int[m]);\n\t\treturn best;\n\t}",
"public Reservation makeReservation(Reservation trailRes){\n //Using a for each loop to chekc to see if a reservation can be made or not\n if(trailRes.getName().equals(\"\")) {\n System.out.println(\"Not a valid name\");\n return null;\n }\n \n \n for(Reservation r: listR){\n if(trailRes.getReservationTime() == r.getReservationTime()){\n System.out.println(\"Could not make the Reservation\");\n System.out.println(\"Reservation has already been made by someone else\");\n return null;\n }\n }\n\n //if the time slot is greater than 10 or less than 0, the reservation cannot be made\n if(trailRes.getReservationTime() > 10 || trailRes.getReservationTime() < 0){\n System.out.println(\"Time slot not available\");\n return null;\n }\n\n //check to see if the reservable list is empty or not\n if(listI.isEmpty())\n {\n System.out.println(\"No reservation available\");\n return null;\n }\n\n //find the item and fitnessValue that will most fit our reservation\n Reservable item = listI.get(0);\n int fitnessValue = item.findFitnessValue(trailRes);\n\n //loop through the table list and find the best fit for our reservation\n for(int i = 0; i < listI.size() ; i++){\n if(listI.get(i).findFitnessValue(trailRes) > fitnessValue){\n item = listI.get(i);\n fitnessValue = item.findFitnessValue(trailRes);\n }\n }\n //if we have found a table that works, then we can make our reservation\n if(fitnessValue > 0){\n //add reservation to our internal list\n //point our reservable to the appropriate reservation\n //set the reservable \n //print out the message here not using the iterator\n listR.add(trailRes);\n item.addRes(trailRes);\n trailRes.setMyReservable(item);\n System.out.println(\"Reservation made for \" + trailRes.getName() + \" at time \" + trailRes.getReservationTime() + \", \" + item.getId());\n return trailRes;\n }\n System.out.println(\"No reservation available, number of people in party may be too large\");\n return null; \n }",
"public double getMakespan(){return makespan;}",
"private JNASchedule getFirstSchedule() {\n\t\tif (this.isDisposed()) {\n\t\t\tthrow new DominoException(0, \"Schedule collection has been disposed\");\n\t\t}\n\n\t\tDHANDLE hSchedules = getAllocations().getSchedulesHandle();\n\t\t\n\t\treturn LockUtil.lockHandle(hSchedules, (hSchedulesByVal) -> {\n\t\t\tIntByReference rethObj = new IntByReference();\n\t\t\tMemory schedulePtrMem = new Memory(Native.POINTER_SIZE);\n\n\t\t\tshort result = NotesCAPI.get().SchContainer_GetFirstSchedule(hSchedulesByVal, rethObj, schedulePtrMem);\n\t\t\tif (result == INotesErrorConstants.ERR_SCHOBJ_NOTEXIST) {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\tNotesErrorUtils.checkResult(result);\n\t\t\t\n\t\t\tif (rethObj.getValue()==0) {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\t\n\t\t\tlong peer = schedulePtrMem.getLong(0);\n\t\t\tif (peer==0) {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\tPointer schedulePtr = new Pointer(peer);\n\t\t\tNotesScheduleStruct retpSchedule = NotesScheduleStruct.newInstance(schedulePtr);\n\t\t\tretpSchedule.read();\n\t\t\t\n\t\t\tint scheduleSize = JNANotesConstants.scheduleSize;\n\t\t\tif (PlatformUtils.isMac() && PlatformUtils.is64Bit()) {\n\t\t\t\t//on Mac/64, this structure is 4 byte aligned, other's are not\n\t\t\t\tint remainder = scheduleSize % 4;\n\t\t\t\tif (remainder > 0) {\n\t\t\t\t\tscheduleSize = 4 * (scheduleSize / 4) + 4;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tPointer pOwner = retpSchedule.getPointer().share(scheduleSize);\n\t\t\tString owner = NotesStringUtils.fromLMBCS(pOwner, (retpSchedule.wOwnerNameSize-1) & 0xffff);\n\t\t\t\n\t\t\treturn new JNASchedule(this, retpSchedule, owner, rethObj.getValue());\n\t\t});\n\t}",
"public ArrayList<ArrayList<Dog>> getVetSchedule() {\n\t\t\tint initialCapacity = 10;\r\n\t\t\tArrayList<ArrayList<Dog>> list = new ArrayList<ArrayList<Dog>>(initialCapacity); //list to put in lists of dogs\r\n\t\t\t//intialize ArrayList with size ArrayList\r\n\t\t\tlist.add(new ArrayList<Dog>());\r\n\t\t\t/*for(int i=0; i<=10; i++){\r\n\t\t\t\tlist.add(new ArrayList<Dog>());\r\n\t\t\t}\r\n\t\t\t*/\r\n\t\t\tDogShelterIterator iterator = new DogShelterIterator();\r\n\t\t\twhile(iterator.hasNext()){\r\n\t\t\t\tDog nextDog = iterator.next();\r\n\t\t\t\tint index = nextDog.getDaysToNextVetAppointment()/7;\r\n\t\t\t\tif(index < list.size())list.get(index).add(nextDog);\r\n\t\t\t\telse{\r\n\t\t\t\t\t//index out of range --> create larger list\r\n\t\t\t\t\tArrayList<ArrayList<Dog>> newList = new ArrayList<ArrayList<Dog>>(index+1);\r\n\t\t\t\t\tnewList.addAll(list); //add all lists from the old list\r\n\t\t\t\t\tfor(int i=0; i<(index+1)-list.size(); i++){ //initialize the other half with new ArrayLists\r\n\t\t\t\t\t\tnewList.add(new ArrayList<Dog>());\r\n\t\t\t\t\t}\r\n\t\t\t\t\tlist = newList; //update list to the larger newList\r\n\t\t\t\t\tlist.get(index).add(nextDog);\r\n\t\t\t\t}\r\n\t\t\t}\r\n return list;\r\n\t\t}",
"public static int minimumNumberOfTimeSlots()\n {\n return 0;\n }",
"public void updateMakeSpan2() {\r\n // making a copy of particle before sorting\r\n List<Operation> copy = new ArrayList<>(particle.length);\r\n for (int jobIdx = 0; jobIdx < particle.length; jobIdx++) {\r\n copy.add(particle[jobIdx]);\r\n }\r\n Collections.sort(copy);\r\n\r\n // lastOperation keeps track of last time a machine is executing each job\r\n int[] lastOperation = new int[LookupTable.numberOfJobs];\r\n // machineNumber keeps track of the current machineNumber doing the specified job\r\n int[] machineNumber = new int[LookupTable.numberOfJobs];\r\n\r\n for (int i = 0; i < LookupTable.numberOfJobs; i++) lastOperation[i] = -1;\r\n\r\n // machineDurations keeps track of the time used to execute all jobs for each machine\r\n int[] machineDurations = new int[LookupTable.numberOfMachines];\r\n\r\n for (Operation o : copy) {\r\n int jobId = o.jobId;\r\n int machineId = LookupTable.jobOrder[jobId][machineNumber[jobId]++];\r\n\r\n // the end time of that job on another machine (possible start time for this job)\r\n int startTime = lastOperation[jobId];\r\n\r\n if (startTime > machineDurations[machineId]) {\r\n machineDurations[machineId] = startTime + LookupTable.durations[o.jobId][machineId];\r\n } else {\r\n machineDurations[machineId] += LookupTable.durations[o.jobId][machineId];\r\n }\r\n if (machineDurations[machineId] > lastOperation[o.jobId]) {\r\n lastOperation[o.jobId] = machineDurations[machineId];\r\n }\r\n }\r\n // update makespan\r\n makespan = 0;\r\n for (int duration : machineDurations) {\r\n if (duration > makespan) {\r\n makespan = duration;\r\n }\r\n }\r\n }",
"public ArrayList<int[]> getSchedule(){\n // Initialize the output list\n ArrayList<int[]> schedule = new ArrayList<>();\n\n // Initialize a list of tuples in the form (rally id, rally duration, rally deadline)\n ArrayList<int[]> rallyList = new ArrayList<>();\n for (int i = 0; i < _rallies.size(); i++) {\n int[] info = new int[] {i, _rallies.get(i)[0], _rallies.get(i)[1]};\n rallyList.add(info);\n }\n\n // Sort them in an increasing order of the deadline\n rallyList.sort(Comparator.comparingInt(rally -> rally[2]));\n\n // Set the start time\n int f = 0;\n\n // If there is no way to finish any one of the rally before its deadline, then we will set this to true.\n boolean nuke = false;\n\n // Run a greedy algorithm (Scheduling to Minimize Lateness)\n for (int[] rally : rallyList) {\n int[] plan = new int[] {rally[0], f};\n int duration = rally[1];\n int deadline = rally[2];\n f += duration;\n\n if (f > deadline) {\n nuke = true;\n break;\n }\n\n schedule.add(plan);\n }\n\n if (nuke) {\n return new ArrayList<>();\n }\n\n return schedule;\n }",
"@Test\n\tpublic void circleLeastStationTest() {\n\t\tList<String> newTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"1\");\n\t\tnewTrain.add(\"4\");\n\t\tList<TimeBetweenStop> timeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\tTimeBetweenStop timeBetweenStop = new TimeBetweenStop(\"1\", \"4\", 20);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"B\", timeBetweenStops);\n\t\t\n\t\tList<String> answer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"2\");\n\t\tanswer.add(\"3\");\n\t\tanswer.add(\"4\");\n\t\tTrip trip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(9, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\n\t\t//Add a new train, least time\n\t\tnewTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"1\");\n\t\tnewTrain.add(\"4\");\n\t\ttimeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\ttimeBetweenStop = new TimeBetweenStop(\"1\", \"4\", 8);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"C\", timeBetweenStops);\n\n\t\tanswer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"4\");\n\t\ttrip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(8, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\n\t\t//Add a new train, more stop but even less time\n\t\tnewTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"2\");\n\t\tnewTrain.add(\"5\");\n\t\tnewTrain.add(\"6\");\n\t\tnewTrain.add(\"4\");\n\t\ttimeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\ttimeBetweenStop = new TimeBetweenStop(\"2\", \"5\", 2);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"5\", \"6\", 1);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"6\", \"4\", 2);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"D\", timeBetweenStops);\n\n\t\tanswer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"2\");\n\t\tanswer.add(\"5\");\n\t\tanswer.add(\"6\");\n\t\tanswer.add(\"4\");\n\t\ttrip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(7, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\n\t\t//Add a new train, less time than above\n\t\tnewTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"7\");\n\t\tnewTrain.add(\"2\");\n\t\tnewTrain.add(\"3\");\n\t\tnewTrain.add(\"4\");\n\t\ttimeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\ttimeBetweenStop = new TimeBetweenStop(\"7\", \"2\", 1);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"2\", \"3\", 3);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"3\", \"4\", 1);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"E\", timeBetweenStops);\n\n\t\tanswer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"2\");\n\t\tanswer.add(\"3\");\n\t\tanswer.add(\"4\");\n\t\ttrip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(6, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\t}",
"public int minSeq() {\n lock.lock();\n int globalMin = dones[me];\n\n for(int i=0;i<dones.length;i++) {\n if(dones[i] < globalMin) {\n globalMin = dones[i];\n }\n }\n\n /*\n Iterator<Map.Entry<Integer,Instance<T>>> iter = (Iterator<Map.Entry<Integer,Instance<T>>>)seqMap.entrySet().iterator();\n while(iter.hasNext()) {\n int key = iter.next().getKey();\n if(key <= globalMin && seqMap.get(key).getStatus() == Status.DECIDED) iter.remove();\n }\n */\n lock.unlock();\n return globalMin+1;\n }",
"public StackWithMin() {\n st = new LinkedList<>();\n minSt = new LinkedList<>();\n }",
"private void applyRaceStartPenalty()\n {\n for(int i = 0; i < getDrivers().getSize(); i++)\n {\n getDrivers().getDriver(i).setAccumulatedTime(0); // set to default\n int driverRanking = getDrivers().getDriver(i).getRanking();\n int timePenalty = 10;\n switch(driverRanking)\n {\n case 1: timePenalty = 0; break;\n case 2: timePenalty = 3; break;\n case 3: timePenalty = 5; break;\n case 4: timePenalty = 7; break;\n }\n getDrivers().getDriver(i).setAccumulatedTime(timePenalty);\n }\n }",
"private void buildSchedule() {\n\t\tclass RabbitsGrassSimulationStep extends BasicAction {\n\t\t\tpublic void execute() {\n\t\t\t\tSimUtilities.shuffle(rabbitList);\n\t\t\t\tfor (int i = 0; i < rabbitList.size(); i++) {\n\t\t\t\t\tRabbitsGrassSimulationAgent rabbit = rabbitList.get(i);\n\t\t\t\t\trabbit.step();\n\t\t\t\t}\n\n\t\t\t\treapDeadRabbits();\n\t\t\t\tgiveBirthToRabbits();\n\n\t\t\t\trabbitSpace.spreadGrass(growthRateGrass);\n\n\t\t\t\tdisplaySurf.updateDisplay();\n\t\t\t}\n\t\t}\n\n\t\tschedule.scheduleActionBeginning(0, new RabbitsGrassSimulationStep());\n\n\t\tclass UpdateNumberOfRabbitsInSpace extends BasicAction {\n\t\t\tpublic void execute() {\n\t\t\t\trabbitsAndGrassInSpace.step();\n\t\t\t}\n\t\t}\n\n\t\tschedule.scheduleActionAtInterval(1, new UpdateNumberOfRabbitsInSpace());\n\n\t}",
"public void realocareThreadsDistribution(){\n for(int i=1;i<=nrThreads;i++){\n if(listofIntervalsForEachThread[i] == null)\n listofIntervalsForEachThread[i] = new IntervalClass();\n this.listofIntervalsForEachThread[i].setStart(0);\n this.listofIntervalsForEachThread[i].setEnd(0);\n }\n if(this.nrThreads>=this.borderArray.size())\n for(int i=0;i<this.borderArray.size();i++){\n this.listofIntervalsForEachThread[i+1].setStart(i);\n this.listofIntervalsForEachThread[i+1].setEnd(i);\n }\n else{\n int nrForEachThread = this.borderArray.size()/nrThreads;\n int difSurplus = this.borderArray.size()%nrThreads;\n int difRate;\n int lastAdded = 0;\n for(int i=1;i<=this.nrThreads;i++){\n if(difSurplus > 0){\n difRate = 1;\n difSurplus--;\n }\n else difRate = 0;\n \n this.listofIntervalsForEachThread[i].setStart(lastAdded);\n lastAdded = lastAdded + difRate + nrForEachThread - 1;\n this.listofIntervalsForEachThread[i].setEnd(lastAdded);\n lastAdded++;\n }\n }\n }",
"public void generateSchedule(){\n\t\t\n\t}",
"public Schedule heuristicScheduling() \n\t{ \n\t\t// this creates an array, originally empty, of all the tasks scheduled in the heuristic manner\n\t\tScheduledTask[] heuristic = new ScheduledTask[tasks.length];\n\t\n\t\t// this creates an array that holds the duration of tasks on every processor\n\t\tint[] processorDuration = new int[m];\n\t\t\n\t\t// this creates a clone of the tasks array so that it can be messed with\n\t\tint[] junkTasks = tasks.clone();\n\t\t\n\t\t// this is the index of how many tasks have already been scheduled\n\t\tint index = 0;\n\t\t\n\t\twhile (index < tasks.length)\n\t\t{\n\t\t\t// this is the index of the processor with the smallest duration\n\t\t\tint smallestIndex = 0;\n\t\t\t\n\t\t\t// this finds the processor with the smallest duration\n\t\t\tfor (int i = 0; i < m; i++)\n\t\t\t{\n\t\t\t\tif (processorDuration[i] < processorDuration[smallestIndex])\n\t\t\t\t\tsmallestIndex = i;\n\t\t\t}\n\t\t\t\n\t\t\t// this is the id of the task with the largest duration\n\t\t\tint largestIndex = 0;\n\n\t\t\t// this finds the task with the largest duration\n\t\t\tfor (int i = 0; i < junkTasks.length; i++)\n\t\t\t{\n\t\t\t\tif (junkTasks[i] > junkTasks[largestIndex])\n\t\t\t\t\tlargestIndex = i;\n\t\t\t}\n\t\t\t\n\t\t\t// this schedules the task with the largest duration at the processor with the smallest duration\n\t\t\t// and assigns it to heuristic array at the index\n\t\t\theuristic[index] = new ScheduledTask(largestIndex, smallestIndex);\n\t\t\t\n\t\t\t// this increments the duration of the processor to which the task just got assigned\n\t\t\tprocessorDuration[smallestIndex] += tasks[largestIndex];\n\t\t\t\n\t\t\t// this sets the duration of the task that was just scheduled to zero\n\t\t\tjunkTasks[largestIndex] = 0;\n\t\t\t\n\t\t\t// this increments the index since another task just got assigned\n\t\t\tindex++;\n\t\t}\n\t\t\n\t\treturn new Schedule(tasks, m, heuristic);\n\t}",
"protected ValuePosition getMinimum() {\n\t\t// Calcule la position et la durée d'exécution de la requête la plus courte dans le tableau des requêtes\n\t\tValuePosition minimum = new ValuePosition();\n\t\tminimum.position = 0;\n\t\tfor(int pos=0; pos<requests.length; pos++) {\n\t\t\tRequest request = requests[pos];\n\t\t\tif(request == null) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif(minimum.value == null || request.getElapsedTime() < minimum.value) {\n\t\t\t\tminimum.position = pos;\n\t\t\t\tminimum.value = request.getElapsedTime();\n\t\t\t}\n\t\t}\n\t\treturn minimum;\n\t}",
"private MySchedule getRandomInitialSchedule() {\r\n\t\tArrayList<MyCourse> courses = new ArrayList<MyCourse>();\r\n\t\tfor (MyClass aClass : this.allClasses)\r\n\t\t\tcourses.add(new MyCourse(aClass,\r\n\t\t\t\tthis.getRandomRoom(),\r\n\t\t\t\tthis.getRandomInstructor(),\r\n\t\t\t\tthis.getRandomTimeSlot()));\r\n\t\tMySchedule result = new MySchedule(courses);\r\n\t\treturn result.getEnergy() > 0 ? result : this.getRandomInitialSchedule();\r\n\t}",
"public ArrayList<Timestamp> generateNonSportSchedule(int faculties[], String course[] ,Date startDate, Date endDate){\r\n \t\r\n \t\r\n \tArrayList<CourseStructure > allCourseStructure = new ArrayList<CourseStructure>();\r\n \tArrayList<CourseStructure > tempCourseStructure = new ArrayList<CourseStructure>();\r\n \tArrayList<Timestamp> allFreeSlot = new ArrayList<Timestamp>();\r\n \t\r\n \t\r\n \t// get all structureCourse based on faculty\r\n \tif(faculties.length>0){\r\n \t\tFacultyCourseManager facultyCourseManager = new FacultyCourseManager();\r\n \t\tallCourseStructure = facultyCourseManager.getCourseByFaculty(faculties);\r\n \t}//end if(faculties.length>0)\r\n \t\r\n \t//get all structureCourse based on course\r\n \tif(course.length>0){\r\n \t\tCourseStructureManager coursestructure = new CourseStructureManager();\r\n \t\ttempCourseStructure = coursestructure.getAllCourseStructureByCourse(course);\r\n \t}//end if(course.length>0)\r\n \t\r\n \t//merge both CourseStructure Arraylist\r\n \tfor(int i =0 ; i<tempCourseStructure.size();i++){\r\n \t\tif(!allCourseStructure.contains(tempCourseStructure.get(i))){\r\n \t\t\tallCourseStructure.add(tempCourseStructure.get(i));\r\n \t\t}//end if(!allCourseStructure.contains(tempCourseStructure.get(i))){\r\n \t}//for(int i =0 ; i<tempCourseStructure.size();i++)\r\n \t\r\n \t\r\n \t\r\n \t /* implement a genetic algorithm\r\n \t * to find the best fit date\r\n \t */\r\n \t//variables\r\n \tArrayList<Timestamp> allSolutions = new ArrayList<Timestamp>();\r\n \tArrayList<Integer> solutionFitness = new ArrayList<Integer>();\r\n \tint totalTime,fitnessValue=0;\r\n \tTimestamp time = new Timestamp(startDate.getYear(), startDate.getMonth(), startDate.getDate(), 8, 0, 0, 0);\r\n \tboolean result;\r\n \t//initialize population\r\n \t/*university start at 8a.m to 8p.m\r\n \t * This makes 12 hr\r\n \t * Total time = (endDate -StartDate) * 12\r\n \t */\r\n \t \r\n \t\r\n \tlong daysBetween = endDate.getTime()- startDate.getTime();\r\n \t\r\n totalTime = (int)( (daysBetween * 12)/ (1000 * 60 * 60 * 24) );\r\n allSolutions.add(time);\r\n Calendar calender = Calendar.getInstance();\r\n \tfor(int i=1;i<totalTime;i++){\r\n \t\tif(time.getHours()>0 && time.getHours()<20){\r\n \t\t\tcalender.setTime(time);\r\n \t\t\t\r\n \t\t\tcalender.add(Calendar.HOUR, 1);\r\n \t\t\tlong tim = calender.getTime().getTime();\r\n \t\t\ttime = new Timestamp(tim);\r\n \t\t\tallSolutions.add(time);\r\n \t\t}//end if(time.getHours()>0 && time.getHours()<8){\r\n \t\telse{\r\n \t\t\tcalender.setTime(time);\r\n \t\t\t\r\n \t\t\tcalender.add(Calendar.HOUR, 12);\r\n \t\t\tlong tim = calender.getTime().getTime();\r\n \t\t\ttime = new Timestamp(tim);\r\n \t\t\tallSolutions.add(time); \t\t\t\r\n \t\t}//end else \t\t \t\t\r\n \t}//end for(int i=1;i<totalTime;i++){\r\n \t\r\n \t\r\n \t//fitness\r\n \t/*\r\n \t * if current timetable slot is free = increase by 1\r\n \t * if module is not in current timetable slot = increase by 1\r\n \t * if module is not a degree = increase by 1\r\n \t * if module is not year 3 = increase by 1 \r\n \t */\r\n \tTimetableManager timetableManager = new TimetableManager();\r\n \t//travel through population\r\n \tfor(int i=0; i<allSolutions.size();i++){\r\n \t\t//travel through course Structure\r\n \r\n \t\tfor(int j=0;j<allCourseStructure.size();j++){\r\n \t\t\t\r\n \t\t\t//check for current timetable slot\r\n \t\tint day = allSolutions.get(i).getDay();\r\n \t\tTime temTime = new Time(allSolutions.get(i).getTime());\r\n \t\t\r\n \t\t//check for course structure timetable slot\r\n \t\tresult = timetableManager.findTimetableByDayTime(temTime, getDays(day), allCourseStructure.get(j).getCourse_structure_id());\r\n \t\tif(!result){\r\n \t\t\tfitnessValue++;\r\n \t\t}//end if(!result) \r\n \t\t\t\r\n \t\t}//end for(int j=0;j<allCourseStructure.size();j++){\r\n \t\t\r\n \t\tsolutionFitness.add(fitnessValue);\r\n \t\tfitnessValue = 0;\r\n \t}//end for (int i=0; i<allSolutions.size();i++){\r\n \t\r\n \tint maxFitness = Collections.max(solutionFitness);\r\n \tfor(int i =0 ; i<allSolutions.size();i++){\r\n \t\tif(solutionFitness.get(i) == maxFitness){\r\n \t\t\tallFreeSlot.add(allSolutions.get(i));\r\n \t\t}\t\r\n \t}\r\n \t\r\n \t\r\n \t\r\n \treturn allFreeSlot; \t\r\n }",
"private MySchedule radomlyMutate(MySchedule schedule) {\r\n\t\tArrayList<MyCourse> courses = (ArrayList<MyCourse>) schedule.getCourses();\r\n\t\tint courseIndex = this.random.nextInt(courses.size());\r\n\t\tMyCourse course = courses.get(courseIndex);\r\n\t\tswitch (random.nextInt(3)) {\r\n\t\t\tcase 0:\r\n\t\t\t\tMyRoom aRoom = this.getRandomRoom();\r\n\t\t\t\twhile (course.getRoom() == aRoom)\r\n\t\t\t\t\taRoom = this.getRandomRoom();\r\n\t\t\t\tcourse.setRoom(aRoom);\r\n\t\t\t\tbreak;\r\n\t\t\tcase 1:\r\n\t\t\t\tMyInstructor aInstructor = this.getRandomInstructor();\r\n\t\t\t\twhile (course.getInstructor() == aInstructor)\r\n\t\t\t\t\taInstructor = this.getRandomInstructor();\r\n\t\t\t\tcourse.setInstructor(aInstructor);\r\n\t\t\t\tbreak;\r\n\t\t\tcase 2:\r\n\t\t\t\tMyTimeSlot aTimeSlot = this.getRandomTimeSlot();\r\n\t\t\t\twhile (course.getTimeSlot() == aTimeSlot)\r\n\t\t\t\t\taTimeSlot = this.getRandomTimeSlot();\r\n\t\t\t\tcourse.setTimeSlot(aTimeSlot);\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\t\tcourses.set(courseIndex, course);\r\n\t\treturn new MySchedule(courses);\r\n\t}",
"public void resizeStartUnchanged(int newcapacity){\n Object []lin=new Object[newcapacity];\n int k=start;\n for(int i=0;i<size;i++){\n lin[i]=cir[k];\n k=(k+1)%cir.length;\n }\n cir=new Object[newcapacity];\n for(int i=0;i<size;i++){\n cir[k]=lin[i];\n k=(k+1)%cir.length;\n }\n }",
"private void recursive(ScheduledTask[] schedule, int startIndex, int[] processorDurations)\n\t{\t\n\t\t// this is the base case. if the start index is at the size of schedule, aka all the tasks have\n\t\t// been assigned, then the method returns the complete schedule formed.\n\t\tif (startIndex == schedule.length)\n\t\t{\n\t\t\tSchedule temp = new Schedule(tasks, m, schedule);\n\t\t\tif (temp.getMakespan() < best.getMakespan())\n\t\t\t{\n\t\t\t\tbest = new Schedule(tasks, m, temp.getScheduledTasks());\n\t\t\t}\n\t\t}\n\t\tif (startIndex < schedule.length)\n\t\t{\n\t\t\t// this tries adding the task to each processor and finds the most optimal schedule formed\n\t\t\tfor (int i = 0; i < m; i++)\n\t\t\t{\n\t\t\t\t// this checks to see if adding a task would make the makespan greater than the optimum\n\t\t\t\t// if it does, then it's probably not the best solution\n\t\t\t\tif ((processorDurations[i] + tasks[startIndex]) > best.getMakespan())\n\t\t\t\t\tcontinue;\n\t\t\t\t\n\t\t\t\t// this assigns the task to the processor i\n\t\t\t\tschedule[startIndex] = new ScheduledTask(startIndex, i);\n\t\t\t\n\t\t\t\t// this increments the total duration of the processor that the task just got assigned to\n\t\t\t\tint [] processorDurationsTemp = processorDurations.clone();\n\t\t\t\tprocessorDurationsTemp[i] += tasks[startIndex];\n\t\t\t\t\n\t\t\t\t// this is where the recursion occurs\n\t\t\t\trecursive(schedule, startIndex + 1, processorDurationsTemp);\n\t\t\t}\n\t\t}\n\t\t\n\t}",
"static int[][] generateShifts(int maxDistanceLeft, ThreadVariables t){\n return null;\n }",
"private void plant(int l) {\n if (l >= empties.size()) {\n if (currentMines > bestMines) {\n copyField(current, best);\n bestMines = currentMines;\n }\n //geval 2: we zijn nog niet alle lege vakjes afgegaan, en we kunnen misschien nog beter doen dan de huidige oplossing\n } else if(currentMines + (empties.size() - l) > bestMines ) {\n //recursief verder uitwerken, met eerst de berekening van welk vakje we na (i,j) zullen behandelen\n int i = empties.get(l).getI();\n int j = empties.get(l).getJ();\n\n //probeer een mijn te leggen op positie i,j\n if (canPlace(i,j)) {\n placeMine(i, j);\n currentMines++;\n\n\n //recursie\n plant(l + 1);\n\n //hersteloperatie\n removeMine(i, j);\n currentMines--;\n\n }\n //recursief verder werken zonder mijn op positie i,j\n plant(l +1);\n }\n }",
"@Test\n\tpublic void modifyingScheduleWorks() throws Exception {\n\t\tResource floatRes = new Resource();\n\t\tfloatRes.setName(\"scheduleTest\");\n\t\tfloatRes.setType(FloatResource.class);\n\t\t// floatRes.setDecorating(Boolean.TRUE);\n\t\tFloatSchedule schedule = createTestSchedule();\n\n\t\tfloatRes.getSubresources().add(schedule);\n\t\tResource meter1 = unmarshal(sman.toXml(meter), Resource.class);\n\t\tmeter1.getSubresources().add(floatRes);\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\n\t\tschedule.getEntry().clear();\n\t\tschedule.setStart(2L);\n\t\tschedule.setEnd(3L);\n\n\t\tSampledValue v = new SampledFloat();\n\t\tv.setQuality(Quality.GOOD);\n\t\tv.setTime(2);\n\t\tv.setValue(new FloatValue(2));\n\t\tschedule.getEntry().add(v);\n\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\n\t\tSchedule ogemaSchedule = (Schedule) meter.getSubResource(\"scheduleTest\").getSubResource(\"data\");\n\n\t\tassertEquals(3, ogemaSchedule.getValues(0).size());\n\t\tassertEquals(2, ogemaSchedule.getValues(0).get(1).getValue().getFloatValue(), 0);\n\t}",
"public Schedule assign()\n\t{\n\t\tif(debug) System.out.println(\"Assignment started (Lecture Random)\");\n\t\tboolean valid = assignSlot(true); //assign times to Lectures\n\t\tif(debug && valid) System.out.println(\"Assignment started (Lab Random)\");\n\t\tif(valid) valid = assignSlot(false); //assign times to Labs\n\t\tif(debug && valid) System.out.println(\"Checking constraints (Random)\");\n\t\tif(valid) \n\t\t{\n\t\t\tvalid = constr(); //check the hard constraints one more time\n\t\t\tif(debug) System.out.println(child);\n\t\t}\n\t\tif (valid) child.setValue(child.eval()); //evaluate the soft constraints\n\t\t\n\t\tif(valid) \n\t\t{\n\t\t\tif(debug) System.out.println(child);\n\t\t\treturn child; //return the completed valid schedule\n\t\t}else\n\t\t{\n\t\t\tSystem.out.println(child);\n\t\t\treturn null; //invalid schedule, return nothing\n\t\t}\n\t}",
"private void findWaitingTime(int wt[]) {\n\t\tint rt[] = new int[n];\r\n\t\t\r\n\t\tfor(int i=0;i<n;i++) {\r\n\t\t\trt[i] = processList.get(i).getBurstTime();\r\n\t\t}\r\n\t\t\r\n\t\tint completed = 0,t=0,minm = Integer.MAX_VALUE;\r\n\t\tint shortest = 0, finish_time;\r\n\t\t\r\n\t\tboolean check = false;\r\n\t\t\r\n\t\twhile(completed!=n) {\r\n\t\t\t// find process with min rmaining time\r\n\t\t\tfor(int i=0; i<n ;i++) {\r\n\t\t\t\tif (processList.get(i).getArrivalTime()<=t && rt[i]<minm && rt[i]>0) {\r\n\t\t\t\t\tminm = rt[i];\r\n\t\t\t\t\tshortest = i;\r\n\t\t\t\t\tcheck = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(check == false) {\r\n\t\t\t\tt++;\r\n\t\t\t\tcontinue;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\trt[shortest]--;\r\n\t\t\t\r\n\t\t\tif (minm == 0) {\r\n\t\t\t\tminm = Integer.MAX_VALUE;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif (rt[shortest]==0) {\r\n\t\t\t\tcompleted++;\r\n\t\t\t\tcheck=false;\r\n\t\t\t\t\r\n\t\t\t\tfinish_time = t+1;\r\n\t\t\t\t\r\n\t\t\t\twt[shortest] = finish_time - processList.get(shortest).getBurstTime() - processList.get(shortest).getArrivalTime();\r\n\t\t\t\t\r\n\t\t\t\tif (wt[shortest]<0) {\r\n\t\t\t\t\twt[shortest] = 0;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tt++;\r\n\t\t}\r\n\t}",
"private List<Schedule> getSchedules(String traverserName, int delay) {\n List<ScheduleTimeInterval> intervals =\n new ArrayList<ScheduleTimeInterval>();\n intervals.add(new ScheduleTimeInterval(\n new ScheduleTime(0),\n new ScheduleTime(0)));\n \n List<Schedule> schedules = new ArrayList<Schedule>();\n Schedule schedule = new Schedule(traverserName, false, 60, delay, intervals);\n schedules.add(schedule);\n return schedules;\n }",
"private List<ItemMovement> uitGraven(Slot slot, Gantry gantry){\n\n List<ItemMovement> itemMovements = new ArrayList<>();\n Richting richting = Richting.NaarVoor;\n\n //Recursief naar boven gaan, doordat we namelijk eerste de gevulde parents van een bepaald slot moeten uithalen\n if(slot.getParent() != null && slot.getParent().getItem() != null){\n itemMovements.addAll(uitGraven(slot.getParent(), gantry));\n }\n\n //Slot in een zo dicht mogelijke rij zoeken\n boolean newSlotFound = false;\n Slot newSlot = null;\n int offset = 1;\n do { //TODO: als storage vol zit en NaarVoor en NaarAchter vinden geen vrije plaats => inf loop\n // bij het NaarAchter lopen uw index telkens het negatieve deel nemen, dus deze wordt telkens groter negatief.\n //AANPASSING\n Integer locatie = richting==Richting.NaarVoor? (slot.getCenterY() / 10) + offset : (slot.getCenterY() / 10) - offset;\n //we overlopen eerst alle richtingen NaarVoor wanneer deze op zen einde komt en er geen plaats meer is van richting veranderen naar achter\n // index terug op 1 zetten omdat de indexen ervoor al gecontroleerd waren\n if (grondSlots.get(locatie) == null) {\n //Grootte resetten en richting omdraaien\n offset = 1;\n richting = Richting.NaarAchter;\n continue;\n }\n\n Set<Slot> ondersteRij = new HashSet<>(grondSlots.get(locatie).values());\n newSlot = GeneralMeasures.zoekLeegSlot(ondersteRij);\n\n if(newSlot != null){\n newSlotFound = true;\n }\n //telkens één slot verder gaan\n offset += 1;\n }while(!newSlotFound);\n // vanaf er een nieuw vrij slot gevonden is deze functie verlaten\n\n //verplaatsen\n itemMovements.addAll(GeneralMeasures.createMoves(pickupPlaceDuration,gantry, slot, newSlot));\n update(Operatie.VerplaatsIntern, newSlot, slot);\n\n return itemMovements;\n }",
"@Override\n public Matching stableMarriageGaleShapley_residentoptimal(Matching marriage) {\n\n int m = marriage.getHospitalCount();\n int n = marriage.getResidentCount();\n\n ArrayList<ArrayList<Integer>> hospital_preference = marriage.getHospitalPreference();\n ArrayList<ArrayList<Integer>> resident_preference = marriage.getResidentPreference();\n ArrayList<Integer> hospitalSlots = marriage.getHospitalSlots();\n ArrayList<Integer> residentMatching = new ArrayList<Integer>();\n arrlistInit(residentMatching, n, -1, false); //O(n)\n\n /*At first the resident can propose to all his list.\n Each time a proposal is made the hospital is removed from the list*/\n\n /*Trying to create a copy of the arraylist elements not copy of references*/\n ArrayList<ArrayList<Integer>> hospitalsToProposeTo = new ArrayList<ArrayList<Integer>>();\n for (int i = 0; i < n; i++) //O(n)\n hospitalsToProposeTo.add(new ArrayList<Integer>(resident_preference.get(i)));\n\n\n /*list of residents that still can propose(free and hasn't proposed to every hospital)*/\n ArrayList<Integer> proposing = new ArrayList<Integer>();\n arrlistInit(proposing, n, 0, true); //O(n)\n\n\n /*Keep track of each hospital matched residents*/\n ArrayList<ArrayList<Integer>> hospitalResidents = new ArrayList<ArrayList<Integer>>(0);\n for (int i = 0; i < m; i++)\n hospitalResidents.add(new ArrayList<Integer>(0)); //O(m)\n\n /*Array list that holds the value of the lowest matched resident rank in each hospital\n * so each time a resident propose to a full hospital, the resident is swapped with the least ranked rmatched resident */\n ArrayList<Integer> lowestMatchedResidentRank = new ArrayList<Integer>();\n arrlistInit(lowestMatchedResidentRank, m, -1, false); //O(m)\n\n /*we enter the loop as long as some residents aren't done proposing to all hospitals yet O(mn*maximum no of spots)*/\n while (!proposing.isEmpty()) {\n\n /*Get the head of the proposing list*/\n for (int residentIndex = 0; residentIndex < proposing.size(); residentIndex++) {\n int resident = proposing.get(0);\n int hospital = 0;\n int hospitalIndex;\n /*Get the first hospital in the resident list which he hasn't proposed to yet, breaks if he can't no longer propose if matched*/\n for (hospitalIndex = 0; hospitalIndex < hospitalsToProposeTo.get(resident).size() && proposing.contains(resident); hospitalIndex++) {\n hospital = hospitalsToProposeTo.get(resident).get(0);\n int residentRank = hospital_preference.get(hospital).indexOf(resident);\n\n /*hospital is full, loop through the matched residents and see if anyone can be kicked out*/\n if (hospitalResidents.get(hospital).size() == hospitalSlots.get(hospital)) {\n\n if (residentRank < lowestMatchedResidentRank.get(hospital)) {\n /*1.Replace in hospitalResidents\n * 2.Add/remove in resident-matching\n * 3.Remove resident from the proposing list\n * 4.Check if matched resident still has hospitals to propose to (if yes, add to proposing)\n */\n int lowestMatchedResident = hospital_preference.get(hospital).get(lowestMatchedResidentRank.get(hospital));\n\n hospitalResidents.get(hospital).set(hospitalResidents.get(hospital).indexOf(lowestMatchedResident), resident);\n residentMatching.set(lowestMatchedResident, -1);\n residentMatching.set(resident, hospital);\n proposing.remove(proposing.indexOf(resident));\n if (!hospitalsToProposeTo.get(lowestMatchedResident).isEmpty()) {\n proposing.add(lowestMatchedResident);\n }\n\n /*set the lowest rank\n * TODO make it O(1)*/\n int min = 0;\n for (int i = 0; i < hospitalResidents.get(hospital).size(); i++) {\n int tempRank = hospital_preference.get(hospital).indexOf(hospitalResidents.get(hospital).get(i));\n if (tempRank > min)\n min = tempRank;\n }\n lowestMatchedResidentRank.set(hospital, min);\n\n }\n }\n\n /*If there is available spot*/\n else {\n /*1.Add in hospitalResidents\n * 2.Add in resident-matching\n * 3.Set the lowest ranked resident\n * 4.Remove resident from proposing list\n */\n\n /*Update the lowest rank*/\n if (residentRank > lowestMatchedResidentRank.get(hospital))\n lowestMatchedResidentRank.set(hospital, residentRank);\n\n hospitalResidents.get(hospital).add(resident);\n residentMatching.set(resident, hospital);\n proposing.remove(proposing.indexOf(resident));\n }\n\n /*1. Remove hospital from resident's hospitalsToProposeTo\n *2. If resident is matched or proposed to every possible hospital, remove resident from proposing list\n */\n\n hospitalsToProposeTo.get(resident).remove(hospitalsToProposeTo.get(resident).indexOf(hospital));\n if (hospitalsToProposeTo.get(resident).size() == 0 && proposing.contains(resident))\n proposing.remove(proposing.indexOf(resident));\n }\n }\n }\n\n marriage.setResidentMatching(residentMatching);\n return marriage;\n\n }",
"public void buildSchedule() {\n class SimulationStep extends BasicAction {\n public void execute() {\n SimUtilities.shuffle(rabbitList);\n for (int i = 0; i < rabbitList.size(); i++) {\n RabbitsGrassSimulationAgent rabbit = rabbitList.get(i);\n rabbit.step();\n }\n\n reapDeadRabbits();\n\n displaySurf.updateDisplay();\n }\n }\n schedule.scheduleActionBeginning(0, new SimulationStep());\n\n class GrassGrowth extends BasicAction {\n public void execute() {\n space.spreadGrass(grassGrowthRate);\n }\n }\n schedule.scheduleActionBeginning(0, new GrassGrowth());\n\n class UpdatePopulationPlot extends BasicAction {\n public void execute() {\n populationPlot.step();\n }\n }\n schedule.scheduleActionAtInterval(5, new UpdatePopulationPlot());\n }",
"public long getMinTime()\n {\n return times[0];\n }",
"public void makeRounds() {\n for (int i = 0; i < nrofturns; i++) {\n int check = 0;\n // If all distributors are bankrupt we intrrerupt the simulation\n for (Distributor d : listOfDistributors.getList()) {\n if (d.isBankrupt()) {\n continue;\n }\n check = 1;\n break;\n }\n if (check == 0) {\n break;\n }\n // Auxiliary variable that will point to the best deal for the consumers\n Distributor bestDist;\n // Making the updates at the start of each month\n if (listOfUpdates.getList().get(i).getNewConsumers().size() != 0) {\n for (Consumer x : listOfUpdates.getList().get(i).getNewConsumers()) {\n listOfConsumers.getList().add(x);\n }\n }\n if (listOfUpdates.getList().get(i).getDistributorChanges().size() != 0) {\n for (DistributorChanges x : listOfUpdates.getList().get(\n i).getDistributorChanges()) {\n listOfDistributors.grabDistributorbyID(\n x.getId()).setInitialInfrastructureCost(x.getInfrastructureCost());\n }\n }\n\n // Checking if the producers have changed their costs asta ar trb sa fie update\n\n // Making the variable point to the best deal in the current round\n // while also calculating the contract price for each distributor\n bestDist = listOfDistributors.getBestDistinRound();\n // Removing the link between consumers and distributors when the contract has ended\n for (Distributor d : listOfDistributors.getList()) {\n if (d.isBankrupt()) {\n // Case in which we delete the due payment of the consumer if\n // its current distributor goes bankrupt\n for (Consumer cons : listOfConsumers.getList()) {\n if (cons.getIdofDist() == d.getId()) {\n cons.setDuepayment(0);\n cons.setMonthstoPay(0);\n cons.setIdofDist(-1);\n }\n }\n continue;\n }\n d.getSubscribedconsumers().removeIf(\n c -> c.isBankrupt() || c.getMonthstoPay() <= 0);\n }\n // Giving the non-bankrupt consumers their monthly income and getting the ones\n // without a contract a deal (the best one)\n for (Consumer c : listOfConsumers.getList()) {\n if (c.isBankrupt()) {\n continue;\n }\n c.addtoBudget(c.getMonthlyIncome());\n if (c.getMonthstoPay() <= 0 || c.getIdofDist() == -1) {\n c.setIdofDist(bestDist.getId());\n c.setMonthstoPay(bestDist.getContractLength());\n c.setToPay(bestDist.getContractPrice());\n bestDist.addSubscribedconsumer(c);\n }\n }\n // Making the monthly payments for the non-bankrupt consumers\n for (Consumer entity : listOfConsumers.getList()) {\n if (entity.isBankrupt()) {\n continue;\n }\n // If the consumer has no due payment we check if he can pay the current rate\n if (entity.getDuepayment() == 0) {\n // If he can, do just that\n if (entity.getBudget() >= entity.getToPay()) {\n entity.addtoBudget(-entity.getToPay());\n listOfDistributors.grabDistributorbyID(entity.getIdofDist()).addBudget(\n entity.getToPay());\n entity.reduceMonths();\n // Contract has ended\n if (entity.getMonthstoPay() <= 0) {\n entity.setIdofDist(-1);\n }\n } else {\n // He cannot pay so he gets a due payment\n entity.setDuepayment(entity.getToPay());\n entity.reduceMonths();\n }\n } else {\n // The consumer has a due payment\n if (entity.getMonthstoPay() == 0) {\n // He has one to a distributor with whom he has ended the contract so\n // he must make the due payment and the one to the new distributor\n int aux = (int) Math.round(Math.floor(DUECOEFF * entity.getDuepayment()));\n int idAux = entity.getIdofDist();\n entity.setIdofDist(bestDist.getId());\n entity.setToPay(bestDist.getContractPrice());\n entity.setMonthstoPay(bestDist.getContractLength());\n bestDist.addSubscribedconsumer(entity);\n // He is able to\n if (entity.getBudget() >= (aux + entity.getToPay())) {\n entity.addtoBudget(-(aux + entity.getToPay()));\n listOfDistributors.grabDistributorbyID(idAux).addBudget(\n aux);\n listOfDistributors.grabDistributorbyID(entity.getIdofDist()).addBudget(\n entity.getToPay());\n entity.reduceMonths();\n } else {\n // He has insufficient funds\n entity.setBankrupt(true);\n }\n } else {\n // His due payment is at the same distributor he has to make the monthly\n // payments\n // He can do the payments\n if (entity.getBudget()\n >= (int) Math.round(Math.floor(DUECOEFF * entity.getDuepayment())\n + entity.getToPay())) {\n entity.addtoBudget(-(int) Math.round(Math.floor(DUECOEFF\n * entity.getDuepayment()) + entity.getToPay()));\n listOfDistributors.grabDistributorbyID(entity.getIdofDist()).addBudget(\n (int) Math.round(Math.floor(DUECOEFF * entity.getDuepayment())\n + entity.getToPay()));\n entity.reduceMonths();\n } else {\n // He cannot do the payments\n entity.setBankrupt(true);\n }\n }\n }\n }\n // The non-bankrupt distributors pay their monthly rates\n for (Distributor d : listOfDistributors.getList()) {\n if (d.isBankrupt()) {\n continue;\n }\n d.reduceBudget();\n // Those who cannot, go bankrupt\n if (d.getBudget() < 0) {\n d.setBankrupt(true);\n }\n }\n\n this.roundsAdjustments(i);\n }\n }",
"public void resetBoard(Board b, Team t) {\n\t\tstart = new ArrayList<Node>();\n\t\tpossibleSmart = new ArrayList<Integer>();\n\t\tbetterSmart = new ArrayList<Integer>();\n\t\tsmartIndex = -1;\n\t\tmaxType = -1;\n\t\tminType = 7;\n\t\tcheckMate = false;\n\t\tmaxProtect = -1;\n\t\tmaxRow = -1;\n\t\tmaxCol = -1;\n\n\t\tb.setProtections();\n\t\tb.setLocations();\n\t\tPiece[][] board = b.getBoard();\n\n\t\tPiece[][] newBoard = new Piece[board.length][board[0].length];\n\n\t\tfor (int r = 0; r < newBoard.length; r++)\n\t\t\tfor (int c = 0; c < newBoard[r].length; c++)\n\t\t\t\tnewBoard[r][c] = new Piece(board[r][c]);\n\n\t\tTeam op = (t == Team.WHITE) ? Team.BLACK : Team.WHITE;\n\n\t\tfor (int i = 0; i < newBoard.length; i++) {\n\t\t\tfor (int j = 0; j < newBoard[i].length; j++) {\n\t\t\t\tif (newBoard[i][j].getColor() == t) {\n\t\t\t\t\tif ((!newBoard[i][j].isProtected(t) && newBoard[i][j]\n\t\t\t\t\t\t\t.isProtected(op))\n\t\t\t\t\t\t\t|| newBoard[i][j].amountProtect(t) < newBoard[i][j]\n\t\t\t\t\t\t\t\t\t.amountProtect(op)) {\n\t\t\t\t\t\tif (newBoard[i][j].valueProtect(t) > maxProtect) {\n\t\t\t\t\t\t\tmaxProtect = newBoard[i][j].valueProtect(t);\n\t\t\t\t\t\t\tmaxRow = i;\n\t\t\t\t\t\t\tmaxCol = j;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfor (int r = 0; r < newBoard.length; r++) {\n\t\t\tfor (int c = 0; c < newBoard[r].length; c++) {\n\t\t\t\tif (newBoard[r][c].getColor() == t) {\n\t\t\t\t\tPiece p = new Piece(newBoard[r][c]);\n\t\t\t\t\tList<Location> loc = p.getMoveLoc();\n\t\t\t\t\tfor (Location l : loc) {\n\t\t\t\t\t\tstart.add(createNode(new Board(newBoard, t), p, r, c,\n\t\t\t\t\t\t\t\tl, t));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (smartIndex == -1) {\n\t\t\tif(betterSmart.size() > 0)\n\t\t\t\tsmartIndex = (int) (Math.random() * betterSmart.size());\n\t\t\telse if (possibleSmart.size() > 0)\n\t\t\t\tsmartIndex = (int) (Math.random() * possibleSmart.size());\n\t\t\telse\n\t\t\t\tsmartIndex = (int) (Math.random() * start.size());\n\t\t}\n\t}",
"public BetterParkingLot( int size )\n\t{\n\t\tsuper(size);\n queue = new PriorityQueue<Integer>(size);\n\n // add all available parking slots in zero-indexed form\n for(int i=0; i <= size; i++) // this is my only problem. It HAS to be O(n) here.\n queue.add(i);\n\t}",
"@Override\n public void run() {\n // each Car stop 1 second at first\n try {\n Thread.sleep(1000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n\n // choose between 4 lists\n while (true) {\n if (car.start == 1) {\n if (Street.west_list.peek().equals(car)) {\n try {\n Street.west_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n canAccessStreet();\n Street.west_list.remove();\n Street.west_street.release();\n break;\n } else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } else if (car.start == 2) {\n if (Street.south_list.peek().equals(car)) {\n try {\n Street.south_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n canAccessStreet();\n Street.south_list.remove();\n Street.south_street.release();\n break;\n }\n else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } else if (car.start == 3) {\n if (Street.east_list.peek().equals(car)) {\n try {\n Street.east_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n canAccessStreet();\n Street.east_list.remove();\n Street.east_street.release();\n break;\n }\n else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n // start = 4\n else {\n if (Street.north_list.peek().equals(car)) {\n try {\n Street.north_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n canAccessStreet();\n Street.north_list.remove();\n Street.north_street.release();\n break;\n }\n else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n }\n }",
"public Schedule() {\n\t\t// TODO Auto-generated constructor stub\n\t}",
"public void setSchedule(SpaceSchedule s) {\n\t\t\n\t}",
"@BeforeAll\n public static void setUp() {\n\n unsolvedCourseSchedule = new RoomSchedule();\n\n \n // fixed periods I'm defining\n \tRoomPeriods fixedRoomPeriod1=new RoomPeriods(1, 1);\n \tfixedRoomPeriod1.setSessionName(\"Session Fixed 1\");\n \t\n \tRoomPeriods fixedRoomPeriod2=new RoomPeriods(1, 2);\n \tfixedRoomPeriod2.setSessionName(\"Session Fixed 2\");\n \t\n // I'm adding fixed periods to schedule, these are known fixed schedule items\n \tunsolvedCourseSchedule.getLectureList().add(fixedRoomPeriod1);\n \tunsolvedCourseSchedule.getLectureList().add(fixedRoomPeriod2); \n \n /* I'm adding 10 more schedule items which are [null,null] , I'm expecting optoplanner assign period and room numbers. \n * [ THEY ARE LINKED with annotations, @PlanningVariable,\t@ValueRangeProvider(id = \"availablePeriods\", @ProblemFactCollectionProperty]\n */\n for(int i = 0; i < 10; i++){ \t \t\n unsolvedCourseSchedule.getLectureList().add(new RoomPeriods()); \n }\n \n // \n unsolvedCourseSchedule.getPeriodList().addAll(Arrays.asList(new Integer[] { 1, 2, 3 }));\n unsolvedCourseSchedule.getRoomList().addAll(Arrays.asList(new Integer[] { 1, 2 }));\n }",
"public ListUtilities returnToStart(){\n\t\tListUtilities temp = new ListUtilities();\n\t\tif(this.prevNum != null){\n\t\t\ttemp = this.prevNum.returnToStart();\n\t\t\treturn temp;\n\t\t}else{\n\t\t\t//System.out.println(\"Returned to... \" + this.num);\n\t\t\treturn this;\n\t\t}\n\t}",
"public double getMinTimeBetweenCarArrivals() {\n return minTimeBetweenCarArrivals;\n }",
"public Scheduler getScheduler()\r\n/* 30: */ {\r\n/* 31: 73 */ return this.scheduler;\r\n/* 32: */ }",
"public TSPMSTSolution(int iterations)\n {\n// System.out.println(\"NODE CREATED\");\n this.included = new int[0];\n this.includedT = new int[0];\n this.excluded = new int[0];\n this.excludedT = new int[0];\n this.iterations = iterations;\n }",
"public Object setInitialHoldings()\r\n/* */ {\r\n\t\t\t\tlogger.info (count++ + \" About to setInitialHoldings : \" + \"Agent\");\r\n/* 98 */ \tthis.profit = 0.0D;\r\n/* 99 */ \tthis.wealth = 0.0D;\r\n/* 100 */ \tthis.cash = this.initialcash;\r\n/* 101 */ \tthis.position = 0.0D;\r\n/* */ \r\n/* 103 */ return this;\r\n/* */ }",
"public void addFreezeFrame()\n{\n int index = Collections.binarySearch(_freezeFrames, getTime());\n if(index<0)\n _freezeFrames.add(-index - 1, getTime());\n}",
"Sporthall() {\n reservationsList = new ArrayList<>();\n }",
"private void maybeScheduleSlice(double when) {\n if (nextSliceRunTime > when) {\n timer.schedule(when);\n nextSliceRunTime = when;\n }\n }",
"@Test\n\tpublic void deletingScheduleIntervalWorks() throws Exception {\n\t\tResource floatRes = new Resource();\n\t\tfloatRes.setName(\"scheduleTest\");\n\t\tfloatRes.setType(FloatResource.class);\n\t\t// floatRes.setDecorating(Boolean.TRUE);\n\t\tFloatSchedule schedule = createTestSchedule();\n\n\t\tfloatRes.getSubresources().add(schedule);\n\t\tResource meter1 = unmarshal(sman.toXml(meter), Resource.class);\n\t\tmeter1.getSubresources().add(floatRes);\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\t\t\n\t\tschedule.getEntry().clear();\n\t\tschedule.setStart(2L);\n\t\tschedule.setEnd(3L);\n\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\n\t\tSchedule ogemaSchedule = (Schedule) meter.getSubResource(\"scheduleTest\").getSubResource(\"data\");\n\n\t\tassertEquals(2, ogemaSchedule.getValues(0).size());\n\t\tassertEquals(42, ogemaSchedule.getValues(0).get(0).getValue().getFloatValue(), 0);\n\t\tassertEquals(44, ogemaSchedule.getValues(0).get(1).getValue().getFloatValue(), 0);\n\t}",
"private void nextTraining() {\n\t\tif(!training_queue.isEmpty()) {\n\t\t\tPair<Soldier, Integer> tmp = training_queue.remove();\n\t\t\tif(tmp!=null) {\n\t\t\t\tcurrent = tmp.getKey();\n\t\t\t\tnb_to_train = tmp.getValue();\t\t\n\t\t\t\tnb_rounds = current.getTime_prod();\n\t\t\t}else {\n\t\t\t\tcurrent = null;\n\t\t\t\tnb_to_train = 1;\n\t\t\t\tnb_rounds = 100+50*(owner_castle.getLevel()+1);\n\t\t\t\tupgrade = true;\n\t\t\t}\n\t\t}else\n\t\t\tcurrent = null;\n\t}",
"private static List<FacilityFreeSchedule> generateFacilityFreeSchedules(Facility facility) {\n List<FacilityFreeSchedule> facilityFreeSchedules=new ArrayList<>();\n LocalDateTime now = LocalDateTime.now();\n Map<Integer,List<LocalDateTime>> workingHoursForMonth=workingHoursForFacilityPerWeek(facility, now);\n workingHoursForMonth.keySet().stream().forEach(weekIndex -> {\n List<LocalDateTime> workingHoursPerWeek = workingHoursForMonth.get(weekIndex);\n facilityFreeSchedules.addAll(workingHoursPerWeek.stream()\n .map(dateTime -> generateFacilityFreeSchedule(facility, dateTime, weekIndex))\n .collect(Collectors.toList()));\n });\n return facilityFreeSchedules;\n }",
"private void checkRequiredSemaphores() {\n if (car.start == 1){\n if (car.end == 2)\n requiredSemaphores.add(Street.sw);\n else if (car.end == 3){\n requiredSemaphores.add(Street.sw);\n requiredSemaphores.add(Street.se);\n }\n // end = 4\n else {\n requiredSemaphores.add(Street.sw);\n requiredSemaphores.add(Street.se);\n requiredSemaphores.add(Street.ne);\n }\n }\n else if (car.start == 2){\n if (car.end == 3)\n requiredSemaphores.add(Street.se);\n else if (car.end == 4){\n requiredSemaphores.add(Street.se);\n requiredSemaphores.add(Street.ne);\n }\n // end = 1\n else {\n requiredSemaphores.add(Street.se);\n requiredSemaphores.add(Street.ne);\n requiredSemaphores.add(Street.nw);\n }\n }\n else if (car.start == 3){\n if (car.end == 4)\n requiredSemaphores.add(Street.ne);\n else if (car.end == 1){\n requiredSemaphores.add(Street.ne);\n requiredSemaphores.add(Street.nw);\n }\n // end = 2\n else{\n requiredSemaphores.add(Street.ne);\n requiredSemaphores.add(Street.nw);\n requiredSemaphores.add(Street.sw);\n }\n }\n // start = 4\n else{\n if (car.end == 1)\n requiredSemaphores.add(Street.nw);\n else if (car.end == 2){\n requiredSemaphores.add(Street.nw);\n requiredSemaphores.add(Street.sw);\n }\n // end = 3\n else {\n requiredSemaphores.add(Street.nw);\n requiredSemaphores.add(Street.sw);\n requiredSemaphores.add(Street.se);\n }\n }\n }",
"public static int calcNextNewSpace(int stmIndex,SpaceTimeMatrix stm,Subcourseblock block,Vector<Room> rooms,Hashtable<Educator,Vector<Integer>> unavailableHoursForEducator,Hashtable<Program,Vector<Integer>> unavailableHoursForProgram)\r\n\t{\r\n\t\tfor(int i=stmIndex+1;i<stm.getSize();i++)\r\n\t\t{ \r\n\t\t\tif(Constraint.roomAvailableAtTime(i,stm))\r\n\t\t\t{\t\r\n\t\t\t\tRoom room = rooms.get(stm.giveRoom(i));\r\n\t\t\t\tif(Constraint.roomSufficient(room,block))\r\n\t\t\t\t{\t\r\n\t\t\t\t\tint hour = stm.giveHour(i);\r\n\t\t\t\t\tif(Constraint.roomAvailableForBlock(i,block,stm))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tif(Constraint.hourAvailable(hour,block,unavailableHoursForEducator,unavailableHoursForProgram))\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\treturn i;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn -1;\r\n\t}",
"public Location spread()\n {\n // plant needs to be alive, ready to reproduce (# of turns) \n // square needs to have fewer than 10 plants, BUT a tree can kill \n // a grass plant\n }",
"private void supplementMST(){\n\t\tList<Village> noOutRoads = getNoOutRoadVillages();\n\t\tList<Village> noInRoads = getNoInRoadVillages();\n\t\t\n\t\tfor(Village v: noOutRoads){\n\t\t\tVillage closestVillage = findClosestVillageTo(v,noInRoads);\n\t\t\tnoInRoads.remove(closestVillage);\n\t\t\tnew Road(v,closestVillage);\n\t\t}\n\t\t\n\t\tfor(Village v: noInRoads){\n\t\t\tnew Road(findClosestVillageTo(v,villages),v);\n\t\t}\n\t}",
"private int getLatestRuns() {\n // return 90 for simplicity\n return 90;\n }",
"private void maybeScheduleSlice() {\n if (nextSliceRunTime > 0) {\n timer.schedule();\n nextSliceRunTime = 0;\n }\n }",
"public Schedule() {\r\n\t\tschedule = new boolean[WEEK_DAYS][];\r\n\t\tfor(int i = 0; i < WEEK_DAYS; i++)\r\n\t\t\tschedule[i] = new boolean[SEGMENTS_PER_DAY];\r\n\t\tlisteners = new ArrayList<ScheduleChangeListener>();\r\n\t}",
"private Integer getStandardStart(int startTime) \n {\n \tif (startTime % 1440 > 960) {\n \t\tstartTime += 1440;\n \t}\n \tint startOfDay = startTime - (startTime % 1440);\n \t//we need a standard variable to indicate the day of week;\n \t//standard day starts at 08:00 = 480 minutes and ends at 16:00 = 960 minutes\n \tcapacityEndTime = startOfDay + 960;\n \treturn startOfDay + 480;\n }",
"private long getTimeIni(ArrayList<Point> r, ArrayList<Point> s){\n\t\t// Get the trajectory with latest first point\n\t\tlong t1 = s.get(0).timeLong > r.get(0).timeLong ? \n\t\t\t\ts.get(0).timeLong : r.get(0).timeLong;\n\t\treturn t1;\n\t}",
"public Pair<ProductionType,SoldierType> update() {\t\t\n\t\tif(current!=null) {\n\t\t\tnb_rounds--;\n\t\t\tif(nb_rounds==0) {\n\t\t\t\tnb_to_train--;\n\t\t\t\tPair<ProductionType,SoldierType> result = new Pair<ProductionType,SoldierType>(ProductionType.S,current.getType());\n\t\t\t\tif(nb_to_train==0)\n\t\t\t\t\tthis.nextTraining();\n\t\t\t\telse\n\t\t\t\t\tnb_rounds = current.getTime_prod();\n\t\t\t\treturn result;\n\t\t\t}\n\t\t}else if(upgrade){\n\t\t\tnb_rounds--;\n\t\t\tif(nb_rounds==0) {\n\t\t\t\tnb_to_train--;\n\t\t\t\tthis.nextTraining();\n\t\t\t\tupgrade = false;\n\t\t\t\treturn new Pair<ProductionType,SoldierType>(ProductionType.U,null);\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}",
"private void setWinningTuples() {\n\t\tWINS = new ArrayList<Set<CMNMove>>();\n\t\tSet<CMNMove> winSet = new TreeSet<CMNMove>();\n\t\tfor (int i = MM; i > 0; i--) {\n\t\t\tknapsack(winSet, CC, i, NN);\n\t\t}// end for\n\n\t}",
"public void generateWeeklySchedule(){\r\n for (int i = 0; i < numDayWorkWeek; i++)\r\n weeklySchedule.get(i).clear();\r\n\r\n int day = 0;\r\n int workHrs = 0;\r\n\r\n for (Task unfinishedTask: unfinished){\r\n if (day > numDayWorkWeek - 1) break;\r\n\r\n //if there is room for this task --> add it. Else, move to the next day\r\n if (workHrs + unfinishedTask.getHrsLeft() <= dailyWorkload){\r\n weeklySchedule.get(day).add(unfinishedTask);\r\n workHrs += unfinishedTask.getHrsLeft();\r\n }\r\n else{\r\n day++;\r\n weeklySchedule.get(day).add(unfinishedTask);\r\n workHrs = unfinishedTask.getHrsLeft();\r\n }\r\n }\r\n }",
"void lowerNumberOfStonesLeftToPlace();",
"public static void main(String[] args) throws FileNotFoundException, IOException {\nfor (double b = 0.5; b < 0.51; b+=0.1) {\n for (double k = 4.40; k < 4.5; k+=0.5) {\n Machine.b = 0.5; //0.2 - ATCnon-delay\n Machine.k = 1.5; //1.4 - ATCnon delay\n int hits = 0;\n engineJob = new cern.jet.random.engine.MersenneTwister(99999);\n noise = new cern.jet.random.Normal(0, 1, engineJob);\n SmallStatistics[] result = new SmallStatistics[5];\n result[0] = new SmallStatistics();\n result[1] = new SmallStatistics();\n for (int ds = 0; ds < 2; ds++) {\n JSPFramework[] jspTesting = new JSPFramework[105];\n for (int i = 0; i < jspTesting.length; i++) {\n jspTesting[i] = new JSPFramework();\n jspTesting[i].getJSPdata(i*2 + 1);\n }\n //DMU - instances (1-80)//la - instances (81-120)\n //mt - instances (121/-123)//orb - instances (124-133)//ta -instances (134-173)\n //////////////////////////////////////////////\n for (int i = 0; i < jspTesting.length; i++) {\n double countEval = 0;\n double tempObj = Double.POSITIVE_INFINITY;\n double globalBest = Double.POSITIVE_INFINITY;\n boolean[] isApplied_Nk = new boolean[2]; //Arrays.fill(isApplied_Nk, Boolean.TRUE);\n int Nk = 0; // index of the Iterative dispatching rule to be used\n jspTesting[i].resetALL();\n boolean firstIteration = true;\n double countLargeStep = 0;\n do{\n countEval++;\n //start evaluate schedule\n jspTesting[i].reset();\n int N = jspTesting[i].getNumberofOperations();\n jspTesting[i].initilizeSchedule();\n int nScheduledOp = 0;\n\n //choose the next machine to be schedule\n while (nScheduledOp<N){\n\n Machine M = jspTesting[i].Machines[jspTesting[i].nextMachine()];\n\n jspTesting[i].setScheduleStrategy(Machine.scheduleStrategy.HYBRID );\n jspTesting[i].setPriorityType(Machine.priorityType.ATC);\n jspTesting[i].setNonDelayFactor(0.3);\n //*\n jspTesting[i].setInitalPriority(M);\n for (Job J:M.getQueue()) {\n double RJ = J.getReadyTime();\n double RO = J.getNumberRemainingOperations();\n double RT = J.getRemainingProcessingTime();\n double PR = J.getCurrentOperationProcessingTime();\n double W = J.getWeight();\n double DD = J.getDuedate();\n double RM = M.getReadyTime();\n double RWT = J.getCurrentOperationWaitingTime();\n double RFT = J.getFinishTime();\n double RNWT = J.getNextOperationWaitingTime();\n int nextMachine = J.getNextMachine();\n\n if (nextMachine==-1){\n RNWT=0;\n } else {\n RNWT = J.getNextOperationWaitingTime();\n if (RNWT == -1){\n RNWT = jspTesting[i].getMachines()[nextMachine].getQueueWorkload()/2.0;\n }\n }\n if (RWT == -1){\n RWT = M.getQueueWorkload()/2.0;\n }\n //J.addPriority((W/PR)*Math.exp(-maxPlus((DD-RM-PR-(RT-PR+J.getRemainingWaitingTime(M)))/(3*M.getQueueWorkload()/M.getNumberofJobInQueue())))); //iATC\n //J.addPriority((PR*PR*0.614577*(-RM-RM/W)-RT*PR*RT/W)\n // -(RT*PR/(W-0.5214191)-RM/W*PR*0.614577+RT*PR/(W-0.5214191)*2*RM/W));\n //J.addPriority(((W/PR)*((W/PR)/(RFT*RFT)))/(max(div((RFT-RT),(RWT/W)),IF(RFT/W-max(RFT-RT,DD),DD,RFT))+DD/RFT+RFT/W-max(RFT-RFT/W,DD))); //best TWT priorityIterative\n if (Nk==0)\n //J.addPriority(min(W/PR-RFT+min(RT,W/RFT),((min(RT,RNWT-RFT)/(RJ-min(RWT,RFT*0.067633785)))/(RJ-min(RWT,RFT*0.067633785))))/RFT);\n J.addPriority(min(W/PR-RFT+min(RT,W/RFT),((div(min(RT,RNWT-RFT),(RJ-min(RWT,RFT*0.067633785))))/(RJ-min(RWT,RFT*0.067633785))))/RFT);\n else\n J.addPriority(min((((W/PR)/RFT)/(2*RNWT+max(RO,RFT)))/(PR+RNWT+max(RO,RFT)),((W/PR)/RFT)/PR)/RFT);\n }\n //jspTesting[i].calculatePriority(M);\n jspTesting[i].sortJobInQueue(M);\n Job J = M.completeJob();\n if (!J.isCompleted()) jspTesting[i].Machines[J.getCurrentMachine()].joinQueue(J);\n nScheduledOp++;\n }\n double currentObj = -100;\n currentObj = jspTesting[i].getTotalWeightedTardiness();\n if (tempObj > currentObj){\n tempObj = currentObj;\n jspTesting[i].recordSchedule();\n Arrays.fill(isApplied_Nk, Boolean.FALSE);\n //System.out.println(\"Improved!!!\");\n }\n else {\n isApplied_Nk[Nk] = true;\n if (!isNextApplied(Nk, isApplied_Nk)) Nk = circleShift(Nk, isApplied_Nk.length);\n else {\n if (globalBest>tempObj) {\n globalBest = tempObj;\n jspTesting[i].storeBestRecordSchedule();\n } jspTesting[i].restoreBestRecordSchedule();\n if (countLargeStep<1) {\n tempObj = Double.POSITIVE_INFINITY;\n Arrays.fill(isApplied_Nk, Boolean.FALSE);\n jspTesting[i].shakeRecordSchedule(noise, engineJob, globalBest);\n countLargeStep++;\n }\n else break;\n }\n }\n firstIteration = false;\n \n } while(true);\n result[ds].add(jspTesting[i].getDevREFTotalWeightedTardiness(globalBest));\n if (jspTesting[i].getDevLBCmax()==0) hits++;\n System.out.println(jspTesting[i].instanceName + \" & \"+ globalBest + \" & \" + countEval);\n }\n }\n //jsp.schedule();\n //*\n System.out.println(\"*************************************************************************\");\n System.out.println(\"[ & \" + formatter.format(result[0].getMin()) + \" & \"\n + formatter.format(result[0].getAverage()) + \" & \" + formatter.format(result[0].getMax()) +\n \" & \" + formatter.format(result[1].getMin()) + \" & \"\n + formatter.format(result[1].getAverage()) + \" & \" + formatter.format(result[1].getMax()) + \"]\");\n //*/\n System.out.print(\"\"+formatter.format(result[0].getAverage()) + \" \");\n }\n System.out.println(\"\");\n}\n }",
"Schedule createSchedule();",
"public String[] runRegularSeason()\n {\n int r = new Random().nextInt(1 + 1);\n String[] temp;\n\n int starting = new Random().nextInt(14 + 1);\n int ending = new Random().nextInt(14 + 1);\n\n for(int i = 0; i < standings.length; i++)\n {\n temp = standings[ending];\n\n if(standings[ending][1].compareTo(standings[starting][1]) > 0 && r == 1)\n {\n standings[ending] = standings[starting];\n standings[starting] = temp;\n }\n\n starting = new Random().nextInt(14 + 1);\n ending = new Random().nextInt(14 + 1);\n r = new Random().nextInt(1 + 1);\n }\n\n //Set playoff Array\n for(int i = 0; i < playoffs.length; i++)\n {\n playoffs[i] = standings[i][0];\n }\n\n return playoffs;\n }",
"public double evalSecDiff(Schedule sched) {\n\t\t\n\t\tint failCount = 0;\n\t\tArrayList<Course> sectionsOfCourse = new ArrayList<Course>(); //A list of all the sections for a class\n\t\tArrayList<Course> alreadyDone = new ArrayList<Course>(); //List of courses already looked\n\t\tCourse workingCourse, tempCourse;\n\t\tTimeSlot workingTimeSlot;\n\t\t\n\t\tfor(int i = 0;i<sched.getCourses().size();i++)\n\t\t{\n\t\t\tsectionsOfCourse = new ArrayList<Course>();\n\t\t\tworkingCourse = sched.getCourses().get(i);\n\t\t\t\n\t\t\t//If we haven't already looked at this course\n\t\t\tif((!alreadyDone.contains(workingCourse)) && workingCourse.getDepartment().equals(\"CPSC\"))\n\t\t\t{\n\t\t\t\t\n\t\t\t\tsectionsOfCourse.add(workingCourse);\n\t\t\t\talreadyDone.add(workingCourse);\n\t\t\t\t\n\t\t\t\t//Traverse through the course list and find all the sections\n\t\t\t\t//of the selected working course\n\t\t\t\tfor(int j = 0;j<sched.getCourses().size();j++)\n\t\t\t\t{\n\t\t\t\t\ttempCourse = sched.getCourses().get(j);\n\t\t\t\t\t\n\t\t\t\t\t//If they are the same course (with different sections)\n\t\t\t\t\tif(tempCourse.getDepartment().equals(workingCourse.getDepartment()) &&\n\t\t\t\t\t\t\ttempCourse.getNumber() == workingCourse.getNumber() &&\n\t\t\t\t\t\t\ttempCourse.getSection() != workingCourse.getSection())\n\t\t\t\t\t{\n\t\t\t\t\t\tsectionsOfCourse.add(tempCourse);\n\t\t\t\t\t\talreadyDone.add(tempCourse);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif(sectionsOfCourse.size() >1)\n\t\t\t\t{\n\t\t\t\t\t//System.out.println(sectionsOfCourse.size());\n\t\t\t\t\t//At this point, sections of course is all filled up with the sections of one course\n\t\t\t\t\t//Now we have to check that they all have different time slots\n\t\t\t\t\twhile(sectionsOfCourse.size() > 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tworkingTimeSlot = sectionsOfCourse.get(0).getSlot();\n\t\t\t\t\t\t\n\t\t\t\t\t\tif(workingTimeSlot != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfor(int j = 1;j<sectionsOfCourse.size();j++)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif(workingTimeSlot.getDay().equals(sectionsOfCourse.get(j).getSlot().getDay()) &&\n\t\t\t\t\t\t\t\t\t\tworkingTimeSlot.getStartTime() == sectionsOfCourse.get(j).getSlot().getStartTime())\n\t\t\t\t\t\t\t\t\tfailCount++;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tsectionsOfCourse.remove(0);\n\t\t\t\t\t}\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\t\t\n\t\treturn failCount * this.get_penSection();\n\t}",
"public void run() {\r\n\t\tint miCiclo = cicloRR;\r\n\t\tint misRafagas = rafagasRR;\r\n\t\t\r\n\t\tfloat indicePenalizacion = (float) 0.00;\r\n\t\tfloat penalizacion = (float) 0.00;\r\n\t\tfloat indicePenalizacionPorProceso =(float) 0.00;\r\n\t\t\r\n\t\t//Como vamos a reducir el valor del quantum antes del principio de ciclo\r\n\t\t//Sumamos 1 al quantum original, así compensamos esa reducción en el primer\r\n\t\t//ciclo de ejecución y realizamos un ciclo de quantum completo\r\n\t\tint miQuantum = quantumRR + 1;\r\n\t\t\r\n\t\tfor (miCiclo = 0; miCiclo < misRafagas; miCiclo++) {\r\n\t\t\t//Compruebo si algún elemento coincide su llegada con el ciclo\r\n\t\t\t//Si coincide, lo añado a la cola\r\n\t\t\tfor (int i = 0; i<miListaRR.size(); i++) {\r\n\t\t\t\tif(miListaRR.get(i).getLlegada() == cicloRR) {\r\n\t\t\t\t\tcolaProcesosRR.add(miListaRR.get(i));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t//Sumamos 1 al ciclo\r\n\t\t\tcicloRR++;\r\n\t\t\t\t\r\n\t\t\t//Restamos 1 al quantum restante\r\n\t\t\tmiQuantum--;\r\n\t\t\t//Si el quantum es 0, lo reiniciamos y enviamos el 1er elemento de la cola al final\r\n\t\t\tif (miQuantum == 0) {\r\n\t\t\t\tmiQuantum = quantumRR;\r\n\t\t\t\tcolaProcesosRR.add(colaProcesosRR.peek());\r\n\t\t\t\tcolaProcesosRR.poll();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//Restamos 1 a la rafaga pendiente\r\n\t\t\tcolaProcesosRR.peek().setRafaga(colaProcesosRR.peek().getRafaga()-1);\r\n\t\t\t\t\r\n\t\t\t//Escribimos la línea con la información del proceso\r\n\t\t\t//Si al proceso le quedan 0 ráfagas, ha terminado, así que lo sacamos de la cola\r\n\t\t\tif (colaProcesosRR.peek().getRafaga() == 0) {\r\n\r\n\t\t\t\tSystem.out.println(\t\"Ciclo \" + cicloRR + \r\n\t\t\t\t\t\t\t\t\t\". Proceso \" + colaProcesosRR.peek().getNombre() + \r\n\t\t\t\t\t\t\t\t\t\". Ráfagas pendientes: \" + colaProcesosRR.peek().getRafaga() +\r\n\t\t\t\t\t\t\t\t\t\" FIN DEL PROCESO \" + colaProcesosRR.peek().getNombre()); \r\n\t\t\t\tcolaProcesosRR.peek().setSalida(cicloRR);\r\n\t\t\t\tcolaProcesosRR.poll();\r\n\t\t\t\tmiQuantum = quantumRR+1;\r\n\t\t\t}\t\t\t\t\r\n\t\t\t//Si le quedan ráfagas pendientes, mostramos la información y volvemos al principio\r\n\t\t\telse {\r\n\t\t\t\tSystem.out.println(\t\"Ciclo \" + cicloRR + \r\n\t\t\t\t\t\t\t\t\t\". Proceso \" + colaProcesosRR.peek().getNombre() + \r\n\t\t\t\t\t\t\t\t\t\". Ráfagas pendientes: \" + colaProcesosRR.peek().getRafaga());\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println(\"\\n\" + \"Índices de penalización:\" + \"\\n\");\r\n\t\t\r\n\t\t//Para cada proceso, calculamos la penalización y la vamos añadiendo a un total\r\n\t\tfor (int i = 0; i<miListaRR.size() ; i++) {\r\n\t\t\tpenalizacion = (float) (miListaRR.get(i).getSalida()-miListaRR.get(i).getLlegada()) / miListaRR.get(i).getRafagaInicial();\r\n\t\t\tindicePenalizacionPorProceso = penalizacion / miListaRR.size();\r\n\t\t\tindicePenalizacion = indicePenalizacion + indicePenalizacionPorProceso;\r\n\t\t\tSystem.out.println(\"Índice de penalización del proceso \" + miListaRR.get(i).getNombre() + \": \" + penalizacion);\r\n\t\t}\r\n\t\t\r\n\t\t//Finalmente, mostramos la penalización total\r\n System.out.println(\"\\n\" + \"Índice de Penalización total: \" + indicePenalizacion);\r\n \r\n\t}",
"private void createConstraintsForSingleton() {\n \t\tSet s = slice.entrySet();\n \t\tfor (Iterator iterator = s.iterator(); iterator.hasNext();) {\n \t\t\tMap.Entry entry = (Map.Entry) iterator.next();\n \t\t\tHashMap conflictingEntries = (HashMap) entry.getValue();\n \t\t\tif (conflictingEntries.size() < 2)\n \t\t\t\tcontinue;\n \n \t\t\tCollection conflictingVersions = conflictingEntries.values();\n \t\t\tString singletonRule = \"\"; //$NON-NLS-1$\n \t\t\tArrayList nonSingleton = new ArrayList();\n \t\t\tint countSingleton = 0;\n \t\t\tfor (Iterator conflictIterator = conflictingVersions.iterator(); conflictIterator.hasNext();) {\n \t\t\t\tIInstallableUnit conflictElt = (IInstallableUnit) conflictIterator.next();\n \t\t\t\tif (conflictElt.isSingleton()) {\n \t\t\t\t\tsingletonRule += \" -1 \" + getVariable(conflictElt); //$NON-NLS-1$\n \t\t\t\t\tcountSingleton++;\n \t\t\t\t} else {\n \t\t\t\t\tnonSingleton.add(conflictElt);\n \t\t\t\t}\n \t\t\t}\n \t\t\tif (countSingleton == 0)\n \t\t\t\tcontinue;\n \n \t\t\tfor (Iterator iterator2 = nonSingleton.iterator(); iterator2.hasNext();) {\n \t\t\t\tconstraints.add(singletonRule + \" -1 \" + getVariable((IInstallableUnit) iterator2.next()) + \" >= -1;\"); //$NON-NLS-1$ //$NON-NLS-2$\n \t\t\t}\n \t\t\tsingletonRule += \" >= -1;\"; //$NON-NLS-1$\n \t\t\tconstraints.add(singletonRule);\n \t\t}\n \t}",
"public void scheduleMarathon()\n\t{\n\n\t\t//Create new threads\n\t\tThread h = new Thread(new ThreadRunner(HARE,H_REST,H_SPEED)); \n\t\tThread t = new Thread(new ThreadRunner(TORTOISE,T_REST,T_SPEED)); \n\n\t\tArrayList<Thread> runnerList = new ArrayList<Thread>();\n\t\trunnerList.add(h);\n\t\trunnerList.add(t);\n\n\t\tSystem.out.println(\"Get set...Go! \");\n\t\t//Start threads\n\t\tfor (Thread i: runnerList){\n\t\t\ti.start();\n\t\t}\n\n\t\twaitMarathonFinish(runnerList);\n\t}",
"private void setTableModel(List<SlotDto> slots){\n \n int size = 0;\n if(slots != null && !slots.isEmpty())\n size = slots.size();\n \n Object [][] slotsArr = new Object [25][9];\n\n // set days to table cells\n slotsArr[0][0] = \"Sunday\";\n slotsArr[5][0] = \"Monday\";\n slotsArr[10][0] = \"Tuesday\";\n slotsArr[15][0] = \"Wednesday\";\n slotsArr[20][0] = \"Thursday\";\n\n // loop for days' rows of schedule\n for(int r =0;r<5;r++){\n r=r*5;\n \n // loop for slots' columns of schedule \n for (int c=0 ; c<4 ; c++){ \n int cell=c*2;\n \n // loop to get slot of indexed day and time slot \n for( int i=0 ; i<size ; i++ ){\n if( (slots.get(i).getNum()== (c+1) && (slots.get(i).getDay().equals(slotsArr[r][0])) ) ){\n \n // set course name and code od slot \n slotsArr[r][cell+1] = slots.get(i).getCourse().getName();\n slotsArr[r][cell+2] = slots.get(i).getCourse().getCode();\n \n // set type of slot \n slotsArr[r+2][cell+1] = slots.get(i).getSlot_type();\n \n // set location of slot\n slotsArr[r+3][cell+1] = slots.get(i).getLocation().getName();\n \n \n // check slot type then set plt of slot\n if(slots.get(i).getSlot_type().equals(\"LECTURE\")){\n slotsArr[r+3][cell+2] = slots.get(i).getCourse().getPlt_lecture().getCode();\n System.out.println(\"plt\"+slots.get(i).getCourse().getPlt_lecture().getCode());\n }\n if(slots.get(i).getSlot_type().equals(\"SECTION\")){\n slotsArr[r+3][cell+2] = slots.get(i).getCourse().getPlt_lecture().getCode();\n System.out.println(\"plt\"+slots.get(i).getCourse().getPlt_lecture().getCode()); \n }\n \n // set student number of slot \n slotsArr[r+4][cell+1] = \"STUDENT NUMBER\";\n slotsArr[r+4][cell+2] = slots.get(i).getStudent_number();\n \n /*\n * set staff of slot then check if members > 1 then concatenate all members' names\n * and set to cell */\n String staff = slots.get(i).getStaff().get(0).getPosition() + \"/\" +\n slots.get(i).getStaff().get(0).getName() ;\n \n System.out.println(\"staff size\" + slots.get(i).getStaff().size()); \n System.out.println(\"user size\" + slots.get(i).getUser().size()); \n \n if(slots.get(i).getStaff().size()>1){\n for(int j=1 ; j<slots.get(i).getStaff().size() ; j++ ){\n staff=staff+\" # \" +slots.get(i).getStaff().get(j).getPosition()+\"/\"+\n slots.get(i).getStaff().get(j).getName() ; \n }\n }\n slotsArr[r+1][cell+1] = staff;\n \n /*\n * set user email of slot then check if users > 1 then concatenate all users' email \n * and set to cell */ \n String[] email = slots.get(i).getUser().get(0).getEmail().split(\"@\", 2);\n String user = email[0];\n if(slots.get(i).getUser().size()>1){\n for(int k=0 ; k<slots.get(i).getUser().size() ; k++){\n String[] _email = slots.get(i).getUser().get(k).getEmail().split(\"@\", 2);\n user = user +\" # \" + _email[0]; \n }\n }\n slotsArr[r+1][cell+2] = user;\n }\n }\n }\n }\n scheduleTable.setModel(new javax.swing.table.DefaultTableModel(slotsArr,\n new String [] {\n \"Time Slot\", \"First\",\" \", \"Second\", \" \" ,\"Third\",\" \",\"Fourth\",\" \"\n }\n ));\n\n }",
"public boolean scheduleAlg1(int currBoolReset, int maxGuidesPerTourInt, int maxToursPerGuideInt, int minGuidesPerTourInt, int minToursPerGuideInt){\n\t\t\r\n\t\tint numberOfWeeks = findNumWeeks();\r\n\t\tfor(int x = 0; x < numberOfWeeks; x++){\r\n\t\t\tfor(int y = 0; y < personList.size(); y++){\r\n\t\t\t\t//System.out.println(\"a\");\r\n\t\t\t\tpersonList.get(y).weeks.add(false);\r\n\t\t\t}\r\n\t\t}\r\n\t\t//System.out.println(\"here it's \" + personList.get(0).weeks.size());\r\n\t\t\r\n\t\tint currentAvailabilityBool; //This is the index in the availability boolean array list that is currently relevant. \r\n\t\tint week = 0;\r\n\t\tboolean innerWhile, outerWhile;\r\n\t\tint currentAvailabilityInt, currentToursGivenInt; \r\n\t\tcurrentHighestTourCount = 0;\r\n\t\tif(currBoolReset >= toursInTheWeek){\r\n\t\t\tcurrBoolReset = 0;\t\t\t\r\n\t\t}\r\n\t\tfor(int i = 0; i < maxGuidesPerTourInt; i++){\r\n\t\t\t//System.out.println(\"guide: \" + i);\r\n\t\t\t//System.out.println(\"Adding guide \" + i);\r\n\t\t\tcurrentAvailabilityBool = currBoolReset; //Have to reset it each time we loop through. \r\n\t\t\t//System.out.println(\"OUTERMOST LOOP IS \" + i);\r\n\t\t\tfor(int j = 0; j < dayList.size(); j++){\r\n\t\t\t\tweek = getWeekFromDay(j);\r\n\t\t\t\t//System.out.println(\"Day: \" + j + \" Week: \" + week);\r\n\t\t\t\tif(!dayList.get(j).holiday){ //If the current day isn't a holiday.\r\n\t\t\t\t\t//Go through all the tours on the current day.\r\n\t\t\t\t\t//System.out.println(dayList.get(j).numberOfTours + \" tours today\");\r\n\t\t\t\t\tfor(int k = 0; k < dayList.get(j).numberOfTours; k++){\r\n\t\t\t\t\t\t//System.out.println(\"Looking at tour \" + k);\r\n\t\t\t\t\t\touterWhile = true;\r\n\t\t\t\t\t\tcurrentToursGivenInt = 0;\r\n\t\t\t\t\t\twhile(outerWhile){\r\n\t\t\t\t\t\t\tinnerWhile = true;\r\n\t\t\t\t\t\t\t//System.out.println(\"OUTER WHILE - Looking at guides who have given \" + currentToursGivenInt + \" tours\");\r\n\t\t\t\t\t\t\tcurrentAvailabilityInt = 0;\r\n\t\t\t\t\t\t\twhile(innerWhile){\r\n\t\t\t\t\t\t\t\t//System.out.println(\"INNER WHILE - Availability of \" + currentAvailabilityInt);\r\n\t\t\t\t\t\t\t\t//numOfAvailableSlots\r\n\t\t\t\t\t\t\t\t//Go through guides and find one with an availability matching the currentAvailabilityInt and a true value \r\n\t\t\t\t\t\t\t\t//at the currentAvailabilityBool. Set lookingForAGuide to true and add that guide to the current tour's list,\r\n\t\t\t\t\t\t\t\t//as long as all the requirements are met. \r\n\t\t\t\t\t\t\t\t//Remember to check if currentHighestTourCount needs to be incremented.\r\n\t\t\t\t\t\t\t\tfor(int m = 0; m < personList.size(); m++){\r\n\t\t\t\t\t\t\t\t\t//System.out.println(\"m is \" + m + \" and currentAvailabilityBool is \" + currentAvailabilityBool);\r\n\t\t\t\t\t\t\t\t\tif(personList.get(m).toursThisMonth == currentToursGivenInt && personList.get(m).numOfAvailableSlots == currentAvailabilityInt && personList.get(m).availabilityBooleans.get(currentAvailabilityBool))\r\n\t\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\t\t//Then we've found a guide that's got the minimum availability and is available at this time.\r\n\t\t\t\t\t\t\t\t\t\t//Check requirements, then add them if they're met. \r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\tif(personList.get(m).toursThisMonth < maxToursPerGuideInt){\r\n\t\t\t\t\t\t\t\t\t\t\t//Have to check if they've already given a tour that day. \r\n\t\t\t\t\t\t\t\t\t\t\tif(personList.get(m).checkIfScheduled(j) && personList.get(m).weeks.get(week) == false){ //Make sure they haven't been given a tour on this day before.\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).toursThisMonth++;\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).scheduledDays.add(j); //Add this day to the list. \r\n\t\t\t\t\t\t\t\t\t\t\t\tif(personList.get(m).toursThisMonth > currentHighestTourCount){\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tcurrentHighestTourCount = personList.get(m).toursThisMonth;\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t//System.out.println(\"Current highest tour count is \" + currentHighestTourCount);\r\n\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t\t\tdayList.get(j).tourList.get(k).addGuide(personList.get(m));\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).tourList.add(dayList.get(j).tourList.get(k)); //Add the tour to that guide's list of tours.\r\n\t\t\t\t\t\t\t\t\t\t\t\t//System.out.println(\"We just added \" + personList.get(m).name);\r\n\t\t\t\t\t\t\t\t\t\t\t\tinnerWhile = false;\r\n\t\t\t\t\t\t\t\t\t\t\t\touterWhile = false;\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).weeks.set(week, true);\r\n\t\t\t\t\t\t\t\t\t\t\t\tm = personList.size();\r\n\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}//For m\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\tcurrentAvailabilityInt++;\r\n\t\t\t\t\t\t\t\tif(currentAvailabilityInt > toursInTheWeek){\r\n\t\t\t\t\t\t\t\t\tinnerWhile = false;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t} //inner while\r\n\t\t\t\t\t\t\tcurrentToursGivenInt++;\r\n\t\t\t\t\t\t\tif(currentToursGivenInt > currentHighestTourCount){\r\n\t\t\t\t\t\t\t\t//We couldn't find a tour guide. Do we break somehow?\r\n\t\t\t\t\t\t\t\tif(i < minGuidesPerTourInt){\r\n\t\t\t\t\t\t\t\t\tSystem.out.println(\"Returned here\");\r\n\t\t\t\t\t\t\t\t\treturn false; //Because we never reached the minimum guides per tour number.\r\n\t\t\t\t\t\t\t\t}\t\r\n\t\t\t\t\t\t\t\t//Otherwise we can just skip this tour. \r\n\t\t\t\t\t\t\t\touterWhile = false;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t} //outer while\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//Here's where we update the counter for which availability bool we're looking at.\r\n\t\t\t\t\t\tcurrentAvailabilityBool++;\r\n\t\t\t\t\t\tif(currentAvailabilityBool >= toursInTheWeek){\r\n\t\t\t\t\t\t\tcurrentAvailabilityBool = 0; //Time to reset it.\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}//For k\r\n\t\t\t\t}//If not a holiday.\r\n\t\t\t\telse{\r\n\t\t\t\t\tfor(int k = 0; k < dayList.get(j).numberOfTours; k++){\r\n\t\t\t\t\t\tcurrentAvailabilityBool++;\r\n\t\t\t\t\t\tif(currentAvailabilityBool >= toursInTheWeek){\r\n\t\t\t\t\t\t\tcurrentAvailabilityBool = 0; //Time to reset it.\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}//For j\r\n\t\t}//For i\r\n\t\t//Check if minToursPerGuide has been met.\r\n\t\tif(!checkMinToursPerGuide(minToursPerGuideInt)){\r\n\t\t\tSystem.out.println(\"Min tours per guide not met\");\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\treturn true; //It worked!\r\n\t}",
"public Task(int i, int R){\n\n\t\ttasknum = i;\n\t\tallocation = new ArrayList<Integer>();\n\n\t\tfor(int j = 0; j < R; j++){\n\n\t\t\tallocation.add(0);\n\t\t\tclaims.add(0);\n\t\t}\n\t}",
"public Sim sim()\n { if(!this.isEmptyStepList()) //non-empty StepList the weight is not 0\n { double lwb=increase()/weight();\n double upb=1-decrease()/weight();\n //System.out.println(\"weight()=\"+weight());\n //System.out.println(\"[\"+lwb+\",\"+upb+\"]\");\n return new Sim(lwb, upb);\n }\n else return new Sim(0.0,0.0);\n }",
"int getMin() \n\t{ \n\t\tint x = min.pop(); \n\t\tmin.push(x); \n\t\treturn x; \n\t}",
"public Builder clearScheduling() {\n \n scheduling_ = 0;\n onChanged();\n return this;\n }",
"private void removeFromSavedScheduleList() {\n if (!yesNoQuestion(\"This will print every schedule, are you sure? \")) {\n return;\n }\n\n showAllSchedules(scheduleList.getScheduleList());\n\n System.out.println(\"What is the number of the one you want to remove?\");\n int removeIndex = obtainIntSafely(1, scheduleList.getScheduleList().size(), \"Number out of bounds\");\n scheduleList.getScheduleList().remove(removeIndex - 1);\n System.out.println(\"Removed!\");\n }",
"void makeNborLists(){\n\t\t\tfor (int i = 0; i < N; i++){\n\t\t\t\tint ct = 0;\n\t\t\t\tint boundsCt = 0;\n\t\t\t\tfor (int j = 0; j < maxNbors; j++){\n\t\t\t\t\tint nborSite = nborList[i][j];\n\t\t\t\t\tif(nborSite>=1){\n\t\t\t\t\t\tif (aliveLattice[nborSite]){\n\t\t\t\t\t\t\tct += 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t}else{\n\t\t\t\t\t\tboundsCt += 1;\n\t\t\t\t\t}\n\t\t\t\t\tint noDead = maxNbors - ct;\n\t\t\t\t\tfracDeadNbors[i] = (double)noDead/maxNbors;\n\t\t\t\t\tif(deadDissipation==true) noNborsForSite[i] = noNbors; \n\t\t\t\t\telse if (deadDissipation==false){\n\t\t\t\t\t\tif(boundaryConditions==\"Open\")\n\t\t\t\t\t\t\tnoNborsForSite[i]=ct+boundsCt;\n\t\t\t\t\t\telse if(boundaryConditions == \"Periodic\")\n\t\t\t\t\t\t\tnoNborsForSite[i]=ct;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(deadDissipation==true){\n\t\t\t\tfor (int i = 0; i < N; i++)\tnoNborsForSite[i] = noNbors; \n\t\t\t\tfor (int i = 0; i < N; i++){\n\t\t\t\t\tint ct = 0;\n\t\t\t\t\tfor (int j = 0; j < maxNbors; j++){\n\t\t\t\t\t\tif (aliveLattice[nborList[i][j]]){\n\t\t\t\t\t\t\tct += 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tint noDead = maxNbors - ct;\n\t\t\t\t\t\tfracDeadNbors[i] = (double)noDead/maxNbors;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}else if (deadDissipation==false){\n\t\t\t\tfor (int i = 0; i < N; i++){\n\t\t\t\t\tint ct = 0;\n\t\t\t\t\tfor (int j = 0; j < maxNbors; j++){\n\t\t\t\t\t\tif (aliveLattice[nborList[i][j]]){\n\t\t\t\t\t\t\tct += 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tint noDead = maxNbors - ct;\n\t\t\t\t\t\tfracDeadNbors[i] = (double)noDead/maxNbors;\n\t\t\t\t\t\tnoNborsForSite[i]=ct;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t}",
"public void creationSable(){\n\t\tfor(int x=2;x<=this.taille-3;x++) {\n\t\tfor(int y=2;y<=this.taille-3;y++) {\n\t\tif( grille.get(x).get(y).getTypeOccupation()==0 &&\n\t\t\t\tgrille.get(x+2).get(y).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x+2).get(y+2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x).get(y+2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x-2).get(y+2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x-2).get(y).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x-2).get(y-2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x).get(y-2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x+2).get(y-2).getTypeOccupation()!=3 ) {\n\t\t\t\n\t\t\tint[] coord = new int[2];\n\t\t\tcoord[0]=x;\n\t\t\tcoord[1]=y;\n\t\t\tSable sable = new Sable(coord);\n\t\t\tgrille.get(x).set(y, sable);\n\t\t}\n\t\t}\n\t\t}\n\t}",
"static Tour sequence() {\r\n\t\tTour tr = new Tour();\r\n\t\tfor (int i = 0; i < tr.length(); i++) {\r\n\t\t\ttr.index[i] = i;\r\n\t\t}\r\n\t\ttr.distance = tr.distance();\r\n\t\treturn tr;\r\n\t}",
"public void monteCarlo(BlackHoleBoard currentBoard){\n if(currentBoard.getBoardDepth() < (currentBoard.getGameDepth() - THRESHOLD)){\n HashMap<Integer,Integer> mapNextMovetoScore = new HashMap<>();//map first move to final outcome\n for(int i = 0; i < BlackHoleBoard.NUM_GAMES_TO_SIMULATE; i++){\n //ArrayList<Integer> currentIndices = new ArrayList<>();\n int finalScore = 0;\n BlackHoleBoard currentWorkingBoard = new BlackHoleBoard();\n currentWorkingBoard.copyBoardState(currentBoard);\n int score = 0;\n int index = currentWorkingBoard.pickRandomMove();\n while(!currentWorkingBoard.gameOver()){\n //int index = currentWorkingBoard.pickRandomMove();\n\n currentWorkingBoard.setValue(index);\n index = currentWorkingBoard.pickRandomMove();\n\n\n }\n if(currentWorkingBoard.gameOver()){\n score = currentWorkingBoard.getScore();\n }\n mapNextMovetoScore.put(index,score);\n }\n int minScore = 0;\n int indexWithMinScore = 0;\n for(int key: mapNextMovetoScore.keySet()){\n if(mapNextMovetoScore.get(key) < minScore){\n minScore = mapNextMovetoScore.get(key);\n indexWithMinScore = key;\n }\n }\n //ArrayList<Integer> reccomendedMoves = mapNextMovetoScore.get(minScore);\n nextMove = indexWithMinScore;\n }else {\n nextMove = -1;\n }\n }",
"public MinStack() {\n capacity = 1 << 4;\n nums = new int[capacity];\n mins = new int[capacity];\n }",
"private void CreatingBeautyContent(int count,int typeSymmetry, int methodSearch) {\n\t\t\tConstraintsPlacement objConstraints= new ConstraintsPlacement(this);\r\n\t\t\t//Creating array with states\r\n\t\t\tArrayList<BlockNode> states = new ArrayList<BlockNode>();\r\n\t\t\t//Building the graph in a deph way\r\n\t \tGraphBuilder objGrapB= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB2= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB3= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB3a= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB4= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB5= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB6= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB7= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB8= new GraphBuilder(1);\r\n\t \t\r\n\t \tobjGrapB.setWparamether(wParamether);\r\n\t \tobjGrapB2.setWparamether(wParamether);\r\n\t \tobjGrapB3.setWparamether(wParamether);\r\n\t \tobjGrapB3a.setWparamether(wParamether);\r\n\t \tobjGrapB4.setWparamether(wParamether);\r\n\t \tobjGrapB5.setWparamether(wParamether);\r\n\t \tobjGrapB6.setWparamether(wParamether);\r\n\t \tobjGrapB7.setWparamether(wParamether);\r\n\t \tobjGrapB8.setWparamether(wParamether);\r\n\t \t\r\n\t \tint numElements=objElem.getNumberObjects();\r\n\t \tint numEnemies=objElem.getNumberObjectsEnemies();\r\n\t \tint globalControlSearch=0;\r\n\t \t\r\n\t \tdouble time6=0;\r\n\t \tdouble time7=0;\r\n\t \tdouble time3=0;\r\n\t \tdouble time4=0;\r\n\t \tdouble time5=0;\r\n\t \tdouble time8=0;\r\n\t \t\r\n\t \tdouble startTime=0;\r\n\t \tdouble stopTime=0;\r\n\t \t\r\n\t \tdouble sum3=0;\r\n\t \tdouble sum4=0;\r\n\t \tdouble sum5=0;\r\n\t \tdouble sum6=0;\r\n\t \tdouble sum7=0;\r\n\t \tdouble sum8=0;\r\n\r\n\t \t\r\n\t \t//Beststates=objGrapB.basicDepthSearch(mediumStraight,height,numElements,numElements,states,objConstraints, objElem.getFinalList(),objElem);\r\n\t \t//Beststates=objGrapB.relativePositionDepthSearch(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,-mediumStraight+2,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch);\r\n\t \t//Beststates=objGrapB.relativeTransPositionDepthSearch(mediumStraight,height,numElements,numElements,states,objConstraints, objElem.getFinalList(),objElem,-mediumStraight+1,mediumStraight-1,floorTileHeight,0,0,currentState,hTable);\r\n\t \t//Beststates=objGrapB.DepthSearchCenterFrame(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,1,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch);\r\n\t \t//Beststates=objGrapB.DepthSearchPruningAlt(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,1,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch);\r\n\t \t\r\n\t \r\n\r\n\t \r\n\t //3.3) Brute-force search\r\n\t //objElem.setFinalList(objElem.getFinalListNoOrder());\r\n\t \tfor(int i=0;i<1;i++)\r\n\t \t{\r\n\t \t\tstartTime = System.currentTimeMillis();\r\n\t \t\tBeststates3=objGrapB3.DepthSearchCenterFrameNoPruningNoRegionsNoObjects(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,0,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch,8,typeSymmetry);\r\n\t \t\tstopTime = System.currentTimeMillis();\r\n\t \t\ttime3 = stopTime - startTime;\r\n//\t \t\tround(time3,2);\r\n//\t \t\tdouble nodes3=round((double)objGrapB3.getCounterIDs(),2);\r\n//\t \t\tSystem.out.println(objGrapB3.bestSymmetryV+\" \"+time3+\" \"+((objGrapB3.getCounterIDs())));\r\n\t \t\tsum3=sum3+time3;\r\n\t \t}\r\n\t \ttime3=sum3/1;\r\n\t \ttime3=round(time3,2);\r\n\t //System.out.println(\"Time Brute-force search \"+elapsedTime);\r\n\t \t\r\n\t \r\n\t \r\n\t //3.7) B&B+heuristic\r\n\t //objElem.setFinalList(objElem.getFinalListNoOrder());\r\n\t \tfor(int i=0;i<1;i++)\r\n\t \t{\r\n\t \t\tstartTime = System.currentTimeMillis();\r\n\t \t\tBeststates7=objGrapB7.depthSearchBBHeuristic(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,0,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch,8,typeSymmetry);\r\n\t \t\tstopTime = System.currentTimeMillis();\r\n\t \t\ttime7 = stopTime - startTime;\r\n//\t \t\tround(time7,2);\r\n//\t \t\tdouble nodes7=round((double)objGrapB3.getCounterIDs(),2);\r\n//\t \t\tSystem.out.println(objGrapB6.bestSymmetryV+\" \"+time6+\" \"+((objGrapB6.getCounterIDs())));\r\n\t \t\tsum7=sum7+time7;\r\n\t \t}\r\n\t \ttime7=sum7/1;\r\n\t \ttime7=round(time7,2);\r\n\t //System.out.println(\"Time B&B+heuristic + region ordering \"+elapsedTime);\r\n\t \t\r\n\t \t\r\n\t \t\r\n//\t \tif(objGrapB3.bestSymmetryV<objGrapB5.bestSymmetryV)\r\n//\t \t{\r\n//\t \t\tdouble bestSYmmetry=objGrapB3.bestSymmetryV;\r\n//\t \t\t//System.out.println(\"bestSym \"+bestSYmmetry);\r\n//\t \t\tBestGlobalstates=Beststates3;\r\n//\t \t\t\r\n//\t \t}\r\n//\t \telse\r\n//\t \t{\r\n//\t \t\tdouble bestSYmmetry=objGrapB5.bestSymmetryV;\r\n//\t \t\t//System.out.println(\"bestSym \"+bestSYmmetry);\r\n//\t \t\tBestGlobalstates=Beststates5;\r\n//\t \t}\r\n\t \t\r\n\t \tBestGlobalstates=Beststates7;\r\n\t \r\n\t \r\n\t \t//**System.out.println(\"Simetry 0-> Brute-force search order \"+objGrapB3a.bestSymmetryV);\t\r\n\t \t//System.out.println(\"Simetry 1-> Brute-force search \"+objGrapB3.bestSymmetryV);\t \t\r\n\t \t//System.out.println(\"Simetry 2-> B&B+oldheuristic \"+objGrapB4.bestSymmetryV);\r\n\t \t//**System.out.println(\"Simetry 3-> B&B+heuristic + object ordering \"+objGrapB2.bestSymmetryV);\t \t\r\n\t \t//System.out.println(\"Simetry 4-> B&B+ region + leviheuristic\"+objGrapB5.bestSymmetryV);\r\n\t \t//**System.out.println(\"Simetry 5-> B&B+heuristic + region ordering + object ordering \"+objGrapB.bestSymmetryV);\r\n\t \t//System.out.println(\"Simetry 6-> B&B+heuristic + leviheuristic \"+objGrapB6.bestSymmetryV);\r\n\t \t//System.out.println(\"Simetry 7-> B&B+oldoldheuristic \"+objGrapB7.bestSymmetryV);\r\n\t \t\r\n\t \t//**System.out.println( \"States 0 \"+objGrapB3a.getCounterIDs() );\r\n\t \t//System.out.println( \"States 1 \"+objGrapB3.getCounterIDs() );\r\n\t \t//System.out.println( \"States 2 \"+objGrapB4.getCounterIDs() );\r\n\t \t//**System.out.println( \"States 3 \"+objGrapB2.getCounterIDs() );\t \t\t \t\r\n\t \t//System.out.println( \"States 4 \"+objGrapB5.getCounterIDs() );\r\n\t \t//**System.out.println( \"States 5 \"+objGrapB.getCounterIDs() );\r\n\t \t//System.out.println( \"States 6 \"+objGrapB6.getCounterIDs() );\r\n\t \t//System.out.println( \"States 7 \"+objGrapB7.getCounterIDs() );\r\n\t \t\r\n\t \tdouble TimeRate7=time3/time7;\r\n\t \tdouble TimeRate6=time3/time6;\r\n\t \tdouble TimeRate5=time3/time5;\r\n\t \t\r\n\t \tTimeRate7=round(TimeRate7,2);\r\n\t \tTimeRate6=round(TimeRate6,2);\r\n\t \tTimeRate5=round(TimeRate5,2);\r\n\t \t\r\n\t \tdouble NodesRate7=(double)objGrapB3.getCounterIDs()/(double)objGrapB7.getCounterIDs();\r\n\t \tdouble NodesRate6=(double)objGrapB3.getCounterIDs()/(double)objGrapB6.getCounterIDs();\r\n\t \tdouble NodesRate5=(double)objGrapB3.getCounterIDs()/(double)objGrapB5.getCounterIDs();\r\n\t \t\r\n\t \tNodesRate7=round(NodesRate7,2);\r\n\t \tNodesRate6=round(NodesRate6,2);\r\n\t \tNodesRate5=round(NodesRate5,2);\r\n\r\n\t \t\r\n\t \t\r\n\r\n\t //imprimiendo los estados visitados\r\n\t /*\r\n\t Iterator<BlockNode> nombreIterator = states.iterator();\r\n\t while(nombreIterator.hasNext()){\r\n\t \tBlockNode elemento = nombreIterator.next();\r\n\t \tSystem.out.print(elemento.getID()+\" / \");\r\n\t }*/\r\n\t \r\n\t //here we are painting as the best branch founded\r\n\t \r\n\t //System.out.println(\"nene \"+BestGlobalstates.size());\r\n\t Iterator<BlockNode> nombreIterator = BestGlobalstates.iterator();\r\n\t while(nombreIterator.hasNext()){\r\n\t \tBlockNode elemento = nombreIterator.next();\r\n\t \t//System.out.print(elemento.getID()+\"(\"+elemento.getX()+\" \"+elemento.getY()+\" ) - \"+elemento.getType()+\" \"+elemento.getIdElement()+ \" / \");\r\n\t }\r\n\t \r\n\t \r\n\t //Here we will put the elements on the tile\r\n\t try {\r\n\t Level levelScreen=PaintElements(BestGlobalstates,this);\r\n\t Screen objScreen=new Screen();\r\n\t\t\tobjScreen.SaveScreen(levelScreen,odds,objElem);\r\n \t\tInformacoesTelas info = new InformacoesTelas();\r\n\t CopiaArquivos copiador = new CopiaArquivos();\r\n\t \r\n\t info = info.carregaInfoTela(\"infoTela\");\r\n\t\t\tinfo.setOutrasVariaveis(0, 0); // Salva outras informacoes da Tela\r\n\t\t\tinfo.salvaInfoTela(\"infoTela\", info);\t\t\t\t\t\r\n\t\t\tcopiador.copy(\"\" + count, \"Screens/\");\r\n\t\t\t\r\n\t } catch (ClassNotFoundException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t} catch (IOException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t}",
"public int[] mRtreeFromSource(int s,int k){\n double INFINITY = Double.MAX_VALUE;\n boolean[] SPT = new boolean[intersection];\n double[] d = new double[intersection];\n int[] parent = new int[intersection];\n\n for (int i = 0; i <intersection ; i++) {\n d[i] = INFINITY;\n parent[i] = -1;\n }\n\n d[s] = 0;\n parent[s]=s;\n\n MinHeap minHeap = new MinHeap(k);\n for (int i = 0; i <intersection ; i++) {\n minHeap.add(i,d[i]);\n }\n while(!minHeap.isEmpty()){\n\n int extractedVertex = minHeap.extractMin();\n\n if(d[extractedVertex]==INFINITY)\n break;\n\n SPT[extractedVertex] = true;\n\n LinkedList<Edge> list = g.adjacencylist[extractedVertex];\n for (int i = 0; i <list.size() ; i++) {\n Edge edge = list.get(i);\n int destination = edge.destination;\n if(SPT[destination]==false ) {\n\n double newKey = edge.weight ; //the different part with previous method\n double currentKey = d[destination];\n if(currentKey>=newKey){\n if(currentKey==newKey){\n if(extractedVertex<parent[destination]){\n minHeap.updateKey(newKey, destination, d[destination]);\n parent[destination] = extractedVertex;\n d[destination] = newKey;\n }\n }\n else {\n minHeap.updateKey(newKey, destination, d[destination]);\n parent[destination] = extractedVertex;\n d[destination] = newKey;\n }\n }\n }\n }\n }\n return parent;\n }",
"public void setRemainingToScenery(){\n\t\tfor(int i=0;i<grid.length;i++){\n\t\t\tfor(int j=0;j<grid[0].length;j++){\n\t\t\t\tif(grid[i][j]==null)\n\t\t\t\t\tgrid[i][j]=new Scenery(i*grid[0].length+j);\n\t\t\t}\n\t\t}\n\t}",
"public Schedule() {\n\t\tcourses = new ArrayList<Course>();\n\t}",
"public QwirkleSpiel()\n {\n beutel=new Beutel(3); //erzeuge Beutel mit 3 Steinfamilien\n spielfeld=new List<Stein>();\n\n rote=new ArrayList<Stein>(); //Unterlisten, die zum leichteren Durchsuchen des Spielfelds angelegt werden\n blaue=new ArrayList<Stein>();\n gruene=new ArrayList<Stein>();\n gelbe=new ArrayList<Stein>();\n violette=new ArrayList<Stein>();\n orangene=new ArrayList<Stein>();\n kreise=new ArrayList<Stein>();\n kleeblaetter=new ArrayList<Stein>();\n quadrate=new ArrayList<Stein>();\n karos=new ArrayList<Stein>();\n kreuze=new ArrayList<Stein>();\n sterne=new ArrayList<Stein>();\n\n erstelleListenMap();\n }",
"public void setSchedule(Schedule newSchedule) {\n\n schedule = newSchedule;\n }",
"public synchronized long getSlots() {\n return slots;\n }",
"private IScope getTrainScope(TrainSchedule trainSchedule) {\n\t\tEObject rootElement = EcoreUtil.getRootContainer(trainSchedule);\r\n\r\n\t\tif (rootElement instanceof Schedule) {\r\n\t\t\tSchedule schedule = (Schedule) rootElement;\r\n\r\n\t\t\tList<Train> trains = schedule.getDepots().stream().flatMap(d -> d.getTrains().stream())\r\n\t\t\t\t\t.collect(Collectors.toList());\r\n\t\t\treturn Scopes.scopeFor(trains);\r\n\t\t}\r\n\r\n\t\treturn null;\r\n\t}",
"public void arrivesAtTestSTation() throws InterruptedException {\n int max = 5;\n int min = 1;\n int range = max - min + 1;\n\n long time = System.currentTimeMillis();\n long timeTo = System.currentTimeMillis() + 7200;\n while(time <= timeTo){\n Thread.sleep(Times.calculateTimeDistributionForArrivingAtTheCarStation());\n int res = (int) ( Math.random()*range)+min;\n Car c = new Car(res);\n personsInCar += c.getNumberOfPassengers();\n carGenerated++;\n if(carQueue.size() >= Times.carQueueSize) {\n if(Times.enableDebugging)\n System.out.println(\"0. Car queue is to hight and needs to leave: \" + c.getIdentifier().getCarId() );\n carLeftLaneSinceItIsFull++;\n }else {\n c.setArrivesAtTestStation(true);\n c.setStartsWaiting(System.currentTimeMillis());\n c.setCurrentStation(\"Arrives Test Station\");\n synchronized (carQueue){\n carQueue.add(c);}\n // Collections.sort(carQueue);\n if(Times.enableDebugging)\n System.out.println(\"1. Arrives at the Teststation: \" + c.getIdentifier().getCarId() );\n }\n time = System.currentTimeMillis();\n }\n }",
"public Schedule getSchedule() {\n\n return schedule;\n }",
"void initFirstTower() {\n for (int i = 0; i < numDisks; i++) {\n towers[0].push(numDisks - i + 1);\n }\n }",
"private JCStatement makeInvalidateSize() {\n // Initialize the singleton synthetic item vars (during IS_VALID phase)\n // Bound sequences don't have a value\n ListBuffer<JCStatement> stmts = ListBuffer.lb();\n for (int i = 0; i < length; ++i) {\n if (!isSequence(i)) {\n stmts.append(SetStmt(vsym(i), CallGetter(i)));\n }\n }\n JCStatement varInits = Block(stmts);\n \n return\n Block(\n If(IsTriggerPhase(),\n setSequenceValid(),\n varInits\n ),\n SetStmt(sizeSymbol, cummulativeSize(length)),\n CallSeqInvalidate(Int(0), Int(0), Get(sizeSymbol))\n );\n }",
"private void LeastMoviableItem() {\n DefaultTableModel dtm=(DefaultTableModel) leastmoviableitemtable.getModel();\n ArrayList<MoviableItem> findleastmoviableitem;\n try {\n findleastmoviableitem = LeastMoviableItemController.findleastmoviableitem();\n for (MoviableItem moviableItem : findleastmoviableitem) {\n Object[]rowdata={moviableItem.getItemcode(),moviableItem.getDescription(),moviableItem.getSalse()}; \n dtm.addRow(rowdata);\n }\n } catch (ClassNotFoundException | SQLException ex) {\n JOptionPane.showMessageDialog(null, ex.getMessage());\n }\n \n\n }",
"public void WorkloadBasedOnlineCostOptimizationWithDoubleCopy() {\n\t\t\n\t \tinitialParameters();\n\t\tint inputObjectsNumber=0;\n\t\tint indexJ=0;\n\t\t\n\t\tint keepTime=0;// This variable indicates how long an object is stayed in the hot-tier\n\t\tint currentTime=0; // This variable indicates the passing time in the simulation\n\t\t\n\t for (int slot = 0; slot < workloadGenerator.numberObjectsPerSlot.length; slot++) {\n\t\tinputObjectsNumber=inputObjectsNumber+workloadGenerator.numberObjectsPerSlot[slot];\n\t\t\n\t\tfor (int j = indexJ; j < inputObjectsNumber; j++) {\n\t\t\t\n\t\t\tfor (int t=0; t<T; t++ ){\n\t\t\t\t\n\t\t\t\tcurrentTime=t;\n\t\t\t\tif(existRequest(j, t)){\n\t\t\t\t\tbreakPointEvaluation(j, t);\n\t\t\t\t\talphaCalculation();\n\t\t\t\t\t\n\t\t\t\t\tif(finalLocation[j][t]==1){\n\t\t\t\t\t\n\t\t\t\t\t for (keepTime = currentTime; keepTime < currentTime+alpha*(breakPoint); keepTime++) {\n\t\t\t\t\t\t finalLocation[j][t]=1;\n\t\t\t\t\t }\n\t\t\t\t\t}else if(residentialLatencyCost(j, t, 0).compareTo(residentialLatencyCost(j, t,1).add(totalCostCalculation.btotalMigrationCost[t][j][0][1]))==1){\n\t\t\t\t\t\tfinalLocation[j][t]=1;\n\t\t\t\t\t}\n\t\t\t\t}// FIRST IF\n\t\t\t} \t\n\t\t}//For t\n\t\tindexJ=inputObjectsNumber;\n\t }//slot\n\t \n\t /*\n\t for (int obj = 0; obj < finalLocation.length; obj++) {\n\t\t for (int time = 0; time < finalLocation[obj].length; time++) {\n\t\t System.out.print(finalLocation[obj][time]+\" \");\n\t\t \n\t\t \n\t\t }\n\t }\n\t */\n\t \n}",
"public WaitingCell(int i,int rtw) {\n\t\tsuper(i);\n\t\tthis.roundsToWait = rtw;\n\t\tthis.roundsWaited = 0;\n\t}",
"private void generateDefaultTimeSlots() {\n\t\tLocalTime startTime = LocalTime.of(9, 0); // 9AM start time\n\t\tLocalTime endTime = LocalTime.of(19, 0); // 5PM end time\n\n\t\tfor (int i = 1; i <= 7; i++) {\n\t\t\tList<Timeslot> timeSlots = new ArrayList<>();\n\t\t\tLocalTime currentTime = startTime.plusMinutes(15);\n\t\t\twhile (currentTime.isBefore(endTime) && currentTime.isAfter(startTime)) {\n\t\t\t\tTimeslot newSlot = new Timeslot();\n\t\t\t\tnewSlot.setTime(currentTime);\n\t\t\t\tnewSlot = timeslotRepository.save(newSlot);\n\t\t\t\ttimeSlots.add(newSlot);\n\t\t\t\tcurrentTime = currentTime.plusHours(1); // new slot after one hour\n\t\t\t}\n\t\t\tDay newDay = new Day();\n\t\t\tnewDay.setTs(timeSlots);\n\t\t\tnewDay.setDayOfWeek(DayOfWeek.of(i));\n\t\t\tdayRepository.save(newDay);\n\t\t}\n\t}",
"abstract public void computeSchedule();",
"public SpaceSchedule getSchedule() {\n\t\treturn null;\n\t}"
] | [
"0.5668172",
"0.5568091",
"0.5549635",
"0.54582894",
"0.53865564",
"0.5327895",
"0.5224997",
"0.5177688",
"0.5175095",
"0.51612663",
"0.5139494",
"0.5061209",
"0.5061086",
"0.5057539",
"0.50447965",
"0.5015928",
"0.5014814",
"0.50116503",
"0.5007716",
"0.49971458",
"0.49782825",
"0.49579105",
"0.4954103",
"0.49309742",
"0.49224293",
"0.49116206",
"0.4908644",
"0.49063703",
"0.4895238",
"0.48809797",
"0.48578513",
"0.48570698",
"0.48548427",
"0.4853313",
"0.48449853",
"0.48448732",
"0.48416573",
"0.48383972",
"0.48184732",
"0.48166335",
"0.47981736",
"0.47776455",
"0.47741297",
"0.4773595",
"0.4769504",
"0.4768416",
"0.47674033",
"0.4753506",
"0.47457588",
"0.4735342",
"0.47339165",
"0.47323734",
"0.47308916",
"0.47299844",
"0.47291812",
"0.47291744",
"0.4726588",
"0.4723729",
"0.47199687",
"0.4717882",
"0.47051784",
"0.47023594",
"0.46981955",
"0.46968102",
"0.46915007",
"0.46900165",
"0.46811536",
"0.46786192",
"0.4677941",
"0.4675179",
"0.4674197",
"0.46736035",
"0.46723655",
"0.46631455",
"0.46619904",
"0.46604946",
"0.4656999",
"0.46509793",
"0.46493706",
"0.4648524",
"0.4646603",
"0.46455783",
"0.4644563",
"0.4641546",
"0.46383682",
"0.46319088",
"0.46267402",
"0.46256354",
"0.46228614",
"0.4620711",
"0.462033",
"0.46195084",
"0.46132195",
"0.46127605",
"0.46065328",
"0.46050242",
"0.46045324",
"0.46044967",
"0.46022457",
"0.46013287",
"0.4598888"
] | 0.0 | -1 |
int minMakespan = 0; RKSchedule r = S.get(i).copyOf(); | public static rk getBestSolutionMin(ArrayList<rk> Sched) {
rk best = Sched.get(0).copyOf();
for (int i = 1; i < Sched.size(); i++) {
rk S = Sched.get(i).copyOf();
if (S.getFitness() < best.getFitness()) {
best = S;
}
}
return best;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void initialize(){\n// Schedule initializeList1, initializeList2, initializeList3, initializeList4,initializeList5,\n// initializeList6,initializeList7,initializeList8,initializeList9,\n// initializeList10,initializeList11,initializeList12,initializeList13,\n// initializeList14,initializeList15,initializeList16,initializeList17,\n// initializeList18,initializeList19,initializeList20,initializeList21,initializeList22;\n// initializeList1= new Schedule(\"A001\",\"LimKH\", 1629,\"A01\", \"pewdiepie\", \"0162313212\", \"Delivering\",\"5min\");\n// initializeList2= new Schedule(\"A002\",\"LimKW\", 1111,\"A02\", \"MsTingTT\", \"012432434\", \"Delivering\",\"5min\");\n// initializeList3= new Schedule(\"A003\",\"LowSK\",3456, \"A03\", \"AhLiao\", \"01312321213\", \"Delivering\",\"5min\");\n// initializeList4= new Schedule(\"A004\",\"NgWD\",9909, \"A04\", \"Kazuma\", \"015213797\", \"Delivering\",\"5min\"); \n// initializeList5= new Schedule(\"A005\",\"LooJW\",1233,\"A05\",\"Kalima\",\"01124356\",\"Delivering\",\"5min\");\n// initializeList6= new Schedule(\"A006\",\"LimJJ\",1012,\"A06\", \"LeongFoei\", \"01239909\", \"Delivering\",\"5min\");\n// initializeList7= new Schedule(\"A007\",\"MahHW\",3757,\"A07\",\"KongKong\",\"012283747\",\"Delivering\",\"5min\");\n// initializeList8= new Schedule(\"A008\",\"LoiKH\",9610,\"A08\",\"MigMing\",\"012636383\",\"Delivering\",\"5min\"); \n// initializeList9= new Schedule(\"A009\",\"LimNF\",5566,\"A09\",\"MsTing\",\"0192726363\",\"Delivering\",\"5min\");\n// initializeList10= new Schedule(\"A010\",\"LohKC\",6969,\"A10\",\"KitKat\",\"017265353\",\"Delivering\",\"5min\");\n// \n// initializeList11= new Schedule(\"A011\",\"LimKH\", 1629,\"A11\", \"Kari\", \"012213778\", \"Delivering\",\"5min\");\n// initializeList12= new Schedule(\"A012\",\"LimKW\", 1111,\"A12\", \"Yolo\", \"0162328212\", \"Delivering\",\"5min\");\n// initializeList13= new Schedule(\"A013\",\"LowSK\", 3456,\"A13\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList14= new Schedule(\"A015\",\"LowSK\", 3456,\"A14\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList15= new Schedule(\"A016\",\"LooJW\", 1233,\"A15\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList16= new Schedule(\"A017\",\"LimJJ\", 1012,\"A16\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList17= new Schedule(\"A018\",\"LimJJ\", 1012,\"A17\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList18= new Schedule(\"A019\",\"LoiKH\", 9610,\"A18\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList19= new Schedule(\"A020\",\"LimNF\", 5566,\"A19\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// initializeList20= new Schedule(\"A021\",\"LimNF\", 5566,\"A20\", \"Hahaha\", \"0198377213\", \"Delivering\",\"5min\");\n// \n// //completed jobs\n// initializeList21= new Schedule(\"A022\",\"LimKH\", 1629,\"A21\", \"Doggo\", \"0198377213\", \"Completed\",\"5min\");\n// initializeList22= new Schedule(\"A023\",\"LimKH\", 1629,\"A22\", \"Cloud\", \"0198377213\", \"Completed\",\"5min\");\n// scheduleList.addSchedule(initializeList1);\n// scheduleList.addSchedule(initializeList2);\n// scheduleList.addSchedule(initializeList3);\n// scheduleList.addSchedule(initializeList4);\n// scheduleList.addSchedule(initializeList5);\n// scheduleList.addSchedule(initializeList6);\n// scheduleList.addSchedule(initializeList7);\n// scheduleList.addSchedule(initializeList8);\n// scheduleList.addSchedule(initializeList9);\n// scheduleList.addSchedule(initializeList10);\n// scheduleList.addSchedule(initializeList11);\n// scheduleList.addSchedule(initializeList12);\n// scheduleList.addSchedule(initializeList13);\n// scheduleList.addSchedule(initializeList14);\n// scheduleList.addSchedule(initializeList15);\n// scheduleList.addSchedule(initializeList16);\n// scheduleList.addSchedule(initializeList17); \n// scheduleList.addSchedule(initializeList18);\n// scheduleList.addSchedule(initializeList19);\n// scheduleList.addSchedule(initializeList20);\n// scheduleList.addSchedule(initializeList21);\n// scheduleList.addSchedule(initializeList22);\n \n \n\n for(int i = 0; i<scheduleList.getNumberOfSchedule();i++){\n int staff = scheduleList.getSchedule(i).getStaffID();\n jcbDeliveryman.addItem(staff);\n \n String order = scheduleList.getSchedule(i).getOrderID();\n jcbOrderNo.addItem(order);\n\n }\n \n \n// jcbDeliveryman.addActionListener(jcbOrderNo);\n// for(int i = 0; i<scheduleList.getNumberOfSchedule();i++){\n// jcbOrderNo.addItem(scheduleList.getSchedule(i).getOrderID());\n// }\n }",
"public Schedule getOptSchedule() \n\t{\n\t\tScheduledTask[] schedule = new ScheduledTask[tasks.length];\n\t\tbest = heuristicScheduling(); \n\t\trecursive(schedule, 0, new int[m]);\n\t\treturn best;\n\t}",
"public Reservation makeReservation(Reservation trailRes){\n //Using a for each loop to chekc to see if a reservation can be made or not\n if(trailRes.getName().equals(\"\")) {\n System.out.println(\"Not a valid name\");\n return null;\n }\n \n \n for(Reservation r: listR){\n if(trailRes.getReservationTime() == r.getReservationTime()){\n System.out.println(\"Could not make the Reservation\");\n System.out.println(\"Reservation has already been made by someone else\");\n return null;\n }\n }\n\n //if the time slot is greater than 10 or less than 0, the reservation cannot be made\n if(trailRes.getReservationTime() > 10 || trailRes.getReservationTime() < 0){\n System.out.println(\"Time slot not available\");\n return null;\n }\n\n //check to see if the reservable list is empty or not\n if(listI.isEmpty())\n {\n System.out.println(\"No reservation available\");\n return null;\n }\n\n //find the item and fitnessValue that will most fit our reservation\n Reservable item = listI.get(0);\n int fitnessValue = item.findFitnessValue(trailRes);\n\n //loop through the table list and find the best fit for our reservation\n for(int i = 0; i < listI.size() ; i++){\n if(listI.get(i).findFitnessValue(trailRes) > fitnessValue){\n item = listI.get(i);\n fitnessValue = item.findFitnessValue(trailRes);\n }\n }\n //if we have found a table that works, then we can make our reservation\n if(fitnessValue > 0){\n //add reservation to our internal list\n //point our reservable to the appropriate reservation\n //set the reservable \n //print out the message here not using the iterator\n listR.add(trailRes);\n item.addRes(trailRes);\n trailRes.setMyReservable(item);\n System.out.println(\"Reservation made for \" + trailRes.getName() + \" at time \" + trailRes.getReservationTime() + \", \" + item.getId());\n return trailRes;\n }\n System.out.println(\"No reservation available, number of people in party may be too large\");\n return null; \n }",
"public double getMakespan(){return makespan;}",
"private JNASchedule getFirstSchedule() {\n\t\tif (this.isDisposed()) {\n\t\t\tthrow new DominoException(0, \"Schedule collection has been disposed\");\n\t\t}\n\n\t\tDHANDLE hSchedules = getAllocations().getSchedulesHandle();\n\t\t\n\t\treturn LockUtil.lockHandle(hSchedules, (hSchedulesByVal) -> {\n\t\t\tIntByReference rethObj = new IntByReference();\n\t\t\tMemory schedulePtrMem = new Memory(Native.POINTER_SIZE);\n\n\t\t\tshort result = NotesCAPI.get().SchContainer_GetFirstSchedule(hSchedulesByVal, rethObj, schedulePtrMem);\n\t\t\tif (result == INotesErrorConstants.ERR_SCHOBJ_NOTEXIST) {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\tNotesErrorUtils.checkResult(result);\n\t\t\t\n\t\t\tif (rethObj.getValue()==0) {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\t\n\t\t\tlong peer = schedulePtrMem.getLong(0);\n\t\t\tif (peer==0) {\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\tPointer schedulePtr = new Pointer(peer);\n\t\t\tNotesScheduleStruct retpSchedule = NotesScheduleStruct.newInstance(schedulePtr);\n\t\t\tretpSchedule.read();\n\t\t\t\n\t\t\tint scheduleSize = JNANotesConstants.scheduleSize;\n\t\t\tif (PlatformUtils.isMac() && PlatformUtils.is64Bit()) {\n\t\t\t\t//on Mac/64, this structure is 4 byte aligned, other's are not\n\t\t\t\tint remainder = scheduleSize % 4;\n\t\t\t\tif (remainder > 0) {\n\t\t\t\t\tscheduleSize = 4 * (scheduleSize / 4) + 4;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tPointer pOwner = retpSchedule.getPointer().share(scheduleSize);\n\t\t\tString owner = NotesStringUtils.fromLMBCS(pOwner, (retpSchedule.wOwnerNameSize-1) & 0xffff);\n\t\t\t\n\t\t\treturn new JNASchedule(this, retpSchedule, owner, rethObj.getValue());\n\t\t});\n\t}",
"public ArrayList<ArrayList<Dog>> getVetSchedule() {\n\t\t\tint initialCapacity = 10;\r\n\t\t\tArrayList<ArrayList<Dog>> list = new ArrayList<ArrayList<Dog>>(initialCapacity); //list to put in lists of dogs\r\n\t\t\t//intialize ArrayList with size ArrayList\r\n\t\t\tlist.add(new ArrayList<Dog>());\r\n\t\t\t/*for(int i=0; i<=10; i++){\r\n\t\t\t\tlist.add(new ArrayList<Dog>());\r\n\t\t\t}\r\n\t\t\t*/\r\n\t\t\tDogShelterIterator iterator = new DogShelterIterator();\r\n\t\t\twhile(iterator.hasNext()){\r\n\t\t\t\tDog nextDog = iterator.next();\r\n\t\t\t\tint index = nextDog.getDaysToNextVetAppointment()/7;\r\n\t\t\t\tif(index < list.size())list.get(index).add(nextDog);\r\n\t\t\t\telse{\r\n\t\t\t\t\t//index out of range --> create larger list\r\n\t\t\t\t\tArrayList<ArrayList<Dog>> newList = new ArrayList<ArrayList<Dog>>(index+1);\r\n\t\t\t\t\tnewList.addAll(list); //add all lists from the old list\r\n\t\t\t\t\tfor(int i=0; i<(index+1)-list.size(); i++){ //initialize the other half with new ArrayLists\r\n\t\t\t\t\t\tnewList.add(new ArrayList<Dog>());\r\n\t\t\t\t\t}\r\n\t\t\t\t\tlist = newList; //update list to the larger newList\r\n\t\t\t\t\tlist.get(index).add(nextDog);\r\n\t\t\t\t}\r\n\t\t\t}\r\n return list;\r\n\t\t}",
"public static int minimumNumberOfTimeSlots()\n {\n return 0;\n }",
"public void updateMakeSpan2() {\r\n // making a copy of particle before sorting\r\n List<Operation> copy = new ArrayList<>(particle.length);\r\n for (int jobIdx = 0; jobIdx < particle.length; jobIdx++) {\r\n copy.add(particle[jobIdx]);\r\n }\r\n Collections.sort(copy);\r\n\r\n // lastOperation keeps track of last time a machine is executing each job\r\n int[] lastOperation = new int[LookupTable.numberOfJobs];\r\n // machineNumber keeps track of the current machineNumber doing the specified job\r\n int[] machineNumber = new int[LookupTable.numberOfJobs];\r\n\r\n for (int i = 0; i < LookupTable.numberOfJobs; i++) lastOperation[i] = -1;\r\n\r\n // machineDurations keeps track of the time used to execute all jobs for each machine\r\n int[] machineDurations = new int[LookupTable.numberOfMachines];\r\n\r\n for (Operation o : copy) {\r\n int jobId = o.jobId;\r\n int machineId = LookupTable.jobOrder[jobId][machineNumber[jobId]++];\r\n\r\n // the end time of that job on another machine (possible start time for this job)\r\n int startTime = lastOperation[jobId];\r\n\r\n if (startTime > machineDurations[machineId]) {\r\n machineDurations[machineId] = startTime + LookupTable.durations[o.jobId][machineId];\r\n } else {\r\n machineDurations[machineId] += LookupTable.durations[o.jobId][machineId];\r\n }\r\n if (machineDurations[machineId] > lastOperation[o.jobId]) {\r\n lastOperation[o.jobId] = machineDurations[machineId];\r\n }\r\n }\r\n // update makespan\r\n makespan = 0;\r\n for (int duration : machineDurations) {\r\n if (duration > makespan) {\r\n makespan = duration;\r\n }\r\n }\r\n }",
"public ArrayList<int[]> getSchedule(){\n // Initialize the output list\n ArrayList<int[]> schedule = new ArrayList<>();\n\n // Initialize a list of tuples in the form (rally id, rally duration, rally deadline)\n ArrayList<int[]> rallyList = new ArrayList<>();\n for (int i = 0; i < _rallies.size(); i++) {\n int[] info = new int[] {i, _rallies.get(i)[0], _rallies.get(i)[1]};\n rallyList.add(info);\n }\n\n // Sort them in an increasing order of the deadline\n rallyList.sort(Comparator.comparingInt(rally -> rally[2]));\n\n // Set the start time\n int f = 0;\n\n // If there is no way to finish any one of the rally before its deadline, then we will set this to true.\n boolean nuke = false;\n\n // Run a greedy algorithm (Scheduling to Minimize Lateness)\n for (int[] rally : rallyList) {\n int[] plan = new int[] {rally[0], f};\n int duration = rally[1];\n int deadline = rally[2];\n f += duration;\n\n if (f > deadline) {\n nuke = true;\n break;\n }\n\n schedule.add(plan);\n }\n\n if (nuke) {\n return new ArrayList<>();\n }\n\n return schedule;\n }",
"@Test\n\tpublic void circleLeastStationTest() {\n\t\tList<String> newTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"1\");\n\t\tnewTrain.add(\"4\");\n\t\tList<TimeBetweenStop> timeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\tTimeBetweenStop timeBetweenStop = new TimeBetweenStop(\"1\", \"4\", 20);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"B\", timeBetweenStops);\n\t\t\n\t\tList<String> answer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"2\");\n\t\tanswer.add(\"3\");\n\t\tanswer.add(\"4\");\n\t\tTrip trip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(9, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\n\t\t//Add a new train, least time\n\t\tnewTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"1\");\n\t\tnewTrain.add(\"4\");\n\t\ttimeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\ttimeBetweenStop = new TimeBetweenStop(\"1\", \"4\", 8);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"C\", timeBetweenStops);\n\n\t\tanswer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"4\");\n\t\ttrip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(8, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\n\t\t//Add a new train, more stop but even less time\n\t\tnewTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"2\");\n\t\tnewTrain.add(\"5\");\n\t\tnewTrain.add(\"6\");\n\t\tnewTrain.add(\"4\");\n\t\ttimeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\ttimeBetweenStop = new TimeBetweenStop(\"2\", \"5\", 2);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"5\", \"6\", 1);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"6\", \"4\", 2);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"D\", timeBetweenStops);\n\n\t\tanswer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"2\");\n\t\tanswer.add(\"5\");\n\t\tanswer.add(\"6\");\n\t\tanswer.add(\"4\");\n\t\ttrip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(7, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\n\t\t//Add a new train, less time than above\n\t\tnewTrain = new ArrayList<String>();\n\t\tnewTrain.add(\"7\");\n\t\tnewTrain.add(\"2\");\n\t\tnewTrain.add(\"3\");\n\t\tnewTrain.add(\"4\");\n\t\ttimeBetweenStops = new ArrayList<TimeBetweenStop>();\n\t\ttimeBetweenStop = new TimeBetweenStop(\"7\", \"2\", 1);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"2\", \"3\", 3);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\ttimeBetweenStop = new TimeBetweenStop(\"3\", \"4\", 1);\n\t\ttimeBetweenStops.add(timeBetweenStop);\n\t\tsubwaySystem.addTrainLine(newTrain, \"E\", timeBetweenStops);\n\n\t\tanswer = new ArrayList<String>();\n\t\tanswer.add(\"1\");\n\t\tanswer.add(\"2\");\n\t\tanswer.add(\"3\");\n\t\tanswer.add(\"4\");\n\t\ttrip = subwaySystem.takeTrain(\"1\", \"4\");\n\t\tAssert.assertTrue(trip.isTripFound());\n\t\tAssert.assertEquals(6, trip.getDuration());\n\t\tAssert.assertTrue(TestHelper.checkAnswer(answer, trip.getStops()));\n\t}",
"public int minSeq() {\n lock.lock();\n int globalMin = dones[me];\n\n for(int i=0;i<dones.length;i++) {\n if(dones[i] < globalMin) {\n globalMin = dones[i];\n }\n }\n\n /*\n Iterator<Map.Entry<Integer,Instance<T>>> iter = (Iterator<Map.Entry<Integer,Instance<T>>>)seqMap.entrySet().iterator();\n while(iter.hasNext()) {\n int key = iter.next().getKey();\n if(key <= globalMin && seqMap.get(key).getStatus() == Status.DECIDED) iter.remove();\n }\n */\n lock.unlock();\n return globalMin+1;\n }",
"public StackWithMin() {\n st = new LinkedList<>();\n minSt = new LinkedList<>();\n }",
"private void applyRaceStartPenalty()\n {\n for(int i = 0; i < getDrivers().getSize(); i++)\n {\n getDrivers().getDriver(i).setAccumulatedTime(0); // set to default\n int driverRanking = getDrivers().getDriver(i).getRanking();\n int timePenalty = 10;\n switch(driverRanking)\n {\n case 1: timePenalty = 0; break;\n case 2: timePenalty = 3; break;\n case 3: timePenalty = 5; break;\n case 4: timePenalty = 7; break;\n }\n getDrivers().getDriver(i).setAccumulatedTime(timePenalty);\n }\n }",
"private void buildSchedule() {\n\t\tclass RabbitsGrassSimulationStep extends BasicAction {\n\t\t\tpublic void execute() {\n\t\t\t\tSimUtilities.shuffle(rabbitList);\n\t\t\t\tfor (int i = 0; i < rabbitList.size(); i++) {\n\t\t\t\t\tRabbitsGrassSimulationAgent rabbit = rabbitList.get(i);\n\t\t\t\t\trabbit.step();\n\t\t\t\t}\n\n\t\t\t\treapDeadRabbits();\n\t\t\t\tgiveBirthToRabbits();\n\n\t\t\t\trabbitSpace.spreadGrass(growthRateGrass);\n\n\t\t\t\tdisplaySurf.updateDisplay();\n\t\t\t}\n\t\t}\n\n\t\tschedule.scheduleActionBeginning(0, new RabbitsGrassSimulationStep());\n\n\t\tclass UpdateNumberOfRabbitsInSpace extends BasicAction {\n\t\t\tpublic void execute() {\n\t\t\t\trabbitsAndGrassInSpace.step();\n\t\t\t}\n\t\t}\n\n\t\tschedule.scheduleActionAtInterval(1, new UpdateNumberOfRabbitsInSpace());\n\n\t}",
"public void realocareThreadsDistribution(){\n for(int i=1;i<=nrThreads;i++){\n if(listofIntervalsForEachThread[i] == null)\n listofIntervalsForEachThread[i] = new IntervalClass();\n this.listofIntervalsForEachThread[i].setStart(0);\n this.listofIntervalsForEachThread[i].setEnd(0);\n }\n if(this.nrThreads>=this.borderArray.size())\n for(int i=0;i<this.borderArray.size();i++){\n this.listofIntervalsForEachThread[i+1].setStart(i);\n this.listofIntervalsForEachThread[i+1].setEnd(i);\n }\n else{\n int nrForEachThread = this.borderArray.size()/nrThreads;\n int difSurplus = this.borderArray.size()%nrThreads;\n int difRate;\n int lastAdded = 0;\n for(int i=1;i<=this.nrThreads;i++){\n if(difSurplus > 0){\n difRate = 1;\n difSurplus--;\n }\n else difRate = 0;\n \n this.listofIntervalsForEachThread[i].setStart(lastAdded);\n lastAdded = lastAdded + difRate + nrForEachThread - 1;\n this.listofIntervalsForEachThread[i].setEnd(lastAdded);\n lastAdded++;\n }\n }\n }",
"public void generateSchedule(){\n\t\t\n\t}",
"public Schedule heuristicScheduling() \n\t{ \n\t\t// this creates an array, originally empty, of all the tasks scheduled in the heuristic manner\n\t\tScheduledTask[] heuristic = new ScheduledTask[tasks.length];\n\t\n\t\t// this creates an array that holds the duration of tasks on every processor\n\t\tint[] processorDuration = new int[m];\n\t\t\n\t\t// this creates a clone of the tasks array so that it can be messed with\n\t\tint[] junkTasks = tasks.clone();\n\t\t\n\t\t// this is the index of how many tasks have already been scheduled\n\t\tint index = 0;\n\t\t\n\t\twhile (index < tasks.length)\n\t\t{\n\t\t\t// this is the index of the processor with the smallest duration\n\t\t\tint smallestIndex = 0;\n\t\t\t\n\t\t\t// this finds the processor with the smallest duration\n\t\t\tfor (int i = 0; i < m; i++)\n\t\t\t{\n\t\t\t\tif (processorDuration[i] < processorDuration[smallestIndex])\n\t\t\t\t\tsmallestIndex = i;\n\t\t\t}\n\t\t\t\n\t\t\t// this is the id of the task with the largest duration\n\t\t\tint largestIndex = 0;\n\n\t\t\t// this finds the task with the largest duration\n\t\t\tfor (int i = 0; i < junkTasks.length; i++)\n\t\t\t{\n\t\t\t\tif (junkTasks[i] > junkTasks[largestIndex])\n\t\t\t\t\tlargestIndex = i;\n\t\t\t}\n\t\t\t\n\t\t\t// this schedules the task with the largest duration at the processor with the smallest duration\n\t\t\t// and assigns it to heuristic array at the index\n\t\t\theuristic[index] = new ScheduledTask(largestIndex, smallestIndex);\n\t\t\t\n\t\t\t// this increments the duration of the processor to which the task just got assigned\n\t\t\tprocessorDuration[smallestIndex] += tasks[largestIndex];\n\t\t\t\n\t\t\t// this sets the duration of the task that was just scheduled to zero\n\t\t\tjunkTasks[largestIndex] = 0;\n\t\t\t\n\t\t\t// this increments the index since another task just got assigned\n\t\t\tindex++;\n\t\t}\n\t\t\n\t\treturn new Schedule(tasks, m, heuristic);\n\t}",
"protected ValuePosition getMinimum() {\n\t\t// Calcule la position et la durée d'exécution de la requête la plus courte dans le tableau des requêtes\n\t\tValuePosition minimum = new ValuePosition();\n\t\tminimum.position = 0;\n\t\tfor(int pos=0; pos<requests.length; pos++) {\n\t\t\tRequest request = requests[pos];\n\t\t\tif(request == null) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif(minimum.value == null || request.getElapsedTime() < minimum.value) {\n\t\t\t\tminimum.position = pos;\n\t\t\t\tminimum.value = request.getElapsedTime();\n\t\t\t}\n\t\t}\n\t\treturn minimum;\n\t}",
"private MySchedule getRandomInitialSchedule() {\r\n\t\tArrayList<MyCourse> courses = new ArrayList<MyCourse>();\r\n\t\tfor (MyClass aClass : this.allClasses)\r\n\t\t\tcourses.add(new MyCourse(aClass,\r\n\t\t\t\tthis.getRandomRoom(),\r\n\t\t\t\tthis.getRandomInstructor(),\r\n\t\t\t\tthis.getRandomTimeSlot()));\r\n\t\tMySchedule result = new MySchedule(courses);\r\n\t\treturn result.getEnergy() > 0 ? result : this.getRandomInitialSchedule();\r\n\t}",
"public ArrayList<Timestamp> generateNonSportSchedule(int faculties[], String course[] ,Date startDate, Date endDate){\r\n \t\r\n \t\r\n \tArrayList<CourseStructure > allCourseStructure = new ArrayList<CourseStructure>();\r\n \tArrayList<CourseStructure > tempCourseStructure = new ArrayList<CourseStructure>();\r\n \tArrayList<Timestamp> allFreeSlot = new ArrayList<Timestamp>();\r\n \t\r\n \t\r\n \t// get all structureCourse based on faculty\r\n \tif(faculties.length>0){\r\n \t\tFacultyCourseManager facultyCourseManager = new FacultyCourseManager();\r\n \t\tallCourseStructure = facultyCourseManager.getCourseByFaculty(faculties);\r\n \t}//end if(faculties.length>0)\r\n \t\r\n \t//get all structureCourse based on course\r\n \tif(course.length>0){\r\n \t\tCourseStructureManager coursestructure = new CourseStructureManager();\r\n \t\ttempCourseStructure = coursestructure.getAllCourseStructureByCourse(course);\r\n \t}//end if(course.length>0)\r\n \t\r\n \t//merge both CourseStructure Arraylist\r\n \tfor(int i =0 ; i<tempCourseStructure.size();i++){\r\n \t\tif(!allCourseStructure.contains(tempCourseStructure.get(i))){\r\n \t\t\tallCourseStructure.add(tempCourseStructure.get(i));\r\n \t\t}//end if(!allCourseStructure.contains(tempCourseStructure.get(i))){\r\n \t}//for(int i =0 ; i<tempCourseStructure.size();i++)\r\n \t\r\n \t\r\n \t\r\n \t /* implement a genetic algorithm\r\n \t * to find the best fit date\r\n \t */\r\n \t//variables\r\n \tArrayList<Timestamp> allSolutions = new ArrayList<Timestamp>();\r\n \tArrayList<Integer> solutionFitness = new ArrayList<Integer>();\r\n \tint totalTime,fitnessValue=0;\r\n \tTimestamp time = new Timestamp(startDate.getYear(), startDate.getMonth(), startDate.getDate(), 8, 0, 0, 0);\r\n \tboolean result;\r\n \t//initialize population\r\n \t/*university start at 8a.m to 8p.m\r\n \t * This makes 12 hr\r\n \t * Total time = (endDate -StartDate) * 12\r\n \t */\r\n \t \r\n \t\r\n \tlong daysBetween = endDate.getTime()- startDate.getTime();\r\n \t\r\n totalTime = (int)( (daysBetween * 12)/ (1000 * 60 * 60 * 24) );\r\n allSolutions.add(time);\r\n Calendar calender = Calendar.getInstance();\r\n \tfor(int i=1;i<totalTime;i++){\r\n \t\tif(time.getHours()>0 && time.getHours()<20){\r\n \t\t\tcalender.setTime(time);\r\n \t\t\t\r\n \t\t\tcalender.add(Calendar.HOUR, 1);\r\n \t\t\tlong tim = calender.getTime().getTime();\r\n \t\t\ttime = new Timestamp(tim);\r\n \t\t\tallSolutions.add(time);\r\n \t\t}//end if(time.getHours()>0 && time.getHours()<8){\r\n \t\telse{\r\n \t\t\tcalender.setTime(time);\r\n \t\t\t\r\n \t\t\tcalender.add(Calendar.HOUR, 12);\r\n \t\t\tlong tim = calender.getTime().getTime();\r\n \t\t\ttime = new Timestamp(tim);\r\n \t\t\tallSolutions.add(time); \t\t\t\r\n \t\t}//end else \t\t \t\t\r\n \t}//end for(int i=1;i<totalTime;i++){\r\n \t\r\n \t\r\n \t//fitness\r\n \t/*\r\n \t * if current timetable slot is free = increase by 1\r\n \t * if module is not in current timetable slot = increase by 1\r\n \t * if module is not a degree = increase by 1\r\n \t * if module is not year 3 = increase by 1 \r\n \t */\r\n \tTimetableManager timetableManager = new TimetableManager();\r\n \t//travel through population\r\n \tfor(int i=0; i<allSolutions.size();i++){\r\n \t\t//travel through course Structure\r\n \r\n \t\tfor(int j=0;j<allCourseStructure.size();j++){\r\n \t\t\t\r\n \t\t\t//check for current timetable slot\r\n \t\tint day = allSolutions.get(i).getDay();\r\n \t\tTime temTime = new Time(allSolutions.get(i).getTime());\r\n \t\t\r\n \t\t//check for course structure timetable slot\r\n \t\tresult = timetableManager.findTimetableByDayTime(temTime, getDays(day), allCourseStructure.get(j).getCourse_structure_id());\r\n \t\tif(!result){\r\n \t\t\tfitnessValue++;\r\n \t\t}//end if(!result) \r\n \t\t\t\r\n \t\t}//end for(int j=0;j<allCourseStructure.size();j++){\r\n \t\t\r\n \t\tsolutionFitness.add(fitnessValue);\r\n \t\tfitnessValue = 0;\r\n \t}//end for (int i=0; i<allSolutions.size();i++){\r\n \t\r\n \tint maxFitness = Collections.max(solutionFitness);\r\n \tfor(int i =0 ; i<allSolutions.size();i++){\r\n \t\tif(solutionFitness.get(i) == maxFitness){\r\n \t\t\tallFreeSlot.add(allSolutions.get(i));\r\n \t\t}\t\r\n \t}\r\n \t\r\n \t\r\n \t\r\n \treturn allFreeSlot; \t\r\n }",
"private MySchedule radomlyMutate(MySchedule schedule) {\r\n\t\tArrayList<MyCourse> courses = (ArrayList<MyCourse>) schedule.getCourses();\r\n\t\tint courseIndex = this.random.nextInt(courses.size());\r\n\t\tMyCourse course = courses.get(courseIndex);\r\n\t\tswitch (random.nextInt(3)) {\r\n\t\t\tcase 0:\r\n\t\t\t\tMyRoom aRoom = this.getRandomRoom();\r\n\t\t\t\twhile (course.getRoom() == aRoom)\r\n\t\t\t\t\taRoom = this.getRandomRoom();\r\n\t\t\t\tcourse.setRoom(aRoom);\r\n\t\t\t\tbreak;\r\n\t\t\tcase 1:\r\n\t\t\t\tMyInstructor aInstructor = this.getRandomInstructor();\r\n\t\t\t\twhile (course.getInstructor() == aInstructor)\r\n\t\t\t\t\taInstructor = this.getRandomInstructor();\r\n\t\t\t\tcourse.setInstructor(aInstructor);\r\n\t\t\t\tbreak;\r\n\t\t\tcase 2:\r\n\t\t\t\tMyTimeSlot aTimeSlot = this.getRandomTimeSlot();\r\n\t\t\t\twhile (course.getTimeSlot() == aTimeSlot)\r\n\t\t\t\t\taTimeSlot = this.getRandomTimeSlot();\r\n\t\t\t\tcourse.setTimeSlot(aTimeSlot);\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\t\tcourses.set(courseIndex, course);\r\n\t\treturn new MySchedule(courses);\r\n\t}",
"public void resizeStartUnchanged(int newcapacity){\n Object []lin=new Object[newcapacity];\n int k=start;\n for(int i=0;i<size;i++){\n lin[i]=cir[k];\n k=(k+1)%cir.length;\n }\n cir=new Object[newcapacity];\n for(int i=0;i<size;i++){\n cir[k]=lin[i];\n k=(k+1)%cir.length;\n }\n }",
"private void recursive(ScheduledTask[] schedule, int startIndex, int[] processorDurations)\n\t{\t\n\t\t// this is the base case. if the start index is at the size of schedule, aka all the tasks have\n\t\t// been assigned, then the method returns the complete schedule formed.\n\t\tif (startIndex == schedule.length)\n\t\t{\n\t\t\tSchedule temp = new Schedule(tasks, m, schedule);\n\t\t\tif (temp.getMakespan() < best.getMakespan())\n\t\t\t{\n\t\t\t\tbest = new Schedule(tasks, m, temp.getScheduledTasks());\n\t\t\t}\n\t\t}\n\t\tif (startIndex < schedule.length)\n\t\t{\n\t\t\t// this tries adding the task to each processor and finds the most optimal schedule formed\n\t\t\tfor (int i = 0; i < m; i++)\n\t\t\t{\n\t\t\t\t// this checks to see if adding a task would make the makespan greater than the optimum\n\t\t\t\t// if it does, then it's probably not the best solution\n\t\t\t\tif ((processorDurations[i] + tasks[startIndex]) > best.getMakespan())\n\t\t\t\t\tcontinue;\n\t\t\t\t\n\t\t\t\t// this assigns the task to the processor i\n\t\t\t\tschedule[startIndex] = new ScheduledTask(startIndex, i);\n\t\t\t\n\t\t\t\t// this increments the total duration of the processor that the task just got assigned to\n\t\t\t\tint [] processorDurationsTemp = processorDurations.clone();\n\t\t\t\tprocessorDurationsTemp[i] += tasks[startIndex];\n\t\t\t\t\n\t\t\t\t// this is where the recursion occurs\n\t\t\t\trecursive(schedule, startIndex + 1, processorDurationsTemp);\n\t\t\t}\n\t\t}\n\t\t\n\t}",
"static int[][] generateShifts(int maxDistanceLeft, ThreadVariables t){\n return null;\n }",
"private void plant(int l) {\n if (l >= empties.size()) {\n if (currentMines > bestMines) {\n copyField(current, best);\n bestMines = currentMines;\n }\n //geval 2: we zijn nog niet alle lege vakjes afgegaan, en we kunnen misschien nog beter doen dan de huidige oplossing\n } else if(currentMines + (empties.size() - l) > bestMines ) {\n //recursief verder uitwerken, met eerst de berekening van welk vakje we na (i,j) zullen behandelen\n int i = empties.get(l).getI();\n int j = empties.get(l).getJ();\n\n //probeer een mijn te leggen op positie i,j\n if (canPlace(i,j)) {\n placeMine(i, j);\n currentMines++;\n\n\n //recursie\n plant(l + 1);\n\n //hersteloperatie\n removeMine(i, j);\n currentMines--;\n\n }\n //recursief verder werken zonder mijn op positie i,j\n plant(l +1);\n }\n }",
"@Test\n\tpublic void modifyingScheduleWorks() throws Exception {\n\t\tResource floatRes = new Resource();\n\t\tfloatRes.setName(\"scheduleTest\");\n\t\tfloatRes.setType(FloatResource.class);\n\t\t// floatRes.setDecorating(Boolean.TRUE);\n\t\tFloatSchedule schedule = createTestSchedule();\n\n\t\tfloatRes.getSubresources().add(schedule);\n\t\tResource meter1 = unmarshal(sman.toXml(meter), Resource.class);\n\t\tmeter1.getSubresources().add(floatRes);\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\n\t\tschedule.getEntry().clear();\n\t\tschedule.setStart(2L);\n\t\tschedule.setEnd(3L);\n\n\t\tSampledValue v = new SampledFloat();\n\t\tv.setQuality(Quality.GOOD);\n\t\tv.setTime(2);\n\t\tv.setValue(new FloatValue(2));\n\t\tschedule.getEntry().add(v);\n\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\n\t\tSchedule ogemaSchedule = (Schedule) meter.getSubResource(\"scheduleTest\").getSubResource(\"data\");\n\n\t\tassertEquals(3, ogemaSchedule.getValues(0).size());\n\t\tassertEquals(2, ogemaSchedule.getValues(0).get(1).getValue().getFloatValue(), 0);\n\t}",
"public Schedule assign()\n\t{\n\t\tif(debug) System.out.println(\"Assignment started (Lecture Random)\");\n\t\tboolean valid = assignSlot(true); //assign times to Lectures\n\t\tif(debug && valid) System.out.println(\"Assignment started (Lab Random)\");\n\t\tif(valid) valid = assignSlot(false); //assign times to Labs\n\t\tif(debug && valid) System.out.println(\"Checking constraints (Random)\");\n\t\tif(valid) \n\t\t{\n\t\t\tvalid = constr(); //check the hard constraints one more time\n\t\t\tif(debug) System.out.println(child);\n\t\t}\n\t\tif (valid) child.setValue(child.eval()); //evaluate the soft constraints\n\t\t\n\t\tif(valid) \n\t\t{\n\t\t\tif(debug) System.out.println(child);\n\t\t\treturn child; //return the completed valid schedule\n\t\t}else\n\t\t{\n\t\t\tSystem.out.println(child);\n\t\t\treturn null; //invalid schedule, return nothing\n\t\t}\n\t}",
"private void findWaitingTime(int wt[]) {\n\t\tint rt[] = new int[n];\r\n\t\t\r\n\t\tfor(int i=0;i<n;i++) {\r\n\t\t\trt[i] = processList.get(i).getBurstTime();\r\n\t\t}\r\n\t\t\r\n\t\tint completed = 0,t=0,minm = Integer.MAX_VALUE;\r\n\t\tint shortest = 0, finish_time;\r\n\t\t\r\n\t\tboolean check = false;\r\n\t\t\r\n\t\twhile(completed!=n) {\r\n\t\t\t// find process with min rmaining time\r\n\t\t\tfor(int i=0; i<n ;i++) {\r\n\t\t\t\tif (processList.get(i).getArrivalTime()<=t && rt[i]<minm && rt[i]>0) {\r\n\t\t\t\t\tminm = rt[i];\r\n\t\t\t\t\tshortest = i;\r\n\t\t\t\t\tcheck = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(check == false) {\r\n\t\t\t\tt++;\r\n\t\t\t\tcontinue;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\trt[shortest]--;\r\n\t\t\t\r\n\t\t\tif (minm == 0) {\r\n\t\t\t\tminm = Integer.MAX_VALUE;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif (rt[shortest]==0) {\r\n\t\t\t\tcompleted++;\r\n\t\t\t\tcheck=false;\r\n\t\t\t\t\r\n\t\t\t\tfinish_time = t+1;\r\n\t\t\t\t\r\n\t\t\t\twt[shortest] = finish_time - processList.get(shortest).getBurstTime() - processList.get(shortest).getArrivalTime();\r\n\t\t\t\t\r\n\t\t\t\tif (wt[shortest]<0) {\r\n\t\t\t\t\twt[shortest] = 0;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tt++;\r\n\t\t}\r\n\t}",
"private List<Schedule> getSchedules(String traverserName, int delay) {\n List<ScheduleTimeInterval> intervals =\n new ArrayList<ScheduleTimeInterval>();\n intervals.add(new ScheduleTimeInterval(\n new ScheduleTime(0),\n new ScheduleTime(0)));\n \n List<Schedule> schedules = new ArrayList<Schedule>();\n Schedule schedule = new Schedule(traverserName, false, 60, delay, intervals);\n schedules.add(schedule);\n return schedules;\n }",
"private List<ItemMovement> uitGraven(Slot slot, Gantry gantry){\n\n List<ItemMovement> itemMovements = new ArrayList<>();\n Richting richting = Richting.NaarVoor;\n\n //Recursief naar boven gaan, doordat we namelijk eerste de gevulde parents van een bepaald slot moeten uithalen\n if(slot.getParent() != null && slot.getParent().getItem() != null){\n itemMovements.addAll(uitGraven(slot.getParent(), gantry));\n }\n\n //Slot in een zo dicht mogelijke rij zoeken\n boolean newSlotFound = false;\n Slot newSlot = null;\n int offset = 1;\n do { //TODO: als storage vol zit en NaarVoor en NaarAchter vinden geen vrije plaats => inf loop\n // bij het NaarAchter lopen uw index telkens het negatieve deel nemen, dus deze wordt telkens groter negatief.\n //AANPASSING\n Integer locatie = richting==Richting.NaarVoor? (slot.getCenterY() / 10) + offset : (slot.getCenterY() / 10) - offset;\n //we overlopen eerst alle richtingen NaarVoor wanneer deze op zen einde komt en er geen plaats meer is van richting veranderen naar achter\n // index terug op 1 zetten omdat de indexen ervoor al gecontroleerd waren\n if (grondSlots.get(locatie) == null) {\n //Grootte resetten en richting omdraaien\n offset = 1;\n richting = Richting.NaarAchter;\n continue;\n }\n\n Set<Slot> ondersteRij = new HashSet<>(grondSlots.get(locatie).values());\n newSlot = GeneralMeasures.zoekLeegSlot(ondersteRij);\n\n if(newSlot != null){\n newSlotFound = true;\n }\n //telkens één slot verder gaan\n offset += 1;\n }while(!newSlotFound);\n // vanaf er een nieuw vrij slot gevonden is deze functie verlaten\n\n //verplaatsen\n itemMovements.addAll(GeneralMeasures.createMoves(pickupPlaceDuration,gantry, slot, newSlot));\n update(Operatie.VerplaatsIntern, newSlot, slot);\n\n return itemMovements;\n }",
"@Override\n public Matching stableMarriageGaleShapley_residentoptimal(Matching marriage) {\n\n int m = marriage.getHospitalCount();\n int n = marriage.getResidentCount();\n\n ArrayList<ArrayList<Integer>> hospital_preference = marriage.getHospitalPreference();\n ArrayList<ArrayList<Integer>> resident_preference = marriage.getResidentPreference();\n ArrayList<Integer> hospitalSlots = marriage.getHospitalSlots();\n ArrayList<Integer> residentMatching = new ArrayList<Integer>();\n arrlistInit(residentMatching, n, -1, false); //O(n)\n\n /*At first the resident can propose to all his list.\n Each time a proposal is made the hospital is removed from the list*/\n\n /*Trying to create a copy of the arraylist elements not copy of references*/\n ArrayList<ArrayList<Integer>> hospitalsToProposeTo = new ArrayList<ArrayList<Integer>>();\n for (int i = 0; i < n; i++) //O(n)\n hospitalsToProposeTo.add(new ArrayList<Integer>(resident_preference.get(i)));\n\n\n /*list of residents that still can propose(free and hasn't proposed to every hospital)*/\n ArrayList<Integer> proposing = new ArrayList<Integer>();\n arrlistInit(proposing, n, 0, true); //O(n)\n\n\n /*Keep track of each hospital matched residents*/\n ArrayList<ArrayList<Integer>> hospitalResidents = new ArrayList<ArrayList<Integer>>(0);\n for (int i = 0; i < m; i++)\n hospitalResidents.add(new ArrayList<Integer>(0)); //O(m)\n\n /*Array list that holds the value of the lowest matched resident rank in each hospital\n * so each time a resident propose to a full hospital, the resident is swapped with the least ranked rmatched resident */\n ArrayList<Integer> lowestMatchedResidentRank = new ArrayList<Integer>();\n arrlistInit(lowestMatchedResidentRank, m, -1, false); //O(m)\n\n /*we enter the loop as long as some residents aren't done proposing to all hospitals yet O(mn*maximum no of spots)*/\n while (!proposing.isEmpty()) {\n\n /*Get the head of the proposing list*/\n for (int residentIndex = 0; residentIndex < proposing.size(); residentIndex++) {\n int resident = proposing.get(0);\n int hospital = 0;\n int hospitalIndex;\n /*Get the first hospital in the resident list which he hasn't proposed to yet, breaks if he can't no longer propose if matched*/\n for (hospitalIndex = 0; hospitalIndex < hospitalsToProposeTo.get(resident).size() && proposing.contains(resident); hospitalIndex++) {\n hospital = hospitalsToProposeTo.get(resident).get(0);\n int residentRank = hospital_preference.get(hospital).indexOf(resident);\n\n /*hospital is full, loop through the matched residents and see if anyone can be kicked out*/\n if (hospitalResidents.get(hospital).size() == hospitalSlots.get(hospital)) {\n\n if (residentRank < lowestMatchedResidentRank.get(hospital)) {\n /*1.Replace in hospitalResidents\n * 2.Add/remove in resident-matching\n * 3.Remove resident from the proposing list\n * 4.Check if matched resident still has hospitals to propose to (if yes, add to proposing)\n */\n int lowestMatchedResident = hospital_preference.get(hospital).get(lowestMatchedResidentRank.get(hospital));\n\n hospitalResidents.get(hospital).set(hospitalResidents.get(hospital).indexOf(lowestMatchedResident), resident);\n residentMatching.set(lowestMatchedResident, -1);\n residentMatching.set(resident, hospital);\n proposing.remove(proposing.indexOf(resident));\n if (!hospitalsToProposeTo.get(lowestMatchedResident).isEmpty()) {\n proposing.add(lowestMatchedResident);\n }\n\n /*set the lowest rank\n * TODO make it O(1)*/\n int min = 0;\n for (int i = 0; i < hospitalResidents.get(hospital).size(); i++) {\n int tempRank = hospital_preference.get(hospital).indexOf(hospitalResidents.get(hospital).get(i));\n if (tempRank > min)\n min = tempRank;\n }\n lowestMatchedResidentRank.set(hospital, min);\n\n }\n }\n\n /*If there is available spot*/\n else {\n /*1.Add in hospitalResidents\n * 2.Add in resident-matching\n * 3.Set the lowest ranked resident\n * 4.Remove resident from proposing list\n */\n\n /*Update the lowest rank*/\n if (residentRank > lowestMatchedResidentRank.get(hospital))\n lowestMatchedResidentRank.set(hospital, residentRank);\n\n hospitalResidents.get(hospital).add(resident);\n residentMatching.set(resident, hospital);\n proposing.remove(proposing.indexOf(resident));\n }\n\n /*1. Remove hospital from resident's hospitalsToProposeTo\n *2. If resident is matched or proposed to every possible hospital, remove resident from proposing list\n */\n\n hospitalsToProposeTo.get(resident).remove(hospitalsToProposeTo.get(resident).indexOf(hospital));\n if (hospitalsToProposeTo.get(resident).size() == 0 && proposing.contains(resident))\n proposing.remove(proposing.indexOf(resident));\n }\n }\n }\n\n marriage.setResidentMatching(residentMatching);\n return marriage;\n\n }",
"public void buildSchedule() {\n class SimulationStep extends BasicAction {\n public void execute() {\n SimUtilities.shuffle(rabbitList);\n for (int i = 0; i < rabbitList.size(); i++) {\n RabbitsGrassSimulationAgent rabbit = rabbitList.get(i);\n rabbit.step();\n }\n\n reapDeadRabbits();\n\n displaySurf.updateDisplay();\n }\n }\n schedule.scheduleActionBeginning(0, new SimulationStep());\n\n class GrassGrowth extends BasicAction {\n public void execute() {\n space.spreadGrass(grassGrowthRate);\n }\n }\n schedule.scheduleActionBeginning(0, new GrassGrowth());\n\n class UpdatePopulationPlot extends BasicAction {\n public void execute() {\n populationPlot.step();\n }\n }\n schedule.scheduleActionAtInterval(5, new UpdatePopulationPlot());\n }",
"public long getMinTime()\n {\n return times[0];\n }",
"public void makeRounds() {\n for (int i = 0; i < nrofturns; i++) {\n int check = 0;\n // If all distributors are bankrupt we intrrerupt the simulation\n for (Distributor d : listOfDistributors.getList()) {\n if (d.isBankrupt()) {\n continue;\n }\n check = 1;\n break;\n }\n if (check == 0) {\n break;\n }\n // Auxiliary variable that will point to the best deal for the consumers\n Distributor bestDist;\n // Making the updates at the start of each month\n if (listOfUpdates.getList().get(i).getNewConsumers().size() != 0) {\n for (Consumer x : listOfUpdates.getList().get(i).getNewConsumers()) {\n listOfConsumers.getList().add(x);\n }\n }\n if (listOfUpdates.getList().get(i).getDistributorChanges().size() != 0) {\n for (DistributorChanges x : listOfUpdates.getList().get(\n i).getDistributorChanges()) {\n listOfDistributors.grabDistributorbyID(\n x.getId()).setInitialInfrastructureCost(x.getInfrastructureCost());\n }\n }\n\n // Checking if the producers have changed their costs asta ar trb sa fie update\n\n // Making the variable point to the best deal in the current round\n // while also calculating the contract price for each distributor\n bestDist = listOfDistributors.getBestDistinRound();\n // Removing the link between consumers and distributors when the contract has ended\n for (Distributor d : listOfDistributors.getList()) {\n if (d.isBankrupt()) {\n // Case in which we delete the due payment of the consumer if\n // its current distributor goes bankrupt\n for (Consumer cons : listOfConsumers.getList()) {\n if (cons.getIdofDist() == d.getId()) {\n cons.setDuepayment(0);\n cons.setMonthstoPay(0);\n cons.setIdofDist(-1);\n }\n }\n continue;\n }\n d.getSubscribedconsumers().removeIf(\n c -> c.isBankrupt() || c.getMonthstoPay() <= 0);\n }\n // Giving the non-bankrupt consumers their monthly income and getting the ones\n // without a contract a deal (the best one)\n for (Consumer c : listOfConsumers.getList()) {\n if (c.isBankrupt()) {\n continue;\n }\n c.addtoBudget(c.getMonthlyIncome());\n if (c.getMonthstoPay() <= 0 || c.getIdofDist() == -1) {\n c.setIdofDist(bestDist.getId());\n c.setMonthstoPay(bestDist.getContractLength());\n c.setToPay(bestDist.getContractPrice());\n bestDist.addSubscribedconsumer(c);\n }\n }\n // Making the monthly payments for the non-bankrupt consumers\n for (Consumer entity : listOfConsumers.getList()) {\n if (entity.isBankrupt()) {\n continue;\n }\n // If the consumer has no due payment we check if he can pay the current rate\n if (entity.getDuepayment() == 0) {\n // If he can, do just that\n if (entity.getBudget() >= entity.getToPay()) {\n entity.addtoBudget(-entity.getToPay());\n listOfDistributors.grabDistributorbyID(entity.getIdofDist()).addBudget(\n entity.getToPay());\n entity.reduceMonths();\n // Contract has ended\n if (entity.getMonthstoPay() <= 0) {\n entity.setIdofDist(-1);\n }\n } else {\n // He cannot pay so he gets a due payment\n entity.setDuepayment(entity.getToPay());\n entity.reduceMonths();\n }\n } else {\n // The consumer has a due payment\n if (entity.getMonthstoPay() == 0) {\n // He has one to a distributor with whom he has ended the contract so\n // he must make the due payment and the one to the new distributor\n int aux = (int) Math.round(Math.floor(DUECOEFF * entity.getDuepayment()));\n int idAux = entity.getIdofDist();\n entity.setIdofDist(bestDist.getId());\n entity.setToPay(bestDist.getContractPrice());\n entity.setMonthstoPay(bestDist.getContractLength());\n bestDist.addSubscribedconsumer(entity);\n // He is able to\n if (entity.getBudget() >= (aux + entity.getToPay())) {\n entity.addtoBudget(-(aux + entity.getToPay()));\n listOfDistributors.grabDistributorbyID(idAux).addBudget(\n aux);\n listOfDistributors.grabDistributorbyID(entity.getIdofDist()).addBudget(\n entity.getToPay());\n entity.reduceMonths();\n } else {\n // He has insufficient funds\n entity.setBankrupt(true);\n }\n } else {\n // His due payment is at the same distributor he has to make the monthly\n // payments\n // He can do the payments\n if (entity.getBudget()\n >= (int) Math.round(Math.floor(DUECOEFF * entity.getDuepayment())\n + entity.getToPay())) {\n entity.addtoBudget(-(int) Math.round(Math.floor(DUECOEFF\n * entity.getDuepayment()) + entity.getToPay()));\n listOfDistributors.grabDistributorbyID(entity.getIdofDist()).addBudget(\n (int) Math.round(Math.floor(DUECOEFF * entity.getDuepayment())\n + entity.getToPay()));\n entity.reduceMonths();\n } else {\n // He cannot do the payments\n entity.setBankrupt(true);\n }\n }\n }\n }\n // The non-bankrupt distributors pay their monthly rates\n for (Distributor d : listOfDistributors.getList()) {\n if (d.isBankrupt()) {\n continue;\n }\n d.reduceBudget();\n // Those who cannot, go bankrupt\n if (d.getBudget() < 0) {\n d.setBankrupt(true);\n }\n }\n\n this.roundsAdjustments(i);\n }\n }",
"public void resetBoard(Board b, Team t) {\n\t\tstart = new ArrayList<Node>();\n\t\tpossibleSmart = new ArrayList<Integer>();\n\t\tbetterSmart = new ArrayList<Integer>();\n\t\tsmartIndex = -1;\n\t\tmaxType = -1;\n\t\tminType = 7;\n\t\tcheckMate = false;\n\t\tmaxProtect = -1;\n\t\tmaxRow = -1;\n\t\tmaxCol = -1;\n\n\t\tb.setProtections();\n\t\tb.setLocations();\n\t\tPiece[][] board = b.getBoard();\n\n\t\tPiece[][] newBoard = new Piece[board.length][board[0].length];\n\n\t\tfor (int r = 0; r < newBoard.length; r++)\n\t\t\tfor (int c = 0; c < newBoard[r].length; c++)\n\t\t\t\tnewBoard[r][c] = new Piece(board[r][c]);\n\n\t\tTeam op = (t == Team.WHITE) ? Team.BLACK : Team.WHITE;\n\n\t\tfor (int i = 0; i < newBoard.length; i++) {\n\t\t\tfor (int j = 0; j < newBoard[i].length; j++) {\n\t\t\t\tif (newBoard[i][j].getColor() == t) {\n\t\t\t\t\tif ((!newBoard[i][j].isProtected(t) && newBoard[i][j]\n\t\t\t\t\t\t\t.isProtected(op))\n\t\t\t\t\t\t\t|| newBoard[i][j].amountProtect(t) < newBoard[i][j]\n\t\t\t\t\t\t\t\t\t.amountProtect(op)) {\n\t\t\t\t\t\tif (newBoard[i][j].valueProtect(t) > maxProtect) {\n\t\t\t\t\t\t\tmaxProtect = newBoard[i][j].valueProtect(t);\n\t\t\t\t\t\t\tmaxRow = i;\n\t\t\t\t\t\t\tmaxCol = j;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfor (int r = 0; r < newBoard.length; r++) {\n\t\t\tfor (int c = 0; c < newBoard[r].length; c++) {\n\t\t\t\tif (newBoard[r][c].getColor() == t) {\n\t\t\t\t\tPiece p = new Piece(newBoard[r][c]);\n\t\t\t\t\tList<Location> loc = p.getMoveLoc();\n\t\t\t\t\tfor (Location l : loc) {\n\t\t\t\t\t\tstart.add(createNode(new Board(newBoard, t), p, r, c,\n\t\t\t\t\t\t\t\tl, t));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (smartIndex == -1) {\n\t\t\tif(betterSmart.size() > 0)\n\t\t\t\tsmartIndex = (int) (Math.random() * betterSmart.size());\n\t\t\telse if (possibleSmart.size() > 0)\n\t\t\t\tsmartIndex = (int) (Math.random() * possibleSmart.size());\n\t\t\telse\n\t\t\t\tsmartIndex = (int) (Math.random() * start.size());\n\t\t}\n\t}",
"public BetterParkingLot( int size )\n\t{\n\t\tsuper(size);\n queue = new PriorityQueue<Integer>(size);\n\n // add all available parking slots in zero-indexed form\n for(int i=0; i <= size; i++) // this is my only problem. It HAS to be O(n) here.\n queue.add(i);\n\t}",
"@Override\n public void run() {\n // each Car stop 1 second at first\n try {\n Thread.sleep(1000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n\n // choose between 4 lists\n while (true) {\n if (car.start == 1) {\n if (Street.west_list.peek().equals(car)) {\n try {\n Street.west_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n canAccessStreet();\n Street.west_list.remove();\n Street.west_street.release();\n break;\n } else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } else if (car.start == 2) {\n if (Street.south_list.peek().equals(car)) {\n try {\n Street.south_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n canAccessStreet();\n Street.south_list.remove();\n Street.south_street.release();\n break;\n }\n else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } else if (car.start == 3) {\n if (Street.east_list.peek().equals(car)) {\n try {\n Street.east_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n canAccessStreet();\n Street.east_list.remove();\n Street.east_street.release();\n break;\n }\n else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n // start = 4\n else {\n if (Street.north_list.peek().equals(car)) {\n try {\n Street.north_street.acquire();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n canAccessStreet();\n Street.north_list.remove();\n Street.north_street.release();\n break;\n }\n else {\n try {\n Thread.sleep(2000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n }\n }",
"public Schedule() {\n\t\t// TODO Auto-generated constructor stub\n\t}",
"public void setSchedule(SpaceSchedule s) {\n\t\t\n\t}",
"@BeforeAll\n public static void setUp() {\n\n unsolvedCourseSchedule = new RoomSchedule();\n\n \n // fixed periods I'm defining\n \tRoomPeriods fixedRoomPeriod1=new RoomPeriods(1, 1);\n \tfixedRoomPeriod1.setSessionName(\"Session Fixed 1\");\n \t\n \tRoomPeriods fixedRoomPeriod2=new RoomPeriods(1, 2);\n \tfixedRoomPeriod2.setSessionName(\"Session Fixed 2\");\n \t\n // I'm adding fixed periods to schedule, these are known fixed schedule items\n \tunsolvedCourseSchedule.getLectureList().add(fixedRoomPeriod1);\n \tunsolvedCourseSchedule.getLectureList().add(fixedRoomPeriod2); \n \n /* I'm adding 10 more schedule items which are [null,null] , I'm expecting optoplanner assign period and room numbers. \n * [ THEY ARE LINKED with annotations, @PlanningVariable,\t@ValueRangeProvider(id = \"availablePeriods\", @ProblemFactCollectionProperty]\n */\n for(int i = 0; i < 10; i++){ \t \t\n unsolvedCourseSchedule.getLectureList().add(new RoomPeriods()); \n }\n \n // \n unsolvedCourseSchedule.getPeriodList().addAll(Arrays.asList(new Integer[] { 1, 2, 3 }));\n unsolvedCourseSchedule.getRoomList().addAll(Arrays.asList(new Integer[] { 1, 2 }));\n }",
"public ListUtilities returnToStart(){\n\t\tListUtilities temp = new ListUtilities();\n\t\tif(this.prevNum != null){\n\t\t\ttemp = this.prevNum.returnToStart();\n\t\t\treturn temp;\n\t\t}else{\n\t\t\t//System.out.println(\"Returned to... \" + this.num);\n\t\t\treturn this;\n\t\t}\n\t}",
"public double getMinTimeBetweenCarArrivals() {\n return minTimeBetweenCarArrivals;\n }",
"public Scheduler getScheduler()\r\n/* 30: */ {\r\n/* 31: 73 */ return this.scheduler;\r\n/* 32: */ }",
"public TSPMSTSolution(int iterations)\n {\n// System.out.println(\"NODE CREATED\");\n this.included = new int[0];\n this.includedT = new int[0];\n this.excluded = new int[0];\n this.excludedT = new int[0];\n this.iterations = iterations;\n }",
"public Object setInitialHoldings()\r\n/* */ {\r\n\t\t\t\tlogger.info (count++ + \" About to setInitialHoldings : \" + \"Agent\");\r\n/* 98 */ \tthis.profit = 0.0D;\r\n/* 99 */ \tthis.wealth = 0.0D;\r\n/* 100 */ \tthis.cash = this.initialcash;\r\n/* 101 */ \tthis.position = 0.0D;\r\n/* */ \r\n/* 103 */ return this;\r\n/* */ }",
"public void addFreezeFrame()\n{\n int index = Collections.binarySearch(_freezeFrames, getTime());\n if(index<0)\n _freezeFrames.add(-index - 1, getTime());\n}",
"Sporthall() {\n reservationsList = new ArrayList<>();\n }",
"private void maybeScheduleSlice(double when) {\n if (nextSliceRunTime > when) {\n timer.schedule(when);\n nextSliceRunTime = when;\n }\n }",
"@Test\n\tpublic void deletingScheduleIntervalWorks() throws Exception {\n\t\tResource floatRes = new Resource();\n\t\tfloatRes.setName(\"scheduleTest\");\n\t\tfloatRes.setType(FloatResource.class);\n\t\t// floatRes.setDecorating(Boolean.TRUE);\n\t\tFloatSchedule schedule = createTestSchedule();\n\n\t\tfloatRes.getSubresources().add(schedule);\n\t\tResource meter1 = unmarshal(sman.toXml(meter), Resource.class);\n\t\tmeter1.getSubresources().add(floatRes);\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\t\t\n\t\tschedule.getEntry().clear();\n\t\tschedule.setStart(2L);\n\t\tschedule.setEnd(3L);\n\n\t\tsman.applyXml(marshal(meter1), meter, true);\n\n\t\tSchedule ogemaSchedule = (Schedule) meter.getSubResource(\"scheduleTest\").getSubResource(\"data\");\n\n\t\tassertEquals(2, ogemaSchedule.getValues(0).size());\n\t\tassertEquals(42, ogemaSchedule.getValues(0).get(0).getValue().getFloatValue(), 0);\n\t\tassertEquals(44, ogemaSchedule.getValues(0).get(1).getValue().getFloatValue(), 0);\n\t}",
"private void nextTraining() {\n\t\tif(!training_queue.isEmpty()) {\n\t\t\tPair<Soldier, Integer> tmp = training_queue.remove();\n\t\t\tif(tmp!=null) {\n\t\t\t\tcurrent = tmp.getKey();\n\t\t\t\tnb_to_train = tmp.getValue();\t\t\n\t\t\t\tnb_rounds = current.getTime_prod();\n\t\t\t}else {\n\t\t\t\tcurrent = null;\n\t\t\t\tnb_to_train = 1;\n\t\t\t\tnb_rounds = 100+50*(owner_castle.getLevel()+1);\n\t\t\t\tupgrade = true;\n\t\t\t}\n\t\t}else\n\t\t\tcurrent = null;\n\t}",
"private static List<FacilityFreeSchedule> generateFacilityFreeSchedules(Facility facility) {\n List<FacilityFreeSchedule> facilityFreeSchedules=new ArrayList<>();\n LocalDateTime now = LocalDateTime.now();\n Map<Integer,List<LocalDateTime>> workingHoursForMonth=workingHoursForFacilityPerWeek(facility, now);\n workingHoursForMonth.keySet().stream().forEach(weekIndex -> {\n List<LocalDateTime> workingHoursPerWeek = workingHoursForMonth.get(weekIndex);\n facilityFreeSchedules.addAll(workingHoursPerWeek.stream()\n .map(dateTime -> generateFacilityFreeSchedule(facility, dateTime, weekIndex))\n .collect(Collectors.toList()));\n });\n return facilityFreeSchedules;\n }",
"private void checkRequiredSemaphores() {\n if (car.start == 1){\n if (car.end == 2)\n requiredSemaphores.add(Street.sw);\n else if (car.end == 3){\n requiredSemaphores.add(Street.sw);\n requiredSemaphores.add(Street.se);\n }\n // end = 4\n else {\n requiredSemaphores.add(Street.sw);\n requiredSemaphores.add(Street.se);\n requiredSemaphores.add(Street.ne);\n }\n }\n else if (car.start == 2){\n if (car.end == 3)\n requiredSemaphores.add(Street.se);\n else if (car.end == 4){\n requiredSemaphores.add(Street.se);\n requiredSemaphores.add(Street.ne);\n }\n // end = 1\n else {\n requiredSemaphores.add(Street.se);\n requiredSemaphores.add(Street.ne);\n requiredSemaphores.add(Street.nw);\n }\n }\n else if (car.start == 3){\n if (car.end == 4)\n requiredSemaphores.add(Street.ne);\n else if (car.end == 1){\n requiredSemaphores.add(Street.ne);\n requiredSemaphores.add(Street.nw);\n }\n // end = 2\n else{\n requiredSemaphores.add(Street.ne);\n requiredSemaphores.add(Street.nw);\n requiredSemaphores.add(Street.sw);\n }\n }\n // start = 4\n else{\n if (car.end == 1)\n requiredSemaphores.add(Street.nw);\n else if (car.end == 2){\n requiredSemaphores.add(Street.nw);\n requiredSemaphores.add(Street.sw);\n }\n // end = 3\n else {\n requiredSemaphores.add(Street.nw);\n requiredSemaphores.add(Street.sw);\n requiredSemaphores.add(Street.se);\n }\n }\n }",
"public static int calcNextNewSpace(int stmIndex,SpaceTimeMatrix stm,Subcourseblock block,Vector<Room> rooms,Hashtable<Educator,Vector<Integer>> unavailableHoursForEducator,Hashtable<Program,Vector<Integer>> unavailableHoursForProgram)\r\n\t{\r\n\t\tfor(int i=stmIndex+1;i<stm.getSize();i++)\r\n\t\t{ \r\n\t\t\tif(Constraint.roomAvailableAtTime(i,stm))\r\n\t\t\t{\t\r\n\t\t\t\tRoom room = rooms.get(stm.giveRoom(i));\r\n\t\t\t\tif(Constraint.roomSufficient(room,block))\r\n\t\t\t\t{\t\r\n\t\t\t\t\tint hour = stm.giveHour(i);\r\n\t\t\t\t\tif(Constraint.roomAvailableForBlock(i,block,stm))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tif(Constraint.hourAvailable(hour,block,unavailableHoursForEducator,unavailableHoursForProgram))\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\treturn i;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn -1;\r\n\t}",
"public Location spread()\n {\n // plant needs to be alive, ready to reproduce (# of turns) \n // square needs to have fewer than 10 plants, BUT a tree can kill \n // a grass plant\n }",
"private void supplementMST(){\n\t\tList<Village> noOutRoads = getNoOutRoadVillages();\n\t\tList<Village> noInRoads = getNoInRoadVillages();\n\t\t\n\t\tfor(Village v: noOutRoads){\n\t\t\tVillage closestVillage = findClosestVillageTo(v,noInRoads);\n\t\t\tnoInRoads.remove(closestVillage);\n\t\t\tnew Road(v,closestVillage);\n\t\t}\n\t\t\n\t\tfor(Village v: noInRoads){\n\t\t\tnew Road(findClosestVillageTo(v,villages),v);\n\t\t}\n\t}",
"private int getLatestRuns() {\n // return 90 for simplicity\n return 90;\n }",
"private void maybeScheduleSlice() {\n if (nextSliceRunTime > 0) {\n timer.schedule();\n nextSliceRunTime = 0;\n }\n }",
"public Schedule() {\r\n\t\tschedule = new boolean[WEEK_DAYS][];\r\n\t\tfor(int i = 0; i < WEEK_DAYS; i++)\r\n\t\t\tschedule[i] = new boolean[SEGMENTS_PER_DAY];\r\n\t\tlisteners = new ArrayList<ScheduleChangeListener>();\r\n\t}",
"private Integer getStandardStart(int startTime) \n {\n \tif (startTime % 1440 > 960) {\n \t\tstartTime += 1440;\n \t}\n \tint startOfDay = startTime - (startTime % 1440);\n \t//we need a standard variable to indicate the day of week;\n \t//standard day starts at 08:00 = 480 minutes and ends at 16:00 = 960 minutes\n \tcapacityEndTime = startOfDay + 960;\n \treturn startOfDay + 480;\n }",
"private long getTimeIni(ArrayList<Point> r, ArrayList<Point> s){\n\t\t// Get the trajectory with latest first point\n\t\tlong t1 = s.get(0).timeLong > r.get(0).timeLong ? \n\t\t\t\ts.get(0).timeLong : r.get(0).timeLong;\n\t\treturn t1;\n\t}",
"public Pair<ProductionType,SoldierType> update() {\t\t\n\t\tif(current!=null) {\n\t\t\tnb_rounds--;\n\t\t\tif(nb_rounds==0) {\n\t\t\t\tnb_to_train--;\n\t\t\t\tPair<ProductionType,SoldierType> result = new Pair<ProductionType,SoldierType>(ProductionType.S,current.getType());\n\t\t\t\tif(nb_to_train==0)\n\t\t\t\t\tthis.nextTraining();\n\t\t\t\telse\n\t\t\t\t\tnb_rounds = current.getTime_prod();\n\t\t\t\treturn result;\n\t\t\t}\n\t\t}else if(upgrade){\n\t\t\tnb_rounds--;\n\t\t\tif(nb_rounds==0) {\n\t\t\t\tnb_to_train--;\n\t\t\t\tthis.nextTraining();\n\t\t\t\tupgrade = false;\n\t\t\t\treturn new Pair<ProductionType,SoldierType>(ProductionType.U,null);\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}",
"private void setWinningTuples() {\n\t\tWINS = new ArrayList<Set<CMNMove>>();\n\t\tSet<CMNMove> winSet = new TreeSet<CMNMove>();\n\t\tfor (int i = MM; i > 0; i--) {\n\t\t\tknapsack(winSet, CC, i, NN);\n\t\t}// end for\n\n\t}",
"public void generateWeeklySchedule(){\r\n for (int i = 0; i < numDayWorkWeek; i++)\r\n weeklySchedule.get(i).clear();\r\n\r\n int day = 0;\r\n int workHrs = 0;\r\n\r\n for (Task unfinishedTask: unfinished){\r\n if (day > numDayWorkWeek - 1) break;\r\n\r\n //if there is room for this task --> add it. Else, move to the next day\r\n if (workHrs + unfinishedTask.getHrsLeft() <= dailyWorkload){\r\n weeklySchedule.get(day).add(unfinishedTask);\r\n workHrs += unfinishedTask.getHrsLeft();\r\n }\r\n else{\r\n day++;\r\n weeklySchedule.get(day).add(unfinishedTask);\r\n workHrs = unfinishedTask.getHrsLeft();\r\n }\r\n }\r\n }",
"void lowerNumberOfStonesLeftToPlace();",
"public static void main(String[] args) throws FileNotFoundException, IOException {\nfor (double b = 0.5; b < 0.51; b+=0.1) {\n for (double k = 4.40; k < 4.5; k+=0.5) {\n Machine.b = 0.5; //0.2 - ATCnon-delay\n Machine.k = 1.5; //1.4 - ATCnon delay\n int hits = 0;\n engineJob = new cern.jet.random.engine.MersenneTwister(99999);\n noise = new cern.jet.random.Normal(0, 1, engineJob);\n SmallStatistics[] result = new SmallStatistics[5];\n result[0] = new SmallStatistics();\n result[1] = new SmallStatistics();\n for (int ds = 0; ds < 2; ds++) {\n JSPFramework[] jspTesting = new JSPFramework[105];\n for (int i = 0; i < jspTesting.length; i++) {\n jspTesting[i] = new JSPFramework();\n jspTesting[i].getJSPdata(i*2 + 1);\n }\n //DMU - instances (1-80)//la - instances (81-120)\n //mt - instances (121/-123)//orb - instances (124-133)//ta -instances (134-173)\n //////////////////////////////////////////////\n for (int i = 0; i < jspTesting.length; i++) {\n double countEval = 0;\n double tempObj = Double.POSITIVE_INFINITY;\n double globalBest = Double.POSITIVE_INFINITY;\n boolean[] isApplied_Nk = new boolean[2]; //Arrays.fill(isApplied_Nk, Boolean.TRUE);\n int Nk = 0; // index of the Iterative dispatching rule to be used\n jspTesting[i].resetALL();\n boolean firstIteration = true;\n double countLargeStep = 0;\n do{\n countEval++;\n //start evaluate schedule\n jspTesting[i].reset();\n int N = jspTesting[i].getNumberofOperations();\n jspTesting[i].initilizeSchedule();\n int nScheduledOp = 0;\n\n //choose the next machine to be schedule\n while (nScheduledOp<N){\n\n Machine M = jspTesting[i].Machines[jspTesting[i].nextMachine()];\n\n jspTesting[i].setScheduleStrategy(Machine.scheduleStrategy.HYBRID );\n jspTesting[i].setPriorityType(Machine.priorityType.ATC);\n jspTesting[i].setNonDelayFactor(0.3);\n //*\n jspTesting[i].setInitalPriority(M);\n for (Job J:M.getQueue()) {\n double RJ = J.getReadyTime();\n double RO = J.getNumberRemainingOperations();\n double RT = J.getRemainingProcessingTime();\n double PR = J.getCurrentOperationProcessingTime();\n double W = J.getWeight();\n double DD = J.getDuedate();\n double RM = M.getReadyTime();\n double RWT = J.getCurrentOperationWaitingTime();\n double RFT = J.getFinishTime();\n double RNWT = J.getNextOperationWaitingTime();\n int nextMachine = J.getNextMachine();\n\n if (nextMachine==-1){\n RNWT=0;\n } else {\n RNWT = J.getNextOperationWaitingTime();\n if (RNWT == -1){\n RNWT = jspTesting[i].getMachines()[nextMachine].getQueueWorkload()/2.0;\n }\n }\n if (RWT == -1){\n RWT = M.getQueueWorkload()/2.0;\n }\n //J.addPriority((W/PR)*Math.exp(-maxPlus((DD-RM-PR-(RT-PR+J.getRemainingWaitingTime(M)))/(3*M.getQueueWorkload()/M.getNumberofJobInQueue())))); //iATC\n //J.addPriority((PR*PR*0.614577*(-RM-RM/W)-RT*PR*RT/W)\n // -(RT*PR/(W-0.5214191)-RM/W*PR*0.614577+RT*PR/(W-0.5214191)*2*RM/W));\n //J.addPriority(((W/PR)*((W/PR)/(RFT*RFT)))/(max(div((RFT-RT),(RWT/W)),IF(RFT/W-max(RFT-RT,DD),DD,RFT))+DD/RFT+RFT/W-max(RFT-RFT/W,DD))); //best TWT priorityIterative\n if (Nk==0)\n //J.addPriority(min(W/PR-RFT+min(RT,W/RFT),((min(RT,RNWT-RFT)/(RJ-min(RWT,RFT*0.067633785)))/(RJ-min(RWT,RFT*0.067633785))))/RFT);\n J.addPriority(min(W/PR-RFT+min(RT,W/RFT),((div(min(RT,RNWT-RFT),(RJ-min(RWT,RFT*0.067633785))))/(RJ-min(RWT,RFT*0.067633785))))/RFT);\n else\n J.addPriority(min((((W/PR)/RFT)/(2*RNWT+max(RO,RFT)))/(PR+RNWT+max(RO,RFT)),((W/PR)/RFT)/PR)/RFT);\n }\n //jspTesting[i].calculatePriority(M);\n jspTesting[i].sortJobInQueue(M);\n Job J = M.completeJob();\n if (!J.isCompleted()) jspTesting[i].Machines[J.getCurrentMachine()].joinQueue(J);\n nScheduledOp++;\n }\n double currentObj = -100;\n currentObj = jspTesting[i].getTotalWeightedTardiness();\n if (tempObj > currentObj){\n tempObj = currentObj;\n jspTesting[i].recordSchedule();\n Arrays.fill(isApplied_Nk, Boolean.FALSE);\n //System.out.println(\"Improved!!!\");\n }\n else {\n isApplied_Nk[Nk] = true;\n if (!isNextApplied(Nk, isApplied_Nk)) Nk = circleShift(Nk, isApplied_Nk.length);\n else {\n if (globalBest>tempObj) {\n globalBest = tempObj;\n jspTesting[i].storeBestRecordSchedule();\n } jspTesting[i].restoreBestRecordSchedule();\n if (countLargeStep<1) {\n tempObj = Double.POSITIVE_INFINITY;\n Arrays.fill(isApplied_Nk, Boolean.FALSE);\n jspTesting[i].shakeRecordSchedule(noise, engineJob, globalBest);\n countLargeStep++;\n }\n else break;\n }\n }\n firstIteration = false;\n \n } while(true);\n result[ds].add(jspTesting[i].getDevREFTotalWeightedTardiness(globalBest));\n if (jspTesting[i].getDevLBCmax()==0) hits++;\n System.out.println(jspTesting[i].instanceName + \" & \"+ globalBest + \" & \" + countEval);\n }\n }\n //jsp.schedule();\n //*\n System.out.println(\"*************************************************************************\");\n System.out.println(\"[ & \" + formatter.format(result[0].getMin()) + \" & \"\n + formatter.format(result[0].getAverage()) + \" & \" + formatter.format(result[0].getMax()) +\n \" & \" + formatter.format(result[1].getMin()) + \" & \"\n + formatter.format(result[1].getAverage()) + \" & \" + formatter.format(result[1].getMax()) + \"]\");\n //*/\n System.out.print(\"\"+formatter.format(result[0].getAverage()) + \" \");\n }\n System.out.println(\"\");\n}\n }",
"Schedule createSchedule();",
"public String[] runRegularSeason()\n {\n int r = new Random().nextInt(1 + 1);\n String[] temp;\n\n int starting = new Random().nextInt(14 + 1);\n int ending = new Random().nextInt(14 + 1);\n\n for(int i = 0; i < standings.length; i++)\n {\n temp = standings[ending];\n\n if(standings[ending][1].compareTo(standings[starting][1]) > 0 && r == 1)\n {\n standings[ending] = standings[starting];\n standings[starting] = temp;\n }\n\n starting = new Random().nextInt(14 + 1);\n ending = new Random().nextInt(14 + 1);\n r = new Random().nextInt(1 + 1);\n }\n\n //Set playoff Array\n for(int i = 0; i < playoffs.length; i++)\n {\n playoffs[i] = standings[i][0];\n }\n\n return playoffs;\n }",
"public double evalSecDiff(Schedule sched) {\n\t\t\n\t\tint failCount = 0;\n\t\tArrayList<Course> sectionsOfCourse = new ArrayList<Course>(); //A list of all the sections for a class\n\t\tArrayList<Course> alreadyDone = new ArrayList<Course>(); //List of courses already looked\n\t\tCourse workingCourse, tempCourse;\n\t\tTimeSlot workingTimeSlot;\n\t\t\n\t\tfor(int i = 0;i<sched.getCourses().size();i++)\n\t\t{\n\t\t\tsectionsOfCourse = new ArrayList<Course>();\n\t\t\tworkingCourse = sched.getCourses().get(i);\n\t\t\t\n\t\t\t//If we haven't already looked at this course\n\t\t\tif((!alreadyDone.contains(workingCourse)) && workingCourse.getDepartment().equals(\"CPSC\"))\n\t\t\t{\n\t\t\t\t\n\t\t\t\tsectionsOfCourse.add(workingCourse);\n\t\t\t\talreadyDone.add(workingCourse);\n\t\t\t\t\n\t\t\t\t//Traverse through the course list and find all the sections\n\t\t\t\t//of the selected working course\n\t\t\t\tfor(int j = 0;j<sched.getCourses().size();j++)\n\t\t\t\t{\n\t\t\t\t\ttempCourse = sched.getCourses().get(j);\n\t\t\t\t\t\n\t\t\t\t\t//If they are the same course (with different sections)\n\t\t\t\t\tif(tempCourse.getDepartment().equals(workingCourse.getDepartment()) &&\n\t\t\t\t\t\t\ttempCourse.getNumber() == workingCourse.getNumber() &&\n\t\t\t\t\t\t\ttempCourse.getSection() != workingCourse.getSection())\n\t\t\t\t\t{\n\t\t\t\t\t\tsectionsOfCourse.add(tempCourse);\n\t\t\t\t\t\talreadyDone.add(tempCourse);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif(sectionsOfCourse.size() >1)\n\t\t\t\t{\n\t\t\t\t\t//System.out.println(sectionsOfCourse.size());\n\t\t\t\t\t//At this point, sections of course is all filled up with the sections of one course\n\t\t\t\t\t//Now we have to check that they all have different time slots\n\t\t\t\t\twhile(sectionsOfCourse.size() > 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tworkingTimeSlot = sectionsOfCourse.get(0).getSlot();\n\t\t\t\t\t\t\n\t\t\t\t\t\tif(workingTimeSlot != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfor(int j = 1;j<sectionsOfCourse.size();j++)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif(workingTimeSlot.getDay().equals(sectionsOfCourse.get(j).getSlot().getDay()) &&\n\t\t\t\t\t\t\t\t\t\tworkingTimeSlot.getStartTime() == sectionsOfCourse.get(j).getSlot().getStartTime())\n\t\t\t\t\t\t\t\t\tfailCount++;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tsectionsOfCourse.remove(0);\n\t\t\t\t\t}\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\t\t\n\t\treturn failCount * this.get_penSection();\n\t}",
"public void run() {\r\n\t\tint miCiclo = cicloRR;\r\n\t\tint misRafagas = rafagasRR;\r\n\t\t\r\n\t\tfloat indicePenalizacion = (float) 0.00;\r\n\t\tfloat penalizacion = (float) 0.00;\r\n\t\tfloat indicePenalizacionPorProceso =(float) 0.00;\r\n\t\t\r\n\t\t//Como vamos a reducir el valor del quantum antes del principio de ciclo\r\n\t\t//Sumamos 1 al quantum original, así compensamos esa reducción en el primer\r\n\t\t//ciclo de ejecución y realizamos un ciclo de quantum completo\r\n\t\tint miQuantum = quantumRR + 1;\r\n\t\t\r\n\t\tfor (miCiclo = 0; miCiclo < misRafagas; miCiclo++) {\r\n\t\t\t//Compruebo si algún elemento coincide su llegada con el ciclo\r\n\t\t\t//Si coincide, lo añado a la cola\r\n\t\t\tfor (int i = 0; i<miListaRR.size(); i++) {\r\n\t\t\t\tif(miListaRR.get(i).getLlegada() == cicloRR) {\r\n\t\t\t\t\tcolaProcesosRR.add(miListaRR.get(i));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t//Sumamos 1 al ciclo\r\n\t\t\tcicloRR++;\r\n\t\t\t\t\r\n\t\t\t//Restamos 1 al quantum restante\r\n\t\t\tmiQuantum--;\r\n\t\t\t//Si el quantum es 0, lo reiniciamos y enviamos el 1er elemento de la cola al final\r\n\t\t\tif (miQuantum == 0) {\r\n\t\t\t\tmiQuantum = quantumRR;\r\n\t\t\t\tcolaProcesosRR.add(colaProcesosRR.peek());\r\n\t\t\t\tcolaProcesosRR.poll();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//Restamos 1 a la rafaga pendiente\r\n\t\t\tcolaProcesosRR.peek().setRafaga(colaProcesosRR.peek().getRafaga()-1);\r\n\t\t\t\t\r\n\t\t\t//Escribimos la línea con la información del proceso\r\n\t\t\t//Si al proceso le quedan 0 ráfagas, ha terminado, así que lo sacamos de la cola\r\n\t\t\tif (colaProcesosRR.peek().getRafaga() == 0) {\r\n\r\n\t\t\t\tSystem.out.println(\t\"Ciclo \" + cicloRR + \r\n\t\t\t\t\t\t\t\t\t\". Proceso \" + colaProcesosRR.peek().getNombre() + \r\n\t\t\t\t\t\t\t\t\t\". Ráfagas pendientes: \" + colaProcesosRR.peek().getRafaga() +\r\n\t\t\t\t\t\t\t\t\t\" FIN DEL PROCESO \" + colaProcesosRR.peek().getNombre()); \r\n\t\t\t\tcolaProcesosRR.peek().setSalida(cicloRR);\r\n\t\t\t\tcolaProcesosRR.poll();\r\n\t\t\t\tmiQuantum = quantumRR+1;\r\n\t\t\t}\t\t\t\t\r\n\t\t\t//Si le quedan ráfagas pendientes, mostramos la información y volvemos al principio\r\n\t\t\telse {\r\n\t\t\t\tSystem.out.println(\t\"Ciclo \" + cicloRR + \r\n\t\t\t\t\t\t\t\t\t\". Proceso \" + colaProcesosRR.peek().getNombre() + \r\n\t\t\t\t\t\t\t\t\t\". Ráfagas pendientes: \" + colaProcesosRR.peek().getRafaga());\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println(\"\\n\" + \"Índices de penalización:\" + \"\\n\");\r\n\t\t\r\n\t\t//Para cada proceso, calculamos la penalización y la vamos añadiendo a un total\r\n\t\tfor (int i = 0; i<miListaRR.size() ; i++) {\r\n\t\t\tpenalizacion = (float) (miListaRR.get(i).getSalida()-miListaRR.get(i).getLlegada()) / miListaRR.get(i).getRafagaInicial();\r\n\t\t\tindicePenalizacionPorProceso = penalizacion / miListaRR.size();\r\n\t\t\tindicePenalizacion = indicePenalizacion + indicePenalizacionPorProceso;\r\n\t\t\tSystem.out.println(\"Índice de penalización del proceso \" + miListaRR.get(i).getNombre() + \": \" + penalizacion);\r\n\t\t}\r\n\t\t\r\n\t\t//Finalmente, mostramos la penalización total\r\n System.out.println(\"\\n\" + \"Índice de Penalización total: \" + indicePenalizacion);\r\n \r\n\t}",
"private void createConstraintsForSingleton() {\n \t\tSet s = slice.entrySet();\n \t\tfor (Iterator iterator = s.iterator(); iterator.hasNext();) {\n \t\t\tMap.Entry entry = (Map.Entry) iterator.next();\n \t\t\tHashMap conflictingEntries = (HashMap) entry.getValue();\n \t\t\tif (conflictingEntries.size() < 2)\n \t\t\t\tcontinue;\n \n \t\t\tCollection conflictingVersions = conflictingEntries.values();\n \t\t\tString singletonRule = \"\"; //$NON-NLS-1$\n \t\t\tArrayList nonSingleton = new ArrayList();\n \t\t\tint countSingleton = 0;\n \t\t\tfor (Iterator conflictIterator = conflictingVersions.iterator(); conflictIterator.hasNext();) {\n \t\t\t\tIInstallableUnit conflictElt = (IInstallableUnit) conflictIterator.next();\n \t\t\t\tif (conflictElt.isSingleton()) {\n \t\t\t\t\tsingletonRule += \" -1 \" + getVariable(conflictElt); //$NON-NLS-1$\n \t\t\t\t\tcountSingleton++;\n \t\t\t\t} else {\n \t\t\t\t\tnonSingleton.add(conflictElt);\n \t\t\t\t}\n \t\t\t}\n \t\t\tif (countSingleton == 0)\n \t\t\t\tcontinue;\n \n \t\t\tfor (Iterator iterator2 = nonSingleton.iterator(); iterator2.hasNext();) {\n \t\t\t\tconstraints.add(singletonRule + \" -1 \" + getVariable((IInstallableUnit) iterator2.next()) + \" >= -1;\"); //$NON-NLS-1$ //$NON-NLS-2$\n \t\t\t}\n \t\t\tsingletonRule += \" >= -1;\"; //$NON-NLS-1$\n \t\t\tconstraints.add(singletonRule);\n \t\t}\n \t}",
"public void scheduleMarathon()\n\t{\n\n\t\t//Create new threads\n\t\tThread h = new Thread(new ThreadRunner(HARE,H_REST,H_SPEED)); \n\t\tThread t = new Thread(new ThreadRunner(TORTOISE,T_REST,T_SPEED)); \n\n\t\tArrayList<Thread> runnerList = new ArrayList<Thread>();\n\t\trunnerList.add(h);\n\t\trunnerList.add(t);\n\n\t\tSystem.out.println(\"Get set...Go! \");\n\t\t//Start threads\n\t\tfor (Thread i: runnerList){\n\t\t\ti.start();\n\t\t}\n\n\t\twaitMarathonFinish(runnerList);\n\t}",
"private void setTableModel(List<SlotDto> slots){\n \n int size = 0;\n if(slots != null && !slots.isEmpty())\n size = slots.size();\n \n Object [][] slotsArr = new Object [25][9];\n\n // set days to table cells\n slotsArr[0][0] = \"Sunday\";\n slotsArr[5][0] = \"Monday\";\n slotsArr[10][0] = \"Tuesday\";\n slotsArr[15][0] = \"Wednesday\";\n slotsArr[20][0] = \"Thursday\";\n\n // loop for days' rows of schedule\n for(int r =0;r<5;r++){\n r=r*5;\n \n // loop for slots' columns of schedule \n for (int c=0 ; c<4 ; c++){ \n int cell=c*2;\n \n // loop to get slot of indexed day and time slot \n for( int i=0 ; i<size ; i++ ){\n if( (slots.get(i).getNum()== (c+1) && (slots.get(i).getDay().equals(slotsArr[r][0])) ) ){\n \n // set course name and code od slot \n slotsArr[r][cell+1] = slots.get(i).getCourse().getName();\n slotsArr[r][cell+2] = slots.get(i).getCourse().getCode();\n \n // set type of slot \n slotsArr[r+2][cell+1] = slots.get(i).getSlot_type();\n \n // set location of slot\n slotsArr[r+3][cell+1] = slots.get(i).getLocation().getName();\n \n \n // check slot type then set plt of slot\n if(slots.get(i).getSlot_type().equals(\"LECTURE\")){\n slotsArr[r+3][cell+2] = slots.get(i).getCourse().getPlt_lecture().getCode();\n System.out.println(\"plt\"+slots.get(i).getCourse().getPlt_lecture().getCode());\n }\n if(slots.get(i).getSlot_type().equals(\"SECTION\")){\n slotsArr[r+3][cell+2] = slots.get(i).getCourse().getPlt_lecture().getCode();\n System.out.println(\"plt\"+slots.get(i).getCourse().getPlt_lecture().getCode()); \n }\n \n // set student number of slot \n slotsArr[r+4][cell+1] = \"STUDENT NUMBER\";\n slotsArr[r+4][cell+2] = slots.get(i).getStudent_number();\n \n /*\n * set staff of slot then check if members > 1 then concatenate all members' names\n * and set to cell */\n String staff = slots.get(i).getStaff().get(0).getPosition() + \"/\" +\n slots.get(i).getStaff().get(0).getName() ;\n \n System.out.println(\"staff size\" + slots.get(i).getStaff().size()); \n System.out.println(\"user size\" + slots.get(i).getUser().size()); \n \n if(slots.get(i).getStaff().size()>1){\n for(int j=1 ; j<slots.get(i).getStaff().size() ; j++ ){\n staff=staff+\" # \" +slots.get(i).getStaff().get(j).getPosition()+\"/\"+\n slots.get(i).getStaff().get(j).getName() ; \n }\n }\n slotsArr[r+1][cell+1] = staff;\n \n /*\n * set user email of slot then check if users > 1 then concatenate all users' email \n * and set to cell */ \n String[] email = slots.get(i).getUser().get(0).getEmail().split(\"@\", 2);\n String user = email[0];\n if(slots.get(i).getUser().size()>1){\n for(int k=0 ; k<slots.get(i).getUser().size() ; k++){\n String[] _email = slots.get(i).getUser().get(k).getEmail().split(\"@\", 2);\n user = user +\" # \" + _email[0]; \n }\n }\n slotsArr[r+1][cell+2] = user;\n }\n }\n }\n }\n scheduleTable.setModel(new javax.swing.table.DefaultTableModel(slotsArr,\n new String [] {\n \"Time Slot\", \"First\",\" \", \"Second\", \" \" ,\"Third\",\" \",\"Fourth\",\" \"\n }\n ));\n\n }",
"public boolean scheduleAlg1(int currBoolReset, int maxGuidesPerTourInt, int maxToursPerGuideInt, int minGuidesPerTourInt, int minToursPerGuideInt){\n\t\t\r\n\t\tint numberOfWeeks = findNumWeeks();\r\n\t\tfor(int x = 0; x < numberOfWeeks; x++){\r\n\t\t\tfor(int y = 0; y < personList.size(); y++){\r\n\t\t\t\t//System.out.println(\"a\");\r\n\t\t\t\tpersonList.get(y).weeks.add(false);\r\n\t\t\t}\r\n\t\t}\r\n\t\t//System.out.println(\"here it's \" + personList.get(0).weeks.size());\r\n\t\t\r\n\t\tint currentAvailabilityBool; //This is the index in the availability boolean array list that is currently relevant. \r\n\t\tint week = 0;\r\n\t\tboolean innerWhile, outerWhile;\r\n\t\tint currentAvailabilityInt, currentToursGivenInt; \r\n\t\tcurrentHighestTourCount = 0;\r\n\t\tif(currBoolReset >= toursInTheWeek){\r\n\t\t\tcurrBoolReset = 0;\t\t\t\r\n\t\t}\r\n\t\tfor(int i = 0; i < maxGuidesPerTourInt; i++){\r\n\t\t\t//System.out.println(\"guide: \" + i);\r\n\t\t\t//System.out.println(\"Adding guide \" + i);\r\n\t\t\tcurrentAvailabilityBool = currBoolReset; //Have to reset it each time we loop through. \r\n\t\t\t//System.out.println(\"OUTERMOST LOOP IS \" + i);\r\n\t\t\tfor(int j = 0; j < dayList.size(); j++){\r\n\t\t\t\tweek = getWeekFromDay(j);\r\n\t\t\t\t//System.out.println(\"Day: \" + j + \" Week: \" + week);\r\n\t\t\t\tif(!dayList.get(j).holiday){ //If the current day isn't a holiday.\r\n\t\t\t\t\t//Go through all the tours on the current day.\r\n\t\t\t\t\t//System.out.println(dayList.get(j).numberOfTours + \" tours today\");\r\n\t\t\t\t\tfor(int k = 0; k < dayList.get(j).numberOfTours; k++){\r\n\t\t\t\t\t\t//System.out.println(\"Looking at tour \" + k);\r\n\t\t\t\t\t\touterWhile = true;\r\n\t\t\t\t\t\tcurrentToursGivenInt = 0;\r\n\t\t\t\t\t\twhile(outerWhile){\r\n\t\t\t\t\t\t\tinnerWhile = true;\r\n\t\t\t\t\t\t\t//System.out.println(\"OUTER WHILE - Looking at guides who have given \" + currentToursGivenInt + \" tours\");\r\n\t\t\t\t\t\t\tcurrentAvailabilityInt = 0;\r\n\t\t\t\t\t\t\twhile(innerWhile){\r\n\t\t\t\t\t\t\t\t//System.out.println(\"INNER WHILE - Availability of \" + currentAvailabilityInt);\r\n\t\t\t\t\t\t\t\t//numOfAvailableSlots\r\n\t\t\t\t\t\t\t\t//Go through guides and find one with an availability matching the currentAvailabilityInt and a true value \r\n\t\t\t\t\t\t\t\t//at the currentAvailabilityBool. Set lookingForAGuide to true and add that guide to the current tour's list,\r\n\t\t\t\t\t\t\t\t//as long as all the requirements are met. \r\n\t\t\t\t\t\t\t\t//Remember to check if currentHighestTourCount needs to be incremented.\r\n\t\t\t\t\t\t\t\tfor(int m = 0; m < personList.size(); m++){\r\n\t\t\t\t\t\t\t\t\t//System.out.println(\"m is \" + m + \" and currentAvailabilityBool is \" + currentAvailabilityBool);\r\n\t\t\t\t\t\t\t\t\tif(personList.get(m).toursThisMonth == currentToursGivenInt && personList.get(m).numOfAvailableSlots == currentAvailabilityInt && personList.get(m).availabilityBooleans.get(currentAvailabilityBool))\r\n\t\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\t\t//Then we've found a guide that's got the minimum availability and is available at this time.\r\n\t\t\t\t\t\t\t\t\t\t//Check requirements, then add them if they're met. \r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\tif(personList.get(m).toursThisMonth < maxToursPerGuideInt){\r\n\t\t\t\t\t\t\t\t\t\t\t//Have to check if they've already given a tour that day. \r\n\t\t\t\t\t\t\t\t\t\t\tif(personList.get(m).checkIfScheduled(j) && personList.get(m).weeks.get(week) == false){ //Make sure they haven't been given a tour on this day before.\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).toursThisMonth++;\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).scheduledDays.add(j); //Add this day to the list. \r\n\t\t\t\t\t\t\t\t\t\t\t\tif(personList.get(m).toursThisMonth > currentHighestTourCount){\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tcurrentHighestTourCount = personList.get(m).toursThisMonth;\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t//System.out.println(\"Current highest tour count is \" + currentHighestTourCount);\r\n\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t\t\tdayList.get(j).tourList.get(k).addGuide(personList.get(m));\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).tourList.add(dayList.get(j).tourList.get(k)); //Add the tour to that guide's list of tours.\r\n\t\t\t\t\t\t\t\t\t\t\t\t//System.out.println(\"We just added \" + personList.get(m).name);\r\n\t\t\t\t\t\t\t\t\t\t\t\tinnerWhile = false;\r\n\t\t\t\t\t\t\t\t\t\t\t\touterWhile = false;\r\n\t\t\t\t\t\t\t\t\t\t\t\tpersonList.get(m).weeks.set(week, true);\r\n\t\t\t\t\t\t\t\t\t\t\t\tm = personList.size();\r\n\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}//For m\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\tcurrentAvailabilityInt++;\r\n\t\t\t\t\t\t\t\tif(currentAvailabilityInt > toursInTheWeek){\r\n\t\t\t\t\t\t\t\t\tinnerWhile = false;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t} //inner while\r\n\t\t\t\t\t\t\tcurrentToursGivenInt++;\r\n\t\t\t\t\t\t\tif(currentToursGivenInt > currentHighestTourCount){\r\n\t\t\t\t\t\t\t\t//We couldn't find a tour guide. Do we break somehow?\r\n\t\t\t\t\t\t\t\tif(i < minGuidesPerTourInt){\r\n\t\t\t\t\t\t\t\t\tSystem.out.println(\"Returned here\");\r\n\t\t\t\t\t\t\t\t\treturn false; //Because we never reached the minimum guides per tour number.\r\n\t\t\t\t\t\t\t\t}\t\r\n\t\t\t\t\t\t\t\t//Otherwise we can just skip this tour. \r\n\t\t\t\t\t\t\t\touterWhile = false;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t} //outer while\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//Here's where we update the counter for which availability bool we're looking at.\r\n\t\t\t\t\t\tcurrentAvailabilityBool++;\r\n\t\t\t\t\t\tif(currentAvailabilityBool >= toursInTheWeek){\r\n\t\t\t\t\t\t\tcurrentAvailabilityBool = 0; //Time to reset it.\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}//For k\r\n\t\t\t\t}//If not a holiday.\r\n\t\t\t\telse{\r\n\t\t\t\t\tfor(int k = 0; k < dayList.get(j).numberOfTours; k++){\r\n\t\t\t\t\t\tcurrentAvailabilityBool++;\r\n\t\t\t\t\t\tif(currentAvailabilityBool >= toursInTheWeek){\r\n\t\t\t\t\t\t\tcurrentAvailabilityBool = 0; //Time to reset it.\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}//For j\r\n\t\t}//For i\r\n\t\t//Check if minToursPerGuide has been met.\r\n\t\tif(!checkMinToursPerGuide(minToursPerGuideInt)){\r\n\t\t\tSystem.out.println(\"Min tours per guide not met\");\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\treturn true; //It worked!\r\n\t}",
"public Task(int i, int R){\n\n\t\ttasknum = i;\n\t\tallocation = new ArrayList<Integer>();\n\n\t\tfor(int j = 0; j < R; j++){\n\n\t\t\tallocation.add(0);\n\t\t\tclaims.add(0);\n\t\t}\n\t}",
"public Sim sim()\n { if(!this.isEmptyStepList()) //non-empty StepList the weight is not 0\n { double lwb=increase()/weight();\n double upb=1-decrease()/weight();\n //System.out.println(\"weight()=\"+weight());\n //System.out.println(\"[\"+lwb+\",\"+upb+\"]\");\n return new Sim(lwb, upb);\n }\n else return new Sim(0.0,0.0);\n }",
"int getMin() \n\t{ \n\t\tint x = min.pop(); \n\t\tmin.push(x); \n\t\treturn x; \n\t}",
"public Builder clearScheduling() {\n \n scheduling_ = 0;\n onChanged();\n return this;\n }",
"private void removeFromSavedScheduleList() {\n if (!yesNoQuestion(\"This will print every schedule, are you sure? \")) {\n return;\n }\n\n showAllSchedules(scheduleList.getScheduleList());\n\n System.out.println(\"What is the number of the one you want to remove?\");\n int removeIndex = obtainIntSafely(1, scheduleList.getScheduleList().size(), \"Number out of bounds\");\n scheduleList.getScheduleList().remove(removeIndex - 1);\n System.out.println(\"Removed!\");\n }",
"void makeNborLists(){\n\t\t\tfor (int i = 0; i < N; i++){\n\t\t\t\tint ct = 0;\n\t\t\t\tint boundsCt = 0;\n\t\t\t\tfor (int j = 0; j < maxNbors; j++){\n\t\t\t\t\tint nborSite = nborList[i][j];\n\t\t\t\t\tif(nborSite>=1){\n\t\t\t\t\t\tif (aliveLattice[nborSite]){\n\t\t\t\t\t\t\tct += 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t}else{\n\t\t\t\t\t\tboundsCt += 1;\n\t\t\t\t\t}\n\t\t\t\t\tint noDead = maxNbors - ct;\n\t\t\t\t\tfracDeadNbors[i] = (double)noDead/maxNbors;\n\t\t\t\t\tif(deadDissipation==true) noNborsForSite[i] = noNbors; \n\t\t\t\t\telse if (deadDissipation==false){\n\t\t\t\t\t\tif(boundaryConditions==\"Open\")\n\t\t\t\t\t\t\tnoNborsForSite[i]=ct+boundsCt;\n\t\t\t\t\t\telse if(boundaryConditions == \"Periodic\")\n\t\t\t\t\t\t\tnoNborsForSite[i]=ct;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(deadDissipation==true){\n\t\t\t\tfor (int i = 0; i < N; i++)\tnoNborsForSite[i] = noNbors; \n\t\t\t\tfor (int i = 0; i < N; i++){\n\t\t\t\t\tint ct = 0;\n\t\t\t\t\tfor (int j = 0; j < maxNbors; j++){\n\t\t\t\t\t\tif (aliveLattice[nborList[i][j]]){\n\t\t\t\t\t\t\tct += 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tint noDead = maxNbors - ct;\n\t\t\t\t\t\tfracDeadNbors[i] = (double)noDead/maxNbors;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}else if (deadDissipation==false){\n\t\t\t\tfor (int i = 0; i < N; i++){\n\t\t\t\t\tint ct = 0;\n\t\t\t\t\tfor (int j = 0; j < maxNbors; j++){\n\t\t\t\t\t\tif (aliveLattice[nborList[i][j]]){\n\t\t\t\t\t\t\tct += 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tint noDead = maxNbors - ct;\n\t\t\t\t\t\tfracDeadNbors[i] = (double)noDead/maxNbors;\n\t\t\t\t\t\tnoNborsForSite[i]=ct;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t}",
"public void creationSable(){\n\t\tfor(int x=2;x<=this.taille-3;x++) {\n\t\tfor(int y=2;y<=this.taille-3;y++) {\n\t\tif( grille.get(x).get(y).getTypeOccupation()==0 &&\n\t\t\t\tgrille.get(x+2).get(y).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x+2).get(y+2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x).get(y+2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x-2).get(y+2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x-2).get(y).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x-2).get(y-2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x).get(y-2).getTypeOccupation()!=3 &&\n\t\t\t\tgrille.get(x+2).get(y-2).getTypeOccupation()!=3 ) {\n\t\t\t\n\t\t\tint[] coord = new int[2];\n\t\t\tcoord[0]=x;\n\t\t\tcoord[1]=y;\n\t\t\tSable sable = new Sable(coord);\n\t\t\tgrille.get(x).set(y, sable);\n\t\t}\n\t\t}\n\t\t}\n\t}",
"static Tour sequence() {\r\n\t\tTour tr = new Tour();\r\n\t\tfor (int i = 0; i < tr.length(); i++) {\r\n\t\t\ttr.index[i] = i;\r\n\t\t}\r\n\t\ttr.distance = tr.distance();\r\n\t\treturn tr;\r\n\t}",
"public void monteCarlo(BlackHoleBoard currentBoard){\n if(currentBoard.getBoardDepth() < (currentBoard.getGameDepth() - THRESHOLD)){\n HashMap<Integer,Integer> mapNextMovetoScore = new HashMap<>();//map first move to final outcome\n for(int i = 0; i < BlackHoleBoard.NUM_GAMES_TO_SIMULATE; i++){\n //ArrayList<Integer> currentIndices = new ArrayList<>();\n int finalScore = 0;\n BlackHoleBoard currentWorkingBoard = new BlackHoleBoard();\n currentWorkingBoard.copyBoardState(currentBoard);\n int score = 0;\n int index = currentWorkingBoard.pickRandomMove();\n while(!currentWorkingBoard.gameOver()){\n //int index = currentWorkingBoard.pickRandomMove();\n\n currentWorkingBoard.setValue(index);\n index = currentWorkingBoard.pickRandomMove();\n\n\n }\n if(currentWorkingBoard.gameOver()){\n score = currentWorkingBoard.getScore();\n }\n mapNextMovetoScore.put(index,score);\n }\n int minScore = 0;\n int indexWithMinScore = 0;\n for(int key: mapNextMovetoScore.keySet()){\n if(mapNextMovetoScore.get(key) < minScore){\n minScore = mapNextMovetoScore.get(key);\n indexWithMinScore = key;\n }\n }\n //ArrayList<Integer> reccomendedMoves = mapNextMovetoScore.get(minScore);\n nextMove = indexWithMinScore;\n }else {\n nextMove = -1;\n }\n }",
"public MinStack() {\n capacity = 1 << 4;\n nums = new int[capacity];\n mins = new int[capacity];\n }",
"private void CreatingBeautyContent(int count,int typeSymmetry, int methodSearch) {\n\t\t\tConstraintsPlacement objConstraints= new ConstraintsPlacement(this);\r\n\t\t\t//Creating array with states\r\n\t\t\tArrayList<BlockNode> states = new ArrayList<BlockNode>();\r\n\t\t\t//Building the graph in a deph way\r\n\t \tGraphBuilder objGrapB= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB2= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB3= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB3a= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB4= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB5= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB6= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB7= new GraphBuilder(1);\r\n\t \tGraphBuilder objGrapB8= new GraphBuilder(1);\r\n\t \t\r\n\t \tobjGrapB.setWparamether(wParamether);\r\n\t \tobjGrapB2.setWparamether(wParamether);\r\n\t \tobjGrapB3.setWparamether(wParamether);\r\n\t \tobjGrapB3a.setWparamether(wParamether);\r\n\t \tobjGrapB4.setWparamether(wParamether);\r\n\t \tobjGrapB5.setWparamether(wParamether);\r\n\t \tobjGrapB6.setWparamether(wParamether);\r\n\t \tobjGrapB7.setWparamether(wParamether);\r\n\t \tobjGrapB8.setWparamether(wParamether);\r\n\t \t\r\n\t \tint numElements=objElem.getNumberObjects();\r\n\t \tint numEnemies=objElem.getNumberObjectsEnemies();\r\n\t \tint globalControlSearch=0;\r\n\t \t\r\n\t \tdouble time6=0;\r\n\t \tdouble time7=0;\r\n\t \tdouble time3=0;\r\n\t \tdouble time4=0;\r\n\t \tdouble time5=0;\r\n\t \tdouble time8=0;\r\n\t \t\r\n\t \tdouble startTime=0;\r\n\t \tdouble stopTime=0;\r\n\t \t\r\n\t \tdouble sum3=0;\r\n\t \tdouble sum4=0;\r\n\t \tdouble sum5=0;\r\n\t \tdouble sum6=0;\r\n\t \tdouble sum7=0;\r\n\t \tdouble sum8=0;\r\n\r\n\t \t\r\n\t \t//Beststates=objGrapB.basicDepthSearch(mediumStraight,height,numElements,numElements,states,objConstraints, objElem.getFinalList(),objElem);\r\n\t \t//Beststates=objGrapB.relativePositionDepthSearch(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,-mediumStraight+2,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch);\r\n\t \t//Beststates=objGrapB.relativeTransPositionDepthSearch(mediumStraight,height,numElements,numElements,states,objConstraints, objElem.getFinalList(),objElem,-mediumStraight+1,mediumStraight-1,floorTileHeight,0,0,currentState,hTable);\r\n\t \t//Beststates=objGrapB.DepthSearchCenterFrame(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,1,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch);\r\n\t \t//Beststates=objGrapB.DepthSearchPruningAlt(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,1,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch);\r\n\t \t\r\n\t \r\n\r\n\t \r\n\t //3.3) Brute-force search\r\n\t //objElem.setFinalList(objElem.getFinalListNoOrder());\r\n\t \tfor(int i=0;i<1;i++)\r\n\t \t{\r\n\t \t\tstartTime = System.currentTimeMillis();\r\n\t \t\tBeststates3=objGrapB3.DepthSearchCenterFrameNoPruningNoRegionsNoObjects(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,0,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch,8,typeSymmetry);\r\n\t \t\tstopTime = System.currentTimeMillis();\r\n\t \t\ttime3 = stopTime - startTime;\r\n//\t \t\tround(time3,2);\r\n//\t \t\tdouble nodes3=round((double)objGrapB3.getCounterIDs(),2);\r\n//\t \t\tSystem.out.println(objGrapB3.bestSymmetryV+\" \"+time3+\" \"+((objGrapB3.getCounterIDs())));\r\n\t \t\tsum3=sum3+time3;\r\n\t \t}\r\n\t \ttime3=sum3/1;\r\n\t \ttime3=round(time3,2);\r\n\t //System.out.println(\"Time Brute-force search \"+elapsedTime);\r\n\t \t\r\n\t \r\n\t \r\n\t //3.7) B&B+heuristic\r\n\t //objElem.setFinalList(objElem.getFinalListNoOrder());\r\n\t \tfor(int i=0;i<1;i++)\r\n\t \t{\r\n\t \t\tstartTime = System.currentTimeMillis();\r\n\t \t\tBeststates7=objGrapB7.depthSearchBBHeuristic(mediumStraight,height,numElements-numEnemies,numElements-numEnemies,states,objConstraints, objElem.getFinalList(),objElem,0,mediumStraight-2,floorTileHeight,0,0,numEnemies,random,globalControlSearch,8,typeSymmetry);\r\n\t \t\tstopTime = System.currentTimeMillis();\r\n\t \t\ttime7 = stopTime - startTime;\r\n//\t \t\tround(time7,2);\r\n//\t \t\tdouble nodes7=round((double)objGrapB3.getCounterIDs(),2);\r\n//\t \t\tSystem.out.println(objGrapB6.bestSymmetryV+\" \"+time6+\" \"+((objGrapB6.getCounterIDs())));\r\n\t \t\tsum7=sum7+time7;\r\n\t \t}\r\n\t \ttime7=sum7/1;\r\n\t \ttime7=round(time7,2);\r\n\t //System.out.println(\"Time B&B+heuristic + region ordering \"+elapsedTime);\r\n\t \t\r\n\t \t\r\n\t \t\r\n//\t \tif(objGrapB3.bestSymmetryV<objGrapB5.bestSymmetryV)\r\n//\t \t{\r\n//\t \t\tdouble bestSYmmetry=objGrapB3.bestSymmetryV;\r\n//\t \t\t//System.out.println(\"bestSym \"+bestSYmmetry);\r\n//\t \t\tBestGlobalstates=Beststates3;\r\n//\t \t\t\r\n//\t \t}\r\n//\t \telse\r\n//\t \t{\r\n//\t \t\tdouble bestSYmmetry=objGrapB5.bestSymmetryV;\r\n//\t \t\t//System.out.println(\"bestSym \"+bestSYmmetry);\r\n//\t \t\tBestGlobalstates=Beststates5;\r\n//\t \t}\r\n\t \t\r\n\t \tBestGlobalstates=Beststates7;\r\n\t \r\n\t \r\n\t \t//**System.out.println(\"Simetry 0-> Brute-force search order \"+objGrapB3a.bestSymmetryV);\t\r\n\t \t//System.out.println(\"Simetry 1-> Brute-force search \"+objGrapB3.bestSymmetryV);\t \t\r\n\t \t//System.out.println(\"Simetry 2-> B&B+oldheuristic \"+objGrapB4.bestSymmetryV);\r\n\t \t//**System.out.println(\"Simetry 3-> B&B+heuristic + object ordering \"+objGrapB2.bestSymmetryV);\t \t\r\n\t \t//System.out.println(\"Simetry 4-> B&B+ region + leviheuristic\"+objGrapB5.bestSymmetryV);\r\n\t \t//**System.out.println(\"Simetry 5-> B&B+heuristic + region ordering + object ordering \"+objGrapB.bestSymmetryV);\r\n\t \t//System.out.println(\"Simetry 6-> B&B+heuristic + leviheuristic \"+objGrapB6.bestSymmetryV);\r\n\t \t//System.out.println(\"Simetry 7-> B&B+oldoldheuristic \"+objGrapB7.bestSymmetryV);\r\n\t \t\r\n\t \t//**System.out.println( \"States 0 \"+objGrapB3a.getCounterIDs() );\r\n\t \t//System.out.println( \"States 1 \"+objGrapB3.getCounterIDs() );\r\n\t \t//System.out.println( \"States 2 \"+objGrapB4.getCounterIDs() );\r\n\t \t//**System.out.println( \"States 3 \"+objGrapB2.getCounterIDs() );\t \t\t \t\r\n\t \t//System.out.println( \"States 4 \"+objGrapB5.getCounterIDs() );\r\n\t \t//**System.out.println( \"States 5 \"+objGrapB.getCounterIDs() );\r\n\t \t//System.out.println( \"States 6 \"+objGrapB6.getCounterIDs() );\r\n\t \t//System.out.println( \"States 7 \"+objGrapB7.getCounterIDs() );\r\n\t \t\r\n\t \tdouble TimeRate7=time3/time7;\r\n\t \tdouble TimeRate6=time3/time6;\r\n\t \tdouble TimeRate5=time3/time5;\r\n\t \t\r\n\t \tTimeRate7=round(TimeRate7,2);\r\n\t \tTimeRate6=round(TimeRate6,2);\r\n\t \tTimeRate5=round(TimeRate5,2);\r\n\t \t\r\n\t \tdouble NodesRate7=(double)objGrapB3.getCounterIDs()/(double)objGrapB7.getCounterIDs();\r\n\t \tdouble NodesRate6=(double)objGrapB3.getCounterIDs()/(double)objGrapB6.getCounterIDs();\r\n\t \tdouble NodesRate5=(double)objGrapB3.getCounterIDs()/(double)objGrapB5.getCounterIDs();\r\n\t \t\r\n\t \tNodesRate7=round(NodesRate7,2);\r\n\t \tNodesRate6=round(NodesRate6,2);\r\n\t \tNodesRate5=round(NodesRate5,2);\r\n\r\n\t \t\r\n\t \t\r\n\r\n\t //imprimiendo los estados visitados\r\n\t /*\r\n\t Iterator<BlockNode> nombreIterator = states.iterator();\r\n\t while(nombreIterator.hasNext()){\r\n\t \tBlockNode elemento = nombreIterator.next();\r\n\t \tSystem.out.print(elemento.getID()+\" / \");\r\n\t }*/\r\n\t \r\n\t //here we are painting as the best branch founded\r\n\t \r\n\t //System.out.println(\"nene \"+BestGlobalstates.size());\r\n\t Iterator<BlockNode> nombreIterator = BestGlobalstates.iterator();\r\n\t while(nombreIterator.hasNext()){\r\n\t \tBlockNode elemento = nombreIterator.next();\r\n\t \t//System.out.print(elemento.getID()+\"(\"+elemento.getX()+\" \"+elemento.getY()+\" ) - \"+elemento.getType()+\" \"+elemento.getIdElement()+ \" / \");\r\n\t }\r\n\t \r\n\t \r\n\t //Here we will put the elements on the tile\r\n\t try {\r\n\t Level levelScreen=PaintElements(BestGlobalstates,this);\r\n\t Screen objScreen=new Screen();\r\n\t\t\tobjScreen.SaveScreen(levelScreen,odds,objElem);\r\n \t\tInformacoesTelas info = new InformacoesTelas();\r\n\t CopiaArquivos copiador = new CopiaArquivos();\r\n\t \r\n\t info = info.carregaInfoTela(\"infoTela\");\r\n\t\t\tinfo.setOutrasVariaveis(0, 0); // Salva outras informacoes da Tela\r\n\t\t\tinfo.salvaInfoTela(\"infoTela\", info);\t\t\t\t\t\r\n\t\t\tcopiador.copy(\"\" + count, \"Screens/\");\r\n\t\t\t\r\n\t } catch (ClassNotFoundException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t} catch (IOException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t}",
"public int[] mRtreeFromSource(int s,int k){\n double INFINITY = Double.MAX_VALUE;\n boolean[] SPT = new boolean[intersection];\n double[] d = new double[intersection];\n int[] parent = new int[intersection];\n\n for (int i = 0; i <intersection ; i++) {\n d[i] = INFINITY;\n parent[i] = -1;\n }\n\n d[s] = 0;\n parent[s]=s;\n\n MinHeap minHeap = new MinHeap(k);\n for (int i = 0; i <intersection ; i++) {\n minHeap.add(i,d[i]);\n }\n while(!minHeap.isEmpty()){\n\n int extractedVertex = minHeap.extractMin();\n\n if(d[extractedVertex]==INFINITY)\n break;\n\n SPT[extractedVertex] = true;\n\n LinkedList<Edge> list = g.adjacencylist[extractedVertex];\n for (int i = 0; i <list.size() ; i++) {\n Edge edge = list.get(i);\n int destination = edge.destination;\n if(SPT[destination]==false ) {\n\n double newKey = edge.weight ; //the different part with previous method\n double currentKey = d[destination];\n if(currentKey>=newKey){\n if(currentKey==newKey){\n if(extractedVertex<parent[destination]){\n minHeap.updateKey(newKey, destination, d[destination]);\n parent[destination] = extractedVertex;\n d[destination] = newKey;\n }\n }\n else {\n minHeap.updateKey(newKey, destination, d[destination]);\n parent[destination] = extractedVertex;\n d[destination] = newKey;\n }\n }\n }\n }\n }\n return parent;\n }",
"public void setRemainingToScenery(){\n\t\tfor(int i=0;i<grid.length;i++){\n\t\t\tfor(int j=0;j<grid[0].length;j++){\n\t\t\t\tif(grid[i][j]==null)\n\t\t\t\t\tgrid[i][j]=new Scenery(i*grid[0].length+j);\n\t\t\t}\n\t\t}\n\t}",
"public Schedule() {\n\t\tcourses = new ArrayList<Course>();\n\t}",
"public QwirkleSpiel()\n {\n beutel=new Beutel(3); //erzeuge Beutel mit 3 Steinfamilien\n spielfeld=new List<Stein>();\n\n rote=new ArrayList<Stein>(); //Unterlisten, die zum leichteren Durchsuchen des Spielfelds angelegt werden\n blaue=new ArrayList<Stein>();\n gruene=new ArrayList<Stein>();\n gelbe=new ArrayList<Stein>();\n violette=new ArrayList<Stein>();\n orangene=new ArrayList<Stein>();\n kreise=new ArrayList<Stein>();\n kleeblaetter=new ArrayList<Stein>();\n quadrate=new ArrayList<Stein>();\n karos=new ArrayList<Stein>();\n kreuze=new ArrayList<Stein>();\n sterne=new ArrayList<Stein>();\n\n erstelleListenMap();\n }",
"public void setSchedule(Schedule newSchedule) {\n\n schedule = newSchedule;\n }",
"public synchronized long getSlots() {\n return slots;\n }",
"private IScope getTrainScope(TrainSchedule trainSchedule) {\n\t\tEObject rootElement = EcoreUtil.getRootContainer(trainSchedule);\r\n\r\n\t\tif (rootElement instanceof Schedule) {\r\n\t\t\tSchedule schedule = (Schedule) rootElement;\r\n\r\n\t\t\tList<Train> trains = schedule.getDepots().stream().flatMap(d -> d.getTrains().stream())\r\n\t\t\t\t\t.collect(Collectors.toList());\r\n\t\t\treturn Scopes.scopeFor(trains);\r\n\t\t}\r\n\r\n\t\treturn null;\r\n\t}",
"public void arrivesAtTestSTation() throws InterruptedException {\n int max = 5;\n int min = 1;\n int range = max - min + 1;\n\n long time = System.currentTimeMillis();\n long timeTo = System.currentTimeMillis() + 7200;\n while(time <= timeTo){\n Thread.sleep(Times.calculateTimeDistributionForArrivingAtTheCarStation());\n int res = (int) ( Math.random()*range)+min;\n Car c = new Car(res);\n personsInCar += c.getNumberOfPassengers();\n carGenerated++;\n if(carQueue.size() >= Times.carQueueSize) {\n if(Times.enableDebugging)\n System.out.println(\"0. Car queue is to hight and needs to leave: \" + c.getIdentifier().getCarId() );\n carLeftLaneSinceItIsFull++;\n }else {\n c.setArrivesAtTestStation(true);\n c.setStartsWaiting(System.currentTimeMillis());\n c.setCurrentStation(\"Arrives Test Station\");\n synchronized (carQueue){\n carQueue.add(c);}\n // Collections.sort(carQueue);\n if(Times.enableDebugging)\n System.out.println(\"1. Arrives at the Teststation: \" + c.getIdentifier().getCarId() );\n }\n time = System.currentTimeMillis();\n }\n }",
"public Schedule getSchedule() {\n\n return schedule;\n }",
"void initFirstTower() {\n for (int i = 0; i < numDisks; i++) {\n towers[0].push(numDisks - i + 1);\n }\n }",
"private JCStatement makeInvalidateSize() {\n // Initialize the singleton synthetic item vars (during IS_VALID phase)\n // Bound sequences don't have a value\n ListBuffer<JCStatement> stmts = ListBuffer.lb();\n for (int i = 0; i < length; ++i) {\n if (!isSequence(i)) {\n stmts.append(SetStmt(vsym(i), CallGetter(i)));\n }\n }\n JCStatement varInits = Block(stmts);\n \n return\n Block(\n If(IsTriggerPhase(),\n setSequenceValid(),\n varInits\n ),\n SetStmt(sizeSymbol, cummulativeSize(length)),\n CallSeqInvalidate(Int(0), Int(0), Get(sizeSymbol))\n );\n }",
"private void LeastMoviableItem() {\n DefaultTableModel dtm=(DefaultTableModel) leastmoviableitemtable.getModel();\n ArrayList<MoviableItem> findleastmoviableitem;\n try {\n findleastmoviableitem = LeastMoviableItemController.findleastmoviableitem();\n for (MoviableItem moviableItem : findleastmoviableitem) {\n Object[]rowdata={moviableItem.getItemcode(),moviableItem.getDescription(),moviableItem.getSalse()}; \n dtm.addRow(rowdata);\n }\n } catch (ClassNotFoundException | SQLException ex) {\n JOptionPane.showMessageDialog(null, ex.getMessage());\n }\n \n\n }",
"public void WorkloadBasedOnlineCostOptimizationWithDoubleCopy() {\n\t\t\n\t \tinitialParameters();\n\t\tint inputObjectsNumber=0;\n\t\tint indexJ=0;\n\t\t\n\t\tint keepTime=0;// This variable indicates how long an object is stayed in the hot-tier\n\t\tint currentTime=0; // This variable indicates the passing time in the simulation\n\t\t\n\t for (int slot = 0; slot < workloadGenerator.numberObjectsPerSlot.length; slot++) {\n\t\tinputObjectsNumber=inputObjectsNumber+workloadGenerator.numberObjectsPerSlot[slot];\n\t\t\n\t\tfor (int j = indexJ; j < inputObjectsNumber; j++) {\n\t\t\t\n\t\t\tfor (int t=0; t<T; t++ ){\n\t\t\t\t\n\t\t\t\tcurrentTime=t;\n\t\t\t\tif(existRequest(j, t)){\n\t\t\t\t\tbreakPointEvaluation(j, t);\n\t\t\t\t\talphaCalculation();\n\t\t\t\t\t\n\t\t\t\t\tif(finalLocation[j][t]==1){\n\t\t\t\t\t\n\t\t\t\t\t for (keepTime = currentTime; keepTime < currentTime+alpha*(breakPoint); keepTime++) {\n\t\t\t\t\t\t finalLocation[j][t]=1;\n\t\t\t\t\t }\n\t\t\t\t\t}else if(residentialLatencyCost(j, t, 0).compareTo(residentialLatencyCost(j, t,1).add(totalCostCalculation.btotalMigrationCost[t][j][0][1]))==1){\n\t\t\t\t\t\tfinalLocation[j][t]=1;\n\t\t\t\t\t}\n\t\t\t\t}// FIRST IF\n\t\t\t} \t\n\t\t}//For t\n\t\tindexJ=inputObjectsNumber;\n\t }//slot\n\t \n\t /*\n\t for (int obj = 0; obj < finalLocation.length; obj++) {\n\t\t for (int time = 0; time < finalLocation[obj].length; time++) {\n\t\t System.out.print(finalLocation[obj][time]+\" \");\n\t\t \n\t\t \n\t\t }\n\t }\n\t */\n\t \n}",
"public WaitingCell(int i,int rtw) {\n\t\tsuper(i);\n\t\tthis.roundsToWait = rtw;\n\t\tthis.roundsWaited = 0;\n\t}",
"private void generateDefaultTimeSlots() {\n\t\tLocalTime startTime = LocalTime.of(9, 0); // 9AM start time\n\t\tLocalTime endTime = LocalTime.of(19, 0); // 5PM end time\n\n\t\tfor (int i = 1; i <= 7; i++) {\n\t\t\tList<Timeslot> timeSlots = new ArrayList<>();\n\t\t\tLocalTime currentTime = startTime.plusMinutes(15);\n\t\t\twhile (currentTime.isBefore(endTime) && currentTime.isAfter(startTime)) {\n\t\t\t\tTimeslot newSlot = new Timeslot();\n\t\t\t\tnewSlot.setTime(currentTime);\n\t\t\t\tnewSlot = timeslotRepository.save(newSlot);\n\t\t\t\ttimeSlots.add(newSlot);\n\t\t\t\tcurrentTime = currentTime.plusHours(1); // new slot after one hour\n\t\t\t}\n\t\t\tDay newDay = new Day();\n\t\t\tnewDay.setTs(timeSlots);\n\t\t\tnewDay.setDayOfWeek(DayOfWeek.of(i));\n\t\t\tdayRepository.save(newDay);\n\t\t}\n\t}",
"abstract public void computeSchedule();",
"public SpaceSchedule getSchedule() {\n\t\treturn null;\n\t}"
] | [
"0.5668172",
"0.5568091",
"0.5549635",
"0.54582894",
"0.53865564",
"0.5327895",
"0.5224997",
"0.5177688",
"0.5175095",
"0.51612663",
"0.5139494",
"0.5061209",
"0.5061086",
"0.5057539",
"0.50447965",
"0.5015928",
"0.5014814",
"0.50116503",
"0.5007716",
"0.49971458",
"0.49782825",
"0.49579105",
"0.4954103",
"0.49309742",
"0.49224293",
"0.49116206",
"0.4908644",
"0.49063703",
"0.4895238",
"0.48809797",
"0.48578513",
"0.48570698",
"0.48548427",
"0.4853313",
"0.48449853",
"0.48448732",
"0.48416573",
"0.48383972",
"0.48184732",
"0.48166335",
"0.47981736",
"0.47776455",
"0.47741297",
"0.4773595",
"0.4769504",
"0.4768416",
"0.47674033",
"0.4753506",
"0.47457588",
"0.4735342",
"0.47339165",
"0.47323734",
"0.47308916",
"0.47299844",
"0.47291812",
"0.47291744",
"0.4726588",
"0.4723729",
"0.47199687",
"0.4717882",
"0.47051784",
"0.47023594",
"0.46981955",
"0.46968102",
"0.46915007",
"0.46900165",
"0.46811536",
"0.46786192",
"0.4677941",
"0.4675179",
"0.4674197",
"0.46736035",
"0.46723655",
"0.46631455",
"0.46619904",
"0.46604946",
"0.4656999",
"0.46509793",
"0.46493706",
"0.4648524",
"0.4646603",
"0.46455783",
"0.4644563",
"0.4641546",
"0.46383682",
"0.46319088",
"0.46267402",
"0.46256354",
"0.46228614",
"0.4620711",
"0.462033",
"0.46195084",
"0.46132195",
"0.46127605",
"0.46065328",
"0.46050242",
"0.46045324",
"0.46044967",
"0.46022457",
"0.46013287",
"0.4598888"
] | 0.0 | -1 |
Create a new Folder | public static void main(String[] args) {
File f=new File("C:\\Users\\DELL\\Desktop\\","CheckFolder");
f.mkdir();
System.out.println(f.isDirectory());
System.out.println(f.getName());
System.out.println(f.getParent());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Folder createFolder();",
"public void createFolder (String folderName, long parentFolderId, Long userId) throws BookMarkException;",
"WithCreate withFolderPath(String folderPath);",
"private void createLocalFolder(File newFolder) {\n\n if (!newFolder.exists()) {\n newFolder.mkdirs();\n //TODO: what if the folder can't be created?\n PieLogger.trace(this.getClass(), \"Folder created!\");\n } else {\n PieLogger.debug(this.getClass(), \"Folder exits already?!\");\n }\n }",
"public static void CreateFolder(String folderName, String path){\n File file = new File(path+ \"/\" + folderName);\n file.mkdirs ();\n }",
"public void make_folder(String folder) throws Exception{\n\t\tFile file = new File(folder);\n\t\tfile.mkdirs();\n\t}",
"public static void createFolder(File folder) {\n\tif (!folder.exists()) {\n\t folder.mkdirs();\n\t}\n }",
"private void createFolder(String name, String path, Long id) {\n VMDirectory newDir = new VMDirectory();\n newDir.setName(name);\n editResourceService.createDir(id, name, new AsyncCallback<Long>() {\n\n @Override\n public void onFailure(Throwable caught) {\n SC.say(caught.getMessage());\n }\n\n @Override\n public void onSuccess(Long result) {\n createCallbackFile(fileTreeNodeFactory.findTreeNode(tree, id), newDir, result, true);\n folderPath_idMap.put(path, result);\n fileTreeNodeFactory.refresh(editorTabSet, tree, tabRegs);\n treeGrid.sort();\n treeGrid.redraw();\n }\n });\n }",
"@Override\n\tpublic boolean createFolder(String pathfolder) {\n\t\treturn eDao.createFolder(pathfolder);\n\t}",
"private void createDir(){\n\t\tPath path = Path.of(this.dir);\n\t\ttry {\n\t\t\tFiles.createDirectories(path);\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"private void makeFolders( final File directoryToCreate )\n throws MojoExecutionException\n {\n this.logger.debug( \"Creating folder '\" + directoryToCreate.getAbsolutePath() + \"' ...\" );\n if ( directoryToCreate.mkdirs() == false )\n {\n throw new MojoExecutionException( \"Could not create folder '\" + directoryToCreate.getAbsolutePath() + \"'!\" );\n }\n }",
"private void createFolder(String myFilesystemDirectory) {\n\r\n File file = new File(myFilesystemDirectory);\r\n try {\r\n if (!file.exists()) {\r\n //modified \r\n file.mkdirs();\r\n }\r\n } catch (SecurityException e) {\r\n Utilidades.escribeLog(\"Error al crear carpeta: \" + e.getMessage());\r\n }\r\n }",
"@Override\n\tpublic void createFolder(String bucketName, String folderName) {\n\t\t\n\t}",
"private void makeFolder(File folderNameFile) {\n\t\tfolderNameFile.mkdir();\n\t}",
"private static void doCreateDir() {\n String newDir = \"new_dir\";\n boolean success = (new File(newDir)).mkdir();\n\n if (success) {\n System.out.println(\"Successfully created directory: \" + newDir);\n } else {\n System.out.println(\"Failed to create directory: \" + newDir);\n }\n\n // Create a directory; all non-existent ancestor directories are\n // automatically created.\n newDir = \"c:/export/home/jeffreyh/new_dir1/new_dir2/new_dir3\";\n success = (new File(newDir)).mkdirs();\n\n if (success) {\n System.out.println(\"Successfully created directory: \" + newDir);\n } else {\n System.out.println(\"Failed to create directory: \" + newDir);\n }\n\n }",
"public void makeFolder() throws IOException {\n\t\tclientOutput.println(\n\t\t\t\t\">>> Unesite relativnu putanju do destinacije na kojoj pravite folder zajedno sa imenom foldera: \");\n\t\tuserInput = clientInput.readLine();\n\n\t\tuserInput = \"drive/\" + username + \"/\" + userInput;\n\t\tdestinacija = new File(userInput);\n\t\tdestinacija.mkdir();\n\t}",
"@BeforeClass(groups ={\"All\"})\n\tpublic void createFolder() {\n\t\tdciFunctions = new DCIFunctions();\n\t\ttry {\n\t\t\tif(suiteData.getSaasApp().equalsIgnoreCase(\"Salesforce\")){\n\t\t\t\tLogger.info(\"No need to create folder for salesforce\");\n\t\t\t}else{\n\t\t\t\tUserAccount account = dciFunctions.getUserAccount(suiteData);\n\t\t\t\tUniversalApi universalApi = dciFunctions.getUniversalApi(suiteData, account);\n\t\t\t\tfolderInfo = dciFunctions.createFolder(universalApi, suiteData, \n\t\t\t\t\t\tDCIConstants.DCI_FOLDER+uniqueId);\n\t\t\t}\n\t\t} catch (Exception ex) {\n\t\t\tLogger.info(\"Issue with Create Folder Operation \" + ex.getLocalizedMessage());\n\t\t}\n\t}",
"public boolean createFolder(String path){\n\t\tValueCollection payload = new ValueCollection();\n\t\tpayload.put(\"path\", new StringPrimitive(path));\n\t\ttry {\t\n\t\t\tclient.invokeService(ThingworxEntityTypes.Things, FileThingName, \"CreateFolder\", payload, 5000);\n\t\t\tLOG.info(\"Folder {} created.\",path);\n\t\t} catch (Exception e) {\n\t\t\tLOG.error(\"Folder already exists. Error: {}\",e);\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}",
"public static void creaSezione(Folder newFolder, long idCorso) {\n\t\ttry {\n\t\t\tRequestContent rp = new RequestContent();\n\t\t\trp.parameters = new Object[] { newFolder, idCorso };\n\t\t\trp.type = RequestType.CREATE_FOLDER;\n\t\t\tsend(rp);\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"Errore nella generazione della nuova cartella\");\n\t\t}\n\t}",
"private File createNewFolder(final String parentName, String parentId, final String name){\n File fileMetadata = new File();\n fileMetadata.setName(name);\n fileMetadata.setTeamDriveId(teamDrive.getId());\n fileMetadata.set(\"supportsTeamDrives\", true);\n fileMetadata.setMimeType(GOOGLE_DRIVE_FOLDER_MIMETYPE);\n fileMetadata.setParents(Collections.singletonList(parentId));\n try {\n File newFolder = drive.files().create(fileMetadata)\n .setSupportsTeamDrives(true)\n .setFields(\"id, name, parents\")\n .execute();\n listener.getLogger().printf(\"Created new Folder %s (%s) in %s (%s)%n\",\n newFolder.getName(), newFolder.getId(), parentName, parentId);\n return newFolder;\n } catch (IOException e) {\n listener.error(\"Error creating folder in Shared Drive\", e);\n }\n return null;\n }",
"public File createNewFolder(File paramFile) throws IOException {\n/* 803 */ if (paramFile == null) {\n/* 804 */ throw new IOException(\"Containing directory is null:\");\n/* */ }\n/* */ \n/* 807 */ File file = createFileObject(paramFile, newFolderString);\n/* */ \n/* 809 */ if (file.exists()) {\n/* 810 */ throw new IOException(\"Directory already exists:\" + file.getAbsolutePath());\n/* */ }\n/* 812 */ file.mkdirs();\n/* */ \n/* */ \n/* 815 */ return file;\n/* */ }",
"public String createDirectory(String parentID, String new_directory) throws CloudStorageNotEnoughSpace {\n File newFile = new File();\n newFile.setTitle(new_directory);\n newFile.setMimeType(\"application/vnd.google-apps.folder\");\n newFile.setParents(Arrays.asList(new ParentReference().setId(parentID)));\n\n try {\n File insertedFile = drive.files().insert(newFile).execute();\n return insertedFile.getId();\n } catch (IOException e) {\n e.printStackTrace();\n return null;\n }\n\n }",
"private void createFolderHelper(final IFolder folder,final IProgressMonitor monitor)\n throws CoreException\n {\n if(!folder.exists())\n {\n IContainer parent = folder.getParent();\n if(parent instanceof IFolder\n && (!((IFolder)parent).exists())) {\n createFolderHelper((IFolder)parent,monitor);\n }\n folder.create(false,true,monitor);\n }\n }",
"public static void createFolder(IResource res) {\r\n \t\tif (res instanceof IFolder) {\r\n \t\t\tIFolder folder=(IFolder)res;\r\n \t\t\t\r\n \t\t\tif (folder.exists() == false) {\r\n \t\t\t\tcreateFolder(folder.getParent());\r\n \r\n \t\t\t\ttry {\r\n \t\t\t\t\tfolder.create(true, true,\r\n \t\t\t\t\t\t\tnew org.eclipse.core.runtime.NullProgressMonitor());\r\n \t\t\t\t} catch(Exception e) {\r\n \t\t\t\t\te.printStackTrace();\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t} else if (res.getParent() != null) {\r\n \t\t\tcreateFolder(res.getParent());\r\n \t\t}\r\n \t}",
"@Test\n public void testNewFolder() {\n boolean result = instance.newFolder(mailboxID + File.separator + \"newFolder\");\n assertEquals(true, result);\n }",
"public DocumentListEntry createFolder(String folderName) throws MalformedURLException, IOException, ServiceException;",
"private static MenuItem createAddNewFolderMenuItem(SongManager model, Item selectedItem) {\n MenuItem createNewFolder = new MenuItem(CREATE_NEW_FOLDER);\n\n createNewFolder.setOnAction((event) -> {\n if (selectedItem != null) {\n File folderSelected = selectedItem.getFile();\n Path newPath = PromptUI.createNewFolder(folderSelected);\n\n if (newPath != null) {\n try {\n model.addNewFolder(newPath.toFile());\n } catch (IOException ex) {\n PromptUI.customPromptError(\"Create new folder\", null, \"Unable to create new folder \" + newPath);\n }\n }\n }\n });\n\n return createNewFolder;\n }",
"public Folder createFolder(String name) {\n Validate.notBlank(name, \"name cannot be blank\");\n List<NameValuePair> params = ClientUtils.asParams(\"Name\", name);\n Folder folder = client.post(FOLDERS_PATH, Folder.class, params).getEntry();\n folder.setName(name);\n return folder;\n }",
"@TaskAction\n public void create() {\n dir.mkdirs();\n getChmod().chmod(dir, dirMode);\n }",
"public OutputResponse mkdir(String path){\n String command = \"mkdir \" + path;\n return jobTarget.runCommand( command );\n }",
"private Path initFolder(String folder) throws IOException {\n return Files.createDirectory(Paths.get(uploadFolder + \"/\" + folder));\n }",
"private void createNewDirectory() {\n getMainWindow().addWindow(\n new TextInputDialog(\n \"Create Directory\",\n \"Create Directory\",\n \"New Folder\",\n new TextInputDialog.Callback() {\n public void onDialogResult(boolean happy, String newDirectory) {\n if ( happy\n && isValidFile(newDirectory)) {\n try {\n // Verzeichnis anlegen\n File newDir = getFile(newDirectory);\n if (!newDir.exists()) {\n newDir.mkdir(0755);\n }\n // Prüfen, ob das Verzeichnis angelegt wurde\n if (newDir.exists()) {\n loadXtreemFSData();\n showNotification(\"Success\", \"Directory \" + newDirectory + \" created.\", Notification.TYPE_TRAY_NOTIFICATION, null);\n }\n else {\n showNotification(\"Error\", \"Directory \" + newDirectory + \" could not be created.\", Notification.TYPE_WARNING_MESSAGE, null);\n }\n } catch (IOException e) {\n showNotification(\"Error\", e.toString(), Notification.TYPE_ERROR_MESSAGE, e);\n }\n }\n }\n }));\n }",
"private boolean createFolder (Path path) {\n if (Files.notExists(path)) {\n // If the folder doesn't already exists we create it\n File f = new File(path.toString());\n try {\n // Create the folder\n f.mkdir();\n // Create an empty flow.json file\n f = new File(path + \"/flow.json\");\n f.createNewFile();\n return true;\n } catch (Exception e) {\n e.printStackTrace();\n return false;\n }\n } else {\n return false;\n }\n }",
"@Override\n protected NodeInfo createDirectoryEntry(NodeInfo parentEntry, Path dir) throws IOException {\n return drive.createFolder(parentEntry.getId(), toFilenameString(dir));\n }",
"private static void createTempFolder(String folderName) throws IOException {\n Path tempFolderPath = Paths.get(folderName);\n if (Files.notExists(tempFolderPath) || !Files.isDirectory(tempFolderPath)) {\n Files.createDirectory(tempFolderPath);\n }\n }",
"public void createDirectory() {\r\n\t\tpath = env.getProperty(\"resources\") + \"/\" + Year.now().getValue() + \"/\";\r\n\t\tFile file = new File(path);\r\n\t\tif (!file.exists())\r\n\t\t\tfile.mkdirs();\r\n\t}",
"public void createFolder(String remotepath){\n String path = rootremotepath+remotepath;\n try {\n sardine.createDirectory(path);\n } catch (IOException e) {\n throw new NextcloudApiException(e);\n }\n }",
"private void createFolders() {\n File f = new File(System.getProperty(\"user.dir\") + \"/chatimages/\");\n if (!f.exists()){\n f.mkdir();\n }\n }",
"public void createFolder(String path, String folderName) throws GRIDAClientException {\n\n try {\n Communication communication = getCommunication();\n communication.sendMessage(\n ExecutorConstants.COM_CREATE_FOLDER + Constants.MSG_SEP_1\n + proxyPath + Constants.MSG_SEP_1\n + Util.removeLfnFromPath(path + \"/\" + folderName));\n communication.sendEndOfMessage();\n\n communication.getMessage();\n communication.close();\n\n } catch (IOException ex) {\n throw new GRIDAClientException(ex);\n }\n }",
"public void testCreateDmsFolder() throws Exception {\n String verifyString = this.config.getString(\"lenya.tests.general.authoringPageTitle\");\n String newId = createTestNodeID();\n FolderHelper helper = new FolderHelper();\n helper.setUp(TEST_NAME);\n // create a new folder\n helper.folderCreate(newId, verifyString);\n }",
"public void createFolder(View view) {\n if (mDriveServiceHelper != null) {\n\n // check folder present or not\n mDriveServiceHelper.isFolderPresent()\n .addOnSuccessListener(new OnSuccessListener<String>() {\n @Override\n public void onSuccess(String id) {\n if (id.isEmpty()){\n mDriveServiceHelper.createFolder()\n .addOnSuccessListener(new OnSuccessListener<String>() {\n @Override\n public void onSuccess(String fileId) {\n Log.e(TAG, \"folder id: \"+fileId );\n folderId=fileId;\n showMessage(\"Folder Created with id: \"+fileId);\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception exception) {\n showMessage(\"Couldn't create file.\");\n Log.e(TAG, \"Couldn't create file.\", exception);\n }\n });\n }else {\n folderId=id;\n showMessage(\"Folder already present\");\n }\n\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception exception) {\n showMessage(\"Couldn't create file..\");\n Log.e(TAG, \"Couldn't create file..\", exception);\n }\n });\n }\n }",
"void folderCreated(String remoteFolder);",
"protected DataPackage createFolder(String nameFolder) {\r\n\r\n\t\tObjectIdentity<?> folderIdentity = new ObjectIdentity();\r\n\r\n\t\tfolderIdentity.setRepositoryName(REPOSITORY_NAME);\r\n\r\n\t\tDataObject dataObject = new DataObject(folderIdentity, DM_FOLDER);\r\n\r\n\t\tPropertySet properties = new PropertySet();\r\n\r\n\t\tproperties.set(OBJECT_NAME, nameFolder);\r\n\r\n\t\tdataObject.setProperties(properties);\r\n\r\n\t\tDataPackage dataPackage = new DataPackage(dataObject);\r\n\r\n\t\tOperationOptions operationOptions = null;\r\n\r\n\t\ttry {\r\n\r\n\t\t\tdataPackage = this.objectService.create(dataPackage,\r\n\t\t\t\t\toperationOptions);\r\n\r\n\t\t} catch (CoreServiceException e) {\r\n\r\n\t\t\tlogger.error(ERROR_REPOSITORIO_EMC.concat(e.getLocalizedMessage()));\r\n\r\n\t\t} catch (ServiceException e) {\r\n\r\n\t\t\tlogger.error(ERROR_SERVICO_EMC.concat(e.getLocalizedMessage()));\r\n\r\n\t\t}\r\n\r\n\t\treturn dataPackage;\r\n\r\n\t}",
"protected void createDirectory(Path path, Path destPath) {\n String rootLocation = destPath.toString();\n int index;\n if(firstTime) {\n firstTime = false;\n index = path.toFile().getPath().lastIndexOf(\"\\\\\")+1;//index where cur directory name starts\n rootFolder = path.toFile().getPath().substring(index);\n }\n else {\n index = path.toFile().getPath().indexOf(rootFolder);\n }\n\n String folderName= path.toFile().getPath().substring(index);\n Path newDirPath = Paths.get(rootLocation + DOUBLE_BKW_SLASH +folderName);\n try {\n Path newDir = Files.createDirectory(newDirPath);\n } catch(FileAlreadyExistsException e){\n // the directory already exists.\n e.printStackTrace();\n } catch (IOException e) {\n //something else went wrong\n e.printStackTrace();\n }\n }",
"public void newFolder ()\n {\n newNode(null);\n }",
"public abstract boolean create(FolderType type) throws MessagingException;",
"@Override\r\n\tpublic boolean createFolder(String filePath) throws FileSystemUtilException {\r\n\t\ttry{\r\n\t\t\tString userHome = getUserHome();\r\n\t\t\t//if given file path doesnot start with user home\r\n\t\t\tif(filePath == null && filePath.trim().length() < 1 && !filePath.startsWith(userHome)){\r\n\t\t\t\tthrow new FileSystemUtilException(\"EL0701\");\r\n\t\t\t}\r\n\t\t\tconnect();\r\n\t\t\tString mkDirCmd = \"mkdir -p \"+filePath;\t\t\t\r\n\t\t\tint x = executeSimpleCommand(mkDirCmd);\r\n\t\t\tif(x!=0)\r\n\t\t\t{\r\n\t\t\t\tlogger.info(\"Folder creation failed, may be file path is not correct or privileges are not there\");\r\n\t\t\t\tthrow new FileSystemUtilException(\"EL0699\");\r\n\t\t\t}\r\n\t\t\treturn true;\r\n\t\t}catch(FileSystemUtilException e)\r\n\t\t{\r\n\t\t disconnect();\r\n\t\t\tthrow new FileSystemUtilException(e.getErrorCode(),e.getException());\r\n\t\t}catch(Exception e)\r\n\t\t{\r\n\t\t\tthrow new FileSystemUtilException(\"F00002\",e);\r\n\t\t}\r\n\r\n\t}",
"private void addFolder(){\n }",
"public void createFolder(ActionRequest request, ThemeDisplay themeDisplay) {\n\t\tboolean folderExist = isFolderExist(themeDisplay);\n\n\t\tif (!folderExist) {\n\t\t\tlong repositoryId = themeDisplay.getScopeGroupId();\n\t\t\ttry {\n\t\t\t\tServiceContext serviceContext = ServiceContextFactory.getInstance(DLFolder.class.getName(), request);\n\t\t\t\tDLAppServiceUtil.addFolder(repositoryId, PARENT_FOLDER_ID, ROOT_FOLDER_NAME, ROOT_FOLDER_DESCRIPTION,\n\t\t\t\t\t\tserviceContext);\n\t\t\t} catch (PortalException e1) {\n\t\t\t\t_log.error(e1.getMessage());\n\t\t\t} catch (SystemException e1) {\n\t\t\t\t_log.error(e1.getMessage());\n\t\t\t}\n\t\t}\n\t}",
"public OutputResponse mkdirs(String path){\n String command = \"mkdir -p \" + path;\n return jobTarget.runCommand( command);\n }",
"public boolean createDirectoryInJarFolder(String folderName){\r\n \r\n path = getPathToJarFolder();\r\n \r\n // add folder to path and make directory\r\n path += folderName;\r\n File file = new File(path);\r\n return file.mkdir();\r\n }",
"public boolean createFolderInServerDir(String FolderName){\r\n File file = new File(serversDir, FolderName);\r\n if(file.exists()){\r\n Toast.makeText(mContext, \"server already exist\", Toast.LENGTH_SHORT).show();\r\n return false;\r\n }else{\r\n file.mkdirs();\r\n updateServerList();\r\n return true;\r\n }\r\n }",
"@PreAuthorize(\"hasAuthority('file:write')\")\n @PostMapping(\"/newDirectory\")\n public String createNewDirectory(@RequestParam(\"folderName\") String folderName,\n HttpSession httpSession,\n RedirectAttributes redirectAttributes) {\n String currentDirectory = httpSession.getAttribute(\"currentFolderPath\").toString();\n\n //create New directory from the request\n storageService.createNewDirectory(currentDirectory + File.separator + folderName);\n\n redirectAttributes.addFlashAttribute(\"message\",\n \"New directory created\");\n\n return \"redirect:/\";\n }",
"public String createNewFolder(String token) throws IOException, GeneralSecurityException {\n String folderID = null;\n Drive service = getDriveService(token);\n File fileMetadata = new File();\n fileMetadata.setName(FOLDER_NAME);\n fileMetadata.setMimeType(\"application/vnd.google-apps.folder\");\n List<File> files = search(token, FOLDER_NAME);\n log.debug(\"files is empty? {}, {}\", files.size(), files.isEmpty());\n if (files.isEmpty()) {\n File file = service.files().create(fileMetadata).setFields(\"id\").execute();\n log.debug(\"Folder ID: \" + file.getId());\n folderID = file.getId();\n } else {\n boolean folderExists = false;\n for (File file : files) {\n if (file.getOwnedByMe() && !file.getTrashed()) {\n log.debug(\"Folder ID: {}, trashed {}, ownedbyme {}\", file.getId(), file.getTrashed(), file.getOwnedByMe());\n folderID = file.getId();\n folderExists = true;\n break;\n }\n }\n if (!folderExists) {\n File createdFile = service.files().create(fileMetadata).setFields(\"id\").execute();\n log.debug(\"Folder ID: \" + createdFile.getId());\n folderID = createdFile.getId();\n\n }\n }\n return folderID;\n }",
"private static void createDirectory(Path path) throws IOException {\n\t\ttry {\n\t\t\tFiles.createDirectory(path);\n\t\t} catch (FileAlreadyExistsException e) {\n\t\t\tif (!Files.isDirectory(path)) {\n\t\t\t\tthrow e;\n\t\t\t}\n\t\t}\n\t}",
"protected Reference createFolder(final String parentPath, final String folderName) {\n\t\tParentReference parentReference = new ParentReference(\n\t\t\t\tSTORE, null, parentPath, Constants.ASSOC_CONTAINS,\n\t\t\t\tConstants.createQNameString(Constants.NAMESPACE_CONTENT_MODEL, folderName));\n\n\t\tNamedValue[] properties = new NamedValue[] { Utils.createNamedValue(Constants.PROP_NAME, folderName) };\n\t\tCMLCreate create = new CMLCreate(\"1\", parentReference, null, null, null, Constants.TYPE_FOLDER, properties);\n\t\tCML cml = new CML();\n\n\t\tcml.setCreate(new CMLCreate[] { create });\n\n\t\ttry {\n\t\t\tUpdateResult[] results = repositoryService.update(cml);\n\n\t\t\treturn results[0].getDestination();\n\t\t} catch(RemoteException e) {\n\t\t\tLOG.error(String.format(\"Error creating folder: %s in path: %s\", folderName, parentPath), e);\n\t\t}\n\n\t\treturn null;\n\t}",
"public boolean makeDirectory(){\n File root = new File(Environment.getExternalStorageDirectory(),\"OQPS\");\n if(!root.exists()){\n return root.mkdir();\n }\n return true; //folder already exists\n }",
"public MkdirCommand() {\r\n // The name of the mkdir command\r\n name = \"mkdir\";\r\n\r\n // The description of the mkdir command\r\n description = \"Creates a directory ar the given path. The given path can\"\r\n + \" be a full path or a path relative to the working directory\";\r\n\r\n // The parameters for the mkdir command and their description\r\n parameters.put(\"DIR\", \"The path that points to where the new directory\"\r\n + \" should be created.\");\r\n }",
"private void createDirectories()\r\n\t{\r\n\t\t// TODO: Do some checks here\r\n\t\tFile toCreate = new File(Lunar.OUT_DIR + Lunar.PIXEL_DIR\r\n\t\t\t\t\t\t\t\t\t+ Lunar.PROCESSED_DIR);\r\n\t\ttoCreate.mkdirs();\r\n\t\ttoCreate = null;\r\n\t\ttoCreate = new File(Lunar.OUT_DIR + Lunar.ROW_DIR + Lunar.PROCESSED_DIR);\r\n\t\ttoCreate.mkdirs();\r\n\t\ttoCreate = null;\r\n\t}",
"private IFolder createFolder(IFolder topFolder) throws CoreException {\n \t\ttopFolder.create(IResource.NONE, true, getMonitor());\n \n \t\t//tree depth is log of total resource count with the width as the log base\n \t\tint depth = (int) (Math.log(TOTAL_RESOURCES) / Math.log(TREE_WIDTH));\n \t\trecursiveCreateChildren(topFolder, depth - 1);\n \t\treturn topFolder;\n \t}",
"public static void createDir(String path) {\n File dir = new File(new File(path).getParentFile().getAbsolutePath());\n dir.mkdirs();\n }",
"public void newFolderButtonClicked() {\n TreePath[] paths = _fileSystemTree.getSelectionPaths();\r\n List selection = getSelectedFolders(paths);\r\n if (selection.size() > 1 || selection.size() == 0)\r\n return; // should never happen\r\n \r\n File parent = (File) selection.get(0);\r\n \r\n final ResourceBundle resourceBundle = FolderChooserResource.getResourceBundle(Locale.getDefault());\r\n String folderName = JOptionPane.showInputDialog(_folderChooser, resourceBundle.getString(\"FolderChooser.new.folderName\"),\r\n resourceBundle.getString(\"FolderChooser.new.title\"), JOptionPane.OK_CANCEL_OPTION | JOptionPane.QUESTION_MESSAGE);\r\n \r\n if (folderName != null) {\r\n File newFolder = new File(parent, folderName);\r\n boolean success = newFolder.mkdir();\r\n \r\n TreePath parentPath = paths[0];\r\n boolean isExpanded = _fileSystemTree.isExpanded(parentPath);\r\n if (!isExpanded) { // expand it first\r\n _fileSystemTree.expandPath(parentPath);\r\n }\r\n \r\n LazyMutableTreeNode parentTreeNode = (LazyMutableTreeNode) parentPath.getLastPathComponent();\r\n BasicFileSystemTreeNode child = BasicFileSystemTreeNode.createFileSystemTreeNode(newFolder, _folderChooser);\r\n // child.setParent(parentTreeNode);\r\n if (success) {\r\n parentTreeNode.clear();\r\n int insertIndex = _fileSystemTree.getModel().getIndexOfChild(parentTreeNode, child);\r\n if (insertIndex != -1) {\r\n // ((BasicFileSystemTreeModel) _fileSystemTree.getModel()).insertNodeInto(child, parentTreeNode, insertIndex);\r\n ((BasicFileSystemTreeModel) _fileSystemTree.getModel()).nodeStructureChanged(parentTreeNode);\r\n // ((BasicFileSystemTreeModel) _fileSystemTree.getModel()).addPath(parentPath, insertIndex, child);\r\n }\r\n }\r\n TreePath newPath = parentPath.pathByAddingChild(child);\r\n _fileSystemTree.setSelectionPath(newPath);\r\n _fileSystemTree.scrollPathToVisible(newPath);\r\n }\r\n }",
"@PostMapping(\"/createfolder\")\n public String createFolder(@RequestParam(name=\"directoryName\", required=true) String directoryName, @RequestParam(name=\"currentPath\", required=true) String currentPath, RedirectAttributes redirectAttributes) {\n try {\n logger.log(Level.INFO, \"Creating directory\");\n uiCommandService.createNewFolder(directoryName, currentPath);\n logger.log(Level.INFO, \"Folder was created successfully!\");\n redirectAttributes.addFlashAttribute(\"success_messages\",\"[Successfully created \" + directoryName + \"!]\");\n } catch (DirectoryExistsException e) {\n redirectAttributes.addFlashAttribute(\"error_messages\", \"[\"+ directoryName +\" already exists!]\");\n logger.log(Level.WARNING, \"Folder {0} already exist in {1}\", new Object[]{directoryName, currentPath});\n }\n return \"redirect:/imageview?location=\" + currentPath.replace(\"\\\\\", \"/\");\n }",
"private void createDirectory(String path) throws IOException {\n\t\tfinal Path p = Paths.get(path);\n\t\tif (!fileExists(p)) {\n\t\t\tFiles.createDirectory(p);\n\t\t}\n\t}",
"public void mkdir(String path) throws SystemException;",
"@Override\n public void createDirectory(File storageName) throws IOException {\n }",
"private void prepareFolder(String name, String newFolderName) {\n }",
"public static void mkdir(String path)\n\t{\n\t\tif(!new File(path).exists())\n\t\t\tnew File(path).mkdirs();\n\t}",
"public static void createDirectory(String srcDir, String nameDir) {\n try {\n Path path = Paths.get(srcDir + \"/\" + nameDir);\n\n Files.createDirectories(path);\n System.out.println(\"Directory is created\");\n } catch (IOException e) {\n System.err.println(\"ERROR CREATION! \" + e.getMessage());\n }\n\n }",
"protected static void createDirectory(MasterProcedureEnv env, NamespaceDescriptor nsDescriptor)\n throws IOException {\n createDirectory(env.getMasterServices().getMasterFileSystem(), nsDescriptor);\n }",
"public static void createLogsFolder(String name, String folderPath) {\r\n\t\tFile path = new File(folderPath);\r\n\t\tFile file = new File(folderPath+name+\".txt\");\r\n\t\tif(!file.exists()) {\r\n\t\t\tpath.mkdirs();\r\n\t\t\ttry {file.createNewFile();} catch (IOException e) {System.err.println(\"The file \\\"\"+name+\"\\\" cannot be created : \"+e.getMessage());}\r\n\t\t}\r\n\t}",
"public static void mkdir(String path) {\n File directory = new File(path);\n if (directory.exists())\n return;\n directory.mkdir();\n }",
"public void checkFolder() {\n String mPath = Environment.getExternalStorageDirectory().getAbsolutePath() + \"/ExoTest/\";\n mDir = new File(mPath);\n boolean isDirectoryCreated = mDir.exists();\n if (!isDirectoryCreated) {\n isDirectoryCreated = mDir.mkdir();\n }\n if (isDirectoryCreated) {\n // do something\\\n Log.d(\"Folder\", \"Already Created\");\n }\n }",
"public void clickCreateFolderButton() {\n\t\tfilePicker.fileManButton(locCreateFolderButton);\n\t}",
"@Test\n\tpublic void createFolderAsAuditorTest() {\n\t\tauthenticate(\"agent2\");\n\t\tint principalId = actorService.findByPrincipal().getId();\n\t\tint numFoldersNow = folderService.findFoldersOfActor(principalId).size();\n\t\tFolderForm folderFormAux = new FolderForm();\n\t\tfolderFormAux.setName(\"New Agent2 Folder for testing its creation\");\n\t\tFolder folder = folderService.reconstruct(folderFormAux,0);\n\t\tfolderService.save(folder);\n\t\tint numFoldersExpected = folderService.findFoldersOfActor(principalId).size();\n\t\tunauthenticate();\t\n\t\t\n\t\tAssert.isTrue(numFoldersNow + 1 == numFoldersExpected);\n\t}",
"public void createDir(File file) {\n if (!file.exists()) {\n file.mkdir();\n }\n }",
"public static void CrearDirectorio (String args){\n File directorio = new File(args);\n \n if (!directorio.exists()) {\n if (directorio.mkdirs()) {\n //System.out.println(\"Directorio creado\\n\");\n } else {\n //System.out.println(\"Error al crear directorio\\n\");\n }\n }\n }",
"public void createDirectory(SrvSession sess, TreeConnection tree, FileOpenParams params)\n throws IOException {\n\n // Access the database context\n\n DBDeviceContext dbCtx = (DBDeviceContext) tree.getContext();\n\n // Check if the database is online\n \n if ( dbCtx.getDBInterface().isOnline() == false)\n throw new DiskOfflineException( \"Database is offline\");\n \n // Get, or create, a file state for the new path. Initially this will indicate that the directory\n // does not exist.\n \n FileState fstate = getFileState(params.getPath(), dbCtx, false);\n if ( fstate != null && fstate.fileExists() == true)\n throw new FileExistsException(\"Path \" + params.getPath() + \" exists\");\n\n // If there is no file state check if the directory exists\n \n if ( fstate == null) {\n\n // Create a file state for the new directory\n \n fstate = getFileState(params.getPath(), dbCtx, true);\n \n // Get the file details for the directory\n \n if ( getFileDetails(params.getPath(), dbCtx, fstate) != null)\n throw new FileExistsException(\"Path \" + params.getPath() + \" exists\");\n }\n\n // Find the parent directory id for the new directory\n \n int dirId = findParentDirectoryId(dbCtx,params.getPath(),true);\n if ( dirId == -1)\n throw new IOException(\"Cannot find parent directory\");\n \n // Create the new directory entry\n \n try {\n\n // Get the directory name\n \n String[] paths = FileName.splitPath(params.getPath());\n String dname = paths[1];\n\n // Check if the directory name is too long\n \n if ( dname != null && dname.length() > MaxFileNameLen)\n throw new FileNameException(\"Directory name too long, \" + dname);\n \n // If retention is enabled check if the file is a temporary folder\n \n boolean retain = true;\n \n if ( dbCtx.hasRetentionPeriod()) {\n \n // Check if the file is marked delete on close\n \n if ( params.isDeleteOnClose())\n retain = false;\n }\n \n // Set the default NFS file mode, if not set\n \n if ( params.hasMode() == false)\n params.setMode(DefaultNFSDirMode);\n\n // Make sure the create directory option is enabled\n \n if ( params.hasCreateOption( WinNT.CreateDirectory) == false)\n throw new IOException( \"Create directory called for non-directory\");\n \n // Use the database interface to create the new file record\n \n int fid = dbCtx.getDBInterface().createFileRecord(dname, dirId, params, retain);\n\n // Indicate that the path exists\n \n fstate.setFileStatus( FileStatus.DirectoryExists);\n \n // Set the file id for the new directory\n \n fstate.setFileId(fid);\n \n // If retention is enabled get the expiry date/time\n \n if ( dbCtx.hasRetentionPeriod() && retain == true) {\n RetentionDetails retDetails = dbCtx.getDBInterface().getFileRetentionDetails(dirId, fid);\n if ( retDetails != null)\n fstate.setRetentionExpiryDateTime(retDetails.getEndTime());\n }\n \n // Check if the file loader handles create directory requests\n \n if ( fid != -1 && dbCtx.getFileLoader() instanceof NamedFileLoader) {\n \n // Create the directory in the filesystem/repository\n \n NamedFileLoader namedLoader = (NamedFileLoader) dbCtx.getFileLoader();\n namedLoader.createDirectory(params.getPath(), fid);\n }\n }\n catch (Exception ex) {\n Debug.println(ex);\n }\n }",
"public boolean mkdirs(String folderName){\n File f = new File(folderName);\n if (f.mkdirs()){\n return true;\n }\n return false;\n }",
"private String createTestTargetFolder(Long targetId, Long userId) {\r\n\t\t// create user folder if not existing\r\n\t\tString path = mFileStorePath + userId + \"//tt-\" + targetId;\r\n\t\tif (new File(path).mkdirs()) {\r\n\t\t\tmLogger.info(\"New folder created:\" + path);\r\n\t\t\treturn path;\r\n\t\t}\r\n\t\treturn null;\r\n\t}",
"private void setUpDirectories() {\r\n\t\tFile creation = new File(\"Creations\");\r\n\t\tFile audio = new File(\"Audio\");\r\n\t\tFile quiz = new File(\"Quiz\");\r\n\t\tFile temp = new File(\"Temp\");\r\n\r\n\t\tif (!creation.isDirectory()) {\r\n\t\t\tcreation.mkdir();\r\n\t\t}\r\n\t\tif (!audio.isDirectory()) {\r\n\t\t\taudio.mkdir();\r\n\t\t}\r\n\t\tif (!quiz.isDirectory()) {\r\n\t\t\tquiz.mkdir();\r\n\t\t}\r\n\t\tif (!temp.isDirectory()) {\r\n\t\t\ttemp.mkdir();\r\n\t\t}\r\n\r\n\t}",
"public void mkdir(String name) throws FileExistsException\n\t{\n\t\tcheckMakeFile(name);\n\t\tFileElement add = new FileElement(name, true);\n\t\tfileSystem.addChild(currentFileElement, add);\n\t}",
"private final void directory() {\n\t\tif (!this.plugin.getDataFolder().isDirectory()) {\n\t\t\tif (!this.plugin.getDataFolder().mkdirs()) {\n\t\t\t\tMain.SEVERE(\"Failed to create directory\");\n\t\t\t} else {\n\t\t\t\tMain.INFO(\"Created directory sucessfully!\");\n\t\t\t}\n\t\t}\n\t}",
"public static void createDirectory(String inputDirectory) {\n File file = new File(inputDirectory);\n if (file.exists()) {\n System.out.println(\"The directory is already present\");\n } else {\n //use mkdir() and check its return value\n file.mkdir();\n System.out.println(\"The directory \" + inputDirectory + \" has been created.\");\n }\n }",
"public static Menu createFolder(Menu parentMenu, String menuName) {\r\n Menu menu = new Menu();\r\n menu.setMenuText(menuName);\r\n menu.setMenuParent(parentMenu.getMenuId());\r\n menu.setMenuSort(0);\r\n menu.setMenuIcon(\"folder.gif\");\r\n menu.setMenuPath(parentMenu.getMenuPath() + \"/\" + parentMenu.getMenuId());\r\n menu.setMenuType(Menu.MENUTYPE_DIRECTORY);\r\n menu.setMenuHier(parentMenu.getMenuHier() + 1);\r\n menu.setMenuRef(\"\");\r\n for (MenuGroup mg : parentMenu.getMenuGroups()) {\r\n menu.getMenuGroups().add(mg);\r\n }\r\n\r\n MenuDAO menuDao = (MenuDAO) Context.getInstance().getBean(MenuDAO.class);\r\n if (menuDao.store(menu) == false)\r\n return null;\r\n return menu;\r\n }",
"private File initFolder(final String folderPath) throws IOException {\r\n File tempFolder = new File(folderPath);\r\n if (!tempFolder.exists()) {\r\n boolean createdFolder = false;\r\n try {\r\n createdFolder = tempFolder.mkdir();\r\n } catch (SecurityException se) {\r\n if (LOGGER.isLoggable(Level.WARNING)) {\r\n LOGGER.warning(\"Unable to create the specified folder: \" + folderPath\r\n + \"\\nProceeding with using the System temp folder: \" + SYSTEM_TEMP_DIR);\r\n }\r\n }\r\n if (!createdFolder) {\r\n tempFolder = new File(SYSTEM_TEMP_DIR);\r\n }\r\n }\r\n if (!tempFolder.exists() || !tempFolder.canWrite()) {\r\n throw new IOException(\"Unable to write on the specified folder: \"\r\n + tempFolder.getAbsolutePath());\r\n }\r\n return tempFolder;\r\n }",
"public void run(State state) throws IllegalNumberOfArgumentsException,\r\n InvalidPathException {\r\n String[] parameters = state.getParameters();\r\n if (parameters.length == 0) {\r\n throw new IllegalNumberOfArgumentsException(\r\n \"Mkdir requires a path to a directory to create.\");\r\n }\r\n // make a new directory for each path parameter\r\n for (String path : parameters) {\r\n path = State.cleanDirectoryPath(path);\r\n // get the name of the new directory and the path to its parent\r\n String[] separatedPath = state.separatePathName(path);\r\n String name = separatedPath[0];\r\n String parentPath = separatedPath[1];\r\n if (name.matches(\"/*\")) {\r\n throw new InvalidPathException(path);\r\n }\r\n try {\r\n // check that the name and parent's path are valid\r\n if (name.matches(State.ILLEGAL_CHARACTERS) || name\r\n .substring(0, name.length() - 1).contains(\"/\")) {\r\n throw new IllegalNameException(name);\r\n }\r\n // get the parent directory\r\n Directory parentDir = Navigate.navigateToDirectory(state, parentPath);\r\n //System.out.println(\"parent data: \" + parentDir.getData());\r\n //System.out.println(\"name: \" + name);\r\n String newPath = parentDir.getData() + name;\r\n // check that this file does not already exist\r\n if (parentDir.getChild(newPath) == null) {\r\n // create the new directory\r\n parentDir.addChild(name);\r\n state.addMessage(\"Created directory: \" + newPath + \"\\n\");\r\n } else {\r\n state.addMessage(newPath + \" already exists\\n\");\r\n }\r\n } catch (InvalidPathException e) {\r\n state.addMessage(\"Could not add directory \" + path + \" because \"\r\n + parentPath + \" does not exist.\\n\");\r\n } catch (IllegalNameException e) {\r\n state.addMessage(\"Could not add directory \" + path\r\n + \" because it contains illegal characters.\\n\");\r\n }\r\n }\r\n }",
"public BookmarkId addFolder(BookmarkId parent, int index, String title) {\n return nativeAddFolder(mNativeEnhancedBookmarksBridge, parent, index, title);\n }",
"Directory createAsDirectory() {\n return getParentAsExistingDirectory().findOrCreateChildDirectory(name);\n }",
"@Test\n public void testNewFolderInMailbox() {\n String newFolderPath = \"Inbox\" + File.separator + \"junit\";\n boolean result = instance.newFolderInMailbox(newFolderPath);\n assertEquals(true, result);\n }",
"@Override\n\tpublic String createDirectory(AuthenticationToken authenticationToken, String filePath, String idealFolderName, boolean force) \n\t\t\tthrows PermissionDeniedException, CreateDirectoryFailedException { \n\t\tif(idealFolderName.trim().isEmpty()) \n\t\t\tthrow new CreateDirectoryFailedException(\"Directory name is empty. The directory was not created.\");\n\t\t\n\t\tidealFolderName = fileNameNormalizer.normalize(idealFolderName);\n\t\t\n\t\tFile dir = new File(filePath);\n if(dir.isFile()) {\n \tdir = dir.getParentFile();\n \tfilePath = dir.getAbsolutePath();\n }\n dir.mkdirs();\n\t\t\n\t\tboolean permissionResult = filePermissionService.hasWritePermission(authenticationToken, filePath);\n\t\tif(!permissionResult)\n\t\t\tthrow new PermissionDeniedException();\n\t\telse {\n\t\t\tboolean inUseResult = this.isInUse(authenticationToken, filePath);\n\t\t\tif(inUseResult)\n\t\t\t\t//throw new CreateDirectoryFailedException(\"Can't create directory. Parent directory is currently in use.\");\n\t\t\t\tthrow new CreateDirectoryFailedException(\"Can't create directory. Parent directory \"+this.createMessageFileInUse(authenticationToken, filePath)+\". Delete the tasks using Task Manager, then try again.\");\n\t\t\telse {\n\t\t\t\tFile file = new File(filePath + File.separator + idealFolderName);\n\t\t\t\tboolean resultMkDir = file.mkdir();\n\t\t\t\tif(!resultMkDir && force) {\n\t\t\t\t\tString date = dateTimeFormat.format(new Date());\n\t\t\t\t\tidealFolderName = idealFolderName + \"_\" + date;\n\t\t\t\t\tfile = new File(filePath + File.separator + idealFolderName);\n\t\t\t\t\tresultMkDir = file.mkdir();\n\t\t\t\t\tint i = 1;\n\t\t\t\t\twhile(!resultMkDir) {\n\t\t\t\t\t\tfile = new File(filePath + File.separator + idealFolderName + \"_\" + i++);\n\t\t\t\t\t\tresultMkDir = file.mkdir();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif(!resultMkDir){ \n\t\t\t\t\tif(file.isDirectory() && file.exists())\n\t\t\t\t\t\tthrow new CreateDirectoryFailedException(\"Directory \"+file.getName()+\" already exists. You can try again with another name.\");\n\t\t\t\t\telse\n\t\t\t\t\t\tthrow new CreateDirectoryFailedException(\"Network or server errors\");\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\treturn file.getAbsolutePath();\n\t\t\t}\n\t\t}\n\t}",
"public static void createExportFolder(String exportPath) {\n File folder = new File(exportPath);\n if (folder.exists()) {\n for (File file : folder.listFiles()) {\n if (!file.isDirectory()) {\n file.delete();\n }\n }\n } else {\n folder.mkdir();\n }\n }",
"public void createDir(File file){\n\t\tif (!file.exists()) {\n\t\t\tif (file.mkdir()) {\n\t\t\t\tlogger.debug(\"Directory is created!\");\n\t\t\t} else {\n\t\t\t\tlogger.debug(\"Failed to create directory!\");\n\t\t\t}\n\t\t}\n\t}",
"public boolean createDir(String userName) {\n\t\tString path = userName;\n\n\t\tboolean success = true;\n\t\ttry{\n\t\t\tsuccess = (new File(path)).mkdirs();\n\t\t\tSystem.out.println(success);\n\t\t}\n\t\tcatch (Exception e) {\n\t\t\t// TODO: handle exception\n\t\t}\n\t\treturn success;\n\n\t}",
"public static void createDirectories() \r\n\t{\r\n\t\tif(!fCertificatesDir().exists()) \r\n\t\t{\r\n\t\t\tfCertificatesDir().mkdir();\r\n\t\t}\r\n\t\t\r\n\t\tif(!fDbDir().exists()) \r\n\t\t{\r\n\t\t\tfDbDir().mkdir();\r\n\t\t}\r\n\t\t\r\n\t\tif(!fMibsDir().exists())\r\n\t\t{\r\n\t\t\tfMibsDir().mkdir();\r\n\t\t}\r\n\t\t\r\n\t\tif(!fMibsBinaryDir().exists()) \r\n\t\t{\r\n\t\t\tfMibsBinaryDir().mkdir();\r\n\t\t}\r\n\t\t\r\n\t\tif(!fMibsTextDir().exists()) \r\n\t\t{\r\n\t\t\tfMibsTextDir().mkdir();\r\n\t\t}\r\n\t}",
"public void createSubDirData() {\n\t\tFile f = new File(getPFDataPath());\n\t\tf.mkdirs();\n\t}",
"private void createDataModelFolders() {\n\n File dataFolder = new File(Environment.getExternalStorageDirectory() + \"/AGH_IM_DATA\");\n File modelFolder = new File(Environment.getExternalStorageDirectory() + \"/AGH_IM_MODEL\");\n\n boolean dataSuccess = true;\n boolean modelSuccess = true;\n if (!dataFolder.exists()) {\n try {\n dataSuccess = dataFolder.mkdirs();\n } catch (SecurityException e) {\n dataSuccess = false;\n }\n }\n\n if (!modelFolder.exists()) {\n try {\n modelSuccess = modelFolder.mkdirs();\n } catch (SecurityException e) {\n modelSuccess = false;\n }\n }\n\n String TAG = \"MainScreen\";\n if (dataSuccess) Log.d(TAG, \"Created AGH_IM_DATA folder\");\n else Log.d(TAG, \"Cannot create AGH_IM_DATA Folder\");\n if (modelSuccess) Log.d(TAG, \"Successfully created AGH_IM_MODEL folder\");\n else Log.d(TAG, \"Cannot create AGH_IM_MODEL Folder\");\n\n }",
"private void createScratchDirectory(Path rootpath) {\n\t\tprintMsg(\"running createScratchDirectory() in \\\"\" + this.getClass().getName() + \"\\\" class.\");\n\t\t\n\t\tif (Files.isDirectory(rootpath)) {\n\t\t\tprintMsg(\"The \" + theRootPath + \" exists...\");\n\t\t} else {\n\t\t\tprintMsg(\"Creating \" + theRootPath);\n\t\t\ttry {\n\t\t\t\tFiles.createDirectories(rootpath);\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}",
"public void createSubDirCameraTaken() {\n\t\tFile f = new File(getPFCameraTakenPath());\n\t\tf.mkdirs();\n\t}",
"private static void createProjectsFolders() throws IOException {\n /*\n * .sagrada/\n * logs/\n */\n File logFolder = new File(Constants.Paths.LOG_FOLDER.getAbsolutePath());\n\n if (!logFolder.isDirectory() && !logFolder.mkdirs()) {\n throw new IOException(\"Could not directory structure: \" + (Constants.Paths.LOG_FOLDER.getAbsolutePath()));\n }\n }",
"@Override\n protected void createRootDir() {\n }"
] | [
"0.86448646",
"0.780103",
"0.7707089",
"0.7635434",
"0.74418557",
"0.743286",
"0.7399411",
"0.7370476",
"0.7344938",
"0.73014176",
"0.7284769",
"0.7261802",
"0.72544295",
"0.72271764",
"0.71534586",
"0.71481186",
"0.71051574",
"0.7104786",
"0.70903087",
"0.70327497",
"0.6985019",
"0.69550323",
"0.6928309",
"0.6926165",
"0.690086",
"0.68891907",
"0.68755996",
"0.6804528",
"0.68016213",
"0.67963696",
"0.6794689",
"0.67935497",
"0.678671",
"0.67650163",
"0.67419386",
"0.6681302",
"0.6656965",
"0.66387784",
"0.6614137",
"0.6605891",
"0.6581535",
"0.6561124",
"0.65334064",
"0.6515199",
"0.64915234",
"0.64756835",
"0.64659154",
"0.64609945",
"0.6421879",
"0.63947505",
"0.6393878",
"0.6382425",
"0.63703597",
"0.6362661",
"0.6356774",
"0.6343158",
"0.63418484",
"0.63240063",
"0.6314396",
"0.6304457",
"0.6290265",
"0.6287901",
"0.6278723",
"0.62766707",
"0.6271375",
"0.6266694",
"0.6249583",
"0.61986136",
"0.6151436",
"0.6136869",
"0.61267376",
"0.6120775",
"0.61137545",
"0.61115986",
"0.6085501",
"0.60808545",
"0.6068563",
"0.6047599",
"0.60316986",
"0.60315514",
"0.60224867",
"0.6007749",
"0.5996934",
"0.5965621",
"0.59616166",
"0.5960398",
"0.59376454",
"0.593483",
"0.59292483",
"0.5922263",
"0.5911237",
"0.5896077",
"0.5893289",
"0.58702433",
"0.5866074",
"0.584145",
"0.5813181",
"0.5783726",
"0.57596004",
"0.5759521",
"0.5752527"
] | 0.0 | -1 |
Created by dumingwei on 2017/9/3. | public interface Presenter<V> {
void attachView(V view);
void detachView();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void perish() {\n \n }",
"private stendhal() {\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"private static void cajas() {\n\t\t\n\t}",
"public final void mo51373a() {\n }",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n void init() {\n }",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"private void poetries() {\n\n\t}",
"@Override\n public void init() {\n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"private void init() {\n\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"public void mo38117a() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n public void init() {\n\n }",
"public void mo4359a() {\n }",
"@Override\n public void init() {}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n protected void init() {\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\tpublic void jugar() {\n\t\t\n\t}",
"@Override\n public int describeContents() { return 0; }",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\n\tpublic void init()\n\t{\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"private void kk12() {\n\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tpublic void init() {\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"protected boolean func_70814_o() { return true; }",
"private Rekenhulp()\n\t{\n\t}",
"public void mo6081a() {\n }",
"private void m50366E() {\n }",
"private void strin() {\n\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\n public void initialize() { \n }",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"private void init() {\n\n\n\n }",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\n public void initialize() {\n \n }",
"@Override\n\t\tpublic void init() {\n\t\t}",
"@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}",
"@Override\n public void init() {\n }"
] | [
"0.61049306",
"0.59209055",
"0.58070326",
"0.58070326",
"0.5801899",
"0.57870984",
"0.57472324",
"0.57277536",
"0.5671025",
"0.5657757",
"0.56333196",
"0.56285405",
"0.56217575",
"0.5589117",
"0.55884457",
"0.55734414",
"0.5564747",
"0.55644894",
"0.55615807",
"0.55614865",
"0.5548218",
"0.55480164",
"0.55480164",
"0.55480164",
"0.55480164",
"0.55480164",
"0.5546395",
"0.55415314",
"0.5537901",
"0.55286944",
"0.55258507",
"0.551791",
"0.5500168",
"0.5497457",
"0.54923135",
"0.5487565",
"0.5486263",
"0.5486263",
"0.5486263",
"0.5486263",
"0.5486263",
"0.5486263",
"0.546009",
"0.5455025",
"0.5455025",
"0.5455025",
"0.54525244",
"0.54522437",
"0.54522437",
"0.5446664",
"0.5446664",
"0.544466",
"0.5442591",
"0.5436689",
"0.5436689",
"0.5436689",
"0.5436561",
"0.5424767",
"0.5424767",
"0.5419598",
"0.5413391",
"0.5403977",
"0.5403977",
"0.5403977",
"0.53930515",
"0.53812206",
"0.5367791",
"0.53671175",
"0.5359046",
"0.5356648",
"0.53564674",
"0.53544843",
"0.5347038",
"0.53432983",
"0.5342524",
"0.5332722",
"0.5332722",
"0.5332722",
"0.5332722",
"0.5332722",
"0.5332722",
"0.5332722",
"0.5328133",
"0.5326783",
"0.5325874",
"0.5324321",
"0.5321168",
"0.5311164",
"0.5305328",
"0.5303345",
"0.5292825",
"0.5291256",
"0.52884024",
"0.5277744",
"0.527338",
"0.52693695",
"0.52677524",
"0.52619845",
"0.5254861",
"0.5251204",
"0.52463436"
] | 0.0 | -1 |
Approach 1: Direct create the object of implementation class /Airtel airtel = new Airtel(); airtel.calling(); airtel.data(); Approach 2: Use the interface reference to hold the object of implementation class This is nothing but runtime polymorphism. /Sim sim = new Airtel(); sim.calling(); sim.data(); Challenges in above approches 1) If new sim came in market or want to change the operator, need to do code changes on source code. 2) Application is not configurable Solution: 1) Make the app configurable using IoC Why & How? 1) As a developer, we must focus on business logic. 2) Spring framework provides the container, which will creates and manages the objects for us 3) The objects created by container called as beans. 4) Container nothing but an interface either BeanFactory or ApplicationContext | public static void main(String[] args) {
ApplicationContext context = new ClassPathXmlApplicationContext("beans.xml");
System.out.println("context loaded");
// Sim sim = (Sim) context.getBean("sim");
/**
* Avoid above type casting
*/
Sim sim = context.getBean("sim", Sim.class);
sim.calling();
sim.data();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void main()\n {\n ContextImplementation context = new ContextImplementation(new StrategyAImplementation());\n context.doSomething();\n\n context.setStrategy(new StrategyBImplementation());\n context.doSomething();\n\n // Define a one-to-many dependency between objects so that when the object change states,\n // all it dependents are notified and updated automatically.\n SubjectImplementation subject = new SubjectImplementation();\n\n ObserverInterface saori = new ObserverImplementation(\"Saori\");\n subject.attach(new ObserverImplementation(\"Horatio\"));\n subject.attach(new ObserverImplementation(\"Harper\"));\n subject.attach(saori);\n\n subject.notifyObservers(\"Leon departed for work\");\n\n subject.detach(saori);\n subject.notifyObservers(\"Leon arrived back from work\");\n\n // Attach additional responsibilities to an object dynamically.\n // Decorators provide a flexible alternative to subclassing in order to extend features/functions.\n // Also know as a wrapper.\n Component component = new ComponentImplementation();\n component.doSomething();\n\n Component decoratorA = new DecoratorAImplementation(component);\n decoratorA.doSomething();\n\n Component decoratorB = new DecoratorBImplementation(component);\n decoratorB.doSomething();\n\n Component decoratorC = new DecoratorBImplementation(decoratorA);\n decoratorC.doSomething();\n\n // Define a skeleton of an algorithm in an operation deferring steps to the subclasses.\n // Template method design pattern lets subclasses redefine certain steps on an algorithm without changing the structure of the algorithm.\n new TemplateMethodAImplementation().templateMethod();\n\n new TemplateMethodBImplementation().templateMethod();\n\n // Defines a higher-level interface that makes the subsystems easier to use.\n // Client of the facade don't have to access the sub system objects directly.\n new Facade().doSomething();\n\n // Converts the interface of a class into another interface clients expect.\n // Adapter lets classes work together that couldn't otherwise because of incompatible interfaces.\n // Target defines the interface that a client uses, Adaptee defines and existing interface that needs to be adapted, and Adapter adapts the interface of Adaptee to the Target interface.\n Target adapter = new Adapter();\n adapter.request();\n\n // Ensure a class only has one instance, and provide a global point of access to it.\n // The class itself is responsible for keeping track of it sole instance.\n // The class can ensure that no other instances can be created (by intercepting requests to create new objects), and provide a way to access to access to single instances.\n Singleton singleton = Singleton.getInstance();\n singleton.doSomething();\n\n // Defines an object that encapsulates how a set of objects interact.\n // Mediator promotes loose coupling by keeping objects from referring to each other explicitly, and lets you vary their interaction independently.\n Mediator mediator = new MediatorImplementation(); // Defines the mediator interface enabling a community of colleague objects to interact.\n Colleague a = new ColleagueAImplementation(mediator); // Each colleague knows its mediator objects.\n // The colleague classes are decoupled, adding a new colleague does not impact mediation.\n Colleague b = new ColleagueBImplementation(mediator);\n\n // Each colleague communicates with its mediator whenever it would have otherwise communicated with another colleague directly.\n a.sendMessage(\"Hi Horatio\");\n b.receiveMessage();\n\n // Reduces communication channels between colleagues since a colleague only has to communicate with the mediator.\n b.sendMessage(\"Hi Harper\");\n a.receiveMessage();\n\n // Decouples an abstraction from it implementation so that the two can vary independently.\n // Divides the abstraction and the implementation into separate class hierarchies.\n // Changes in the implementation of an abstraction should not have an impact on clients.\n Implementor impA = new ImplementorA();\n Implementor impB = new ImplementorB();\n\n // Implementation of an abstraction can be configured at runtime.\n Client clientA = new Client(new AbtractionImplementation(impA));\n clientA.doSomething();\n\n Client clientB = new Client(new AbtractionImplementation(impB));\n clientB.doSomething();\n\n // Command pattern decouples the object that invokes the operation from the one that knows how to perform it.\n Receiver receiver = new Receiver();\n // Client create a command implementation and specifies a receiver.\n Command command = new CommandImplementation(receiver);\n Invoker invoker = new Invoker();\n // Invoker stores the command object.\n invoker.setCommand(command);\n // Invoker issues a request by calling Execute on the command.\n invoker.execute();\n\n }",
"public interface IShopEngine {\n\n\n /**\n * Moves a product from basket to archive basket\n */\n public void doShopping(IBasket basket,IArchiveBasket archiveBasket);\n\n}",
"public interface OrientationWorkshopI {\n\tpublic void construct(OrientationChecklistI orientationChecklist);\n\n}",
"public static void main(String[] args) {\n \tITelephone timsPhone = new DeskPhone(123456);\n \t//It is also valid to do as below but later you cannot assign the field to the new Mobile Phone Class object creation below\n \t//DeskPhone timsPhone = new DeskPhone(123456);\n \t\n \t//The below is not valid\n \t//ITelephone timsPhone = new ITelephone(123456);\n \n \ttimsPhone.powerOn();\n timsPhone.callPhone(123456);\n timsPhone.answer();\n \n //for MobilePhone\n //you can see we can use the timsPhone variable as it is Interface type and both are implementing the same interface\n //so you can create a new MobilePhone class object using that field of Interface type.\n timsPhone = new MobilePhone(24565);\n \n //if you was using DeskPhone timsPhone above like below it wont work\n //DeskPhone timsPhone = new DeskPhone(123456);\n \n timsPhone.powerOn();\n timsPhone.callPhone(24565);\n timsPhone.answer();\n \n\n\n }",
"public interface ICarFactory {\n\t\n\tpublic ICar produce(String carType);\n\t\n\t \n\t\n}",
"public interface Implementor {\n // 实现抽象部分需要的某些具体功能\n void operationImpl();\n}",
"public interface AppFacade {\n\n String test();\n\n DashboardBo getDashboard();\n\n List<AppStatBo> getAppDetailList(String startDate,String endDate);\n\n List<HostStatBo> getHostDetailList(String startDate,String endDate);\n\n List<AppInfoBo> getAppList();\n\n List<AppInfoBo> getAppList(int appType);\n\n List<TopTimeBo> topReq(String startDate,String endDate,String host,String appName,String moduleName,String method,int size);\n\n}",
"Implementation createImplementation();",
"public interface IFactory {\n\n public IUser createUser();\n\n public IDepartment addDepartment();\n}",
"public interface AbstractFactory {\n /**\n * Create cpu cpu.\n *\n * @return the cpu\n */\n Cpu createCpu();\n\n /**\n * Create main board main board.\n *\n * @return the main board\n */\n MainBoard createMainBoard();\n}",
"public interface AppManager {\n /**\n * 根据bizCode获取业务信息\n * @param bizCode\n * @return\n * @throws ItemException\n */\n public BizInfoDTO getBizInfo(String bizCode) throws ItemException;\n\n /**\n * 根据appKey获取应用信息\n * @param appKey\n * @return\n * @throws ItemException\n */\n public AppInfoDTO getAppInfo(String appKey) throws ItemException;\n\n\n public AppInfoDTO getAppInfoByType(String bizCode, AppTypeEnum appTypeEnum) throws ItemException;\n\n\n}",
"public interface Pet {// interface is the blueprint for other class\r\n\r\n\tpublic String food();// method food abstract method no action \r\n\r\n\r\n}",
"public interface IFactory {\n Operation CreateOperation();\n\n}",
"public interface Factory {\n Animal createAnimal();\n}",
"public interface Factory {\n LeiFeng createLeiFeng();\n}",
"public interface IAnimalFactory {\n ICat createCat();\n IDog createDog();\n}",
"public interface KaupService {\n public String excute(int length, int weight);\n public String excute(KaupBean kaupBean);\n}",
"public interface IPredictionService {\n\t\n\t\n\t/**\n\t * \n\t * Create an instance object of TestSet\n\t * \n\t * @param position\n\t * @return\n\t * @throws Exception\n\t */\n\tpublic Instances makeTestSet(String position) throws Exception;\n\t\n\t/**\n\t * Used a particular algorithm to train the Artificial Intelligence (AI)\n\t * @throws Exception\n\t */\n\tpublic void train() throws Exception;\n\t\n\t/**\n\t * Used to classify after train\n\t * @throws Exception\n\t */\n\tpublic void classify() throws Exception;\n\n}",
"public interface IFactory {\n IProductA getProductA();\n IProductB getProductB();\n}",
"public static void main(String[] args) {\n\t\tDomestic_Consumer dc=new Domestic_Consumer(111,\"vishal\");\r\n\t\t//better way to implement runtime polymorhism\r\n\t\t//ref variable of interface pointing to implementing class\r\n\t\tElectric_Domestic dom=new Domestic_Consumer(123,\"java\");\r\n\t\tint bill=dom.calcBill(130);\r\n\t\tSystem.out.println(\"Totl bill is \"+bill);\r\n\t\t bill=dc.calcBill(100);\r\n\t\tSystem.out.println(\"bill is\" +bill);\r\n\r\n\t}",
"public static void main(String args[]){\nA obj = new B();\n/*And this if I say */\n obj.show(); //This will execute but when I say\n/* obj.display();*/ // This is not possible because display doesnt belong to A interface it belongs\n // to C and I am restricting this user from using this display.\n//This is why Interface are largely used and this the importance of Interface.\n//1 Interface helps you to use Multiple Interface in Java. \n//2.It provides you security. \n//3.Whenever you want to instanstiate an interface we need to create a class which will implement\n// your interface.\n//4. \n}",
"public interface ProductFactory {\n Product createProduct();\n}",
"public interface Animal {\n\n //Animal reproduce();\n\n}",
"public interface ICarFactory {\n}",
"public interface Employee{\n\n void takeCall();\n void endCall();\n}",
"public interface IFactory {\n IUser createUser();\n IDepartment createDepartment();\n}",
"public interface IElementService {\n\n /**\n * Create new element\n * @param name\n */\n public IElement createNewElement(String name);\n}",
"public interface Factory {\n Product create();\n}",
"public interface EngineInterface<T> {\n\tpublic T run (Mower mower);\n}",
"public static void main(String[] args) {\n\t\tA a=new A();\r\n\t\ta.display();\r\n\t\ta.a_display(); // non interface method.\r\n\t\t\r\n\t\t//output : ====A display====\r\n/* Exp: In the above code we defined referance variable \"a\" as A class type,\r\n \t\tin order to call display() method which A class implemented.*/\r\n\t\t\r\n\t//case 2: Now if we want to use display method in B class we will do following code\r\n\t\t\r\n\t\tB b=new B();\r\n\t\tb.display();\r\n\t\t\r\n\t\t//output : \t\t====B display====\r\n/* Exp: In the above code we defined referance variable \"b\" as B class type,\r\n \t\tin order to call display() method which B class implemented. */\r\n\t\t\r\n\t\tInn i=new A(); //new B() to access B class display()\r\n\t\ti.display();\r\n\t\t/*i.a_display(); this gives an error, since interface referance cannot\r\n\t\tpoint to non interface methods*/\r\n\t\t\r\n\t\t//output : ====A display====\r\n\t\t\r\n/*\t\tExp: The above code states that object of \"A\" class was stored in \"i\" variable\r\n\t\t\t which is of \"Inn\" interface type. Since A implements Inn, so Inn type varables\r\n\t\t\t can call all methods in that Interface. \r\n\t\t\t \r\n\t\t\t So display() which belongs to Inn and implemented by A class can be accesed \r\n\t\t\t by \"i\" varable. \r\n\t\t\t this results i.display() to give output \"====A display====\".\r\n\t\tin case2:\r\n\t\t\t Now if I want to access display() in B implementation we simple need\r\n\t\t\t TO CHANGE ONLY ONE LINE \" ie OBJECT CREATION\"\r\n\t\t\t Inn i= new B();\r\n\t\t\t\ti.display();\r\n\t\t\r\n\t\t//output : ====B display====\r\n\t\t\t */\r\n \t\t\r\n\t/*Now we can state that \"Inn\" Interface reference \"i\" is going point any\r\n\tclass object \"A\" or \"B\"\tthat implements \"Inn\"\r\n\t\tNOTE: AN INTERFANCE REFERENCE CANNOT POINT TO NON INTERFACE MENTHODS IN A CLASS \r\n\t\t*/\r\n\t}",
"public interface AddDealInteractor {\n void createDeal(String name, String price, String info);\n}",
"public interface IBuyCar {\n //买车\n void buyCar();\n}",
"interface Employee {\n\tpublic void showEmployeeDetails();\n}",
"public interface DrinksFactory {\n //饮料\n Drinks dBuild();\n\n //面包\n Bread bBuild();\n\n void buyWhat();\n}",
"public interface IAComponentContext\r\n {\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n public de.uka.ipd.sdq.simucomframework.variables.userdata.UserData getUserData();\r\n \t \r\n public void setUserData(de.uka.ipd.sdq.simucomframework.variables.userdata.UserData data);\r\n\n\r\n\r\n }",
"public interface LandService {\n\t//declare some methods \n\tpublic List<LandBean> getAllLands() ;\n\tpublic boolean deleteLand(int id);\n\tpublic boolean addLand(LandBean bean);\n\tboolean modifyLand(LandBean bean);\n\n}",
"public static void main(String[] args) {\n\t\tAbstraction ab = new RefinedAbstraction();\r\n\r\n\t\tab.SetImplementor(new ConcreteImplementorA());\r\n\t\tab.Operation();\r\n\r\n\t\tab.SetImplementor(new ConcreteImplementorB());\r\n\t\tab.Operation();\r\n\t}",
"interface Workshop{\n\tabstract public void work();\n}",
"public interface TempusService extends Serializable {\n\n\t/**\n\t * Initialize the service \n\t * \n\t * @param rowanApp\n\t */\n\tpublic void init(TempusApp rowanApp) throws Exception;\n\n}",
"public interface IOrderFactory{\n\t\n\t/**\n\t * Creates a collection of taxes for US and EU customers\n\t * \n\t * @return the sales tax\n\t */\n\tpublic ISalesTax getTaxObject();\n\t\n\t/**\n\t * Creates the shipping cost for US and EU customers\n\t * \n\t * @return shipping cost\n\t */\n\tpublic IShippingRate getRateObject();\n}",
"public interface RifaMainPresenter {\n void onCreate();\n void onDestroy();\n\n void getRifas();\n void saveFirma(Rifa rifa);\n void removeRifa(Rifa rifa);\n void onEventMainThread(RifaMainEvent event);\n\n RifaMainView getView();\n}",
"public interface BaseModel {\n public static IHttp iHttp = HttpFactory.create();\n\n public static IHttp getiHttp=HttpFactory.create1();\n}",
"ObjectRealization createObjectRealization();",
"public interface ILabReportService {\n //01.保存报表\n public int saveLabReport(LabReport labinfo);\n //02.获取报表数据\n public LabReport getLabReport();\n}",
"public interface Engine {\n\n String run();\n\n}",
"public interface Application {\n /**\n * Initializes resources used by the Application.\n *\n * @param config the application's configuration object\n */\n public void init(ApplicationConfig config) throws ServletException;\n \n /**\n * Called by the TeaServlet when the application is no longer needed.\n */\n public void destroy();\n\n /**\n * Creates a context, which defines functions that are callable by\n * templates. Any public method in the context is a callable function,\n * except methods defined in Object. A context may receive a request and\n * response, but it doesn't need to use any of them. They are provided only\n * in the event that a function needs access to these objects.\n * <p>\n * Unless the getContextType method returns null, the createContext method\n * is called once for every request to the TeaServlet, so context creation\n * should have a fairly quick initialization. One way of accomplishing this\n * is to return the same context instance each time. The drawback to this\n * technique is that functions will not be able to access the current\n * request and response.\n * <p>\n * The recommended technique is to construct a new context that simply\n * references this Application and any of the passed in parameters. This\n * way, the Application contains all the resources and \"business logic\",\n * and the context just provides templates access to it.\n *\n * @param request the client's HTTP request\n * @param response the client's HTTP response\n * @return an object context for the templates\n */\n public Object createContext(ApplicationRequest request,\n ApplicationResponse response);\n\n /**\n * The class of the object that the createContext method will return, which\n * does not need to implement any special interface or extend any special\n * class. Returning null indicates that this Application defines no\n * context, and createContext will never be called.\n *\n * @return the class that the createContext method will return\n */\n public Class getContextType();\n}",
"public interface IJobInfoService {\n /**\n * 列表查询\n * @param vo\n * @return\n */\n DataListVo queryList(QueryJobInfoListVo vo);\n\n /**\n * 列表查询\n * @param vo\n * @return\n */\n JobInfoDetailVo queryDetail(BaseQueryVo vo);\n}",
"public interface AppStandardService {\n\n int addStanard(AppStandard appStandard) throws MilkTeaException;\n\n\n //int updataStandard(AppStandard appStandard) throws MilkTeaException;\n\n AppStandard selectById(String id);\n\n // List<AppStandard> selectByGoodsId(String id);\n\n}",
"public UserInterface createInterface(Object object) {\n User user = (User) object;\n switch (user.getClass().getName()) {\n case InterfaceFactory.APPLICANT_CLASS_NAME:\n return new ApplicantInterface(user);\n case InterfaceFactory.INTERVIEWER_CLASS_NAME:\n return new InterviewerInterface(user);\n case InterfaceFactory.HRCOORDINATOR_CLASS_NAME:\n return new HRCoordinatorInterface(user);\n }\n return null;\n }",
"public interface RentalFactory {\n\n Rental createRental(String pickUpdate, String returnDate, List<PaymentMethod> paymentMethod);\n\n}",
"public interface RuntimewiringInterface {\n public RuntimeWiring buildWiring();\n}",
"public static void main(String[] args)\r\n{\n\tInterfaceDemo obj=new InterfaceDemo();\r\n\t//3. Reference variable can be created\r\n\tInterfaceDemo obj1=new Demo();\r\n}",
"public interface IFactory {\n ICustomer getCustomer(CustomerType type);\n IAccount getAccount(Enum type);\n// IEntry getEntry(EntryType type);\n DAO getDAO(Enum type);\n\n}",
"public interface HomeService {\n public HomeBean getHomeBean(String name);\n}",
"public interface AppManager {\n public AppInfoDTO getAppInfoByDomain(String domainName) throws ServiceException;\n\n public AppInfoDTO getAppInfoByType(String bizCode, AppTypeEnum appTypeEnum) throws ServiceException;\n\n public String getAppDomain(String bizCode, AppTypeEnum appTypeEnum) throws ServiceException;\n\n public BizInfoDTO getBizInfo(String bizCode) throws ServiceException;\n\n public BizInfoDTO getBizInfoByppKey(String appKey) throws ServiceException;\n\n void addAppProperty(AppPropertyDTO appPropertyDTO) throws ServiceException;\n\n void addBizProperty(BizPropertyDTO bizPropertyDTO) throws ServiceException;\n\n public Boolean checkNameEN(String name) throws ServiceException;\n\n BizInfoDTO addBizInfo(BizInfoDTO bizInfoDTO) throws ServiceException;\n\n AppInfoDTO addAppInfo(AppInfoDTO appInfoDTO) throws ServiceException;\n\n void updateBizProperty(String bizCode, String pKey, String value, ValueTypeEnum valueType) throws ServiceException;\n \n String getAppKeyByBizCode(String bizCode,AppTypeEnum appTypeEnum);\n}",
"public interface ICompteService {\n\t/**\n\t * Declaration des methodes metier\n\t */\n\tpublic void createCompte(Compte compte);\n\n\tpublic List<Compte> getAllCompte();\n\n\tpublic void deleteCompte(Long numeroCompte);\n\n\tpublic void updateCompte(Compte compte);\n\n\tpublic Compte getCompteById(Long numeroCompte);\n\n\tpublic void virement(Long compteEmetteur, Long compteRecepteur, double montant);\n\n\tpublic void versement(long numeroCompte, double montant);\n\n}",
"public interface Engine {\n public void fire();\n}",
"public interface cpurseModelInterface {\n\n void getTimeTable(coursePresInterface coursePresInterface, Context context, String stdId);\n void getAttendance(coursePresInterface coursePresInterface,Context context, String stdId);\n void getHomeWork(coursePresInterface coursePresInterface,Context context, String stdId);\n void getExam(coursePresInterface coursePresInterface,Context context, String stdId);\n}",
"public interface Provider{\n Service newService();\n}",
"public interface BuilderIntf extends LogicIntf {\r\n\r\n\t/**\r\n\t * Executes build process.\r\n\t * @return built and runnable instance.\r\n\t */\r\n\tpublic RunnerIntf build();\r\n\r\n}",
"public interface IHomeVIew {\n void getData(List<HomeDataInfo.DataBean.RecommendUserListBean> list);\n void getHeadViewPagerData(List<HomeDataInfo.DataBean.BannerListBean> list);\n void getDataAll(HomeDataInfo homeDataInfo);\n void getListData(HomeListDataInfo homeListDataInfo);\n}",
"public interface TestFactory {\n AssistedObjImpl getAssistedObj(String text);\n}",
"public interface QAService {\n}",
"public interface BeanFactory {\r\n\t/**\r\n\t * Creates a new instance of the bean this is the factory for and invokes \r\n\t * its {@link Initializer}s.\r\n\t * @param controller the controller to use (needed for Actors only, may be null otherwise)\r\n\t * @param props the initial properties of the new bean\r\n\t * @return the new bean\r\n\t */\r\n\tpublic Object createNewInstance(Controller controller, Props props);\r\n}",
"public interface ITVFactory {\n ITV createTV();\n}",
"public interface MobileAppExpert {\n\n void deliverMobileApp();\n\n}",
"public interface Comunicator {\n \n\n}",
"public interface ZhiHuPresenter {\n // 用于View的数据刷新\n interface View extends LifeSubscription {\n void refresh();\n }\n\n interface Presenter{\n void fetchDailyData();\n void fetchThemeList();\n void fetchSectionList();\n void fetchHotList();\n }\n}",
"public interface IMainframeFactory {\n\n\t/**\n\t * \n\t * @return new instance of IMainframe\n\t */\n\tIMainframe createInstance();\n}",
"public interface IAppInfoUsePresenter {\n //加载app列表数据\n void loadAppList();\n}",
"private void testAbstraction() {\n Shape triangle = new Triangle();\n\n Shape circle = new Circle();\n\n //Since square implements IShape but not Shape, so we cannot create instance of Shape using Square\n Square square = new Square();\n\n //The end user only calls getNoOfSides(). But does not see implementation in Shape class.\n //Here it picks implementation from Triangle class, so it will return a 3.\n System.out.println(\"No of sides in a triangle: \" + triangle.getNoOfSides());\n System.out.println(\"No of sides in a circle: \" + circle.getNoOfSides());\n System.out.println(\"No of sides in a square: \" + square.getNoOfSides());\n }",
"public interface IFootService {\n\n //添加食品\n public boolean addFoot(Foot foot);\n //查询食品\n public List footList();\n //根据名称查询食品\n public Foot findFootByName(String fname);\n}",
"public interface Person {\n\n public void service();\n\n public void setAnimal(Animal animal);\n\n public void allService();\n}",
"public interface Factory {\r\n}",
"public interface SalesRepresentativeService {\n void addEmployee(Context context, SalesRepresentative employee);\n void updateEmployee(Context context, SalesRepresentative employee);\n}",
"public interface Producto {\r\n\tpublic void accion();\r\n}",
"public interface Product {\n\n void use();\n}",
"public interface Animal {\n\n public void eat();\n public void travel();\n}",
"public interface IHomeContract {\n\n interface IHomeView extends BaseView {\n void showBanner(List<BannerBean> banner);\n\n void showCats(List<HomeCatBean> cats);\n\n void showArticles(JSONArray articles);\n\n void showGifts(List<HomeGiftBean> gifts);\n\n void showAds(JSONArray ads);\n\n void showFoods(List<HomeFoodShopBean> foods);\n\n void showHotels(List<HomeFoodShopBean> foods);\n\n void showEducations(List<HomeFoodShopBean> foods);\n\n void showEntertainments(List<HomeFoodShopBean> foods);\n\n void showFinances(List<HomeFoodShopBean> finances);\n\n void showGoods(List<HomeGoodBean> goods);\n\n //设置推荐汽车\n void showCars(List<HomeFoodShopBean> goods);\n\n //设置推荐健康\n void showHealth(List<HomeFoodShopBean> healths);\n\n //推荐商务\n void showCommerceData(List<HomeFoodShopBean> commerce);\n\n //推荐家政\n void showHousekeeping(List<HomeFoodShopBean> housekeeping);\n\n //推荐家居\n void showHomes(List<HomeFoodShopBean> homes);\n }\n\n interface IHomePresenter {\n // 获取Home数据\n void getHomeData();\n }\n\n interface IHomeModel {\n // 获取Home数据\n void getHomeData(IHomeCallback callback);\n\n abstract class IHomeCallback extends ModelCallback {\n\n public IHomeCallback(BaseView view) {\n super(view);\n }\n\n public void onBannerData(List<BannerBean> banner) {\n }\n\n public void onCatData(List<HomeCatBean> cats) {\n }\n\n public void onArticleData(JSONArray articles) {\n }\n\n public void onGiftData(List<HomeGiftBean> gifts) {\n }\n\n public void onAdData(JSONArray ads) {\n }\n\n public void onFoodData(List<HomeFoodShopBean> foods) {\n }\n\n public void onHotelsData(List<HomeFoodShopBean> hotels) {\n }\n\n public void onEducationData(List<HomeFoodShopBean> educations) {\n }\n\n public void onEntertainmentData(List<HomeFoodShopBean> entertainments) {\n }\n\n public void onFinanceData(List<HomeFoodShopBean> finances) {\n }\n\n public void onGoodsData(List<HomeGoodBean> goods) {\n }\n\n public void onHealthData(List<HomeFoodShopBean> healths) {\n }\n\n public void onCarsData(List<HomeFoodShopBean> cars) {\n }\n\n public void onCommerceData(List<HomeFoodShopBean> commerce) {\n }\n\n public void onHousekeepingData(List<HomeFoodShopBean> housekeeping) {\n }\n\n public void onHomeData(List<HomeFoodShopBean> homes) {\n }\n }\n\n }\n\n}",
"public interface ICalculator {\n\n int calculate(String exp);\n\n}",
"public interface ISYview {\n void getADInfoData(ADBean adBean);\n void getSYRecycleInfoData(SYRecycleBean bean);\n}",
"public interface Sensor {\n\n\n\n\n /**\n * Each sensor simulator must collect and\n * report on the temperature of the oven simulator every 100 milliseconds.\n *\n * Each report must include a time stamp and a sensor identifier.\n */\n public abstract void temperatureReport();\n\n public abstract void timer(long milliseconds);\n\n public abstract void updateTemperature(int ovenTemperature);\n\n public abstract void updateTimestamp();\n\n /**\n * To set sensor on or off.\n * @param state set sensor on or off based on oven.\n */\n public abstract void setSensorState(boolean state);\n\n\n\n}",
"public interface user_interface {\n public Double getCredit();\n\n\n public void setCredit(Double credit);\n\n\n public String getName();\n\n public String getType();\n\n public void setFirstName(String name);\n\n public String getSurename();\n\n public void setSurename(String surename);\n\n public String getTypeOfCar();\n\n public String getCarID();\n\n public void setTypeOfCar(String typeOfCar);\n}",
"public interface Strategy {\n\n void info();\n\n}",
"public interface IWechatService {\n CodeRe sumbit(String image1, String image2, String image3, String billno, String openid, String appid, String nick, String tAppid);\n\n WechatPublicServer getWechatPublic(String id);\n\n WechatUserInfo getUser(String openid);\n\n CodeRe<UserConfig> getUserConfig(Serializable id);\n}",
"public interface EquipmentService {\r\n\r\n /**\r\n * 通过日期查询设备明细集合\r\n * @param documentNumber 单据号\r\n * @return 设备明细集合\r\n */\r\n List<EquipmentDate> getEquipment(String documentNumber);\r\n\r\n /**\r\n * 查询设备按日期生成的列表\r\n * @return 设备列表\r\n */\r\n List<EquipmentDate> listEquipment();\r\n\r\n /**\r\n * 新增设备\r\n */\r\n void addEquipment(EquipmentDate equipmentDate);\r\n\r\n /**\r\n * 查找最新单据号\r\n */\r\n List<String> getNewestId();\r\n\r\n /**\r\n * 插入设备明细\r\n */\r\n void addEquipmentItem(EquipmentItem equipmentItem);\r\n\r\n /**\r\n * 更新设备明细\r\n * @param equipmentItemList 设备明细条目\r\n */\r\n void updateEquipmentItem(List<EquipmentItem> equipmentItemList);\r\n\r\n /**\r\n * 设置下拉框数据\r\n */\r\n List<Equipment> getEquipmentNameList(Equipment equipment);\r\n\r\n /**\r\n * 查询设备\r\n */\r\n List<EquipmentDate> search(EquipmentDate equipmentDate);\r\n\r\n /**\r\n * 根据日期查询设备\r\n */\r\n List<EquipmentItem> getEquipmentDataByDate(Date dayTime,Date editTime);\r\n\r\n /**\r\n * 分页\r\n * @param page\r\n * @return Equipment列表\r\n */\r\n List<EquipmentDate> equipmentListPage(Page page);\r\n\r\n /**\r\n * 获取设备数量\r\n * @return 设备数量\r\n */\r\n int count();\r\n\r\n /**\r\n * 查询数量\r\n * @return 查询数量\r\n */\r\n int searchCount(Equipment equipment);\r\n\r\n /**\r\n * 删除设备\r\n */\r\n void deleteEquipment(String documentNumber);\r\n\r\n /**\r\n * 获取编号\r\n * @return 编号\r\n */\r\n String getDocumentNumber();\r\n\r\n Equipment getEquipmentByDocumentNumber(String documentNumber);\r\n\r\n EquipmentDate getEquipmentDateByDocumentNumber(String documentNumber);\r\n}",
"public interface GenericApp {\n\n public void startGame();\n\n public void stopGame();\n}",
"public interface IGameDAO {\n static final Logger LOG = LoggerFactory.getLogger(IGameDAO.class);\n\n public Game getGame(Game example);\n\n public Game createOrUpdate(Game game);\n\n public static class FACTORY {\n\n private static IGameDAO instance = null;\n\n public static IGameDAO getInstance() {\n if(instance == null) {\n synchronized (IGameDAO.class) {\n if(instance == null) {\n try {\n instance = Factory.getImplementation(IGameDAO.class);\n } catch(Exception e) {\n LOG.error(\"Exception getting instance of IGameDAO\", e);\n }\n }\n }\n }\n return instance;\n }\n }\n}",
"Instance createInstance();",
"public interface UserMethoss {\n\n // or link(Ass, ApplicationWirelet.deployAsApplication());\n // or link(Ass, ApplicationWirelet.deployAsApplicationLazyBuild());\n\n // new LazyAssembly();\n BeanConfiguration deploy(Supplier<? extends Assembly> supplier, Wirelet... wirelets);\n\n void deployLazy(boolean buildLazy, Supplier<? extends Assembly> supplier, Wirelet... wirelets);\n}",
"public interface IStrategyInstance {\n void forceRefreshStrategy(String str);\n\n String getCNameByHost(String str);\n\n String getClientIp();\n\n List<IConnStrategy> getConnStrategyListByHost(String str);\n\n String getFormalizeUrl(String str);\n\n @Deprecated\n String getFormalizeUrl(String str, String str2);\n\n @Deprecated\n String getSchemeByHost(String str);\n\n String getSchemeByHost(String str, String str2);\n\n String getUnitPrefix(String str, String str2);\n\n void initialize(Context context);\n\n void notifyConnEvent(String str, IConnStrategy iConnStrategy, ConnEvent connEvent);\n\n void registerListener(IStrategyListener iStrategyListener);\n\n void saveData();\n\n void setUnitPrefix(String str, String str2, String str3);\n\n void switchEnv();\n\n void unregisterListener(IStrategyListener iStrategyListener);\n}",
"public interface Employees {\n public Employees work();\n}",
"public interface IDataBaseRepository {\r\n\r\n /**\r\n * Get DataBase object\r\n *\r\n * @return obj\r\n */\r\n //DataBase getDataBase();\r\n\r\n /**\r\n * Save new clothes\r\n *\r\n * @param clothes obj\r\n */\r\n void save(Clothes clothes);\r\n\r\n /**\r\n * Delete clothes\r\n *\r\n * @param clothes obj\r\n */\r\n void delete(Clothes clothes);\r\n\r\n /**\r\n * Update clothes\r\n *\r\n * @param oldClothes obj\r\n * @param newClothes ojb\r\n */\r\n void update(Clothes oldClothes, Clothes newClothes);\r\n\r\n /**\r\n * Get all clothes\r\n *\r\n * @return list\r\n */\r\n List<Clothes> getAll();\r\n\r\n /**\r\n * Get all clothes by type of the office\r\n *\r\n * @param officeType obj\r\n * @return list\r\n */\r\n List<Clothes> getByOffice(OfficeType officeType);\r\n\r\n /**\r\n * Get clothes by ID\r\n *\r\n * @param id int\r\n * @return clothes obj\r\n */\r\n Clothes getById(int id);\r\n\r\n}",
"public interface IDemoService {\n /**\n * 查询测试申请列表\n *\n * @return\n */\n Map<String, Object> getTestPage(JSONObject jsonObject);\n\n /**\n * 新建测试申请\n *\n * @param jsonObject\n * @return\n */\n int addApply(JSONObject jsonObject);\n\n /**\n * 根据iD获取详细信息\n *\n * @param json\n * @return\n */\n Map<String, Object> getTestItemInfo(JSONObject json);\n\n /**\n * 修改\n */\n\n int updateTestItemInfo(JSONObject json);\n\n /**\n * 审核\n */\n\n int checkTestItemInfo(JSONObject json);\n\n /**\n * 补充\n */\n int addSupply(JSONObject json);\n\n /**\n * 延期\n */\n int addDelay(JSONObject json);\n\n /**\n * 获取补充信息列表\n */\n List<Map<String, Object>> getSupply(JSONObject json);\n /**\n * 获取延期信息列表\n */\n List<Map<String, Object>> getDelay(JSONObject json);\n\n /**\n * 测试完成\n */\n int testComplete(JSONObject json);\n\n /**\n * 导出\n */\n List<Map<String, Object>> export(JSONObject json);\n}",
"public interface Strategy {\n\n\n\tpublic void operation();\n\n}",
"public interface ComponetGraph {\n\n void inject(ManHuaApplication application);\n\n void inject(BaseActivity baseActivity);\n\n void inject(BaseFragment baseFragment);\n\n void inject(SettingActivity settingActivity);//设置\n\n void inject(BarrageSettingActivity barrageSettingActivity);//弹幕设置\n\n void inject(LookPhotoActivity lookPhotoActivity);//查看大图\n\n void inject(SplashActivity splashActivity);//启动页\n\n void inject(TestActivity testActivity);//启动页\n}",
"public interface EmployeeService {\n List<Employee> getAll();\n void create(Employee employee);\n}",
"public interface Factory {\n Cup productCup();\n Cover productCover();\n}",
"public interface RobotConveyor {\n\n Robot createRobot();\n}",
"public interface HotelInfoService extends IProvider {\n HotelInfo getInfo();\n}",
"public interface ComponentInterface {\n\t\n\t/** \n\t * Execute component once and calculate metric values\n\t * \n\t * @param inputData Input data set\n\t * @return List of Objects containing component outputs\n\t */\n\t public java.util.List<Object> execute(java.util.List<Object> inputData);\n\t \n\t /** \n\t * Calculate metrics\n\t * \n\t * @param outputValues Output values of component execution\n\t * @param truthValues Component-generated truth values\n\t * @return List of Objects containing computed values of metrics\n\t */\n\t public java.util.List<Object> calculateMetrics(java.util.List<Object> outputValues, java.util.List<Object> truthValues);\n\t \n\t /**\n\t * Generate an input data set\n\t * @param genericProperties Generic parameters for data set generation (e.g., number of data points)\n\t * @return List of Objects containing generated input values\n\t */\n\t public java.util.List<Object> generateDataSet(java.util.List<Object> genericProperties);\n\t \n\t /**\n\t * Generate truth values \n\t * \n\t * @return List of Objects containing generated truth values\n\t */\n\t public java.util.List<Object> generateTruthValues();\n\t \n\t /**\n\t * Generate values for control variables\n\t * \n\t * @return List of Objects containing generated control variable values\n\t */\n\t public java.util.List<Object> generateControlVars();\n\t \n\t /**\n\t * Set control variable values to use in subsequent executions\n\t * \n\t * @param controlValues Values for control variables\n\t */\n\t public void setControlVars(java.util.List<Object> controlValues);\n\n}"
] | [
"0.6276752",
"0.6110541",
"0.6058006",
"0.6030678",
"0.59851676",
"0.59519976",
"0.5928752",
"0.59071684",
"0.5872855",
"0.5863399",
"0.58559555",
"0.581638",
"0.57587725",
"0.5752466",
"0.5748981",
"0.5747686",
"0.5734888",
"0.5730722",
"0.57077765",
"0.56981045",
"0.56863487",
"0.5665212",
"0.56438863",
"0.5643271",
"0.5639932",
"0.5637825",
"0.5637721",
"0.56168693",
"0.56149924",
"0.5613003",
"0.5594265",
"0.55923426",
"0.5578831",
"0.55785185",
"0.5570969",
"0.55630195",
"0.5562344",
"0.5559595",
"0.554417",
"0.5540363",
"0.55321014",
"0.5523612",
"0.5521043",
"0.55140805",
"0.5499045",
"0.5496275",
"0.5494855",
"0.5494182",
"0.5491736",
"0.54890853",
"0.5488186",
"0.5484282",
"0.5473237",
"0.5467659",
"0.54650867",
"0.5460165",
"0.5458341",
"0.5454269",
"0.545222",
"0.54483694",
"0.54471904",
"0.5446092",
"0.5443973",
"0.5434514",
"0.5434502",
"0.54336077",
"0.54333407",
"0.54194486",
"0.5417265",
"0.54166085",
"0.5410601",
"0.5410205",
"0.54087424",
"0.54063123",
"0.5398463",
"0.5394594",
"0.5390783",
"0.5389635",
"0.538955",
"0.5388709",
"0.5384167",
"0.5379799",
"0.5379161",
"0.53780675",
"0.53776515",
"0.5376756",
"0.53762126",
"0.537212",
"0.5371349",
"0.5368639",
"0.5368604",
"0.5366024",
"0.5360057",
"0.535837",
"0.5356922",
"0.5356814",
"0.53542024",
"0.53534937",
"0.535001",
"0.5349505",
"0.5349404"
] | 0.0 | -1 |
MN implemented chooseTargetRels method to support target reusability 3 May 2014 MN assumptions (1): attrRemainder =0 3 May 2014 | @Override
protected boolean chooseTargetRels() throws Exception {
List<RelationType> rels = new ArrayList<RelationType> ();
int numTries = 0;
int created = 0;
boolean found = false;
RelationType rel;
//MN wanted to preserve the initial values of numOfTgtTables and attsPerTargetRel - 26 April 2014
String[][] attrs = new String[numOfTgtTables][];
// first choose one that has attsPerTargetRel
while(created < numOfTgtTables) {
found = true;
//MN check the following again (it is really tricky) - 26 April 2014
if(created == 0){
if(keySize < attsPerTargetRel)
rel = getRandomRel(false, attsPerTargetRel);
else
//MN we use minimum to increase reusability - 3 May 2014
rel = getRandomRel(false, keySize);
}
else{
rel = getRandomRel(false, attsPerTargetRel+keySize, attsPerTargetRel+keySize);
if(rel != null){
for(int j=0; j<rels.size(); j++)
if(rels.get(j).getName().equals(rel.getName()))
found = false;
}else{
found = false;
}
}
//MN VPISA cares about primary key - 26 April 2014
if(found && !rel.isSetPrimaryKey()) {
//MN set to false because this is target relation (Am I right?) - 3 May 2014
int [] primaryKeyPos = new int [keySize];
for(int i=0; i<keySize; i++)
primaryKeyPos[i] = i;
fac.addPrimaryKey(rel.getName(), primaryKeyPos, false);
}
if(found && rel.isSetPrimaryKey()){
//MN keySize should be keySize and key attrs should be the first attrs- 3 May 2014
int[] pkPos = model.getPKPos(rel.getName(), false);
if(pkPos[0] != 0)
found = false;
}
// found a fitting relation
if (found) {
rels.add(rel);
m.addTargetRel(rel);
attrs[created] = new String[rel.sizeOfAttrArray()];
for(int i = 0; i < rel.sizeOfAttrArray(); i++)
attrs[created][i] = rel.getAttrArray(i).getName();
//MN attsPerTargetRel should be set (check that) (it is really tricky) - 26 April 2014
if(created == 0){
keySize = model.getPKPos(rel.getName(), false).length;
attsPerTargetRel = rel.getAttrArray().length- keySize;
}
created++;
numTries = 0;
}
// not found, have exhausted number of tries? then create new one - path tested 1 May 2014
else {
numTries++;
if (numTries >= MAX_NUM_TRIES)
{
numTries = 0;
attrs[created] = new String[attsPerTargetRel+keySize];
for(int j = 0; j < attsPerTargetRel+keySize; j++)
attrs[created][j] = randomAttrName(created, j);
// create the relation
String relName = randomRelName(created);
rels.add(fac.addRelation(getRelHook(created), relName, attrs[created], false));
// primary key should be set and its size should be 1- 26 April 2014
int [] primaryKeyPos = new int [keySize];
for(int i=0; i<keySize; i++)
primaryKeyPos[i] = i;
fac.addPrimaryKey(relName, primaryKeyPos, false);
//MN should I add it to TargetRel? - 26 April 2014
//m.addTargetRel(rels.get(rels.size()-1));
created++;
numTries = 0;
}
}
}
//MN set attrRemainder and numOfSrcTables - 26 April 2014
numOfSrcTblAttr= (numOfTgtTables * attsPerTargetRel) + keySize;
//MN considering only this case - 26 April 2014
attrRemainder =0;
//MN foreign key should be set - 26 April 2014
//MN should be fixed - 24 June 2014
addFKsNoReuse();
//MN - 13 May 2014
targetReuse = true;
//MN
return true;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"N getTarget();",
"public EntityID nextTarget(Set<StandardEntity> victims) {\n\n// Clustering clustering = this.moduleManager.getModule(SampleModuleKey.AMBULANCE_MODULE_CLUSTERING);\n\n// if (this.clusterIndex == -1) {\n this.clusterIndex = clustering.getClusterIndex(this.agentInfo.getID());\n// }\n\n\n Collection<StandardEntity> elements = clustering.getClusterEntities(this.clusterIndex);\n\n calculateMapCenters(this.clusterIndex, elements);\n\n\n targetsMap.clear();\n\n if (previousTarget != null && !victims.contains(worldInfo.getEntity(previousTarget.getVictimID()))) {\n previousTarget = null;\n }\n\n\n refreshTargetsMap(victims, targetsMap);\n\n calculateDecisionParameters(victims, targetsMap);\n\n calculateVictimsCostValue();\n\n\n AmbulanceTarget bestTarget = null;\n bestTarget = findBestVictim(targetsMap, elements);\n\n //considering inertia for the current target to prevent loop in target selection\n if (previousTarget != null && victims.contains(worldInfo.getEntity(previousTarget.getVictimID()))) {\n if (bestTarget != null && !bestTarget.getVictimID().equals(previousTarget.getVictimID())) {\n Human bestHuman = (Human) worldInfo.getEntity(bestTarget.getVictimID());\n Human previousHuman = (Human) worldInfo.getEntity(previousTarget.getVictimID());\n\n double bestHumanCost = pathPlanning.setFrom(agentInfo.getPosition()).setDestination(bestHuman.getPosition()).calc().getDistance();\n double previousHumanCost = pathPlanning.setFrom(agentInfo.getPosition()).setDestination(previousHuman.getPosition()).calc().getDistance();\n if (previousHumanCost < bestHumanCost) {\n bestTarget = previousTarget;\n }\n }\n }\n\n previousTarget = bestTarget;\n\n if (bestTarget != null) {\n return bestTarget.getVictimID();\n } else {\n return null;\n }\n\n }",
"@Test\r\n\tpublic void testTargetsTwoSteps() {\r\n\t\tboard.calcTargets(10, 1, 2);\r\n\t\tSet<BoardCell> targets= board.getTargets();\r\n\t\tassertEquals(6, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(9, 0)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(11, 2)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(11, 0)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(9, 2)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(12, 1)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(10, 3)));\r\n\t\t\r\n\t\tboard.calcTargets(17, 13, 2);\r\n\t\ttargets= board.getTargets();\r\n\t\tassertEquals(5, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(17, 15)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(18, 14)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(16, 14)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(16, 12)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(15, 13)));\r\n\t}",
"@Test\n\tpublic void testTargetsTwoSteps() {\n\t\tboard.calcTargets(7, 6, 2);\n\t\tSet<BoardCell> targets= board.getTargets();\n\t\tassertEquals(7, targets.size());\n\t\tassertTrue(targets.contains(board.getCellAt(5, 6)));\n\t\tassertTrue(targets.contains(board.getCellAt(6, 7)));\n\t\tassertTrue(targets.contains(board.getCellAt(6, 5)));\n\t\tassertTrue(targets.contains(board.getCellAt(8, 7)));\n\t\tassertTrue(targets.contains(board.getCellAt(8, 5)));\n\t\tassertTrue(targets.contains(board.getCellAt(9, 6)));\n\t\tassertTrue(targets.contains(board.getCellAt(7, 4)));\n\t\tboard.calcTargets(14, 24, 2);\n\t\ttargets= board.getTargets();\n\t\tassertEquals(3, targets.size());\n\t\tassertTrue(targets.contains(board.getCellAt(14, 22)));\n\t\tassertTrue(targets.contains(board.getCellAt(15, 23)));\t\n\t\tassertTrue(targets.contains(board.getCellAt(16, 24)));\t\t\t\n\t}",
"@Test\n\tpublic void testTargetsOneStep() {\n\t\tboard.calcTargets(7, 6, 1);\n\t\tSet<BoardCell> targets= board.getTargets();\n\t\tassertEquals(4, targets.size());\n\t\tassertTrue(targets.contains(board.getCellAt(7, 7)));\n\t\tassertTrue(targets.contains(board.getCellAt(7, 5)));\t\n\t\tassertTrue(targets.contains(board.getCellAt(6, 6)));\t\n\t\tassertTrue(targets.contains(board.getCellAt(8, 6)));\t\n\n\n\t\tboard.calcTargets(14, 24, 1);\n\t\ttargets= board.getTargets();\n\t\tassertEquals(2, targets.size());\n\t\tassertTrue(targets.contains(board.getCellAt(15, 24)));\n\t\tassertTrue(targets.contains(board.getCellAt(14, 23)));\t\t\t\n\t}",
"@Test\r\n\tpublic void testTargets11_2() {\r\n\t\tBoardCell cell = board.getCell(1, 1);\r\n\t\tboard.calcTargets(cell, 2);\r\n\t\tSet<BoardCell> targets = board.getTargets();\r\n\t\tassertTrue(targets != null);\r\n\t\tassertEquals(6, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCell(3, 1)));\r\n\t\tassertTrue(targets.contains(board.getCell(1, 3)));\r\n\t\tassertTrue(targets.contains(board.getCell(2, 2)));\r\n\t\tassertTrue(targets.contains(board.getCell(2, 0)));\r\n\t\tassertTrue(targets.contains(board.getCell(0, 2)));\r\n\t\tassertTrue(targets.contains(board.getCell(0, 0)));\r\n\r\n\t}",
"@Test\n\t\t\tpublic void testTargetsTwoSteps() {\n\t\t\t\t//Length of 2\n\t\t\t\tboard.calcTargets(8, 16, 2);\n\t\t\t\tSet<BoardCell> targets= board.getTargets();\n\t\t\t\tboard.clearTargets();\n\t\t\t\tassertEquals(4, targets.size());\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(6, 16)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(10, 16)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(7, 15)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(9, 15)));\n\t\t\t\t//Length of 2\n\t\t\t\tboard.calcTargets(15, 15, 2);\n\t\t\t\ttargets= board.getTargets();\n\t\t\t\tboard.clearTargets();\n\t\t\t\tassertEquals(4, targets.size());\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(13, 15)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(17, 15)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(14, 16)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(15, 17)));\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t}",
"@Test\r\n\tpublic void testTargetsOneStep() {\r\n\t\tboard.calcTargets(24, 17, 1);\r\n\t\tSet<BoardCell> targets= board.getTargets();\r\n\t\tassertEquals(2, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(23, 17)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(24, 18)));\t\r\n\t\t\r\n\t\tboard.calcTargets(10, 24, 1);\r\n\t\ttargets= board.getTargets();\r\n\t\tassertEquals(2, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(11, 24)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(10, 23)));\t\t\t\r\n\t}",
"@Test\n\t\t\tpublic void testTargetsThreeSteps() {\n\t\t\t\t//Using walkway space that will go near a door with the wrong direction\n\t\t\t\tboard.calcTargets(8, 16, 2);\n\t\t\t\tSet<BoardCell> targets= board.getTargets();\n\t\t\t\tboard.clearTargets();\n\t\t\t\tassertEquals(4, targets.size());\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(6, 16)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(10, 16)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(7, 15)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(9, 15)));\n\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t}",
"@Test\r\n\tpublic void testTargets22_2() {\r\n\t\tBoardCell cell = board.getCell(2, 2);\r\n\t\tboard.calcTargets(cell, 2);\r\n\t\tSet<BoardCell> targets = board.getTargets();\r\n\t\tassertTrue(targets != null);\r\n\t\tassertEquals(6, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCell(0, 2)));\r\n\t\tassertTrue(targets.contains(board.getCell(2, 0)));\r\n\t\tassertTrue(targets.contains(board.getCell(1, 1)));\r\n\t\tassertTrue(targets.contains(board.getCell(3, 1)));\r\n\t\tassertTrue(targets.contains(board.getCell(1, 3)));\r\n\t\tassertTrue(targets.contains(board.getCell(3, 3)));\r\n\r\n\t}",
"protected List<Target> overridableCreateTargetsWithPauses(Relation segs)\r\n {\r\n return HalfPhoneTargetFeatureLister.createTargetsWithPauses(segs);\r\n }",
"public Map<Integer, TargetDef> getTargetQueries();",
"private <T> void getPossibleTargets(TargetingScheme<T> t, TargetList<T> current, List<? extends T> searchSpace, int startInd,\n List<TargetList<T>> outputList) {\n if (t.isFullyTargeted(current)) {\n outputList.add(current);\n return;\n }\n if (startInd >= searchSpace.size()) {\n System.out.println(\"this shouldn't happen lmao\");\n }\n int numToSelect = Math.min(searchSpace.size(), t.getMaxTargets());\n for (int i = startInd; i < searchSpace.size() - (numToSelect - current.targeted.size() - 1); i++) {\n T c = searchSpace.get(i);\n if (!current.targeted.contains(c)) {\n TargetList<T> copy = current.clone();\n copy.targeted.add(c);\n this.getPossibleTargets(t, copy, searchSpace, i + 1, outputList);\n }\n }\n }",
"public InsnTarget[] switchTargets() {\n return targetsOp;\n }",
"@Test\n\tpublic void testTargetsFourSteps() {\n\t\tboard.calcTargets(14, 24, 4);\n\t\tSet<BoardCell> targets= board.getTargets();\n\t\tassertEquals(7, targets.size());\n\t\tassertTrue(targets.contains(board.getCellAt(14, 20)));\n\t\tassertTrue(targets.contains(board.getCellAt(15, 21)));\n\t\tassertTrue(targets.contains(board.getCellAt(16, 22)));\n\t\tassertTrue(targets.contains(board.getCellAt(17, 23)));\t\t\t\n\t\tassertTrue(targets.contains(board.getCellAt(15, 23)));\n\t\tassertTrue(targets.contains(board.getCellAt(16, 24)));\t\t\t\n\t\tassertTrue(targets.contains(board.getCellAt(14, 22)));\n\t}",
"@Test\r\n\tpublic void testTargetsFourSteps() {\r\n\t\tboard.calcTargets(24, 0, 4);\r\n\t\tSet<BoardCell> targets= board.getTargets();\r\n\t\tassertEquals(4, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(24, 4)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(23, 3)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(24, 2)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(23, 1)));\r\n\t\t\r\n\t\tboard.calcTargets(0, 20, 4);\r\n\t\ttargets = board.getTargets();\r\n\t\tassertEquals(4, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(1, 19)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(2, 20)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(3, 19)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(4, 20)));\r\n\t\t\r\n\t\t// Includes a path that doesn't have enough length plus one door\r\n\t\tboard.calcTargets(9, 0, 4);\r\n\t\ttargets= board.getTargets();\r\n\t\tassertEquals(8, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(9, 4)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(9, 2)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(10, 3)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(10, 1)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(11, 2)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(12, 1)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(8, 2)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(11, 0)));\t\r\n\t}",
"Attribute getTarget();",
"public Living getTarget();",
"@Test\n\t\t\tpublic void testTargetsFourSteps() {\n\t\t\t\t//Using random walkway space\n\t\t\t\tboard.calcTargets(5, 18, 3);\n\t\t\t\tSet<BoardCell> targets= board.getTargets();\n\t\t\t\tboard.clearTargets();\n\t\t\t\tassertEquals(10, targets.size());\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(5, 21)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(6, 20)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(4, 20)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(5, 19)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(3, 17)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(6, 16)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(4, 16)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(5, 17)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(4, 18)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(6, 18)));\n\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t}",
"public void makePreferredOTTOLRelationshipsNOConflicts() {\n \n // TraversalDescription CHILDOF_TRAVERSAL = Traversal.description()\n // .relationships(RelType.TAXCHILDOF, Direction.INCOMING);\n \n // get the start point\n Node life = getLifeNode();\n System.out.println(life.getProperty(\"name\"));\n \n Transaction tx = beginTx();\n addToPreferredIndexes(life, ALLTAXA);\n HashSet<Long> traveled = new HashSet<Long>();\n int nNewRels = 0;\n try {\n // walk out to the tips from the base of the tree\n for (Node n : TAXCHILDOF_TRAVERSAL.traverse(life).nodes()) {\n if (n.hasRelationship(Direction.INCOMING, RelType.TAXCHILDOF) == false) {\n \n // when we hit a tip, start walking back\n Node curNode = n;\n while (curNode.hasRelationship(Direction.OUTGOING, RelType.TAXCHILDOF)) {\n Node startNode = curNode;\n if (traveled.contains((Long)startNode.getId())){\n \tbreak;\n }else{\n \ttraveled.add((Long)startNode.getId());\n }\n Node endNode = null;\n \n // if the current node already has a preferred relationship, we will just follow it\n if (startNode.hasRelationship(Direction.OUTGOING, RelType.PREFTAXCHILDOF)) {\n Relationship prefRel = startNode.getSingleRelationship(RelType.PREFTAXCHILDOF, Direction.OUTGOING);\n \n // make sure we don't get stuck in an infinite loop (should not happen, could do weird things to the graph)\n if (prefRel.getStartNode().getId() == prefRel.getEndNode().getId()) {\n System.out.println(\"pointing to itself \" + prefRel + \" \" + prefRel.getStartNode().getId() + \" \" + prefRel.getEndNode().getId());\n break;\n }\n \n // prepare to move on\n endNode = prefRel.getEndNode();\n \n } else {\n \n // if there is no preferred rel then they all point to the same end node; just follow the first non-looping relationship\n for (Relationship rel : curNode.getRelationships(RelType.TAXCHILDOF, Direction.OUTGOING)) {\n if (rel.getStartNode().getId() == rel.getEndNode().getId()) {\n System.out.println(\"pointing to itself \" + rel + \" \" + rel.getStartNode().getId() + \" \" + rel.getEndNode().getId());\n break;\n } else {\n endNode = rel.getEndNode();\n break;\n }\n }\n \n // if we found a dead-end, die\n if (endNode == null) {\n System.out.println(curNode.getProperty(\"name\"));\n System.out.println(\"Strange, this relationship seems to be pointing at a nonexistent node. Quitting.\");\n System.exit(0);\n }\n \n // create preferred relationships\n curNode.createRelationshipTo(endNode, RelType.PREFTAXCHILDOF);\n curNode.createRelationshipTo(endNode, RelType.TAXCHILDOF).setProperty(\"source\", \"ottol\");\n nNewRels += 1;\n }\n \n if (startNode == endNode) {\n System.out.println(startNode);\n System.out.println(\"The node seems to be pointing at itself. This is a problem. Quitting.\");\n System.exit(0);\n \n // prepare for next iteration\n } else {\n curNode = endNode;\n addToPreferredIndexes(startNode, ALLTAXA);\n }\n }\n }\n \n if (nNewRels % transaction_iter == 0) {\n System.out.println(nNewRels);\n // tx.success();\n // tx.finish();\n // tx = beginTx();\n }\n }\n tx.success();\n } finally {\n tx.finish();\n }\n }",
"@Test\r\n\tpublic void testTargetsSixSteps() {\r\n\t\tboard.calcTargets(24, 17, 6);\r\n\t\tSet<BoardCell> targets= board.getTargets();\r\n\t\tassertEquals(8, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCellAt(18, 17)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(20, 17)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(22, 17)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(19, 18)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(21, 18)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(23, 18)));\t\r\n\t\tassertTrue(targets.contains(board.getCellAt(22, 19)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(22, 17)));\r\n\t\t\r\n\t}",
"public TargetReport retrieveBestTarget()\n\t{\n\t\t// get targets...\n\t\tgetTargetReports(allTargets);\n//\t\tSystem.out.println(\"All Targets: \" + allTargets);\n\t\t\n\t\t// and find the best one\n\t\tTargetReport bestTarget = null;\n\t\tdouble bestScore = 0;\n\t\tfor (TargetReport target : allTargets)\n\t\t{\n\t\t\t// Eliminate targets based on range\n\t\t\tdouble targetRange = getRangeToTarget(target);\n\t\t\tif (targetRange > MAX_REASONABLE_RANGE || targetRange < MIN_REASONABLE_RANGE)\n\t\t\t\tcontinue;\n\t\t\t\n\t\t\t// When DRIVERS are lining up, eliminate based on the assumption that the target is aligned.\n\t\t\t// (targetCloseToCenter is set to true during teleop, because we would expect it to be with human drivers)\n\t\t\tif (targetCloseToCenter && Math.abs(target.centerX - IMAGE_WIDTH / 2) > CENTER_ZONE_SIZE)\n\t\t\t\tcontinue;\n\t\t\t\n\t\t\t// add score for distance from throttle-based guess\n\t\t\tguessedRange = MAX_REASONABLE_RANGE*0.5*(-Robot.oi.UtilStick.getThrottle() + 1);\n\t\t\tif (Math.abs(guessedRange) > 0.01)\n\t\t\t{\n\t\t\t\t// give a bunch of weight (see TargetReport) based on closesness to guessedRange\n\t\t\t\ttarget.addScoreFromDistance(guessedRange, targetRange);\n\t\t\t\t\n\t\t\t\t// highly prioritize a target close to a guess (this basically overrides the above line...)\n\t\t\t\tif (Math.abs(guessedRange - targetRange) < GUESS_ACCURACY_TOLERANCE)\n\t\t\t\t{\n\t\t\t\t\tbestTarget = target;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// if a target is better than the best, it's now the best\n\t\t\tif (target.getCumulativeScore() > bestScore)\n\t\t\t{\n\t\t\t\tbestTarget = target;\n\t\t\t\tbestScore = target.getCumulativeScore();\n\t\t\t}\n\t\t}\n\t\tallTargets.clear(); // we thought this might have been taking up too much memory, so we cleared it once we were done with it. (It wasn't the issue)\n\t\t\n\t\t// determine if in launcher range to target and set notification based on this\n\t\tcurrentRangeToBestTarget = getRangeToBestTarget();\n\t\tif (Robot.launcherWheels.inRange(currentRangeToBestTarget))\n\t\t\tRobot.launcherstatus.setInRange();\n\t\telse\n\t\t\tRobot.launcherstatus.setOutOfRange();\n\n\t\t// if we've found one, cache and return it\n\t\t// otherwise, return null (it will just default to the first value of bestTarget)\n\t\tcurrentBestTarget = bestTarget;\n\t\t\n\t\t// ALSO, report bestTarget to Driver station\n//\t\tsendBestTargetReport(); // Didn't work, see below\n\t\t\n// \tSystem.out.println(currentBestTarget);\n\t\t\n\t\treturn bestTarget;\n\t}",
"protected abstract LabelNode[] pickNodes(Estimate predictions, int maxPicks);",
"public Relation setDeepRelation(XDI3Segment contextNodeXri, XDI3Segment arcXri, XDI3Segment targetContextNodeXri);",
"public static List<Target> createTargetsWithPauses(Relation segs) {\r\n List<Target> targets = new ArrayList<Target>();\r\n \r\n boolean first = true;\r\n Item s = segs.getHead();\r\n Voice v = FreeTTSVoices.getMaryVoice(s.getUtterance().getVoice());\r\n String silenceSymbol = v.sampa2voice(\"_\");\r\n Target lastTarget = null;\r\n Item lastItem = s;\r\n for (; s != null; s = s.getNext()) {\r\n Element maryxmlElement = (Element) s.getFeatures().getObject(\"maryxmlElement\");\r\n //create next target\r\n String segName = s.getFeatures().getString(\"name\");\r\n Target nextLeftTarget = new HalfPhoneTarget(segName+\"_L\", maryxmlElement, s, true); \r\n Target nextRightTarget = new HalfPhoneTarget(segName+\"_R\", maryxmlElement, s, false);\r\n //if first target is not a pause, add one\r\n if (first){\r\n first = false;\r\n //if (! segName.equals(silenceSymbol)){\r\n if (! nextLeftTarget.isSilence()){\r\n //System.out.println(\"Adding two pause targets: \"\r\n // +silenceSymbol+\"_L and \"\r\n // +silenceSymbol+\"_R\");\r\n //build new pause item\r\n Item newPauseItem = s.prependItem(null);\r\n newPauseItem.getFeatures().setString(\"name\", silenceSymbol);\r\n \r\n //add new targets for item\r\n targets.add(new HalfPhoneTarget(silenceSymbol+\"_L\", null, newPauseItem, true)); \r\n targets.add(new HalfPhoneTarget(silenceSymbol+\"_R\", null, newPauseItem, false));\r\n }\r\n }\r\n targets.add(nextLeftTarget);\r\n targets.add(nextRightTarget);\r\n lastTarget = nextRightTarget;\r\n lastItem = s;\r\n } \r\n if (! lastTarget.isSilence()){\r\n //System.out.println(\"Adding pause target \"\r\n // +silenceSymbol);\r\n //build new pause item\r\n Item newPauseItem = lastItem.appendItem(null);\r\n newPauseItem.getFeatures().setString(\"name\", silenceSymbol);\r\n \r\n //add new targets for item\r\n targets.add(new HalfPhoneTarget(silenceSymbol+\"_L\", null, newPauseItem, true)); \r\n targets.add(new HalfPhoneTarget(silenceSymbol+\"_R\", null, newPauseItem, false));\r\n }\r\n return targets;\r\n }",
"public Attribute[] getTargetAttributes();",
"private void linkTargets(ISequenceComponent seq) throws Exception {\n\t\tif (seq == null) {\n\t\t\tlogger.create().block(\"linkTargets\").info().level(1).msg(\"Group sequence is null, no targets to link\")\n\t\t\t\t\t.send();\n\t\t\treturn;\n\t\t}\n\t\tif (seq instanceof XIteratorComponent) {\n\t\t\t// extract from each sub-element\n\n\t\t\tXIteratorComponent xit = (XIteratorComponent) seq;\n\t\t\tList list = xit.listChildComponents();\n\t\t\tIterator ic = list.iterator();\n\t\t\twhile (ic.hasNext()) {\n\t\t\t\tISequenceComponent cseq = (ISequenceComponent) ic.next();\n\t\t\t\tlinkTargets(cseq);\n\t\t\t}\n\t\t} else if (seq instanceof XBranchComponent) {\n\t\t\t// there should be no targets in here !\n\n\t\t} else {\n\t\t\t// this is an executive - only check slew and target-select\n\n\t\t\tXExecutiveComponent xec = (XExecutiveComponent) seq;\n\t\t\tIExecutiveAction action = xec.getExecutiveAction();\n\n\t\t\tif (action instanceof ITargetSelector) {\n\t\t\t\tITarget target = ((ITargetSelector) action).getTarget();\n\t\t\t\tif (target == null)\n\t\t\t\t\tthrow new Exception(\"TargetSelector:\" + seq.getComponentName() + \" had null target\");\n\t\t\t\t// link the target to one from table\n\t\t\t\tITarget ctarget = targets.get(target.getID());\n\t\t\t\tif (ctarget == null)\n\t\t\t\t\tthrow new Exception(\"Target: \" + target.getName() + \" is not known\");\n\t\t\t\t((XTargetSelector) action).setTarget(ctarget);\n\n\t\t\t} else if (action instanceof ISlew) {\n\t\t\t\tITarget target = ((ISlew) action).getTarget();\n\t\t\t\tif (target == null)\n\t\t\t\t\tthrow new Exception(\"TargetSelector:\" + seq.getComponentName() + \" had null target\");\n\t\t\t\t// link the target to one from table\n\t\t\t\tITarget ctarget = targets.get(target.getID());\n\t\t\t\tif (ctarget == null)\n\t\t\t\t\tthrow new Exception(\"Target: \" + target.getName() + \" is not known\");\n\t\t\t\t((XSlew) action).setTarget(ctarget);\n\t\t\t}\n\t\t}\n\t}",
"@Test\n\tpublic void targetsTest() {\n\t\tgraph.addVertex(A);\n\t\tgraph.addVertex(B);\n\t\tgraph.addVertex(C);\n\t\tgraph.addVertex(D);\n\t\tList<Vertex> vertices = new ArrayList<>();\n\t\tvertices.add(A);\n\t\tvertices.add(B);\n\t\tedge_0.addVertices(vertices);\n\t\tgraph.addEdge(edge_0);\n\t\tassertTrue(graph.targets(A).keySet().contains(B));\n\t\tassertTrue(graph.targets(A).get(B) == 1);\n\t}",
"@Test\r\n\tpublic void testTargets00_3() {\r\n\t\tBoardCell cell = board.getCell(0, 0);\r\n\t\tboard.calcTargets(cell, 3);\r\n\t\tSet<BoardCell> targets = board.getTargets();\r\n\t\tassertTrue(targets != null);\r\n\t\tassertEquals(6, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCell(0, 3)));\r\n\t\tassertTrue(targets.contains(board.getCell(1, 2)));\r\n\t\tassertTrue(targets.contains(board.getCell(2, 1)));\r\n\t\tassertTrue(targets.contains(board.getCell(3, 0)));\r\n\t\tassertTrue(targets.contains(board.getCell(1, 0)));\r\n\t\tassertTrue(targets.contains(board.getCell(0, 1)));\r\n\t}",
"final int getNextBuildTarget(int difficulty) {\n/* 1970 */ difficulty = Math.min(5, difficulty);\n/* 1971 */ int start = difficulty * 3;\n/* 1972 */ int templateFound = -1;\n/* */ int x;\n/* 1974 */ for (x = start; x < 17; x++) {\n/* */ \n/* 1976 */ if (this.epicTargetItems[x] <= 0L) {\n/* */ \n/* 1978 */ templateFound = x;\n/* */ \n/* */ break;\n/* */ } \n/* */ } \n/* 1983 */ if (templateFound == -1)\n/* */ {\n/* */ \n/* 1986 */ for (x = start; x > 0; x--) {\n/* */ \n/* 1988 */ if (this.epicTargetItems[x] <= 0L) {\n/* */ \n/* 1990 */ templateFound = x;\n/* */ \n/* */ break;\n/* */ } \n/* */ } \n/* */ }\n/* 1996 */ if (templateFound > -1) {\n/* */ \n/* 1998 */ if (templateFound < 3)\n/* 1999 */ return 717; \n/* 2000 */ if (templateFound < 6)\n/* 2001 */ return 714; \n/* 2002 */ if (templateFound < 9)\n/* 2003 */ return 713; \n/* 2004 */ if (templateFound < 12)\n/* 2005 */ return 715; \n/* 2006 */ if (templateFound < 15) {\n/* 2007 */ return 712;\n/* */ }\n/* 2009 */ return 716;\n/* */ } \n/* 2011 */ return -1;\n/* */ }",
"@Test\n\t\t\tpublic void testTargetOneStep()\n\t\t\t{\n\t\t\t\t//Test one step and check for the right space\n\t\t\t\tboard.calcTargets(0, 7, 1);\n\t\t\t\tSet<BoardCell> targets= board.getTargets();\n\t\t\t\tboard.clearTargets();\n\t\t\t\tassertEquals(1, targets.size());\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(1, 7)));\n\n\t\t\t\t// Test one step near a door with the incorrect direction\n\t\t\t\tboard.calcTargets(13, 6, 1);\n\t\t\t\ttargets= board.getTargets();\n\t\t\t\tboard.clearTargets();\n\t\t\t\tassertEquals(3, targets.size());\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(14, 6)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(13, 5)));\n\t\t\t\tassertTrue(targets.contains(board.getCellAt(13, 7)));\n\t\t\t\t\n\t\t\t\t\n\t\t\t}",
"@Test\n\tpublic void testAppliedTargets(){\n\t\ttry{\n\t\t\tchord = new Chord(1, \"4/4\");\n\t\t\tassertEquals(7, chord.getRoot());\n\t\t\tassertEquals(4, chord.getAppliedTarget());\n\n\t\t\tchord = new Chord(1, \"5/5\");\n\t\t\tassertEquals(2, chord.getRoot());\n\t\t\tassertEquals(5, chord.getAppliedTarget());\n\n\t\t\tchord = new Chord(1, \"7/6\");\n\t\t\tassertEquals(5, chord.getRoot());\n\t\t\tassertEquals(6, chord.getAppliedTarget());\n\n\t\t\tchord = new Chord(1, \"4/2\");\n\t\t\tassertEquals(5, chord.getRoot());\n\t\t\tassertEquals(2, chord.getAppliedTarget());\n\n\t\t\tchord = new Chord(6, \"4/7\");\n\t\t\tassertEquals(5, chord.getRoot());\n\t\t\tassertEquals(2, chord.getAppliedTarget());\n\n\t\t\tchord = new Chord(1, \"1\");\n\t\t\tassertEquals(0, chord.getAppliedTarget());\n\t\t}\n\t\tcatch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\tfail(e.getMessage());\n\t\t}\n\t}",
"@Test\r\n\tpublic void testTargets00_2() {\r\n\t\tBoardCell cell = board.getCell(0, 0);\r\n\t\tboard.calcTargets(cell, 2);\r\n\t\tSet<BoardCell> targets = board.getTargets();\r\n\t\tassertTrue(targets != null);\r\n\t\tassertEquals(3, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCell(0, 2)));\r\n\t\tassertTrue(targets.contains(board.getCell(2, 0)));\r\n\t\tassertTrue(targets.contains(board.getCell(1, 1)));\r\n\r\n\t}",
"public OMCollection getTarget() {\r\n return IServer.associationHasTarget().dr(this).range();\r\n }",
"private void setTargetCosts(){\n\t\t//Check which targets that are inside of this building\n\t\tfor(LinkedList<Node> list : targets){\n\t\t\tfor(Node node : list){\n\t\t\t\t//Make a walkable square at the position so that the target is reachable\n\t\t\t\tfor(int k = node.getXPos()-PedestriansSimulator.PEDESTRIAN_RADIUS; k < node.getXPos()+PedestriansSimulator.PEDESTRIAN_RADIUS; k++) {\n\t\t\t\t\tif(Math.round(scaleCollision * k) >= 0 && Math.round(scaleCollision * k) < COLLISION_ROWS){\n\t\t\t\t\t\tfor(int l = node.getYPos()-PedestriansSimulator.PEDESTRIAN_RADIUS; l < node.getYPos()+PedestriansSimulator.PEDESTRIAN_RADIUS; l++) {\n\t\t\t\t\t\t\tif(Math.round(scaleCollision * l) >= 0 && Math.round(scaleCollision * l) < COLLISION_ROWS){\n\t\t\t\t\t\t\t\tcollisionMatrix[Math.round(scaleCollision * k)][Math.round(scaleCollision * l)] = FOOTWAY_COST;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"@Test\n\tpublic void testTargetsIntoRoomShortcut() \n\t{\n\t\tboard.calcTargets(9, 18, 2);\n\t\tSet<BoardCell> targets= board.getTargets();\n\t\tassertEquals(6, targets.size());\n\t\tassertTrue(targets.contains(board.getCellAt(9, 19)));\n\t\tassertTrue(targets.contains(board.getCellAt(10, 19)));\n\t\tassertTrue(targets.contains(board.getCellAt(11, 18)));\n\t\tassertTrue(targets.contains(board.getCellAt(10, 17)));\n\t\tassertTrue(targets.contains(board.getCellAt(8, 17)));\n\t\tassertTrue(targets.contains(board.getCellAt(7, 18)));\n\t}",
"public Relation getDeepRelation(XDI3Segment contextNodeXri, XDI3Segment arcXri, XDI3Segment targetContextNodeXri);",
"private void manageBlueTargets(){\n int randBlueTarget = generator.nextInt(100);\n \n while(labelArray[randBlueTarget].getIcon()!=iconSet.getGrayIcon()){\n randBlueTarget = generator.nextInt(100);\n } \n labelArray[randBlueTarget].setIcon(iconSet.getBlueTargetIcon());\n\n if (blueTargetCounter<ACTIVE_BLUE_TARGET_TOTAL){\n activeBlueTarget[blueTargetCounter] = randBlueTarget;\n }\n\n if (blueTargetCounter>=ACTIVE_BLUE_TARGET_TOTAL){\n if(labelArray[activeBlueTarget[0]].getIcon()!=iconSet.getGrayIcon()){\n labelArray[activeBlueTarget[0]].setIcon(iconSet.getGrayIcon());\n }\n for(int i = 0; i < activeBlueTarget.length-1; i++){\n activeBlueTarget[i] = activeBlueTarget[i+1];\n }\n activeBlueTarget[ACTIVE_BLUE_TARGET_TOTAL-1] = randBlueTarget;\n }\n \n blueTargetCounter++;\n }",
"protected List<Target> createTargets(Relation segs)\r\n {\r\n List<Target> targets = new ArrayList<Target>();\r\n for (Item s = segs.getHead(); s != null; s = s.getNext()) {\r\n Element maryxmlElement = (Element) s.getFeatures().getObject(\"maryxmlElement\");\r\n String segName = s.getFeatures().getString(\"name\");\r\n targets.add(new HalfPhoneTarget(segName+\"_L\", maryxmlElement, s, true)); // left half\r\n targets.add(new HalfPhoneTarget(segName+\"_R\", maryxmlElement, s, false)); // right half\r\n }\r\n return targets;\r\n }",
"public Relation setDeepRelation(XDI3Segment contextNodeXri, XDI3Segment arcXri, ContextNode targetContextNode);",
"private void computeTargetContrib(final int[][] pix) {\n \t\t// NB: Computation could certainly be made more efficient, but this\n \t\t// method is performant enough and hopefully easy to understand.\n \n \t\t// compute minimum scale factor needed for desired image\n \t\t//\n \t\t// TODO: rather than scaling up and comparing... search for maxContrib\n \t\t// directly? Need to robustly convert from maxContrib to the four bin\n \t\t// ranges. Look at various GitHub users to derive the formula.\n \t\t// Can still use the same strategy of looping only once through (y, x),\n \t\t// increasing maxContrib as needed when one of the pixels fails.\n \t\t//\n \t\t// Also should think about what to do if *no* pixel has max value...\n \t\t// for now might be easiest to just document that such is unsupported.\n \t\tint scale = 1;\n \t\tfor (int y = 0; y < CAL_HEIGHT; y++) {\n \t\t\tfor (int x = 0; x < CAL_WIDTH; x++) {\n \t\t\t\tif (contrib[y][x] == null) continue;\n \t\t\t\twhile (contrib[y][x].current > scale(pix[y][x], scale)) {\n \t\t\t\t\tscale++;\n \t\t\t\t}\n \t\t\t}\n \t\t}\n \t\tdebug(\"Scale factor = \" + scale);\n \n \t\t// populate new contribution matrix\n \t\tmaxContrib = scale(0, scale);\n \t\tboolean maxFulfilled = false;\n \t\tfor (int y = 0; y < CAL_HEIGHT; y++) {\n \t\t\tfor (int x = 0; x < CAL_WIDTH; x++) {\n \t\t\t\tif (contrib[y][x] == null) continue;\n \t\t\t\tfinal int target = scale(pix[y][x], scale, maxFulfilled);\n \t\t\t\tif (target == maxContrib) maxFulfilled = true;\n \t\t\t\tcontrib[y][x].target = target;\n \t\t\t}\n \t\t}\n \t}",
"TargetChain createTargetChain();",
"protected void updateTargetEditPart() {\n\t\tsetTargetEditPart(calculateTargetEditPart());\n\t}",
"String getTarget();",
"String getTarget();",
"private WeightedSampler<String> getPossibleActions(int team) {\n if (this.b.getCurrentPlayerTurn() != team || this.b.getWinner() != 0) {\n return null;\n }\n Player p = this.b.getPlayer(team);\n WeightedSampler<String> poss = new WeightedRandomSampler<>();\n // playing cards & selecting targets\n List<Card> hand = p.getHand();\n for (Card c : hand) {\n if (p.canPlayCard(c)) {\n double totalWeight = PLAY_CARD_TOTAL_WEIGHT + PLAY_CARD_COST_WEIGHT_MULTIPLIER * c.finalStats.get(Stat.COST);\n List<List<List<TargetList<?>>>> targetSearchSpace = new LinkedList<>();\n this.getPossibleListTargets(c.getBattlecryTargetingSchemes(), new LinkedList<>(), targetSearchSpace);\n if (targetSearchSpace.isEmpty()) {\n targetSearchSpace.add(List.of());\n }\n if (c instanceof BoardObject) {\n double weightPerPos = totalWeight / (p.getPlayArea().size() + 1);\n // rip my branching factor lol\n for (int playPos = 0; playPos <= p.getPlayArea().size(); playPos++) {\n for (List<List<TargetList<?>>> targets : targetSearchSpace) {\n poss.add(new PlayCardAction(p, c, playPos, targets).toString().intern(), weightPerPos / targetSearchSpace.size());\n }\n }\n } else {\n // spells don't require positioning\n for (List<List<TargetList<?>>> targets : targetSearchSpace) {\n poss.add(new PlayCardAction(p, c, 0, targets).toString().intern(), totalWeight / targetSearchSpace.size());\n }\n }\n }\n }\n this.b.getMinions(team, false, true).forEachOrdered(m -> {\n // unleashing cards & selecting targets\n if (p.canUnleashCard(m)) {\n List<List<List<TargetList<?>>>> targetSearchSpace = new LinkedList<>();\n this.getPossibleListTargets(m.getUnleashTargetingSchemes(), new LinkedList<>(), targetSearchSpace);\n if (targetSearchSpace.isEmpty()) {\n targetSearchSpace.add(List.of());\n }\n for (List<List<TargetList<?>>> targets : targetSearchSpace) {\n poss.add(new UnleashMinionAction(p, m, targets).toString().intern(), UNLEASH_TOTAL_WEIGHT / targetSearchSpace.size());\n }\n }\n // minion attack\n if (m.canAttack()) {\n double totalWeight = ATTACK_TOTAL_WEIGHT + ATTACK_WEIGHT_MULTIPLIER * m.finalStats.get(Stat.ATTACK);\n double weight = totalWeight / m.getAttackableTargets().count();\n m.getAttackableTargets().forEachOrdered(target -> {\n double bonus = target instanceof Leader ? ATTACK_TARGET_LEADER_MULTIPLIER : 1;\n double overkillMultiplier = Math.pow(ATTACK_WEIGHT_OVERKILL_PENALTY, Math.max(0, m.finalStats.get(Stat.ATTACK) - target.health));\n poss.add(new OrderAttackAction(m, target).toString().intern(), overkillMultiplier * bonus * weight);\n });\n }\n });\n // ending turn\n poss.add(new EndTurnAction(team).toString().intern(), END_TURN_WEIGHT);\n return poss;\n }",
"EValidTargetTypes getTargets();",
"@Test\r\n\tpublic void testTargets33_1() {\r\n\t\tBoardCell cell = board.getCell(3, 3);\r\n\t\tboard.calcTargets(cell, 1);\r\n\t\tSet<BoardCell> targets = board.getTargets();\r\n\t\tassertTrue(targets != null);\r\n\t\tassertEquals(2, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCell(2, 3)));\r\n\t\tassertTrue(targets.contains(board.getCell(3, 2)));\r\n\r\n\t}",
"public Relation setRelation(XDI3Segment arcXri, XDI3Segment targetContextNodeXri);",
"@Test\n public void test_chooseBadTargetOnSacrifice_WithTargets_User() {\n // Redcap Melee deals 4 damage to target creature or planeswalker. If a nonred permanent is dealt damage this way, you sacrifice a land.\n addCard(Zone.HAND, playerA, \"Redcap Melee\", 1);\n addCard(Zone.BATTLEFIELD, playerA, \"Mountain\", 3);\n //\n addCard(Zone.BATTLEFIELD, playerB, \"Silvercoat Lion\", 1);\n\n castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, \"Redcap Melee\", \"Silvercoat Lion\");\n addTarget(playerA, \"Mountain\");\n\n setStrictChooseMode(true);\n setStopAt(1, PhaseStep.END_TURN);\n execute();\n\n assertGraveyardCount(playerA, \"Redcap Melee\", 1);\n assertGraveyardCount(playerA, \"Mountain\", 1);\n assertPermanentCount(playerA, \"Mountain\", 3 - 1);\n assertGraveyardCount(playerB, \"Silvercoat Lion\", 1);\n }",
"java.lang.String getTarget();",
"java.lang.String getTarget();",
"public IdentifierListNode getTargets()throws ClassCastException;",
"public void remTarget(){\n rem(DmpDMSAG.__target);\n }",
"@Test\r\n\tpublic void testTargets00_1() {\r\n\t\tBoardCell cell = board.getCell(0, 0);\r\n\t\tboard.calcTargets(cell, 1);\r\n\t\tSet<BoardCell> targets = board.getTargets();\r\n\t\tassertTrue(targets != null);\r\n\t\tassertEquals(2, targets.size());\r\n\t\tassertTrue(targets.contains(board.getCell(0, 1)));\r\n\t\tassertTrue(targets.contains(board.getCell(1, 0)));\r\n\r\n\t}",
"private final long getRandomTarget(int attempts, int targetTemplate, @Nullable ArrayList<Long> itemList) {\n/* 1746 */ long itemFound = -1L;\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1751 */ if (Servers.localServer.PVPSERVER) {\n/* */ \n/* 1753 */ int numsExisting = 0;\n/* */ int x;\n/* 1755 */ for (x = 0; x < 17; x++) {\n/* */ \n/* 1757 */ if (this.epicTargetItems[x] > 0L)\n/* 1758 */ numsExisting++; \n/* */ } \n/* 1760 */ if (numsExisting > 0)\n/* */ {\n/* */ \n/* 1763 */ for (x = 0; x < 17; x++) {\n/* */ \n/* 1765 */ if (this.epicTargetItems[x] > 0L) {\n/* */ \n/* */ try {\n/* */ \n/* 1769 */ Item eti = Items.getItem(this.epicTargetItems[x]);\n/* 1770 */ Village v = Villages.getVillage(eti.getTilePos(), eti.isOnSurface());\n/* */ \n/* */ \n/* */ \n/* 1774 */ if (v == null) {\n/* */ \n/* 1776 */ if (itemFound == -1L) {\n/* 1777 */ itemFound = this.epicTargetItems[x];\n/* 1778 */ } else if (Server.rand.nextInt(numsExisting) == 0) {\n/* 1779 */ itemFound = this.epicTargetItems[x];\n/* */ } \n/* */ } else {\n/* */ \n/* 1783 */ logger.info(\"Disqualified Epic Mission Target item due to being in village \" + v.getName() + \": Name: \" + eti\n/* 1784 */ .getName() + \" | WurmID: \" + eti.getWurmId() + \" | TileX: \" + eti.getTileX() + \" | TileY: \" + eti\n/* 1785 */ .getTileY());\n/* */ \n/* */ }\n/* */ \n/* */ \n/* */ }\n/* 1791 */ catch (NoSuchItemException nsie) {\n/* */ \n/* 1793 */ logger.warning(\"Epic mission item could not be found when loaded, maybe it was wrongfully deleted? WurmID:\" + this.epicTargetItems[x] + \". \" + nsie);\n/* */ } \n/* */ }\n/* */ } \n/* */ }\n/* */ } else {\n/* */ int templateId;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1807 */ if (logger.isLoggable(Level.FINE)) {\n/* 1808 */ logger.fine(\"Entering Freedom Version of Valrei Mission Target Structure selection.\");\n/* */ }\n/* 1810 */ Connection dbcon = null;\n/* 1811 */ PreparedStatement ps1 = null;\n/* 1812 */ ResultSet rs = null;\n/* */ \n/* 1814 */ int structureType = Server.rand.nextInt(6);\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1820 */ if (targetTemplate > 0) {\n/* */ \n/* 1822 */ templateId = targetTemplate;\n/* */ }\n/* */ else {\n/* */ \n/* 1826 */ switch (structureType) {\n/* */ \n/* */ case 0:\n/* 1829 */ templateId = 717;\n/* */ break;\n/* */ case 1:\n/* 1832 */ templateId = 714;\n/* */ break;\n/* */ case 2:\n/* 1835 */ templateId = 713;\n/* */ break;\n/* */ case 3:\n/* 1838 */ templateId = 715;\n/* */ break;\n/* */ case 4:\n/* 1841 */ templateId = 712;\n/* */ break;\n/* */ case 5:\n/* 1844 */ templateId = 716;\n/* */ break;\n/* */ default:\n/* 1847 */ templateId = 713;\n/* */ break;\n/* */ } \n/* */ \n/* */ \n/* */ } \n/* 1853 */ if (logger.isLoggable(Level.FINE)) {\n/* 1854 */ logger.fine(\"Selected template with id=\" + templateId);\n/* */ }\n/* 1856 */ if (itemList == null) {\n/* */ \n/* 1858 */ itemList = new ArrayList<>();\n/* */ \n/* */ \n/* */ try {\n/* 1862 */ String dbQueryString = \"SELECT WURMID FROM ITEMS WHERE TEMPLATEID=?\";\n/* */ \n/* 1864 */ if (logger.isLoggable(Level.FINER)) {\n/* 1865 */ logger.finer(\"Query String [ SELECT WURMID FROM ITEMS WHERE TEMPLATEID=? ]\");\n/* */ }\n/* 1867 */ dbcon = DbConnector.getItemDbCon();\n/* 1868 */ ps1 = dbcon.prepareStatement(\"SELECT WURMID FROM ITEMS WHERE TEMPLATEID=?\");\n/* 1869 */ ps1.setInt(1, templateId);\n/* 1870 */ rs = ps1.executeQuery();\n/* */ \n/* 1872 */ while (rs.next())\n/* */ {\n/* 1874 */ long currentLong = rs.getLong(\"WURMID\");\n/* 1875 */ if (currentLong > 0L)\n/* */ {\n/* 1877 */ itemList.add(Long.valueOf(currentLong));\n/* */ }\n/* 1879 */ if (logger.isLoggable(Level.FINEST)) {\n/* 1880 */ logger.finest(rs.toString());\n/* */ }\n/* */ }\n/* */ \n/* 1884 */ } catch (SQLException ex) {\n/* */ \n/* 1886 */ logger.log(Level.WARNING, \"Failed to locate mission items with templateid=\" + templateId, ex);\n/* */ }\n/* */ finally {\n/* */ \n/* 1890 */ DbUtilities.closeDatabaseObjects(ps1, null);\n/* 1891 */ DbConnector.returnConnection(dbcon);\n/* */ } \n/* */ } \n/* */ \n/* */ \n/* 1896 */ if (itemList.size() > 0) {\n/* */ \n/* 1898 */ int randomIndex = Server.rand.nextInt(itemList.size());\n/* */ \n/* 1900 */ if (itemList.get(randomIndex) != null)\n/* */ {\n/* */ \n/* 1903 */ long selectedTarget = ((Long)itemList.get(randomIndex)).longValue();\n/* */ \n/* */ \n/* */ try {\n/* 1907 */ Item eti = Items.getItem(selectedTarget);\n/* 1908 */ Village v = Villages.getVillage(eti.getTilePos(), eti.isOnSurface());\n/* */ \n/* */ \n/* */ \n/* 1912 */ if (v == null) {\n/* */ \n/* 1914 */ logger.info(\"Selected mission target with wurmid=\" + selectedTarget);\n/* 1915 */ return selectedTarget;\n/* */ } \n/* */ \n/* */ \n/* 1919 */ logger.info(\"Disqualified Epic Mission Target item due to being in village \" + v.getName() + \": Name: \" + eti\n/* 1920 */ .getName() + \" | WurmID: \" + eti.getWurmId() + \" | TileX: \" + eti.getTileX() + \" | TileY: \" + eti\n/* 1921 */ .getTileY());\n/* */ \n/* */ \n/* 1924 */ int ATTEMPT_NUMBER_OF_TIMES = 25;\n/* */ \n/* 1926 */ if (attempts < 25) {\n/* */ \n/* 1928 */ logger.fine(\"Failing roll number \" + attempts + \"/\" + '\\031' + \" and trying again.\");\n/* 1929 */ return getRandomTarget(attempts + 1, templateId, itemList);\n/* */ } \n/* */ \n/* */ \n/* 1933 */ logger.info(\"Failing roll of finding structure with templateID=\" + templateId + \" completely, could not find any mission structure not in a village in \" + '\\031' + \" tries.\");\n/* */ \n/* 1935 */ return -1L;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ }\n/* 1943 */ catch (NoSuchItemException noSuchItemException) {}\n/* */ \n/* */ \n/* */ }\n/* */ else\n/* */ {\n/* */ \n/* */ \n/* 1951 */ logger.warning(\"WURMID was null for item with templateId=\" + templateId);\n/* 1952 */ return -1L;\n/* */ }\n/* */ \n/* */ }\n/* */ else {\n/* */ \n/* 1958 */ logger.info(\"Couldn't find any items with itemtemplate=\" + templateId + \" failing, the roll.\");\n/* 1959 */ return -1L;\n/* */ } \n/* */ } \n/* */ \n/* */ \n/* 1964 */ return itemFound;\n/* */ }",
"public void setTargeted() {\n targeted ++;\n }",
"private void updateSingles(Hierarchy con, ViolatedCandidate lCandidate, ViolatedCandidate tCandidate,\n double delta) {\n Multiset<Constraint> targetPreferringView = UpdateUtils.getViolatedByLearner(lCandidate, tCandidate);\n Multiset<Constraint> learnerPreferringView = UpdateUtils.getViolatedByTarget(lCandidate, tCandidate);\n Multiset<Constraint> learnerPreferringHigh = HashMultiset.create(learnerPreferringView.size());\n double promoteWeightedDelta = delta / targetPreferringView.size();\n double maxTPreferringRanking = Double.MIN_VALUE;\n for (Constraint constraint : targetPreferringView.elementSet()) {\n maxTPreferringRanking = Math.max(maxTPreferringRanking, con.getRanking(constraint));\n double multipliedDelta = (targetPreferringView.count(constraint) * promoteWeightedDelta);\n con.changeConstraintRanking(constraint, multipliedDelta);\n }\n\n for (Constraint constraint : learnerPreferringView.elementSet()) {\n double thisRanking = con.getRanking(constraint);\n if (thisRanking > maxTPreferringRanking) {\n int count = learnerPreferringView.count(constraint);\n learnerPreferringHigh.add(constraint, count);\n }\n }\n // If 'higher' set is empty, just add argMax to it\n if (learnerPreferringHigh.isEmpty()) {\n Constraint argMax = UpdateUtils.getMax(learnerPreferringView, con);\n learnerPreferringHigh.add(argMax);\n }\n\n Multiset<Constraint> toIterateOver = learnerPreferringHigh;\n\n double demoteWeightedDelta = -(delta / toIterateOver.size());\n for (Constraint constraint : toIterateOver.elementSet()) {\n double multipliedDelta = toIterateOver.count(constraint) * demoteWeightedDelta;\n con.changeConstraintRanking(constraint, multipliedDelta);\n // System.out.println(\"↓ Updating \" + constraint +\" by \" +\n // multipliedDelta);\n }\n }",
"private TargetsDescriptor setTargetsDescriptor(TargetsDescriptor td) {\n\t\tTargetsDescriptor previous = getTargetsDescriptor();\r\n\t\t_targetsDescriptor = td;\r\n\t\treturn previous;\r\n\t}",
"Object getTarget();",
"Object getTarget();",
"public Relation getRelation(XDI3Segment arcXri, XDI3Segment targetContextNodeXri);",
"private void manageGreenTargets(){\n int randGreenTarget = generator.nextInt(100);\n \n while(labelArray[randGreenTarget].getIcon()!=iconSet.getGrayIcon()){\n randGreenTarget = generator.nextInt(100);\n } \n labelArray[randGreenTarget].setIcon(iconSet.getGreenTargetIcon());\n\n if (greenTargetCounter<ACTIVE_GREEN_TARGET_TOTAL){\n activeGreenTarget[greenTargetCounter] = randGreenTarget;\n }\n\n if (greenTargetCounter>=ACTIVE_GREEN_TARGET_TOTAL){\n if(labelArray[activeGreenTarget[0]].getIcon()!=iconSet.getGrayIcon()){\n labelArray[activeGreenTarget[0]].setIcon(iconSet.getGrayIcon());\n }\n for(int i = 0; i < activeGreenTarget.length-1; i++){\n activeGreenTarget[i] = activeGreenTarget[i+1];\n }\n activeGreenTarget[ACTIVE_GREEN_TARGET_TOTAL-1] = randGreenTarget;\n }\n \n greenTargetCounter++;\n }",
"private boolean testTargetSemanticGroup( Edge edge, Set<String> sourceAliases, List<String> types ) {\n\t\t\n\t\tNode subject = edge.getSubject();\n\t\tString subjectId = translator.makeId( subject );\n\n\t\tNode object = edge.getObject();\n\t\tString objectId = translator.makeId( object );\n\t\t\n\t\tif( sourceAliases.contains(subjectId) ) \n\t\t\treturn types.contains(translator.inferConceptCategory(object));\n\t\t\t\n\t\t else if( sourceAliases.contains(objectId) )\n\t\t\treturn types.contains(translator.inferConceptCategory(subject));\n \n\t\t// Strange situation... one of the two id's should match a source alias!\n\t\t_logger.warn(\"ControllerImpl.testTargetSemanticGroup(): strange!... neither subject id '\"+subjectId+\n\t\t\t\t \"' nor object id '\"+objectId+\"' found in source alias list '\"+String.join(\",\", sourceAliases)+\"'?\");\n\t\treturn false;\n\n\t}",
"private static Set<Relation> cutRelationDifferences(Wmm targetWmm, Wmm baselineWmm) {\n // TODO: Add support to move flagged axioms to the baselineWmm\n Set<Relation> cutRelations = new HashSet<>();\n Set<Relation> cutCandidates = new HashSet<>();\n int cutCounter = 0;\n targetWmm.getAxioms().stream().filter(ax -> !ax.isFlagged())\n .forEach(ax -> collectDependencies(ax.getRelation(), cutCandidates));\n for (Relation rel : cutCandidates) {\n if (rel.getDefinition() instanceof Difference) {\n Relation sec = ((Difference) rel.getDefinition()).complement;\n if (!sec.getDependencies().isEmpty() || sec.getDefinition() instanceof Identity\n || sec.getDefinition() instanceof CartesianProduct) {\n // NOTE: The check for RelSetIdentity/RelCartesian is needed because they appear\n // non-derived in our Wmm but for CAAT they are derived from unary predicates!\n logger.info(\"Found difference {}. Cutting rhs relation {}\", rel, sec);\n cutRelations.add(sec);\n Relation baselineCopy = getCopyOfRelation(sec, baselineWmm);\n baselineWmm.addConstraint(new ForceEncodeAxiom(baselineCopy));\n // We give the cut relations new aliases in the original and the baseline wmm\n // so that we can match them later by name.\n targetWmm.addAlias(\"cut#\" + cutCounter, sec);\n baselineWmm.addAlias(\"cut#\" + cutCounter, baselineCopy);\n cutCounter++;\n }\n }\n }\n return cutRelations;\n }",
"ImmutableSet<BuildTarget> getAdditionalCoverageTargets();",
"State getTarget();",
"@Override\n public void acceptTargets(Set<String> myTargets, Set<String> otherTargets) {\n \n }",
"void setUpRefs(GElement target) {\n\t\t if(target.isDataGenerator()){\n\t\t\t setDg((GDataGenerator)target);\n\t\t } \n\t }",
"Entity determinePriorityTarget();",
"Ontology getTargetOntology();",
"List<String> getTargetClassifications(Observation obs);",
"private CFGNode findTarget(String target, ArrayList<CFGNode> nodes) {\n for (CFGNode n: nodes) {\n if (n.block.label != null && n.block.label.trim().equals(target.trim())) {\n return n;\n }\n }\n\n return null;\n }",
"@Test\n public void test_chooseBadTargetOnSacrifice_WithTargets_AI() {\n addCard(Zone.HAND, playerA, \"Redcap Melee\", 1);\n addCard(Zone.BATTLEFIELD, playerA, \"Mountain\", 3);\n //\n addCard(Zone.BATTLEFIELD, playerB, \"Silvercoat Lion\", 1);\n\n castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, \"Redcap Melee\", \"Silvercoat Lion\");\n //addTarget(playerA, \"Mountain\"); AI must select targets\n\n //setStrictChooseMode(true); AI must select targets\n setStopAt(1, PhaseStep.END_TURN);\n execute();\n\n assertGraveyardCount(playerA, \"Redcap Melee\", 1);\n assertGraveyardCount(playerA, \"Mountain\", 1);\n assertPermanentCount(playerA, \"Mountain\", 3 - 1);\n assertGraveyardCount(playerB, \"Silvercoat Lion\", 1);\n }",
"Object getTargetexists();",
"@Override\n public List<GraphRelationship> getRelationships() {\n int localMax=1;\n Hashtable checkIfRelationExists = new Hashtable();\n List<GraphRelationship> relatonships = new ArrayList<>();\n List<String> filePaths = ProjectFileNamesUtil.getFileNamesFromProject(project.getBaseDir());\n for (String filePath : filePaths){ //foreach filepath - node name\n String str[] = filePath.split(\"/\");\n String name = str[str.length-1];\n CoverageNode startNode = (CoverageNode) nodeHashTable.get(name); //relations from this node\n ImportFileUtil importFileUtil = (ImportFileUtil) relations.get(name); //get relations for node\n if (importFileUtil != null && startNode != null){\n for (ImportFrom importFrom : importFileUtil.getImportFromList()) //for each relation\n {\n NodeRelationship relation;\n CoverageNode endNode = (CoverageNode) nodeHashTable.get(importFrom.getName());//end node of relation\n String nameOfRelation = startNode.getId() + \"->\" + endNode.getId();\n if (checkIfRelationExists.get(nameOfRelation) != null){\n continue;\n }\n relation = new NodeRelationship(nameOfRelation);\n relation.setWeight(getRelationWeight(importFrom));\n if (localMax < getRelationWeight(importFrom)){localMax=getRelationWeight(importFrom);} //localMax of weights for proper logScale\n relation.setCallsCount(\"\" + (int) relation.getWeight());\n relation.setStartNode(startNode);\n relation.setEndNode(endNode);\n setRelationTypes(relation.getTypes(),relation.getWeight()); //sets trivia\n HashMap<String, Object> properties = new HashMap<>();\n getPropertiesForRelations(properties, importFrom);\n ResultsPropertyContainer resultsPropertyContainer = new ResultsPropertyContainer(properties);\n relation.setPropertyContainer(resultsPropertyContainer);\n checkIfRelationExists.put(relation.getId(), relation);\n relatonships.add(relation);\n }\n }\n }\n for(GraphRelationship relationship : relatonships){\n relationship.setWeight(normalizeWeight(relationship.getWeight(), localMax));\n }\n return relatonships;\n }",
"@Override public Map<L, Integer> targets(L source) {\r\n \t Map<L, Integer> res= new HashMap <L, Integer>();\r\n \tif(!vertices.contains(source)) {\r\n \t\t//System.out.println(source+\" is not in the graph!\");\r\n \t\treturn res;\r\n \t}\r\n \tIterator<Edge<L>> iter=edges.iterator();\r\n \twhile(iter.hasNext()) {\r\n \t\tEdge<L> tmp=iter.next();\r\n \t\t//if(tmp.getSource()==source)\r\n \t\tif(tmp.getSource().equals(source))\r\n \t\t\tres.put(tmp.getTarget(), tmp.getWeight());\r\n \t\t\r\n \t}\r\n \tcheckRep();\r\n \treturn res;\r\n\r\n }",
"@Override\r\n public Set<List<String>> findAllPaths(int sourceId, int targetId, int reachability) {\r\n //all paths found\r\n Set<List<String>> allPaths = new HashSet<List<String>>();\r\n //collects path in one iteration\r\n Set<List<String>> newPathsCollector = new HashSet<List<String>>();\r\n //same as the solution but with inverted edges\r\n Set<List<String>> tmpPathsToTarget = new HashSet<List<String>>();\r\n //final solution\r\n Set<List<String>> pathsToTarget = new HashSet<List<String>>();\r\n \r\n String[] statementTokens = null; \r\n Set<Integer> allProcessedNodes = new HashSet<Integer>(); //to avoid duplicates\r\n List<String> statementsFound = new ArrayList<String>();\r\n \r\n for (int i = 0; i < reachability; i++) {\r\n if (i == 0) { \r\n Collection<String> inEdges = jungCompleteGraph.getInEdges(sourceId);\r\n for (String inEdge: inEdges) {\r\n \r\n statementsFound = new ArrayList<String>();\r\n statementTokens = inEdge.split(\"->\");\r\n int inNodeId = Integer.parseInt(statementTokens[0]);\r\n //allProcessedNodes.add(inNodeId); \r\n //Incoming nodes are reversed\r\n statementsFound.add(new StringBuilder(inEdge).reverse().toString());\r\n allPaths.add(statementsFound);\r\n if (inNodeId == targetId) tmpPathsToTarget.add(statementsFound);\r\n }\r\n \r\n Collection<String> outEdges = jungCompleteGraph.getOutEdges(sourceId);\r\n \r\n for (String outEdge: outEdges) {\r\n \r\n statementsFound = new ArrayList<String>();\r\n statementTokens = outEdge.split(\"->\");\r\n int outNodeId = Integer.parseInt(statementTokens[2]);\r\n statementsFound.add(outEdge);\r\n allPaths.add(statementsFound);\r\n if (outNodeId == targetId) tmpPathsToTarget.add(statementsFound);\r\n \r\n }\r\n \r\n } else {\r\n newPathsCollector = new HashSet<List<String>>();\r\n\r\n for (List<String> statements: allPaths) {\r\n allProcessedNodes = new HashSet<Integer>(); //to avoid duplicates\r\n int lastNodeInPath = 0;\r\n \r\n for (String predicate: statements) {\r\n if (predicate.contains(\">-\")) {\r\n statementTokens = predicate.split(\">-\");\r\n allProcessedNodes.add(Integer.parseInt(\r\n new StringBuilder(statementTokens[0]).reverse().toString()));\r\n allProcessedNodes.add(Integer.parseInt(\r\n new StringBuilder(statementTokens[2]).reverse().toString()));\r\n lastNodeInPath = Integer.parseInt(\r\n new StringBuilder(statementTokens[2]).reverse().toString());\r\n } else {\r\n statementTokens = predicate.split(\"->\"); \r\n allProcessedNodes.add(Integer.parseInt(statementTokens[0]));\r\n allProcessedNodes.add(Integer.parseInt(statementTokens[2]));\r\n lastNodeInPath = Integer.parseInt(statementTokens[2]);\r\n }\r\n }\r\n \r\n Collection<String> inEdges = jungCompleteGraph.getInEdges(lastNodeInPath);\r\n for (String inEdge: inEdges) {\r\n \r\n statementsFound = new ArrayList<String>();\r\n statementsFound.addAll(statements);\r\n statementTokens = inEdge.split(\"->\");\r\n int inNodeId = Integer.parseInt(statementTokens[0]);\r\n if (allProcessedNodes.contains(inNodeId)) continue;\r\n \r\n //Incoming nodes are reversed \r\n statementsFound.add(new StringBuilder(inEdge).reverse().toString());\r\n newPathsCollector.add(statementsFound);\r\n if (inNodeId == targetId) tmpPathsToTarget.add(statementsFound);\r\n \r\n }\r\n \r\n Collection<String> outEdges = jungCompleteGraph.getOutEdges(lastNodeInPath);\r\n for (String outEdge: outEdges) {\r\n \r\n statementsFound = new ArrayList<String>();\r\n statementsFound.addAll(statements);\r\n statementTokens = outEdge.split(\"->\");\r\n int outNodeId = Integer.parseInt(statementTokens[2]);\r\n if (allProcessedNodes.contains(outNodeId)) continue;\r\n \r\n //Incoming nodes are reversed \r\n statementsFound.add(outEdge);\r\n newPathsCollector.add(statementsFound);\r\n if (outNodeId == targetId) tmpPathsToTarget.add(statementsFound);\r\n }\r\n }\r\n allPaths.addAll(newPathsCollector);\r\n }\r\n \r\n //System.out.println(\"*****End of iteration \" + i);\r\n //System.out.println(\"#SIZE OF allPaths: \" + allPaths.size());\r\n int numItems = 0;\r\n for (List<String> currList: allPaths) {\r\n numItems = numItems + currList.size();\r\n }\r\n //System.out.println(\"#NUMBER OF ELEMS OF ALL LISTS: \" + numItems);\r\n //System.out.println(\"#SIZE OF tmpPathsToTarget : \" + tmpPathsToTarget.size());\r\n }\r\n \r\n //We need to reverse back all the predicates\r\n for (List<String> statements: tmpPathsToTarget) { \r\n List<String> fixedStatements = new ArrayList<String>(); \r\n for (int i = 0; i < statements.size(); i++) { \r\n String statement = statements.get(i); \r\n if (statement.contains(\">-\")) {\r\n fixedStatements.add(new StringBuilder(statement).reverse().toString());\r\n } else {\r\n fixedStatements.add(statement);\r\n } \r\n }\r\n pathsToTarget.add(fixedStatements);\r\n }\r\n return pathsToTarget;\r\n }",
"public boolean definesTargetAttribute(int idx);",
"public TargetCollection(TargetCollection targetCollection){\n targets = targetCollection.getTargets();\n }",
"public void setTarget(TestSetDiscrepancyReportResourceTarget target) {\n this.target = target;\n }",
"@Test\r\n\tpublic void testTargetsIntoRoomShortcut() \r\n\t{\r\n\t\tboard.calcTargets(11, 24, 3);\r\n\t\tSet<BoardCell> targets= board.getTargets();\r\n\t\tassertEquals(6, targets.size());\r\n\t\t//up and then left\r\n\t\tassertTrue(targets.contains(board.getCellAt(10, 22)));\r\n\t\t//up left down\r\n\t\tassertTrue(targets.contains(board.getCellAt(11, 23)));\r\n\t\t//left up right\r\n\t\tassertTrue(targets.contains(board.getCellAt(10, 24)));\r\n\t\t//left only\r\n\t\tassertTrue(targets.contains(board.getCellAt(11, 21)));\r\n\t\t// into the rooms\r\n\t\tassertTrue(targets.contains(board.getCellAt(12, 23)));\r\n\t\tassertTrue(targets.contains(board.getCellAt(12, 22)));\t\t\t\r\n\t}",
"@Override\n protected abstract Regressor[] getLearnerSetups();",
"TrgPlace getTarget();",
"@Test \n\tpublic void testTargetsIntoRoom()\n\t{\n\t\t// One room is exactly 2 away\n\t\tboard.calcTargets(5, 24, 2);\n\t\tSet<BoardCell> targets= board.getTargets();\n\t\tassertEquals(4, targets.size());\n\t\tassertTrue(targets.contains(board.getCellAt(3, 24)));\n\t\tassertTrue(targets.contains(board.getCellAt(6, 23)));\n\t\tassertTrue(targets.contains(board.getCellAt(5, 22)));\n\t\tassertTrue(targets.contains(board.getCellAt(4, 23)));\n\t}",
"Target target();",
"public TargetModuleID[] getResultTargetModuleIDs();",
"@Test\n \tpublic void testTargetRandomSelection() {\n \tComputerPlayer player = new ComputerPlayer();\n \t// Pick a location with no rooms in target, just three targets\n \tboard.calcTargets(23, 7, 2);\n \tint loc_24_8Tot = 0;\n \tint loc_22_8Tot = 0;\n \tint loc_21_7Tot = 0;\n \t// Run the test 100 times\n \tfor (int i=0; i<100; i++) {\n \t\tBoardCell selected = player.pickLocation(board.getTargets());\n \t\tif (selected == board.getRoomCellAt(24, 8))\n \t\t\tloc_24_8Tot++;\n \t\telse if (selected == board.getRoomCellAt(22, 8))\n \t\t\tloc_22_8Tot++;\n \t\telse if (selected == board.getRoomCellAt(21, 7))\n \t\t\tloc_21_7Tot++;\n \t\telse\n \t\t\tfail(\"Invalid target selected\");\n \t}\n \t// Ensure we have 100 total selections (fail should also ensure)\n \tassertEquals(100, loc_24_8Tot + loc_22_8Tot + loc_21_7Tot);\n \t// Ensure each target was selected more than once\n \tassertTrue(loc_24_8Tot > 10);\n \tassertTrue(loc_22_8Tot > 10);\n \tassertTrue(loc_21_7Tot > 10);\t\t\t\t\t\t\t\n }",
"public Set<GrouperProvisioningTarget> getViewableTargets() {\r\n \r\n GrouperObject grouperObject = null;\r\n \r\n GuiGroup guiGroup = GrouperRequestContainer.retrieveFromRequestOrCreate().getGroupContainer().getGuiGroup();\r\n GuiStem guiStem = GrouperRequestContainer.retrieveFromRequestOrCreate().getStemContainer().getGuiStem();\r\n \r\n if (guiGroup != null) {\r\n grouperObject = guiGroup.getGrouperObject();\r\n }\r\n if (guiStem != null) {\r\n grouperObject = guiStem.getGrouperObject();\r\n }\r\n \r\n Map<String, GrouperProvisioningTarget> targets = GrouperProvisioningSettings.getTargets(true);\r\n Subject loggedInSubject = GrouperUiFilter.retrieveSubjectLoggedIn();\r\n \r\n Set<GrouperProvisioningTarget> viewableTargets = new HashSet<GrouperProvisioningTarget>();\r\n \r\n for (GrouperProvisioningTarget target: targets.values()) {\r\n if (GrouperProvisioningService.isTargetViewable(target, loggedInSubject, grouperObject)) {\r\n viewableTargets.add(target);\r\n }\r\n }\r\n \r\n return viewableTargets;\r\n }",
"private void intelligentDecideMove() {\n\t\tMonster target=nearestEnemy();\r\n\t\tif(target!=null){\t\t\t\t//FIRST PRIORITY: pursue the target if it can be seen.\r\n\t\t\tswitchStates(PURSUIT);\r\n\t\t\ttargetTile=new Tile(target.currentTile);\r\n\t\t\t//saveMove();\r\n\t\t\tmonster.moveTowards(target);\r\n\t\t}\r\n\t\t\t\r\n\t\telse{\r\n\t\t\ttargetLostResponse();\r\n\t\t\t}\r\n\t}",
"private Target getMatchingTarget(Element targetElement)\n {\n String targetName = targetElement.getAttribute(\"name\").getValue();\n\n for (Target target : targets)\n {\n String label = target.getName();\n\n if (label.equals(targetName))\n {\n return target;\n }\n }\n\n return null;\n }",
"public static Set<Target> getTargetDeps(Scope runtime, Scope compile) {\n return Sets.intersection(runtime.getTargetDeps(), compile.getTargetDeps());\n }",
"protected void reinitialize() {\n \n TTSelectTargetModel m = new TTSelectTargetModel(source, targetFilter);\n \n targetTree.setTreeTableModel( m );\n \n expandAll(new TreePath(m.getRoot()));\n \n // Clear any old listeners by creating a new listener list.\n listenerList = new EventListenerList();\n \n setPresetTarget(false);\n \n setAdditionalNotes(null);\n }",
"public TestSetDiscrepancyReportResourceTarget getTarget() {\n return this.target;\n }",
"String targetGraph();",
"public void setChargerTarget() {\n if (getEnemies().size() > 0) {\n ArrayList<RobotReference> enemies = getEnemies();\n RobotReference closestEnemy = enemies.get(0);\n if (chargerTarget == null && teamTarget != null) {\n for (RobotReference enemy : enemies) {\n if (!enemy.isTeammate()) {\n if (Vector2d.getDistanceTo(closestEnemy.getLocation(), getLocation()) > Vector2d.getDistanceTo(enemy.getLocation(), getLocation()))\n closestEnemy = enemy;\n }\n }\n chargerTarget = closestEnemy;\n } else {\n chargerTarget = enemies.get(0);\n }\n }\n }",
"public Relation setRelation(XDI3Segment arcXri, ContextNode targetContextNode);",
"public DecisionTree build(WorkingMemory wm, Class<?> klass, String targetField, Collection<String> workingAttributes) {\n\n\t\tunclassified_facts = new ArrayList<Fact>();\n\t\tDecisionTree dt = new DecisionTree(klass.getName());\n//\t\t**OPT\t\tList<FactSet> facts = new ArrayList<FactSet>();\n\t\tArrayList<Fact> facts = new ArrayList<Fact>();\n\t\tFactSet klass_fs = null;\n\t\tIterator<FactSet> it_fs= wm.getFactsets(); \n\t\twhile (it_fs.hasNext()) {\n\t\t\tFactSet fs = it_fs.next();\n\t\t\tif (fs instanceof OOFactSet) {\n\t\t\t\tif (klass.isAssignableFrom(((OOFactSet)fs).getFactClass())) {\n//\t\t\t\t\t**OPT\t\tfacts.add(fs);\n\t\t\t\t\t((OOFactSet)fs).assignTo(facts); // adding all facts of fs to \"facts\"\n\n\t\t\t\t\tif (klass == ((OOFactSet)fs).getFactClass()) {\n\t\t\t\t\t\tklass_fs = fs;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else if (klass.getName()== fs.getClassName()) {\n\n\t\t\t}\n\n\t\t}\n\t\tdt.FACTS_READ += facts.size();\n\n\t\tnum_fact_processed = facts.size();\n\n\t\tif (workingAttributes != null)\n\t\t\tfor (String attr: workingAttributes) {\n\t\t\t\tdt.addDomain(klass_fs.getDomain(attr));\n\t\t\t}\n\t\telse \n\t\t\tfor (Domain<?> d: klass_fs.getDomains())\n\t\t\t\tdt.addDomain(d);\n\n\t\tdt.setTarget(targetField);\n\n\t\tArrayList<String> attrs = new ArrayList<String>(dt.getAttributes());\n\t\tCollections.sort(attrs);\n\n\t\thelper = new MyThread();\n//\t\tSystem.out.println(\"IS ALIVE\"+helper.isAlive());\n\t\tTreeNode root = id3(dt, facts, attrs);\n\t\ttry {\n\t\t\thelper.join();\n\t\t} catch (InterruptedException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\tdt.setRoot(root);\n\n\t\treturn dt;\n\t}",
"default List<PendingAttestation> get_matching_target_attestations(BeaconState state, EpochNumber epoch) {\n return get_matching_source_attestations(state, epoch).stream()\n .filter(a -> a.getData().getTargetRoot().equals(get_block_root(state, epoch)))\n .collect(toList());\n }",
"private void manageTestTarget(){ \n if(labelArray[TEST_TARGET_LOCATION].getIcon()==iconSet.getGrayIcon()){\n labelArray[TEST_TARGET_LOCATION].setIcon(iconSet.getTestTargetIcon());\n System.out.println(\"Test Start\");\n } \n else{\n testTargetDelay++;\n System.out.println(\"DELAY:\" + testTargetDelay);\n }\n }"
] | [
"0.5981682",
"0.5734855",
"0.5633182",
"0.5537188",
"0.5487734",
"0.5456225",
"0.5447635",
"0.539962",
"0.5395699",
"0.5384148",
"0.5376247",
"0.5336951",
"0.5322357",
"0.53194076",
"0.5301935",
"0.52994084",
"0.52942324",
"0.5255084",
"0.525408",
"0.5250722",
"0.5236851",
"0.51883435",
"0.5187823",
"0.5181217",
"0.51587003",
"0.51523685",
"0.5137914",
"0.5133068",
"0.5128471",
"0.5127521",
"0.5125651",
"0.50944185",
"0.50882334",
"0.50781554",
"0.50702506",
"0.5065503",
"0.50652635",
"0.5047521",
"0.5038703",
"0.50027883",
"0.49909347",
"0.4984942",
"0.49802637",
"0.49752963",
"0.49752963",
"0.4961477",
"0.49470177",
"0.49398252",
"0.49380237",
"0.4928147",
"0.49128863",
"0.49128863",
"0.49095395",
"0.4898744",
"0.48928452",
"0.48888668",
"0.48866734",
"0.48826665",
"0.48815468",
"0.48804048",
"0.48804048",
"0.48636428",
"0.4862632",
"0.48505923",
"0.48440957",
"0.48335323",
"0.48306862",
"0.4827516",
"0.4814121",
"0.481153",
"0.48108786",
"0.47839507",
"0.47811323",
"0.47783354",
"0.47662556",
"0.474272",
"0.47423583",
"0.47420973",
"0.47378364",
"0.47355214",
"0.47283044",
"0.4726126",
"0.47208574",
"0.47196084",
"0.47150016",
"0.47090653",
"0.47086304",
"0.4708059",
"0.47028834",
"0.46903318",
"0.46900696",
"0.46876416",
"0.46862727",
"0.46858808",
"0.46818936",
"0.46794596",
"0.46717408",
"0.46673065",
"0.46547723",
"0.46429342"
] | 0.7637484 | 0 |
MN FIXED addFKs 24 June 2014 | private void addFKsNoReuse()
{
for(int i = 1; i < numOfTgtTables; i++)
{
// add a variable number of foreign keys per table (always the first keySize attributes)
//MN fixed the errors of incorrectly generating foreign key - 24 June 2014
//for (int j = 0; j < keySize; j++)
//addFK(i, j, 0, j, false);
String[] fAttr = new String[keySize];
for(int j=0; j<keySize; j++)
fAttr[j] = m.getTargetRels().get(i).getAttrArray(j).getName();
String[] tAttr = new String[keySize];
for (int j=0; j<keySize; j++)
tAttr[j] = m.getTargetRels().get(0).getAttrArray(j).getName();
addFK(i, fAttr, 0, tAttr, false);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void creatEmptyFixData() {\n fixInserts.put(ZcSettingConstants.FIX, \"上架费\");\r\n fixInserts.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixFVLs.put(ZcSettingConstants.FIX, \"成交费\");\r\n fixFVLs.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixPayPalFees.put(ZcSettingConstants.FIX, \"paypal费\");\r\n fixPayPalFees.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixProfits.put(ZcSettingConstants.FIX, \"利润\");\r\n fixProfits.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixProfitRates.put(ZcSettingConstants.FIX, \"利润率\");\r\n fixProfitRates.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n }",
"public static void deleteEntryFromCheckinsMinor3() throws PersistenceException, ParseException {\n\t\tDate date;\n\t\tDateFormat df = new SimpleDateFormat(\"yyyy-MM-dd\");\n\t\tCalendar calendar;\n\t\tString[] dates = new String[]{\t\"2011-01-01\", \"2011-01-02\", \"2011-01-03\", \"2011-01-04\",\n\t\t \t\"2011-01-05\", \"2011-01-06\", \"2011-01-07\", \"2011-01-08\",\n\t\t \t\"2011-01-09\", \"2011-01-10\", \"2011-01-11\", \"2011-01-12\",\n\t\t \t\"2011-01-13\", \"2011-01-14\", \"2011-01-15\", \"2011-01-16\",\n\t\t \t\"2011-01-17\", \"2011-01-18\", \"2011-01-19\", \"2011-01-20\",\n\t\t\t \"2011-01-21\", \"2011-01-22\", \"2011-01-23\", \"2011-01-24\",\n\t\t\t \"2011-01-25\", \"2011-01-26\", \"2011-01-27\", \"2011-01-28\",\n\t\t\t \"2011-01-29\", \"2011-01-30\", \"2011-01-31\",\n\t\t\t \"2011-02-01\", \"2011-02-02\", \"2011-02-03\", \"2011-02-04\",\n\t\t\t \"2011-02-05\", \"2011-02-06\", \"2011-02-07\", \"2011-02-08\",\n\t\t\t \"2011-02-09\", \"2011-02-10\", \"2011-02-11\", \"2011-02-12\",\n\t\t\t \"2011-02-13\", \"2011-02-14\", \"2011-02-15\", \"2011-02-16\",\n\t\t\t \"2011-02-17\", \"2011-02-18\", \"2011-02-19\", \"2011-02-20\",\n\t\t\t \"2011-02-21\", \"2011-02-22\", \"2011-02-23\", \"2011-02-24\",\n\t\t\t \"2011-02-28\",\n\t\t\t \"2011-03-01\", \"2011-03-02\", \"2011-03-03\", \"2011-03-04\",\n\t\t\t \"2011-03-05\", \"2011-03-06\", \"2011-03-07\", \"2011-03-08\",\n\t\t\t \"2011-03-09\", \"2011-03-10\", \"2011-03-11\", \"2011-03-12\",\n\t\t\t \"2011-03-13\", \"2011-03-14\", \"2011-03-15\", \"2011-03-16\",\n\t\t\t \"2011-03-17\", \"2011-03-18\", \"2011-03-19\", \"2011-03-20\",\n\t\t\t \"2011-03-21\", \"2011-03-22\", \"2011-03-23\", \"2011-03-24\",\n\t\t\t \"2011-03-25\", \"2011-03-26\", \"2011-03-27\", \"2011-03-28\",\n\t\t\t \"2011-03-29\", \"2011-03-30\", \"2011-03-31\",\n\t\t\t \"2011-04-01\", \"2011-04-02\", \"2011-04-03\", \"2011-04-04\",\n\t\t\t \"2011-04-05\", \"2011-04-06\", \"2011-04-07\", \"2011-04-08\",\n\t\t\t \"2011-04-09\", \"2011-04-10\", \"2011-04-11\", \"2011-04-12\",\n\t\t\t \"2011-04-13\", \"2011-04-14\", \"2011-04-15\", \"2011-04-16\",\n\t\t\t \"2011-04-17\", \"2011-04-18\", \"2011-04-19\", \"2011-04-20\",\n\t\t\t \"2011-04-21\", \"2011-04-22\", \"2011-04-23\", \"2011-04-24\",\n\t\t\t \"2011-04-25\", \"2011-04-26\", \"2011-04-27\", \"2011-04-28\",\n\t\t\t \"2011-04-29\", \"2011-04-30\",\n\t\t\t \"2011-05-01\", \"2011-05-02\", \"2011-05-03\", \"2011-05-04\",\n\t\t\t \"2011-05-05\", \"2011-05-06\", \"2011-05-07\", \"2011-05-08\",\n\t\t\t \"2011-05-09\", \"2011-05-10\", \"2011-05-11\", \"2011-05-12\",\n\t\t\t \"2011-05-13\", \"2011-05-14\", \"2011-05-15\", \"2011-05-16\",\n\t\t\t \"2011-05-17\", \"2011-05-18\", \"2011-05-19\", \"2011-05-20\",\n\t\t\t \"2011-05-21\", \"2011-05-22\", \"2011-05-23\", \"2011-05-24\",\n\t\t\t \"2011-05-25\", \"2011-05-26\", \"2011-05-27\", \"2011-05-28\",\n\t\t\t \"2011-05-29\", \"2011-05-30\", \"2011-05-31\",\n\t\t\t \"2011-06-01\", \"2011-06-02\", \"2011-06-03\", \"2011-06-04\",\n\t\t\t \"2011-06-05\", \"2011-06-06\", \"2011-06-07\", \"2011-06-08\",\n\t\t\t \"2011-06-09\", \"2011-06-10\", \"2011-06-11\", \"2011-06-12\",\n\t\t\t \"2011-06-13\", \"2011-06-14\", \"2011-06-15\", \"2011-06-16\",\n\t\t\t \"2011-06-17\", \"2011-06-18\", \"2011-06-19\", \"2011-06-20\",\n\t\t\t \"2011-06-21\", \"2011-06-22\", \"2011-06-23\", \"2011-06-24\",\n\t\t\t \"2011-06-25\", \"2011-06-26\", \"2011-06-27\", \"2011-06-28\",\n\t\t\t \"2011-06-29\", \"2011-06-30\",\n\t\t\t \"2011-07-01\", \"2011-07-02\", \"2011-07-03\", \"2011-07-04\",\n\t\t\t \"2011-07-05\", \"2011-07-06\", \"2011-07-07\", \"2011-07-08\",\n\t\t\t \"2011-07-09\", \"2011-07-10\", \"2011-07-11\", \"2011-07-12\",\n\t\t\t \"2011-07-13\", \"2011-07-14\", \"2011-07-15\", \"2011-07-16\",\n\t\t\t \"2011-07-17\", \"2011-07-18\", \"2011-07-19\", \"2011-07-20\",\n\t\t\t \"2011-07-21\", \"2011-07-22\", \"2011-07-23\", \"2011-07-24\",\n\t\t\t \"2011-07-25\", \"2011-07-26\", \"2011-07-27\", \"2011-07-28\",\n\t\t\t \"2011-07-29\", \"2011-07-30\", \"2011-07-31\" };\n\t\tDataSource datasource = new DataSource();\n\t\tConnection connection = null;\n\t\tPreparedStatement statement = null;\t\t\n\t\tResultSet result = null;\n\t\ttry {\n\t\t\tconnection = datasource.getConnection();\n\t\t\tfor (String s: dates) {\n\t\t\t\tcalendar = new GregorianCalendar();\n\t\t\t\tSystem.out.print(\"Inizio: \" + calendar.get(Calendar.HOUR) + \":\" + calendar.get(Calendar.MINUTE) + \" -- s=\" + s);\n\t\t\t\tString query =\t\"select user_id \" +\n\t\t\t\t\t\t\t\t\"from \" +\n\t\t\t\t\t\t\t\t\t\"(select user_id, count(date) \" +\n\t\t\t\t\t\t\t\t\t\"from \" +\n\t\t\t\t\t\t\t\t\t\t\"(select user_id, date(date) \" +\n\t\t\t\t\t\t\t\t\t\t\"from checkins_filtered \" +\n\t\t\t\t\t\t\t\t\t\t\"where date(date) = ? \" +\n\t\t\t\t\t\t\t\t\t\t\"order by user_id) as A \" +\n\t\t\t\t\t\t\t\t\t\"group by user_id) as B \" +\n\t\t\t\t\t\t\t\t\"where count < 3\";\n\t\t\t\tstatement = connection.prepareStatement(query);\n\t\t\t\tdate = df.parse(s);\n\t\t\t\tstatement.setTimestamp(1, new java.sql.Timestamp(date.getTime()));\t\t\n\t\t\t\tresult = statement.executeQuery();\n\t\t\t\t\n\t\t\t\tString delete = \"delete from checkins_filtered where user_id = ? and date(date) = ?\";\n\t\t\t\twhile (result.next()) {\n\t\t\t\t\tstatement = connection.prepareStatement(delete);\n\t\t\t\t\tstatement.setInt(1, result.getInt(\"user_id\"));\n\t\t\t\t\tstatement.setTimestamp(2, new java.sql.Timestamp(date.getTime()));\n\t\t\t\t\tstatement.executeUpdate();\t\t\t\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\tcalendar = new GregorianCalendar();\n\t\t\t\tSystem.out.print(\" -- Fine: \" + calendar.get(Calendar.HOUR) + \":\" + calendar.get(Calendar.MINUTE));\n\t\t\t\tSystem.out.println();\n\t\t\t\tSystem.out.println();\n\t\t\t}\t\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t} catch (SQLException e) {\n\t\t\t\tthrow new PersistenceException(e.getMessage());\n\t\t} finally {\n\t\t\t\ttry {\n\t\t\t\t\tif (result != null)\n\t\t\t\t\t\tresult.close();\n\t\t\t\t\tif (statement != null) \n\t\t\t\t\t\tstatement.close();\n\t\t\t\t\tif (connection!= null)\n\t\t\t\t\t\tconnection.close();\n\t\t\t\t} catch (SQLException e) {\n\t\t\t\t\tthrow new PersistenceException(e.getMessage());\n\t\t\t\t}\n\t\t\t}\n\t}",
"public TableModel cacualateFixPriceFee(EbCandidateItem item) {\n EbFeeCaculaterFactory factory = EbFeeCaculaterFactory.getInstance();\r\n EbUtil ebu = new EbUtil();\r\n fixInserts.put(ZcSettingConstants.FIX, \"上架费\");\r\n fixInserts.put(\r\n ZcSettingConstants.US,\r\n factory.getFixInsertFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n fixInserts.put(\r\n ZcSettingConstants.UK,\r\n factory.getFixInsertFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n fixInserts.put(\r\n ZcSettingConstants.DE,\r\n factory.getFixInsertFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n fixInserts.put(\r\n ZcSettingConstants.FR,\r\n factory.getFixInsertFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n fixInserts.put(\r\n ZcSettingConstants.CA,\r\n factory.getFixInsertFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n fixInserts.put(\r\n ZcSettingConstants.AU,\r\n factory.getFixInsertFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n fixFVLs.put(ZcSettingConstants.FIX, \"成交费\");\r\n fixFVLs.put(\r\n ZcSettingConstants.US,\r\n factory.getFixFVLs(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.UK,\r\n factory.getFixFVLs(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.DE,\r\n factory.getFixFVLs(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.FR,\r\n factory.getFixFVLs(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.CA,\r\n factory.getFixFVLs(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.AU,\r\n factory.getFixFVLs(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU), item.getCategoryType()));\r\n\r\n fixPayPalFees.put(ZcSettingConstants.FIX, \"paypal费\");\r\n fixPayPalFees.put(\r\n ZcSettingConstants.US,\r\n factory.getFixPayPalFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.UK,\r\n factory.getFixPayPalFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.DE,\r\n factory.getFixPayPalFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.FR,\r\n factory.getFixPayPalFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.CA,\r\n factory.getFixPayPalFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.AU,\r\n factory.getFixPayPalFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n fixProfits.put(ZcSettingConstants.FIX, \"利润\");\r\n fixProfitRates.put(ZcSettingConstants.FIX, \"利润率\");\r\n\r\n if (item.getCost() != null && item.getTransportFee() != null) {\r\n\r\n EbProfit profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()),\r\n ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()), item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD));\r\n fixProfits.put(ZcSettingConstants.US, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.US, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP));\r\n fixProfits.put(ZcSettingConstants.UK, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.UK, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR));\r\n fixProfits.put(ZcSettingConstants.DE, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.DE, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR));\r\n fixProfits.put(ZcSettingConstants.FR, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.FR, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD));\r\n fixProfits.put(ZcSettingConstants.CA, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.CA, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD));\r\n fixProfits.put(ZcSettingConstants.AU, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.AU, profit.getProfitRate());\r\n }\r\n return getFixTableModel();\r\n }",
"public void setupDays() {\n\n //if(days.isEmpty()) {\n days.clear();\n int day_number = today.getActualMaximum(Calendar.DAY_OF_MONTH);\n SimpleDateFormat sdf = new SimpleDateFormat(\"EEEE\");\n SimpleDateFormat sdfMonth = new SimpleDateFormat(\"MMM\");\n today.set(Calendar.DATE, 1);\n for (int i = 1; i <= day_number; i++) {\n OrariAttivita data = new OrariAttivita();\n data.setId_utente(mActualUser.getID());\n\n //Trasformare in sql date\n java.sql.Date sqldate = new java.sql.Date(today.getTimeInMillis());\n data.setGiorno(sqldate.toString());\n\n data.setDay(i);\n data.setMonth(today.get(Calendar.MONTH) + 1);\n\n data.setDay_of_week(today.get(Calendar.DAY_OF_WEEK));\n Date date = today.getTime();\n String day_name = sdf.format(date);\n data.setDay_name(day_name);\n data.setMonth_name(sdfMonth.format(date));\n\n int indice;\n\n if (!attivitaMensili.isEmpty()) {\n if ((indice = attivitaMensili.indexOf(data)) > -1) {\n OrariAttivita temp = attivitaMensili.get(indice);\n if (temp.getOre_totali() == 0.5) {\n int occurence = Collections.frequency(attivitaMensili, temp);\n if (occurence == 2) {\n for (OrariAttivita other : attivitaMensili) {\n if (other.equals(temp) && other.getCommessa() != temp.getCommessa()) {\n data.setOtherHalf(other);\n data.getOtherHalf().setModifica(true);\n }\n }\n\n }\n }\n data.setFromOld(temp);\n data.setModifica(true);\n }\n }\n isFerie(data);\n\n\n //Aggiungi la data alla lista\n days.add(data);\n\n //Aggiugni un giorno alla data attuale\n today.add(Calendar.DATE, 1);\n }\n\n today.setTime(actualDate);\n\n mCalendarAdapter.notifyDataSetChanged();\n mCalendarList.setAdapter(mCalendarAdapter);\n showProgress(false);\n }",
"private void addFKs(String attrs[], int relNum) \n\t{\n\t\t//for(int i = 1; i < numOfTgtTables; i++) \n\t\t//{\n\t\t\t// add a variable number of foreign keys per table (always the first keySize attributes)\n\t\t\t//MN fixed the errors of incorrectly generating foreign key - 24 June 2014\n\t\t\t//for (int j = 0; j < keySize; j++)\n\t\t\t\t//addFK(i, j, 0, j, false);\n\t\t\tString[] fAttr = new String[keySize];\n\t\t\tfor(int i=0; i<keySize; i++)\n\t\t\t\tfAttr[i] = attrs[i];\n\t\t\t\n\t\t\tString[] tAttr = new String[keySize];\n\t\t\tfor (int i=0; i<keySize; i++)\n\t\t\t\ttAttr [i] = m.getTargetRels().get(0).getAttrArray(i).getName();\n\t\t\t\n\t\t\taddFK(relNum, fAttr, 0, tAttr, false);\n\t\t//}\n\t}",
"static void feladat7() {\n\t}",
"public void secondaryAddI13nDateSaving(com.hps.july.persistence.I13nDateSaving anI13nDateSaving) throws java.rmi.RemoteException;",
"public static void main(String[] args) {\r\n\t Scanner in = new Scanner(System.in);\r\n\t int d1 = in.nextInt();\r\n\t int m1 = in.nextInt();\r\n\t int y1 = in.nextInt();\r\n\t int d2 = in.nextInt();\r\n\t int m2 = in.nextInt();\r\n\t int y2 = in.nextInt();\r\n\t LocalDate returnDate=LocalDate.of(y1,m1,d1);\r\n\t LocalDate dueDate=LocalDate.of(y2,m2,d2);\r\n\t long fine=0;\r\n\t if(returnDate.isBefore(dueDate)||returnDate.equals(dueDate))fine=0;\r\n\t else if(returnDate.isAfter(dueDate)){\r\n\t \tif(returnDate.getYear()==dueDate.getYear()){\r\n\t \t\tif(returnDate.getMonth()==dueDate.getMonth()){\r\n\t \t\t\tfine=(returnDate.getDayOfYear()-dueDate.getDayOfYear())*15;\r\n\t \t\t}else{\r\n\t \t\t\t\tfine=(returnDate.getMonthValue()-dueDate.getMonthValue())*500;\r\n\t \t\t\r\n\t \t}\r\n\t \t\t\r\n\t \t\t\r\n\t } else fine=10000;\r\n\t }else fine=10000;\r\n\t System.out.println(fine);\r\n\t }",
"public void AddAvailableDates()\n\t{\n\t\ttry\n\t\t{\n\t\t\tConnector con = new Connector();\n\t\t\tString query; \n\t\t\t\n\t\t\tfor(int i = 0; i < openDates.size(); i++)\n\t\t\t{\n\t\t\t\tboolean inTable = CheckAvailableDate(openDates.get(i)); \n\t\t\t\tif(inTable == false)\n\t\t\t\t{\n\t\t\t\t\tquery = \"INSERT INTO Available(available_hid, price_per_night, startDate, endDate)\"\n\t\t\t\t\t\t\t+\" VALUE(\"+hid+\", \"+price+\", '\"+openDates.get(i).stringStart+\"', '\"+openDates.get(i).stringEnd+\"')\";\n\t\t\t\t\tint result = con.stmt.executeUpdate(query); \n\t\t\t\t}\n\t\t\t}\n\t\t\tcon.closeConnection();\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t}",
"public void addAufgabe() {\r\n this.aufgabenZahl++;\r\n }",
"public abstract void add(Date212 date);",
"public int getLBR_ProtestDays();",
"static void feladat6() {\n\t}",
"public boolean createFixedDeposit(FixedDepositDetails fdd) {\n\t\treturn true;\n\t}",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.DebtEntry addNewDebts();",
"public void addUsedUDay(Integer date) {\n pastUDays.add(date);\n }",
"int insert(AoD5e466WorkingDay record);",
"public void createBonFiscal(int idBonFiscal, Date data, float suma, int idClient) {\n\t\tif (bonFiscalOperations.checkBonFiscal(idBonFiscal) == true) {\n\t\t\tSystem.out.println(\"Bon fiscal existent!\");\n\n\t\t\tBonFiscal bonFiscal = new BonFiscal(idBonFiscal, data, suma);\n\t\t\tbonFiscal.setIdClient(idClient);\n\t\t\tList<BonFiscal> list = bonFiscalOperations.getAllBonuri();\n\t\t\tbonFiscalOperations.addBonFiscal(bonFiscal);\n\t\t\tbonFiscalOperations.printListOfBonuri(list);\n\t\t}\n\t}",
"int insertSelective(AoD5e466WorkingDay record);",
"@Test(timeout = 4000)\n public void test012() throws Throwable {\n DBSchema dBSchema0 = new DBSchema(\"truncate\");\n DefaultDBTable defaultDBTable0 = new DefaultDBTable(\"createnuniqe inde*]/$]($%;qgq`gg\", dBSchema0);\n DBForeignKeyConstraint dBForeignKeyConstraint0 = new DBForeignKeyConstraint(\"&]ZYR\", false, defaultDBTable0, (String[]) null, defaultDBTable0, (String[]) null);\n NameSpec nameSpec0 = NameSpec.ALWAYS;\n String string0 = SQLUtil.fkSpec(dBForeignKeyConstraint0, nameSpec0);\n assertEquals(\"CONSTRAINT &]ZYR FOREIGN KEY () REFERENCES createnuniqe inde*]/$]($%;qgq`gg()\", string0);\n }",
"void mo1507n();",
"public TableModel cacualateChineseFee(EbCandidateItem item) {\n EbFeeCaculaterFactory factory = EbFeeCaculaterFactory.getInstance();\r\n EbUtil ebu = new EbUtil();\r\n chineseInserts.put(ZcSettingConstants.CHINESE, \"上架费\");\r\n chineseInserts.put(\r\n ZcSettingConstants.US,\r\n factory.getChineseInsertFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n chineseInserts.put(\r\n ZcSettingConstants.UK,\r\n factory.getChineseInsertFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n chineseInserts.put(\r\n ZcSettingConstants.DE,\r\n factory.getChineseInsertFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n chineseInserts.put(\r\n ZcSettingConstants.FR,\r\n factory.getChineseInsertFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n chineseInserts.put(\r\n ZcSettingConstants.CA,\r\n factory.getChineseInsertFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n chineseInserts.put(\r\n ZcSettingConstants.AU,\r\n factory.getChineseInsertFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n chineseFVLs.put(ZcSettingConstants.CHINESE, \"成交费\");\r\n chineseFVLs.put(\r\n ZcSettingConstants.US,\r\n factory.getChineseFVLs(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.UK,\r\n factory.getChineseFVLs(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.DE,\r\n factory.getChineseFVLs(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.FR,\r\n factory.getChineseFVLs(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.CA,\r\n factory.getChineseFVLs(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.AU,\r\n factory.getChineseFVLs(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU), item.getCategoryType()));\r\n\r\n chinesePayPalFees.put(ZcSettingConstants.CHINESE, \"paypal费\");\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.US,\r\n factory.getChinesePayPalFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.UK,\r\n factory.getChinesePayPalFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.DE,\r\n factory.getChinesePayPalFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.FR,\r\n factory.getChinesePayPalFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.CA,\r\n factory.getChinesePayPalFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.AU,\r\n factory.getChinesePayPalFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n chineseProfits.put(ZcSettingConstants.CHINESE, \"利润\");\r\n chineseProfitRates.put(ZcSettingConstants.CHINESE, \"利润率\");\r\n if (item.getCost() != null && item.getTransportFee() != null) {\r\n\r\n EbProfit profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()),\r\n ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()), item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD));\r\n chineseProfits.put(ZcSettingConstants.US, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.US, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP));\r\n chineseProfits.put(ZcSettingConstants.UK, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.UK, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR));\r\n chineseProfits.put(ZcSettingConstants.DE, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.DE, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR));\r\n chineseProfits.put(ZcSettingConstants.FR, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.FR, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD));\r\n chineseProfits.put(ZcSettingConstants.CA, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.CA, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD));\r\n chineseProfits.put(ZcSettingConstants.AU, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.AU, profit.getProfitRate());\r\n }\r\n return getChineseTableModel();\r\n }",
"public void addFM(final FMTafTrend change) {\n fMs.add(change);\n }",
"protected void addDay(Date date) throws Exception {\n Calendar cal = DateHelper.newCalendarUTC();\n cal.setTime(date);\n String datecode = cal.get(Calendar.YEAR) + \"-\" + (cal.get(Calendar.MONTH) + 1) + \"-\" + cal.get(Calendar.DAY_OF_MONTH);\n affectedDays.put(datecode, date);\n Date rDate = DateHelper.roundDownLocal(date);\n datesTodo.add(rDate);\n }",
"public void payFees(int fees) {\n feesPaid += fees;\n School.updateTotalMoneyEarned(feesPaid);\n }",
"@attribute(value = \"\", required = true)\t\r\n\tpublic void addDateField(DateField f) {\r\n\t\tfields.put(\"\" + fieldCount++, f);\r\n\t}",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.FinancialStatement addNewFinancialStatements();",
"public void afegirFestius() {\n\t\t\tGregorianCalendar dia1 = new GregorianCalendar(any,0,1);\n\t\t\tint diaset = dia1.get(Calendar.DAY_OF_WEEK);\n\t\t\tif(diaset==2) diaset=6;\n\t\t\telse if(diaset==3) diaset=5;\n\t\t\telse if(diaset==4) diaset=4;\n\t\t\telse if(diaset==5) diaset=3;\n\t\t\telse if(diaset==6) diaset=2;\n\t\t\telse if(diaset==7) diaset=1;\n\t\t\telse diaset=0;\n\t\t\tfor(int i=diaset; i<cal.length; i+=7){\n\t\t\t\tcal[i].setFestiu(true);\n\t\t\t}\n\t\t\n\t}",
"public void mo35052a() {\n this.f30707l = true;\n }",
"int getNdwi6Id(String project, String feature, DataDate date) throws SQLException;",
"public void setDaysAdded(int value) {\n this.daysAdded = value;\n }",
"public void addUsedEDay(Integer date) {\n pastEDays.add(date);\n }",
"public void setFiNgayDk(Date fiNgayDk) {\n this.fiNgayDk = fiNgayDk;\n }",
"public void toPunish() {\n\n //// TODO: 24/03/2017 delete the following lines\n// dalDynamic.addRowToTable2(\"23/03/2017\",\"Thursday\",4,walkingLength,deviation)\n\n\n\n int dev,sum=0;\n long id;\n id=dalDynamic.getRecordIdAccordingToRecordName(\"minutesWalkTillEvening\");\n Calendar now = Calendar.getInstance();//today\n Calendar calendar = Calendar.getInstance();\n SimpleDateFormat dateFormat=new SimpleDateFormat(\"dd/MM/yyyy\");\n String date;\n for (int i = 0; i <DAYS_DEVIATION ; i++) {\n date=dateFormat.format(calendar.getTime());\n Log.v(\"Statistic\",\"date \"+date);\n dev = dalDynamic.getDeviationAccordingToeventTypeIdAnddate(id,date);\n sum+=dev;\n calendar.add(Calendar.DATE,-1);//// TODO: -1-i????\n }\n if(sum==DAYS_DEVIATION){\n Intent intent = new Intent(context,BlankActivity.class);\n context.startActivity(intent);\n //todo:punishment\n }\n\n }",
"@Override\n\tpublic int fees() {\n\t\treturn 25000;\n\t\t\n\t}",
"void addHasCFD(CFD newHasCFD);",
"public void addFjlx(Fjlx fx) {\n\r\n\t}",
"int getNdwi5Id(String project, String feature, DataDate date) throws SQLException;",
"private void attachDatabaseReference_requested_holidays() {\n if (mChildEventListenerDaysRequested == null) {\n mChildEventListenerDaysRequested = new ChildEventListener() {\n @Override\n public void onChildAdded(DataSnapshot dataSnapshot, String s) {\n Log.v(\"***********\", \"There has beem an addition in daysRequested\");\n //List<Long> longList = (List) dataSnapshot.getValue();\n if (dataSnapshot.getKey().equals(mUserID)) {//check if it's the current user branch\n RequestedHolidays reques = new RequestedHolidays();\n //reques = dataSnapshot.getValue(RequestedHolidays.class);\n GenericTypeIndicator<List<Long>> t =\n new GenericTypeIndicator<List<Long>>() {\n };\n\n Object objecto = dataSnapshot.getValue();\n //List<Long> messages = dataSnapshot.getValue(t);\n //makeMapHash(objecto);\n //HashMap<String, Long> map = new HashMap<String, Long>();\n //map.put (1, \"Mark\");\n //map.put (2, \"Tarryn\");\n //map = (HashMap) dataSnapshot.getValue();\n //List<Long> list = new ArrayList<Long>(map.values());\n\n //List<Long> longList = (List) dataSnapshot.getValue();\n List<Long> longList = (List<Long>) dataSnapshot.getValue();\n requestedHolidays = ConvertHashToList(longList);\n Log.i(\"***********\", \"DrawMonth called in attach...requested\");\n drawMonth(workingDays, holidays, requestedHolidays, generalCalendar);\n }\n }\n\n @Override\n public void onChildChanged(DataSnapshot dataSnapshot, String s) {\n Log.i(\"***********\", \"There has beem a change in daysRequested\");\n }\n\n @Override\n public void onChildRemoved(DataSnapshot dataSnapshot) {\n Log.i(\"***********\", \"There has beem a removed in daysRequested\");\n\n }\n\n @Override\n public void onChildMoved(DataSnapshot dataSnapshot, String s) {\n Log.i(\"***********\", \"There has beem a moved in daysRequested\");\n }\n\n @Override\n public void onCancelled(DatabaseError databaseError) {\n Toast.makeText(getApplicationContext(), \"ONCANCELLED in /requested_holidays\", Toast.LENGTH_LONG).show();\n Log.i(\"***********\", \"ONCANCELLED IN /requested_holidays\");\n }\n };\n //when days are added to the requestedHolidays in the DB this will trigger\n //mDatabaseReferenceHolidays.addChildEventListener(mChildEventListenerDaysRequested);\n mDatabaseReferenceRequestedHolidays.addChildEventListener(mChildEventListenerDaysRequested);\n //mDatabaseReference.addChildEventListener(mChildEventListenerDaysRequested);\n }\n }",
"private void addrec() {\n\t\tnmfkpinds.setPgmInd34(false);\n\t\tnmfkpinds.setPgmInd36(true);\n\t\tnmfkpinds.setPgmInd37(false);\n\t\tstateVariable.setActdsp(replaceStr(stateVariable.getActdsp(), 1, 8, \"ADDITION\"));\n\t\tstateVariable.setXwricd(\"INV\");\n\t\ttransactionTypeDescription.retrieve(stateVariable.getXwricd());\n\t\tnmfkpinds.setPgmInd99(! lastIO.isFound());\n\t\t// BR00003 Trn_Hst_Trn_Type not found on Transaction_type_description\n\t\tif (nmfkpinds.pgmInd99()) {\n\t\t\tstateVariable.setXwtdsc(all(\"-\", 20));\n\t\t}\n\t\tstateVariable.setXwa2cd(\"EAC\");\n\t\tstateVariable.setUmdes(replaceStr(stateVariable.getUmdes(), 1, 11, um[1]));\n\t\taddrec0();\n\t}",
"public void insertarPlanDieta(int id_plan_de_dieta, int caloria_max_diarias, Date fecha_Inicio, Date Fecha_fin, int n_comidas_diarias,int id_paciente,int id_nutricionista);",
"public void addWF(int f, int d){\n\t\tf= getIndirectAdress(f);\n\t\tint w = Worker.reg.getWReg(); \n\t\tint buf = getValFromBank(f)+w;\n\t\tint dc = (w & 15) + (getValFromBank(f) & 15);\n\t\tsetCFlag(buf);\n\t\tsetDCFlag(dc);\n\t\tbuf = buf&255;\n\t\tsetZFlag(buf);\n\t\tcheckDandInsert(buf,f,d);\n\t\tWorker.reg.increasePC();\n\t\tWorker.reg.addCycle();\n\t}",
"public void addDate(Date value) {\n/* 132 */ addDateToSeq(\"date\", value);\n/* */ }",
"@RequestForEnhancement(\r\n\t\t/* see also 4561444 - balance trade deficit */\r\n\t\tid=4561414,\r\n\t\tsynopsis=\"Balance the federal budget\") // after RequestForEnhancement\r\n\t@Author(\r\n\t\t//The author name\r\n\t\t@Name(first=\"Joe\", last=\"Hacker\") )\r\n\t// after Author\r\n\tpublic static void balanceFederalBudget() {\r\n\t\tthrow new UnsupportedOperationException(\"Not implemented\");\r\n\t}",
"com.synergyj.cursos.webservices.ordenes.XMLBFactura addNewXMLBFactura();",
"public com.guidewire.datamodel.ForeignkeyDocument.Foreignkey addNewForeignkey()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n com.guidewire.datamodel.ForeignkeyDocument.Foreignkey target = null;\r\n target = (com.guidewire.datamodel.ForeignkeyDocument.Foreignkey)get_store().add_element_user(FOREIGNKEY$4);\r\n return target;\r\n }\r\n }",
"@Test\n\tpublic void test() {\n\t\tfinal LocalDate referenceDate = LocalDate.of(2016, 1, 1);\n\t\tfor(int i=0; i<1000; i++) {\n\t\t\tfinal LocalDate date = referenceDate.plusDays(i);\n\n\t\t\tfinal double floatingPointDate = FloatingpointDate.getFloatingPointDateFromDate(referenceDate, date);\n\t\t\tfinal LocalDate dateFromFloat\t= FloatingpointDate.getDateFromFloatingPointDate(referenceDate, floatingPointDate);\n\n\t\t\tAssert.assertTrue(\"Roundtrip with date offset of \" + i + \" days.\", dateFromFloat.isEqual(date));\n\t\t}\n\t}",
"void addEndingHadithNo(Object newEndingHadithNo);",
"private void searchex()\n {\n try\n {\n this.dtm.setRowCount(0);\n \n String a = \"date(now())\";\n if (this.jComboBox1.getSelectedIndex() == 1) {\n a = \"DATE_ADD( date(now()),INTERVAL 10 DAY)\";\n } else if (this.jComboBox1.getSelectedIndex() == 2) {\n a = \"DATE_ADD( date(now()),INTERVAL 31 DAY)\";\n } else if (this.jComboBox1.getSelectedIndex() == 3) {\n a = \"DATE_ADD( date(now()),INTERVAL 90 DAY)\";\n } else if (this.jComboBox1.getSelectedIndex() == 4) {\n a = \"DATE_ADD( date(now()),INTERVAL 180 DAY)\";\n }\n ResultSet rs = this.d.srh(\"select * from stock inner join product on stock.product_id = product.id where exdate <= \" + a + \" and avqty > 0 order by exdate\");\n while (rs.next())\n {\n Vector v = new Vector();\n v.add(rs.getString(\"product_id\"));\n v.add(rs.getString(\"name\"));\n v.add(rs.getString(\"stock.id\"));\n v.add(Double.valueOf(rs.getDouble(\"buyprice\")));\n v.add(Double.valueOf(rs.getDouble(\"avqty\")));\n v.add(rs.getString(\"exdate\"));\n this.dtm.addRow(v);\n }\n }\n catch (Exception e)\n {\n e.printStackTrace();\n }\n }",
"public static void Ln7() {\r\n EBAS.L7_Timestamp.setText(GtDates.ldate);\r\n \r\n EBAS.L7_First_Sku.setEnabled(false);\r\n EBAS.L7_Qty_Out.setEnabled(false);\r\n EBAS.L7_First_Desc.setEnabled(false);\r\n EBAS.L7_Orig_Sku.setEnabled(false);\r\n EBAS.L7_Orig_Desc.setEnabled(false);\r\n EBAS.L7_Orig_Attr.setEnabled(false);\r\n EBAS.L7_Orig_Size.setEnabled(false);\r\n EBAS.L7_Orig_Retail.setEnabled(false);\r\n EBAS.L7_Manuf_Inspec.setEnabled(false);\r\n EBAS.L7_New_Used.setEnabled(false);\r\n EBAS.L7_Reason_DropDown.setEnabled(false);\r\n EBAS.L7_Desc_Damage.setEnabled(false);\r\n EBAS.L7_Cust_Satisf_ChkBox.setEnabled(false);\r\n EBAS.L7_Warranty_ChkBox.setEnabled(false);\r\n \r\n try {\r\n upDB();\r\n } catch (ClassNotFoundException | SQLException ex) {\r\n Logger.getLogger(EBAS.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n }",
"@Test(timeout = 4000)\n public void test011() throws Throwable {\n DefaultDBTable defaultDBTable0 = new DefaultDBTable(\"inserto\");\n String[] stringArray0 = new String[2];\n DBForeignKeyConstraint dBForeignKeyConstraint0 = new DBForeignKeyConstraint(\"4}1ngl\", false, defaultDBTable0, stringArray0, defaultDBTable0, stringArray0);\n NameSpec nameSpec0 = NameSpec.NEVER;\n String string0 = SQLUtil.fkSpec(dBForeignKeyConstraint0, nameSpec0);\n assertEquals(\"FOREIGN KEY (, ) REFERENCES inserto(, )\", string0);\n }",
"public void setDateAdded(Date dateAdded);",
"public Date getDateAdded();",
"static void feladat9() {\n\t}",
"public void dvAdded()\r\n/* 76: */ {\r\n/* 77:160 */ this.numDVRecords += 1;\r\n/* 78: */ }",
"public int getLBR_CollectionReturnDays();",
"static void feladat4() {\n\t}",
"int insertSelective(FinMonthlySnapModel record);",
"public void addNewBenificiary() {\n\t\t\tsetColBankCode(null);\n\t\t\tsetCardNumber(null);\n\t\t\tsetPopulatedDebitCardNumber(null);\n\t\t\tsetApprovalNumberCard(null);\n\t\t\tsetRemitamount(null);\n\t\t\tsetColAuthorizedby(null);\n\t\t\tsetColpassword(null);\n\t\t\tsetApprovalNumber(null);\n\t\t\tsetBooAuthozed(false);\n\t\t\tbankMasterList.clear();\n\t\t\tlocalbankList.clear();// From View V_EX_CBNK\n\t\t\tlstDebitCard.clear();\n\n\t\t\t// to fetch All Banks from View\n\t\t\t//getLocalBankListforIndicatorFromView();\n\t\t\tlocalbankList = generalService.getLocalBankListFromView(session.getCountryId());\n\n\t\t\tList<BigDecimal> duplicateCheck = new ArrayList<BigDecimal>();\n\t\t\tList<ViewBankDetails> lstofBank = new ArrayList<ViewBankDetails>();\n\t\t\tif (localbankList.size() != 0) {\n\t\t\t\tfor (ViewBankDetails lstBank : localbankList) {\n\t\t\t\t\tif (!duplicateCheck.contains(lstBank.getChequeBankId())) {\n\t\t\t\t\t\tduplicateCheck.add(lstBank.getChequeBankId());\n\t\t\t\t\t\tlstofBank.add(lstBank);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tsetBankMasterList(lstofBank);\n\t\t\tsetBooRenderSingleDebit(true);\n\t\t\tsetBooRenderMulDebit(false);\n\t\t}",
"public void m6607X() {\n try {\n HashMap hashMap = new HashMap();\n hashMap.put(\"is_rename\", \"0\");\n C1390G.m6779b(\"A107|1|3|10\", hashMap);\n HashMap hashMap2 = new HashMap();\n hashMap2.put(\"mark_num\", String.valueOf(this.f5418ga));\n C1390G.m6779b(\"A107|1|3|10\", hashMap2);\n HashMap hashMap3 = new HashMap();\n hashMap3.put(\"rec_time\", String.valueOf(this.f5420ha));\n C1390G.m6779b(\"A107|1|3|10\", hashMap3);\n } catch (Exception e) {\n C0938a.m5004b(\"SR/SoundRecorder\", \"A107|1|3|10Vcode error:\" + e);\n }\n }",
"public static void traduitSiteFrancais() {\n\t\t\n\t}",
"public void getREFDT()//get reference date\n\t{\n\t\ttry\n\t\t{\n\t\t\tDate L_strTEMP=null;\n\t\t\tM_strSQLQRY = \"Select CMT_CCSVL,CMT_CHP01,CMT_CHP02 from CO_CDTRN where CMT_CGMTP='S\"+cl_dat.M_strCMPCD_pbst+\"' and CMT_CGSTP = 'FGXXREF' and CMT_CODCD='DOCDT'\";\n\t\t\tResultSet L_rstRSSET = cl_dat.exeSQLQRY2(M_strSQLQRY);\n\t\t\tif(L_rstRSSET != null && L_rstRSSET.next())\n\t\t\t{\n\t\t\t\tstrREFDT = L_rstRSSET.getString(\"CMT_CCSVL\").trim();\n\t\t\t\tL_rstRSSET.close();\n\t\t\t\tM_calLOCAL.setTime(M_fmtLCDAT.parse(strREFDT)); // Convert Into Local Date Format\n\t\t\t\tM_calLOCAL.add(Calendar.DATE,+1); // Increase Date from +1 with Locked Date\n\t\t\t\tstrREFDT = M_fmtLCDAT.format(M_calLOCAL.getTime()); // Assign Date to Veriable \n\t\t\t\t//System.out.println(\"REFDT = \"+strREFDT);\n\t\t\t}\n\t\t}\n\t\tcatch(Exception L_EX)\n\t\t{\n\t\t\tsetMSG(L_EX,\"getREFDT\");\n\t\t}\n\t}",
"stockFilePT102.StockDocument.Stock addNewStock();",
"Long addWayBill(WayBill wayBill);",
"public int insertCohortNutritionalNeeds(CohortNutritionalNeeds dietReq) throws SQLException {\n\t\tint recordAdded = -1;\n\t\tString qryString = \"insert into imd.FEED_COHORT_NUTRITIONAL_NEEDS (ORG_ID,\"\n\t\t\t\t+ \"FEED_COHORT,\"\n\t\t\t\t+ \"START,\"\n\t\t\t\t+ \"END,\"\n\t\t\t\t+ \"DM,\"\n\t\t\t\t+ \"CP,\"\n\t\t\t\t+ \"ME,\"\n\t\t\t\t+ \"CREATED_BY,\"\n\t\t\t\t+ \"CREATED_DTTM,\"\n\t\t\t\t+ \"UPDATED_BY,\"\n\t\t\t\t+ \"UPDATED_DTTM) VALUES (?,?,?,?,?,?,?,?,?,?,?)\";\n\t\tPreparedStatement preparedStatement = null;\n\t\tConnection conn = DBManager.getDBConnection();\n\t\ttry {\n\t\t\tpreparedStatement = conn.prepareStatement(qryString);\n\t\t\tpreparedStatement.setString(1, dietReq.getOrgId());\n\t\t\tpreparedStatement.setString(2, dietReq.getFeedCohortCD());\n\t\t\tpreparedStatement.setFloat(3, dietReq.getStart());\n\t\t\tpreparedStatement.setFloat(4, dietReq.getEnd());\n\t\t\tpreparedStatement.setFloat(5, dietReq.getDryMatter());\n\t\t\tpreparedStatement.setFloat(6, dietReq.getCrudeProtein());\n\t\t\tpreparedStatement.setFloat(7, dietReq.getMetabloizableEnergy());\n\t\t\tpreparedStatement.setString(8, dietReq.getCreatedBy().getUserId());\n\t\t\tpreparedStatement.setString(9, dietReq.getCreatedDTTMSQLFormat());\n\t\t\tpreparedStatement.setString(10, dietReq.getUpdatedBy().getUserId());\n\t\t\tpreparedStatement.setString(11, dietReq.getUpdatedDTTMSQLFormat());\n\t\t\trecordAdded = preparedStatement.executeUpdate();\n\t\t} catch (java.sql.SQLIntegrityConstraintViolationException ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.KEY_INTEGRITY_VIOLATION;\n\t\t\tex.printStackTrace();\n\t\t} catch (com.mysql.cj.jdbc.exceptions.MysqlDataTruncation ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.DATA_LENGTH_ISSUE;\n\t\t\tex.printStackTrace();\n\t\t} catch (java.sql.SQLSyntaxErrorException ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.SQL_SYNTAX_ERROR;\n\t\t\tex.printStackTrace();\n\t\t} catch (java.sql.SQLException ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.UNKNOWN_ERROR;\n\t\t\tex.printStackTrace();\n\t\t} catch (Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t} finally {\n\t\t try {\n\t\t\t\tif (preparedStatement != null && !preparedStatement.isClosed()) {\n\t\t\t\t\tpreparedStatement.close();\t\n\t\t\t\t}\n\t\t\t} catch (SQLException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\treturn recordAdded;\n\t}",
"private void addRow() throws CoeusException{\r\n // PDF is not mandatory\r\n// String fileName = displayPDFFileDialog();\r\n// if(fileName == null) {\r\n// //Cancelled\r\n// return ;\r\n// }\r\n \r\n BudgetSubAwardBean budgetSubAwardBean = new BudgetSubAwardBean();\r\n budgetSubAwardBean.setProposalNumber(budgetBean.getProposalNumber());\r\n budgetSubAwardBean.setVersionNumber(budgetBean.getVersionNumber());\r\n budgetSubAwardBean.setAcType(TypeConstants.INSERT_RECORD);\r\n// budgetSubAwardBean.setPdfAcType(TypeConstants.INSERT_RECORD);\r\n budgetSubAwardBean.setSubAwardStatusCode(1);\r\n // PDF is not mandatory\r\n// budgetSubAwardBean.setPdfFileName(fileName);\r\n budgetSubAwardBean.setUpdateUser(userId);\r\n //COEUSQA-4061 \r\n CoeusVector cvBudgetPeriod = new CoeusVector(); \r\n \r\n cvBudgetPeriod = getBudgetPeriodData(budgetSubAwardBean.getProposalNumber(),budgetSubAwardBean.getVersionNumber()); \r\n \r\n //COEUSQA-4061\r\n int rowIndex = 0;\r\n if(data == null || data.size() == 0) {\r\n budgetSubAwardBean.setSubAwardNumber(1);\r\n // Added for COEUSQA-2115 : Subaward budgeting for Proposal Development - Start\r\n // Sub Award Details button will be enabled only when the periods are generated or budget has one period\r\n if(isPeriodsGenerated() || cvBudgetPeriod.size() == 1){\r\n subAwardBudget.btnSubAwardDetails.setEnabled(true);\r\n }\r\n // Added for COEUSQA-2115 : Subaward budgeting for Proposal Development - End\r\n }else{\r\n rowIndex = data.size();\r\n BudgetSubAwardBean lastBean = (BudgetSubAwardBean)data.get(rowIndex - 1);\r\n budgetSubAwardBean.setSubAwardNumber(lastBean.getSubAwardNumber() + 1);\r\n }\r\n if(!subAwardBudget.isEnabled()){\r\n subAwardBudget.btnSubAwardDetails.setEnabled(true);\r\n }\r\n data.add(budgetSubAwardBean);\r\n subAwardBudgetTableModel.fireTableRowsInserted(rowIndex, rowIndex);\r\n subAwardBudget.tblSubAwardBudget.setRowSelectionInterval(rowIndex, rowIndex);\r\n \r\n }",
"public void addFine() {\n dbRef = FirebaseDatabase.getInstance().getReference().child(\"Fines\");\n// fineObj = new FinesDetails();\n\n fineObj.setDl(this.dlNo);\n fineObj.setName(this.oName);\n fineObj.setEmail((this.oEmail).trim());\n fineObj.setContact((this.oContact).trim());\n fineObj.setAddress((this.oAddress).trim());\n fineObj.setLocation((this.oLocation).trim());\n fineObj.setOfficerId((this.userName).trim());\n fineObj.setTotal(this.fineTotal);\n fineObj.setStatus((this.status).trim());\n fineObj.setRule((this.ruleArray_list));\n fineObj.setDateTime(this.dateTime);\n\n fineId = this.currentTimeMil + this.dlNo;\n\n dbRef.child(fineId).setValue(fineObj);\n\n Toast.makeText(getApplicationContext(), \" saved\", Toast.LENGTH_SHORT).show();\n\n }",
"public void rekenAf(Dienblad dienblad, LocalDate date) {\n\n int artikelenopdienblad = getAantalArtikelenOpDienblad(dienblad);\n\n // Factuur wordt aangemaakt, deze berekent automatisch zelf de totaalprijs (ook korting).\n factuur = new Factuur(dienblad, date);\n\n System.out.println(factuur.toString());\n\n double totaalprijs = factuur.getTotaal();\n\n // Saldo wordt gecheckt, en indien toereikend wordt er geld van de klant naar de kassa overgemaakt.\n // Als saldo niet toereikend is dan vertrekt de klant zonder iets te kopen. Hoe dan ook komt hierna de volgende klant.\n EntityTransaction tx = null;\n try {\n dienblad.getKlant().getBetaalwijze().betaal(totaalprijs);\n aantalartikelen += artikelenopdienblad;\n geld += totaalprijs;\n tx = manager.getTransaction();\n tx.begin();\n manager.persist(factuur);\n } catch(TeWeinigGeldException e) {\n System.out.println(e + dienblad.getKlant().getVoornaam() + \" \" + dienblad.getKlant().getAchternaam());\n }\n if (tx != null) {\n tx.commit();\n }\n aantalklanten++;\n kassarij.naarVolgendeKlant();\n }",
"@Override\n\tpublic void addTkfl(Tkfl tkfl) {\n\t\tString sql = \"insert into tkfl values(?,?,?,?,?)\";\n\t\tthis.jdbcTemplate.update(sql,\n\t\t\t\tnew Object[] { tkfl.getId(), tkfl.getParentId(),\n\t\t\t\t\t\ttkfl.getTkmc(), tkfl.getMs(), tkfl.getPxh() });\n\t}",
"public String dateAddDaysToCurrentSystemDate(int addDays) throws NumberFormatException, IOException {\n\t\t\t\ttry{\n\t\t\t\t\tlong fingerprint = dateAddDaysToCurrentTimeMilliseconds(addDays);\t\t\t\t\n\t\t\t\t\tDateFormat dateFormat = new SimpleDateFormat(\"M/dd/yyyy\");\n\t\t\t\t\tfileWriterPrinter(\"\\nCurrent System Date: \" + dateFormat.format(new Date()));\t\t\t\t\n\t\t\t\t\tString dateToSet = dateFormat.format(new Date(fingerprint));\t\t\t\t\t\n\t\t\t\t\tfileWriterPrinter(\"Changed System Date: \" + dateToSet + \"\\n\");\n\t\t\t\t\tRuntime.getRuntime().exec(\"cmd /C date \" + dateToSet); // M/dd/yyyy\n\t\t\t\t\treturn dateToSet;\n\t\t\t\t} catch(Exception e) { fileWriterPrinter(e); return null;}\t\t\t\t\n\t\t\t}",
"public void cascadeDay(int days) {\n HashMap<String, Integer> cascadeReminders = new HashMap<>();\n HashMap<String, Integer> cascadeFollowups = new HashMap<>();\n Iterator it = reminders.entrySet().iterator();\n while (it.hasNext()) {\n HashMap.Entry pair = (HashMap.Entry) it.next();\n String key = pair.getKey().toString();\n int value = Integer.parseInt(pair.getValue().toString()) - days;\n if (value >= 0) {\n cascadeReminders.put(key, value);\n }\n it.remove();\n }\n reminders = cascadeReminders;\n\n it = followup.entrySet().iterator();\n while (it.hasNext()) {\n HashMap.Entry pair = (HashMap.Entry) it.next();\n String key = pair.getKey().toString();\n int value = Integer.parseInt(pair.getValue().toString()) - days;\n if (value >= 0) {\n cascadeFollowups.put(key, value);\n }\n it.remove();\n }\n followup = cascadeFollowups;\n }",
"static void feladat5() {\n\t}",
"public static void main(String[] args) {\n\n LocalDate today = LocalDate.now();\n System.out.println(\"today = \" + today);\n\n LocalDate tomorrow = today.plus(1, ChronoUnit.DAYS);\n System.out.println(\"tomorrow = \" + tomorrow );\n\n LocalDate yesterday = tomorrow.minusDays(2);\n System.out.println(\"yesterday = \" + yesterday);\n\n LocalDate independenceDay = LocalDate.of(2019, Month.DECEMBER, 11);\n DayOfWeek dayOfWeek = independenceDay.getDayOfWeek();\n System.out.println(\"dayOfWeek = \" + dayOfWeek);\n\n\n\n\n }",
"private void makeDeposit() {\n\t\t\r\n\t}",
"int insert(FinMonthlySnapModel record);",
"private void nextDay() {\r\n tmp.setDay(tmp.getDay() + 1);\r\n int nd = tmp.getDayOfWeek();\r\n nd++;\r\n if (nd > daysInWeek) nd -= daysInWeek;\r\n tmp.setDayOfWeek(nd);\r\n upDMYcountDMYcount();\r\n }",
"void addHasSCF(SCF newHasSCF);",
"public void setDateOfAdded(Date dateOfAdded) {\n\t\tthis.dateOfAdded = dateOfAdded;\n\t}",
"public FamilyPlanningRecord addRecord(int communityMemberId, int serviceId, Date serviceDate,double quantity){\n\t try{\n\t\t\t\n\t\t\tSimpleDateFormat dateFormat=new SimpleDateFormat(\"yyyy-MM-dd\",Locale.UK);\n\t\t\tString strDate=dateFormat.format(serviceDate);\n\t\t\treturn addRecord(communityMemberId,serviceId,strDate,quantity);\n\t\t}catch(Exception ex){\n\t\t\tclose();\n\t\t\treturn null;\n\t\t}\n\t\t\t\n\t}",
"public void calcFund(FundamentalDomain fd)\n {\n \tfd.fund[0].setLC(1, frameO, 1, frameV);\n \tfd.fund[1].set(frameO);\n \tfd.fund[2].setLC(1, frameO, 1, frameU);\n \tif(fd.det>0)\n \t\tfd.fund[3].setLC(1, frameO, 1,frameU, 2, frameV);\n \telse\n \t\tfd.fund[3].setLC(1, frameO, 2,frameU, 1, frameV);\n \tfd.numFund = 4;\n }",
"public static void Ln6() {\r\n EBAS.L6_Timestamp.setText(GtDates.ldate);\r\n \r\n EBAS.L6_First_Sku.setEnabled(false);\r\n EBAS.L6_Qty_Out.setEnabled(false);\r\n EBAS.L6_First_Desc.setEnabled(false);\r\n EBAS.L6_Orig_Sku.setEnabled(false);\r\n EBAS.L6_Orig_Desc.setEnabled(false);\r\n EBAS.L6_Orig_Attr.setEnabled(false);\r\n EBAS.L6_Orig_Size.setEnabled(false);\r\n EBAS.L6_Orig_Retail.setEnabled(false);\r\n EBAS.L6_Manuf_Inspec.setEnabled(false);\r\n EBAS.L6_New_Used.setEnabled(false);\r\n EBAS.L6_Reason_DropDown.setEnabled(false);\r\n EBAS.L6_Desc_Damage.setEnabled(false);\r\n EBAS.L6_Cust_Satisf_ChkBox.setEnabled(false);\r\n EBAS.L6_Warranty_ChkBox.setEnabled(false);\r\n \r\n try {\r\n upDB();\r\n } catch (ClassNotFoundException | SQLException ex) {\r\n Logger.getLogger(EBAS.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n }",
"static void feladat3() {\n\t}",
"@Test(timeout = 4000)\n public void test098() throws Throwable {\n DefaultDBTable defaultDBTable0 = new DefaultDBTable(\"x=&,Xbg5VGv)A%T)\");\n String[] stringArray0 = new String[3];\n DBForeignKeyConstraint dBForeignKeyConstraint0 = new DBForeignKeyConstraint((String) null, true, defaultDBTable0, stringArray0, defaultDBTable0, stringArray0);\n NameSpec nameSpec0 = NameSpec.ALWAYS;\n String string0 = SQLUtil.fkSpec(dBForeignKeyConstraint0, nameSpec0);\n assertEquals(\"FOREIGN KEY (, , ) REFERENCES x=&,Xbg5VGv)A%T)(, , )\", string0);\n }",
"public void updateDateFreezed (String email, String periodical, Timestamp newDate){\r\n try (Connection connection = jdbcUtils.getConnection();){\r\n preparedStatement = connection.prepareStatement(SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL);\r\n preparedStatement.setTimestamp(NEXTDATE_SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL_NUMBER, newDate);\r\n preparedStatement.setString(EMAIL_SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL_NUMBER, email);\r\n preparedStatement.setString(PERIODICAL_SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL_NUMBER, periodical);\r\n preparedStatement.executeUpdate();\r\n } catch (SQLException ex) {\r\n configLog.init();\r\n logger.info(LOG_SQL_EXCEPTION_MESSAGE + AdminDao.class.getName());\r\n Logger.getLogger(AdminDao.class.getName()).log(Level.SEVERE, null, ex);\r\n throw new RuntimeException();\r\n }\r\n }",
"void addIncomeToBudget();",
"void addHoliday(int y, int m, int d) {\n\t\tif (y < 1900)\n\t\t\ty += 1900;\n\t\tCalendar aHoliday = (new GregorianCalendar(y, m, d, 0, 0, 0));\n\n\t\tHoliday.add(aHoliday);\n\t}",
"@Test(expected = IllegalArgumentException.class)\n public void testAddExpenseWithFutureDate() {\n\tDefaultTableModel model = new DefaultTableModel();\n\tExpense e = new Expense(\"bread\", 8, LocalDate.of(2017, 10, 22), ExpenseType.DAILY);\n\texpenseManager.addExpense(e, model);\n }",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.DebtEntry insertNewDebts(int i);",
"public void saveJbdTravelPoint2014(JbdTravelPoint2014 jbdTravelPoint2014);",
"@Test\r\n public void testAddDays1() {\n Calendar cal = Calendar.getInstance();\r\n cal.add(Calendar.DAY_OF_MONTH, 10);\r\n System.out.println(\"The day after increment is: \" + cal.getTime());\r\n }",
"private void nextWeek() {\r\n tmp.setDay(tmp.getDay() + daysInWeek);\r\n upDMYcountDMYcount();\r\n }",
"public void mo1406f() {\n }",
"public static void insertLutenicaRecordToDB(LocalDateTime date, int quantity, String babaName){\n try {\n dbDAO.getInstance().createLutenicaRecord(date, quantity, babaName);\n System.out.println(\"Lutenica record was added to db\");\n } catch (SQLException e) {\n e.printStackTrace();\n }\n }",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.FurtherRelations addNewFurtherRelations();",
"protected void saveLocalDate() {\n\n }",
"void addStartingHadithNo(Object newStartingHadithNo);",
"public void addBuy(RightFormEvent rfe) {\n\t\tdbs.addBuy(buy);\r\n\t}",
"@Test\n\tpublic void testSetFecha7(){\n\t\tPlataforma.closePlataforma();\n\t\t\n\t\tfile = new File(\"./data/plataforma\");\n\t\tfile.delete();\n\t\tPlataforma.openPlataforma();\n\t\tPlataforma.login(\"1\", \"contraseniaprofe\");\n\t\t\n\t\tPlataforma.setFechaActual(Plataforma.fechaActual.plusDays(2));\n\t\tej1.responderEjercicio(nacho, array);\n\t\t\t\t\n\t\tLocalDate fin = Plataforma.fechaActual.plusDays(10);\n\t\tLocalDate ini = Plataforma.fechaActual.plusDays(3);\n\t\tassertTrue(ej1.setFechaFin(fin));\n\t\tassertFalse(ej1.setFechaIni(ini));\n\t}",
"org.hl7.fhir.DateTime addNewAppliesDateTime();",
"public void setEntityAddDate(String entityAddDate);"
] | [
"0.544784",
"0.538616",
"0.53826964",
"0.5362194",
"0.5269986",
"0.52122396",
"0.51971376",
"0.51924133",
"0.5145193",
"0.5134191",
"0.5091372",
"0.50747526",
"0.50718915",
"0.50715333",
"0.5051602",
"0.50423056",
"0.5039183",
"0.5024072",
"0.5009842",
"0.4972677",
"0.497093",
"0.49421346",
"0.4924334",
"0.49124044",
"0.4911916",
"0.49097943",
"0.49001443",
"0.48859894",
"0.48777524",
"0.4861029",
"0.48555642",
"0.48530594",
"0.48495504",
"0.4848732",
"0.48483893",
"0.4843495",
"0.483987",
"0.48354155",
"0.48342922",
"0.48337078",
"0.48318037",
"0.48316655",
"0.4820791",
"0.48204523",
"0.48179528",
"0.4811209",
"0.48102924",
"0.48039848",
"0.48012692",
"0.4794039",
"0.47794256",
"0.477562",
"0.47721994",
"0.47706443",
"0.47695917",
"0.47572285",
"0.4742995",
"0.47416997",
"0.4737475",
"0.47266552",
"0.4724537",
"0.4723044",
"0.4714821",
"0.47147673",
"0.4714305",
"0.47125164",
"0.47086734",
"0.4707228",
"0.4703635",
"0.47023386",
"0.47015983",
"0.4696268",
"0.4684011",
"0.46829882",
"0.4682126",
"0.46810007",
"0.46794394",
"0.46723068",
"0.46708047",
"0.46693927",
"0.4664658",
"0.46628624",
"0.46598288",
"0.46573484",
"0.4656492",
"0.46531346",
"0.46511143",
"0.4649535",
"0.46433356",
"0.4642768",
"0.46391723",
"0.4636888",
"0.46353886",
"0.46258333",
"0.4617831",
"0.46176863",
"0.46145928",
"0.4611455",
"0.46108717",
"0.46036348"
] | 0.54721093 | 0 |
MN FIXED addFKs 24 June 2014 | private void addFKs(String attrs[], int relNum)
{
//for(int i = 1; i < numOfTgtTables; i++)
//{
// add a variable number of foreign keys per table (always the first keySize attributes)
//MN fixed the errors of incorrectly generating foreign key - 24 June 2014
//for (int j = 0; j < keySize; j++)
//addFK(i, j, 0, j, false);
String[] fAttr = new String[keySize];
for(int i=0; i<keySize; i++)
fAttr[i] = attrs[i];
String[] tAttr = new String[keySize];
for (int i=0; i<keySize; i++)
tAttr [i] = m.getTargetRels().get(0).getAttrArray(i).getName();
addFK(relNum, fAttr, 0, tAttr, false);
//}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void addFKsNoReuse() \n\t{\n\t\t\tfor(int i = 1; i < numOfTgtTables; i++) \n\t\t\t{\n\t\t\t\t// add a variable number of foreign keys per table (always the first keySize attributes)\n\t\t\t\t//MN fixed the errors of incorrectly generating foreign key - 24 June 2014\n\t\t\t\t//for (int j = 0; j < keySize; j++)\n\t\t\t\t\t//addFK(i, j, 0, j, false);\n\t\t\t\tString[] fAttr = new String[keySize];\n\t\t\t\tfor(int j=0; j<keySize; j++)\n\t\t\t\t\tfAttr[j] = m.getTargetRels().get(i).getAttrArray(j).getName();\n\t\t\t\t\n\t\t\t\tString[] tAttr = new String[keySize];\n\t\t\t\tfor (int j=0; j<keySize; j++)\n\t\t\t\t\ttAttr[j] = m.getTargetRels().get(0).getAttrArray(j).getName();\n\t\t\t\t\n\t\t\t\taddFK(i, fAttr, 0, tAttr, false);\n\t\t\t}\n\t}",
"private void creatEmptyFixData() {\n fixInserts.put(ZcSettingConstants.FIX, \"上架费\");\r\n fixInserts.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixInserts.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixFVLs.put(ZcSettingConstants.FIX, \"成交费\");\r\n fixFVLs.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixFVLs.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixPayPalFees.put(ZcSettingConstants.FIX, \"paypal费\");\r\n fixPayPalFees.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixPayPalFees.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixProfits.put(ZcSettingConstants.FIX, \"利润\");\r\n fixProfits.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixProfits.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n\r\n fixProfitRates.put(ZcSettingConstants.FIX, \"利润率\");\r\n fixProfitRates.put(ZcSettingConstants.US, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.UK, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.DE, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.FR, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.CA, new BigDecimal(0));\r\n fixProfitRates.put(ZcSettingConstants.AU, new BigDecimal(0));\r\n }",
"public static void deleteEntryFromCheckinsMinor3() throws PersistenceException, ParseException {\n\t\tDate date;\n\t\tDateFormat df = new SimpleDateFormat(\"yyyy-MM-dd\");\n\t\tCalendar calendar;\n\t\tString[] dates = new String[]{\t\"2011-01-01\", \"2011-01-02\", \"2011-01-03\", \"2011-01-04\",\n\t\t \t\"2011-01-05\", \"2011-01-06\", \"2011-01-07\", \"2011-01-08\",\n\t\t \t\"2011-01-09\", \"2011-01-10\", \"2011-01-11\", \"2011-01-12\",\n\t\t \t\"2011-01-13\", \"2011-01-14\", \"2011-01-15\", \"2011-01-16\",\n\t\t \t\"2011-01-17\", \"2011-01-18\", \"2011-01-19\", \"2011-01-20\",\n\t\t\t \"2011-01-21\", \"2011-01-22\", \"2011-01-23\", \"2011-01-24\",\n\t\t\t \"2011-01-25\", \"2011-01-26\", \"2011-01-27\", \"2011-01-28\",\n\t\t\t \"2011-01-29\", \"2011-01-30\", \"2011-01-31\",\n\t\t\t \"2011-02-01\", \"2011-02-02\", \"2011-02-03\", \"2011-02-04\",\n\t\t\t \"2011-02-05\", \"2011-02-06\", \"2011-02-07\", \"2011-02-08\",\n\t\t\t \"2011-02-09\", \"2011-02-10\", \"2011-02-11\", \"2011-02-12\",\n\t\t\t \"2011-02-13\", \"2011-02-14\", \"2011-02-15\", \"2011-02-16\",\n\t\t\t \"2011-02-17\", \"2011-02-18\", \"2011-02-19\", \"2011-02-20\",\n\t\t\t \"2011-02-21\", \"2011-02-22\", \"2011-02-23\", \"2011-02-24\",\n\t\t\t \"2011-02-28\",\n\t\t\t \"2011-03-01\", \"2011-03-02\", \"2011-03-03\", \"2011-03-04\",\n\t\t\t \"2011-03-05\", \"2011-03-06\", \"2011-03-07\", \"2011-03-08\",\n\t\t\t \"2011-03-09\", \"2011-03-10\", \"2011-03-11\", \"2011-03-12\",\n\t\t\t \"2011-03-13\", \"2011-03-14\", \"2011-03-15\", \"2011-03-16\",\n\t\t\t \"2011-03-17\", \"2011-03-18\", \"2011-03-19\", \"2011-03-20\",\n\t\t\t \"2011-03-21\", \"2011-03-22\", \"2011-03-23\", \"2011-03-24\",\n\t\t\t \"2011-03-25\", \"2011-03-26\", \"2011-03-27\", \"2011-03-28\",\n\t\t\t \"2011-03-29\", \"2011-03-30\", \"2011-03-31\",\n\t\t\t \"2011-04-01\", \"2011-04-02\", \"2011-04-03\", \"2011-04-04\",\n\t\t\t \"2011-04-05\", \"2011-04-06\", \"2011-04-07\", \"2011-04-08\",\n\t\t\t \"2011-04-09\", \"2011-04-10\", \"2011-04-11\", \"2011-04-12\",\n\t\t\t \"2011-04-13\", \"2011-04-14\", \"2011-04-15\", \"2011-04-16\",\n\t\t\t \"2011-04-17\", \"2011-04-18\", \"2011-04-19\", \"2011-04-20\",\n\t\t\t \"2011-04-21\", \"2011-04-22\", \"2011-04-23\", \"2011-04-24\",\n\t\t\t \"2011-04-25\", \"2011-04-26\", \"2011-04-27\", \"2011-04-28\",\n\t\t\t \"2011-04-29\", \"2011-04-30\",\n\t\t\t \"2011-05-01\", \"2011-05-02\", \"2011-05-03\", \"2011-05-04\",\n\t\t\t \"2011-05-05\", \"2011-05-06\", \"2011-05-07\", \"2011-05-08\",\n\t\t\t \"2011-05-09\", \"2011-05-10\", \"2011-05-11\", \"2011-05-12\",\n\t\t\t \"2011-05-13\", \"2011-05-14\", \"2011-05-15\", \"2011-05-16\",\n\t\t\t \"2011-05-17\", \"2011-05-18\", \"2011-05-19\", \"2011-05-20\",\n\t\t\t \"2011-05-21\", \"2011-05-22\", \"2011-05-23\", \"2011-05-24\",\n\t\t\t \"2011-05-25\", \"2011-05-26\", \"2011-05-27\", \"2011-05-28\",\n\t\t\t \"2011-05-29\", \"2011-05-30\", \"2011-05-31\",\n\t\t\t \"2011-06-01\", \"2011-06-02\", \"2011-06-03\", \"2011-06-04\",\n\t\t\t \"2011-06-05\", \"2011-06-06\", \"2011-06-07\", \"2011-06-08\",\n\t\t\t \"2011-06-09\", \"2011-06-10\", \"2011-06-11\", \"2011-06-12\",\n\t\t\t \"2011-06-13\", \"2011-06-14\", \"2011-06-15\", \"2011-06-16\",\n\t\t\t \"2011-06-17\", \"2011-06-18\", \"2011-06-19\", \"2011-06-20\",\n\t\t\t \"2011-06-21\", \"2011-06-22\", \"2011-06-23\", \"2011-06-24\",\n\t\t\t \"2011-06-25\", \"2011-06-26\", \"2011-06-27\", \"2011-06-28\",\n\t\t\t \"2011-06-29\", \"2011-06-30\",\n\t\t\t \"2011-07-01\", \"2011-07-02\", \"2011-07-03\", \"2011-07-04\",\n\t\t\t \"2011-07-05\", \"2011-07-06\", \"2011-07-07\", \"2011-07-08\",\n\t\t\t \"2011-07-09\", \"2011-07-10\", \"2011-07-11\", \"2011-07-12\",\n\t\t\t \"2011-07-13\", \"2011-07-14\", \"2011-07-15\", \"2011-07-16\",\n\t\t\t \"2011-07-17\", \"2011-07-18\", \"2011-07-19\", \"2011-07-20\",\n\t\t\t \"2011-07-21\", \"2011-07-22\", \"2011-07-23\", \"2011-07-24\",\n\t\t\t \"2011-07-25\", \"2011-07-26\", \"2011-07-27\", \"2011-07-28\",\n\t\t\t \"2011-07-29\", \"2011-07-30\", \"2011-07-31\" };\n\t\tDataSource datasource = new DataSource();\n\t\tConnection connection = null;\n\t\tPreparedStatement statement = null;\t\t\n\t\tResultSet result = null;\n\t\ttry {\n\t\t\tconnection = datasource.getConnection();\n\t\t\tfor (String s: dates) {\n\t\t\t\tcalendar = new GregorianCalendar();\n\t\t\t\tSystem.out.print(\"Inizio: \" + calendar.get(Calendar.HOUR) + \":\" + calendar.get(Calendar.MINUTE) + \" -- s=\" + s);\n\t\t\t\tString query =\t\"select user_id \" +\n\t\t\t\t\t\t\t\t\"from \" +\n\t\t\t\t\t\t\t\t\t\"(select user_id, count(date) \" +\n\t\t\t\t\t\t\t\t\t\"from \" +\n\t\t\t\t\t\t\t\t\t\t\"(select user_id, date(date) \" +\n\t\t\t\t\t\t\t\t\t\t\"from checkins_filtered \" +\n\t\t\t\t\t\t\t\t\t\t\"where date(date) = ? \" +\n\t\t\t\t\t\t\t\t\t\t\"order by user_id) as A \" +\n\t\t\t\t\t\t\t\t\t\"group by user_id) as B \" +\n\t\t\t\t\t\t\t\t\"where count < 3\";\n\t\t\t\tstatement = connection.prepareStatement(query);\n\t\t\t\tdate = df.parse(s);\n\t\t\t\tstatement.setTimestamp(1, new java.sql.Timestamp(date.getTime()));\t\t\n\t\t\t\tresult = statement.executeQuery();\n\t\t\t\t\n\t\t\t\tString delete = \"delete from checkins_filtered where user_id = ? and date(date) = ?\";\n\t\t\t\twhile (result.next()) {\n\t\t\t\t\tstatement = connection.prepareStatement(delete);\n\t\t\t\t\tstatement.setInt(1, result.getInt(\"user_id\"));\n\t\t\t\t\tstatement.setTimestamp(2, new java.sql.Timestamp(date.getTime()));\n\t\t\t\t\tstatement.executeUpdate();\t\t\t\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\tcalendar = new GregorianCalendar();\n\t\t\t\tSystem.out.print(\" -- Fine: \" + calendar.get(Calendar.HOUR) + \":\" + calendar.get(Calendar.MINUTE));\n\t\t\t\tSystem.out.println();\n\t\t\t\tSystem.out.println();\n\t\t\t}\t\t\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t} catch (SQLException e) {\n\t\t\t\tthrow new PersistenceException(e.getMessage());\n\t\t} finally {\n\t\t\t\ttry {\n\t\t\t\t\tif (result != null)\n\t\t\t\t\t\tresult.close();\n\t\t\t\t\tif (statement != null) \n\t\t\t\t\t\tstatement.close();\n\t\t\t\t\tif (connection!= null)\n\t\t\t\t\t\tconnection.close();\n\t\t\t\t} catch (SQLException e) {\n\t\t\t\t\tthrow new PersistenceException(e.getMessage());\n\t\t\t\t}\n\t\t\t}\n\t}",
"public TableModel cacualateFixPriceFee(EbCandidateItem item) {\n EbFeeCaculaterFactory factory = EbFeeCaculaterFactory.getInstance();\r\n EbUtil ebu = new EbUtil();\r\n fixInserts.put(ZcSettingConstants.FIX, \"上架费\");\r\n fixInserts.put(\r\n ZcSettingConstants.US,\r\n factory.getFixInsertFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n fixInserts.put(\r\n ZcSettingConstants.UK,\r\n factory.getFixInsertFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n fixInserts.put(\r\n ZcSettingConstants.DE,\r\n factory.getFixInsertFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n fixInserts.put(\r\n ZcSettingConstants.FR,\r\n factory.getFixInsertFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n fixInserts.put(\r\n ZcSettingConstants.CA,\r\n factory.getFixInsertFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n fixInserts.put(\r\n ZcSettingConstants.AU,\r\n factory.getFixInsertFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n fixFVLs.put(ZcSettingConstants.FIX, \"成交费\");\r\n fixFVLs.put(\r\n ZcSettingConstants.US,\r\n factory.getFixFVLs(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.UK,\r\n factory.getFixFVLs(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.DE,\r\n factory.getFixFVLs(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.FR,\r\n factory.getFixFVLs(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.CA,\r\n factory.getFixFVLs(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA), item.getCategoryType()));\r\n fixFVLs.put(\r\n ZcSettingConstants.AU,\r\n factory.getFixFVLs(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU), item.getCategoryType()));\r\n\r\n fixPayPalFees.put(ZcSettingConstants.FIX, \"paypal费\");\r\n fixPayPalFees.put(\r\n ZcSettingConstants.US,\r\n factory.getFixPayPalFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.UK,\r\n factory.getFixPayPalFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.DE,\r\n factory.getFixPayPalFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.FR,\r\n factory.getFixPayPalFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.CA,\r\n factory.getFixPayPalFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n fixPayPalFees.put(\r\n ZcSettingConstants.AU,\r\n factory.getFixPayPalFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n fixProfits.put(ZcSettingConstants.FIX, \"利润\");\r\n fixProfitRates.put(ZcSettingConstants.FIX, \"利润率\");\r\n\r\n if (item.getCost() != null && item.getTransportFee() != null) {\r\n\r\n EbProfit profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()),\r\n ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()), item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD));\r\n fixProfits.put(ZcSettingConstants.US, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.US, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP));\r\n fixProfits.put(ZcSettingConstants.UK, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.UK, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR));\r\n fixProfits.put(ZcSettingConstants.DE, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.DE, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR));\r\n fixProfits.put(ZcSettingConstants.FR, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.FR, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD));\r\n fixProfits.put(ZcSettingConstants.CA, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.CA, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(), ebu.getRMBValue((BigDecimal) fixInserts.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) fixFVLs.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) fixPayPalFees.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD));\r\n fixProfits.put(ZcSettingConstants.AU, profit.getProfit());\r\n fixProfitRates.put(ZcSettingConstants.AU, profit.getProfitRate());\r\n }\r\n return getFixTableModel();\r\n }",
"public void setupDays() {\n\n //if(days.isEmpty()) {\n days.clear();\n int day_number = today.getActualMaximum(Calendar.DAY_OF_MONTH);\n SimpleDateFormat sdf = new SimpleDateFormat(\"EEEE\");\n SimpleDateFormat sdfMonth = new SimpleDateFormat(\"MMM\");\n today.set(Calendar.DATE, 1);\n for (int i = 1; i <= day_number; i++) {\n OrariAttivita data = new OrariAttivita();\n data.setId_utente(mActualUser.getID());\n\n //Trasformare in sql date\n java.sql.Date sqldate = new java.sql.Date(today.getTimeInMillis());\n data.setGiorno(sqldate.toString());\n\n data.setDay(i);\n data.setMonth(today.get(Calendar.MONTH) + 1);\n\n data.setDay_of_week(today.get(Calendar.DAY_OF_WEEK));\n Date date = today.getTime();\n String day_name = sdf.format(date);\n data.setDay_name(day_name);\n data.setMonth_name(sdfMonth.format(date));\n\n int indice;\n\n if (!attivitaMensili.isEmpty()) {\n if ((indice = attivitaMensili.indexOf(data)) > -1) {\n OrariAttivita temp = attivitaMensili.get(indice);\n if (temp.getOre_totali() == 0.5) {\n int occurence = Collections.frequency(attivitaMensili, temp);\n if (occurence == 2) {\n for (OrariAttivita other : attivitaMensili) {\n if (other.equals(temp) && other.getCommessa() != temp.getCommessa()) {\n data.setOtherHalf(other);\n data.getOtherHalf().setModifica(true);\n }\n }\n\n }\n }\n data.setFromOld(temp);\n data.setModifica(true);\n }\n }\n isFerie(data);\n\n\n //Aggiungi la data alla lista\n days.add(data);\n\n //Aggiugni un giorno alla data attuale\n today.add(Calendar.DATE, 1);\n }\n\n today.setTime(actualDate);\n\n mCalendarAdapter.notifyDataSetChanged();\n mCalendarList.setAdapter(mCalendarAdapter);\n showProgress(false);\n }",
"static void feladat7() {\n\t}",
"public void secondaryAddI13nDateSaving(com.hps.july.persistence.I13nDateSaving anI13nDateSaving) throws java.rmi.RemoteException;",
"public static void main(String[] args) {\r\n\t Scanner in = new Scanner(System.in);\r\n\t int d1 = in.nextInt();\r\n\t int m1 = in.nextInt();\r\n\t int y1 = in.nextInt();\r\n\t int d2 = in.nextInt();\r\n\t int m2 = in.nextInt();\r\n\t int y2 = in.nextInt();\r\n\t LocalDate returnDate=LocalDate.of(y1,m1,d1);\r\n\t LocalDate dueDate=LocalDate.of(y2,m2,d2);\r\n\t long fine=0;\r\n\t if(returnDate.isBefore(dueDate)||returnDate.equals(dueDate))fine=0;\r\n\t else if(returnDate.isAfter(dueDate)){\r\n\t \tif(returnDate.getYear()==dueDate.getYear()){\r\n\t \t\tif(returnDate.getMonth()==dueDate.getMonth()){\r\n\t \t\t\tfine=(returnDate.getDayOfYear()-dueDate.getDayOfYear())*15;\r\n\t \t\t}else{\r\n\t \t\t\t\tfine=(returnDate.getMonthValue()-dueDate.getMonthValue())*500;\r\n\t \t\t\r\n\t \t}\r\n\t \t\t\r\n\t \t\t\r\n\t } else fine=10000;\r\n\t }else fine=10000;\r\n\t System.out.println(fine);\r\n\t }",
"public void AddAvailableDates()\n\t{\n\t\ttry\n\t\t{\n\t\t\tConnector con = new Connector();\n\t\t\tString query; \n\t\t\t\n\t\t\tfor(int i = 0; i < openDates.size(); i++)\n\t\t\t{\n\t\t\t\tboolean inTable = CheckAvailableDate(openDates.get(i)); \n\t\t\t\tif(inTable == false)\n\t\t\t\t{\n\t\t\t\t\tquery = \"INSERT INTO Available(available_hid, price_per_night, startDate, endDate)\"\n\t\t\t\t\t\t\t+\" VALUE(\"+hid+\", \"+price+\", '\"+openDates.get(i).stringStart+\"', '\"+openDates.get(i).stringEnd+\"')\";\n\t\t\t\t\tint result = con.stmt.executeUpdate(query); \n\t\t\t\t}\n\t\t\t}\n\t\t\tcon.closeConnection();\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t}",
"public void addAufgabe() {\r\n this.aufgabenZahl++;\r\n }",
"public abstract void add(Date212 date);",
"public int getLBR_ProtestDays();",
"static void feladat6() {\n\t}",
"public boolean createFixedDeposit(FixedDepositDetails fdd) {\n\t\treturn true;\n\t}",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.DebtEntry addNewDebts();",
"public void addUsedUDay(Integer date) {\n pastUDays.add(date);\n }",
"int insert(AoD5e466WorkingDay record);",
"public void createBonFiscal(int idBonFiscal, Date data, float suma, int idClient) {\n\t\tif (bonFiscalOperations.checkBonFiscal(idBonFiscal) == true) {\n\t\t\tSystem.out.println(\"Bon fiscal existent!\");\n\n\t\t\tBonFiscal bonFiscal = new BonFiscal(idBonFiscal, data, suma);\n\t\t\tbonFiscal.setIdClient(idClient);\n\t\t\tList<BonFiscal> list = bonFiscalOperations.getAllBonuri();\n\t\t\tbonFiscalOperations.addBonFiscal(bonFiscal);\n\t\t\tbonFiscalOperations.printListOfBonuri(list);\n\t\t}\n\t}",
"int insertSelective(AoD5e466WorkingDay record);",
"@Test(timeout = 4000)\n public void test012() throws Throwable {\n DBSchema dBSchema0 = new DBSchema(\"truncate\");\n DefaultDBTable defaultDBTable0 = new DefaultDBTable(\"createnuniqe inde*]/$]($%;qgq`gg\", dBSchema0);\n DBForeignKeyConstraint dBForeignKeyConstraint0 = new DBForeignKeyConstraint(\"&]ZYR\", false, defaultDBTable0, (String[]) null, defaultDBTable0, (String[]) null);\n NameSpec nameSpec0 = NameSpec.ALWAYS;\n String string0 = SQLUtil.fkSpec(dBForeignKeyConstraint0, nameSpec0);\n assertEquals(\"CONSTRAINT &]ZYR FOREIGN KEY () REFERENCES createnuniqe inde*]/$]($%;qgq`gg()\", string0);\n }",
"void mo1507n();",
"public TableModel cacualateChineseFee(EbCandidateItem item) {\n EbFeeCaculaterFactory factory = EbFeeCaculaterFactory.getInstance();\r\n EbUtil ebu = new EbUtil();\r\n chineseInserts.put(ZcSettingConstants.CHINESE, \"上架费\");\r\n chineseInserts.put(\r\n ZcSettingConstants.US,\r\n factory.getChineseInsertFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n chineseInserts.put(\r\n ZcSettingConstants.UK,\r\n factory.getChineseInsertFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n chineseInserts.put(\r\n ZcSettingConstants.DE,\r\n factory.getChineseInsertFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n chineseInserts.put(\r\n ZcSettingConstants.FR,\r\n factory.getChineseInsertFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n chineseInserts.put(\r\n ZcSettingConstants.CA,\r\n factory.getChineseInsertFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n chineseInserts.put(\r\n ZcSettingConstants.AU,\r\n factory.getChineseInsertFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n chineseFVLs.put(ZcSettingConstants.CHINESE, \"成交费\");\r\n chineseFVLs.put(\r\n ZcSettingConstants.US,\r\n factory.getChineseFVLs(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.UK,\r\n factory.getChineseFVLs(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.DE,\r\n factory.getChineseFVLs(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.FR,\r\n factory.getChineseFVLs(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.CA,\r\n factory.getChineseFVLs(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA), item.getCategoryType()));\r\n chineseFVLs.put(\r\n ZcSettingConstants.AU,\r\n factory.getChineseFVLs(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU), item.getCategoryType()));\r\n\r\n chinesePayPalFees.put(ZcSettingConstants.CHINESE, \"paypal费\");\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.US,\r\n factory.getChinesePayPalFees(ZcSettingConstants.US, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.US),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.US)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.UK,\r\n factory.getChinesePayPalFees(ZcSettingConstants.UK, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.UK),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.UK)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.DE,\r\n factory.getChinesePayPalFees(ZcSettingConstants.DE, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.DE),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.DE)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.FR,\r\n factory.getChinesePayPalFees(ZcSettingConstants.FR, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.FR),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.FR)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.CA,\r\n factory.getChinesePayPalFees(ZcSettingConstants.CA, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.CA),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.CA)));\r\n chinesePayPalFees.put(\r\n ZcSettingConstants.AU,\r\n factory.getChinesePayPalFees(ZcSettingConstants.AU, ZcSettingConstants.STORE_TYPE_BASIC,\r\n ebu.getCurencyValue(item.getEbPrice(), item.getCurrencyId(), ZcSettingConstants.AU),\r\n ebu.getCurencyValue(item.getEbShippingFee(), item.getCurrencyId(), ZcSettingConstants.AU)));\r\n\r\n chineseProfits.put(ZcSettingConstants.CHINESE, \"利润\");\r\n chineseProfitRates.put(ZcSettingConstants.CHINESE, \"利润率\");\r\n if (item.getCost() != null && item.getTransportFee() != null) {\r\n\r\n EbProfit profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()),\r\n ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()), item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.US), ZcSettingConstants.CURENCY_USD));\r\n chineseProfits.put(ZcSettingConstants.US, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.US, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.UK), ZcSettingConstants.CURENCY_GBP));\r\n chineseProfits.put(ZcSettingConstants.UK, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.UK, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.DE), ZcSettingConstants.CURENCY_EUR));\r\n chineseProfits.put(ZcSettingConstants.DE, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.DE, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.FR), ZcSettingConstants.CURENCY_EUR));\r\n chineseProfits.put(ZcSettingConstants.FR, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.FR, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.CA), ZcSettingConstants.CURENCY_CAD));\r\n chineseProfits.put(ZcSettingConstants.CA, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.CA, profit.getProfitRate());\r\n\r\n profit = getProfit(ebu.getRMBValue(item.getEbPrice(), item.getCurrencyId()), ebu.getRMBValue(item.getEbShippingFee(), item.getCurrencyId()),\r\n item.getCost(), item.getTransportFee(),\r\n ebu.getRMBValue((BigDecimal) chineseInserts.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) chineseFVLs.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD),\r\n ebu.getRMBValue((BigDecimal) chinesePayPalFees.get(ZcSettingConstants.AU), ZcSettingConstants.CURENCY_AUD));\r\n chineseProfits.put(ZcSettingConstants.AU, profit.getProfit());\r\n chineseProfitRates.put(ZcSettingConstants.AU, profit.getProfitRate());\r\n }\r\n return getChineseTableModel();\r\n }",
"public void addFM(final FMTafTrend change) {\n fMs.add(change);\n }",
"protected void addDay(Date date) throws Exception {\n Calendar cal = DateHelper.newCalendarUTC();\n cal.setTime(date);\n String datecode = cal.get(Calendar.YEAR) + \"-\" + (cal.get(Calendar.MONTH) + 1) + \"-\" + cal.get(Calendar.DAY_OF_MONTH);\n affectedDays.put(datecode, date);\n Date rDate = DateHelper.roundDownLocal(date);\n datesTodo.add(rDate);\n }",
"public void payFees(int fees) {\n feesPaid += fees;\n School.updateTotalMoneyEarned(feesPaid);\n }",
"@attribute(value = \"\", required = true)\t\r\n\tpublic void addDateField(DateField f) {\r\n\t\tfields.put(\"\" + fieldCount++, f);\r\n\t}",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.FinancialStatement addNewFinancialStatements();",
"public void afegirFestius() {\n\t\t\tGregorianCalendar dia1 = new GregorianCalendar(any,0,1);\n\t\t\tint diaset = dia1.get(Calendar.DAY_OF_WEEK);\n\t\t\tif(diaset==2) diaset=6;\n\t\t\telse if(diaset==3) diaset=5;\n\t\t\telse if(diaset==4) diaset=4;\n\t\t\telse if(diaset==5) diaset=3;\n\t\t\telse if(diaset==6) diaset=2;\n\t\t\telse if(diaset==7) diaset=1;\n\t\t\telse diaset=0;\n\t\t\tfor(int i=diaset; i<cal.length; i+=7){\n\t\t\t\tcal[i].setFestiu(true);\n\t\t\t}\n\t\t\n\t}",
"public void mo35052a() {\n this.f30707l = true;\n }",
"int getNdwi6Id(String project, String feature, DataDate date) throws SQLException;",
"public void setDaysAdded(int value) {\n this.daysAdded = value;\n }",
"public void addUsedEDay(Integer date) {\n pastEDays.add(date);\n }",
"public void setFiNgayDk(Date fiNgayDk) {\n this.fiNgayDk = fiNgayDk;\n }",
"public void toPunish() {\n\n //// TODO: 24/03/2017 delete the following lines\n// dalDynamic.addRowToTable2(\"23/03/2017\",\"Thursday\",4,walkingLength,deviation)\n\n\n\n int dev,sum=0;\n long id;\n id=dalDynamic.getRecordIdAccordingToRecordName(\"minutesWalkTillEvening\");\n Calendar now = Calendar.getInstance();//today\n Calendar calendar = Calendar.getInstance();\n SimpleDateFormat dateFormat=new SimpleDateFormat(\"dd/MM/yyyy\");\n String date;\n for (int i = 0; i <DAYS_DEVIATION ; i++) {\n date=dateFormat.format(calendar.getTime());\n Log.v(\"Statistic\",\"date \"+date);\n dev = dalDynamic.getDeviationAccordingToeventTypeIdAnddate(id,date);\n sum+=dev;\n calendar.add(Calendar.DATE,-1);//// TODO: -1-i????\n }\n if(sum==DAYS_DEVIATION){\n Intent intent = new Intent(context,BlankActivity.class);\n context.startActivity(intent);\n //todo:punishment\n }\n\n }",
"@Override\n\tpublic int fees() {\n\t\treturn 25000;\n\t\t\n\t}",
"void addHasCFD(CFD newHasCFD);",
"public void addFjlx(Fjlx fx) {\n\r\n\t}",
"private void attachDatabaseReference_requested_holidays() {\n if (mChildEventListenerDaysRequested == null) {\n mChildEventListenerDaysRequested = new ChildEventListener() {\n @Override\n public void onChildAdded(DataSnapshot dataSnapshot, String s) {\n Log.v(\"***********\", \"There has beem an addition in daysRequested\");\n //List<Long> longList = (List) dataSnapshot.getValue();\n if (dataSnapshot.getKey().equals(mUserID)) {//check if it's the current user branch\n RequestedHolidays reques = new RequestedHolidays();\n //reques = dataSnapshot.getValue(RequestedHolidays.class);\n GenericTypeIndicator<List<Long>> t =\n new GenericTypeIndicator<List<Long>>() {\n };\n\n Object objecto = dataSnapshot.getValue();\n //List<Long> messages = dataSnapshot.getValue(t);\n //makeMapHash(objecto);\n //HashMap<String, Long> map = new HashMap<String, Long>();\n //map.put (1, \"Mark\");\n //map.put (2, \"Tarryn\");\n //map = (HashMap) dataSnapshot.getValue();\n //List<Long> list = new ArrayList<Long>(map.values());\n\n //List<Long> longList = (List) dataSnapshot.getValue();\n List<Long> longList = (List<Long>) dataSnapshot.getValue();\n requestedHolidays = ConvertHashToList(longList);\n Log.i(\"***********\", \"DrawMonth called in attach...requested\");\n drawMonth(workingDays, holidays, requestedHolidays, generalCalendar);\n }\n }\n\n @Override\n public void onChildChanged(DataSnapshot dataSnapshot, String s) {\n Log.i(\"***********\", \"There has beem a change in daysRequested\");\n }\n\n @Override\n public void onChildRemoved(DataSnapshot dataSnapshot) {\n Log.i(\"***********\", \"There has beem a removed in daysRequested\");\n\n }\n\n @Override\n public void onChildMoved(DataSnapshot dataSnapshot, String s) {\n Log.i(\"***********\", \"There has beem a moved in daysRequested\");\n }\n\n @Override\n public void onCancelled(DatabaseError databaseError) {\n Toast.makeText(getApplicationContext(), \"ONCANCELLED in /requested_holidays\", Toast.LENGTH_LONG).show();\n Log.i(\"***********\", \"ONCANCELLED IN /requested_holidays\");\n }\n };\n //when days are added to the requestedHolidays in the DB this will trigger\n //mDatabaseReferenceHolidays.addChildEventListener(mChildEventListenerDaysRequested);\n mDatabaseReferenceRequestedHolidays.addChildEventListener(mChildEventListenerDaysRequested);\n //mDatabaseReference.addChildEventListener(mChildEventListenerDaysRequested);\n }\n }",
"int getNdwi5Id(String project, String feature, DataDate date) throws SQLException;",
"private void addrec() {\n\t\tnmfkpinds.setPgmInd34(false);\n\t\tnmfkpinds.setPgmInd36(true);\n\t\tnmfkpinds.setPgmInd37(false);\n\t\tstateVariable.setActdsp(replaceStr(stateVariable.getActdsp(), 1, 8, \"ADDITION\"));\n\t\tstateVariable.setXwricd(\"INV\");\n\t\ttransactionTypeDescription.retrieve(stateVariable.getXwricd());\n\t\tnmfkpinds.setPgmInd99(! lastIO.isFound());\n\t\t// BR00003 Trn_Hst_Trn_Type not found on Transaction_type_description\n\t\tif (nmfkpinds.pgmInd99()) {\n\t\t\tstateVariable.setXwtdsc(all(\"-\", 20));\n\t\t}\n\t\tstateVariable.setXwa2cd(\"EAC\");\n\t\tstateVariable.setUmdes(replaceStr(stateVariable.getUmdes(), 1, 11, um[1]));\n\t\taddrec0();\n\t}",
"public void addWF(int f, int d){\n\t\tf= getIndirectAdress(f);\n\t\tint w = Worker.reg.getWReg(); \n\t\tint buf = getValFromBank(f)+w;\n\t\tint dc = (w & 15) + (getValFromBank(f) & 15);\n\t\tsetCFlag(buf);\n\t\tsetDCFlag(dc);\n\t\tbuf = buf&255;\n\t\tsetZFlag(buf);\n\t\tcheckDandInsert(buf,f,d);\n\t\tWorker.reg.increasePC();\n\t\tWorker.reg.addCycle();\n\t}",
"public void insertarPlanDieta(int id_plan_de_dieta, int caloria_max_diarias, Date fecha_Inicio, Date Fecha_fin, int n_comidas_diarias,int id_paciente,int id_nutricionista);",
"public void addDate(Date value) {\n/* 132 */ addDateToSeq(\"date\", value);\n/* */ }",
"@RequestForEnhancement(\r\n\t\t/* see also 4561444 - balance trade deficit */\r\n\t\tid=4561414,\r\n\t\tsynopsis=\"Balance the federal budget\") // after RequestForEnhancement\r\n\t@Author(\r\n\t\t//The author name\r\n\t\t@Name(first=\"Joe\", last=\"Hacker\") )\r\n\t// after Author\r\n\tpublic static void balanceFederalBudget() {\r\n\t\tthrow new UnsupportedOperationException(\"Not implemented\");\r\n\t}",
"com.synergyj.cursos.webservices.ordenes.XMLBFactura addNewXMLBFactura();",
"public com.guidewire.datamodel.ForeignkeyDocument.Foreignkey addNewForeignkey()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n com.guidewire.datamodel.ForeignkeyDocument.Foreignkey target = null;\r\n target = (com.guidewire.datamodel.ForeignkeyDocument.Foreignkey)get_store().add_element_user(FOREIGNKEY$4);\r\n return target;\r\n }\r\n }",
"@Test\n\tpublic void test() {\n\t\tfinal LocalDate referenceDate = LocalDate.of(2016, 1, 1);\n\t\tfor(int i=0; i<1000; i++) {\n\t\t\tfinal LocalDate date = referenceDate.plusDays(i);\n\n\t\t\tfinal double floatingPointDate = FloatingpointDate.getFloatingPointDateFromDate(referenceDate, date);\n\t\t\tfinal LocalDate dateFromFloat\t= FloatingpointDate.getDateFromFloatingPointDate(referenceDate, floatingPointDate);\n\n\t\t\tAssert.assertTrue(\"Roundtrip with date offset of \" + i + \" days.\", dateFromFloat.isEqual(date));\n\t\t}\n\t}",
"void addEndingHadithNo(Object newEndingHadithNo);",
"private void searchex()\n {\n try\n {\n this.dtm.setRowCount(0);\n \n String a = \"date(now())\";\n if (this.jComboBox1.getSelectedIndex() == 1) {\n a = \"DATE_ADD( date(now()),INTERVAL 10 DAY)\";\n } else if (this.jComboBox1.getSelectedIndex() == 2) {\n a = \"DATE_ADD( date(now()),INTERVAL 31 DAY)\";\n } else if (this.jComboBox1.getSelectedIndex() == 3) {\n a = \"DATE_ADD( date(now()),INTERVAL 90 DAY)\";\n } else if (this.jComboBox1.getSelectedIndex() == 4) {\n a = \"DATE_ADD( date(now()),INTERVAL 180 DAY)\";\n }\n ResultSet rs = this.d.srh(\"select * from stock inner join product on stock.product_id = product.id where exdate <= \" + a + \" and avqty > 0 order by exdate\");\n while (rs.next())\n {\n Vector v = new Vector();\n v.add(rs.getString(\"product_id\"));\n v.add(rs.getString(\"name\"));\n v.add(rs.getString(\"stock.id\"));\n v.add(Double.valueOf(rs.getDouble(\"buyprice\")));\n v.add(Double.valueOf(rs.getDouble(\"avqty\")));\n v.add(rs.getString(\"exdate\"));\n this.dtm.addRow(v);\n }\n }\n catch (Exception e)\n {\n e.printStackTrace();\n }\n }",
"public static void Ln7() {\r\n EBAS.L7_Timestamp.setText(GtDates.ldate);\r\n \r\n EBAS.L7_First_Sku.setEnabled(false);\r\n EBAS.L7_Qty_Out.setEnabled(false);\r\n EBAS.L7_First_Desc.setEnabled(false);\r\n EBAS.L7_Orig_Sku.setEnabled(false);\r\n EBAS.L7_Orig_Desc.setEnabled(false);\r\n EBAS.L7_Orig_Attr.setEnabled(false);\r\n EBAS.L7_Orig_Size.setEnabled(false);\r\n EBAS.L7_Orig_Retail.setEnabled(false);\r\n EBAS.L7_Manuf_Inspec.setEnabled(false);\r\n EBAS.L7_New_Used.setEnabled(false);\r\n EBAS.L7_Reason_DropDown.setEnabled(false);\r\n EBAS.L7_Desc_Damage.setEnabled(false);\r\n EBAS.L7_Cust_Satisf_ChkBox.setEnabled(false);\r\n EBAS.L7_Warranty_ChkBox.setEnabled(false);\r\n \r\n try {\r\n upDB();\r\n } catch (ClassNotFoundException | SQLException ex) {\r\n Logger.getLogger(EBAS.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n }",
"@Test(timeout = 4000)\n public void test011() throws Throwable {\n DefaultDBTable defaultDBTable0 = new DefaultDBTable(\"inserto\");\n String[] stringArray0 = new String[2];\n DBForeignKeyConstraint dBForeignKeyConstraint0 = new DBForeignKeyConstraint(\"4}1ngl\", false, defaultDBTable0, stringArray0, defaultDBTable0, stringArray0);\n NameSpec nameSpec0 = NameSpec.NEVER;\n String string0 = SQLUtil.fkSpec(dBForeignKeyConstraint0, nameSpec0);\n assertEquals(\"FOREIGN KEY (, ) REFERENCES inserto(, )\", string0);\n }",
"public void setDateAdded(Date dateAdded);",
"public Date getDateAdded();",
"static void feladat9() {\n\t}",
"public void dvAdded()\r\n/* 76: */ {\r\n/* 77:160 */ this.numDVRecords += 1;\r\n/* 78: */ }",
"public int getLBR_CollectionReturnDays();",
"static void feladat4() {\n\t}",
"int insertSelective(FinMonthlySnapModel record);",
"public void addNewBenificiary() {\n\t\t\tsetColBankCode(null);\n\t\t\tsetCardNumber(null);\n\t\t\tsetPopulatedDebitCardNumber(null);\n\t\t\tsetApprovalNumberCard(null);\n\t\t\tsetRemitamount(null);\n\t\t\tsetColAuthorizedby(null);\n\t\t\tsetColpassword(null);\n\t\t\tsetApprovalNumber(null);\n\t\t\tsetBooAuthozed(false);\n\t\t\tbankMasterList.clear();\n\t\t\tlocalbankList.clear();// From View V_EX_CBNK\n\t\t\tlstDebitCard.clear();\n\n\t\t\t// to fetch All Banks from View\n\t\t\t//getLocalBankListforIndicatorFromView();\n\t\t\tlocalbankList = generalService.getLocalBankListFromView(session.getCountryId());\n\n\t\t\tList<BigDecimal> duplicateCheck = new ArrayList<BigDecimal>();\n\t\t\tList<ViewBankDetails> lstofBank = new ArrayList<ViewBankDetails>();\n\t\t\tif (localbankList.size() != 0) {\n\t\t\t\tfor (ViewBankDetails lstBank : localbankList) {\n\t\t\t\t\tif (!duplicateCheck.contains(lstBank.getChequeBankId())) {\n\t\t\t\t\t\tduplicateCheck.add(lstBank.getChequeBankId());\n\t\t\t\t\t\tlstofBank.add(lstBank);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tsetBankMasterList(lstofBank);\n\t\t\tsetBooRenderSingleDebit(true);\n\t\t\tsetBooRenderMulDebit(false);\n\t\t}",
"public void m6607X() {\n try {\n HashMap hashMap = new HashMap();\n hashMap.put(\"is_rename\", \"0\");\n C1390G.m6779b(\"A107|1|3|10\", hashMap);\n HashMap hashMap2 = new HashMap();\n hashMap2.put(\"mark_num\", String.valueOf(this.f5418ga));\n C1390G.m6779b(\"A107|1|3|10\", hashMap2);\n HashMap hashMap3 = new HashMap();\n hashMap3.put(\"rec_time\", String.valueOf(this.f5420ha));\n C1390G.m6779b(\"A107|1|3|10\", hashMap3);\n } catch (Exception e) {\n C0938a.m5004b(\"SR/SoundRecorder\", \"A107|1|3|10Vcode error:\" + e);\n }\n }",
"public static void traduitSiteFrancais() {\n\t\t\n\t}",
"public void getREFDT()//get reference date\n\t{\n\t\ttry\n\t\t{\n\t\t\tDate L_strTEMP=null;\n\t\t\tM_strSQLQRY = \"Select CMT_CCSVL,CMT_CHP01,CMT_CHP02 from CO_CDTRN where CMT_CGMTP='S\"+cl_dat.M_strCMPCD_pbst+\"' and CMT_CGSTP = 'FGXXREF' and CMT_CODCD='DOCDT'\";\n\t\t\tResultSet L_rstRSSET = cl_dat.exeSQLQRY2(M_strSQLQRY);\n\t\t\tif(L_rstRSSET != null && L_rstRSSET.next())\n\t\t\t{\n\t\t\t\tstrREFDT = L_rstRSSET.getString(\"CMT_CCSVL\").trim();\n\t\t\t\tL_rstRSSET.close();\n\t\t\t\tM_calLOCAL.setTime(M_fmtLCDAT.parse(strREFDT)); // Convert Into Local Date Format\n\t\t\t\tM_calLOCAL.add(Calendar.DATE,+1); // Increase Date from +1 with Locked Date\n\t\t\t\tstrREFDT = M_fmtLCDAT.format(M_calLOCAL.getTime()); // Assign Date to Veriable \n\t\t\t\t//System.out.println(\"REFDT = \"+strREFDT);\n\t\t\t}\n\t\t}\n\t\tcatch(Exception L_EX)\n\t\t{\n\t\t\tsetMSG(L_EX,\"getREFDT\");\n\t\t}\n\t}",
"stockFilePT102.StockDocument.Stock addNewStock();",
"Long addWayBill(WayBill wayBill);",
"public int insertCohortNutritionalNeeds(CohortNutritionalNeeds dietReq) throws SQLException {\n\t\tint recordAdded = -1;\n\t\tString qryString = \"insert into imd.FEED_COHORT_NUTRITIONAL_NEEDS (ORG_ID,\"\n\t\t\t\t+ \"FEED_COHORT,\"\n\t\t\t\t+ \"START,\"\n\t\t\t\t+ \"END,\"\n\t\t\t\t+ \"DM,\"\n\t\t\t\t+ \"CP,\"\n\t\t\t\t+ \"ME,\"\n\t\t\t\t+ \"CREATED_BY,\"\n\t\t\t\t+ \"CREATED_DTTM,\"\n\t\t\t\t+ \"UPDATED_BY,\"\n\t\t\t\t+ \"UPDATED_DTTM) VALUES (?,?,?,?,?,?,?,?,?,?,?)\";\n\t\tPreparedStatement preparedStatement = null;\n\t\tConnection conn = DBManager.getDBConnection();\n\t\ttry {\n\t\t\tpreparedStatement = conn.prepareStatement(qryString);\n\t\t\tpreparedStatement.setString(1, dietReq.getOrgId());\n\t\t\tpreparedStatement.setString(2, dietReq.getFeedCohortCD());\n\t\t\tpreparedStatement.setFloat(3, dietReq.getStart());\n\t\t\tpreparedStatement.setFloat(4, dietReq.getEnd());\n\t\t\tpreparedStatement.setFloat(5, dietReq.getDryMatter());\n\t\t\tpreparedStatement.setFloat(6, dietReq.getCrudeProtein());\n\t\t\tpreparedStatement.setFloat(7, dietReq.getMetabloizableEnergy());\n\t\t\tpreparedStatement.setString(8, dietReq.getCreatedBy().getUserId());\n\t\t\tpreparedStatement.setString(9, dietReq.getCreatedDTTMSQLFormat());\n\t\t\tpreparedStatement.setString(10, dietReq.getUpdatedBy().getUserId());\n\t\t\tpreparedStatement.setString(11, dietReq.getUpdatedDTTMSQLFormat());\n\t\t\trecordAdded = preparedStatement.executeUpdate();\n\t\t} catch (java.sql.SQLIntegrityConstraintViolationException ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.KEY_INTEGRITY_VIOLATION;\n\t\t\tex.printStackTrace();\n\t\t} catch (com.mysql.cj.jdbc.exceptions.MysqlDataTruncation ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.DATA_LENGTH_ISSUE;\n\t\t\tex.printStackTrace();\n\t\t} catch (java.sql.SQLSyntaxErrorException ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.SQL_SYNTAX_ERROR;\n\t\t\tex.printStackTrace();\n\t\t} catch (java.sql.SQLException ex) {\n\t\t\trecordAdded = Util.ERROR_CODE.UNKNOWN_ERROR;\n\t\t\tex.printStackTrace();\n\t\t} catch (Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t} finally {\n\t\t try {\n\t\t\t\tif (preparedStatement != null && !preparedStatement.isClosed()) {\n\t\t\t\t\tpreparedStatement.close();\t\n\t\t\t\t}\n\t\t\t} catch (SQLException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\treturn recordAdded;\n\t}",
"private void addRow() throws CoeusException{\r\n // PDF is not mandatory\r\n// String fileName = displayPDFFileDialog();\r\n// if(fileName == null) {\r\n// //Cancelled\r\n// return ;\r\n// }\r\n \r\n BudgetSubAwardBean budgetSubAwardBean = new BudgetSubAwardBean();\r\n budgetSubAwardBean.setProposalNumber(budgetBean.getProposalNumber());\r\n budgetSubAwardBean.setVersionNumber(budgetBean.getVersionNumber());\r\n budgetSubAwardBean.setAcType(TypeConstants.INSERT_RECORD);\r\n// budgetSubAwardBean.setPdfAcType(TypeConstants.INSERT_RECORD);\r\n budgetSubAwardBean.setSubAwardStatusCode(1);\r\n // PDF is not mandatory\r\n// budgetSubAwardBean.setPdfFileName(fileName);\r\n budgetSubAwardBean.setUpdateUser(userId);\r\n //COEUSQA-4061 \r\n CoeusVector cvBudgetPeriod = new CoeusVector(); \r\n \r\n cvBudgetPeriod = getBudgetPeriodData(budgetSubAwardBean.getProposalNumber(),budgetSubAwardBean.getVersionNumber()); \r\n \r\n //COEUSQA-4061\r\n int rowIndex = 0;\r\n if(data == null || data.size() == 0) {\r\n budgetSubAwardBean.setSubAwardNumber(1);\r\n // Added for COEUSQA-2115 : Subaward budgeting for Proposal Development - Start\r\n // Sub Award Details button will be enabled only when the periods are generated or budget has one period\r\n if(isPeriodsGenerated() || cvBudgetPeriod.size() == 1){\r\n subAwardBudget.btnSubAwardDetails.setEnabled(true);\r\n }\r\n // Added for COEUSQA-2115 : Subaward budgeting for Proposal Development - End\r\n }else{\r\n rowIndex = data.size();\r\n BudgetSubAwardBean lastBean = (BudgetSubAwardBean)data.get(rowIndex - 1);\r\n budgetSubAwardBean.setSubAwardNumber(lastBean.getSubAwardNumber() + 1);\r\n }\r\n if(!subAwardBudget.isEnabled()){\r\n subAwardBudget.btnSubAwardDetails.setEnabled(true);\r\n }\r\n data.add(budgetSubAwardBean);\r\n subAwardBudgetTableModel.fireTableRowsInserted(rowIndex, rowIndex);\r\n subAwardBudget.tblSubAwardBudget.setRowSelectionInterval(rowIndex, rowIndex);\r\n \r\n }",
"public void addFine() {\n dbRef = FirebaseDatabase.getInstance().getReference().child(\"Fines\");\n// fineObj = new FinesDetails();\n\n fineObj.setDl(this.dlNo);\n fineObj.setName(this.oName);\n fineObj.setEmail((this.oEmail).trim());\n fineObj.setContact((this.oContact).trim());\n fineObj.setAddress((this.oAddress).trim());\n fineObj.setLocation((this.oLocation).trim());\n fineObj.setOfficerId((this.userName).trim());\n fineObj.setTotal(this.fineTotal);\n fineObj.setStatus((this.status).trim());\n fineObj.setRule((this.ruleArray_list));\n fineObj.setDateTime(this.dateTime);\n\n fineId = this.currentTimeMil + this.dlNo;\n\n dbRef.child(fineId).setValue(fineObj);\n\n Toast.makeText(getApplicationContext(), \" saved\", Toast.LENGTH_SHORT).show();\n\n }",
"public void rekenAf(Dienblad dienblad, LocalDate date) {\n\n int artikelenopdienblad = getAantalArtikelenOpDienblad(dienblad);\n\n // Factuur wordt aangemaakt, deze berekent automatisch zelf de totaalprijs (ook korting).\n factuur = new Factuur(dienblad, date);\n\n System.out.println(factuur.toString());\n\n double totaalprijs = factuur.getTotaal();\n\n // Saldo wordt gecheckt, en indien toereikend wordt er geld van de klant naar de kassa overgemaakt.\n // Als saldo niet toereikend is dan vertrekt de klant zonder iets te kopen. Hoe dan ook komt hierna de volgende klant.\n EntityTransaction tx = null;\n try {\n dienblad.getKlant().getBetaalwijze().betaal(totaalprijs);\n aantalartikelen += artikelenopdienblad;\n geld += totaalprijs;\n tx = manager.getTransaction();\n tx.begin();\n manager.persist(factuur);\n } catch(TeWeinigGeldException e) {\n System.out.println(e + dienblad.getKlant().getVoornaam() + \" \" + dienblad.getKlant().getAchternaam());\n }\n if (tx != null) {\n tx.commit();\n }\n aantalklanten++;\n kassarij.naarVolgendeKlant();\n }",
"@Override\n\tpublic void addTkfl(Tkfl tkfl) {\n\t\tString sql = \"insert into tkfl values(?,?,?,?,?)\";\n\t\tthis.jdbcTemplate.update(sql,\n\t\t\t\tnew Object[] { tkfl.getId(), tkfl.getParentId(),\n\t\t\t\t\t\ttkfl.getTkmc(), tkfl.getMs(), tkfl.getPxh() });\n\t}",
"public String dateAddDaysToCurrentSystemDate(int addDays) throws NumberFormatException, IOException {\n\t\t\t\ttry{\n\t\t\t\t\tlong fingerprint = dateAddDaysToCurrentTimeMilliseconds(addDays);\t\t\t\t\n\t\t\t\t\tDateFormat dateFormat = new SimpleDateFormat(\"M/dd/yyyy\");\n\t\t\t\t\tfileWriterPrinter(\"\\nCurrent System Date: \" + dateFormat.format(new Date()));\t\t\t\t\n\t\t\t\t\tString dateToSet = dateFormat.format(new Date(fingerprint));\t\t\t\t\t\n\t\t\t\t\tfileWriterPrinter(\"Changed System Date: \" + dateToSet + \"\\n\");\n\t\t\t\t\tRuntime.getRuntime().exec(\"cmd /C date \" + dateToSet); // M/dd/yyyy\n\t\t\t\t\treturn dateToSet;\n\t\t\t\t} catch(Exception e) { fileWriterPrinter(e); return null;}\t\t\t\t\n\t\t\t}",
"public void cascadeDay(int days) {\n HashMap<String, Integer> cascadeReminders = new HashMap<>();\n HashMap<String, Integer> cascadeFollowups = new HashMap<>();\n Iterator it = reminders.entrySet().iterator();\n while (it.hasNext()) {\n HashMap.Entry pair = (HashMap.Entry) it.next();\n String key = pair.getKey().toString();\n int value = Integer.parseInt(pair.getValue().toString()) - days;\n if (value >= 0) {\n cascadeReminders.put(key, value);\n }\n it.remove();\n }\n reminders = cascadeReminders;\n\n it = followup.entrySet().iterator();\n while (it.hasNext()) {\n HashMap.Entry pair = (HashMap.Entry) it.next();\n String key = pair.getKey().toString();\n int value = Integer.parseInt(pair.getValue().toString()) - days;\n if (value >= 0) {\n cascadeFollowups.put(key, value);\n }\n it.remove();\n }\n followup = cascadeFollowups;\n }",
"static void feladat5() {\n\t}",
"public static void main(String[] args) {\n\n LocalDate today = LocalDate.now();\n System.out.println(\"today = \" + today);\n\n LocalDate tomorrow = today.plus(1, ChronoUnit.DAYS);\n System.out.println(\"tomorrow = \" + tomorrow );\n\n LocalDate yesterday = tomorrow.minusDays(2);\n System.out.println(\"yesterday = \" + yesterday);\n\n LocalDate independenceDay = LocalDate.of(2019, Month.DECEMBER, 11);\n DayOfWeek dayOfWeek = independenceDay.getDayOfWeek();\n System.out.println(\"dayOfWeek = \" + dayOfWeek);\n\n\n\n\n }",
"private void makeDeposit() {\n\t\t\r\n\t}",
"int insert(FinMonthlySnapModel record);",
"private void nextDay() {\r\n tmp.setDay(tmp.getDay() + 1);\r\n int nd = tmp.getDayOfWeek();\r\n nd++;\r\n if (nd > daysInWeek) nd -= daysInWeek;\r\n tmp.setDayOfWeek(nd);\r\n upDMYcountDMYcount();\r\n }",
"void addHasSCF(SCF newHasSCF);",
"public void setDateOfAdded(Date dateOfAdded) {\n\t\tthis.dateOfAdded = dateOfAdded;\n\t}",
"public FamilyPlanningRecord addRecord(int communityMemberId, int serviceId, Date serviceDate,double quantity){\n\t try{\n\t\t\t\n\t\t\tSimpleDateFormat dateFormat=new SimpleDateFormat(\"yyyy-MM-dd\",Locale.UK);\n\t\t\tString strDate=dateFormat.format(serviceDate);\n\t\t\treturn addRecord(communityMemberId,serviceId,strDate,quantity);\n\t\t}catch(Exception ex){\n\t\t\tclose();\n\t\t\treturn null;\n\t\t}\n\t\t\t\n\t}",
"public void calcFund(FundamentalDomain fd)\n {\n \tfd.fund[0].setLC(1, frameO, 1, frameV);\n \tfd.fund[1].set(frameO);\n \tfd.fund[2].setLC(1, frameO, 1, frameU);\n \tif(fd.det>0)\n \t\tfd.fund[3].setLC(1, frameO, 1,frameU, 2, frameV);\n \telse\n \t\tfd.fund[3].setLC(1, frameO, 2,frameU, 1, frameV);\n \tfd.numFund = 4;\n }",
"public static void Ln6() {\r\n EBAS.L6_Timestamp.setText(GtDates.ldate);\r\n \r\n EBAS.L6_First_Sku.setEnabled(false);\r\n EBAS.L6_Qty_Out.setEnabled(false);\r\n EBAS.L6_First_Desc.setEnabled(false);\r\n EBAS.L6_Orig_Sku.setEnabled(false);\r\n EBAS.L6_Orig_Desc.setEnabled(false);\r\n EBAS.L6_Orig_Attr.setEnabled(false);\r\n EBAS.L6_Orig_Size.setEnabled(false);\r\n EBAS.L6_Orig_Retail.setEnabled(false);\r\n EBAS.L6_Manuf_Inspec.setEnabled(false);\r\n EBAS.L6_New_Used.setEnabled(false);\r\n EBAS.L6_Reason_DropDown.setEnabled(false);\r\n EBAS.L6_Desc_Damage.setEnabled(false);\r\n EBAS.L6_Cust_Satisf_ChkBox.setEnabled(false);\r\n EBAS.L6_Warranty_ChkBox.setEnabled(false);\r\n \r\n try {\r\n upDB();\r\n } catch (ClassNotFoundException | SQLException ex) {\r\n Logger.getLogger(EBAS.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n }",
"static void feladat3() {\n\t}",
"@Test(timeout = 4000)\n public void test098() throws Throwable {\n DefaultDBTable defaultDBTable0 = new DefaultDBTable(\"x=&,Xbg5VGv)A%T)\");\n String[] stringArray0 = new String[3];\n DBForeignKeyConstraint dBForeignKeyConstraint0 = new DBForeignKeyConstraint((String) null, true, defaultDBTable0, stringArray0, defaultDBTable0, stringArray0);\n NameSpec nameSpec0 = NameSpec.ALWAYS;\n String string0 = SQLUtil.fkSpec(dBForeignKeyConstraint0, nameSpec0);\n assertEquals(\"FOREIGN KEY (, , ) REFERENCES x=&,Xbg5VGv)A%T)(, , )\", string0);\n }",
"public void updateDateFreezed (String email, String periodical, Timestamp newDate){\r\n try (Connection connection = jdbcUtils.getConnection();){\r\n preparedStatement = connection.prepareStatement(SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL);\r\n preparedStatement.setTimestamp(NEXTDATE_SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL_NUMBER, newDate);\r\n preparedStatement.setString(EMAIL_SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL_NUMBER, email);\r\n preparedStatement.setString(PERIODICAL_SET_NEW_NEXT_DATE_TO_FOLLOWERS_SQL_NUMBER, periodical);\r\n preparedStatement.executeUpdate();\r\n } catch (SQLException ex) {\r\n configLog.init();\r\n logger.info(LOG_SQL_EXCEPTION_MESSAGE + AdminDao.class.getName());\r\n Logger.getLogger(AdminDao.class.getName()).log(Level.SEVERE, null, ex);\r\n throw new RuntimeException();\r\n }\r\n }",
"void addIncomeToBudget();",
"void addHoliday(int y, int m, int d) {\n\t\tif (y < 1900)\n\t\t\ty += 1900;\n\t\tCalendar aHoliday = (new GregorianCalendar(y, m, d, 0, 0, 0));\n\n\t\tHoliday.add(aHoliday);\n\t}",
"@Test(expected = IllegalArgumentException.class)\n public void testAddExpenseWithFutureDate() {\n\tDefaultTableModel model = new DefaultTableModel();\n\tExpense e = new Expense(\"bread\", 8, LocalDate.of(2017, 10, 22), ExpenseType.DAILY);\n\texpenseManager.addExpense(e, model);\n }",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.DebtEntry insertNewDebts(int i);",
"public void saveJbdTravelPoint2014(JbdTravelPoint2014 jbdTravelPoint2014);",
"@Test\r\n public void testAddDays1() {\n Calendar cal = Calendar.getInstance();\r\n cal.add(Calendar.DAY_OF_MONTH, 10);\r\n System.out.println(\"The day after increment is: \" + cal.getTime());\r\n }",
"private void nextWeek() {\r\n tmp.setDay(tmp.getDay() + daysInWeek);\r\n upDMYcountDMYcount();\r\n }",
"public void mo1406f() {\n }",
"public static void insertLutenicaRecordToDB(LocalDateTime date, int quantity, String babaName){\n try {\n dbDAO.getInstance().createLutenicaRecord(date, quantity, babaName);\n System.out.println(\"Lutenica record was added to db\");\n } catch (SQLException e) {\n e.printStackTrace();\n }\n }",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.FurtherRelations addNewFurtherRelations();",
"void addStartingHadithNo(Object newStartingHadithNo);",
"protected void saveLocalDate() {\n\n }",
"public void addBuy(RightFormEvent rfe) {\n\t\tdbs.addBuy(buy);\r\n\t}",
"org.hl7.fhir.DateTime addNewAppliesDateTime();",
"@Test\n\tpublic void testSetFecha7(){\n\t\tPlataforma.closePlataforma();\n\t\t\n\t\tfile = new File(\"./data/plataforma\");\n\t\tfile.delete();\n\t\tPlataforma.openPlataforma();\n\t\tPlataforma.login(\"1\", \"contraseniaprofe\");\n\t\t\n\t\tPlataforma.setFechaActual(Plataforma.fechaActual.plusDays(2));\n\t\tej1.responderEjercicio(nacho, array);\n\t\t\t\t\n\t\tLocalDate fin = Plataforma.fechaActual.plusDays(10);\n\t\tLocalDate ini = Plataforma.fechaActual.plusDays(3);\n\t\tassertTrue(ej1.setFechaFin(fin));\n\t\tassertFalse(ej1.setFechaIni(ini));\n\t}",
"public void setEntityAddDate(String entityAddDate);"
] | [
"0.5470918",
"0.544711",
"0.53869414",
"0.5381968",
"0.5362013",
"0.52125597",
"0.51981705",
"0.51926476",
"0.51457113",
"0.5135086",
"0.50925857",
"0.5074853",
"0.5071794",
"0.5070333",
"0.50521827",
"0.50441194",
"0.50389045",
"0.5023327",
"0.5009262",
"0.49720109",
"0.49710697",
"0.49423534",
"0.4925335",
"0.49134323",
"0.49116352",
"0.49103534",
"0.489953",
"0.488598",
"0.487782",
"0.48589626",
"0.4855977",
"0.4854993",
"0.48504943",
"0.48487544",
"0.48481295",
"0.4841644",
"0.48402527",
"0.48335427",
"0.4833501",
"0.4833257",
"0.4831019",
"0.4830835",
"0.4822563",
"0.48198724",
"0.48178074",
"0.48106605",
"0.48085198",
"0.48046237",
"0.4801414",
"0.47950342",
"0.47786653",
"0.47778025",
"0.47735894",
"0.4771115",
"0.47692776",
"0.4757069",
"0.47427797",
"0.47416174",
"0.47372591",
"0.47268382",
"0.47243184",
"0.47227937",
"0.47155362",
"0.47152662",
"0.4713801",
"0.47126865",
"0.4708931",
"0.47067052",
"0.47043717",
"0.47038567",
"0.47014523",
"0.46962804",
"0.4684238",
"0.46827167",
"0.4682411",
"0.46816346",
"0.46785176",
"0.4673798",
"0.46716213",
"0.46677375",
"0.46650705",
"0.46632272",
"0.4658997",
"0.46583435",
"0.46559894",
"0.46534964",
"0.46516308",
"0.4649346",
"0.4643407",
"0.46433115",
"0.4640478",
"0.46374935",
"0.46366382",
"0.46255633",
"0.46182021",
"0.46181238",
"0.46150434",
"0.4612532",
"0.46121925",
"0.4604974"
] | 0.526976 | 5 |
Created by nengneng on 2017/6/6. | public interface UserService {
ResponseEntity<?> login(String username, String password, HttpSession session); //用户登录
ResponseEntity<?> auth(String username,String password); //获取token
ResponseEntity<?> register(String username,String password); //用户注册
ResponseEntity<?> getOne(long userId);
ResponseEntity<?> getUserNumber(); //获取用户数量
ResponseEntity<?> saveAndFlush(User user);
ResponseEntity<?> getUsers();
ResponseEntity<?> changeStatus(long userId, int status);
Page<User> list(Pageable pageable);
ResponseEntity<?> search(String name);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void perish() {\n \n }",
"private stendhal() {\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"@Override\n public void init() {\n\n }",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n void init() {\n }",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n public void init() {\n }",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\n public void init() {\n\n }",
"@Override\n public void init() {\n\n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\n public void settings() {\n // TODO Auto-generated method stub\n \n }",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"private void init() {\n\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"private static void cajas() {\n\t\t\n\t}",
"@Override\n public void initialize() { \n }",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n public void init() {}",
"@Override\n protected void init() {\n }",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n public void onPostInit()\n {\n\n }",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"@Override\n\tpublic void afterInit() {\n\t\t\n\t}",
"@Override\n\tpublic void afterInit() {\n\t\t\n\t}",
"private void init() {\n\n\n\n }",
"@Override\n\tpublic void init()\n\t{\n\n\t}",
"private void poetries() {\n\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tpublic void init() {\n\t}",
"public final void mo51373a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {}",
"public void mo38117a() {\n }",
"@Override\n protected void getExras() {\n }",
"@Override\n\tpublic void einkaufen() {\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n super.init();\n\n }",
"@Override\n\tpublic void postInit() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\n public void initialize() {\n \n }",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void initialize() {}",
"@Override\n public void initialize() {}",
"@Override\n public void initialize() {}",
"Constructor() {\r\n\t\t \r\n\t }",
"public void init(){\n \n }",
"@Override\n public void init() {\n }",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"@Override\npublic void init() {\n\t\n}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"private Rekenhulp()\n\t{\n\t}",
"public void mo6081a() {\n }",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\n public void initialize() {\n\n }",
"@Override\n public void initialize() {\n\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void jugar() {\n\t\t\n\t}"
] | [
"0.63257724",
"0.6236422",
"0.61054385",
"0.605081",
"0.60470825",
"0.60281485",
"0.59948474",
"0.59700054",
"0.59700054",
"0.5948236",
"0.5899361",
"0.58991545",
"0.58988774",
"0.58789194",
"0.58788526",
"0.58788526",
"0.58679736",
"0.58592623",
"0.58582264",
"0.5839622",
"0.5839622",
"0.5827205",
"0.58269376",
"0.58233386",
"0.58115745",
"0.581142",
"0.58043647",
"0.5801977",
"0.5801977",
"0.5801977",
"0.5801977",
"0.5801977",
"0.5800524",
"0.57865536",
"0.5779265",
"0.5779265",
"0.5779265",
"0.5779265",
"0.5779265",
"0.5779265",
"0.57757425",
"0.57757425",
"0.57757425",
"0.57673275",
"0.57370144",
"0.57370144",
"0.57370144",
"0.5733124",
"0.57273036",
"0.57272846",
"0.57184595",
"0.57059026",
"0.57059026",
"0.57059026",
"0.56884134",
"0.5685938",
"0.56761557",
"0.5670106",
"0.56614035",
"0.56614035",
"0.56585586",
"0.5651274",
"0.56458837",
"0.56458837",
"0.5642358",
"0.5642048",
"0.56257737",
"0.5623996",
"0.5621127",
"0.5618404",
"0.56176203",
"0.5607928",
"0.5604563",
"0.5596801",
"0.5591866",
"0.5591525",
"0.5588083",
"0.55821824",
"0.5581336",
"0.55799586",
"0.5576139",
"0.55695",
"0.5558061",
"0.55291307",
"0.5529095",
"0.5529095",
"0.5529095",
"0.5523762",
"0.55206776",
"0.55186856",
"0.5515499",
"0.55147874",
"0.5513673",
"0.5506259",
"0.55055904",
"0.5501291",
"0.54964745",
"0.54964316",
"0.54964316",
"0.54956067",
"0.5491711"
] | 0.0 | -1 |
DA layer for access to Account | public interface AccountDao {
/**
* Get one account with accountNumber
*
* @param accountNumber unique number for account
* @return Account or null
*/
Account getAccount(Integer accountNumber);
/**
* Get one account with accountNumber
*
* @param accountNumber unique number for account
* @param configuration {@link Configuration} for executing in DB-transaction
* @return Account or null
*/
Account getAccount(Integer accountNumber, Configuration configuration);
/**
* Get all accounts for user with login
*
* @param login unique String key for user
* @return List of Account or empty List
*/
List<Account> getAccounts(String login);
/**
* Update account
*
* @param account new data to Account
* @param configuration {@link Configuration} for executing in DB-transaction
* @return new updated Account
*/
Account updateAccount(Account account, Configuration configuration);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Account getAccount();",
"public void openAccount(Account a) {}",
"public interface Account extends LrsObject {\n /**\n * The canonical home page for the system the account is on. This is based on FOAF's accountServiceHomePage.\n */\n InternationalizedResourceLocator getHomePage();\n\n /**\n * The unique id or name used to log in to this account. This is based on FOAF's accountName.\n */\n String getName();\n}",
"public abstract GDataAccount getAccount(String account) throws ServiceException;",
"public Account getAccount() {\n return account;\n }",
"public Account getAccount() {\n return account;\n }",
"Account apply();",
"public void linkAccount() {}",
"java.lang.String getAccount();",
"GlAccount getGlAccount();",
"public AccountService getAccountService(){\n return accountService;\n }",
"Account() { }",
"private GetAccount()\r\n/* 19: */ {\r\n/* 20:18 */ super(new APITag[] { APITag.ACCOUNTS }, new String[] { \"account\" });\r\n/* 21: */ }",
"public interface Account {\n\t\n//\t\n//\t\tMoney money;\n//\t\tInterestRate interestRate;\n//\t\tPeriod interestPeriod;\n\t\t\n\t\tpublic int deposit(int depositAmmount);\n//\t\t{\n//\t\t\treturn money.getMoney()+depositAmmount;\n//\t\t}\n\t\t\n\t\tpublic int withdrawl(int withdrawAmmount);\n//\t\t{\n//\t\t\treturn money.getMoney()-withdrawAmmount;\n//\t\t}\n\t\t\n\t\tpublic int getBalance();\n//\t\t{\n//\t\t\treturn money.getMoney()*interestRate.getInterestRate()*interestPeriod.getPeriod()/100;\n//\t\t}\n\t}",
"public String getAccount() {\r\n return account;\r\n }",
"public\n Account\n getAccount()\n {\n return itsAccount;\n }",
"public Account getAccount() {\r\n\t\treturn account;\r\n\t}",
"public String getAccount(){\n\t\treturn account;\n\t}",
"AccountDetail getAccount(String number) throws Exception;",
"private void consumeAccountInfo() {\n Account[] accounts = mAccountManager.getAccountsByType(ACCOUNT_TYPE);\n Account account;\n if (accounts != null && accounts.length > 0) {\n account = accounts[0];\n } else {\n account = new Account(\"\", ACCOUNT_TYPE);\n }\n mAccountManager.getAuthToken(account, AUTH_TOKEN_TYPE, null, true, authTokenCallback, null);\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public void AddToAccountInfo();",
"public LoanAccounting getAccounting();",
"@Override\r\n\tpublic void NroAccount() {\n\t\t\r\n\t}",
"public LocalAccount\t\tgetAccount();",
"public Account(Name alias) {\n this(alias, ACCOUNT);\n }",
"public String getAccount() {\r\n\t\treturn account;\r\n\t}",
"String getTradingAccount();",
"@Override\n\tpublic void credite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void showAccount() {\n\t\t\r\n\t}",
"public abstract AccountDAO getAccountDAO();",
"public interface AccountService {\n\tpublic Long getUserId(String name);\n\tpublic MessageSystem getMessageSystem();\n}",
"public boolean collectAccountInfo(IBankAPI bankAPI){\n\t}",
"public interface Account {\n\n\tpublic String getId();\n\n\tpublic String getEmail();\n\n\tpublic AccountState getState();\n\tpublic void setState(AccountState state);\n\t\n\tpublic void setEmail(String email);\n\n\tpublic String getCompanyName();\n\n\tpublic void setCompanyName(String companyName);\n\n\tpublic Name getFullName();\n\n\tpublic void setFullName(Name fullName);\n\n\tpublic Address getAddress();\n\n\tpublic void setAddress(Address address);\n\t\n\tpublic Map<String, String> getExternalAccounts();\n\t\n\tpublic void setExternalAccounts(Map<String, String> externalAccounts);\n\t\n}",
"@RequestLine(\"GET /accounts\")\n AccountList getAccountsListOfUser();",
"public AccountDataAccess() {\r\n\t\tlogger = Logger.getLogger(getClass());\r\n\t}",
"Long getAccountId();",
"public void setAccount(String account) {\n this.account = account;\n }",
"public void setAccount(String account) {\n this.account = account;\n }",
"public void setAccount(String account) {\n this.account = account;\n }",
"public void setAccount(String account) {\n this.account = account;\n }",
"public AccountInfo getAccount()\n {\n if(accountInfo == null)\n {\n System.out.println(\"You need to generate an account before getting the details.\");\n return null;\n }\n return accountInfo;\n }",
"Account getAccount(Integer accountNumber);",
"java.lang.String getAccountId();",
"java.lang.String getAccountId();",
"java.lang.String getAccountId();",
"@Override\r\n\tpublic void loginIn(Account account) throws ServiceException {\n\r\n\t}",
"public interface AccountService {\n\n Double getBalanceByDate(Long id, Date date);\n\n List<Account> getAllByUser(String mobileNumber);\n}",
"public account(int acc,int Id,String Atype,double bal ){\n this.accNo = acc;\n this.id = Id;\n this.atype = Atype;\n this.abal = bal;\n }",
"BillingAccount getBillingAccount();",
"GenerateUserAccount () {\r\n }",
"public AccountInfo getAccountInfo() {\n return accountInfo;\n }",
"public interface Account {\n /**\n * Gets the id property: Fully qualified resource Id for the resource.\n *\n * @return the id value.\n */\n String id();\n\n /**\n * Gets the name property: The name of the resource.\n *\n * @return the name value.\n */\n String name();\n\n /**\n * Gets the type property: The type of the resource.\n *\n * @return the type value.\n */\n String type();\n\n /**\n * Gets the etag property: Resource Etag.\n *\n * @return the etag value.\n */\n String etag();\n\n /**\n * Gets the kind property: The Kind of the resource.\n *\n * @return the kind value.\n */\n String kind();\n\n /**\n * Gets the sku property: The resource model definition representing SKU.\n *\n * @return the sku value.\n */\n Sku sku();\n\n /**\n * Gets the identity property: Identity for the resource.\n *\n * @return the identity value.\n */\n Identity identity();\n\n /**\n * Gets the systemData property: Metadata pertaining to creation and last modification of the resource.\n *\n * @return the systemData value.\n */\n SystemData systemData();\n\n /**\n * Gets the tags property: Resource tags.\n *\n * @return the tags value.\n */\n Map<String, String> tags();\n\n /**\n * Gets the location property: The geo-location where the resource lives.\n *\n * @return the location value.\n */\n String location();\n\n /**\n * Gets the properties property: Properties of Cognitive Services account.\n *\n * @return the properties value.\n */\n AccountProperties properties();\n\n /**\n * Gets the region of the resource.\n *\n * @return the region of the resource.\n */\n Region region();\n\n /**\n * Gets the name of the resource region.\n *\n * @return the name of the resource region.\n */\n String regionName();\n\n /**\n * Gets the name of the resource group.\n *\n * @return the name of the resource group.\n */\n String resourceGroupName();\n\n /**\n * Gets the inner com.azure.resourcemanager.cognitiveservices.fluent.models.AccountInner object.\n *\n * @return the inner object.\n */\n AccountInner innerModel();\n\n /** The entirety of the Account definition. */\n interface Definition\n extends DefinitionStages.Blank, DefinitionStages.WithResourceGroup, DefinitionStages.WithCreate {\n }\n\n /** The Account definition stages. */\n interface DefinitionStages {\n /** The first stage of the Account definition. */\n interface Blank extends WithResourceGroup {\n }\n\n /** The stage of the Account definition allowing to specify parent resource. */\n interface WithResourceGroup {\n /**\n * Specifies resourceGroupName.\n *\n * @param resourceGroupName The name of the resource group. The name is case insensitive.\n * @return the next definition stage.\n */\n WithCreate withExistingResourceGroup(String resourceGroupName);\n }\n\n /**\n * The stage of the Account definition which contains all the minimum required properties for the resource to be\n * created, but also allows for any other optional properties to be specified.\n */\n interface WithCreate\n extends DefinitionStages.WithLocation,\n DefinitionStages.WithTags,\n DefinitionStages.WithKind,\n DefinitionStages.WithSku,\n DefinitionStages.WithIdentity,\n DefinitionStages.WithProperties {\n /**\n * Executes the create request.\n *\n * @return the created resource.\n */\n Account create();\n\n /**\n * Executes the create request.\n *\n * @param context The context to associate with this operation.\n * @return the created resource.\n */\n Account create(Context context);\n }\n\n /** The stage of the Account definition allowing to specify location. */\n interface WithLocation {\n /**\n * Specifies the region for the resource.\n *\n * @param location The geo-location where the resource lives.\n * @return the next definition stage.\n */\n WithCreate withRegion(Region location);\n\n /**\n * Specifies the region for the resource.\n *\n * @param location The geo-location where the resource lives.\n * @return the next definition stage.\n */\n WithCreate withRegion(String location);\n }\n\n /** The stage of the Account definition allowing to specify tags. */\n interface WithTags {\n /**\n * Specifies the tags property: Resource tags..\n *\n * @param tags Resource tags.\n * @return the next definition stage.\n */\n WithCreate withTags(Map<String, String> tags);\n }\n\n /** The stage of the Account definition allowing to specify kind. */\n interface WithKind {\n /**\n * Specifies the kind property: The Kind of the resource..\n *\n * @param kind The Kind of the resource.\n * @return the next definition stage.\n */\n WithCreate withKind(String kind);\n }\n\n /** The stage of the Account definition allowing to specify sku. */\n interface WithSku {\n /**\n * Specifies the sku property: The resource model definition representing SKU.\n *\n * @param sku The resource model definition representing SKU.\n * @return the next definition stage.\n */\n WithCreate withSku(Sku sku);\n }\n\n /** The stage of the Account definition allowing to specify identity. */\n interface WithIdentity {\n /**\n * Specifies the identity property: Identity for the resource..\n *\n * @param identity Identity for the resource.\n * @return the next definition stage.\n */\n WithCreate withIdentity(Identity identity);\n }\n\n /** The stage of the Account definition allowing to specify properties. */\n interface WithProperties {\n /**\n * Specifies the properties property: Properties of Cognitive Services account..\n *\n * @param properties Properties of Cognitive Services account.\n * @return the next definition stage.\n */\n WithCreate withProperties(AccountProperties properties);\n }\n }\n\n /**\n * Begins update for the Account resource.\n *\n * @return the stage of resource update.\n */\n Account.Update update();\n\n /** The template for Account update. */\n interface Update\n extends UpdateStages.WithTags,\n UpdateStages.WithKind,\n UpdateStages.WithSku,\n UpdateStages.WithIdentity,\n UpdateStages.WithProperties {\n /**\n * Executes the update request.\n *\n * @return the updated resource.\n */\n Account apply();\n\n /**\n * Executes the update request.\n *\n * @param context The context to associate with this operation.\n * @return the updated resource.\n */\n Account apply(Context context);\n }\n\n /** The Account update stages. */\n interface UpdateStages {\n /** The stage of the Account update allowing to specify tags. */\n interface WithTags {\n /**\n * Specifies the tags property: Resource tags..\n *\n * @param tags Resource tags.\n * @return the next definition stage.\n */\n Update withTags(Map<String, String> tags);\n }\n\n /** The stage of the Account update allowing to specify kind. */\n interface WithKind {\n /**\n * Specifies the kind property: The Kind of the resource..\n *\n * @param kind The Kind of the resource.\n * @return the next definition stage.\n */\n Update withKind(String kind);\n }\n\n /** The stage of the Account update allowing to specify sku. */\n interface WithSku {\n /**\n * Specifies the sku property: The resource model definition representing SKU.\n *\n * @param sku The resource model definition representing SKU.\n * @return the next definition stage.\n */\n Update withSku(Sku sku);\n }\n\n /** The stage of the Account update allowing to specify identity. */\n interface WithIdentity {\n /**\n * Specifies the identity property: Identity for the resource..\n *\n * @param identity Identity for the resource.\n * @return the next definition stage.\n */\n Update withIdentity(Identity identity);\n }\n\n /** The stage of the Account update allowing to specify properties. */\n interface WithProperties {\n /**\n * Specifies the properties property: Properties of Cognitive Services account..\n *\n * @param properties Properties of Cognitive Services account.\n * @return the next definition stage.\n */\n Update withProperties(AccountProperties properties);\n }\n }\n\n /**\n * Refreshes the resource to sync with Azure.\n *\n * @return the refreshed resource.\n */\n Account refresh();\n\n /**\n * Refreshes the resource to sync with Azure.\n *\n * @param context The context to associate with this operation.\n * @return the refreshed resource.\n */\n Account refresh(Context context);\n\n /**\n * Lists the account keys for the specified Cognitive Services account.\n *\n * @param context The context to associate with this operation.\n * @throws IllegalArgumentException thrown if parameters fail the validation.\n * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.\n * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.\n * @return the access keys for the cognitive services account along with {@link Response}.\n */\n Response<ApiKeys> listKeysWithResponse(Context context);\n\n /**\n * Lists the account keys for the specified Cognitive Services account.\n *\n * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.\n * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.\n * @return the access keys for the cognitive services account.\n */\n ApiKeys listKeys();\n\n /**\n * Regenerates the specified account key for the specified Cognitive Services account.\n *\n * @param parameters regenerate key parameters.\n * @param context The context to associate with this operation.\n * @throws IllegalArgumentException thrown if parameters fail the validation.\n * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.\n * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.\n * @return the access keys for the cognitive services account along with {@link Response}.\n */\n Response<ApiKeys> regenerateKeyWithResponse(RegenerateKeyParameters parameters, Context context);\n\n /**\n * Regenerates the specified account key for the specified Cognitive Services account.\n *\n * @param parameters regenerate key parameters.\n * @throws IllegalArgumentException thrown if parameters fail the validation.\n * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.\n * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.\n * @return the access keys for the cognitive services account.\n */\n ApiKeys regenerateKey(RegenerateKeyParameters parameters);\n}",
"public void setAccount(Account account) {\n this.account = account;\n }",
"public interface AccountService {\n\n Account createAccount(Account account);\n\n AccountDto.ResponseAccount getAccountById(Long accountId);\n\n}",
"public interface AccountDAO {\n public BankAccount createAccount(String accountNumber);\n public BankAccount getAccount(String accountNumber);\n public long deposit(String accountNumber, long amount, String description);\n public long withdraw(String accountNumber, long amount, String description);\n}",
"@Override\n public void a(int n2, Account account, ahp ahp2) throws RemoteException {\n Parcel parcel = Parcel.obtain();\n Parcel parcel2 = Parcel.obtain();\n try {\n parcel.writeInterfaceToken(\"com.google.android.gms.signin.internal.ISignInService\");\n parcel.writeInt(n2);\n if (account != null) {\n parcel.writeInt(1);\n account.writeToParcel(parcel, 0);\n } else {\n parcel.writeInt(0);\n }\n IBinder iBinder = ahp2 != null ? ahp2.asBinder() : null;\n parcel.writeStrongBinder(iBinder);\n this.a.transact(8, parcel, parcel2, 0);\n parcel2.readException();\n return;\n }\n finally {\n parcel2.recycle();\n parcel.recycle();\n }\n }",
"public void addAccount(Account account,Person person);",
"public interface IAccountService {\n public TenantInfo getTenantInfo(String tenantAccount);\n public Map createUserInfo(TenantInfo tenant);\n public Map createUserDB(AdminUser adminUser,User user);\n public Map loginOfTenantInfo(TenantInfo tenant);\n public Map loginOfUser(User user);\n public Map getVerificationCode(Msg msg);\n\n}",
"public interface AccountDao {\n\n /**\n * Retrieve a specific bank account by id\n *\n * @param id the account id to retrieve\n * @return Account object representing the bank account\n */\n Account getAccount(int id);\n\n /**\n * Retrieve all accounts for a given customer\n *\n * @param customerId the customer id to lookup\n * @return list of accounts belonging to the given customer\n */\n List<Account> getAccountsForCustomerId(int customerId);\n\n /**\n * Add a new account to the data source\n *\n * Note that the account id will be automatically generated\n *\n * @param account the account information to store\n * @return generated account id\n */\n int createAccount(Account account);\n\n /**\n * Update stored information for a given account\n *\n * @param account the account to update\n */\n void updateAccount(Account account);\n}",
"Account apply(Context context);",
"public void setAccountId(String accountId) {\n this.accountId = accountId;\n }",
"public int getAccountId() {\n return accountId;\n }",
"public interface AccountService {\n void deposit(Account account, double amount);\n\n void withdraw(Account account, double amount) throws NotEnoughFundsException;\n\n void transfer(Account fromAccount, Account toAccount, double amount) throws NotEnoughFundsException;\n\n\n}",
"public interface AccountService {\n\n /**\n * 登录\n * @param mobile\n * @param password\n * @return\n */\n Account login(String mobile, String password);\n\n /**\n * 添加新部门\n * @param deptName\n */\n void saveDept (String deptName) throws ServiceException;\n\n List<Dept> findAllDept();\n\n /**\n * 根据参数查找分页后的list\n * @param map\n * @return\n */\n List<Account> pageByParam(Map<String, Object> map);\n\n /**\n * 根据deptId查找account的总数\n * @param deptId\n * @return\n */\n Long countByDeptId(Integer deptId);\n\n /**\n * 添加新员工\n * @param userName\n * @param mobile\n * @param password\n * @param deptIdArray 部门可以多选\n */\n void saveEmployee(String userName, String mobile, String password, Integer[] deptIdArray);\n\n /**\n * 根据id删除员工\n * @param id\n */\n void delEmployeeById(Integer id);\n\n /**\n * 查找所有user\n * @return\n */\n List<Account> findAllAccount();\n}",
"public void setAccount(String account) {\r\n\t\tthis.account = account;\r\n\t}",
"int createAccount(Account account);",
"public String getAccountId() {\n return this.accountId;\n }",
"public Account(String alias) {\n this(DSL.name(alias), ACCOUNT);\n }",
"public AccountManager(){\r\n allAccounts.put(\"CreditCard\",credits);\r\n allAccounts.put(\"LineOfCredit\",lineOfCredits);\r\n allAccounts.put(\"Chequing\",chequing);\r\n allAccounts.put(\"Saving\",saving);\r\n createAccount(\"3\", 0);\r\n primaryAccount = chequing[0];\r\n }",
"public Account getAccount(int accound_index){\n return accounts[accound_index];\n }",
"Account getAccount(int id);",
"public interface Accountable {\n\n public String getName();\n public Object[] getTabData();\n\n}",
"public interface BankAccountService\n{\n BankAccount openAccount(long accountNumber, Date timeCreated);\n\n BankAccount getAccount(long accountNumber);\n\n void deposit(long accountNumber, double amount, String description, Date time);\n\n List<Transaction> getTransactions(BankAccount bankAccount, Date startTime, Date endTime);\n\n void withdraw(long testAccountNumber, double amount, String description, Date time);\n\n List<Transaction> getAllTransactions(BankAccount bankAccount);\n\n List<Transaction> getLatestTransactions(BankAccount bankAccount, int total);\n}",
"public Account() {\n super();\n }",
"public interface AccountControlDataAgent {\n void loginUser(String phoneNo,String password);\n void RegisterUser(String phoneNo,String password,String name);\n}",
"void updateAccount();",
"UserAccount getUserAccountById(long id);",
"public void readAccount() throws Exception {\n\n\t\tFacebookAdaccountBuilder fbAccount = SocialEntity\n\t\t\t\t.facebookAccount(accessToken);\n\t\tfbAccount.addAccount(\"New Test AdAccount\", \"USD\", 1);\n\t\t// fbAccount.create();\n\n\t\tfbAccount.fetch(\"275668082617836\", \"name,timezone_name,users\");\n\t\t// fbAccount.fetch(\"578846975538588\");\n\t\tfor (AdAccount account : fbAccount.read()) {\n\t\t\tSystem.out.println(account.getAccountId());\n\t\t\tSystem.out.println(account.getTimezone_name());\n\t\t\tSystem.out.println(account.getName());\n\t\t\tSystem.out.println(account.getUsers().get(0).getRole());\n\t\t}\n\t}",
"public Long getAccountId() {\n return accountId;\n }",
"public Account() {\n\n\t}",
"public long getAccountId() {\n return accountId;\n }",
"public GenericDao<Account> getAccountDao();",
"public MnoAccount getAccountById(String id);",
"public account(){\n this.accNo = 000;\n this.id = 000;\n this.atype = \"\";\n this.abal = 0.00;\n }",
"public String getAccountId() {\n return accountId;\n }",
"public String getAccountId() {\n return accountId;\n }",
"public void addAccount(Person p, Account a);",
"private void loadAccount() {\n if (mSingleAccountApp == null) {\n return;\n }\n\n mSingleAccountApp.getCurrentAccountAsync(new ISingleAccountPublicClientApplication.CurrentAccountCallback() {\n @Override\n public void onAccountLoaded(@Nullable IAccount activeAccount) {\n // You can use the account data to update your UI or your app database.\n mAccount = activeAccount;\n updateUI();\n }\n\n @Override\n public void onAccountChanged(@Nullable IAccount priorAccount, @Nullable IAccount currentAccount) {\n if (currentAccount == null) {\n // Perform a cleanup task as the signed-in account changed.\n showToastOnSignOut();\n }\n }\n\n @Override\n public void onError(@NonNull MsalException exception) {\n displayError(exception);\n }\n });\n }",
"public void setAccountId(String accountId) {\n this.accountId = accountId;\n }",
"public void setAccountId(String accountId) {\n this.accountId = accountId;\n }"
] | [
"0.69053257",
"0.6790178",
"0.64661086",
"0.64269614",
"0.6404597",
"0.6404597",
"0.6390048",
"0.63707346",
"0.63478416",
"0.63133115",
"0.6248354",
"0.62457025",
"0.6233993",
"0.62316084",
"0.62293893",
"0.6213538",
"0.6211717",
"0.61708087",
"0.6159211",
"0.6150878",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6150554",
"0.6135391",
"0.61041635",
"0.60973334",
"0.609281",
"0.6061059",
"0.6057047",
"0.60507464",
"0.6046128",
"0.6031204",
"0.60161203",
"0.6003713",
"0.6001892",
"0.6001295",
"0.59697026",
"0.5969284",
"0.5963472",
"0.5952776",
"0.5952776",
"0.5952776",
"0.5952776",
"0.5936026",
"0.59347034",
"0.5932962",
"0.5932962",
"0.5932962",
"0.5927862",
"0.5926974",
"0.5916981",
"0.59137356",
"0.58895683",
"0.5886166",
"0.58817935",
"0.58630705",
"0.58566916",
"0.58418655",
"0.58410823",
"0.58375275",
"0.5834895",
"0.58260685",
"0.5826021",
"0.5824556",
"0.5807043",
"0.5805874",
"0.57993513",
"0.5780167",
"0.57748765",
"0.5764208",
"0.5762058",
"0.57596517",
"0.57594275",
"0.57572967",
"0.5752191",
"0.574637",
"0.5743922",
"0.5743062",
"0.57419187",
"0.574124",
"0.5735872",
"0.57280976",
"0.5727583",
"0.57231003",
"0.5721068",
"0.5712852",
"0.57072484",
"0.5706695",
"0.5706695",
"0.57021135",
"0.5701644",
"0.57005906",
"0.57005906"
] | 0.57295823 | 88 |
Get one account with accountNumber | Account getAccount(Integer accountNumber); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"AccountDetail getAccount(String number) throws Exception;",
"private Account getAccount( int accountNumber )\n {\n for( Account currentAccount : accounts )\n {\n if( currentAccount.getAccountNumber() == accountNumber )\n {\n return currentAccount;\n }\n \n }\n return null;\n }",
"private Account getAccount(int accountNumber) {\r\n // loop through accounts searching for matching account number\r\n for (Account currentAccount : accounts) {\r\n // return current account if match found\r\n if (currentAccount.getAccountNumber() == accountNumber) {\r\n return currentAccount;\r\n }\r\n }\r\n\r\n return null; // if no matching account was found, return null\r\n }",
"@Override\n public Account findByAccountNumber(String accountNumber) {\n Query findByAccNum = new Query();\n findByAccNum.addCriteria(Criteria.where(\"accountNumber\").is(accountNumber));\n Account found = operations.findOne(findByAccNum, Account.class);\n return found;\n }",
"java.lang.String getAccountNumber();",
"Optional<Account> findByNumber(long number);",
"AccountModel findById(String accountNumber) throws AccountException;",
"public static Account getAccount(long accountNo) {\n Account[] accounts = AccountsDB.getAccounts();\n\n Account account = null;\n // get the account from accounts using the accountNo\n\n return account;\n }",
"public Account getAccountByAccountNo(int accNo) {\n Account account = accountRepository.findByAccountNo(accNo);\n return account;\n }",
"public Account findById(String num) {\n\t\treturn null;\n\t}",
"@Override\r\n\tpublic Account findByNumber(String number) {\n\t\tString jpaQuery = \"SELECT a FROM Account a WHERE a.number = :number\";\r\n\t\tTypedQuery<Account> query = entityManager.createQuery(jpaQuery, Account.class);\r\n\t\tquery.setParameter(\"number\", number);\r\n\t\treturn getFirstResult(query);\r\n\t}",
"Account getAccount(int id);",
"public BankAccount getAccountByAccountNr(String accountNr){\n\n String sql = \"SELECT * FROM bankaccount WHERE accountnr = :accountnr\";\n Map paramMap = new HashMap();\n paramMap.put(\"accountnr\", accountNr);\n\n // check if account by given number exists\n List<BankAccount> accounts = jdbcTemplate.query(sql, paramMap, new AccountRowMapper());\n\n if(accounts.size() == 0){\n throw new ApplicationException(\"Account not found!\");\n }\n\n BankAccount result = jdbcTemplate.queryForObject(sql, paramMap, new AccountRowMapper());\n return result;\n }",
"public static Account getAccount(String accountId) {\r\n return (accounts.get(accountId));\r\n }",
"public BankAccount getBankAccount(int accountNumber) {\n\t\tString sql = \"SELECT id, name, balance, balance_saving FROM accounts WHERE id = ?\";\n\n\t\ttry (PreparedStatement pstmt = dbConnection.prepareStatement(sql)) {\n\t\t\tpstmt.setInt(1, accountNumber);\n\t\t\tResultSet rs = pstmt.executeQuery();\n\n\t\t\t// loop through the result set\n\t\t\tif (rs.next()) {\n\t\t\t\tint id = rs.getInt(\"id\");\n\t\t\t\tString name = rs.getString(\"name\");\n\t\t\t\tint checking_balance = rs.getInt(\"balance\");\n\t\t\t\tint saving_balance = rs.getInt(\"balance_saving\");\n\t\t\t\treturn new BankAccount(id, name, checking_balance, saving_balance);\n\t\t\t}\n\n\t\t} catch (SQLException e) {\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\n\t\treturn null;\n\t}",
"public Account getSpecifiedAccount(String type, int accountNumber) {\r\n /*\r\n * Here is the table :\r\n * - 1 : Credit\r\n * - 2 : LineOfCredit\r\n * - 3 : Chequing\r\n * - 4 : Saving\r\n * */\r\n System.out.println(\"Accessing account...\");\r\n Account specifiedAccount;\r\n switch (type){\r\n case \"1\":\r\n specifiedAccount = credits[accountNumber-1];\r\n break;\r\n case \"2\":\r\n specifiedAccount = lineOfCredits[accountNumber-1];\r\n break;\r\n case \"3\":\r\n specifiedAccount = chequing[accountNumber-1];\r\n break;\r\n case \"4\":\r\n specifiedAccount = saving[accountNumber-1];\r\n break;\r\n default:\r\n specifiedAccount = null;\r\n break;\r\n }\r\n return specifiedAccount;\r\n }",
"public BankAccountInterface getAccount(String accountID){\n BankAccountInterface account = null;\n for(int i = 0; i < accounts.size(); i++){\n if(accounts.get(i).getAccountID().equals(accountID)){\n account = accounts.get(i);\n break;\n } \n }\n return account;\n }",
"public Account getAccount(int index) {\n\n\t\ttry {\n\t\t\treturn accounts.get(index);\n\t\t} catch (IndexOutOfBoundsException ex) {\n\t\t\treturn null;\n\t\t}\n\t}",
"public MnoAccount getAccountById(String id);",
"public String getAccountNo();",
"public Account getAccount(int accound_index){\n return accounts[accound_index];\n }",
"java.lang.String getAccount();",
"public String getAccountNumber() {\n\t\tthis.setAccountNumber(this.account);\n\t\treturn this.account;\n\t}",
"Account getAccount();",
"public int getAccountNumber() {\n return accountNumber;\n }",
"@Override\n\tpublic Account findAccountByAccountId(int accountId) throws SQLException {\n\t\tConnection connect = db.getConnection();\n\t\tString selectQuery = \"select * from accounts where id=?\";\n\t\tPreparedStatement prepStmt = connect.prepareStatement(selectQuery);\n\t\tprepStmt.setInt(1, accountId);\n\t\tResultSet rs = prepStmt.executeQuery();\n\t\tAccount a = null;\n\t\twhile (rs.next()) {\n\t\t\ta = new Account(rs.getInt(1), rs.getString(2), rs.getDouble(3));\n\t\t}\n\t\treturn a;\n\n\t}",
"public String getAccountNumber() {\n return accountNumber;\n }",
"public String getAccountNumber() {\n return accountNumber;\n }",
"public String getAccountNumber() {\n return accountNumber;\n }",
"public Integer getAccountNumber() {\n return accountNumber;\n }",
"public Integer getAccountNumber() {\n return accountNumber;\n }",
"public BankAccount lookUp(int accountNumber){\n\t\t// create an Entry with a \"dummy\" name, zero balance and the given accountNumber\n\t\t// This \"dummy\" name will be ignored when executing getData\n\t\tBankAccount lookFor = new BankAccount(\"dummy\", accountNumber,0);\n\t\treturn (BankAccount)accountNumbersTree.findData(lookFor);\n\t}",
"UserAccount getUserAccountById(long id);",
"public Account getAccount(String address) {\n Account account = accounts.get(address);\n if (account == null) {\n account = createAccount(SHA3Util.hexToDigest(address));\n accounts.put(address, account);\n }\n return account;\n }",
"public Account getAccountByNumber(String number, boolean attachTransactions) throws SQLException {\r\n\t\tAccount account = new Account();\r\n\t\tConnection connection = dbAdministration.getConnection();\r\n\t\tStatement statement = connection.createStatement();\r\n\t\t// Datensatz von der Datenbank erhalten\r\n\t\tString sql = \"SELECT * FROM account WHERE number = '\" + number + \"'\";\r\n\t\tResultSet resultSet = statement.executeQuery(sql);\r\n\t\tlogger.info(\"SQL-Statement ausgeführt: \" + sql);\r\n\t\tif (resultSet.next()) {\r\n\t\t\t// Aus dem Datensatz ein Kontoobjekt erstellen\r\n\t\t\tint id = resultSet.getInt(1);\r\n\t\t\tString owner = resultSet.getString(2);\r\n\t\t\taccount.setId(id);\r\n\t\t\taccount.setOwner(owner);\r\n\t\t\taccount.setNumber(number);\r\n\t\t\tif (attachTransactions) {\r\n\t\t\t\t// Transaktionen an das Kontoobjekt hängen\r\n\t\t\t\taccount.setTransactions(daTransaction.getTransactionHistory(number));\r\n\t\t\t}\r\n\t\t}\r\n\t\tresultSet.close();\r\n\t\tstatement.close();\r\n\t\tconnection.close();\r\n\t\treturn account;\r\n\t}",
"public final AfAccount getAccount(String accountName) {\n return _accounts.get(accountName);\n }",
"public AccountInterface getAccount(String _address) {\n\t\tfor (AccountInterface account: accounts) {\n\t\t\tif (account.getAddress().equals(_address))\n\t\t\t\treturn account;\n\t\t}\n\t\treturn null;\t\t\n\t}",
"public Account searchAccount(String account_no)\n {\n Account account=null;\n \n try\n {\n String query=\"select * from account where account_no=\"+account_no;\n PreparedStatement ps=this.conn.prepareStatement(query);\n \n ResultSet rs=ps.executeQuery();\n \n if(rs.next())\n {\n account=new Account();\n \n account.setAccount_no(rs.getString(\"account_no\"));\n account.setAadhar_id(rs.getString(\"aadhar_no\"));\n account.setAccount_type(rs.getString(\"ac_type\"));\n account.setInterest_rate(rs.getString(\"interest\"));\n account.setBalance(rs.getString(\"balance\"));\n account.setAccount_status(rs.getString(\"ac_status\"));\n account.setName(rs.getString(\"name\"));\n }\n \n }catch(Exception e)\n {\n JOptionPane.showMessageDialog(null,e);\n }\n return account;\n }",
"public Account getAccountByAccountId(String accountId) {\n\t\treturn this.accountMapper.selectAccountByPrimaryKey(accountId);\r\n\t}",
"Account selectByPrimaryKey(Long accountid);",
"public static String getAccountNumber() {\n\t\treturn accountNumber;\n\t}",
"public String getAccountNumber() {\n\t\treturn accountNumber;\n\t}",
"public String getAccountNumber() {\n\t\treturn accountNumber;\n\t}",
"public static PhoneAccount getAccount(PhoneNumber phoneNumber){\n\t\t\treturn phoneAccounts.get(phoneNumber);\n\t}",
"public Account getAccount(byte[] address) {\n String addressAsHex = SHA3Util.digestToHex(address);\n Account account = accounts.get(addressAsHex);\n if (account == null) {\n account = createAccount(address);\n accounts.put(addressAsHex, account);\n }\n return account;\n }",
"public abstract GDataAccount getAccount(String account) throws ServiceException;",
"public BankAccount authenticateAccount(String acctNumber, String pin) {\n\t\tString sql = \"SELECT id, name, balance, balance_saving FROM accounts WHERE id = ? and pin = ?\";\n\n\t\ttry (PreparedStatement pstmt = dbConnection.prepareStatement(sql)) {\n\t\t\t// set the value\n\t\t\tint acctNumberInt = 0;\n\t\t\ttry {\n\t\t\t\tacctNumberInt = Integer.parseInt(acctNumber);\n\t\t\t} catch (NumberFormatException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tpstmt.setInt(1, acctNumberInt);\n\t\t\tpstmt.setString(2, pin);\n\n\t\t\tResultSet rs = pstmt.executeQuery();\n\n\t\t\t// loop through the result set\n\t\t\tif (rs.next()) {\n\t\t\t\tint id = rs.getInt(\"id\");\n\t\t\t\tString name = rs.getString(\"name\");\n\t\t\t\tint checking_balance = rs.getInt(\"balance\");\n\t\t\t\tint saving_balance = rs.getInt(\"balance_saving\");\n\t\t\t\treturn new BankAccount(id, name, checking_balance, saving_balance);\n\t\t\t}\n\t\t} catch (SQLException e) {\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\n\t\treturn null;\n\t}",
"String getAccountID();",
"String getAccountID();",
"public Account getExistingAccount(String accountId) {\n return this.currentBlock.getAccount(accountId);\n }",
"public int getAccountNumber() {\n\t\treturn accNum;\n\t}",
"public java.lang.String getAccountNumber() {\r\n return accountNumber;\r\n }",
"public static Account grabAccount(String playerName, String accountno) {\n\t\treturn getAccountant(playerName).getAccountByNumber(accountno);\n\t}",
"public Account getAccountByOwnerAndName(String user,String accountName);",
"public java.lang.String getAccountNumber() {\n return accountNumber;\n }",
"public Account getAccount(int accountid) {\n\t\treturn userDao.getAccount(accountid);\r\n\t}",
"Optional<Account> getAccountByUsername(String username);",
"public static Account getAccountDetails(int accountId) throws SQLException {\n boolean cdt1 = Checker.checkValidUserAccountAccountId(accountId);\n // if it is a account id, establish a connection\n if (cdt1) {\n EnumMapRolesAndAccounts map = new EnumMapRolesAndAccounts();\n map.createEnumMap();\n Connection connection = DatabaseDriverHelper.connectOrCreateDataBase();\n ResultSet results = DatabaseSelector.getAccountDetails(accountId, connection);\n while (results.next()) {\n // get the account details\n String name = results.getString(\"NAME\");\n BigDecimal balance = new BigDecimal(results.getString(\"BALANCE\"));\n // make an account class (either chequing, savings, or tfsa) based on the type\n if (DatabaseSelectHelper.getAccountType(accountId) == map.accountTypes.get(AccountTypes.CHEQUING)) {\n ChequingAccount chequing = new ChequingAccountImpl(accountId, name, balance);\n connection.close();\n return chequing;\n } else if (DatabaseSelectHelper.getAccountType(accountId) == map.accountTypes.get(AccountTypes.SAVINGS)) {\n SavingsAccount savings = new SavingsAccountImpl(accountId, name, balance);\n connection.close();\n return savings;\n } else if (DatabaseSelectHelper.getAccountType(accountId) == map.accountTypes.get(AccountTypes.TFSA)) {\n TFSA tfsa = new TFSAImpl(accountId, name, balance);\n connection.close();\n return tfsa;\n } else if (DatabaseSelectHelper.getAccountType(accountId) == map.accountTypes.get(AccountTypes.RESTRICTEDSAVING)) {\n RestrictedSavingsAccount rsa = new RestrictedSavingsAccountImpl(accountId, name, balance);\n connection.close();\n return rsa;\n } else if (DatabaseSelectHelper.getAccountType(accountId) == map.accountTypes.get(AccountTypes.BALANCEOWING)) {\n BalanceOwingAccount boa = new BalanceOwingAccountImpl(accountId, name, balance);\n connection.close();\n return boa;\n }\n }\n }\n return null;\n }",
"java.lang.String getAccountId();",
"java.lang.String getAccountId();",
"java.lang.String getAccountId();",
"public String getAccountNo() {\n return accountNo;\n }",
"@Override\n\tpublic Person getPersonByAccount(String account) {\n\t\tString hql = \"from \" + Common.TABLE_PERSON + \" where account = ?\";\n\t\tString pro[] = new String[1];\n\t\tpro[0] = account;\n\t\tPerson p = (Person) dao.loadObject(hql,pro);\n\t\tif(p != null)\n\t\t\treturn p;\n\t\treturn null;\n\t}",
"String getTradingAccount();",
"Long getAccountId();",
"Account getAccount(Long recvWindow, Long timestamp);",
"public int getAccountNo()\r\n\t{\r\n\t\t\r\n\t\treturn accountNo;\r\n\t\t\r\n\t}",
"public AccountInfo getAccount()\n {\n if(accountInfo == null)\n {\n System.out.println(\"You need to generate an account before getting the details.\");\n return null;\n }\n return accountInfo;\n }",
"public CarerAccount getAccountWithID(int search){\n\t\tCarerAccount item = null;\n\n\t\tint count = 0;\n for (int i = 0; i < CarerAccounts.size(); ++i) {\n if (CarerAccounts.get(i).getID() == search){\n\t\t\t\tcount++;\n item = CarerAccounts.get(i);\n\t\t\t}\n\t\t}\n\t\treturn item;\n\t}",
"@Override\npublic Account findById(int accountid) {\n\treturn accountdao.findById(accountid);\n}",
"@Override\n\tpublic Account getAccount(Integer id) {\n\t\tfor(Account account:accountList) {\n\t\t\tif(id.compareTo(account.returnAccountNumber()) == 0 ) {\n\t\t\t\treturn account;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn null;\n\t}",
"@GET\n @Path(\"/{accountID}\")\n @Produces(MediaType.APPLICATION_JSON)\n public Account getAccount(@PathParam(\"accountID\") int a_id ) {\n \tSystem.out.println(\"get Account by ID: \"+a_id );\n\treturn AccountService.getAccount(a_id);\n }",
"public java.lang.String getAccount_number() {\n return account_number;\n }",
"public void setAccountNo(int number){\n\t\taccountNo = number;\n\t}",
"public AccountDto getAccountFor(int cardNumber, int cardPIN) {\n Account account = repository.getAccount(cardNumber, cardPIN);\n return getAccountDtoFor(account.getAccountId());\n }",
"public Account getAccount(String username)\n\t {\n\t\t Account account = null;\n\t\t \n\t\t String columns[] = new String[] {DatabaseContract.AccountContract.COLUMN_NAME_USERNAME,\n\t\t\t\t \t\t\t\t\t\t\tDatabaseContract.AccountContract.COLUMN_NAME_BALANCE,\n\t\t\t\t \t\t\t\t\t\t\tDatabaseContract.AccountContract.COLUMN_NAME_AUTH_TOKEN};\n\t\t \n\t\t String where = DatabaseContract.AccountContract.COLUMN_NAME_USERNAME + \" = ? \";\n\t\t \n\t\t Cursor cursor = db.query(DatabaseContract.AccountContract.TABLE_NAME,\n\t\t\t\t columns,\n\t\t\t\t where,\n\t\t\t\t new String[] {username},\n\t\t\t\t null, null, null);\n\t\t\n\t\t if(cursor.getCount() > 0)\n\t\t {\n\t\t\t cursor.moveToFirst();\n\t\t\t \n\t\t\t int userCol = cursor.getColumnIndex(DatabaseContract.AccountContract.COLUMN_NAME_USERNAME);\n\t\t\t int balCol = cursor.getColumnIndex(DatabaseContract.AccountContract.COLUMN_NAME_BALANCE);\n\t\t\t int authCol = cursor.getColumnIndex(DatabaseContract.AccountContract.COLUMN_NAME_AUTH_TOKEN);\n\t\t\t \n\t\t\t String usernameString = cursor.getString(userCol);\n\t\t\t String authTokenString = cursor.getString(authCol);\n\t\t\t int balance = cursor.getInt(balCol);\n\t\t\t \n\t\t\t account = new Account(usernameString, authTokenString, balance); \n\t\t }\n\t\t \n\t\t cursor.close();\n\t\t return account;\n\t }",
"public Account findAccount() {\n Account[] accounts = accountManager.getAccountsByType(ACCOUNT_TYPE);\n\n // only one matching account - use it, and remember it for the next time.\n if (accounts.length == 1) {\n persistAccountName(accounts[0].name);\n return accounts[0];\n }\n\n // No accounts, create one and use it if created, otherwise we have no account to use\n\n if (accounts.length == 0) {\n String accountName = createAccount();\n if (accountName != null) {\n persistAccountName(accountName);\n return accountManager.getAccountsByType(ACCOUNT_TYPE)[0];\n } else {\n Log.i(LOG_TAG, \"User failed to create a valid account\");\n return null;\n }\n }\n\n // Still valid previously chosen account - use it\n\n Account account;\n String accountName = getPersistedAccountName();\n if (accountName != null && (account = chooseAccount(accountName, accounts)) != null) {\n return account;\n }\n\n // Either there is no saved account name, or our saved account vanished\n // Have the user select the account\n\n accountName = selectAccount(accounts);\n if (accountName != null) {\n persistAccountName(accountName);\n return chooseAccount(accountName, accounts);\n }\n\n // user didn't choose an account at all!\n Log.i(LOG_TAG, \"User failed to choose an account\");\n return null;\n }",
"public String getCardNumber() {\n return this.account;\n }",
"BillingAccount getBillingAccount();",
"public static String getUserAccount(String account){\n return \"select ui_account from user_information where ui_account = '\"+account+\"'\";\n }",
"public int getAccountNo() {\n\t\treturn this.accountNo;\r\n\t}",
"public int getAccountNo() {\n return accountNo;\n }",
"public String getAccount() {\r\n return account;\r\n }",
"public CarerAccount getAccountWithUsername(String search){\n\t\tCarerAccount item = null;\n\n\t\tint count = 0;\n for (int i = 0; i < CarerAccounts.size(); ++i) {\n if (CarerAccounts.get(i).getUsername().equals(search)){\n\t\t\t\tcount++;\n item = CarerAccounts.get(i);\n\t\t\t}\n\t\t}\n\t\treturn item;\n\t}",
"public Account getAccountByID(int id)//This function is for getting account for transfering amount\r\n {\r\n return this.ac.stream().filter(ac1 -> ac1.getAccId()==id).findFirst().orElse(null);\r\n }",
"public Patient getPatient(String idNumber)\n {\n Patient targetAccount = null;\n \n for (Patient account : accountsToVerify)\n {\n if (account.getIdNumber().equals(idNumber))\n {\n targetAccount = account;\n break;\n }\n }\n \n return targetAccount;\n }",
"public Account getAccount(Player p) {\n\t\tif (p == null)\n\t\t\treturn null; // safety\n\t\t// If the account is in memory, return it\n\t\tfor ( Account a : accounts) {\n\t\t\tif (a.isFor(p.getUniqueId()))\n\t\t\t\treturn a;\n\t\t}\n\t\t// spawn a new account object with default values\n\t\tAccount acct = new Account(p.getName(), p.getUniqueId());\n\t\t// load account status from yml file, if it exists\n\t\tacct.openAccount();\n\t\t// append to the bank list\n\t\taccounts.add(acct);\n\t\treturn acct;\n\t}",
"public static String getCurrentBill(String accountNumber){\n return \"select cb_bill from current_bills where cb_account = '\"+accountNumber+\"'\";\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"public String getAccount() {\n return account;\n }",
"@Override\r\n\tpublic BankAccount checkAccount(int accountNo) {\n\t\tfor (BankAccount acc : bankAccount)\r\n\t\t{\r\n\t\t\tif (acc.getAccNum() == accountNo)\r\n\t\t\t\treturn acc;\r\n\t\t}\r\n\t\t\r\n\t\treturn null;\r\n\t}",
"@Override\n\tpublic Account displayAccountDetails(int accountNo) {\n\t\treturn genericRepository.fetchById(Account.class, accountNo);\n\t}"
] | [
"0.8464238",
"0.8278287",
"0.8094078",
"0.7742639",
"0.75002456",
"0.7479184",
"0.7350438",
"0.7312385",
"0.72948843",
"0.72535276",
"0.71504086",
"0.7080233",
"0.7057111",
"0.70547855",
"0.7039471",
"0.69862235",
"0.6979657",
"0.6968448",
"0.6923725",
"0.69206846",
"0.6893179",
"0.68654984",
"0.6861237",
"0.68434674",
"0.6840647",
"0.6818792",
"0.6783674",
"0.6783674",
"0.6783674",
"0.67378414",
"0.67378414",
"0.6692747",
"0.66834354",
"0.66825634",
"0.6673344",
"0.6661927",
"0.665744",
"0.6648203",
"0.66287136",
"0.6602398",
"0.65989006",
"0.6591166",
"0.6591166",
"0.65537465",
"0.650984",
"0.6500933",
"0.648695",
"0.6486307",
"0.6486307",
"0.6451475",
"0.64469844",
"0.6438431",
"0.64330107",
"0.6425225",
"0.64224297",
"0.64167464",
"0.6400525",
"0.6387327",
"0.63800883",
"0.63800883",
"0.63800883",
"0.6376557",
"0.63606715",
"0.6359287",
"0.6345883",
"0.6338765",
"0.6322935",
"0.6311652",
"0.63023096",
"0.6298528",
"0.6295425",
"0.62931585",
"0.62841946",
"0.6276647",
"0.6267828",
"0.62667227",
"0.6262961",
"0.6257591",
"0.62540436",
"0.6241862",
"0.6235005",
"0.6230186",
"0.6212407",
"0.6186722",
"0.61853373",
"0.61828834",
"0.61717224",
"0.6170574",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6166154",
"0.6161202",
"0.61573315"
] | 0.8571854 | 0 |
Get all accounts for user with login | List<Account> getAccounts(String login); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic List<AccountDTO> getAllUser() {\n\t\treturn accountDao.getAll();\r\n\t}",
"Collection<Account> getAll();",
"@Override\n\tpublic List<Account> findAllAccounts() {\n\t\treturn m_accountDao.findAll();\n\t}",
"public List<Account> getAllAccounts() {\n List<Account> accounts = new ArrayList<>();\n accountRepository.findAll().forEach(account -> accounts.add(account));\n return accounts;\n }",
"public ArrayList<User> getAllLoggedInUser() {\n ArrayList<User> allUsers = new ArrayList<>();\n Realm realm = (mRealm == null) ? Realm.getDefaultInstance() : mRealm;\n\n try {\n RealmResults<User> allUsersInRealm = realm.where(User.class).equalTo(\"IsLoggedIn\", true).findAll();\n List<User> retval = realm.copyFromRealm(new ArrayList<>(allUsersInRealm)); // convert user to unmanaged copy\n allUsers.addAll(retval);\n } catch (Exception ex) {\n // todo handle exception\n }\n\n if (mRealm == null)\n realm.close();\n\n return allUsers;\n }",
"@Override\n\tpublic List<Account> findAll() {\n\t\treturn accountRepository.findAll();\n\t}",
"List<Account> findAll();",
"List<Account> findAll();",
"@Override\n\tpublic List<Login> findAllUsers() {\n\t\treturn userRepo.findAll();\n\t}",
"@RequestLine(\"GET /accounts\")\n AccountList getAccountsListOfUser();",
"@Override\r\n\tpublic void viewAllAccountsAllUsers() {\n\t\tas.getAllAccountsAllUsers();\r\n\t}",
"public List<Accounts> getAllAccounts() {\n List<Accounts> accountList = new ArrayList<Accounts>();\n // Select All Query\n String selectQuery = \"SELECT * FROM \" + TABLE_ACCOUNTS;\n\n SQLiteDatabase db = this.getWritableDatabase();\n Cursor cursor = db.rawQuery(selectQuery, null);\n\n // looping through all rows and adding to list\n if (cursor.moveToFirst()) {\n do {\n Accounts account = new Accounts();\n account.setID(Integer.parseInt(cursor.getString(0)));\n account.setName(cursor.getString(1));\n account.setPassword(cursor.getString(2));\n account.setPhoneNumber(cursor.getString(3));\n account.setEmail(cursor.getString(4));\n // Adding account to list\n accountList.add(account);\n } while (cursor.moveToNext());\n }\n\n // return account list\n return accountList;\n }",
"public List<Account> getListOfLoggedUsers() {\n\t\tList<Account> loggedUsers = new ArrayList<>();\n\t\tloggedUsers = adminDao.getLoggedUsers();\n\n\t\tif (loggedUsers == null) {\n\t\t\tSystem.out.println(\"There is no logged users currently!\\n\");\n\t\t\tAdminMenu.getAdminMenu();\n\t\t}\n\t\treturn loggedUsers;\n\t}",
"public ResultSet getAllAccounts () throws Exception {\r\n String sql = \"SELECT * FROM `accounts`;\";\r\n return stmt.executeQuery(sql);\r\n }",
"public List getAllUsers();",
"@GetMapping(\"/accounts\")\n public List<Account> getAccounts() {\n Iterable<Account> accounts = repository.findAll(Sort.by(\"name\"));\n return StreamSupport.stream(accounts.spliterator(), false).collect(Collectors.toList());\n }",
"public List getAllAccounts() {\n\t\treturn null;\r\n\t}",
"@Override\n\tpublic List<Account> GetAllAccounts() {\n\t\tif(accountList.size() > 0)\n\t\t\treturn accountList;\n\t\treturn null;\n\t}",
"@Override\n\tpublic List<Login> findAll() {\n\t\treturn this.loginDao.findAll();\n\t}",
"public UserAccount getUserAccountByLoginId(String loginId);",
"public List<User> getAllUsers();",
"@Override\n\tpublic List<CustomerLogin> findAllCustomerLogins() {\n\t\treturn dao.getAllCustomers();\n\t}",
"public static ArrayList<Account> getAccounts() {\n ArrayList<Account> accounts = new ArrayList<>();\n\n try (Statement statement = connection.createStatement()) {\n ResultSet resultSet = statement.executeQuery(\"SELECT * FROM LOGIN_ACCOUNTS\");\n while (resultSet.next()) { // as long as the next row is not null\n String username, password, firstName, lastName;\n int age;\n username = resultSet.getString(\"username\");\n password = resultSet.getString(\"password\");\n firstName = resultSet.getString(\"firstname\");\n lastName = resultSet.getString(\"lastname\");\n age = resultSet.getInt(\"age\");\n // place all the new items into a new Account object\n Account newAccount = new Account(username, password, firstName, lastName, age);\n // add the account to the list\n accounts.add(newAccount);\n }\n } catch (SQLException exc) {\n Logger.getLogger(Database.class.getName()).log(Level.SEVERE, null, exc);\n }\n\n return accounts;\n }",
"public List<User> getAllUsers(){\n myUsers = loginDAO.getAllUsers();\n return myUsers;\n }",
"@Override\r\n\tpublic Users queryUsers(String account) {\n\t\treturn rp.queryUsers(account);\r\n\t}",
"@RequestMapping(value = \"/all\")\n public List<Account> getAll(){\n return new ArrayList<>(accountHelper.getAllAccounts().values());\n }",
"public Set<Account> getAccountsForOwner(String username);",
"Iterable<User> getAllUsers();",
"List<Account> selectAll();",
"List<UserRepresentation> searchUserAccount(final String username);",
"List<UserRepresentation> getUsers(final String realm);",
"public List<Account> findByUserDetails(UserDetails userDetails);",
"public static List<Account> getAccounts()\n\t{\n\t\treturn Application.getAccountLibrary().getAccounts();\n\t}",
"@Override\n public List<Account> listAccounts() {\n currentCustomer.findAndUpdateAccounts();\n // return list of accounts the customer owns\n return currentCustomer.getAccounts();\n }",
"List<User> getAllUsers();",
"List<User> getAllUsers();",
"@Override\r\n\tpublic List<AppAccount> findAllAppAccounts() {\r\n\t\tlogger.debug(\"findAllAppAccounts() method started\");\r\n\t\tList<AppAccount> models = new ArrayList<AppAccount>();\r\n\t\ttry {\r\n\t\t\t// call Repository method\r\n\t\t\tList<AppAccountEntity> entities = appAccRepository.findAll();\r\n\r\n\t\t\tif (entities.isEmpty()) {\r\n\t\t\t\tlogger.warn(\"***No Accounts found in Application****\");\r\n\t\t\t} else {\r\n\t\t\t\t// convert Entities to models\r\n\t\t\t\tfor (AppAccountEntity entity : entities) {\r\n\t\t\t\t\tAppAccount model = new AppAccount();\r\n\t\t\t\t\tBeanUtils.copyProperties(entity, model);\r\n\t\t\t\t\tmodels.add(model);\r\n\t\t\t\t}\r\n\t\t\t\tlogger.info(\"All Accounts details loaded successfully\");\r\n\t\t\t}\r\n\t\t} catch (Exception e) {\r\n\t\t\tlogger.error(\"Exception occured in findAllAppAccounts()::\" + e.getMessage());\r\n\t\t}\r\n\t\tlogger.debug(\"findAllAppAccounts() method ended\");\r\n\t\treturn models;\r\n\t}",
"public List<User> listAll() throws Exception;",
"List<Account> getAccountsForCustomerId(int customerId);",
"ArrayList<String> getAccounts(Klant klant) throws SessionExpiredException, IllegalArgumentException, RemoteException;",
"public List<Account> queryAll() {\n\t\treturn null;\n\t}",
"List<UserAccount> getUserAccountListByCompany(Serializable companyId,\r\n Serializable creatorId, Serializable subsystemId);",
"@Override\r\n\tpublic List<AccountDTO> getUserByFilter(UserFilter userFilter) {\n\t\treturn accountDao.getUserByFilter(userFilter);\r\n\t}",
"@Override\n\tpublic ArrayList<User> findAll() {\n\t\t\n\t\treturn userDao.querydAll();\n\t}",
"@Override\n\tpublic List<Account> findAccountByIdUser(int id) {\n\t\treturn null;\n\t}",
"@Query(\"select a from Account a where a.role = 'ADMIN'\")\n List<Account> getAllAdminsAccount();",
"public List<UserCredential> getAllCredentials() {\n\t\t List<UserCredential> userCredentials = new ArrayList<>();\n\t\t \n\t\t credentialRepo.findAll().forEach(userCredential -> userCredentials.add(userCredential));\n\t\t \n\t\treturn userCredentials;\n\t}",
"List<KingdomUser> getAllUsers();",
"public List<AccountBean> getAllAccounts() {\n\t\tList<AccountBean> accountBeans = null;\n\t\tConnectionSource connectionSource = null;\n\t\tDao<AccountBean, Integer> contactDao = null;\n\n\t\ttry {\n\t\t\tconnectionSource = new AndroidConnectionSource(mDatabase);\n\t\t\tcontactDao = DaoManager.createDao(connectionSource,\n\t\t\t\t\tAccountBean.class);\n\t\t\taccountBeans = contactDao.queryBuilder()\n\t\t\t\t\t.orderBy(IConstants.ORDER_BY_UPDATED_AT, false).query();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn accountBeans;\n\t}",
"public List<VendUser> findAll() {\n\t\tString key=\"key_VendUser_findAll\";\r\n\t\tList<VendUser> vendUsers=(List<VendUser>)CacheUtils.get(\"userCache\", key);\r\n\t\tif(vendUsers==null){\r\n\t\t\tvendUsers=vendUserMapper.findAll();\r\n\t\t\tCacheUtils.put(\"userCache\",key, vendUsers);\r\n\t\t}\r\n\t\treturn vendUsers;\r\n\t}",
"public List<EOSUser> findUsers(List<String> logins);",
"@GetMapping()\n public List<Account> accounts(){\n List<Account> accounts = new ArrayList<>();\n //repoAccounts.forEach(accounts::add);\n accountRepository.findAll().forEach(accounts::add);\n return accounts;\n }",
"@Override\n\tpublic ArrayList<User> getUsers(ArrayList<Account> accounts) {\n\t\tArrayList<User> users=new ArrayList<User>();\n\t\tfor(int i=0;i<accounts.size();i++)\n\t\t{\n\t\t\tusers.add(usersHashtable.get(accounts.get(i)));\n\t\t}\n\t\t\n\t\treturn users;\n\t}",
"public void getAllUsers() {\n\t\t\n\t}",
"List<AccountModel> findAll();",
"public void getUserAccounts(){\n UserAccountDAO userAccountsManager = DAOFactory.getUserAccountDAO();\n //populate with values from the database\n if(!userAccountsManager.readUsersHavingResults(userAccounts)){\n //close the window due to read failure\n JOptionPane.showMessageDialog(rootPanel, \"Failed to read user accounts from database. Please check your internet connection and try again.\");\n System.exit(-4);\n }\n }",
"public List<User> getAllUsers() {\n\t\t/* begin transaction */ \n\t\tSession session = getCurrentSession(); \n\t\tsession.beginTransaction();\n\n\t\tQuery query = session.createQuery(\"from User u order by u.lastLogin DESC\");\n\t\tList<User> userList = query.list();\n\n\t\t/* commit */ \n\t\tsession.getTransaction().commit();\n\n\t\treturn userList;\n\t}",
"@Override\n\tpublic List<Account> getAllAcountsForUser(User user) {\n\t\t/* begin transaction */ \n\t\tSession session = getCurrentSession(); \n\t\tsession.beginTransaction();\n\n\t\tQuery query = session.createQuery(\"from Account where user.id=:user\");\n\t\tquery.setParameter(\"user\", user.getId()); // maybe put the id here ? \n\t\tList<Account> accountList = query.list();\n\n\t\t/* commit */ \n\t\tsession.getTransaction().commit();\n\n\t\treturn accountList;\n\t}",
"@Override\r\n\tpublic List<Map<String, Object>> findAllUser() {\n\t\treturn userMapper.findAllUser();\r\n\t}",
"@Override\n\tpublic List<Object> getAllUsers() {\n\t\tList<Object> usersList = new ArrayList<Object>();\n\t\tList<TestUser> users = dao.getAll();\n\t\tSystem.out.println(dao.exists(5));\n\t\tfor(TestUser user : users){\n\t\t\tMap<String,Object> m = new HashMap<String,Object>();\n\t\t\tm.put(\"id\", user.getId());\n\t\t\tm.put(\"name\", user.getUsername());\n\t\t\tm.put(\"pwd\", user.getPassword());\n\t\t\tJSONObject j = new JSONObject(m);\n\t\t\tusersList.add(j);\n\t\t}\n\t\treturn usersList;\n\t}",
"@Override\n\tpublic List<Account> findAll() {\n\t\treturn null;\n\t}",
"@Override\r\n public List<User> userfindAll() {\n return userMapper.userfindAll();\r\n }",
"@Override\n public List<Account> getAccounts(Long customerId) {\n return customerDao.getAccounts(customerId);\n }",
"public List<Account> getUserAccount(User user) {\n List<Account> result = new ArrayList<>();\n result = this.map.get(user);\n return result;\n }",
"@RequestMapping(\"/accounts\")\n public List<Account> getAllAccounts(){\n return accountService.getAllAccounts();\n }",
"public List<User> getAll() {\n\t\treturn service.getAll();\n\t}",
"@Override\r\n\tpublic List listAllUser() {\n\t\treturn userDAO.getUserinfoList();\r\n\t}",
"@Override\n public List<User> findAll() throws DaoException {\n log.info(\"Get all users\");\n return userDao.findAll();\n }",
"public List<User> findAll() {\n return store.findAll();\n }",
"List<User> getUsers();",
"List<User> getUsers();",
"@Override\r\n\tpublic List<User> getUsersList(String key) {\n\t\treturn loginDao.findByUsernameAndRole(key,\"USER\");\r\n\t}",
"@Override\n\tpublic List<User> getAllUsers() {\n\t\tlog.info(\"get all users!\");\n\t\treturn userRepository.findAll();\n\t}",
"public static List<User> all() \n {\n return find.all();\n }",
"java.util.List<com.heroiclabs.nakama.api.User> \n getUsersList();",
"List<User> loadActiveUsers(User user);",
"public ArrayList<UserDetail> gettingAllAvailableUsers() throws Exception;",
"public List getUsers(User user);",
"@Query(\"select ad from AccountDetail ad where ad.role = 'USER'\")\n List<AccountDetail> getAllAdminAccounts();",
"@Override\n public List<User> findAll() {\n return dao.findAll();\n }",
"public void selectAllUser() {\n String sql = \"SELECT id, user, publickey, password, salt FROM users\";\n\n try (Connection conn = this.connect();\n Statement stmt = conn.createStatement();\n ResultSet rs = stmt.executeQuery(sql)) {\n\n // loop through the result set\n while (rs.next()) {\n System.out.println(rs.getInt(\"id\") + \"\\t\" + rs.getString(\"user\") + \"\\t\" + rs.getDouble(\"publickey\")\n + \"\\t\" + rs.getString(\"password\") + \"\\t\" + rs.getString(\"salt\"));\n }\n } catch (SQLException e) {\n System.out.println(e.getMessage());\n }\n }",
"@RequestMapping(value = \"/user\", method = RequestMethod.GET)\n @PreAuthorize(\"hasRole('ADMIN')\")\n public ResponseEntity<List<UserAccount>> listAllUsers() {\n List<UserAccount> users = userAccountDetailsService.findAllUsers();\n if (users.isEmpty()) {\n return new ResponseEntity<List<UserAccount>>(HttpStatus.NO_CONTENT);//You many decide to return HttpStatus.NOT_FOUND\n }\n return new ResponseEntity<List<UserAccount>>(users, HttpStatus.OK);\n }",
"public List<User> getUsers();",
"List<KingdomUser> getUsers();",
"public List<User> getAllUsers(){\n return userRepository.findAll();\n }",
"@Override\r\n\tpublic List findAll() {\n\t\treturn usermaindao.findAll();\r\n\t}",
"public List<TbUser> getAllUsers() {\n return userRepository.findAll();\n }",
"public List<User> loadAllUserDetails()throws Exception;",
"String getAccountList(int accountId);",
"public ArrayList getAccountList() throws RemoteException, SQLException, Exception;",
"public List<User> queryAllUsers() {\n \tList<User> userList = new ArrayList<>();\n\tUser user;\n String sql = \"SELECT * FROM users\";\n\ttry {\t\n this.statement = connection.prepareStatement(sql);\n this.resultSet = this.statement.executeQuery();\n while(this.resultSet.next()) {\n\t\tuser = new User();\n user.setUserName(this.resultSet.getString(\"user_name\"));\n user.setHashedPassword(this.resultSet.getString(\"hashed_password\"));\n\t\tuser.setEmail(this.resultSet.getString(\"email\"));\n user.setHashedAnswer(this.resultSet.getString(\"hashed_answer\"));\n user.setIsActivated(this.resultSet.getInt(\"is_activated\"));\n user.setPublicKey(this.resultSet.getString(\"pubkey\"));\n\t\tuserList.add(user);\n }\t\n this.statement.close();\n\t} \n catch(SQLException ex) {\n Logger.getLogger(UserDBManager.class.getName()).log(Level.SEVERE, null, ex);\n }\n return userList;\n }",
"@Override\r\n\tpublic List<User> queryAllUsers() {\n\t\tList<User> users = userMapper.queryAllUsers();\r\n\t\treturn users;\r\n\t}",
"@Override\n public List<User> getAllUsers() {\n\n Session session = sessionFactory.openSession();\n Transaction tx = session.beginTransaction();\n List<User> hiberusers =\n session.createQuery(\"From User\").list();\n tx.commit();\n session.close();\n return hiberusers;\n }",
"List<User> getAllClients();",
"@Query(\"select a from Account a\")\n List<Account> getAllAccounts();",
"public List<TestUser> getAllUsers(){\n\t\tSystem.out.println(\"getting list of users..\");\n\t\tList<TestUser> user=new ArrayList<TestUser>();\n\t\tuserRepositary.findAll().forEach(user::add);\n\t\t//System.out.println(\"data: \"+userRepositary.FindById(\"ff80818163731aea0163731b190c0000\"));\n\t\treturn user;\n\t}",
"@Override\r\n\tpublic List<User> findAllUsers() {\n\t\treturn userDAO.findAllUsers();\r\n\t}",
"@Query(\"select a from Account a where a.role = 'Admin'\")\n List<Account> getAllAdmins();",
"public static ArrayList<AdminAccounts> getUsers() {\n return users;\n }",
"@Override\n\tpublic List<User> getAll() {\n\t\treturn userDao.getAll();\n\t}"
] | [
"0.7379987",
"0.710506",
"0.6919115",
"0.6909216",
"0.68929327",
"0.68928826",
"0.6842814",
"0.6842814",
"0.68127024",
"0.68104964",
"0.6784805",
"0.6770508",
"0.6747536",
"0.67350686",
"0.66938925",
"0.6677502",
"0.6673529",
"0.66595227",
"0.6656679",
"0.66285443",
"0.6607323",
"0.66045785",
"0.65917987",
"0.6567601",
"0.6553193",
"0.6551317",
"0.65446955",
"0.65323573",
"0.6515144",
"0.65043736",
"0.6503558",
"0.6499035",
"0.64989704",
"0.6496344",
"0.64923406",
"0.64923406",
"0.6478743",
"0.6450566",
"0.6432915",
"0.6424055",
"0.6419864",
"0.64041907",
"0.64006674",
"0.63838714",
"0.6383797",
"0.63785934",
"0.63640046",
"0.635737",
"0.6333039",
"0.6315618",
"0.6313418",
"0.63122916",
"0.63109493",
"0.6300369",
"0.6293552",
"0.62782305",
"0.6276746",
"0.6266647",
"0.62614155",
"0.6247822",
"0.6247395",
"0.62457263",
"0.6230722",
"0.6223286",
"0.6217396",
"0.620691",
"0.6195658",
"0.619194",
"0.6189004",
"0.61874205",
"0.61874205",
"0.6180659",
"0.6176243",
"0.61565405",
"0.61537385",
"0.61519724",
"0.6151642",
"0.61515796",
"0.61443394",
"0.61440825",
"0.6141092",
"0.6135814",
"0.6129702",
"0.6129227",
"0.61285716",
"0.61234534",
"0.6121984",
"0.6118531",
"0.61087775",
"0.6104019",
"0.61016226",
"0.6098005",
"0.6090322",
"0.6085557",
"0.6083984",
"0.60838944",
"0.60777074",
"0.6077607",
"0.6076537",
"0.60747063"
] | 0.8038137 | 0 |
turns on vision then tracks | public AutoVisionTurretCommand() {
addParallel(new VisionCommand(), 5);
addSequential(new DelayedAimCommand());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void turn_on () {\n this.on = true;\n }",
"public void setTurned(){\n\tIS_TURNED = true;\n\tvimage = turnedVimImage;\n }",
"public void turnOn() {\n\t\tisOn = true;\n\t}",
"public void turnOn( ) {\n\t\t\t\tSystem.out.println(\"Light is on \");\n\t\t}",
"private void turnOnCamera() {\n // play sound\n playSound();\n isCameraOn = true;\n turnOffFlash();\n strobo.setChecked(false);\n previewCamera();\n toggleButtonImageCamera();\n }",
"public void turnOn() {\n\t\tOn = true;\n\t}",
"@Override\n\tpublic void turnOn() {\n\n\t}",
"public void turnOn(){\n Logger.getGlobal().log(Level.INFO,\" Turning On..\");\n vendingMachine = new VendingMachine();\n inventoryPopulation();\n idle();\n }",
"void onTurn();",
"public void turnOn() {\n this.status = true;\n update(this.redValue, this.greenValue, this.blueValue);\n }",
"public void playCvC() {\n isAI[0] = true;\n isAI[1] = true;\n players[0] = new AI();\n players[1] = new AI();\n playerShips[0] = players[0].getShipList();\n playerShips[1] = players[1].getShipList();\n grids[0] = new Grid();\n grids[1] = new Grid();\n currentPlayer = 0;\n playGame();\n }",
"@Override\n public void turnOnEngine() {\n engine.on();\n System.out.println(\"Engine is turned on.\");\n }",
"private void inAvanti() {\n\t\tif (Game.getInstance().isOnGround) {\n\t\t\tjump=false;\n\t\t\tGame.getInstance().getPersonaggio().setStato(Protagonista.RUN);\n\t\t\tGraficaProtagonista.getInstance().cambiaAnimazioni(Protagonista.RUN);\n\t\t}\n\t}",
"@Override\n public void run() {\n cameraDetector.setDetectJoy(true);\n cameraDetector.setDetectAnger(true);\n cameraDetector.setDetectSadness(true);\n cameraDetector.setDetectSurprise(true);\n cameraDetector.setDetectFear(true);\n cameraDetector.setDetectDisgust(true);\n }",
"boolean turnFaceUp();",
"public void activate() {\n\t\tcameraNXT.sortBy('A');\n\t\tcameraNXT.enableTracking(true);\n\t}",
"@Override\r\n public void turnOn(){\r\n isOn = true;\r\n Reporter.report(this, Reporter.Msg.SWITCHING_ON);\r\n if (isOn){\r\n engageLoads();\r\n }\r\n }",
"@Override\n\tpublic void on() {\n\t\tSystem.out.println(\"turn on the \"+name+\" Light\");\n\t}",
"private void startEyeTracking() {\n if (!mFaceAnalyser.isTrackingRunning()) {\n mFaceAnalyser.startFaceTracker();\n mUserAwarenessListener.onEyeTrackingStarted(); //notify caller\n }\n }",
"Track(){\n\t}",
"void startTracking();",
"void think() {\n //get the output of the neural network\n decision = brain.output(vision);\n\n if (decision[0] > 0.8) {//output 0 is boosting\n boosting = true;\n } else {\n boosting = false;\n }\n if (decision[1] > 0.8) {//output 1 is turn left\n spin = -0.08f;\n } else {//cant turn right and left at the same time\n if (decision[2] > 0.8) {//output 2 is turn right\n spin = 0.08f;\n } else {//if neither then dont turn\n spin = 0;\n }\n }\n //shooting\n if (decision[3] > 0.8) {//output 3 is shooting\n shoot();\n }\n }",
"@Override\n public void execute() {\n drivetrain.set(ControlMode.MotionMagic, targetDistance, targetDistance);\n }",
"public void turnLightsOn()\n {\n set(Relay.Value.kForward);\n }",
"private static void turnFlashlightOn() {\n Parameters p = cam.getParameters();\n p.setFlashMode(Parameters.FLASH_MODE_TORCH);\n cam.setParameters(p);\n }",
"public void setupVuforia() {\n parameters = new VuforiaLocalizer.Parameters(); // To remove the camera view from the screen, remove the R.id.cameraMonitorViewId\n parameters.vuforiaLicenseKey = VUFORIA_KEY;\n parameters.cameraDirection = VuforiaLocalizer.CameraDirection.FRONT;\n parameters.useExtendedTracking = false;\n vuforiaLocalizer = ClassFactory.createVuforiaLocalizer(parameters);\n\n // These are the vision targets that we want to use\n // The string needs to be the name of the appropriate .xml file in the assets folder\n visionTargets = vuforiaLocalizer.loadTrackablesFromAsset(\"FTC_2016-17\");\n Vuforia.setHint(HINT.HINT_MAX_SIMULTANEOUS_IMAGE_TARGETS, 4);\n\n // Setup the target to be tracked\n\n vuforiaWheels = visionTargets.get(0);\n vuforiaWheels.setName(\"wheels\"); // wheels - blue 1\n\n vuforiaTools = visionTargets.get(1);\n vuforiaTools.setName(\"tools\"); // Tools = red 2\n\n vuforiaLegos = visionTargets.get(2);\n vuforiaLegos.setName(\"legos\"); // legos - blue 2\n\n vuforiaGears = visionTargets.get(3);\n vuforiaGears.setName(\"gears\"); // Gears - red 1\n\n if (teamColor == \"blue\") {\n target = vuforiaWheels;\n } else {\n target = vuforiaGears;\n }\n\n target.setLocation(createMatrix(0, 500, 0, 90, 0, 90));\n\n // Set phone location on robot - not set\n phoneLocation = createMatrix(0, 225, 0, 90, 0, 0);\n\n // Setup listener and inform it of phone information\n listener = (VuforiaTrackableDefaultListener) target.getListener();\n listener.setPhoneInformation(phoneLocation, parameters.cameraDirection);\n }",
"public void activateVolume(boolean on){\n\n\t\tif(prevPitch != cow.getPitch()) {\n\t\t\tcow.setIsPlaying(on);\n\n\t\t\t//if(sequencer.isRunning()) {\n\t\t\t\tcow.stopNote(synthesizer);\n\t\t\t//-}\n\n\t\t\tif (cow.getIsPlaying()) {\n\t\t\t\tsynthesizer = cow.playNote();\n\t\t\t}\n\n\t\t\tprevPitch = cow.getPitch();\n\t\t}\n\t\t\n\t}",
"public void setTorch(boolean on) {\n torchOn = on;\n if (cameraInstance != null) {\n cameraInstance.setTorch(on);\n }\n }",
"public void vision()\n {\n NIVision.IMAQdxGrab(session, colorFrame, 1);\t\t\t\t\n RETRO_HUE_RANGE.minValue = (int)SmartDashboard.getNumber(\"Retro hue min\", RETRO_HUE_RANGE.minValue);\n\t\tRETRO_HUE_RANGE.maxValue = (int)SmartDashboard.getNumber(\"Retro hue max\", RETRO_HUE_RANGE.maxValue);\n\t\tRETRO_SAT_RANGE.minValue = (int)SmartDashboard.getNumber(\"Retro sat min\", RETRO_SAT_RANGE.minValue);\n\t\tRETRO_SAT_RANGE.maxValue = (int)SmartDashboard.getNumber(\"Retro sat max\", RETRO_SAT_RANGE.maxValue);\n\t\tRETRO_VAL_RANGE.minValue = (int)SmartDashboard.getNumber(\"Retro val min\", RETRO_VAL_RANGE.minValue);\n\t\tRETRO_VAL_RANGE.maxValue = (int)SmartDashboard.getNumber(\"Retro val max\", RETRO_VAL_RANGE.maxValue);\n\t\tAREA_MINIMUM = SmartDashboard.getNumber(\"Area min %\");\n\t\t//MIN_RECT_WIDTH = SmartDashboard.getNumber(\"Min Rect Width\", MIN_RECT_WIDTH);\n\t\t//MAX_RECT_WIDTH = SmartDashboard.getNumber(\"Max Rect Width\", MAX_RECT_WIDTH);\n\t\t//MIN_RECT_HEIGHT = SmartDashboard.getNumber(\"Min Rect Height\", MIN_RECT_HEIGHT);\n\t\t//MAX_RECT_HEIGHT= SmartDashboard.getNumber(\"Max Rect Height\", MAX_RECT_HEIGHT);\n\t\t\n\t\t//SCALE_RANGE.minValue = (int)SmartDashboard.getNumber(\"Scale Range Min\");\n\t\t//SCALE_RANGE.maxValue = (int)SmartDashboard.getNumber(\"Scale Range Max\");\n\t\t//MIN_MATCH_SCORE = (int)SmartDashboard.getNumber(\"Min Match Score\");\n //Look at the color frame for colors that fit the range. Colors that fit the range will be transposed as a 1 to the binary frame.\n\t\t\n\t\tNIVision.imaqColorThreshold(binaryFrame, colorFrame, 255, ColorMode.HSV, RETRO_HUE_RANGE, RETRO_SAT_RANGE, RETRO_VAL_RANGE);\n\t\t//Send the binary image to the cameraserver\n\t\tif(cameraView.getSelected() == BINARY)\n\t\t{\n\t\t\tCameraServer.getInstance().setImage(binaryFrame);\n\t\t}\n\n\t\tcriteria[0] = new NIVision.ParticleFilterCriteria2(NIVision.MeasurementType.MT_AREA_BY_IMAGE_AREA, AREA_MINIMUM, 100.0, 0, 0);\t\t\n\t\t\n NIVision.imaqParticleFilter4(binaryFrame, binaryFrame, criteria, filterOptions, null);\n\n // NIVision.RectangleDescriptor rectangleDescriptor = new NIVision.RectangleDescriptor(MIN_RECT_WIDTH, MAX_RECT_WIDTH, MIN_RECT_HEIGHT, MAX_RECT_HEIGHT);\n// \n// //I don't know\n// NIVision.CurveOptions curveOptions = new NIVision.CurveOptions(NIVision.ExtractionMode.NORMAL_IMAGE, 0, NIVision.EdgeFilterSize.NORMAL, 0, 1, 1, 100, 1,1);\n// NIVision.ShapeDetectionOptions shapeDetectionOptions = new NIVision.ShapeDetectionOptions(1, rectAngleRanges, SCALE_RANGE, MIN_MATCH_SCORE);\n// NIVision.ROI roi = NIVision.imaqCreateROI();\n//\n// NIVision.DetectRectanglesResult result = NIVision.imaqDetectRectangles(binaryFrame, rectangleDescriptor, curveOptions, shapeDetectionOptions, roi);\n// //Dummy rectangle to start\n// \n// NIVision.RectangleMatch bestMatch = new NIVision.RectangleMatch(new PointFloat[]{new PointFloat(0.0, 0.0)}, 0, 0, 0, 0);\n// \n// //Find the best matching rectangle\n// for(NIVision.RectangleMatch match : result.array)\n// {\n// \tif(match.score > bestMatch.score)\n// \t{\n// \t\tbestMatch = match;\n// \t}\n// }\n// SmartDashboard.putNumber(\"Rect height\", bestMatch.height);\n// SmartDashboard.putNumber(\"Rect Width\", bestMatch.width);\n// SmartDashboard.putNumber(\"Rect rotation\", bestMatch.rotation);\n// SmartDashboard.putNumber(\"Rect Score\", bestMatch.score);\n \n //Report how many particles there are\n\t\tint numParticles = NIVision.imaqCountParticles(binaryFrame, 1);\n\t\tSmartDashboard.putNumber(\"Masked particles\", numParticles);\n\t\t\n \n\t\tif(numParticles > 0)\n\t\t{\n\t\t\t//Measure particles and sort by particle size\n\t\t\tVector<ParticleReport> particles = new Vector<ParticleReport>();\n\t\t\tfor(int particleIndex = 0; particleIndex < numParticles; particleIndex++)\n\t\t\t{\n\t\t\t\tParticleReport par = new ParticleReport();\n\t\t\t\tpar.Area = NIVision.imaqMeasureParticle(binaryFrame, particleIndex, 0, NIVision.MeasurementType.MT_AREA);\n\t\t\t\tpar.AreaByImageArea = NIVision.imaqMeasureParticle(binaryFrame, particleIndex, 0, NIVision.MeasurementType.MT_AREA_BY_IMAGE_AREA);\n\t\t\t\tpar.BoundingRectTop = NIVision.imaqMeasureParticle(binaryFrame, particleIndex, 0, NIVision.MeasurementType.MT_BOUNDING_RECT_TOP);\n\t\t\t\tpar.BoundingRectLeft = NIVision.imaqMeasureParticle(binaryFrame, particleIndex, 0, NIVision.MeasurementType.MT_BOUNDING_RECT_LEFT);\n\t\t\t\tpar.BoundingRectHeight = NIVision.imaqMeasureParticle(binaryFrame, particleIndex, 0, NIVision.MeasurementType.MT_BOUNDING_RECT_HEIGHT);\n\t\t\t\tpar.BoundingRectWidth = NIVision.imaqMeasureParticle(binaryFrame, particleIndex, 0, NIVision.MeasurementType.MT_BOUNDING_RECT_WIDTH);\n\t\t\t\tparticles.add(par);\n\n\t\t\t}\n\t\t\tparticles.sort(null);\n\n\t\t\t//This example only scores the largest particle. Extending to score all particles and choosing the desired one is left as an exercise\n\t\t\t//for the reader. Note that this scores and reports information about a single particle (single L shaped target). To get accurate information \n\t\t\t//about the location of the tote (not just the distance) you will need to correlate two adjacent targets in order to find the true center of the tote.\n//\t\t\tscores.Aspect = AspectScore(particles.elementAt(0));\n//\t\t\tSmartDashboard.putNumber(\"Aspect\", scores.Aspect);\n//\t\t\tscores.Area = AreaScore(particles.elementAt(0));\n//\t\t\tSmartDashboard.putNumber(\"Area\", scores.Area);\n//\t\t\tboolean isTote = scores.Aspect > SCORE_MIN && scores.Area > SCORE_MIN;\n//\n\t\t\tParticleReport bestParticle = particles.elementAt(0);\n\t\t NIVision.Rect particleRect = new NIVision.Rect((int)bestParticle.BoundingRectTop, (int)bestParticle.BoundingRectLeft, (int)bestParticle.BoundingRectHeight, (int)bestParticle.BoundingRectWidth);\n\t\t \n\t\t //NIVision.imaqOverlayRect(colorFrame, particleRect, new NIVision.RGBValue(0, 0, 0, 255), DrawMode.PAINT_VALUE, \"a\");//;(colorFrame, colorFrame, particleRect, DrawMode.DRAW_VALUE, ShapeMode.SHAPE_OVAL, 20);\n\t\t NIVision.imaqDrawShapeOnImage(colorFrame, colorFrame, particleRect, NIVision.DrawMode.DRAW_VALUE, ShapeMode.SHAPE_RECT, 0.0f);\n\t\t SmartDashboard.putNumber(\"Rect Top\", bestParticle.BoundingRectTop);\n\t\t SmartDashboard.putNumber(\"Rect Left\", bestParticle.BoundingRectLeft);\n\t\t SmartDashboard.putNumber(\"Rect Width\", bestParticle.BoundingRectWidth);\n\t\t SmartDashboard.putNumber(\"Area by image area\", bestParticle.AreaByImageArea);\n\t\t SmartDashboard.putNumber(\"Area\", bestParticle.Area);\n\t\t double bestParticleMidpoint = bestParticle.BoundingRectLeft + bestParticle.BoundingRectWidth/2.0;\n\t\t double bestParticleMidpointAimingCoordnates = pixelCoordnateToAimingCoordnate(bestParticleMidpoint, CAMERA_RESOLUTION_X);\n\t\t angleToTarget = aimingCoordnateToAngle(bestParticleMidpointAimingCoordnates, VIEW_ANGLE);\n\t\t \n\t\t}\n\t\telse\n\t\t{\n\t\t\tangleToTarget = 0.0;\n\t\t}\n\n if(cameraView.getSelected() == COLOR)\n {\n \tCameraServer.getInstance().setImage(colorFrame);\n }\n\t SmartDashboard.putNumber(\"Angle to target\", angleToTarget);\n\n }",
"public void setIsTrack(boolean isTrack){\n this.isTrack = isTrack;\n }",
"@Override \n public void runOpMode() \n {\n leftMotors = hardwareMap.get(DcMotor.class, \"left_Motors\");\n rightMotors = hardwareMap.get(DcMotor.class, \"right_Motors\");\n vLiftMotor = hardwareMap.get(DcMotor.class, \"vLift_Motor\"); \n \n leftMotors.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n rightMotors.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n leftMotors.setDirection(DcMotor.Direction.REVERSE);\n rightMotors.setDirection(DcMotor.Direction.FORWARD);\n vLiftMotor.setDirection(DcMotor.Direction.REVERSE);\n vLiftMotor.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n \n waitForStart(); //press play button, actives opMode\n intakePivotServo.setPosition(intakePivotServoPos);\n while (opModeIsActive()) \n { \n drive();\n pivotIntake();\n pivotLift();\n \n }//opModeIsActive \n \n }",
"@Override\n public void onCameraPreviewStarted() {\n enableTorchButtonIfPossible();\n }",
"void track();",
"public void startTurn() {\n nMovesBeforeGrabbing = 1;\n nMovesBeforeShooting = 0;\n\n if (damages.size() > 2)\n nMovesBeforeGrabbing = 2;\n\n if (damages.size() > 5)\n nMovesBeforeShooting = 1;\n\n playerStatus.isActive = true;\n }",
"public void startFrontCam() {\n }",
"public static void trackCheck() {\n\t\t// reset the motor\n\t\tfor (EV3LargeRegulatedMotor motor : new EV3LargeRegulatedMotor[] { leftMotor, rightMotor }) {\n\t\t\tmotor.stop();\n\t\t\tmotor.setAcceleration(3000);\n\t\t}\n\t\ttry {\n\t\t\tThread.sleep(200);\n\t\t} catch (InterruptedException e) {\n\t\t\t// There is nothing to be done here\n\t\t}\n\t\t\n\t\t//move the robot forward until the Y asis is detected\n\t\tleftMotor.setSpeed(400);\n\t\trightMotor.setSpeed(400);\n\t\tleftMotor.rotate(Navigation_Test.convertAngle(Project_Test.WHEEL_RAD, Project_Test.TRACK, 720), true);\n\t\trightMotor.rotate(-Navigation_Test.convertAngle(Project_Test.WHEEL_RAD, Project_Test.TRACK, 720), false);\n\t}",
"public void turnOn(boolean truth) {\r\n setEnabled(truth);\r\n }",
"@Override\n public void runOpMode() {\n frontLeftWheel = hardwareMap.dcMotor.get(\"frontLeft\");\n backRightWheel = hardwareMap.dcMotor.get(\"backRight\");\n frontRightWheel = hardwareMap.dcMotor.get(\"frontRight\");\n backLeftWheel = hardwareMap.dcMotor.get(\"backLeft\");\n\n //telemetry sends data to robot controller\n telemetry.addData(\"Output\", \"hardwareMapped\");\n\n // The TFObjectDetector uses the camera frames from the VuforiaLocalizer, so we create that\n // first.\n initVuforia();\n\n if (ClassFactory.getInstance().canCreateTFObjectDetector()) {\n initTfod();\n } else {\n telemetry.addData(\"Sorry!\", \"This device is not compatible with TFOD\");\n }\n\n /**\n * Activate TensorFlow Object Detection before we wait for the start command.\n * Do it here so that the Camera Stream window will have the TensorFlow annotations visible.\n **/\n if (tfod != null) {\n tfod.activate();\n }\n\n /** Wait for the game to begin */\n telemetry.addData(\">\", \"Press Play to start op mode\");\n telemetry.update();\n waitForStart();\n\n if (opModeIsActive()) {\n while (opModeIsActive()) {\n if (tfod != null) {\n // getUpdatedRecognitions() will return null if no new information is available since\n // the last time that call was made\n List<Recognition> updatedRecognitions = tfod.getUpdatedRecognitions();\n if(updatedRecognitions == null) {\n frontLeftWheel.setPower(0);\n frontRightWheel.setPower(0);\n backLeftWheel.setPower(0);\n backRightWheel.setPower(0);\n } else if (updatedRecognitions != null) {\n telemetry.addData(\"# Object Detected\", updatedRecognitions.size());\n // step through the list of recognitions and display boundary info.\n int i = 0;\n\n\n for (Recognition recognition : updatedRecognitions) {\n float imageHeight = recognition.getImageHeight();\n float blockHeight = recognition.getHeight();\n\n //-----------------------\n// stoneCX = (recognition.getRight() + recognition.getLeft())/2;//get center X of stone\n// screenCX = recognition.getImageWidth()/2; // get center X of the Image\n// telemetry.addData(\"screenCX\", screenCX);\n// telemetry.addData(\"stoneCX\", stoneCX);\n// telemetry.addData(\"width\", recognition.getImageWidth());\n //------------------------\n\n telemetry.addData(\"blockHeight\", blockHeight);\n telemetry.addData(\"imageHeight\", imageHeight);\n telemetry.addData(String.format(\"label (%d)\", i), recognition.getLabel());\n telemetry.addData(String.format(\" left,top (%d)\", i), \"%.03f , %.03f\", recognition.getLeft(), recognition.getTop());\n telemetry.addData(String.format(\" right,bottom (%d)\", i), \"%.03f , %.03f\", recognition.getRight(), recognition.getBottom());\n\n\n if(hasStrafed == false) {\n float midpoint = (recognition.getLeft() + recognition.getRight()) /2;\n float multiplier ;\n if(midpoint > 500) {\n multiplier = -(((int)midpoint - 500) / 100) - 1;\n log = \"Adjusting Right\";\n sleep(200);\n } else if(midpoint < 300) {\n multiplier = 1 + ((500 - midpoint) / 100);\n log = \"Adjusting Left\";\n sleep(200);\n } else {\n multiplier = 0;\n log = \"In acceptable range\";\n hasStrafed = true;\n }\n frontLeftWheel.setPower(-0.1 * multiplier);\n backLeftWheel.setPower(0.1 * multiplier);\n frontRightWheel.setPower(-0.1 * multiplier);\n backRightWheel.setPower(0.1 * multiplier);\n } else {\n if( blockHeight/ imageHeight < .5) {\n frontLeftWheel.setPower(-.3);\n backLeftWheel.setPower(.3);\n frontRightWheel.setPower(.3);\n backRightWheel.setPower(-.3);\n telemetry.addData(\"detecting stuff\", true);\n } else {\n frontLeftWheel.setPower(0);\n backLeftWheel.setPower(0);\n frontRightWheel.setPower(0);\n backRightWheel.setPower(0);\n telemetry.addData(\"detecting stuff\", false);\n }\n }\n\n telemetry.addData(\"Angle to unit\", recognition.estimateAngleToObject(AngleUnit.DEGREES));\n telemetry.addData(\"Log\", log);\n\n }\n telemetry.update();\n }\n\n }\n }\n }\n if (tfod != null) {\n tfod.shutdown();\n }\n }",
"private void turnOnFlash() {\n if (!batteryOk) {\n showBatteryLowDialog();\n return;\n }\n getCamera();\n Log.d(\"Flash on?\", \"============+>\" + String.valueOf(isFlashOn));\n if (!isFlashOn) {\n if (camera == null || params == null) {\n isFlashOn = false;\n return;\n }\n // play sound\n playSound();\n try {\n if (freq != 0) {\n sr = new StroboRunner();\n t = new Thread(sr);\n t.start();\n } else {\n params = camera.getParameters();\n params.setFlashMode(Camera.Parameters.FLASH_MODE_TORCH);\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.ICE_CREAM_SANDWICH) {\n params.setFocusMode(Camera.Parameters.FOCUS_MODE_CONTINUOUS_PICTURE);\n }\n camera.setParameters(params);\n camera.startPreview();\n }\n } catch (Exception e) {\n // Do nothing;\n }\n\n isFlashOn = true;\n // changing button/switch image\n toggleButtonImageSwitch();\n }\n\n }",
"@Override\n public void turnOn() {\n System.out.println(\"this wont happen\");\n }",
"public void onClick(View v) {\n\t\t\t\tboolean trackEnable = Preference.getInstance(baseAct.getApplicationContext()).getGpsMonitor();\n\t\t if (!trackEnable){// turn on gpsSwt\n\t\t \tLogRecord.SaveLogInfo2File(Base.OperateInfo, TAG+\"track enable\");\n\t \t\tPreference.getInstance(baseAct.getApplicationContext()).setGpsMonitor(true);\n\t \t\tgpsSwt.setImageResource(R.drawable.icon_radio_enable);\t\t\t\t \n\t\t\t\t}\n\t\t\t\telse{\t// turn off gpsSwt\n\t\t\t\t\tLogRecord.SaveLogInfo2File(Base.OperateInfo, TAG+\"track disable\");\n\t\t\t\t\tPreference.getInstance(baseAct.getApplicationContext()).setGpsMonitor(false);\n\t\t\t\t\tgpsSwt.setImageResource(R.drawable.icon_radio_disable);\n\t\t\t\t\tif(baseAct.localbinder != null)\n\t\t\t\t\t\tbaseAct.localbinder.setGPSUpdateState(CarDataService.GPS_UPLOAD_START);\t// to cause to make a new trace\n\t\t\t\t}\t\t\n\t\t\t}",
"public void onEnable() {\n\t\tmain = this;\n\t\tthis.config = new YMLFile(\"plugins\", \"BBSkyBPvpArena\", \"config\");\n\t\tthis.etatDuJeu = 0;\n\t\tthis.pari = new Pari();\n\t\tthis.play = new Play();\n\t\tgetServer().getPluginManager().registerEvents(new pluginListeners(), this);\n\t\tgetCommand(\"arene\").setExecutor(new CommandListener());\n\t\tSystem.out.println(\"plugin SkyBlock Pvp Arena ON!\");\n\t}",
"public void startTracking()\n {\n if(!pixyThread.isAlive())\n {\n pixyThread = new Thread(this);\n pixyThread.start();\n leds.setMode(LEDController.Mode.ON);\n }\n }",
"public void on() {\n\t\tSystem.out.println(\"Tuner is on\");\n\n\t}",
"public void turnOn(int x, int y);",
"private void turnOnLights(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_turnOnLights\n\n this.selectedTrain.setLights(1); // turn on lights\n this.operatingLogbook.add(\"Lights on.\");\n this.printOperatingLogs();\n }",
"public void onTurnBegin() {\n\n\t}",
"public void changeStatus()\n {\n if(this.isActivate == false)\n {\n this.isActivate = true;\n switchSound.play();\n //this.dungeon.updateSwitches(true); \n }\n else{\n this.isActivate = false;\n switchSound.play(1.75, 0, 1.5, 0, 1);\n //this.dungeon.updateSwitches(false); \n }\n notifyObservers();\n\n }",
"public void turnOn ()\n\t{\n\t\tthis.powerState = true;\n\t}",
"public void onToggleTorch(View v) {\n if (mWZCameraView == null) return;\n\n WZCamera activeCamera = mWZCameraView.getCamera();\n activeCamera.setTorchOn(mBtnTorch.toggleState());\n }",
"public void startTrainingMode() {\n\t\t\r\n\t}",
"public void set_videotoggle_on_off(View view)\n\t{\n\t\tif(VideoModule.isVideoThreadStarted())\n\t\t{\n\t\t\tVideoModule.stopVideoServer();\n\t\t}\n\t\telse\n\t\t{\n\t\t\tVideoModule.startVideoServer();\n\t\t}\n\t\tvideo_toggle_OnOff.setChecked(VideoModule.isVideoThreadStarted());\n\t}",
"void onEnoughLightAvailable() {\n //start eye tracking if it is not running already\n startEyeTracking();\n }",
"@Override\n public boolean isAiOn()\n {\n return aiIsOn;\n }",
"protected void execute() {\n\t\tBBox bBox = bBoxLocator.getBBox();\n\t\tSmartDashboard.putBoolean(\"Can See With Vision\", wasDetected);\n\n\t\tif (bBox != null) {\n\t\t\twasDetected = true;\n\t\t\tpidAngle.setSetpoint(Robot.drivetrain.getHeading() + bBox.angleDeg);\n\t\t\tSmartDashboard.putNumber(\"PID Vision Setpoint Angle\", pidAngle.getSetpoint());\n\t\t}\n\n\t\tif (!waitForVision || wasDetected) {\n\t\t\tRobot.drivetrain.drive(driveOutput * (useAccelerationFiler ? filter.output() : 1), driveCurve);\n\t\t}\n\t}",
"public void setTrackEnabled(boolean trackAble){\n this.trackEnabled = trackAble;\n refreshTheView();\n }",
"public void startVirtual() {\n if (mMediaProjection != null) {\n Log.i(TAG, \"want to display virtual\");\n virtualDisplay();\n } else {\n Log.i(TAG, \"start screen capture intent\");\n Log.i(TAG, \"want to build mediaprojection and display virtual\");\n setUpMediaProjection();\n virtualDisplay();\n }\n }",
"public Drivetrain(){\r\n LeftSlave.follow(LeftMaster);\r\n RightSlave.follow(RightMaster);\r\n\r\n RightMaster.setInverted(true);\r\n LeftMaster.setInverted(true);\r\n\r\n gyro.reset();\r\n}",
"@Override\n public void runOpMode() {\n hw = new RobotHardware(robotName, hardwareMap);\n rd = new RobotDrive(hw);\n rs=new RobotSense(hw, telemetry);\n /*rd.moveDist(RobotDrive.Direction.FORWARD, .5, .3);\n rd.moveDist(RobotDrive.Direction.REVERSE, .5, .3);\n rd.moveDist(RobotDrive.Direction.FORWARD, .5, 1);\n rd.moveDist(RobotDrive.Direction.REVERSE, .5, 1);*/\n telemetry.addData(\"Ready! \", \"Go Flamangos!\"); \n telemetry.update();\n\n //Starting the servos in the correct starting position\n /*hw.armRight.setPosition(1-.3);\n hw.armLeft.setPosition(.3);\n hw.level.setPosition(.3+.05);*/\n hw.f_servoLeft.setPosition(1);\n hw.f_servoRight.setPosition(0.5);\n \n rd.moveArm(hw.startPos());\n waitForStart();\n while (opModeIsActive()) {\n \n /*Starting close to the bridge on the building side\n Move under the bridge and push into the wall*/\n rd.moveDist(RobotDrive.Direction.LEFT,2,.5);\n rd.moveDist(RobotDrive.Direction.FORWARD, 10, .5);\n break;\n }\n }",
"boolean isTurnedFaceUp();",
"public void startTracking()\n\t{\t\n\t\tProcessBuilder starterProcess = new ProcessBuilder(\"ssh\", \n\t\t\t\t\t\t\t\t\t\t\"pi@\" + RASPBERRY_PI_LOCATION,\n\t\t\t\t\t\t\t\t\t\t\"\\\"sudo /home/pi/code/stop_vision.sh && /home/pi/code/start_vision.sh \" + \n\t\t\t\t\t\t\t\t\t\tFPS + \" \" + \n\t\t\t\t\t\t\t\t\t\tIMAGE_WIDTH + \"x\" + IMAGE_HEIGHT + \"\\\"\");\n\t\t\n\t\ttry \n\t\t{\n\t\t\tstarterProcess.start();\n\t\t\ttracking = true;\n\t\t\tSystem.out.println(\"Started vision tracking on Pi\");// + startedProcess + \" (Error:\" + startedProcess.getErrorStream() + \")\");\n\t\t} \n\t\tcatch (IOException e) \n\t\t{\n\t\t\tSystem.out.println(\"Could not start process to commence Raspberry Pi GRIP program: \");\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"@Override\n public void powerOn() {\n if(isOn)System.out.println(\"The Projector is already ON!\");\n else{\n System.out.println(\"The Projector is now ON!\");\n isOn = true;\n }\n }",
"public Vision() {\n\n visionCam = CameraServer.getInstance().startAutomaticCapture(\"HatchCam\", 0);\n visionCam.setVideoMode(PixelFormat.kMJPEG, 320, 240, 115200);\n \n int retry = 0;\n while(cam == null && retry < 10) {\n try {\n System.out.println(\"Connecting to jevois serial port ...\");\n cam = new SerialPort(115200, SerialPort.Port.kUSB1);\n System.out.println(\"Success!!!\");\n } catch (Exception e) {\n System.out.println(\"We all shook out\");\n e.printStackTrace();\n sleep(500);\n System.out.println(\"Retry\" + Integer.toString(retry));\n retry++;\n }\n }\n // BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n\n // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n }",
"@Override\n public void track() {\n tracker.update(\n driveEncoder.getCount(),\n getTurnAngle(turnEncoder.getCount())\n );\n }",
"public void startGearCam() {\n }",
"@Override\n public void runOpMode() {\n motorFL = hardwareMap.get(DcMotor.class, \"motorFL\");\n motorBL = hardwareMap.get(DcMotor.class, \"motorBL\");\n motorFR = hardwareMap.get(DcMotor.class, \"motorFR\");\n motorBR = hardwareMap.get(DcMotor.class, \"motorBR\");\n landerRiser = hardwareMap.get(DcMotor.class, \"lander riser\");\n landerRiser = hardwareMap.get(DcMotor.class, \"lander riser\");\n landerRiser.setDirection(DcMotor.Direction.FORWARD);\n landerRiser.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n markerDrop = hardwareMap.get(Servo.class, \"marker\");\n markerDrop.setDirection(Servo.Direction.FORWARD);\n telemetry.addData(\"Status\", \"Initialized\");\n telemetry.update();\n\n // Wait for the game to start (driver presses PLAY)\n waitForStart();\n runtime.reset();\n\n //Landing & unlatching\n landerRiser.setPower(-1);\n telemetry.addData(\"Status\", \"Descending\");\n telemetry.update();\n sleep(5550);\n landerRiser.setPower(0);\n telemetry.addData(\"Status\",\"Unhooking\");\n telemetry.update();\n move(-0.5, 600, true);\n strafe(-0.4,0.6, 3600, true);\n move(0.5,600,true);\n markerDrop.setPosition(0);\n sleep(1000);\n markerDrop.setPosition(0.5);\n sleep(700);\n markerDrop.setPosition(0);\n strafe(0, -0.5,500,true);\n strafe(0.5, -0.25, 8500, true);\n\n }",
"public void setVisionChanged(boolean visionChanged) {\n this.visionChanged = visionChanged;\n }",
"public void onDouyinDetectStart() {\n HwAPPStateInfo curAppInfo = getCurStreamAppInfo();\n if (curAppInfo != null && 100501 == curAppInfo.mScenceId) {\n curAppInfo.mIsVideoStart = true;\n }\n }",
"@Override\r\n\tpublic void startTurn() {\n\t\t\r\n\t}",
"public void setOn(){\n state = true;\n //System.out.println(\"Se detecto un requerimiento!\");\n\n }",
"@Override\n public void runOpMode() {\n initialize();\n\n //wait for user to press start\n waitForStart();\n\n if (opModeIsActive()) {\n\n // drive forward 24\"\n // turn left 90 degrees\n // turnLeft(90);\n // drive forward 20\"\n // driveForward(20);\n // turn right 90 degrees\n // turnRight(90);\n // drive forward 36\"\n // driveForward(36);\n\n }\n\n\n }",
"public void switchOn();",
"boolean turnFaceDown();",
"public void setFaceUp(){faceUp = true;}",
"private void humanTurn() \n {\n \n playTurn();\n }",
"public void setEngineOn();",
"@Override\n public void onDetectionStateChanged(int state) {\n\n\n Log.d(\"onDetectionStateChanged\", \"state = \" + state);\n if (state == DETECTED) {\n robot.constraintBeWith();\n Log.d(this.getClass().getName(), \"onDetectionState = DETECTED\");\n\n //remove this listener as we do not want it triggering again and interrupting itself, note that we will have to listen for the end of the above speech so we can re-add this listener\n robot.removeOnDetectionStateChangedListener(this);\n robot.addTtsListener(new InteractionSpeechListener(this, robot, stateMachine));\n } else {\n robot.stopMovement();\n }\n }",
"public void playPvC() {\n boolean computerFirst = true;\n playPvC(computerFirst);\n }",
"protected void initialize(){\n\t\tRobot.driveTrain.changeTalonControlMode(TalonControlMode.Follower);\n\t\tRobot.driveTrain.setTalonsReversedState(true);\n\t\tRobotMap.visionSensor.startProcessing(PIDVisionSourceType.DistanceFromTarget);\n\t\thasStarted = RobotMap.VisionDistanceLeftPIDController.init(m_setPoint, StaticMembers.ABSOLUTE_TOLERANCE_DISTANCE);\n\t\thasStarted = RobotMap.VisionDistanceRightPIDController.init(m_setPoint, StaticMembers.ABSOLUTE_TOLERANCE_DISTANCE) && hasStarted;\n\t}",
"@Override\n public void run(boolean on, Telemetry telemetry) {\n if (on) {\n dcMotor.setTargetPosition(onLocation);\n dcMotor.setPower(maxSpeed);\n } else {\n dcMotor.setTargetPosition(offLocation);\n dcMotor.setPower(maxSpeed);\n }\n telemetry.addData(\"Target position\", dcMotor.getTargetPosition());\n telemetry.addData(\"Encoder\", dcMotor.getCurrentPosition());\n }",
"@Override\n\tpublic void drive() {\n\t\tSystem.out.println(\"VAN IS DRIVING\");\n\t}",
"void onTurn(GameIO io, GameState move);",
"void togglePlay();",
"public void interactWhenSteppingOn() {\r\n\t\t\r\n\t}",
"@Override\n public void runOpMode() {\n\n robot.init(hardwareMap);\n robot.MotorRightFront.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);\n robot.MotorLeftFront.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);\n robot.MotorRightFront.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n robot.MotorLeftFront.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n\n /** Wait for the game to begin */\n while (!isStarted()) {\n telemetry.addData(\"angle\", \"0\");\n telemetry.update();\n }\n\n\n }",
"public void playTurn() {\r\n\r\n }",
"@Override\n public void runOpMode() {\n detector = new modifiedGoldDetector(); //Create detector\n detector.init(hardwareMap.appContext, CameraViewDisplay.getInstance(), DogeCV.CameraMode.BACK); //Initialize it with the app context and camera\n detector.enable(); //Start the detector\n\n //Initialize the drivetrain\n motorFL = hardwareMap.get(DcMotor.class, \"motorFL\");\n motorFR = hardwareMap.get(DcMotor.class, \"motorFR\");\n motorRL = hardwareMap.get(DcMotor.class, \"motorRL\");\n motorRR = hardwareMap.get(DcMotor.class, \"motorRR\");\n motorFL.setDirection(DcMotor.Direction.REVERSE);\n motorFR.setDirection(DcMotor.Direction.FORWARD);\n motorRL.setDirection(DcMotor.Direction.REVERSE);\n motorRR.setDirection(DcMotor.Direction.FORWARD);\n\n //Reset encoders\n motorFL.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);\n motorFR.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);\n motorRL.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);\n motorRR.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);\n motorFL.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n motorFR.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n motorRL.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n motorRR.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n\n telemetry.addData(\"IsFound: \", detector.isFound());\n telemetry.addData(\">\", \"Waiting for start\");\n telemetry.update();\n\n\n //TODO Pass skystone location to storage\n\n //Wait for the game to start (driver presses PLAY)\n waitForStart();\n\n /**\n * *****************\n * OpMode Begins Here\n * *****************\n */\n\n //Disable the detector\n if(detector != null) detector.disable();\n\n //Start the odometry processing thread\n odometryPositionUpdate positionUpdate = new odometryPositionUpdate(motorFL, motorFR, motorRL, motorRR, inchPerCount, trackWidth, wheelBase, 75);\n Thread odometryThread = new Thread(positionUpdate);\n odometryThread.start();\n runtime.reset();\n\n //Run until the end of the match (driver presses STOP)\n while (opModeIsActive()) {\n\n absPosnX = startPosnX + positionUpdate.returnOdometryX();\n absPosnY = startPosnY + positionUpdate.returnOdometryY();\n absPosnTheta = startPosnTheta + positionUpdate.returnOdometryTheta();\n\n telemetry.addData(\"X Position [in]\", absPosnX);\n telemetry.addData(\"Y Position [in]\", absPosnY);\n telemetry.addData(\"Orientation [deg]\", absPosnTheta);\n telemetry.addData(\"Thread Active\", odometryThread.isAlive());\n telemetry.update();\n\n//Debug: Drive forward for 3.0 seconds and make sure telemetry is correct\n if (runtime.seconds() < 3.0) {\n motorFL.setPower(0.25);\n motorFR.setPower(0.25);\n motorRL.setPower(0.25);\n motorRR.setPower(0.25);\n }else {\n motorFL.setPower(0);\n motorFR.setPower(0);\n motorRL.setPower(0);\n motorRR.setPower(0);\n }\n\n\n }\n //Stop the odometry processing thread\n odometryThread.interrupt();\n }",
"public void notifyTurn()\n {\n playerObserver.onTurnStart();\n }",
"public void land() {\n Game currentGame = this.getGame();\n this.setHasBeenVisited(true);\n currentGame.setMode( Game.Mode.GAME_WON);\n\n }",
"public void startStreaming() {\n// phoneCam.setViewportRenderingPolicy(OpenCvCamera.ViewportRenderingPolicy.OPTIMIZE_VIEW);\n phoneCam.startStreaming(320, 240, OpenCvCameraRotation.SIDEWAYS_RIGHT);\n }",
"public void play() \n{\n s = !s; \n if (s == false)\n {\n //pausets = millis()/4;\n controlP5.getController(\"play\").setLabel(\"Play\");\n } else if (s == true)\n {\n //origint = origint + millis()/4 - pausets;\n controlP5.getController(\"play\").setLabel(\"Pause\");\n }\n}",
"public void switchLight(){\r\n _switchedOn = !_switchedOn;\r\n }",
"public void initVuforiaNavigation() {\n int cameraMonitorViewId = hardwareMap.appContext.getResources().getIdentifier(\"cameraMonitorViewId\", \"id\", hardwareMap.appContext.getPackageName());\n VuforiaLocalizer.Parameters parameters = new VuforiaLocalizer.Parameters(cameraMonitorViewId);\n\n // VuforiaLocalizer.Parameters parameters = new VuforiaLocalizer.Parameters();\n\n parameters.vuforiaLicenseKey = VUFORIA_KEY;\n parameters.cameraDirection = CAMERA_CHOICE;\n\n // Make sure extended tracking is disabled for this example.\n parameters.useExtendedTracking = false;\n\n // Instantiate the Vuforia engine\n vuforia = ClassFactory.getInstance().createVuforia(parameters);\n\n // Load the data sets for the trackable objects. These particular data\n // sets are stored in the 'assets' part of our application.\n targetsUltimateGoal = this.vuforia.loadTrackablesFromAsset(\"UltimateGoal\");\n VuforiaTrackable blueTowerGoalTarget = targetsUltimateGoal.get(0);\n blueTowerGoalTarget.setName(\"Blue Tower Goal Target\");\n VuforiaTrackable redTowerGoalTarget = targetsUltimateGoal.get(1);\n redTowerGoalTarget.setName(\"Red Tower Goal Target\");\n VuforiaTrackable redAllianceTarget = targetsUltimateGoal.get(2);\n redAllianceTarget.setName(\"Red Alliance Target\");\n VuforiaTrackable blueAllianceTarget = targetsUltimateGoal.get(3);\n blueAllianceTarget.setName(\"Blue Alliance Target\");\n VuforiaTrackable frontWallTarget = targetsUltimateGoal.get(4);\n frontWallTarget.setName(\"Front Wall Target\");\n\n // For convenience, gather together all the trackable objects in one easily-iterable collection */\n allTrackables = new ArrayList<VuforiaTrackable>();\n allTrackables.addAll(targetsUltimateGoal);\n\n /**\n * In order for localization to work, we need to tell the system where each target is on the field, and\n * where the phone resides on the robot. These specifications are in the form of <em>transformation matrices.</em>\n * Transformation matrices are a central, important concept in the math here involved in localization.\n * See <a href=\"https://en.wikipedia.org/wiki/Transformation_matrix\">Transformation Matrix</a>\n * for detailed information. Commonly, you'll encounter transformation matrices as instances\n * of the {@link OpenGLMatrix} class.\n *\n * If you are standing in the Red Alliance Station looking towards the center of the field,\n * - The X axis runs from your left to the right. (positive from the center to the right)\n * - The Y axis runs from the Red Alliance Station towards the other side of the field\n * where the Blue Alliance Station is. (Positive is from the center, towards the BlueAlliance station)\n * - The Z axis runs from the floor, upwards towards the ceiling. (Positive is above the floor)\n *\n * Before being transformed, each target image is conceptually located at the origin of the field's\n * coordinate system (the center of the field), facing up.\n */\n\n //Set the position of the perimeter targets with relation to origin (center of field)\n redAllianceTarget.setLocation(OpenGLMatrix\n .translation(0, -halfField, mmTargetHeight)\n .multiplied(Orientation.getRotationMatrix(EXTRINSIC, XYZ, DEGREES, 90, 0, 180)));\n\n blueAllianceTarget.setLocation(OpenGLMatrix\n .translation(0, halfField, mmTargetHeight)\n .multiplied(Orientation.getRotationMatrix(EXTRINSIC, XYZ, DEGREES, 90, 0, 0)));\n frontWallTarget.setLocation(OpenGLMatrix\n .translation(-halfField, 0, mmTargetHeight)\n .multiplied(Orientation.getRotationMatrix(EXTRINSIC, XYZ, DEGREES, 90, 0 , 90)));\n\n // The tower goal targets are located a quarter field length from the ends of the back perimeter wall.\n blueTowerGoalTarget.setLocation(OpenGLMatrix\n .translation(halfField, quadField, mmTargetHeight)\n .multiplied(Orientation.getRotationMatrix(EXTRINSIC, XYZ, DEGREES, 90, 0 , -90)));\n redTowerGoalTarget.setLocation(OpenGLMatrix\n .translation(halfField, -quadField, mmTargetHeight)\n .multiplied(Orientation.getRotationMatrix(EXTRINSIC, XYZ, DEGREES, 90, 0, -90)));\n\n //\n // Create a transformation matrix describing where the phone is on the robot.\n //\n // NOTE !!!! It's very important that you turn OFF your phone's Auto-Screen-Rotation option.\n // Lock it into Portrait for these numbers to work.\n //\n // Info: The coordinate frame for the robot looks the same as the field.\n // The robot's \"forward\" direction is facing out along X axis, with the LEFT side facing out along the Y axis.\n // Z is UP on the robot. This equates to a bearing angle of Zero degrees.\n //\n // The phone starts out lying flat, with the screen facing Up and with the physical top of the phone\n // pointing to the LEFT side of the Robot.\n // The two examples below assume that the camera is facing forward out the front of the robot.\n\n // We need to rotate the camera around it's long axis to bring the correct camera forward.\n if (CAMERA_CHOICE == BACK) {\n phoneYRotate = -90;\n } else {\n phoneYRotate = 90;\n }\n\n // Rotate the phone vertical about the X axis if it's in portrait mode\n if (PHONE_IS_PORTRAIT) {\n phoneXRotate = 90 ;\n }\n\n // Next, translate the camera lens to where it is on the robot.\n // In this example, it is centered (left to right), but forward of the middle of the robot, and above ground level.\n final float CAMERA_FORWARD_DISPLACEMENT = 7.0f * mmPerInch; // eg: Camera is 7 Inches in front of robot center\n final float CAMERA_VERTICAL_DISPLACEMENT = 6.0f * mmPerInch; // eg: Camera is 6 Inches above ground\n final float CAMERA_LEFT_DISPLACEMENT = -4.0f * mmPerInch; // eg: Camera is 4 inches to the RIGHT the robot's center line\n\n OpenGLMatrix robotFromCamera = OpenGLMatrix\n .translation(CAMERA_FORWARD_DISPLACEMENT, CAMERA_LEFT_DISPLACEMENT, CAMERA_VERTICAL_DISPLACEMENT)\n .multiplied(Orientation.getRotationMatrix(EXTRINSIC, YZX, DEGREES, phoneYRotate, phoneZRotate, phoneXRotate));\n\n /** Let all the trackable listeners know where the phone is. */\n for (VuforiaTrackable trackable : allTrackables) {\n ((VuforiaTrackableDefaultListener) trackable.getListener()).setPhoneInformation(robotFromCamera, parameters.cameraDirection);\n }\n targetsUltimateGoal.activate();\n }",
"@Override\n\tpublic void setup() {\n\t\tint videoWidth = 1280/2;\n\t\tint videoHeight = 720/2;\n//\t\tint videoWidth = 640;\n//\t\tint videoHeight = 400;\n\t\tint videoFrameRate = 30;\n\t\tint secondsToRecordInSegment = 5;\n\t\n\t\tsize(videoWidth, videoHeight, P2D);\n\t\tframeRate(60);\n\t\t\n\t\tcam = new Camera(this, videoWidth, videoHeight, videoFrameRate, secondsToRecordInSegment);\n\t\tregionManager = new RegionManager(this, videoWidth, videoHeight);\n\t\twinnerProcessor = new WinnerProcessor(this, cam, regionManager);\n\t\tstartingPistol = new StartingPistol();\n\t\t\n\t\tglobalKeyboardActions = new HashMap<Integer, Runnable>();\n\t\tglobalKeyboardActions.put(Integer.valueOf('D'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"Switching to region definition mode\");\n\t\t\t\tcurrentMode = Mode.DEFINE_REGION;\n\t\t\t}\n\t\t});\n\t\tglobalKeyboardActions.put(Integer.valueOf('R'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"Switching to recording mode\");\n\t\t\t\tcurrentMode = Mode.RECORDING;\n\t\t\t}\n\t\t});\n\t\tglobalKeyboardActions.put(Integer.valueOf('P'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"Switching to playback mode\");\n\t\t\t\tcurrentMode = Mode.PLAYBACK;\n\t\t\t}\n\t\t});\n\t\t\n\t\tmodeKeyboardActions = new HashMap<Mode, Map<Integer,Runnable>>();\n\t\t\n\t\t// Region Actions\n\t\tMap<Integer, Runnable> regionActions = new HashMap<Integer, Runnable>();\n\t\tmodeKeyboardActions.put(Mode.DEFINE_REGION, regionActions);\n\t\t\n\t\tregionActions.put(Integer.valueOf('3'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"In region define mode. Switching to finish line definition\");\n\t\t\t\tregionManager.setRegionToDefine(Region.FINISH_LINE);\n\t\t\t}\n\t\t});\n\t\tregionActions.put(Integer.valueOf('1'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"In region define mode. Switching to lane 1 definition\");\n\t\t\t\tregionManager.setRegionToDefine(Region.LANE1);\n\t\t\t}\n\t\t});\n\t\tregionActions.put(Integer.valueOf('2'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"In region define mode. Switching to lane 2 definition\");\n\t\t\t\tregionManager.setRegionToDefine(Region.LANE2);\n\t\t\t}\n\t\t});\n\t\tregionActions.put(Integer.valueOf('0'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"In region define mode. Clearing current region definition\");\n\t\t\t\tregionManager.setRegionToDefine(null);\n\t\t\t}\n\t\t});\n\t\tregionActions.put(Integer.valueOf('S'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"Saving current regions to disk\");\n\t\t\t\tregionManager.saveRegions();\n\t\t\t}\n\t\t});\n\t\tregionActions.put(Integer.valueOf('L'), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tprintln(\"Loading previous regions from disk\");\n\t\t\t\tregionManager.loadRegions();\n\t\t\t}\n\t\t});\n\t\t\n\t\t// Recording actions\n\t\tMap<Integer, Runnable> recordingActions = new HashMap<Integer, Runnable>();\n\t\tmodeKeyboardActions.put(Mode.RECORDING, recordingActions);\n\t\t\n\t\trecordingActions.put(Integer.valueOf(' '), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\tstartRace();\n\t\t\t}\n\t\t});\n\t\t\n\t\t// Playback actions\n\t\tMap<Integer, Runnable> playbackActions = new HashMap<Integer, Runnable>();\n\t\tmodeKeyboardActions.put(Mode.PLAYBACK, playbackActions);\n\t\t\n\t\t// Left arrow\n\t\tplaybackActions.put(Integer.valueOf(37), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\twinnerProcessor.stepBackward();\n\t\t\t}\n\t\t});\n\t\t// Right arrow\n\t\tplaybackActions.put(Integer.valueOf(39), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\twinnerProcessor.stepForward();\n\t\t\t}\n\t\t});\n\t\tplaybackActions.put(Integer.valueOf(' '), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\twinnerProcessor.toggleManualStep();\n\t\t\t}\n\t\t});\n\t\tplaybackActions.put(Integer.valueOf(38), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\twinnerProcessor.togglePlayOriginal();\n\t\t\t}\n\t\t});\n\t\tplaybackActions.put(Integer.valueOf(40), new Runnable() {\n\t\t\t@Override public void run() {\n\t\t\t\twinnerProcessor.togglePlayOriginal();\n\t\t\t}\n\t\t});\n\t\t\n\t\tcam.start();\n\t\t\n\t\tstartingPistol.listen(this);\n\t}",
"protected void execute() {\n \tRobot.driveTrain.driveByArcade(_speed, 0);\n }",
"public void onClick(View v) {\n speechRecognizer.startListening(speechRecognizerIntent);\n Toast.makeText( getActivity(),\"Voice\", Toast.LENGTH_SHORT).show();\n }",
"@Override\n public void execute() {\n\n\n /* container.swerveControllerCommand =\n new SwerveControllerCommand(\n trajectory,\n drivetrain::getCurrentPose, \n DrivetrainConstants.DRIVE_KINEMATICS,\n\n // Position controllers\n new PIDController(DrivetrainConstants.P_X_Controller, 0, 0),\n new PIDController(DrivetrainConstants.P_Y_Controller, 0, 0),\n container.thetaController,\n drivetrain::setModuleStates, //Not sure about setModuleStates\n drivetrain);*/\n\n// Reset odometry to the starting pose of the trajectory.\ndrivetrain.resetOdometry(trajectory.getInitialPose());\n\n\n}",
"public void nextTurn() {\n visionChanged = true;\n SoundPlayer.playEndTurn();\n // Check if any protection objectives have failed\n gameState.updateAllHeroProtectionGoals(getHeroManager());\n // hook the next turn\n if (!multiplayerGameManager.hookNextTurn()) {\n\n if (map.enemyPerformingMove()) {\n return;\n }\n // Enemy action was made\n if (playerTurn && map.hasEnemy()) {\n try {\n map.enemyTurn(this);\n } catch (InterruptedException e) {\n logger.error(\"ayylmao at the GameManager.nextTurn(..) Method\");\n Platform.exit();\n Thread.currentThread().interrupt();\n }\n } else {\n map.playerTurn(this);\n updateBuffIcons();\n updateTempVisiblePoints();\n map.turnTick();\n for(CurrentHeroChangeListener listener:heroChangeListeners){\n \tlistener.onHeroChange(getHeroManager().getCurrentHero());\n }\n }\n\n } else {\n moveViewTo(getHeroManager().getCurrentHero().getX(), getHeroManager().getCurrentHero().getY());\n updateBuffIcons();\n updateTempVisiblePoints();\n }\n\n map.updateVisibilityArray();\n dayNightClock.tick();\n turnTickLiveTiles();\n abilitySelected = AbilitySelected.MOVE;\n abilitySelectedChanged = true;\n backgroundChanged = true;\n gameChanged = true;\n minimapChanged = true;\n saveOriginator.writeMap(this.map, this.getObjectives(), this.gameState);\n // update(this.tracker,null);\n }",
"private void setUpTracking(){\n final Button startRoute = findViewById(R.id.trackRoute);\n\n startRoute.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n if(trackingRoute){\n eventStopTrackingRoute();\n startRoute.setText(R.string.startRoute);\n }\n else{\n startTrackingRoute();\n startRoute.setText(R.string.stopTracking);\n trackingRoute = true;\n }\n }\n });\n }",
"@Override\n public void runOpMode() throws InterruptedException {\n super.runOpMode();\n // LeftServo.setPosition(0.4);\n // RightServo.setPosition(0.5);\n\n waitForStart();\n telemetry.addData(\"Angles\", MyDriveTrain.getAngle());\n telemetry.update();\n telemetry.addData(\"Mikum:\", Mikum);\n telemetry.update();\n LF.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.FLOAT);\n RF.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.FLOAT);\n LB.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.FLOAT);\n RB.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.FLOAT);\n\n MyDriveTrain.encoderDrive(0.8, -30, 30, 30, -30, 1);\n MyDriveTrain.Rotate(0,0.1,10);\n// Mikum = MyVuforiaStone.ConceptVuforiaSkyStoneNavigationWebcam();\n// Mikum = 3;\n LF.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n RF.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n LB.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n RB.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n\n\n if (Mikum > 2) {\n telemetry.addLine(\"you're on the right\");\n telemetry.update();\n MyDriveTrain.encoderDrive(0.8, -84, 84, 84, -84, 1);\n MyIntake.maxIntake();\n MyDriveTrain.encoderDrive(0.8, -25, -25, -25, -25, 2);\n sleep(500);\n// MyDriveTrain.Verification(cubeIn,cubeNotInMM);\n\n MyIntake.ShutDown();\n MyDriveTrain.encoderDrive(0.8, 45, -45, -45, 45, 1);\n MyDriveTrain.Rotate(0,0.1,10);\n MyDriveTrain.encoderDrive(0.8, 100, 100, 100, 100, 2);\n }\n\n else if (Mikum < -2) {\n telemetry.addLine(\"you're on the left\");\n telemetry.update();\n MyDriveTrain.encoderDrive(0.8, 15, 15, 15, 15, 2);\n MyDriveTrain.encoderDrive(0.8, -86, 86, 86, -86, 1);\n MyIntake.maxIntake();\n MyDriveTrain.encoderDrive(0.8, -25, -25, -25, -25, 2);\n sleep(500);\n// MyDriveTrain.Verification(cubeIn,cubeNotInMM);\n\n MyIntake.ShutDown();\n MyDriveTrain.encoderDrive(0.8, 50, -50, -50, 50, 1);\n MyDriveTrain.Rotate(0,0.1,10);\n MyDriveTrain.encoderDrive(1, 85, 85, 85, 85, 2);\n\n\n\n } else {\n telemetry.addLine(\"You are on the center!\");\n telemetry.update();\n MyDriveTrain.encoderDrive(0.8, 30, 30, 30, 30, 2);\n MyDriveTrain.encoderDrive(0.5, -82, 82, 82, -82, 1);\n MyIntake.maxIntake();\n MyDriveTrain.encoderDrive(0.8, -25, -25, -25, -25, 2);\n sleep(500);\n// MyDriveTrain.Verification(cubeIn,cubeNotInMM);\n\n MyIntake.ShutDown();\n MyDriveTrain.encoderDrive(0.8, 45, -45, -45, 45, 1);\n MyDriveTrain.Rotate(0,0.1,10);\n MyDriveTrain.encoderDrive(1, 80, 80, 80, 80, 2);\n\n }\n\n MyDriveTrain.Rotate(0,0.2,10);\n MyIntake.maxIntake();\n sleep(500);\n MyIntake.ShutDown();\n Output.setPosition(OutputDown);\n MyDriveTrain.encoderDrive(1, 130, 130, 130, 130, 2);\n MyDriveTrain.encoderDrive(0.8, -5, 5, 5, -5, 1);\n\n MyDriveTrain.RotateP(90,1,10,0.0108);\n sleep(500);\n MyDriveTrain.encoderDrive(0.2,29,29,29,29,2);\n MyDriveTrain.Rotate(90,0.1,10);\n LeftServo.setPosition(0.15);\n RightServo.setPosition(0.2);\n MyDriveTrain.encoderDrive(0.1,10,10,10,10,2);\n LeftServo.setPosition(LeftServoDown);\n RightServo.setPosition(RightServoDown);\n sleep(500);\n MyDriveTrain.encoderDrive(1,-90,-90,-90,-90,2);\n MyDriveTrain.Rotate(-0,0.5,10);\n MyDriveTrain.encoderDrive(1,40,40,40,40,2);\n\n MyElevator.ElevateWithEncoder(-450, 0.8, 0.5);\n sleep(500);\n Arm.setPosition(1);\n sleep(1500);\n MyElevator.ElevateWithEncoder(0, 0.3, 0.0035);\n sleep(700);\n Output.setPosition(OutputUp);\n sleep(500);\n MyElevator.ElevateWithEncoder(-500, 0.3, 0.5);\n Arm.setPosition(0.135);\n sleep(1000);\n MyElevator.ElevateWithEncoder(0, 0.5, 0.003);\n\n LeftServo.setPosition(LeftServoUp);\n RightServo.setPosition(RightServoUp);\n MyDriveTrain.Rotate(0,0.4,10);\n MyDriveTrain.encoderDrive(0.3,-30,30,30,-30,2);\n ParkingMot.setPosition(ParkingMotIn);\n sleep(500);\n MyDriveTrain.encoderDrive(0.8, -5, 5, 5, -5, 1);\n MyDriveTrain.encoderDrive(0.5,-43,-43, -43,-43,1);\n }",
"protected void toggleLaser() {\n laserOn = !laserOn;\n }"
] | [
"0.6585142",
"0.6583487",
"0.64984214",
"0.6438942",
"0.63838786",
"0.62422544",
"0.61719",
"0.61717093",
"0.61076945",
"0.607654",
"0.6057839",
"0.60056996",
"0.60041595",
"0.5999707",
"0.59693646",
"0.59536797",
"0.59410506",
"0.5923412",
"0.59012246",
"0.58696944",
"0.5864918",
"0.5854775",
"0.5823992",
"0.58095556",
"0.5801796",
"0.57963586",
"0.5781341",
"0.57768077",
"0.5770375",
"0.576419",
"0.57617635",
"0.5760171",
"0.5751637",
"0.57482564",
"0.5746104",
"0.5745906",
"0.5740553",
"0.5702829",
"0.570078",
"0.5695064",
"0.56870073",
"0.56777483",
"0.5671252",
"0.56613487",
"0.5657518",
"0.56571555",
"0.56570864",
"0.5652213",
"0.5648163",
"0.5647246",
"0.564202",
"0.5637414",
"0.5636393",
"0.5634189",
"0.5629351",
"0.5627382",
"0.5624014",
"0.56223536",
"0.56217855",
"0.56111467",
"0.56109655",
"0.5608235",
"0.56045085",
"0.56028396",
"0.5596049",
"0.55959177",
"0.5573979",
"0.55728555",
"0.5570384",
"0.5570176",
"0.5563961",
"0.5561687",
"0.55595624",
"0.5554055",
"0.5550996",
"0.555078",
"0.55474067",
"0.55467343",
"0.5545443",
"0.55432534",
"0.5541074",
"0.55410093",
"0.55395293",
"0.553452",
"0.5533417",
"0.55317825",
"0.5531476",
"0.5529667",
"0.5527094",
"0.55163145",
"0.5516253",
"0.551386",
"0.5511945",
"0.5511413",
"0.55092233",
"0.55028343",
"0.5501983",
"0.54985774",
"0.54964286",
"0.5495716",
"0.5492855"
] | 0.0 | -1 |
Constructor takes the context to allow the database to be opened/created | public StoreDataInSQLite(Context ctx) {
this.mCtx = ctx;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Database(Context context)\n\t{\n\t\t/* Instanciation de l'openHelper */\n\t\tDBOpenHelper helper = new DBOpenHelper(context);\n\t\t\n\t\t/* Load de la database */\n\t\t//TODO passer en asynchrone pour les perfs\n\t\tmainDatabase = helper.getWritableDatabase();\n\t\t\n\t\t/* DEBUG PRINT */\n\t\tLog.i(\"info\", \"Database Loading Suceeded\");\n\t}",
"public Database(Context context) { \n\t\tsuper( context, database_MEF, null, 2); \n\t}",
"public Database(Context context) {\n super(context, DB_NAME, null, DB_VER);\n }",
"public Database(Context context) {\n super(context, nome_db, null, versao_db);\n }",
"public DatabaseAccess(Context context) {\n this.openHelper = new OlpbhtbDatabase(context);\n }",
"private DatabaseAccess(Context context) {\n this.openHelper = new MyDatabase(context);\n }",
"private DatabaseContext() {\r\n datastore = createDatastore();\r\n init();\r\n }",
"private DatabaseAccess(Context context) {\n this.openHelper = new DatabaseOpenHelper(context);\n }",
"public DatabaseHandler(Context context){\n super(context, \"tienda.db\", null, 1);\n }",
"private DatabaseAccess(Context context) {\n this.openHelper = new RecipesDatabase(context);\n }",
"public DatabaseHandler(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public DatabaseHandler(Context context) {\r\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\r\n }",
"public MyDBHandler(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public SQLHandler(Context context) {\n \t\tsuper(context, DATABASE_NAME, null, DATABASE_VERSION);\n \t}",
"public DBHandler(Context context) {\n super(context, DB_NAME, null, DB_VERSION);\n }",
"private DatabaseAccess(Context context){\n this.openHelper=new DatabaseOpenHelper(context);\n }",
"public DatabaseStorage(Context context)\n {\n this.database = new DatabaseStorageHelper(context);\n }",
"public SQLDataBase(Context context){ // is this supposed to be public?\n super(context, DATABASE_NAME, null, 1);\n }",
"public DBMS(Context context) {\n super(context, DBName, null, DBVersion);\n Log.e(\"DBMS=>\", \"yes Db bna d ha\");\n }",
"public SQLHandler(Context context) {\n super(context, DB_NAME, null, DB_VERSION);\n }",
"public SQLiteHandler(Context context) {\n\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"private DBHelper(Context context) {\n super(context, DB_NAME, null, DB_VERSION);\n }",
"public DatabaseBackend(Context context) {\n super(context, Db_name, null, Db_version);\n }",
"private DatabaseHelper(Context cont) {\n super(cont, DB_NAME, null, DB_VERSION);\n this.context = cont;\n }",
"public DataSource(Context context) {\n dbHelper = new MySQLiteHelper(context);\n database = dbHelper.getWritableDatabase();\n dbHelper.close();\n }",
"public SQLManager(Context context) {\n handler = new SQLHandler(context);\n }",
"public DBManager(Context context){ \n\t\thelper = new DBHelper(context); \n\t\tdb = helper.getWritableDatabase(); \n\t}",
"public GaelDbHelper( final Context context ){\n\tsuper( context, DATABASE_NAME, null, DATABASE_VERSION );\n\tmContext = context;\n\tlog.trace( \"GaelDbHelper.constructor():\" + DATABASE_NAME );\n}",
"public DBHelper(Context context) {\n super(context, Database_Name, null, 1);\n\n }",
"public GastoDAO(Context context){\n dbHelper = new MyDatabaseHelper(context);\n database = dbHelper.getWritableDatabase();\n }",
"public DatabaseHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n this.context = context;\n res = context.getResources();\n }",
"private CalendarDBhelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"private DatabaseHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public DbHelper(Context context) {\n super(context, DBNAME, null, 1);\n }",
"public UserInfoDatabase(Context context) {\r\n mDatabaseOpenHelper = new DatabaseOpenHelper(context);\r\n }",
"public DatabaseHelper(Context context) {\n super(context, DATABASE_NAME, null, 1);\n }",
"private Db() {\n super(Ke.getDatabase(), null);\n }",
"public DatabaseNoteHelper(@Nullable Context context) {\r\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\r\n }",
"public static void initialize(Context context) {\n _db = new DatabaseHandler(context);\n }",
"public DataBaseHelper(Context context) {\n \n \tsuper(context, DB_NAME, null, 1);\n this.myContext = context;\n }",
"public DatabaseOpenHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"private TodoDatabaseHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public SQLiteHelper(Context context) {\n\t\tsuper(context, getDefaultDatabaseName(context), null, DEFAULT_VERSION);\n\t\t\n\t\tLogger.log(\"Database path:\"+ context.getDatabasePath(getDefaultDatabaseName(context)));\n\t}",
"private LocalDatabaseSingleton(Context context) {\r\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\r\n this.mContext = context;\r\n }",
"public SQLHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public DBHelper(Context c) {\n\t\tsuper(c, DB_NAME, null, version);\n\t}",
"public DatabaseHelper(Context context) {\n super(context, \"caballoscocheros.db\", null);\n\n db = getWritableDatabase();\n DaoMaster daoMaster = new DaoMaster(db);\n daoSession = daoMaster.newSession();\n }",
"public DBConnections(Context context) {\n super(context, DbName, null, 1);\n\n }",
"public DbHelper(Context context) {\r\n\t\tsuper(context, DATABASE_NAME, null, VERSION);\r\n\t}",
"public DbOpenHelper(Context context)\n {\n super(context, DB_NAME, null, DB_VERSION);\n }",
"private DBHelper(Context context){\n this.context= context;\n tablesClass = new TablesClass(context, Constants.DATABASE_NAME,null,Constants.DB_VERSION);\n\n }",
"public DatabaseManager(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public ContextDaoImpl() {\n Set<Commissioner> commissionerSet = new HashSet<>();\n List<String> logins = new ArrayList<>();\n commissionerSet.add(new Commissioner(\"victor.net\", \"25345Qw&&\", true));\n commissionerSet.add(new Commissioner(\"egor.net\", \"3456eR&21\", false));\n commissionerSet.add(new Commissioner(\"igor.net\", \"77??SDSw23\", false));\n logins.add(\"victor@khoroshev.net\");\n logins.add(\"egor@khoroshev.net\");\n logins.add(\"igor@khoroshev.net\");\n Database.setCandidateSet(new HashSet<>());\n Database.setVoterSet(new HashSet<>());\n Database.setLogins(logins);\n Database.setCommissionerSet(commissionerSet);\n }",
"public Database()\r\n\t{\r\n\t\tinitializeDatabase();\r\n\t\t\r\n\t}",
"public DataBaseHelper(Context context) {\n\n super(context, DB_NAME, null, 1);\n this.myContext = context;\n }",
"public BookStorage (Context context) {\n\t\tsuper(context, DATABASE_NAME, null, DATABASE_VERSION);\n\t}",
"public MedDBOpenHelper(Context context) {\n super(context, databaseName, null, version);\n }",
"TaskDbHelper(Context context){\n super(context, DATA_BASE_NAME, null, DATABASE_VERSION);\n }",
"public ContextDaoImpl(Context context) {\n Database.setCandidateSet(context.getCandidateSet());\n Database.setVoterSet(context.getVoterSet());\n Database.setLogins(context.getLogins());\n Database.setCommissionerSet(context.getCommissionerSet());\n }",
"SmDatabaseHelper(Context context) {\n super(context, DBNAME, null, 1);\n }",
"private BankingDBOpenHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n mCtx = context;\n }",
"public DatabaseHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public DatabaseHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public TasksDataSource(Context context) {\n dbHelper = new SQLiteHelper(context);\n }",
"private CustomerDatabaseHelper(Context context){\n _openHelper = new DatabaseOpenHelper(context);\n }",
"public ExampleSQLiteOpenHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"private CustomerDbHelper(Context _context) {\n super(_context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public TrapDbHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public DbHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n mContext = context;\n }",
"public DB() {\r\n\t\r\n\t}",
"public NdbAdapter(Context context) {\n this.context = context;\n }",
"private DatabaseHandler(){\n createConnection();\n }",
"public DataBaseManager(Context context) {\n helper = new DataBaseHelper(context);\n db = helper.getWritableDatabase();\n }",
"public Storage(Context context) throws StorageException {\r\n sqlExecutor = new SqlExecutor(context);\r\n }",
"public SqliteDatabase(Context context) {\n super(context, databaseName, null, 2);\n SQLiteDatabase db = this.getWritableDatabase();\n\n // context.deleteDatabase(databaseName);\n }",
"public sqlDatabase() {\n }",
"public SelfieDatabaseHelper(Context context) {\n super(context,\n context.getCacheDir() + File.separator + DATABASE_NAME,\n null,\n DATABASE_VERSION);\n }",
"private PrimeNrDatabase(Context context){\n database = new PrimeNrBaseHelper(context).getWritableDatabase();\n }",
"public InventoryDbHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"DQDatabaseHelper(Context context) {\n\n\t\tsuper(context, DQDatabaseHelper.DB_NAME, null, DQDatabaseHelper.DATABASE_VERSION);\n\t\tthis.mContext = context;\n\t}",
"public MyDatabaseHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"private InstagramDbHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"private BeverageCollection(Context context) {\n mContext = context.getApplicationContext(); // Set the context of this to the application context. Not sure why we have to change this though.\n\n // Open the database file. If the first time its been created, call onCreate. If not the first time, call onUpgrade.\n mDatabase = new BeverageBaseHelper(mContext).getWritableDatabase();\n }",
"Context(final DatabaseMetaData databaseMetaData) {\n super();\n this.databaseMetaData = Objects.requireNonNull(databaseMetaData, \"databaseMetaData is null\");\n }",
"public DBAdapter(Context ctx) {\n this.context = ctx;\n myDBHelper = new DatabaseHelper(context);\n }",
"public Database() {\n if (init) {\n\n //creating Transaction data\n Transaction transactionOne\n = new Transaction(1, \"Debit\", \"Spar Grocery\", 54.68,1);\n\n transactionDB.add(transactionOne);\n\n // Creating an Account data\n Account accountOne = new Account(1, 445, 111111111, \"Savings\",\n 1250.24, transactionDB);\n\n accountDB.add(accountOne);\n\n //creating withdrawal data\n Withdrawal withdrawalOne = new Withdrawal(1, 64422545, 600.89);\n withdrawalDB.add(withdrawalOne);\n\n //creating transfer data\n Transfer transferOne = new Transfer(1, 25252525, 521.23);\n transferDB.add(transferOne);\n\n //creating lodgement data\n Lodgement lodgementOne = new Lodgement(1, 67766666, 521.23);\n lodgementDB.add(lodgementOne);\n\n //add Customer data \n Customer customerOne\n = new Customer(1, \"Darth Vader\", \"DarthVader@deathStar.com\",\n \"Level 5, Suit Dark\", \"darkSideIsGoodStuff\",\n accountDB, withdrawalDB, transferDB, lodgementDB);\n\n customerDB.add(customerOne);\n\n init = false;\n }\n }",
"private ContactModel(Context context) {\n mContext = context.getApplicationContext();\n mDatabase = new ContactBaseHelper(mContext)\n .getWritableDatabase();\n }",
"SimpleDatabaseHelper(Context context) {\n _openHelper = new SimpleSQLiteOpenHelper(context);\n }",
"public SQLiteHelper(Context context, String databaseName) {\n\t\tsuper(context, databaseName, null, DEFAULT_VERSION);\n\t}",
"public DatabaseOpenHelper(Context context, String sourceDirectory) {\n super(context, DATABASE_NAME, sourceDirectory, null);\n }",
"public DBManager(Context ctx) {\n this.mCtx = ctx;\n }",
"DatabaseHelper(Context context){\n super(context,BD_BOLSATRABAJO,null,vers);\n }",
"public static synchronized NoteDatabase getInstance(Context context){\n if(instance == null){//Instantiate if instance is null\n instance = Room.databaseBuilder(context.getApplicationContext(),NoteDatabase.class,\"note_database\")\n .fallbackToDestructiveMigration()\n .addCallback(roomCallBack)\n .build();\n }\n return instance;\n }",
"public NewFlashDBHelper(Context context) {\n super(context,Name_NewFlashDB,null,VERSION_DATABASE);\n }",
"DatabaseController(Context context){\n helper=new MyHelper(context);\n }",
"public QuizDatabaseHelper(Context context) {\n super(context, Database_name, null, Database_version);\n }",
"public ArticlesDBHelper(Context context) {\n super(context, DATABASE_NAME, null, DATABASE_VERSION);\n }",
"public Database(){\n ItemBox.getLogger().info(\"[Database] protocol version \" + net.mckitsu.itembox.protocol.ItemBoxProtocol.getVersion());\n }",
"public DataBase open(){\n myDB = new MyHelper(ourContext);\n myDataBase = myDB.getWritableDatabase();\n return this;\n }",
"private DatabaseCustomAccess(Context context) {\n\t\thelper = new SpokaneValleyDatabaseHelper(context);\n\n\t\tsaveInitialPoolLocation(); // save initial pools into database\n\t\tsaveInitialTotalScore(); // create total score in database\n\t\tsaveInitialGameLocation(); // create game location for GPS checking\n\t\tLoadingDatabaseTotalScore();\n\t\tLoadingDatabaseScores();\n\t\tLoadingDatabaseGameLocation();\n\t}",
"public SmsDatabase(Context context) {\n super(context);\n// dbHelper = new DatabaseHelper(context);\n// sqLiteDatabase = dbHelper.getWritableDatabase();\n }"
] | [
"0.82127976",
"0.8172776",
"0.79335254",
"0.7910171",
"0.78970575",
"0.78838015",
"0.7859239",
"0.7779108",
"0.77768016",
"0.7761403",
"0.7725226",
"0.77057046",
"0.7638482",
"0.76245964",
"0.7620207",
"0.761612",
"0.7555823",
"0.75352603",
"0.7511463",
"0.7485957",
"0.7453048",
"0.74477977",
"0.7407358",
"0.74015194",
"0.7392692",
"0.73734593",
"0.7369383",
"0.7356023",
"0.73157537",
"0.7284019",
"0.7282139",
"0.72793305",
"0.72673965",
"0.72391313",
"0.72368324",
"0.7222745",
"0.7218557",
"0.72168434",
"0.7212995",
"0.71978706",
"0.71959573",
"0.7194473",
"0.7189938",
"0.71876884",
"0.7184128",
"0.71811306",
"0.71629244",
"0.7151612",
"0.71390694",
"0.71334",
"0.7126839",
"0.71156734",
"0.7114215",
"0.7073431",
"0.7071272",
"0.7064841",
"0.7061598",
"0.7053626",
"0.7049205",
"0.7023382",
"0.70194703",
"0.70073456",
"0.70073456",
"0.7001398",
"0.6989253",
"0.69782937",
"0.69769007",
"0.69656044",
"0.69563115",
"0.69449973",
"0.69397914",
"0.6911857",
"0.6908775",
"0.68850297",
"0.68834376",
"0.68648237",
"0.68551546",
"0.68544275",
"0.684602",
"0.6844344",
"0.68408525",
"0.68391997",
"0.6831861",
"0.682284",
"0.6815505",
"0.6800845",
"0.6790336",
"0.67801744",
"0.6777971",
"0.67553645",
"0.6754436",
"0.67382824",
"0.6738006",
"0.6733468",
"0.6725278",
"0.67201984",
"0.66989464",
"0.6693671",
"0.66867954",
"0.66818094",
"0.66782314"
] | 0.0 | -1 |
Before the test is run set up the test data store helper and create a new instance of the | @Before
public void setUp() throws Exception {
testHelper.setUp();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void createTestData() {\n StoreEntity store = new StoreEntity();\n store.setStoreName(DEFAULT_STORE_NAME);\n store.setPecEmail(DEFAULT_PEC);\n store.setPhone(DEFAULT_PHONE);\n store.setImagePath(DEFAULT_IMAGE_PATH);\n store.setDefaultPassCode(STORE_DEFAULT_PASS_CODE);\n store.setStoreCap(DEFAULT_STORE_CAP);\n store.setCustomersInside(DEFAULT_CUSTOMERS_INSIDE);\n store.setAddress(new AddressEntity());\n\n // Create users for store.\n UserEntity manager = new UserEntity();\n manager.setUsercode(USER_CODE_MANAGER);\n manager.setRole(UserRole.MANAGER);\n\n UserEntity employee = new UserEntity();\n employee.setUsercode(USER_CODE_EMPLOYEE);\n employee.setRole(UserRole.EMPLOYEE);\n\n store.addUser(manager);\n store.addUser(employee);\n\n // Create a new ticket.\n TicketEntity ticket = new TicketEntity();\n ticket.setPassCode(INIT_PASS_CODE);\n ticket.setCustomerId(INIT_CUSTOMER_ID);\n ticket.setDate(new Date(new java.util.Date().getTime()));\n\n ticket.setArrivalTime(new Time(new java.util.Date().getTime()));\n ticket.setPassStatus(PassStatus.VALID);\n ticket.setQueueNumber(INIT_TICKET_QUEUE_NUMBER);\n store.addTicket(ticket);\n\n // Persist data.\n em.getTransaction().begin();\n\n em.persist(store);\n em.flush();\n\n // Saving ID generated from SQL after the persist.\n LAST_TICKET_ID = ticket.getTicketId();\n LAST_STORE_ID = store.getStoreId();\n LAST_MANAGER_ID = manager.getUserId();\n LAST_EMPLOYEE_ID = employee.getUserId();\n\n em.getTransaction().commit();\n }",
"@Before\r\n public void setup() {\r\n dbwMock.userId = \"testUser\";\r\n dbw = new DatabaseWrapper(dbwMock);\r\n\r\n context = ApplicationProvider.getApplicationContext();\r\n\r\n book = new Book();\r\n\r\n requester = new Profile();\r\n }",
"@Before\r\n public void setupTestCases() {\r\n instance = new ShoppingListArray();\r\n }",
"@BeforeClass\n public static void setUpBeforeClass() {\n TestNetworkClient.reset();\n context = ApplicationProvider.getApplicationContext();\n dataStorage = TestDataStorage.getInstance(context);\n ApplicationSessionManager.getInstance().startSession();\n }",
"@Before\n\tpublic void setUp() {\n\t\tgateInfoDatabase = new GateInfoDatabase();\t\t\n\t}",
"public StoreTest() {\n }",
"@Before\n public void setUp() throws Exception{\n sDataManager.getmNotes().clear();//before the test runs it should have an empty note\n sDataManager.initializeExampleNote();\n }",
"@BeforeEach\n void setUp() {\n Database database = Database.getInstance();\n database.runSQL(\"cleandb.sql\");\n\n noteDao = new GenericDao(Note.class);\n }",
"@BeforeEach\n public void setUp() throws Exception {\n\n helper = new DatabaseConfigurationTestHelper();\n helper.setUp();\n }",
"@Before\n\tpublic void setUp() throws Exception {\n\t\tscenario = getTac().useScenario(SimpleStoreScenario.class);\n\t\tcatalogPersister = getTac().getPersistersFactory().getCatalogTestPersister();\n\t\ttaxCode = getTac().getPersistersFactory().getTaxTestPersister().getTaxCode(TaxTestPersister.TAX_CODE_GOODS);\n\t}",
"@Before\n\tpublic void setup() {\n\t\tdatabase = new DatabaseLogic();\n\t}",
"@Before\n public void setupTests()\n {\n Service s1 = new Service();\n s1.setCategory(\"HAIR\");\n\n repository.save(s1);\n\n }",
"@BeforeClass (alwaysRun = true)\n public void dataPreparation()\n {\n serverHealth.isServerReachable();\n serverHealth.assertServerIsOnline();\n\n // Before we start testing the live indexing we need to use the reindexing component to index the system nodes.\n Step.STEP(\"Index system nodes.\");\n AlfrescoStackInitializer.reindexEverything();\n\n Step.STEP(\"Create a test user and private site.\");\n testUser = dataUser.createRandomTestUser();\n testSite = helper.createPrivateSite(testUser);\n }",
"@Before\r\n\tpublic void setUp() throws Exception {\r\n\r\n\t\tpd = new PreparedData();\r\n\r\n\t}",
"@Before\n public void setUp()\n {\n m_instance = ConversationRepository.getInstance();\n m_fileSystem = FileSystem.getInstance();\n }",
"protected Object createTest() throws Exception {\n Object test = super.createTest();\n dataPopulator.populate(test);\n return test;\n }",
"protected void setUp() throws Exception {\r\n super.setUp();\r\n this.testedInstances = new ManagerHelper[2];\r\n this.testedInstances[0] = new ManagerHelper();\r\n this.testedInstances[1] = new ManagerHelper(TestDataFactory.MANAGER_HELPER_NAMESPACE);\r\n }",
"@BeforeClass\n public static void setup() {\n getDatabase(\"mandarin\");\n }",
"@BeforeEach\n\tvoid init() {\n\t\tthis.repo.deleteAll();\n\t\tthis.testLists = new TDLists(listTitle, listSubtitle);\n\t\tthis.testListsWithId = this.repo.save(this.testLists);\n\t\tthis.tdListsDTO = this.mapToDTO(testListsWithId);\n\t\tthis.id = this.testListsWithId.getId();\n\t}",
"@BeforeEach\n void setUp() {\n\n Database database = Database.getInstance();\n database.runSQL(\"cleandb.sql\");\n\n genericDao = new GenericDao(Event.class);\n }",
"@Before\n public void setup() {\n Helpers.fillData();\n }",
"@BeforeClass\n public static void classSetUp() {\n printTestClassHeader();\n uri = Const.ActionURIs.ADMIN_INSTRUCTORACCOUNT_ADD;\n // removeAndRestoreTypicalDataInDatastore();\n }",
"@Before\n public void prepare() {\n MetaStore metadb = prepareTestDB();\n testObj = new SdbSchemeRewriter(metadb.getAllDBs().get(0));\n }",
"@Before\n\tpublic void setUp() throws Exception {\n\t\tDatabaseProvider.setInstance(new DerbyDatabase());\n\t\tdb = DatabaseProvider.getInstance();\t\t\n\t\t\n\t}",
"@BeforeClass\n public static void beforeTests() {\n pl = new LocalPersistenceLayer();\n\n DigitalCollection coll = new DigitalCollection(\"Test\");\n edummy = new Element(\"Dummy\", \"Dummy\");\n pdummy = new Property(\"Dummy\");\n vdummy = new ValueSource(\"Dummy\", \"0.1\");\n\n edummy.setCollection(coll);\n edummy.setCollection(coll);\n edummy.setCollection(coll);\n\n pl.handleCreate(DigitalCollection.class, coll);\n pl.handleCreate(Element.class, edummy);\n pl.handleCreate(Property.class, pdummy);\n pl.handleCreate(ValueSource.class, vdummy);\n }",
"@BeforeClass\n\tpublic static void setUp() throws Exception {\n\t\tdao = new SupplierOrderDao();\n\t\tsdao = new SupplierDao();\n\t\tpdao = new ProductDao();\n\t\tidao = new ItemSupplierOrderDao();\n\t\t\n\t\tSupplier supplier = new Supplier();\n\t\tsupplier.setName(\"Supplier\");\n\t\tsupplier = sdao.persist(supplier);\n\n\t\tProduct product = new Product();\n\t\tproduct.setProductSupplierId(1L);\n\t\tproduct.setSupplier(supplier);\n\t\tproduct = pdao.persist(product);\n\t}",
"@BeforeEach\n void setUp() {\n //Database database = Database.getInstance();\n //database.createDatabase(\"adhound.sql\");\n userData = new UserData();\n\n newUser = new User(\"testUsername@email.com\", \"testPassword\", \"testFirstName\", \"testLastName\", \"123-456-7890\", \"987-654-3210\", \"test@email.com\", \"123 Test Street\", \"testCity\", 33, \"12345\");\n\n ValidatorFactory factory = Validation.buildDefaultValidatorFactory();\n validator = factory.getValidator();\n }",
"@Override\n @Before\n public void setUp() throws Exception {\n super.setUp();\n\n entityManager = getEntityManager();\n\n logger = Logger.getLogger(getClass());\n\n instance = new UserServiceImpl();\n TestsHelper.setField(instance, \"logger\", logger);\n TestsHelper.setField(instance, \"entityManager\", entityManager);\n TestsHelper.setField(instance, \"supervisorRoleName\", supervisorRoleName);\n TestsHelper.setField(instance, \"adminRoleName\", adminRoleName);\n }",
"@Override\r\n public void setUp() throws Exception {\r\n super.setUp();\r\n\r\n dbOpenHelper = new DbOpenHelper(getContext());\r\n\r\n db = dbOpenHelper.getWritableDatabase();\r\n db.beginTransaction();\r\n dao = new ExtraPartsDAO(db);\r\n }",
"@Before\n public void initTest() {\n AccountCapsule ownerAccountFirstCapsule =\n new AccountCapsule(\n ByteString.copyFromUtf8(ACCOUNT_NAME_FIRST),\n ByteString.copyFrom(ByteArray.fromHexString(OWNER_ADDRESS_FIRST)),\n AccountType.Normal,\n 10000_000_000L);\n AccountCapsule ownerAccountSecondCapsule =\n new AccountCapsule(\n ByteString.copyFromUtf8(ACCOUNT_NAME_SECOND),\n ByteString.copyFrom(ByteArray.fromHexString(OWNER_ADDRESS_SECOND)),\n AccountType.Normal,\n 20000_000_000L);\n\n dbManager.getAccountStore()\n .put(ownerAccountFirstCapsule.getAddress().toByteArray(), ownerAccountFirstCapsule);\n dbManager.getAccountStore()\n .put(ownerAccountSecondCapsule.getAddress().toByteArray(), ownerAccountSecondCapsule);\n\n dbManager.getDynamicPropertiesStore().saveLatestBlockHeaderTimestamp(1000000);\n dbManager.getDynamicPropertiesStore().saveLatestBlockHeaderNumber(10);\n dbManager.getDynamicPropertiesStore().saveNextMaintenanceTime(2000000);\n }",
"protected void setUp() throws Exception {\n super.setUp();\n FailureTestHelper.loadConfig();\n FailureTestHelper.loadData();\n dao = new SQLServerGameDataDAO(\"com.orpheus.game.persistence.SQLServerGameDataDAO\");\n }",
"@Before\n public void setUp() throws Exception {\n HashMap<String, String> prop = PropertyReader.getProperties(ORACLEPROP);\n if (prop.get(\"schema\") != null && !prop.get(\"schema\").isEmpty())\n databaseTester = new JdbcDatabaseTester(prop.get(\"dbClass\"), prop.get(\"dbURL\"), prop.get(\"user\"), prop.get(\"pass\"), prop.get(\"schema\"));\n else\n databaseTester = new JdbcDatabaseTester(prop.get(\"dbClass\"), prop.get(\"dbURL\"), prop.get(\"user\"), prop.get(\"pass\"));\n\n // initialize your dataset here\n IDataSet dataSet = getDataSet();\n\n databaseTester.setDataSet(dataSet);\n // will call default setUpOperation\n databaseTester.onSetup();\n }",
"protected void setUp() throws Exception {\r\n super.setUp();\r\n target = new JPADigitalRunTrackStatusDAO();\r\n target.setUnitName(\"persistence_unit\");\r\n target.setSessionContext(context);\r\n }",
"@Before\r\n\tpublic void setUp() throws Exception {\r\n\r\n\t\toCont = new OperatorDAO();\r\n\t}",
"@Before\n public void setUp() {\n //clearDbData();//having some trouble\n }",
"@Before\n public void setUp(){\n cmTest = new CoffeeMaker();\n\n }",
"@BeforeClass\n\tpublic static void setup() {\n\t\tdataMunger = new DataMunger();\n\n\t}",
"@Before\n public void setUp() {\n start(fakeApplication(inMemoryDatabase(), fakeGlobal()));\n }",
"@Before\n public void setUp() throws Exception {\n userDao = DatabaseAccess.createOracleDatabase().createUserDaoOperator();\n }",
"@Before\r\n public void setUp() throws Exception {\r\n super.setUp();\r\n TestHelper.cleanupEnvironment();\r\n instance = new MockGetDocumentFileContestAction();\r\n instance.prepare();\r\n }",
"@BeforeEach\n void init() {\n\n EntityManagerFactory entityManagerFactory = Persistence.createEntityManagerFactory(\"pu\");\n employeeDao = new EmployeeDao(entityManagerFactory);\n\n\n }",
"@Before\n public void setUp() {\n delegate = LocusdetailDelegateFactory.getLocusDetailDelegate();\n // Clear any existing caches of objects using the memory manager set in\n // the creation of the delegate.\n clearCaches();\n assertTrue(\"No delegate created\", delegate != null);\n }",
"@Before\r\n\tpublic void setUp() {\r\n\t\tRandom r = new Random();\r\n\t\tmyID = r.nextInt(100);\r\n\t\tmyEntryData = new Entry_Database();\r\n\t\tfor (int i = 0; i < 20; i++) {\r\n\t\t\tEntry e = new Entry(myID);\r\n\t\t\te.setCat(\"Science\");\r\n\t\t\te.setEntry(new File(\"example.txt\"));\r\n\t\t\te.setName(\"Test Name\");\r\n\t\t\te.setNotes(\"\");\r\n\t\t\te.setScore(0);\r\n\t\t\tmyEntryData.addEntry(myID, e);\r\n\t\t}\r\n\t}",
"@Before\n public void setUp()\n {\n salesIte1 = new SalesItem(\"house\", 100000);\n salesIte2 = new SalesItem(\"car\", 1000);\n salesIte2.addComment(\"jack\", \"too slow\", 3);\n salesIte2.addComment(\"ben\", \"too old\", 2);\n }",
"@Before\n public void setUp() throws Exception {\n instance = new User();\n }",
"@Before\n\tpublic void setUp() throws Exception {\n\t\tcatalogTestPersister = persisterFactory.getCatalogTestPersister();\n\t\tsettingsTestPersister = persisterFactory.getSettingsTestPersister();\n\t\ttaxCode = persisterFactory.getTaxTestPersister().getTaxCode(TaxTestPersister.TAX_CODE_GOODS);\n\t}",
"@SuppressWarnings(\"serial\")\n @Before\n public void setUp() throws Exception {\n testInstance = new ClientsPrepopulatingBaseAction() {\n };\n }",
"@Before\n public void setUp() throws Exception {\n storage = new DocumentStorage(9494);\n }",
"@BeforeClass\n public static void setUpBeforeClass() throws Exception {\n dbService = DatabaseServiceFactory.getInstance();\n }",
"public void testSetBasedata() {\n }",
"@BeforeClass\r\n\tpublic void setUp() {\n\t\tdriver = BrowserFactory.startApplication(DataProviderFactory.getConfig().getStagingURL(), DataProviderFactory.getConfig().getBrowser());\r\n\t}",
"public DataStoreTest( String testName )\n {\n super( testName );\n }",
"@Override\n protected void setUp() throws Exception {\n super.setUp();\n mDBService = new DBService(getContext());\n deleteAllRecords();\n }",
"public ImportTestsController() {\n App app = App.getInstance();\n Company company = app.getCompany();\n clientStore = company.getClientStore();\n authFacade = company.getAuthFacade();\n testStore = company.getTestStore();\n testTypeStore = company.getTestTypeStore();\n parameterStore = company.getParameterStore();\n clinicalStore = company.getClinicalStore();\n }",
"@Before\n\tpublic void setUpData() {\n\n\t\t// Make sure there is a type in the database\n\t\tType defaultType = new Type();\n\t\tdefaultType.setName(\"type\");\n\t\ttypeService.save(defaultType);\n\n\t\t// Make sure there is a seed packet in the database\n\t\tSeedPacket seedPacket = new SeedPacketBuilder()\n\t\t\t\t.withName(\"seed\")\n\t\t\t\t.withType(\"type\")\n\t\t\t\t.withPackSize(500).build();\n\n\t\tseedPacketService.save(seedPacket);\n\t}",
"public void setUp() {\n entity = new Entity(BaseCareerSet.FIGHTER);\n }",
"@Before\r\n\tpublic void setup() throws Exception {\n\t\tinitializeInMemoryDatabase();\r\n\r\n\t\t// Created from org.openmrs.test.CreateInitialDataSet\r\n\t\t// without line for \"concept_synonym\" table (not exist)\r\n\t\t// using 1.4.4-createdb-from-scratch-with-demo-data.sql\r\n\t\t// Removed all empty short_name=\"\" from concepts\r\n\t\t// Added missing description to relationship_type\r\n\t\t// Removed all patients and related patient/person info (id 2-500)\r\n\t\t// Removed all concepts except those in sqldiff\r\n\t\texecuteDataSet(\"initial-openmrs-dataset.xml\");\r\n\r\n\t\t// Includes Motech data added in sqldiff\r\n\t\texecuteDataSet(\"motech-dataset.xml\");\r\n\t\t\r\n\t\t// Add example Location, Facility and Community\r\n\t\texecuteDataSet(\"facility-community-dataset.xml\");\r\n\r\n\t\tauthenticate();\r\n\r\n\t\tactivator.startup();\r\n\t}",
"@Before\n\tpublic void setUp() throws Exception {\n//\t\tdao = new MonkeyDao();\n\t}",
"@BeforeEach\n void setUp() {\n\n\n // repopulate the table I'm testing\n com.lukebusch.test.util.Database database = com.lukebusch.test.util.Database.getInstance();\n database.runSQL(\"cleandb.sql\");\n\n genericDao = new GenericDao( User.class );\n\n }",
"@BeforeEach\n void setup() {\n String contentType = getContentType();\n preload(contentType, \"staff\", true);\n }",
"@BeforeEach\n void setUp(){\n DatabaseTwo database = DatabaseTwo.getInstance();\n database.runSQL(\"cleanAll.sql\");\n\n genericDao = new GenericDao(CompositionInstrument.class);\n }",
"@BeforeEach\n void setup() {\n String contentType = getContentType();\n preload(contentType, \"staff\", false);\n }",
"@BeforeClass\n\tpublic static void init() {\n\t\ttestProduct = new Product();\n\t\ttestProduct.setPrice(1000);\n\t\ttestProduct.setName(\"Moto 360\");\n\t\ttestProduct.setDescrip(\"Moto 360 smart watch for smart generation.\");\n\n\t\ttestReview = new Review();\n\t\ttestReview.setHeadline(\"Excellent battery life\");\n\t\ttestReview.setContent(\"Moto 360 has an excellent battery life of 10 days per full charge.\");\n\t}",
"@Before\n public void setUp() {\n \tserver = super.populateTest();\n }",
"@BeforeTest\n public void setUp() {\n UrlaubrWsUtils.migrateDatabase(TravelServiceImpl.DEFAULT_URL, TravelServiceImpl.DEFAULT_USER, TravelServiceImpl.DEFAULT_PASSWORD);\n\n service = new TravelServiceImpl();\n }",
"@Before\n public void setup() {\n endpoint = new Endpoint();\n endpoint.setKey(1);\n endpoint.setUrl(URI.create(\"http://localhost/nmr\"));\n\n // Installation, synchronized against\n installation = new Installation();\n installation.setType(InstallationType.TAPIR_INSTALLATION);\n installation.addEndpoint(endpoint);\n\n // Populated Dataset\n dataset = prepareDataset();\n\n // RegistryUpdater, using mocked web service client implementation\n updater = new RegistryUpdater(datasetService, metasyncHistoryService);\n }",
"@BeforeEach\n void setUp() {\n\n Database database = Database.getInstance();\n database.runSQL(\"cleanDb.sql\");\n\n\n genericDao = new GenericDao(UserRoles.class);\n }",
"protected void setUp() throws Exception {\r\n AccuracyTestHelper.clearConfig();\r\n AccuracyTestHelper.loadXMLConfig(AccuracyTestHelper.CONFIG_FILE);\r\n AccuracyTestHelper.loadXMLConfig(AccuracyTestHelper.AUDIT_CONFIG_FILE);\r\n AccuracyTestHelper.setUpDataBase();\r\n AccuracyTestHelper.setUpEJBEnvironment(null, null, null);\r\n\r\n DBConnectionFactory dbFactory = new DBConnectionFactoryImpl(AccuracyTestHelper.DB_FACTORY_NAMESPACE);\r\n AuditManager auditManager = new AuditDelegate(AccuracyTestHelper.AUDIT_NAMESPACE);\r\n TaskTypeDAO taskTypeDao = new DbTaskTypeDAO(dbFactory, AccuracyTestHelper.CONNECTION_NAME,\r\n \"TaskTypeIdGenerator\", AccuracyTestHelper.SEARCH_NAMESPACE, auditManager);\r\n TimeStatusDAO timeStatusDao = new DbTimeStatusDAO(dbFactory, AccuracyTestHelper.CONNECTION_NAME,\r\n \"TimeStatusIdGenerator\", AccuracyTestHelper.SEARCH_NAMESPACE, auditManager);\r\n\r\n instance = new DbTimeEntryDAO(dbFactory, AccuracyTestHelper.CONNECTION_NAME, \"TimeEntryIdGenerator\",\r\n AccuracyTestHelper.SEARCH_NAMESPACE, auditManager, taskTypeDao, timeStatusDao);\r\n }",
"@Before\n public void setUp() {\n model = new ImportAttributeModel();\n }",
"@Before\n public void setUp() {\n e1 = new Employee(\"Pepper Potts\", 16.0, 152);\n e2 = new Employee(\"Nancy Clementine\", 22.0, 140);\n\n }",
"@Before\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n try {\n em.getTransaction().begin();\n //Delete all, since some future test cases might add/change data\n em.createQuery(\"delete from Customer\").executeUpdate();\n //Add our test data\n Customer c1 = new Customer(\"Kurt\", \"Hansen\");\n Customer c2 = new Customer(\"Hans\", \"Jensen\");\n Customer c3 = new Customer(\"Bjarne\", \"Olsen\");\n em.persist(c1);\n em.persist(c2);\n em.persist(c3);\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@BeforeEach\n void setUp() {\n dao = new GenericDao(User.class);\n Database database = Database.getInstance();\n database.runSQL(\"cleandb.sql\");\n }",
"@Before public void setUp() { }",
"@BeforeEach\n public void setUp() {\n testUserLoginRes = new LoginData(\n CURRENT_USER.getUserId(),\n CURRENT_USER.getPassword()\n );\n }",
"@BeforeClass\n public static void before() {\n final EntityManagerFactory factory = Persistence.createEntityManagerFactory(\"testpersistence\");\n jpa = new StandaloneJpaDao(factory.createEntityManager());\n handler = new QuotePaymentHandler(jpa);\n }",
"public void setUp() {\n super.setUp();\n dbSessionClearCache();\n if(!compare()) {\n clear();\n populate();\n }\n dbSessionClearCache();\n }",
"@BeforeEach\n void setup() {\n String contentType = getContentType();\n preload(contentType, \"hc_staff\", false);\n }",
"@Before\n public void onSetUpBeforeTransaction() throws Exception {\n super.onSetUpBeforeTransaction();\n\n // load up any other needed spring beans\n\n // setup the mock objects if needed\n\n // create and setup the object to be tested\n hierarchyLogicImpl = new ExternalHierarchyLogicImpl();\n hierarchyLogicImpl.setDao(evaluationDao);\n //hierarchyLogicImpl.setHierarchyService(hierarchyService);\n\n }",
"@Override\r\n\tprotected void setUp() throws Exception {\n\t\tsuper.setUp();\r\n\t\timpl=new ProductDAOImpl();\r\n\t}",
"@BeforeEach\n void setUp() {\n ramenMapService = new RamenMapService();\n ramenMapService.save(Ramen.builder().id(OWNERID).build());\n }",
"@BeforeEach\n void setup() {\n String contentType = getContentType();\n preload(contentType, \"staffNS\", true);\n }",
"protected void setUp() {\r\n auditDetail = new AuditDetail();\r\n }",
"@BeforeEach\n public void setup() {\n testTaskList = new TaskList();\n testUi = new Ui();\n\n Event testEvent = new Event(\"Daily Work\", \"CS2113T\", Parser.parseDate(\"31/01/20 0800\"),\n Parser.parseDate(\"31/01/20 1200\"), \"testing\");\n Assignment testAssign = new Assignment(\"Daily Work\", \"CS2113T\", Parser.parseDate(\"20/03/20 0000\"),\n \"testing\");\n testTaskList.addTask(testEvent);\n testTaskList.addTask(testAssign);\n }",
"public static void initGenerateOfflineTestData(){\n dbInstance = Database.newInstance();\n initPlayer();\n initMatches();\n }",
"public void createDataStore (){\n\t\tcloseActiveStoreData ();\n\t\tif (_usablePersistenceManager){\n\t\t\tclosePersistence ();\n\t\t}\n\t\tsetDatastoreProperties ();\n\t\tthis.pm = DataStoreUtil.createDataStore (getDataStoreEnvironment (), true);\n\t\t_usablePersistenceManager = true;\n\t}",
"@Before\n public void init() {\n theaterChainRepository.getMongoTemplate().save(savedTheaterChain);\n }",
"@Before\n public void setUp() throws Exception {\n this.trainer = repository.save(TrainerFactory.getTrainer(1,\"Dillyn\",\"Lakey\",\"Boss\"));\n }",
"@BeforeEach\n void setUp() {\n testBookServiceImpl = new BookServiceImpl(bookRepository, userService, modelMapper);\n }",
"@Before\n public void initDb() {\n mDatabase = Room.inMemoryDatabaseBuilder(InstrumentationRegistry.getContext(),\n ToDoDatabase.class).build();\n }",
"@Before\n\tpublic void setUp() throws Exception\n\t{\n\n\t\tPlayer currentPlayer = new Player(\"joe\");\n\t\tcurrentPlayer.getInventory().add(new Crack(0,\"itemName\", \"description\", 100));\n\t\tDWD content = new DWD(currentPlayer);\n\t\tScanner scanner = new Scanner(System.in);\n\t\tgls = new GameLogicService(content, scanner);\n\t\tgls.init(currentPlayer.getName());\n\n\t}",
"@Before\r\n public void setUp() throws Exception {\r\n super.setUp();\r\n\r\n connection = getConnection();\r\n\r\n configurationObject = TestsHelper.getConfig(TestsHelper.CONFIG_PROJECT_TERMS);\r\n\r\n instance = new ProjectTermsOfUseDaoImpl(configurationObject);\r\n }",
"@org.junit.Before\n public void setUp() throws Exception {\n theModel = new Model();\n }",
"private void createTestDataSet() throws Exception {\n LOG.info(\"creating test data set...\"); \n Database db = null;\n try {\n db = this._category.getDatabase();\n db.begin();\n\n LazyEmployee person = new LazyEmployee();\n person.setFirstName(\"First\");\n person.setLastName(\"Person\");\n person.setBirthday(JDO_ORIGINAL_DATE);\n person.setStartDate(JDO_ORIGINAL_DATE);\n\n LazyAddress address1 = new LazyAddress();\n address1.setId(1);\n address1.setStreet(Integer.toString(1) + JDO_ORIGINAL_STRING);\n address1.setCity(\"First City\");\n address1.setState(\"AB\");\n address1.setZip(\"10000\");\n address1.setPerson(person);\n\n LazyAddress address2 = new LazyAddress();\n address2.setId(2);\n address2.setStreet(Integer.toString(2) + JDO_ORIGINAL_STRING);\n address2.setCity(\"Second City\");\n address2.setState(\"BC\");\n address2.setZip(\"22222\");\n address2.setPerson(person);\n\n LazyAddress address3 = new LazyAddress();\n address3.setId(3);\n address3.setStreet(Integer.toString(3) + JDO_ORIGINAL_STRING);\n address3.setCity(\"Third Ave\");\n address3.setState(\"AB\");\n address3.setZip(\"30003\");\n address3.setPerson(person);\n\n ArrayList addresslist = new ArrayList();\n addresslist.add(address1);\n addresslist.add(address2);\n addresslist.add(address3);\n\n person.setAddress(addresslist);\n\n LazyPayRoll pr1 = new LazyPayRoll();\n pr1.setId(1);\n pr1.setHoliday(15);\n pr1.setHourlyRate(25);\n pr1.setEmployee(person);\n person.setPayRoll(pr1);\n\n LazyContractCategory cc = new LazyContractCategory();\n cc.setId(101);\n cc.setName(\"Full-time slave\");\n db.create(cc);\n\n LazyContractCategory cc2 = new LazyContractCategory();\n cc2.setId(102);\n cc2.setName(\"Full-time employee\");\n db.create(cc2);\n \n ArrayList category = new ArrayList();\n category.add(cc);\n category.add(cc2);\n\n LazyContract con = new LazyContract();\n con.setPolicyNo(1001);\n con.setComment(\"80 hours a week, no pay hoilday, \"\n + \"no sick leave, arrive office at 7:30am everyday\");\n con.setContractNo(78);\n con.setEmployee(person);\n con.setCategory(category);\n person.setContract(con);\n \n db.create(person);\n \n db.commit();\n db.close();\n } catch (Exception e) {\n LOG.error(\"createTestDataSet: exception caught\", e);\n throw e;\n }\n }",
"protected void setUp() throws Exception {\n super.setUp();\n }",
"@BeforeEach\n void setUp() {\n personListTest = new ArrayList<>();\n test_Person = new Person(\"Jane\",\"Dorian\",\n \"987 Westbrook Blvd\",\"Chincinnati\",\"OH\",\"43123\",\"123456789\");\n\n// model.addColumn(\"Col1\");\n// model.addColumn(\"Col2\");\n// model.addColumn(\"Col3\");\n// model.addColumn(\"Col4\");\n// model.addColumn(\"Col5\");\n// model.addColumn(\"Col6\");\n// model.addColumn(\"Col7\");\n test_AddressBook = new AddressBook();\n controllerTest = new AddressBookController(test_AddressBook);\n }",
"@BeforeClass\n public static void initTestClass() throws Exception {\n Map props = MapUtil.mapIt(\"hibernate.connection.url\", \"jdbc:mysql://localhost:3306/event_test\");\n SnowTestSupportNG.initWebApplication(\"src/main/webapp\", props);\n\n inView = appInjector.getInstance(HibernateSessionInViewHandler.class);\n categoryDao = appInjector.getInstance(CategoryDao.class);\n }",
"protected void setUp() {\r\n entry = new ExpenseEntry();\r\n }",
"@Before\n public void setUp() throws Exception {\n dataSource1 = createDataSource(\"jdbc:hsqldb:mem:foodb\");\n createTableWithTestData(dataSource1);\n\n dataSource2 = createDataSource(\"jdbc:hsqldb:mem:bardb\");\n createTableWithTestData(dataSource2);\n }",
"@Before\n public void setUp() {\n InternalDataSerializer.reinitialize();\n }",
"@Before\n\tpublic void setup()\n\t{\n\t\tEbean.execute(Ebean.createCallableSql(dropDdl));\n\t\tEbean.execute(Ebean.createCallableSql(createDdl));\n\n\t\tpr1 = new Province();\n\t\tpr1.provinceId = 1;\n\t\tpr1.abbreviation = \"P1\";\n\t\tpr1.save();\n\n\t\tc1 = new City();\n\t\tc1.cityId = 11;\n\t\tc1.cityParentId = 1;\n\t\tc1.cityName = \"Fake1\";\n\t\tc1.province = pr1;\n\t\tc1.save();\n\n\t\tpr2 = new Province();\n\t\tpr2.provinceId = 2;\n\t\tpr2.abbreviation = \"P2\";\n\t\tpr2.save();\n\n\t\tc2 = new City();\n\t\tc2.cityId = 22;\n\t\tc2.cityParentId = 2;\n\t\tc2.cityName = \"Fake2\";\n\t\tc2.province = pr2;\n\t\tc2.save();\n\n\t\tsetupDelegate();\n\n\t}"
] | [
"0.7190607",
"0.69202185",
"0.6878658",
"0.67928916",
"0.6759698",
"0.67040193",
"0.6683036",
"0.6678973",
"0.66649634",
"0.6642202",
"0.66134113",
"0.65744615",
"0.65262944",
"0.64912534",
"0.64276975",
"0.6422596",
"0.6412321",
"0.6393823",
"0.63898575",
"0.6383117",
"0.63790977",
"0.6372835",
"0.63523364",
"0.63407797",
"0.63333726",
"0.63272595",
"0.63267386",
"0.63180536",
"0.6315635",
"0.63078636",
"0.63004255",
"0.62856925",
"0.62697226",
"0.62694323",
"0.6269421",
"0.62482953",
"0.6247292",
"0.62457114",
"0.62365305",
"0.62287277",
"0.6225453",
"0.6209433",
"0.6208217",
"0.62065125",
"0.6204778",
"0.6204421",
"0.62017894",
"0.6201458",
"0.6201188",
"0.61989474",
"0.6196419",
"0.619379",
"0.6190508",
"0.6187322",
"0.61861813",
"0.6184958",
"0.61778855",
"0.61699486",
"0.6160063",
"0.6159649",
"0.6156551",
"0.61376446",
"0.6133666",
"0.6133145",
"0.61314577",
"0.6125157",
"0.61247563",
"0.612202",
"0.61183447",
"0.6118008",
"0.6111001",
"0.61058694",
"0.61048156",
"0.60987717",
"0.60927695",
"0.6092678",
"0.6090279",
"0.60896105",
"0.6089167",
"0.60819995",
"0.60816556",
"0.60725224",
"0.6063455",
"0.6062297",
"0.6061683",
"0.6049646",
"0.60486776",
"0.60443467",
"0.6037737",
"0.60362566",
"0.6036184",
"0.6031381",
"0.60267526",
"0.60260445",
"0.60099983",
"0.60061955",
"0.59964716",
"0.59946024",
"0.59940094",
"0.59858423"
] | 0.63317347 | 25 |
After the test is run, user the helper to remove the data store entities that were involved in the test as they are unneeded | @After
public void tearDown() throws Exception {
testHelper.tearDown();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@BeforeEach\n\tpublic void cleanDataBase()\n\t{\n\t\taddRepo.deleteAll()\n\t\t.as(StepVerifier::create) \n\t\t.verifyComplete();\n\t\t\n\t\tdomRepo.deleteAll()\n\t\t.as(StepVerifier::create) \n\t\t.verifyComplete();\n\t}",
"@After\n public void after() {\n pl.getEntityManager().clear();\n }",
"@After\n public void teardown() {\n for (UseTypeEntity thisEntity : entities) {\n me.deleteUseTypeEntity(thisEntity);\n }\n\n // clean up\n me = null;\n testEntity = null;\n entities = null;\n\n }",
"@After\n public void tearDown() throws Exception {\n if (!persistentDataStore) {\n datastore.deleteByQuery(datastore.newQuery());\n datastore.flush();\n datastore.close();\n }\n }",
"@Before\n public void setUp() {\n //clearDbData();//having some trouble\n }",
"@After\n\tpublic void tearDown() throws Exception {\n\t\tydelseService.setEntityManager(null);\n\t}",
"@After\r\n public void tearDown(){\r\n \r\n Post post = entityManager.createNamedQuery(\"Post.fetchAllRecordsByUserId\", Post.class)\r\n .setParameter(\"value1\", 1l)\r\n .getSingleResult();\r\n \r\n assertNotNull(post);\r\n \r\n entityTransaction.begin();\r\n entityManager.remove(post);\r\n entityTransaction.commit();\r\n\r\n entityManager.close();\r\n }",
"@AfterEach\n public void tearDown() {\n objectStoreMetaDataService.findAll(ObjectStoreMetadata.class,\n (criteriaBuilder, objectStoreMetadataRoot) -> new Predicate[0],\n null, 0, 100).forEach(metadata -> {\n metadata.getDerivatives().forEach(derivativeService::delete);\n objectStoreMetaDataService.delete(metadata);\n });\n objectUploadService.delete(objectUpload);\n }",
"@AfterClass\n\tpublic static void cleanIndex() {\n\t\tEntityTest et = new EntityTest(id, \"EntityTest\");\n\t\tRedisQuery.remove(et, id);\n\t}",
"@AfterClass\n public static void afterStories() throws Exception {\n Thucydides.getCurrentSession().clear();\n }",
"@After\n public void cleanDatabaseTablesAfterTest() {\n databaseCleaner.clean();\n }",
"@Test\n public void shouldDeleteAllDataInDatabase(){\n }",
"@AfterSuite\r\n\tpublic void tearDown()\r\n\t{\n extent.flush();\r\n\t}",
"public void setUp() {\n deleteAllRecords();\n }",
"@After\n public void tearDown() throws Exception {\n File dbFile = new File(\"./data/clinicmate.h2.db\");\n dbFile.delete();\n dbFile = new File(\"./data/clinicmate.trace.db\");\n dbFile.delete();\n }",
"@After\n\tpublic void testOut() {\n\t\tList<VehicleType> all = vehicleTypeService.getAll();\n\t\tfor (VehicleType vehicleType : all) {\n\t\t\tvehicleTypeService.delete(vehicleType.getId());\n\t\t}\n\t}",
"@Override\n @After\n public void teardown() throws Exception {\n EveKitUserAccountProvider.getFactory()\n .runTransaction(() -> {\n EveKitUserAccountProvider.getFactory()\n .getEntityManager()\n .createQuery(\"DELETE FROM Opportunity \")\n .executeUpdate();\n });\n OrbitalProperties.setTimeGenerator(null);\n super.teardown();\n }",
"@After\n public void tearDown() {\n userRepository.deleteAll();\n }",
"@After\n public void tearDown() {\n addressDelete.setWhere(\"id = \"+addressModel1.getId());\n addressDelete.execute();\n\n addressDelete.setWhere(\"id = \"+addressModel2.getId());\n addressDelete.execute();\n\n addressDelete.setWhere(\"id = \"+addressModel3.getId());\n addressDelete.execute();\n\n\n personDelete.setWhere(\"id = \"+personModel1.getId());\n personDelete.execute();\n\n personDelete.setWhere(\"id = \"+personModel2.getId());\n personDelete.execute();\n\n personDelete.setWhere(\"id = \"+personModel3.getId());\n personDelete.execute();\n\n cityDelete.setWhere(\"id = \"+cityModel1.getId());\n cityDelete.execute();\n\n cityDelete.setWhere(\"id = \"+cityModel2.getId());\n cityDelete.execute();\n }",
"@After\r\n public void cleanTestObject()\r\n {\r\n testLongTermStorage.resetInventory();\r\n }",
"@BeforeEach\n @AfterEach\n public void clearDatabase() {\n \taddressRepository.deleteAll();\n \tcartRepository.deleteAll();\n \tuserRepository.deleteAll();\n }",
"@After\n\tpublic void tearDown() {\n\t\theroRepository.delete(HERO_ONE_KEY);\n\t\theroRepository.delete(HERO_TWO_KEY);\n\t\theroRepository.delete(HERO_THREE_KEY);\n\t\theroRepository.delete(HERO_FOUR_KEY);\n\t\theroRepository.delete(\"hero::counter\");\n\t}",
"@BeforeEach\n void setUp() {\n widgetRepository.deleteAll();\n }",
"@BeforeEach\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n try {\n em.getTransaction().begin();\n em.createNamedQuery(\"Movie.deleteAllRows\").executeUpdate();\n em.persist(m1);\n em.persist(m2);\n em.persist(m3);\n\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@Test\n public void testDeleteAllUserData() {\n storage().deleteAllUserData();\n createSomeUserData();\n Assertions.assertEquals(8, countStorageEntities());\n // ^ TODO Change to 9 after https://github.com/Apicurio/apicurio-registry/issues/1721\n // Delete all\n storage().deleteAllUserData();\n Assertions.assertEquals(0, countStorageEntities());\n }",
"@AfterClass\r\n public static void cleanUpTestFixture(){\r\n entityManagerFactory.close();\r\n }",
"@BeforeEach\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n try {\n em.getTransaction().begin();\n em.createNamedQuery(\"Cars.deleteAllCars\").executeUpdate();\n em.persist(c1);\n em.persist(c2); \n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@Before\n public void setUp() {\n\n EntityManager em = emf.createEntityManager();\n try {\n em.getTransaction().begin();\n //Delete all, since some future test cases might add/change data\n em.createQuery(\"delete from Car\").executeUpdate();\n //Add our test data\n Car e1 = new Car(\"Volvo\");\n Car e2 = new Car(\"WW\");\n em.persist(e1);\n em.persist(e2);\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@BeforeClass\n public static void beforeStories() throws Exception {\n Thucydides.getCurrentSession().clear();\n }",
"@After\n public void tearDown() {\n\t\trepository.delete(dummyUser);\n System.out.println(\"@After - tearDown\");\n }",
"@Before\n public void beforeTest() {\n collection = mongoDB.getCollection(\"assets\");\n collection.remove(new BasicDBObject());\n\n }",
"@BeforeEach\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n\n try {\n em.getTransaction().begin();\n em.createQuery(\"DELETE FROM Book\").executeUpdate();\n em.createNamedQuery(\"RenameMe.deleteAllRows\").executeUpdate();\n em.persist(b1 = new Book(\"12312\", \"harry potter\", \"Gwenyth paltrow\", \"egmont\", \"1999\"));\n em.persist(b2 = new Book(\"8347\", \"harry potter2\", \"Gwenyth paltrow\", \"egmont\", \"1998\"));\n em.persist(b3 = new Book(\"1231\", \"harry potter3\", \"Gwenyth paltrow\", \"egmont\", \"1997\"));\n\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@After\n public void tearDown() {\n try(Connection con = DB.sql2o.open()) {\n String deleteClientsQuery = \"DELETE FROM clients *;\";\n String deleteStylistsQuery = \"DELETE FROM stylists *;\";\n con.createQuery(deleteClientsQuery).executeUpdate();\n con.createQuery(deleteStylistsQuery).executeUpdate();\n }\n }",
"@AfterClass\n public static void tearDown() {\n em.clear();\n em.close();\n emf.close();\n }",
"@Override\n public void setUp() {\n deleteTheDatabase();\n }",
"@Before\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n try {\n em.getTransaction().begin();\n //Delete all, since some future test cases might add/change data\n em.createQuery(\"delete from Customer\").executeUpdate();\n //Add our test data\n Customer c1 = new Customer(\"Kurt\", \"Hansen\");\n Customer c2 = new Customer(\"Hans\", \"Jensen\");\n Customer c3 = new Customer(\"Bjarne\", \"Olsen\");\n em.persist(c1);\n em.persist(c2);\n em.persist(c3);\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@Before\n\tpublic void setUp() throws Exception {\n\t\ttry {\n\t\t\temf = Persistence.createEntityManagerFactory(\"DistribSubastaCoreEM\");\n\t\t dao.setEm(emf.createEntityManager());\n\t\t dao.getEm().setFlushMode(FlushModeType.COMMIT);\n\t\t dao.getEm().getEntityManagerFactory().getCache().evictAll();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\tfail();\n\t\t}\n\t}",
"@BeforeEach\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n p1 = new Person(\"Kim\", \"Hansen\", \"123456789\");\n p2 = new Person(\"Pia\", \"Hansen\", \"111111111\");\n try {\n em.getTransaction().begin();\n em.createNamedQuery(\"Person.deleteAllRows\").executeUpdate();\n em.persist(p1);\n em.persist(p2);\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@BeforeClass\n public static void clean() {\n DatabaseTest.clean();\n }",
"@Ignore //DKH\n @Test\n public void testMakePersistent() {\n }",
"public void setUp() {\n deleteTheDatabase();\n }",
"public void setUp() {\n deleteTheDatabase();\n }",
"@BeforeEach\n void setUp(){\n DatabaseTwo database = DatabaseTwo.getInstance();\n database.runSQL(\"cleanAll.sql\");\n\n genericDao = new GenericDao(CompositionInstrument.class);\n }",
"@AfterClass\n\tpublic static void teardown() {\n\t\tdataMunger = null;\n\n\t}",
"@Before\n public void setUp() throws Exception{\n sDataManager.getmNotes().clear();//before the test runs it should have an empty note\n sDataManager.initializeExampleNote();\n }",
"@Override\r\n\tprotected void tearDown() throws Exception {\n\r\n\t\tdao.insert(\"delete from system.tables where table_id='0000001' and table_name='emp0'\");\r\n\t\tdao.insert(\"delete from system.tables where table_id='0000002' and table_name='dept0'\");\r\n\t\tdao.insert(\"delete from system.tables where table_id='0000003' and table_name='emp'\");\r\n\t\tdao.insert(\"delete from system.tables where table_id='0000004' and table_name='dept'\");\r\n\t\tdao.insert(\"delete from system.databases where database_id='00001' and database_name='database1'\");\r\n\t\tdao.insert(\"delete from system.databases where database_id='00002' and database_name='database2'\");\r\n\t\tdao.insert(\"delete from system.users where user_name='scott'\");\r\n\r\n\t\tdao.insert(\"commit\");\r\n//\t\tdao.disconnect();\r\n\t}",
"protected void tearDown() {\r\n instance = null;\r\n columnNames = null;\r\n }",
"@BeforeEach\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n j1 = new Joke(1,\"dårlig joke 1\", \"type1\");\n j2 = new Joke(2,\"dårlig joke 2\", \"type2\");\n j3 = new Joke(3,\"dårlig joke 3\", \"type2\");\n try {\n em.getTransaction().begin();\n em.createQuery(\"DELETE from Joke\").executeUpdate();\n em.persist(j1);\n em.persist(j2);\n em.persist(j3);\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"public void unsetEntityContext() {\n testAllowedOperations(\"unsetEntityContext\");\n }",
"protected void tearDown() throws Exception {\n\n InvoiceDAOFactory.clear();\n TestHelper.clearNamespaces();\n super.tearDown();\n }",
"@BeforeEach\n void setUp() {\n\n Database database = Database.getInstance();\n database.runSQL(\"cleanDb.sql\");\n\n\n genericDao = new GenericDao(UserRoles.class);\n }",
"@Test\n @JUnitTemporaryDatabase // Relies on specific IDs so we need a fresh database\n public void testDelete() throws Exception {\n createAndFlushServiceTypes();\n createAndFlushCategories();\n \n //Initialize the database\n ModelImporter mi = m_importer;\n String specFile = \"/tec_dump.xml.smalltest\";\n mi.importModelFromResource(new ClassPathResource(specFile));\n \n assertEquals(10, mi.getNodeDao().countAll());\n }",
"@After\n\tpublic void tearDown() throws URISyntaxException {\n\t\tTEST_ENVIRONMENT.emptyDb();\n\t\tTEST_ENVIRONMENT.migrateDb();\n\t}",
"@After\n public void tearDown() {\n fixture.cleanUp();\n }",
"@After\n public void tearDown() throws Exception {\n databaseTester.onTearDown();\n }",
"@After\r\n public void tearDown() {\r\n try {\r\n Connection conn=DriverManager.getConnection(\"jdbc:oracle:thin:@//localhost:1521/XE\",\"hr\",\"hr\");\r\n Statement stmt = conn.createStatement();\r\n stmt.execute(\"DELETE FROM Packages WHERE Pkg_Order_Id=-1\");\r\n stmt.execute(\"DELETE FROM Packages WHERE Pkg_Order_Id=-2\");\r\n } catch (Exception e) {System.out.println(e.getMessage());}\r\n }",
"@Override\n protected void setUp() throws Exception {\n super.setUp();\n mDBService = new DBService(getContext());\n deleteAllRecords();\n }",
"private void populateEntityToDeletetList()\r\n\t{\r\n\t\tentityNameListDelete = new ArrayList<String>();\r\n\t\tentityNameListDelete.add(\"edu.wustl.catissuecore.domain.Quantity\");\r\n\t\tentityNameListDelete\r\n\t\t\t\t.add(\"edu.wustl.catissuecore.domain.SpecimenCollectionRequirementGroup\");\r\n\t}",
"@After\n public void cleanup() {\n Ebean.deleteAll(userQuery.findList());\n Ebean.deleteAll(userOptionalQuery.findList());\n }",
"@AfterClass\n public void cleanUp() {\n }",
"private void deleteTestDataSet() {\n LOG.info(\"deleting test data set...\");\n try {\n Statement stmt = _conn.createStatement();\n stmt.executeUpdate(\"DELETE FROM tc8x_pks_person\");\n stmt.executeUpdate(\"DELETE FROM tc8x_pks_employee\");\n stmt.executeUpdate(\"DELETE FROM tc8x_pks_payroll\");\n stmt.executeUpdate(\"DELETE FROM tc8x_pks_address\");\n stmt.executeUpdate(\"DELETE FROM tc8x_pks_contract\");\n stmt.executeUpdate(\"DELETE FROM tc8x_pks_category\");\n stmt.executeUpdate(\"DELETE FROM tc8x_pks_project\");\n } catch (Exception e) {\n LOG.error(\"deleteTestDataSet: exception caught\", e);\n }\n }",
"@Before\n public void setUp() throws IkatsDaoException {\n Facade.removeAllMacroOp();\n }",
"@After\r\n\tpublic void tearDown() {\r\n\t\t\r\n\t\tcustFact = null;\t\t\t\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\r\n\t}",
"@BeforeMethod\n public void cleanBefore() {\n roleRepository.deleteAll();\n }",
"@After\n public void cleanDatabase() {\n\n databaseInstance.setTaxpayersArrayList(new ArrayList<Taxpayer>());\n }",
"@After\n public void teardown() {\n RoboGuice.Util.reset();\n }",
"@Override\r\n protected void tearDown() throws Exception {\r\n ctx = null;\r\n projectService = null;\r\n }",
"@Override\r\n public void testGettingEntityManager() { debug(\"overriddenTestGettingEntityManager - noop\"); }",
"@AfterEach\n\tpublic void tearThis() throws SQLException {\n\t\tbookDaoImpl.delete(testBook);\n\t\tbranchDaoImpl.delete(testBranch);\n\t}",
"@BeforeEach\n public void setUp() {\n EntityManager em = emf.createEntityManager();\n try {\n em.getTransaction().begin();\n em.createQuery(\"DELETE from Role\").executeUpdate();\n em.createQuery(\"DELETE from Post\").executeUpdate();\n em.persist(new Role(\"user\"));\n em.getTransaction().commit();\n em.getTransaction().begin();\n em.createQuery(\"DELETE from User\").executeUpdate();\n em.persist(new User(\"Some txt\", \"More text\"));\n user = new User(\"aaa\", \"bbb\");\n em.persist(user);\n em.getTransaction().commit();\n } finally {\n em.close();\n }\n }",
"@BeforeEach\r\n public void setUp() {\r\n EntityManager em = emf.createEntityManager();\r\n car1 = new Car(\"1997\", \"Ford\", \"E350\",3000, new Date(), \"Daniel\");\r\n car2 = new Car(\"1999\", \"Chevy\", \"Venture\", 4900, new Date(), \"Emil\");\r\n car3 = new Car(\"2000\", \"Chevy\", \"Venture\", 5000, new Date(), \"Jimmy\");\r\n car4 = new Car(\"1996\", \"Jeep\", \"Grand Cherokee\", 4799, new Date(), \"Jannich\");\r\n try {\r\n em.getTransaction().begin();\r\n em.createNamedQuery(\"Car.deleteAllRows\").executeUpdate();\r\n em.createNativeQuery(\"ALTER TABLE CAR AUTO_INCREMENT = 1\").executeUpdate();\r\n em.persist(car1);\r\n em.persist(car2);\r\n em.persist(car3);\r\n em.persist(car4);\r\n em.getTransaction().commit();\r\n } finally {\r\n em.close();\r\n }\r\n }",
"@Before\n public void clearUnitsOfWork() {\n while (CurrentUnitOfWork.isStarted()) {\n CurrentUnitOfWork.get().rollback();\n }\n }",
"@Before\n\tpublic void setUp() throws Exception {\n\t\tydelseService.setEntityManager(entityManager);\n\t}",
"@Test\n public void removeAllObjects() {\n store.close();\n store.deleteAllFiles();\n store = createBoxStoreBuilderWithTwoEntities(false).build();\n putTestEntities(5);\n Box<TestEntityMinimal> minimalBox = store.boxFor(TestEntityMinimal.class);\n minimalBox.put(new TestEntityMinimal(0, \"Sally\"));\n assertEquals(5, getTestEntityBox().count());\n assertEquals(1, minimalBox.count());\n\n store.removeAllObjects();\n assertEquals(0, getTestEntityBox().count());\n assertEquals(0, minimalBox.count());\n\n // Assert inserting is still possible.\n putTestEntities(1);\n assertEquals(1, getTestEntityBox().count());\n }",
"private void clearData() {\r\n em.createQuery(\"delete from MonitoriaEntity\").executeUpdate();\r\n }",
"@BeforeEach\n\tpublic void setUp()\n\t{\n\t\tGuestBook.clear();\n\t}",
"@After\n public void removeEverything() {\n\n ds.delete(uri1);\n ds.delete(uri2);\n ds.delete(uri3);\n\n System.out.println(\"\");\n }",
"@Test\n public void testDeleteEntities() throws Exception {\n init();\n final AtlasEntity dbEntity = TestUtilsV2.createDBEntity();\n EntityMutationResponse dbCreationResponse = entityStore.createOrUpdate(new AtlasEntityStream(dbEntity), false);\n\n final AtlasEntity tableEntity = TestUtilsV2.createTableEntity(dbEntity);\n AtlasEntity.AtlasEntitiesWithExtInfo entitiesInfo = new AtlasEntity.AtlasEntitiesWithExtInfo(tableEntity);\n\n final AtlasEntity columnEntity1 = TestUtilsV2.createColumnEntity(tableEntity);\n entitiesInfo.addReferredEntity(columnEntity1);\n final AtlasEntity columnEntity2 = TestUtilsV2.createColumnEntity(tableEntity);\n entitiesInfo.addReferredEntity(columnEntity2);\n final AtlasEntity columnEntity3 = TestUtilsV2.createColumnEntity(tableEntity);\n entitiesInfo.addReferredEntity(columnEntity3);\n\n tableEntity.setAttribute(COLUMNS_ATTR_NAME, Arrays.asList(AtlasTypeUtil.getAtlasObjectId(columnEntity1),\n AtlasTypeUtil.getAtlasObjectId(columnEntity2),\n AtlasTypeUtil.getAtlasObjectId(columnEntity3)));\n\n init();\n\n final EntityMutationResponse tblCreationResponse = entityStore.createOrUpdate(new AtlasEntityStream(entitiesInfo), false);\n\n final AtlasEntityHeader column1Created = tblCreationResponse.getCreatedEntityByTypeNameAndAttribute(COLUMN_TYPE, NAME, (String) columnEntity1.getAttribute(NAME));\n final AtlasEntityHeader column2Created = tblCreationResponse.getCreatedEntityByTypeNameAndAttribute(COLUMN_TYPE, NAME, (String) columnEntity2.getAttribute(NAME));\n final AtlasEntityHeader column3Created = tblCreationResponse.getCreatedEntityByTypeNameAndAttribute(COLUMN_TYPE, NAME, (String) columnEntity3.getAttribute(NAME));\n\n // Retrieve the table entities from the Repository, to get their guids and the composite column guids.\n ITypedReferenceableInstance tableInstance = metadataService.getEntityDefinitionReference(TestUtils.TABLE_TYPE, NAME, (String) tableEntity.getAttribute(NAME));\n List<IReferenceableInstance> columns = (List<IReferenceableInstance>) tableInstance.get(COLUMNS_ATTR_NAME);\n\n //Delete column\n String colId = columns.get(0).getId()._getId();\n String tableId = tableInstance.getId()._getId();\n\n init();\n\n EntityMutationResponse deletionResponse = entityStore.deleteById(colId);\n assertEquals(deletionResponse.getDeletedEntities().size(), 1);\n assertEquals(deletionResponse.getDeletedEntities().get(0).getGuid(), colId);\n assertEquals(deletionResponse.getUpdatedEntities().size(), 1);\n assertEquals(deletionResponse.getUpdatedEntities().get(0).getGuid(), tableId);\n assertEntityDeleted(colId);\n\n final AtlasEntity.AtlasEntityWithExtInfo tableEntityCreated = entityStore.getById(tableId);\n assertDeletedColumn(tableEntityCreated);\n\n assertTestDisconnectUnidirectionalArrayReferenceFromClassType(\n (List<AtlasObjectId>) tableEntityCreated.getEntity().getAttribute(COLUMNS_ATTR_NAME), colId);\n\n //update by removing a column - col1\n final AtlasEntity tableEntity1 = TestUtilsV2.createTableEntity(dbEntity, (String) tableEntity.getAttribute(NAME));\n\n AtlasEntity.AtlasEntitiesWithExtInfo entitiesInfo1 = new AtlasEntity.AtlasEntitiesWithExtInfo(tableEntity1);\n final AtlasEntity columnEntity3New = TestUtilsV2.createColumnEntity(tableEntity1, (String) column3Created.getAttribute(NAME));\n tableEntity1.setAttribute(COLUMNS_ATTR_NAME, Arrays.asList(AtlasTypeUtil.getAtlasObjectId(columnEntity3New)));\n entitiesInfo1.addReferredEntity(columnEntity3New);\n\n init();\n deletionResponse = entityStore.createOrUpdate(new AtlasEntityStream(entitiesInfo1), false);\n\n assertEquals(deletionResponse.getDeletedEntities().size(), 1);\n assertEquals(deletionResponse.getDeletedEntities().get(0).getGuid(), column2Created.getGuid());\n assertEntityDeleted(colId);\n\n // Delete the table entities. The deletion should cascade to their composite columns.\n tableInstance = metadataService.getEntityDefinitionReference(TestUtils.TABLE_TYPE, NAME, (String) tableEntity.getAttribute(NAME));\n\n init();\n EntityMutationResponse tblDeletionResponse = entityStore.deleteById(tableInstance.getId()._getId());\n assertEquals(tblDeletionResponse.getDeletedEntities().size(), 2);\n\n final AtlasEntityHeader tableDeleted = tblDeletionResponse.getFirstDeletedEntityByTypeName(TABLE_TYPE);\n final AtlasEntityHeader colDeleted = tblDeletionResponse.getFirstDeletedEntityByTypeName(COLUMN_TYPE);\n\n // Verify that deleteEntities() response has guids for tables and their composite columns.\n Assert.assertTrue(tableDeleted.getGuid().equals(tableInstance.getId()._getId()));\n Assert.assertTrue(colDeleted.getGuid().equals(column3Created.getGuid()));\n\n // Verify that tables and their composite columns have been deleted from the graph Repository.\n assertEntityDeleted(tableDeleted.getGuid());\n assertEntityDeleted(colDeleted.getGuid());\n\n }",
"private void clearData() {\n em.createQuery(\"delete from ViajeroEntity\").executeUpdate();\n }",
"@AfterEach\n\tvoid clearDatabase() {\n\t\t//Clear the table\n\t\taccountRepository.deleteAll();\n\t}",
"@After\n public void tearDown() {\n mapModel = null;\n }",
"@Before\n public void setUp() throws Exception {\n List<Note> nList = dao.getAllNotes();\n\n nList.stream()\n .forEach(note -> dao.deleteNote(note.getNoteId()));\n }",
"@After\n public void tearDown() {\n for (Filter filter : filterService.createTaskFilterQuery().list()) {\n filterService.deleteFilter(filter.getId());\n }\n }",
"@Override\n @After\n public void after() throws Exception {\n\n // clean up the event data\n clearMxTestData();\n\n super.after();\n }",
"@After\n public void tearDown() {\n fixture = null;\n }",
"@Test\r\n public void testExistingEmf() {\r\n debug(\"testExistingEmf\");\r\n this.emf = initialEmf; \r\n super.testGettingEntityManager();\r\n super.testPersisting();\r\n super.testFinding();\r\n super.testQuerying();\r\n super.testGettingMetamodel();\r\n this.emf = null; \r\n }",
"@AfterEach\n public void afterEach() {\n testBasket = null;\n }",
"@After\n public void deleteAfterwards() {\n DBhandlerTest db = null;\n try {\n db = new DBhandlerTest();\n } catch (Exception e) {\n e.printStackTrace();\n }\n db.deleteTable();\n }",
"@AfterClass\n public static void closeTestFixture() {\n entityManager.close();\n entityManagerFactory.close();\n }",
"@Override\n public void tearDown() {\n testEngine = null;\n }",
"protected void tearDown() throws Exception {\n TestHelper.executeDBScript(TestHelper.SCRIPT_CLEAR);\n TestHelper.closeAllConnections();\n TestHelper.clearAllConfigurations();\n\n super.tearDown();\n }",
"@After\n public void tearDown() {\n GWTMockUtilities.restore();\n }",
"@After\r\n public void tearDown() throws Exception {\r\n super.tearDown();\r\n TestHelper.cleanupEnvironment();\r\n instance = null;\r\n }",
"@AfterTest\r\n public void tearDown() {\n }",
"@AfterAll\r\n public void cleanUp() {\r\n\r\n UserEto savedUserFromDb = this.usermanagement.findUserByName(\"testUser\");\r\n\r\n if (savedUserFromDb != null) {\r\n this.usermanagement.deleteUser(savedUserFromDb.getId());\r\n }\r\n }",
"@After\n public void tearDown() {\n \n }",
"@AfterClass\n\tpublic void teardown(){\n\t}",
"@After\n\tpublic void tearDown() {}",
"@After\n public void cleanUp(){\n mockUserRepo = null;\n mockSession = null;\n sut = null;\n }",
"@After\n public void tearDown() {\n jdbcTemplate.execute(\"DELETE FROM assessment_rubric;\" +\n \"DELETE FROM user_group;\" +\n \"DELETE FROM learning_process;\" +\n \"DELETE FROM learning_supervisor;\" +\n \"DELETE FROM learning_process_status;\" +\n \"DELETE FROM rubric_type;\" +\n \"DELETE FROM learning_student;\");\n }",
"@After\n @Override\n public void tearDown() throws Exception {\n execute(\"alter table t1 set (\\\"blocks.read_only\\\" = false)\");\n execute(\"alter table t1 set (\\\"blocks.metadata\\\" = false)\");\n super.tearDown();\n }"
] | [
"0.73327",
"0.72661763",
"0.7209942",
"0.71508723",
"0.7072379",
"0.70622414",
"0.70130163",
"0.6950393",
"0.6733236",
"0.6719222",
"0.67101055",
"0.6693262",
"0.6679986",
"0.66674554",
"0.66334414",
"0.66294783",
"0.66081846",
"0.660699",
"0.65990305",
"0.6590608",
"0.65844715",
"0.6543114",
"0.6493346",
"0.6454436",
"0.64521295",
"0.64377844",
"0.6430712",
"0.6428341",
"0.64242744",
"0.64222527",
"0.6419203",
"0.63793474",
"0.6368415",
"0.63594526",
"0.6351503",
"0.634965",
"0.6348337",
"0.6341738",
"0.63367563",
"0.6333671",
"0.63248557",
"0.63248557",
"0.6313858",
"0.63121945",
"0.6308865",
"0.6289201",
"0.628551",
"0.6259216",
"0.6248258",
"0.62467426",
"0.6230891",
"0.6226644",
"0.6226348",
"0.6213461",
"0.61912066",
"0.6178412",
"0.6165332",
"0.6154781",
"0.6143834",
"0.6133352",
"0.61327803",
"0.61307096",
"0.6108584",
"0.6102871",
"0.60960114",
"0.6095228",
"0.6094216",
"0.60886395",
"0.6082176",
"0.608179",
"0.6077365",
"0.60690475",
"0.6066007",
"0.6065498",
"0.60593754",
"0.6053774",
"0.60531265",
"0.60525596",
"0.6046183",
"0.6044398",
"0.60394216",
"0.6036655",
"0.6032201",
"0.6028904",
"0.60275465",
"0.6019973",
"0.60199374",
"0.60190207",
"0.60051554",
"0.60031426",
"0.59917814",
"0.5985598",
"0.59818625",
"0.5977001",
"0.59769416",
"0.5972796",
"0.59686834",
"0.5966152",
"0.59650767",
"0.5963271",
"0.5960619"
] | 0.0 | -1 |
Created by Edgar on 2016/6/30. | @ProxyGen
@VertxGen
public interface MyService {
void say();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void perish() {\n \n }",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"public final void mo51373a() {\n }",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"public void mo38117a() {\n }",
"@Override\n public void init() {\n\n }",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n protected void initialize() {\n\n \n }",
"private void poetries() {\n\n\t}",
"private static void cajas() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"protected boolean func_70814_o() { return true; }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n\tpublic void jugar() {\n\t\t\n\t}",
"private void m50366E() {\n }",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\n public void init() {\n }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"private void init() {\n\n\t}",
"@Override\n void init() {\n }",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"private void kk12() {\n\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n public void init() {\n\n }",
"@Override\n public void init() {}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n public int describeContents() { return 0; }",
"@Override\r\n\tpublic void init() {}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\n protected void init() {\n }",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"private Rekenhulp()\n\t{\n\t}",
"@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\n\tpublic void init() {\n\t}",
"public void mo6081a() {\n }",
"@Override\n\tpublic void init()\n\t{\n\n\t}",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void initialize() { \n }",
"@Override\n\tpublic int mettreAJour() {\n\t\treturn 0;\n\t}",
"public void mo55254a() {\n }",
"public void mo21877s() {\n }",
"@Override\n public void memoria() {\n \n }",
"@Override\n public int retroceder() {\n return 0;\n }",
"@Override\n\tprotected void initialize() {\n\t}",
"@Override\n\tprotected void initialize() {\n\t}",
"private void strin() {\n\n\t}"
] | [
"0.6045984",
"0.58730847",
"0.5850888",
"0.5843326",
"0.5737674",
"0.5728922",
"0.5728922",
"0.5717737",
"0.57115257",
"0.5656691",
"0.5629494",
"0.56149834",
"0.5610957",
"0.5597055",
"0.55926543",
"0.5584092",
"0.5575276",
"0.55602014",
"0.5557739",
"0.5557607",
"0.5537692",
"0.5537692",
"0.5537692",
"0.5537692",
"0.5537692",
"0.5532",
"0.5527439",
"0.5520732",
"0.55204153",
"0.55136335",
"0.5510105",
"0.5507187",
"0.5504626",
"0.5488141",
"0.54869115",
"0.54869115",
"0.5480921",
"0.5466683",
"0.5461283",
"0.5461186",
"0.54547036",
"0.5441951",
"0.5434986",
"0.5434986",
"0.5427794",
"0.54261106",
"0.54261106",
"0.54261106",
"0.54261106",
"0.54261106",
"0.54261106",
"0.54184383",
"0.54184383",
"0.54184383",
"0.54184383",
"0.54184383",
"0.54184383",
"0.54184383",
"0.541474",
"0.54125285",
"0.5411322",
"0.5404061",
"0.5401843",
"0.5399982",
"0.5399982",
"0.5399982",
"0.539363",
"0.5393373",
"0.5393373",
"0.5393373",
"0.5389331",
"0.5389331",
"0.5389331",
"0.5386922",
"0.5386922",
"0.5383654",
"0.53834647",
"0.5371041",
"0.5366029",
"0.53571564",
"0.53551537",
"0.5348618",
"0.5348277",
"0.53352296",
"0.5330886",
"0.5315764",
"0.5312909",
"0.5312684",
"0.53068537",
"0.5304924",
"0.5304303",
"0.5301496",
"0.52976036",
"0.5293056",
"0.5272149",
"0.52675444",
"0.526602",
"0.5265375",
"0.5264259",
"0.5264259",
"0.524467"
] | 0.0 | -1 |
add a new depaarture to collection | public void addFlight(String flightNumber, String terminalname, String destinationCity, String departureTime)
{
flightList.putIfAbsent(flightNumber, new Departures(flightNumber, terminalname, destinationCity, departureTime));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void AddDep(Department dep) {\n\t\tddi.Add(dep);\n\t\t\n\t}",
"private void addPayeeToCollection() {\n\t\tif (getForm().getType() != TRANSFER) {\n\t\t\tPayee payee = new Payee(getForm().getPayFrom());\n\n\t\t\tif (payee.getIdentifier().length() != 0) {\n\t\t\t\tgetPayees().add(payee);\n\t\t\t\tgetForm().getPayFromChooser().displayElements();\n\t\t\t}\n\t\t}\n\t}",
"public void addEducation(Education e) {\n ed.add(e);\n}",
"private void add() {\n\n\t}",
"public void add(Department dep)\n\t{\n\t\tHRProtocol envelop = null;\n\t\tenvelop = new HRProtocol(HRPROTOCOL_ADD_DEPARTMENT_REQUEST, dep, null);\n\t\tsendEnvelop(envelop);\n\t\tenvelop = receiveEnvelop();\n\t\tif(envelop.getPassingCode() == HRPROTOCOL_ADD_DEPARTMENT_RESPONSE)\n\t\t{\t//Success in transition\n\t\t}else\n\t\t{\n\t\t\t//Error in transition. or other error codes.\n\t\t}\n\t}",
"public void add() {\n\t\t\n\t}",
"public static void addDept() {\n\t\tScanner sc = ReadFromConsole.sc;\n\n\t\tSystem.out.println(\"Enter Department name: \");\n\t\tString deptName = sc.nextLine();\n\n\t\tsc.nextLine(); // had to add this in to prevent input lines with different data types from\n\t\t\t\t\t\t// printing simultaneously, if you know a better solution, let me know\n\n\t\tSystem.out.println(\"Enter Department phone number: \");\n\t\tString deptPhoneNum = sc.nextLine();\n\n\t\tDepartment dept1 = new Department(deptName, deptPhoneNum);\n\t\t// pass in the info for each department\n\t\t// dept1 is the reference to the newly created obj\n\t\t// new Department = creates a new department obj and the Department constructor has a\n\t\t// counter variable which increments the id# and assigns it as new department id\n\n\t\tdeptInfo.add(dept1);\n\t\t// adding the newly created obj ref into arrlist\n\n\t}",
"public void add(LDCEstudante estudante){\n lista.add(estudante);\n }",
"public static void addNewHouse() {\n Services house = new House();\n house = addNewService(house);\n\n ((House) house).setRoomType(FuncValidation.getValidName(ENTER_ROOM_TYPE,INVALID_NAME));\n\n ((House) house).setFacilities(FuncValidation.getValidName(ENTER_FACILITIIES,INVALID_NAME));\n\n ((House) house).setNumberOfFloor(FuncValidation.getValidIntegerNumber(ENTER_NUMBER_OF_FLOOR,INVALID_NUMBER_OF_FLOOR,0));\n\n //Get list house from CSV\n ArrayList<House> houseList = FuncGeneric.getListFromCSV(FuncGeneric.EntityType.HOUSE);\n\n //Add house to list\n houseList.add((House) house);\n\n //Write house list to CSV\n FuncReadWriteCSV.writeHouseToFileCSV(houseList);\n System.out.println(\"----House \"+house.getNameOfService()+\" added to list---- \");\n addNewServices();\n }",
"void addRecord(DistRecord record, boolean persistPoints);",
"@Override\r\n\tpublic void addDepartment(Department department) {\n\r\n\t\tgetHibernateTemplate().save(department);\r\n\t}",
"public void incrementDepartures() {\n numDepartures++; \n }",
"@Override\n\tpublic void addDept(DeptInf dept) {\n\t\tdeptMapper.insert(dept);\n\t}",
"public void add() {\n }",
"public void AddDepartment(String nomDepart)\n\t{ \n\t\tDepartment depart = new Department();\n\t\tdepart.setNameDepartment(nomDepart);\n\t\tdepartments.add(depart);\n\t}",
"public void add(Demographics d) {\n for(DemographicType demoType : DemographicType.values()) {\n //handle demographic population\n demographicPopulation.put(demoType, demographicPopulation.get(demoType) + d.getDemographicPopulation().get(demoType));\n }\n demVotes += d.demVotes;\n repVotes += d.repVotes;\n// System.out.println(\"\\t\\t\" + this);\n }",
"private void addData() {\n Details d1 = new Details(\"Arpitha\", \"+91-9448907664\", \"25/05/1997\");\n Details d2 = new Details(\"Abhijith\", \"+91-993602342\", \"05/10/1992\");\n details.add(d1);\n details.add(d2);\n }",
"@Override\n\t@Transactional\n\tpublic void addLecture(Lecture l) {\n\t\tthis.lectureDao.addLecture(l);\n\t}",
"public void addVehicule(Vehicule vehicule) { listeVehicule.add(vehicule); }",
"int insertSelective(Depart record);",
"void addGarage(Garage garage);",
"int insert(Depart record);",
"@RequiresLock(\"SeaLock\")\r\n private void addDeponent(Drop deponent) {\r\n if (!f_valid || deponent == null) {\r\n return;\r\n }\r\n if (deponent == this) {\r\n return;\r\n }\r\n f_deponents.add(deponent);\r\n }",
"@Override\n\tpublic Fournisseur addFournisseur(Fournisseur fournisseur) {\n\t\treturn dao.addFournisseur(fournisseur);\n\t}",
"com.soa.SolicitarServicioDocument.SolicitarServicio addNewSolicitarServicio();",
"public void addRecord();",
"public void addDvd(DVDDetails details) throws InvalidDvdIdException;",
"public void addDepartmentRow(Departmentdetails departmentDetailsFeed);",
"public void addObject(DcObject dco);",
"public void add() {\n\n }",
"public void add();",
"public void addCapteur(Capteur capteur) {\n\t\tcapteurs.add(capteur);\n\t\tcapteur.setPosRel(posture.getPosition());\n\t}",
"public FamilyPlanningRecord addRecord(int communityMemberId, int serviceId, String serviceDate,double quanity){\n\t\ttry{\n\t\t\t\t\t\t\n\t\t\tdb=getWritableDatabase();\n\t\t\tContentValues cv=new ContentValues();\n\t\t\tcv.put(CommunityMembers.COMMUNITY_MEMBER_ID, communityMemberId);\n\t\t\tcv.put(FamilyPlanningServices.SERVICE_ID,serviceId);\n\t\t\tcv.put(QUANTITY, quanity);\n\t\t\tcv.put(SERVICE_DATE, serviceDate);\n\t\t\tlong id=db.insert(TABLE_NAME_FAMILY_PLANNING_RECORDS, null, cv);\n\t\t\tif(id<=0){\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\treturn getServiceRecord((int)id);\n\t\t\t\n\t\t}catch(Exception ex){\n\t\t\tclose();\n\t\t\treturn null;\n\t\t}\n\n\t}",
"@Override\n public void add(ReporteAccidente rep) {\n repr.save(rep);\n }",
"public void addApartment(int bid) throws IOException {\n Apartment apartment = new Apartment(apartmentsCollection.size() + 1, Integer.parseInt(numOfRooms.getText()), bid, cabinetMarker,\n Double.parseDouble(size.getText()),\n Double.parseDouble(price.getText()));\n try {\n// dataAccess.addApartment(apartment, personsCollection.size() - 1);\n dataAccess.addApartment(apartment, cabinetMarker);\n Main a = new Main();\n //a.changeScene(\"Registration\");\n //a.changeScene(\"OwnerCabinet\");\n reload();\n\n System.out.println(cabinetMarker + \" : Vsyo eshe tam!\");\n\n\n } catch (SQLException e1) {\n e1.printStackTrace();\n }\n apartmentsCollection.add(apartment);\n numOfAp.clear();\n size.clear();\n numOfRooms.clear();\n price.clear();\n }",
"public void add(T e) {\n\t\tif(!this.isEmpty()) {\n\t\t\tsuper.put(e, new Duet<T>(last, null));\n\t\t\tthis.get(last).setLast(e);\n\t\t\tlast = e;\n\t\t} else {\n\t\t\tsuper.put(e, new Duet<T>(null, null));\n\t\t\tfirst = e;\n\t\t\tlast = e;\n\t\t}\n\t}",
"void add(Lugar lugar);",
"public void add() {\n\t\tcart.add(item.createCopy());\n\t}",
"@Override\n\tpublic void add() {\n\t\t\n\t}",
"@Override\n\tpublic void insert(DeptVO deptVO) {\n\t\t\n\t}",
"public void addNewDistrict(District District);",
"void addItem(DataRecord record);",
"public void add(Good good) {\n cargo.add(good);\n numOfGoods++;\n }",
"@Override\n public DetalleVenta add(DetalleVenta detalleVenta) {\n return detalleVentaJpaRepository.save(detalleVenta);\n }",
"public static void add(Collection collection) {\n\t\t\n\t}",
"public void addSportive(Sportive sportive) throws ValidatorException{\n repo.save(sportive);\n }",
"public Triplet add(Triplet t) throws DAOException;",
"public void addDecomp(Decomposition dec){\n decomplist.add(dec);\n }",
"public void addNewYield(CollectionReference colRef, Crop yield)\n throws Exceptions.DatabaseWriteException {\n try {\n yield = validateYieldUnits(yield); //convert units to metric\n Map<String, Object> data = yield.toMap();\n ApiFuture<DocumentReference> addedDocRef = colRef.add(data);\n } catch (Exception e) {\n System.out.println(e.getMessage());\n throw new Exceptions.DatabaseWriteException(\"ERROR Failed to write record to database:\\n\\t\" + yield.toString());\n\n }\n }",
"@Override\n\tpublic void addLecture(Lecture l) {\n\t\tSession session = this.sessionFactory.getCurrentSession();\n\t\tsession.persist(l);\n\t}",
"Long addTravel(Travel travel);",
"public void createDepartament(int id, String denumire, int numarRaioane) {\n\t\tif (departamentOperations.checkDepartament(id) == true)\n\t\t\tSystem.out.println(\"Departament existent!\");\n\t\tDepartament newDepartament = new Departament(id, denumire, numarRaioane);\n\t\tList<Departament> list = departamentOperations.getAllDepartamente();\n\t\tdepartamentOperations.addDepartament(newDepartament);\n\t\tdepartamentOperations.printListOfDepartamente(list);\n\t}",
"public void addPaper(ConferencePaper pape){\r\n\t\tpapers.add(pape);\r\n\t}",
"@Override\n\tprotected final void ajouterUneParticule() {\n\t\tfinal int offsetX = (int) (vitesseX * dureeDeVieParticule)/2;\n\t\tfinal int offsetY = (int) (vitesseY * dureeDeVieParticule)/2;\n\t\t\n\t\tfinal Particule nouvelleParticule;\n\t\tfinal int x0 = Maths.generateurAleatoire.nextInt(Fenetre.LARGEUR_ECRAN) - offsetX;\n\t\tfinal int y0 = Maths.generateurAleatoire.nextInt(Fenetre.HAUTEUR_ECRAN) - offsetY;\n\t\tif (this.bassinDeParticules.size() > 0) {\n\t\t\t// On peut recycler une particule issue du bassin\n\t\t\tnouvelleParticule = this.rehabiliterParticule();\n\t\t\tnouvelleParticule.reinitialiser(x0, y0, dureeDeVieParticule, 0);\n\t\t} else {\n\t\t\t// Le bassin est vide, il faut creer une nouvelle particule\n\t\t\tnouvelleParticule = new Particule(x0, y0, dureeDeVieParticule, 0);\n\t\t}\n\t\tparticules.add(nouvelleParticule);\n\t}",
"private void processDeptsAndCollections(Map<String, String> row, Map<String, Dept> deptsAdded,\n Map<String, Collection> collectionsAdded) {\n String deptName = sanitizeString(row.get(departmentHeading));\n String collName = sanitizeString(row.get(collectionHeading));\n //if (deptName.isEmpty()) {\n // // Don't add anything if the department field was empty\n // return;\n //}\n Dept dept;\n Collection coll;\n\n if (failedDeptAttempts >= maxDeptAttempts) {\n throw new RuntimeException(\"Aborting: too many failed attempts to add Departments\");\n }\n if (failedCollAttempts >= maxCollAttempts) {\n throw new RuntimeException(\"Aborting: too many failed attempts to add Collections\");\n }\n //System.out.println(deptsAdded.get(deptName));\n if (deptsAdded.get(deptName) == null) {\n dept = new Dept();\n // id is auto-generated\n dept.setName(deptName);\n try {\n deptRepo.saveAndFlush(dept);\n deptsAdded.put(deptName, dept);\n }\n catch (Exception exception) {\n System.out.println(\"Skipped Dept: duplicate or malformed entry\");\n System.out.println(exception.toString());\n failedDeptAttempts++;\n }\n }\n // How to handle null deptsAdded.get(deptName)?\n if (collectionsAdded.get(collName) == null) {\n coll = new Collection();\n // id is auto-generated\n coll.setName(collName);\n coll.setDept(deptsAdded.get(deptName));\n try {\n collectionRepo.saveAndFlush(coll);\n collectionsAdded.put(collName, coll);\n } catch (Exception exception) {\n System.out.println(\"Skipped Collection: duplicate or malformed entry, or missing Dept\");\n System.out.println(exception.toString());\n failedCollAttempts++;\n }\n }\n }",
"@Override\n\t\t\tpublic boolean addDept(Dept dept) {\n\t\t\t\treturn false;\n\t\t\t}",
"public static void addNewVilla() {\n Services villa = new Villa();\n villa = addNewService(villa);\n ((Villa) villa).setRoomType(FuncValidation.getValidName(ENTER_ROOM_TYPE,INVALID_NAME));\n ((Villa) villa).setFacilities(FuncValidation.getValidName(ENTER_FACILITIIES,INVALID_NAME));\n ((Villa) villa).setPoolArea(FuncValidation.getValidDoubleNumber(ENTER_POOL_AREA,INVALID_DOUBLE_NUMBER,30.0));\n ((Villa) villa).setNumberOfFloor(FuncValidation.getValidIntegerNumber(ENTER_NUMBER_OF_FLOOR,INVALID_NUMBER_OF_FLOOR, 0));\n\n //Get villa list from CSV\n ArrayList<Villa> villaList = FuncGeneric.getListFromCSV(FuncGeneric.EntityType.VILLA);\n\n //Add villa to list\n villaList.add((Villa) villa);\n\n //Write villa list to CSV\n FuncReadWriteCSV.writeVillaToFileCSV(villaList);\n System.out.println(\"----Villa \"+villa.getNameOfService()+\" added to list---- \");\n addNewServices();\n\n }",
"private void addStudy(Study study) {\n\t\t\r\n\t}",
"@Override\n\t\t\tpublic boolean insert(Dept dept) {\n\t\t\t\treturn false;\n\t\t\t}",
"void addTrade(Trade trade);",
"public void newApointment(Appointment ap){\n\n this.appointments.add(ap);\n }",
"Reservierung insert(Reservierung reservierung) throws ReservierungException;",
"com.soa.SolicitarCreditoDocument.SolicitarCredito addNewSolicitarCredito();",
"private void addAllDepartments() {\n\t\tfinal BillingPeriod bp = (BillingPeriod) this.getBean().getContainer()\n\t\t\t\t.findBean(\"org.rapidbeans.clubadmin.domain.BillingPeriod\", this.getBillingPeriod().getIdString());\n\t\tfor (RapidBean bean : this.getBean().getContainer()\n\t\t\t\t.findBeansByType(\"org.rapidbeans.clubadmin.domain.Department\")) {\n\t\t\tfinal Department dep = (Department) bean;\n\t\t\tif (bp.getDepartments() == null || !bp.getDepartments().contains(dep)) {\n\t\t\t\tbp.addDepartment(dep);\n\t\t\t}\n\t\t}\n\t}",
"@Override\n\tpublic void EnvoyerRequete(Requete req) {\n\t\tmediateur.transmettreRequeteDeEtudiant(req);\n\t\tEtudiant etudiant = etudiantRepo.findOne(req.getExpediteur().getId());\n\t\tetudiant.getDemandes().add(req);\n\t\tthis.update(etudiant);\n\t}",
"public void addArticulo() {\n articulosFactura.setFacturaIdfactura(factura);\n articulosFacturas.add(articulosFactura);\n factura.setArticulosFacturaList(articulosFacturas);\n total = total + (articulosFactura.getCantidad() * articulosFactura.getArticuloIdarticulo().getPrecioVenta());\n articulosFactura = new ArticulosFactura();\n }",
"public void createDiveTotal(int meetId, int diverId,\n DiverTotalDB diveTotal, SQLiteDatabase db){\n ContentValues values = new ContentValues();\n values.put(getDiveCount(), diveTotal.get_diveTotal());\n values.put(getMeetId(), meetId);\n values.put(getDiverId(), diverId);\n\n db.insert(getTableDiveTotals(), null, values);\n }",
"ch.crif_online.www.webservices.crifsoapservice.v1_00.DebtEntry addNewDebts();",
"public void addFine() {\n dbRef = FirebaseDatabase.getInstance().getReference().child(\"Fines\");\n// fineObj = new FinesDetails();\n\n fineObj.setDl(this.dlNo);\n fineObj.setName(this.oName);\n fineObj.setEmail((this.oEmail).trim());\n fineObj.setContact((this.oContact).trim());\n fineObj.setAddress((this.oAddress).trim());\n fineObj.setLocation((this.oLocation).trim());\n fineObj.setOfficerId((this.userName).trim());\n fineObj.setTotal(this.fineTotal);\n fineObj.setStatus((this.status).trim());\n fineObj.setRule((this.ruleArray_list));\n fineObj.setDateTime(this.dateTime);\n\n fineId = this.currentTimeMil + this.dlNo;\n\n dbRef.child(fineId).setValue(fineObj);\n\n Toast.makeText(getApplicationContext(), \" saved\", Toast.LENGTH_SHORT).show();\n\n }",
"public org.hl7.fhir.MedicationStatementDosage addNewDosage()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.hl7.fhir.MedicationStatementDosage target = null;\n target = (org.hl7.fhir.MedicationStatementDosage)get_store().add_element_user(DOSAGE$14);\n return target;\n }\n }",
"@Override\npublic int insert(Department depa) {\n\treturn departmentMapper.insert(depa);\n}",
"public void addExpense(Expense exp) {\n ContentValues values = new ContentValues();\n SQLiteDatabase db = getWritableDatabase();\n\n values.put(COLUMN_NAME, exp.get_name());\n values.put(COLUMN_DATE, exp.get_date());\n db.insert(TABLE_EXPENSES, null, values);\n db.close();\n }",
"public void add(Furniture f) {\r\n\t\tthis.furniture.add(f);\r\n\t}",
"public void add(Avion avion)\n\t{\n\t}",
"private void addArticle() {\n\t\tAdminComposite.display(\"\", STATUS_SUCCESS, SUCCESS_FONT_COLOR);\n\t\tQuotationDetailsDTO detail = new QuotationDetailsDTO();\n\t\ttry {\n\t\t\tdetail = createQuotationDetail(detail);\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\tif (validateMandatoryParameters(detail)) {\n\t\t\taddToArticleTable(detail);\n\t\t}\n\t}",
"public void AddReliquias(){\n DLList reliquias = new DLList();\n reliquias.insertarInicio(NombreReliquia); \n }",
"void addData();",
"public FamilyPlanningRecord addRecord(int communityMemberId, int serviceId, String serviceDate,double quanity, String scheduleDate){\n\t\ttry{\n\t\t\t\t\t\t\n\t\t\tdb=getWritableDatabase();\n\t\t\tContentValues cv=new ContentValues();\n\t\t\tcv.put(CommunityMembers.COMMUNITY_MEMBER_ID, communityMemberId);\n\t\t\tcv.put(FamilyPlanningServices.SERVICE_ID,serviceId);\n\t\t\tcv.put(QUANTITY, quanity);\n\t\t\tcv.put(SERVICE_DATE, serviceDate);\n\t\t\tcv.put(SCHEDULE_DATE, scheduleDate);\n\t\t\tlong id=db.insert(TABLE_NAME_FAMILY_PLANNING_RECORDS, null, cv);\n\t\t\tif(id<=0){\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\treturn getServiceRecord((int)id);\n\t\t\t\n\t\t}catch(Exception ex){\n\t\t\tclose();\n\t\t\treturn null;\n\t\t}\n\n\t}",
"public static void addNewRoom() {\n Services room = new Room();\n room = addNewService(room);\n\n ((Room) room).setFreeService(FuncValidation.getValidFreeServices(ENTER_FREE_SERVICES,INVALID_FREE_SERVICE));\n\n //Get room list from CSV\n ArrayList<Room> roomList = FuncGeneric.getListFromCSV(FuncGeneric.EntityType.ROOM);\n\n //Add room to list\n roomList.add((Room) room);\n\n //Write room list to CSV\n FuncReadWriteCSV.writeRoomToFileCSV(roomList);\n System.out.println(\"----Room \"+room.getNameOfService()+\" added to list---- \");\n addNewServices();\n\n }",
"public void addItem(String user, String departure, String destination, String adult, String child, String trip) {\n\n if(user != null)\n {\n MyItem mItem = new MyItem();\n\n mItem.setName(user);\n mItem.setDeparture(\"Departure City: \" + departure);\n mItem.setDestination(\"Destination City: \" + destination);\n mItem.setAdult(\"Number of Adult: \" + adult);\n mItem.setChild(\"Number of Child: \" + child);\n mItem.setTrip(\"Type of Trip: \" + trip);\n\n mItems.add(mItem);\n }\n\n }",
"public void addFood(Food food, double serving) {\n\t\t\n\t\tString foodName = food.getName();\n\t\t\n\t\tif (foodDetail.containsKey(foodName)) {\n\t\t\tif (foodPortion.get(foodName) + serving==0) {\n\t\t\t\tfoodPortion.remove(foodName);\n\t\t\t\tfoodDetail.remove(foodName);\n\t\t\t\tmeal.remove(foodName);\n\t\t\t} else {\n\t\t\t\tfoodPortion.put(foodName, foodPortion.get(foodName) + serving);\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tmeal.add(foodName);\n\t\t\tfoodDetail.put(foodName, food);\n\t\t\tfoodPortion.put(foodName, serving);\n\t\t}\n\t}",
"@Override\n\tpublic void add(Discount discount) {\n\t\t\n\t}",
"void addAdvert(Advert advert);",
"org.landxml.schema.landXML11.DecisionSightDistanceDocument.DecisionSightDistance addNewDecisionSightDistance();",
"public void addPage(PDFPage aPage) { _pages.add(aPage); }",
"public void add(DVDPackage dvd){\n\t\tqueue.addLast(dvd);\n\t}",
"@Override\n\tpublic void add(Plane p) {\n\t\tString query = \"INSERT INTO fleet(model,planeid)\" + \"VALUES ('\" + p.getName() + \"',\" + p.getPlaneID() + \")\";\n\t\tDBManager.getInstance().addToDB(query);\n\t}",
"private void _addDeltas(Matcher matcher,\n Collection<Delta> collection,\n Delta delta)\n {\n int count;\n\n if (matcher.group(\"count\") == null) count = 1;\n\n else count = Integer.parseInt(matcher.group(\"count\"));\n\n for (int i = 0; i < count; ++i) collection.add(delta);\n }",
"public void createNewHouseAndAddToList(){\n\t\t\tHouse newHouse = new House();\r\n\t\t\tString id = createAutomaticallyID().trim();\r\n\t\t\tnewHouse.setId(id);\r\n\t\t\tnewHouse.setPrice(Double.parseDouble(priceTextField.getText().trim()));\r\n\t\t\tnewHouse.setNumberOfBathrooms(Integer.parseInt(bathroomsTextField.getText().trim()));\r\n\t\t\tnewHouse.setAirConditionerFeature(airConditionerComboBox.getSelectedItem().toString());\r\n\t\t\tnewHouse.setNumberOfRooms(Integer.parseInt(roomsTextField.getText().trim()));\r\n\t\t\tnewHouse.setSize(Double.parseDouble(sizeTextField.getText().trim()));\r\n\t\t\t\r\n\t\t\toriginalHouseList.add(newHouse);//first adding newHouse to arrayList\r\n\t\t\tcopyEstateAgent.setHouseList(originalHouseList);//then set new arrayList in copyEstateAgent\r\n\r\n\t\t}",
"void addReservation(ReservationDto reservationDto) ;",
"void add(GeometricalObject object);",
"public void add( String m, boolean e )\n {\n \tpurchases.add( new Gizmo( m, e) );\n }",
"private void addDishToList(String dsName, int amt, int dsPrice, String type) {\n int n, total;\n Map<String, Object> map = new HashMap<String, Object>();\n map.put(DNAME, dsName);\n if ((n = table.addDish(dsName, amt, dsPrice, type,\n vip.getPhone(), vip.getName())) > amt) {\n Map<String, Object> tm = new HashMap<String, Object>();\n tm.put(DNAME, dsName);\n tm.put(AMOUNT, n - amt);\n mList.remove(tm);\n map.put(AMOUNT, n);\n mList.add(map);\n } else {\n map.put(AMOUNT, amt);\n mList.add(map);\n }\n total = vip.getConsumption() + amt * dishes.get(dsName).getPrice();\n vip.setConsumption(total);\n payBtn.setText(PAY + RMB + String.valueOf(total));\n adapter.notifyDataSetChanged();\n listChanged = true;\n }",
"public boolean addRecord(Purchase purchase)\n {\n ContentValues contentValues = new ContentValues();\n contentValues.put(COL_2, purchase.getName());\n contentValues.put(COL_3, purchase.getPrice());\n contentValues.put(COL_4, purchase.getDate());\n contentValues.put(COL_5, purchase.getNotePath());\n //I am storing the name of of the enum, not the int value\n contentValues.put(COL_6, purchase.getCategory().name());\n SQLiteDatabase db = getWritableDatabase();\n db.insert(PURCHASE_TABLE, null, contentValues);\n db.close();\n return true;\n }",
"public void addPurchase(Event e) {\n if (e == null) {\n throw new IllegalArgumentException(\"Event can not be null\");\n }\n if (!purchases.contains(e)) {\n purchases.add(e);\n }\n }",
"public abstract void addDetails();",
"public void addIng(String name, double qte, Date day, String measure){\n\t\t\tSystem.out.println(\"You added: \"+name);\n\t\t\tif(ingmap.containsKey(name)) {\n\t\t\t\tdouble aux = this.checkMeasurement(qte, measure, name); //this is corrected quantity if conversion is necessary\n\t\t\t\tingmap.get(name).addEntry(aux, day, this.idGen);\n\t\t\t}\n\t\t\telse {\n\t\t\t\tIngList aux = new IngList(measure); //creates new ingredient list for that specific ingredient\n\t\t\t\taux.addEntry(qte, day, this.idGen); //since the list is new there's no need for object conversion\n\t\t\t\tingmap.put(name, aux);\n\t\t\t}\n\t\t\tthis.idGen+=1;\n\t\t}",
"public void addflight(Flight f)\n {\n \t this.mLegs.add(f);\n \t caltotaltraveltime();\n \t caltotalprice();\n }",
"@Override\r\n\tpublic void insertPurchase(Purchase Purchase) throws Exception {\n\t\t\r\n\t}",
"public void addRecord(Record record) {\n if (records.add(record)) {\n // if record has been added, then changing balance\n if (record.getType() == RecordType.WITHDRAW)\n balance -= record.getAmount();\n else if (record.getType() == RecordType.DEPOSIT)\n balance += record.getAmount();\n }\n }"
] | [
"0.6334456",
"0.5838828",
"0.56833947",
"0.5682055",
"0.56581235",
"0.56483775",
"0.5611292",
"0.55729324",
"0.5572892",
"0.5567881",
"0.5560132",
"0.55594057",
"0.5559177",
"0.555658",
"0.5555826",
"0.5555425",
"0.5542961",
"0.55263454",
"0.5509454",
"0.5473235",
"0.54719067",
"0.5467833",
"0.5459622",
"0.545523",
"0.54550755",
"0.54512405",
"0.54432195",
"0.54372895",
"0.54370815",
"0.5432198",
"0.54254687",
"0.5425203",
"0.54210246",
"0.5415109",
"0.5372127",
"0.5371769",
"0.5361502",
"0.5358406",
"0.5355901",
"0.53404945",
"0.53392076",
"0.5331426",
"0.532623",
"0.5302094",
"0.52998966",
"0.529824",
"0.52843046",
"0.5271223",
"0.52652967",
"0.52553236",
"0.5253032",
"0.5249728",
"0.5247146",
"0.52358305",
"0.5233554",
"0.5213203",
"0.52095646",
"0.52014565",
"0.51960135",
"0.51875806",
"0.51853245",
"0.5177643",
"0.5172606",
"0.51652354",
"0.5160366",
"0.51486653",
"0.5144122",
"0.5141036",
"0.5139894",
"0.5139327",
"0.5134782",
"0.5134622",
"0.5130843",
"0.51300395",
"0.5129609",
"0.51288754",
"0.5128166",
"0.51262766",
"0.5101556",
"0.5098953",
"0.5097276",
"0.5095513",
"0.5091671",
"0.50906986",
"0.5088451",
"0.5086177",
"0.50797075",
"0.50793684",
"0.5078304",
"0.5076023",
"0.5075793",
"0.5073545",
"0.5072281",
"0.50683033",
"0.5066653",
"0.50643414",
"0.5061483",
"0.50557756",
"0.50529325",
"0.50526386"
] | 0.5086458 | 85 |
private static final String serverPath = "d:\\test\\111\\"; | public TestServerApi()
{
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setServerPath(@NotNull String serverPath) { this.myServerPath = serverPath; }",
"public ResourcePath() {\n //_externalFolder = \"file:///C:/Program%20Files/ESRI/GPT9/gpt/\";\n //_localFolder = \"gpt/\";\n}",
"@Test\n public void testSetFolderNamePath() {\n System.out.println(\"setFolderNamePath\");\n String folderNamePath = \"c:\\\\relytest\\\\test\\\\test\";\n CharterDto instance = new CharterDto(\"Test name\");\n instance.setFolderNamePath(folderNamePath);\n\n String expResult = folderNamePath;\n String result = instance.getFolderNamePath();\n assertEquals(expResult, result);\n }",
"@NotNull\n/* 52 */ public String getServerPath() { return this.myServerPath; }",
"static String localPath(String name) {\n\t\tchar c = File.separatorChar;\n\t\treturn name.replace((char) (c ^ '/' ^ '\\\\'), c);\n\t}",
"@Test\n public void testPathParsing_withAlternateSeparator() {\n PathService windowsPathService = PathServiceTest.fakeWindowsPathService();\n assertEquals(\n windowsPathService.parsePath(\"foo\\\\bar\\\\baz\"), windowsPathService.parsePath(\"foo/bar/baz\"));\n assertEquals(\n windowsPathService.parsePath(\"C:\\\\foo\\\\bar\"), windowsPathService.parsePath(\"C:\\\\foo/bar\"));\n assertEquals(\n windowsPathService.parsePath(\"c:\\\\foo\\\\bar\\\\baz\"),\n windowsPathService.parsePath(\"c:\", \"foo/\", \"bar/baz\"));\n }",
"private String db4oDBFullPath(Context ctx) {\t\n\t\treturn ctx.getDir(\"data\", 0) + \"/\" + LOCAL_SERVER;\n\t\n\t}",
"@Test\n public void testGetFolderNamePath() {\n System.out.println(\"getFolderNamePath\");\n CharterDto instance = new CharterDto(\"Test name\");\n String expResult = \"c:\\\\tmp\\\\relytest\";\n instance.setFolderNamePath(expResult);\n String result = instance.getFolderNamePath();\n assertEquals(expResult, result);\n\n }",
"public ServerfileReader(String sharedFolderPath, char player){\n\t\tthis.sharedFolderPath = sharedFolderPath;\n\t\tthis.player = player;\n\t}",
"@Test\r\n public void testToPath() {\r\n System.out.println(\"toPath\");\r\n String id = \"c_58__47_Dojo_32_Workshop_47_test_46_txt\";\r\n String expResult = \"c:/Dojo Workshop/test.txt\";\r\n String result = FileRestHelper.toPath(id);\r\n assertEquals(expResult, result);\r\n }",
"private void parseUrlsPaths(String localPath) {\n String[] pathArray = localPath.split(\"/\");\n // Geometry_305_v6_fb_coupe_frontlightbulb1_a001.b3d.dflr\n this.fileName = pathArray[pathArray.length - 1];\n // /cars/mustang2015/geometry/\n this.subDirectory = localPath.replace(\"/\" + this.fileName, \"\");\n }",
"protected String getMyVarPath(String path){\n\t\treturn \"getVariableData('\"+VARNAME+\"', 'part1', '/nswomoxsd:receive/nswomoxsd:evt/\"+path+\"') \";\n\t}",
"private String normalizePath(String path)\n {\n return path.replaceAll(\"\\\\\\\\{1,}\", \"/\");\n }",
"public static String getPath() {\n\t\t// Lấy đường dẫn link\n\t\tAuthentication auth1 = SecurityContextHolder.getContext().getAuthentication();\n\t\tAgentconnection cus = (Agentconnection) auth1.getPrincipal();\n\t\t \n\t\t//String PATH_STRING_REAL = fileStorageProperties.getUploadDir()+cus.getMerchant()+\"/hotel/images/\" + year + \"/\" + month + \"/\" ;\n\t String PATH_STRING_REAL = \"E:/ezcloud/upload/\"+cus.getMerchant()+\"/hotel/images/\" + year + \"/\" + month + \"/\" ;\n\t return PATH_STRING_REAL;\n\t}",
"public void setPath(String path)\r\n/* 21: */ {\r\n/* 22:53 */ this.path = path;\r\n/* 23: */ }",
"String getRealPath(String path);",
"private String toCompletePath(String fullRequest) {\n \n///Parse request for file path\nString requestLine[] = new String[] {\" \", \" \", \" \"};\n requestLine = fullRequest.split(\" \");\nString partialPath = requestLine[1];\n \n//If requested path is just \"/\" or \"\", don't return any path\n if(partialPath.length() <= 1) {\n noFileRequested = true;\n return null;\n }\n \nString completePath;\n//If using my Windows machine, the path is different than the school Linux machines\nif (Windows)\n completePath = \"C:/Users/Michelle/eclipse-workspace/P1\" + partialPath;\nelse\n completePath = \".\" + partialPath;\n \n return completePath;\n}",
"public FileServer(){\n\t\tfilePath = new ConcurrentHashMap<String, String>();\n\t}",
"private String getRootUrl(String path){\n return \"http://localhost:\" + port + \"/api/v1\" + path;\n }",
"public static void main(String[] args) {\n\t\t\r\n\t\tString str =\"D:\\\\jboss-4.2.2.GA\\\\server\\\\default\\\\deploy\\\\shen3spnet.war\\\\aa\\\\bb\";\r\n\t\tint i = str.indexOf(\"shen3spnet\");\r\n\t\tint j = str.substring(i).indexOf(\"\\\\\")+1;\r\n\t\tSystem.out.println(str.substring(i).substring(j));\r\n\t\t\r\n\t}",
"public abstract String getFullPath();",
"public String getPath()\n\t{\n\t\treturn letter + \":/\";\n\t}",
"String rootPath();",
"@Test\n public void testCreateFilePath() {\n System.out.println(\"createFilePath with realistic path\");\n String path = System.getProperty(\"user.dir\")+fSeparator+\"MyDiaryBook\"\n +fSeparator+\"Users\"+fSeparator+\"Panagiwtis Georgiadis\"+fSeparator+\"Entries\"\n +fSeparator+\"Test1\";\n FilesDao instance = new FilesDao();\n boolean expResult = true;\n boolean result = instance.createFilePath(path);\n assertEquals(\"Some message\",expResult, result);\n }",
"public String path(String path1, String path2);",
"private static String createDir(String s) {\r\n \tint len = s.length() - 1;\r\n \tString tempBuff;\r\n \tString result;\r\n \tif (s.charAt(len) != '/') {\r\n \t\ttempBuff = String.format(\"%s/\", s);\r\n \t}\r\n \telse {\r\n \t\ttempBuff = s;\r\n \t}\r\n \tresult = tempBuff;\r\n \treturn result;\r\n }",
"public void setPathname(String s) {this.pathname = s;}",
"Path createPath();",
"private String fixSlashes(String str) {\n\t\tstr = str.replace('\\\\', '/');\r\n\t\t// compress multiples into singles;\r\n\t\t// do in 2 steps with dummy string\r\n\t\t// to avoid infinte loop\r\n\t\tstr = replaceString(str, \"//\", \"_____\");\r\n\t\tstr = replaceString(str, \"_____\", \"/\");\r\n\t\treturn str;\r\n\t}",
"@Test\n public void testSetPicturePath() {\n System.out.println(\"setPicturePath\");\n String picturePath = \"D:\\\\REPOSITORIO\\\\Proyecto\\\\relytest\\\\Prototype001\";\n CharterDto instance = new CharterDto(\"Test name\");\n instance.setPicturePath(picturePath);\n \n String expResult = picturePath;\n String result = instance.getPicturePath();\n assertEquals(expResult, result);\n }",
"protected RMIclientHandler(String s, Registry r) throws RemoteException {\r\n\t\tFile serverStorage = new File (s);\r\n\t\tserverStorage.mkdir();\r\n\t\tthis.registry=r;\r\n\t}",
"private String getPath() {\r\n\t\t\treturn context.getRealPath(\"WEB-INF/ConnectionData\");\r\n\t\t}",
"void path(String path);",
"void path(String path);",
"private String getPath() {\n\t\treturn context.getRealPath(\"WEB-INF/ConnectionData\");\n\t}",
"private String getPath() {\n\t\treturn context.getRealPath(\"WEB-INF/ConnectionData\");\n\t}",
"private String getPath() {\n\t\treturn context.getRealPath(\"WEB-INF/ConnectionData\");\n\t}",
"private String getPath() {\n\t\treturn context.getRealPath(\"WEB-INF/ConnectionData\");\n\t}",
"java.lang.String getMountPath();",
"public Storage(String s){\n this.path=s;\n }",
"private String sep(String path) {\n return path == null ? \"\" : \"/\" + path;\n }",
"String getFilepath();",
"public String jsonPathBuilder(String path){\n\t\tString validJsonPath=\"$\";\n\t\tString[] pathArray = path.split(\"/\");\n\t\tfor(int i=0; i<pathArray.length; i++){\n\t\t\tvalidJsonPath = validJsonPath + \".\" + pathArray[i];\n\t\t}\n\t\treturn validJsonPath;\n\t}",
"private static String handleUrl(String s) {\n if (s.endsWith(\"/..\")) {\n int idx = s.lastIndexOf('/');\n s = s.substring(0, idx - 1);\n idx = s.lastIndexOf('/');\n String gs = s.substring(0, idx);\n if (!gs.equals(\"smb:/\")) {\n s = gs;\n }\n }\n if (!s.endsWith(\"/\")) {\n s += \"/\";\n }\n System.out.println(\"now its \" + s);\n return s;\n }",
"public String path() {\n\treturn path;\n }",
"public interface IPathConstant {\n\tString PROPERTY_FILEPATH=\"./src/main/resources/CommonData.properties\";\n\tString EXCELPATH=\"./src/test/resources/testdata.xlsx\";\n\tString JSONFILEPATH=\"\";\n\tString htmlPath=\"./extentReport\"+JavaUtility.getCurrentSystemDate()+\".html\";\n}",
"public void setServer (\r\n String strServer) throws java.io.IOException, com.linar.jintegra.AutomationException;",
"void setPath(String path);",
"public static void setSextantePath(final String sPath) {\n\n m_sSextantePath = sPath;\n\n }",
"@Override\n protected String getFileSeparator() { return \"/\"; }",
"public MountRequest(String p){\n\t\tpath = p;\n\t}",
"private String getFilePath(String sHTTPRequest) {\n return sHTTPRequest.replaceFirst(\"/\", \"\");\n\n }",
"public void setCommonDir(String path) throws IllegalArgumentException\n {\n ServerSettings.getInstance().setProperty(\n ServerSettings.COMMON_DIR,\n \"\"+validatePath(path)\n );\n }",
"protected String getFileNamePath()\n {\n String sep = System.getProperty(\"file.separator\", \"/\");\n// String path = System.getProperty(\"user.dir\", \".\");\n\n String filename = getPath() + sep + \"sec.dat\";\n\n return filename;\n }",
"@Test\n public void testInvalidSlashesRuleMatches() throws Exception {\n Assume.assumeFalse(SystemInfo.isWindows);\n\n File file = new File(\"at\\\\least/one\\\\of/these\\\\slashes/are\\\\wrong\");\n assertRuleFails(myFileOp, PathValidator.INVALID_SLASHES, file);\n }",
"public static void setServer(final MinecraftServer server) {\n synchronize();\n dataDirectory = server.func_240776_a_(BLOBS_FOLDER_NAME);\n try {\n Files.createDirectories(dataDirectory);\n } catch (final IOException e) {\n LOGGER.error(e);\n }\n }",
"public static String unixPath(String path) {\n String convert = path.replace(\"\\\\\", \"/\");\n return convert;\n }",
"private String fixPath(String Path) {\n\n // Nothing to do if we're running the plugin on a Windows machine.\n if (Global.IsWindowsOS()) {\n return Path;\n }\n\n // Replace all of the Windows separator characters with linux separator characters.\n String NewPath = Path.replaceAll(\"\\\\\\\\\", File.separator);\n\n Log.getInstance().write(Log.LOGLEVEL_TRACE, \"RecordingEpisode.fixPath: \" + Path + \"->\" + NewPath);\n \n return NewPath;\n }",
"private String addSlashes(String in) {\n StringBuffer sb = new StringBuffer();\n int index = 0;\n int i = in.indexOf(\"\\\\\");\n int ii = in.indexOf(\"\\\\\\\\\");\n\n if (i == -1) {\n return in;\n }\n\n if (i != ii) {\n sb.append(in.substring(index,i+1)+\"\\\\\");\n }\n index = i+1;\n boolean done = false;\n while (!done) {\n i = in.indexOf(\"\\\\\", index);\n ii = in.indexOf(\"\\\\\\\\\", index);\n if (i == -1) {\n sb.append(in.substring(index));\n done = true;\n }\n else if (i != ii) {\n sb.append(in.substring(index,i+1)+\"\\\\\");\n index = i+1;\n }\n }\n return sb.toString();\n }",
"public IPath getRuntimeBaseDirectory(TomcatServer server);",
"public serverHttpHandler( String rootDir ) {\n this.serverHome = rootDir;\n }",
"private static String cleanServerAddress(String dirtyServerAddress){\n\t\tif (dirtyServerAddress.contains(\":\")){\n\t\t\tdirtyServerAddress = dirtyServerAddress.substring(0, dirtyServerAddress.indexOf(':'));\n\t\t}\n\t\tif (dirtyServerAddress.contains(\"/\")){\n\t\t\tdirtyServerAddress = dirtyServerAddress.substring(0, dirtyServerAddress.indexOf('/'));\n\t\t}\n\t\treturn(dirtyServerAddress);\n\t}",
"@Override\n\t\tpublic String getRealPath(String path) {\n\t\t\treturn null;\n\t\t}",
"@Override\n\tpublic String generatePathStr(String component,\n\t\t\tString outputName) throws RemoteException {\n\t\treturn \"/user/\" + userName + \"/tmp/redsqirl_\" + component + \"_\" + outputName\n\t\t\t\t+ \"_\" + RandomString.getRandomName(8)+\".txt\";\n\t}",
"public void setPath(String path);",
"@Test\n public void test_slash_string_returns_null()\n {\n InputStream inputStream = ResourceUtil.getInputStream(\"/\");\n assertNull(\"Should be null\", inputStream);\n }",
"private String createTemplateServerRequest(String servletPath,String templateName) {\n String pathInfo = servletPath.substring(servletPath.indexOf(\"/\",TEMPLATE_LOAD_PROTOCOL.length()));\n if (templateName != null) { \n pathInfo = pathInfo + templateName;\n }\n return pathInfo;\n }",
"public final String path() {\n return string(preparePath(concat(path, SLASH, name)));\n }",
"public static String getBasepath() {\n\t\treturn basepath;\n\t}",
"public static String getBasepath() {\n\t\treturn basepath;\n\t}",
"private String getEclipsePathFromWindowsPath(String path) {\n StringBuilder sbPath = new StringBuilder();\n char [] chars = path.toCharArray();\n for (int i = 0; i < chars.length; i++) {\n char c = chars[i];\n if (c == '\\\\') {\n sbPath.append('/');\n } else {\n sbPath.append(c);\n }\n }\n path = sbPath.toString();\n return path;\n }",
"static String escapePathName(String path) {\n if (path == null || path.length() == 0) {\n throw new RuntimeException(\"Path should not be null or empty: \" + path);\n }\n\n StringBuilder sb = null;\n for (int i = 0; i < path.length(); i++) {\n char c = path.charAt(i);\n if (needsEscaping(c)) {\n if (sb == null) {\n sb = new StringBuilder(path.length() + 2);\n for (int j = 0; j < i; j++) {\n sb.append(path.charAt(j));\n }\n }\n escapeChar(c, sb);\n } else if (sb != null) {\n sb.append(c);\n }\n }\n if (sb == null) {\n return path;\n }\n return sb.toString();\n }",
"public static String getPath(String file_path)\n {\n String file_separator = System.getProperty(\"file.separator\"); //Bug Id 81741\n if (file_path == null)\n return null;\n else if (file_path.substring(file_path.length() - 1).equals(file_separator))//Bug Id 81741, substitute file_separator to System.getProperty(\"file.separator\")\n return file_path;\n else\n {\n \t //Bug Id 81741, Start \n\t if (\"/\".equals(file_separator) && (file_path.indexOf(file_separator) == -1))\n\t {\n\t file_path = file_path.replaceAll(\"\\\\\\\\\", \"/\");\n\t return ((new File(file_path)).getParent()).replaceAll(\"/\",\"\\\\\\\\\");\n\t }\n\t //Bug Id 81741, End\n\t else\n return (new File(file_path)).getParent();\n }\n }",
"public static void setRootDir() {\n for(int i = 0; i < rootDir.length; i++){\n Character temp = (char) (65 + i);\n Search.rootDir[i] = temp.toString() + \":\\\\\\\\\";\n }\n }",
"public void setPath(String path){\n mPath = path;\n }",
"public void testGetPath() throws Exception {\n Object[] test_values = {\n new String[]{\"\", \"\"},\n new String[]{\"/\", \"\"},\n new String[]{\"/foo.bar\", \"\"},\n new String[]{\"foo/bar\", \"foo\"},\n new String[]{\"/foo/bar\", \"/foo\"}\n };\n for (int i = 0; i < test_values.length; i++) {\n String tests[] = (String[]) test_values[i];\n String test = tests[0];\n String expected = tests[1];\n\n String result = NetUtils.getPath(test);\n String message = \"Test \" + \"'\" + test + \"'\";\n assertEquals(message, expected, result);\n }\n }",
"public interface ConsValues {\n\n public String PATH = \"/storage/extSdCard/Videos/Others/灵梦和幽幽子的弹幕.mp4\";\n}",
"public static String getServerPathKey(final String serverPath) {\n ArgumentHelper.checkNotNull(serverPath, \"serverPath\");\n return serverPath.toLowerCase();\n }",
"private String getHome()\n {\n return this.bufferHome.getAbsolutePath() + \"/\";\n }",
"private String prependServerDot(String s) {\n\n final String namedot = serverEnv.getInstanceName() + \".\";\n\n if(s.startsWith(namedot))\n return s;\n\n return namedot + s;\n }",
"private char[] getPath() {\n\t\treturn null;\n\t}",
"@Override\n\tpublic String getRealPath(String path) {\n\t\treturn null;\n\t}",
"private static void process() {\n try {\n \tpath = path.replaceAll(\"\\\\\\\\\",\"\\\\\\\\\\\\\\\\\");\n Process process = Runtime.getRuntime().exec(\"cmd /c start \"+\"\\\"\"+\"\\\" \\\"\"+ path+\"\\\"\");\n } catch (Exception ex) {\n ex.printStackTrace();\n }\n }",
"private static void findPath()\r\n {\r\n String temp_path = System.getProperty(\"user.dir\");\r\n char last = temp_path.charAt(temp_path.length() - 1);\r\n if(last == 'g')\r\n {\r\n path = \".\";\r\n }\r\n else\r\n {\r\n path = \"./bag\";\r\n }\r\n \r\n }",
"public static String getOneLevelServerPath(final String serverPath) {\n if (StringUtils.isEmpty(serverPath)) {\n // This is a strange case, but it seems correct to simply return the suffix\n return ONE_LEVEL_MAPPING_SUFFIX;\n }\n\n if (!isOneLevelMapping(serverPath)) {\n // remove any remaining /'s and add the /*\n return StringUtils.stripEnd(serverPath, \"/\") + ONE_LEVEL_MAPPING_SUFFIX;\n }\n\n // It already has the /* at the end\n return serverPath;\n }",
"@Test\n\tpublic void testGetBaseUrlDir() {\n\t\tString result = helper.getBaseUrl(\"http://www.bobbylough.com/test/\");\n\t\tassertEquals(\"http://www.bobbylough.com/test\", result);\n\t}",
"@Test\n public void testPlatformDiskSpaceConfigPath() {\n assertTrue(getPlatformDiskSpaceConfigPath().startsWith(getTempDirPath()\n\t+ File.separator));\n assertTrue(getPlatformDiskSpaceConfigPath().endsWith(File.separator\n\t+ PLATFORM_DISK_SPACE_CONFIG_FILENAME));\n }",
"private void readHttpPath(String line) {\n\t\tString[] parts = line.split(\" \");\n\t\tif (parts.length != 3) {\n\t\t\tchannel.close();\n\t\t} else {\n\t\t\trequest = new Request(parts[1].trim());\n\t\t}\n\t}",
"public static void CreateClientDirectory (Socket soc,String user){\r\n \r\n\t\tString path = \"C:/Users/harsh/Desktop/\"+user+\"/SharedFile.txt\"; //Static path for Server directory\r\n\t\tFile file = new File(path); // Sets File instance of directory\r\n\t\t\t\r\n\t\t/*create a new dynamic directory at specified location with directory name same as user name */\r\n\t\tboolean success = file.getParentFile().mkdirs(); \r\n\t\t\r\n\t\tif (!success) //if directory exists, delete and make again. This is when we run program again with same usernames\r\n\t\t{ \r\n\t\t\ttry {\r\n\t\t\tFileUtils.deleteDirectory(file.getParentFile()); //delete existing directory\r\n\t\t\tfile.getParentFile().mkdir(); //create new directory\r\n\t\t file.createNewFile(); //create a text file in the directory\r\n\t\t \r\n\t\t //inform user of successful connection and directory creation\r\n\t\t System.out.println(\"A directory with your username [\"+user+\"] has been created for you.\"\r\n\t\t\t\t\t+ \"\\nTo start sharing, place a file in this directory.\");\t\r\n\t\t\tSystem.out.println(\"-------------------------------------------\");\r\n\t\t\t} \r\n\t\t\r\n\t\t\tcatch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t\t} \r\n\t\t \r\n\t }\r\n\t\t\t\r\n\t\telse //If directory does not exist, create new and let user know \r\n\t\t{\t\r\n\t\t\ttry {\r\n\t\t\tfile.createNewFile(); //reference link in description of function\r\n\t\t\tSystem.out.println(\"A directory with your username [\"+user+\"] has been created for you.\"\r\n\t\t\t\t\t+ \"\\nTo start sharing, place a file in this directory.\");\t\r\n\t\t\tSystem.out.println(\"-------------------------------------------\");\r\n\t\t\t} \r\n\t\t\r\n\t\t\tcatch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t\t \r\n\t\t}\r\n\t\t\r\n\t\twhile(true) {\r\n\t\t\tWatchDirectory(user, soc); //Function call to watch directory for any new file \t\r\n\t\t }\r\n\t}",
"public static String formatPath(ServletContext context, Document dom, String application, Hashtable hash, String pathSrc, char separator) throws IOException {\n String ret = null;\r\n try\r\n {\r\n String listPathSrc[] = UtilString.split(pathSrc, separator);\r\n int len = UtilSafe.safeListSize(listPathSrc);\r\n // Trace.DEBUG(getInstance(), (new StringBuilder(\"formatPath listPathSrc:\")).append(listPathSrc).append(\" len:\").append(len).toString());\r\n if(len > 0)\r\n {\r\n File filePath = null;\r\n String path = null;\r\n int iDeb = 0;\r\n int iFin = 0;\r\n int iPos = 0;\r\n StringBuffer stb = new StringBuffer();\r\n for(int i = 0; i < len; i++)\r\n {\r\n path = (String)UtilSafe.safeListGetElementAt(listPathSrc, i);\r\n for(iPos = 0; iPos >= 0; iPos = iFin)\r\n {\r\n iDeb = path.indexOf('[', 0);\r\n iFin = path.indexOf(']', iDeb);\r\n // Trace.DEBUG(getInstance(), (new StringBuilder(\"formatPath path:\")).append(path).append(\" iPos:\").append(iPos).append(\" iDeb:\").append(iDeb).append(\" iFin:\").append(iFin).toString());\r\n if(iDeb >= 0 && iFin >= 0)\r\n {\r\n String szApplication = path.substring(iDeb + 1, iFin);\r\n String filePathMain = (String)hash.get(szApplication);\r\n if(filePathMain == null)\r\n if(context == null)\r\n filePathMain = AdpXmlApplication.getPathMain(dom, szApplication);\r\n else\r\n filePathMain = AdpXmlApplication.getFormatedPathMain(context, dom, szApplication);\r\n // Trace.DEBUG(getInstance(), (new StringBuilder(\"formatPath szApplication:\")).append(szApplication).append(\" filePathMain:\").append(filePathMain).toString());\r\n if(UtilString.isNotEmpty(filePathMain))\r\n {\r\n // Trace.DEBUG(getInstance(), (new StringBuilder(\"formatPath filePathMain isNotEmpty:\")).append(filePathMain).toString());\r\n hash.put(szApplication, filePathMain);\r\n if(!filePathMain.toUpperCase().startsWith(\"FTP://\"))\r\n {\r\n path = (new StringBuffer(path)).replace(iDeb, iFin + 1, filePathMain).toString();\r\n path = path.replace(File.separatorChar != '\\\\' ? '\\\\' : '/', File.separatorChar);\r\n } else\r\n {\r\n path = filePath.getCanonicalPath();\r\n }\r\n }\r\n } else\r\n if(UtilString.isNotEmpty(application) && !UtilFile.isPathAbsolute(path))\r\n {\r\n // Trace.DEBUG(getInstance(), (new StringBuilder(\"formatPath application isNotEmpty:\")).append(application).toString());\r\n String filePathApp = null;\r\n if(context == null)\r\n filePathApp = AdpXmlApplication.getPathMain(dom, application);\r\n else\r\n filePathApp = AdpXmlApplication.getFormatedPathMain(context, dom, application);\r\n path = (new File(filePathApp, path)).getCanonicalPath();\r\n }\r\n // Trace.DEBUG(getInstance(), (new StringBuilder(\"formatPath path:\")).append(path).toString());\r\n }\r\n\r\n if(stb.length() > 0)\r\n stb.append(\";\");\r\n stb.append(path);\r\n }\r\n\r\n ret = stb.toString();\r\n }\r\n }\r\n catch(Exception ex)\r\n {\r\n Trace.ERROR(ex);\r\n }\r\n return ret;\r\n }",
"String getPath();",
"String getPath();",
"String getPath();",
"String getPath();",
"String getPath();",
"public void initPath() {\r\n\t\tpath = new Path();\r\n\t}",
"private String servetransform1864(String server) throws InvalidServerURLException {\n\t\tMatcher m = serverPattern.matcher(server);\n\t\tif (!m.matches()) {\n\t\t\tthrow new InvalidServerURLException();\n\t\t}\n\n\t\tString protocol = m.group(1);\n\t\tif (protocol == null) {\n\t\t\tprotocol = \"https://\";\n\t\t}\n\t\tString serverName = m.group(2);\n\t\tString port = m.group(3);\n\t\tif (port == null) {\n\t\t\tport = \":\" + AppSettings.DEFAULT_PORT;\n\t\t}\n\n\t\tString context = m.group(5);\n\t\tif (context == null) {\n\t\t\tcontext = AppSettings.DEFAULT_CONTEXT;\n\t\t}\n\n\t\treturn protocol + serverName + port + \"/\" + context;\n\t}",
"private String getUrlBaseForLocalServer() {\n\t HttpServletRequest request = ((ServletRequestAttributes) \n\t\t\t RequestContextHolder.getRequestAttributes()).getRequest();\n\t String base = \"http://\" + request.getServerName() + ( \n\t (request.getServerPort() != 80) \n\t \t\t ? \":\" + request.getServerPort() \n\t\t\t\t : \"\");\n\t return base;\n\t}",
"public void createURL(){\n urlDB = ( PREFACE + server + \"/\" + database + options);\n }",
"public static String getNewPath() {\n return homePath + Integer.toString(++elementCounter) + \".ser\";\n }",
"protected StringBuilder convertPath(final String path) {\n\t\tStringBuilder pathBuffer = new StringBuilder(\"/app:company_home\");\n\t\tString[] parts = path.split(\"/\");\n\n\t\tString subpath;\n\n\t\tfor(String part : parts) {\n\t\t\tsubpath = part.trim();\n\n\t\t\tif(subpath.length() > 0) {\n\t\t\t\tpathBuffer.append(\"/cm:\").append(ISO9075.encode(subpath));\n\t\t\t}\n\t\t}\n\n\t\treturn pathBuffer;\n\t}"
] | [
"0.64179057",
"0.6258224",
"0.5925306",
"0.5878752",
"0.58712626",
"0.584947",
"0.58263654",
"0.57165647",
"0.56283545",
"0.56277865",
"0.5549731",
"0.55461794",
"0.553083",
"0.5525501",
"0.53908116",
"0.5385961",
"0.5381913",
"0.5379627",
"0.5346286",
"0.5322216",
"0.53125983",
"0.5260208",
"0.524402",
"0.52425903",
"0.5236042",
"0.52327794",
"0.51939124",
"0.5170213",
"0.51615",
"0.51602924",
"0.5157033",
"0.51377857",
"0.51224685",
"0.51224685",
"0.51189584",
"0.51189584",
"0.51189584",
"0.51189584",
"0.5114865",
"0.5104628",
"0.5101786",
"0.5099328",
"0.50746405",
"0.5069548",
"0.5044695",
"0.5019108",
"0.5018255",
"0.5015197",
"0.50008774",
"0.4992559",
"0.49864656",
"0.49833006",
"0.4982027",
"0.49775282",
"0.49713638",
"0.49626684",
"0.49499288",
"0.4949493",
"0.49469757",
"0.49391738",
"0.49312332",
"0.49309698",
"0.49271905",
"0.4920415",
"0.4913885",
"0.49113882",
"0.48953575",
"0.4888947",
"0.4883506",
"0.4883506",
"0.48822606",
"0.48763633",
"0.48762593",
"0.4865066",
"0.4864734",
"0.48621148",
"0.48579064",
"0.48577654",
"0.4854644",
"0.48523086",
"0.4851675",
"0.4848526",
"0.4841364",
"0.48387057",
"0.4832523",
"0.48315424",
"0.4831169",
"0.48302886",
"0.48276204",
"0.48242113",
"0.4817283",
"0.4817283",
"0.4817283",
"0.4817283",
"0.4817283",
"0.48164254",
"0.4809304",
"0.48049834",
"0.48040536",
"0.4797503",
"0.47925"
] | 0.0 | -1 |
A newCachedThreadPool with given ThreadFactory can execute runnables | public void testNewCachedThreadPool2() {
final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());
try (PoolCleaner cleaner = cleaner(e)) {
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public interface RunnableFactory {\n\n\t/**\n\t * Yields a new instance of the runnable.\n\t */\n\n Runnable mk();\n}",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"private void initThreadPool(int numOfThreadsInPool, int[][] resultMat, Observer listener) {\n for(int i=0;i<numOfThreadsInPool; i++){\r\n PoolThread newPoolThread = new PoolThread(m_TaskQueue, resultMat);\r\n newPoolThread.AddResultMatListener(listener);\r\n m_Threads.add(newPoolThread);\r\n }\r\n // Start all Threads:\r\n for(PoolThread currThread: m_Threads){\r\n currThread.start();\r\n }\r\n }",
"public static ThreadPoolExecutor getBoundedCachedThreadPool(\n\t\t\tint maxCachedThread, long timeout, TimeUnit unit,\n\t\t\tThreadFactory threadFactory) {\n\t\tThreadPoolExecutor boundedCachedThreadPool = new ThreadPoolExecutor(\n\t\t\t\tmaxCachedThread, maxCachedThread, timeout, unit,\n\t\t\t\tnew LinkedBlockingQueue<Runnable>(), threadFactory);\n\t\t// allow the core pool threads timeout and terminate\n\t\tboundedCachedThreadPool.allowCoreThreadTimeOut(true);\n\t\treturn boundedCachedThreadPool;\n\t}",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"public static void main(String[] args) {\n\t\tExecutorService pool = Executors.newFixedThreadPool(3);\n\t\t//ExecutorService pool = Executors.newSingleThreadExecutor();\n\t\t\n\t\tExecutorService pool2 = Executors.newCachedThreadPool();\n\t\t//this pool2 will add more thread into pool(when no other thread running), the new thread do not need to wait.\n\t\t//pool2 will delete un runing thread(unrun for 60 secs)\n\t\tThread t1 = new MyThread();\n\t\tThread t2 = new MyThread();\n\t\tThread t3 = new MyThread();\n\n\t\tpool.execute(t1);\n\t\tpool.execute(t2);\n\t\tpool.execute(t3);\n\t\tpool.shutdown();\n\t\t\n\t}",
"public static void main(String[] args) {\n SomeRunnable obj1 = new SomeRunnable();\n SomeRunnable obj2 = new SomeRunnable();\n SomeRunnable obj3 = new SomeRunnable();\n \n System.out.println(\"obj1 = \"+obj1);\n System.out.println(\"obj2 = \"+obj2);\n System.out.println(\"obj3 = \"+obj3);\n \n //Create fixed Thread pool, here pool of 2 thread will created\n ExecutorService pool = Executors.newFixedThreadPool(3);\n ExecutorService pool2 = Executors.newFixedThreadPool(2);\n pool.execute(obj1);\n pool.execute(obj2);\n pool2.execute(obj3);\n \n pool.shutdown();\n pool2.shutdown();\n }",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public void testNewCachedThreadPool3() {\n try {\n ExecutorService e = Executors.newCachedThreadPool(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"@Override\n\tpublic ThreadPoolExecutor getThreadPool(final HystrixThreadPoolKey threadPoolKey,\n\t\t\tfinal HystrixProperty<Integer> corePoolSize, final HystrixProperty<Integer> maximumPoolSize,\n\t\t\tfinal HystrixProperty<Integer> keepAliveTime, final TimeUnit unit,\n\t\t\tfinal BlockingQueue<Runnable> workQueue) {\n\n\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - default [threadPoolKey=\" + threadPoolKey.name() + \", corePoolSize=\"\n\t\t\t\t+ corePoolSize.get() + \", maximumPoolSize=\" + maximumPoolSize.get() + \", keepAliveTime=\"\n\t\t\t\t+ keepAliveTime.get() + \", unit=\" + unit.name() + \"], override with [threadPoolKey=\"\n\t\t\t\t+ threadPoolKey.name() + \", corePoolSize=\" + CORE_POOL_SIZE + \", maximumPoolSize=\" + MAX_POOL_SIZE\n\t\t\t\t+ \", keepAliveTime=\" + KEEP_ALIVE_TIME + \", unit=\" + TimeUnit.SECONDS.name() + \"]\");\n\n\t\tif (threadFactory != null) {\n\t\t\t// All threads will run as part of this application component.\n\t\t\tfinal ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(CORE_POOL_SIZE, MAX_POOL_SIZE,\n\t\t\t\t\tKEEP_ALIVE_TIME, TimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(BLOCKING_QUEUE_SIZE),\n\t\t\t\t\tthis.threadFactory);\n\n\t\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - initialized threadpool executor [threadPoolKey=\"\n\t\t\t\t\t+ threadPoolKey.name() + \"]\");\n\n\t\t\treturn threadPoolExecutor;\n\t\t} else {\n\t\t\tLOGGER.warn(LOG_PREFIX + \"getThreadPool - fallback to Hystrix default thread pool executor.\");\n\n\t\t\treturn super.getThreadPool(threadPoolKey, corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue);\n\t\t}\n\t}",
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"ActorThreadPool getThreadPool();",
"public interface ThreadPool<Job extends Runnable> {\n\n void execute(Job job);\n\n void shutDown();\n\n void addWorkers(int num);\n\n void removeWorkers(int num);\n\n int getJobSize();\n\n}",
"public ThreadPoolExecutor create_blocking_thread_pool( String name, int threads, int queue_size )\n {\n NamedThreadPoolExecutor ret = new NamedThreadPoolExecutor( name, queue_size, threads, threads, 60, TimeUnit.MINUTES);\n \n pool_list.add( ret );\n\n return ret;\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"private TestRunnableResult runRunnable(ModelFactory factory, TestRunnable runnable) {\n\t\tTestRunnableResult result = new TestRunnableResult();\n\t\tlong startMem, endMem, start, end;\n\t\tstartMem = ManagementFactory.getMemoryMXBean().getHeapMemoryUsage().getUsed();\n\t\tstart = System.currentTimeMillis();\n\t\tresult.returned = runnable.run(factory);\n\t\tend = System.currentTimeMillis();\n\t\tresult.usedTime = end - start;\n\t\tendMem = ManagementFactory.getMemoryMXBean().getHeapMemoryUsage().getUsed();\n\t\tresult.usedMemory = endMem - startMem;\n\t\treturn result;\n\t}",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"public void testPrivilegedThreadFactory() throws Exception {\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final ClassLoader thisccl = Thread.currentThread().getContextClassLoader();\n // android-note: Removed unsupported access controller check.\n // final AccessControlContext thisacc = AccessController.getContext();\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n assertSame(thisccl, current.getContextClassLoader());\n //assertEquals(thisacc, AccessController.getContext());\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.privilegedThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }};\n\n runWithPermissions(r,\n new RuntimePermission(\"getClassLoader\"),\n new RuntimePermission(\"setContextClassLoader\"),\n new RuntimePermission(\"modifyThread\"));\n }",
"public interface IHttpThreadExecutor {\n public void addTask(Runnable runnable);\n}",
"private synchronized void execute(TestRunnerThread testRunnerThread) {\n boolean hasSpace = false;\n while(!hasSpace) {\n threadLock.lock();\n try {\n hasSpace = currentThreads.size()<capacity;\n }\n finally {\n threadLock.unlock();\n }\n }\n \n //Adding thread to list and executing it\n threadLock.lock();\n try {\n currentThreads.add(testRunnerThread);\n testRunnerThread.setThreadPoolListener(this);\n Thread thread = new Thread(testRunnerThread);\n //System.out.println(\"Starting thread for \"+testRunnerThread.getTestRunner().getTestName());\n thread.start();\n }\n finally {\n threadLock.unlock();\n }\n }",
"public boolean newThreadPoolAvailable() {\n\t\tif (this.serverConnectorUsed+1 <= MAX_THREADS) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"public ThreadFactory threadFactory() {\n return threadFactory_;\n }",
"private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executorService = new ThreadPoolExecutor(3, 10, 1L, TimeUnit.SECONDS,\n new LinkedBlockingQueue<>(20),\n Executors.defaultThreadFactory(),\n new ThreadPoolExecutor.AbortPolicy());\n ABC abc = new ABC();\n try {\n for (int i = 1; i <= 10; i++) {\n executorService.execute(abc::print5);\n executorService.execute(abc::print10);\n executorService.execute(abc::print15);\n }\n\n }finally {\n executorService.shutdown();\n }\n }",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"public void testExecuteInParallel_Collection_ThreadPoolExecutor() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks, ParallelUtil.createThreadPool( 1 ) );\n assertEquals( result.size(), tasks.size() );\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"public static void main(String[] args) {\n\t\tBlockingQueue queue = new LinkedBlockingQueue(4);\n\n\t\t// Thread factory below is used to create new threads\n\t\tThreadFactory thFactory = Executors.defaultThreadFactory();\n\n\t\t// Rejection handler in case the task get rejected\n\t\tRejectTaskHandler rth = new RejectTaskHandler();\n\t\t// ThreadPoolExecutor constructor to create its instance\n\t\t// public ThreadPoolExecutor(int corePoolSize,int maximumPoolSize,long\n\t\t// keepAliveTime,\n\t\t// TimeUnit unit,BlockingQueue workQueue ,ThreadFactory\n\t\t// threadFactory,RejectedExecutionHandler handler) ;\n\t\tThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(1, 2, 10L, TimeUnit.MILLISECONDS, queue,\n\t\t\t\tthFactory, rth);\n\n\t\tfor (int i = 1; i <= 10; i++) {\n\t\t\tDataFileReader df = new DataFileReader(\"File \" + i);\n\t\t\tSystem.out.println(\"A new file has been added to read : \" + df.getFileName());\n\t\t\t// Submitting task to executor\n\t\t\tthreadPoolExecutor.execute(df);\n\t\t}\n\t\tthreadPoolExecutor.shutdown();\n\t}",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"public ImageManager(final Context context, final int cacheSize, \n final int threads ){\n\n // Instantiate the three queues. The task queue uses a custom comparator to \n // change the ordering from FIFO (using the internal comparator) to respect\n // request priorities. If two requests have equal priorities, they are \n // sorted according to creation date\n mTaskQueue = new PriorityBlockingQueue<Runnable>(QUEUE_SIZE, \n new ImageThreadComparator());\n mActiveTasks = new ConcurrentLinkedQueue<Runnable>();\n mBlockedTasks = new ConcurrentLinkedQueue<Runnable>();\n\n // The application context\n mContext = context;\n\n // Create a new threadpool using the taskQueue\n mThreadPool = new ThreadPoolExecutor(threads, threads, \n Long.MAX_VALUE, TimeUnit.SECONDS, mTaskQueue){\n\n\n @Override\n protected void beforeExecute(final Thread thread, final Runnable run) {\n // Before executing a request, place the request on the active queue\n // This prevents new duplicate requests being placed in the active queue\n mActiveTasks.add(run);\n super.beforeExecute(thread, run);\n }\n\n @Override\n protected void afterExecute(final Runnable r, final Throwable t) {\n // After a request has finished executing, remove the request from\n // the active queue, this allows new duplicate requests to be submitted\n mActiveTasks.remove(r);\n\n // Perform a quick check to see if there are any remaining requests in\n // the blocked queue. Peek the head and check for duplicates in the \n // active and task queues. If no duplicates exist, add the request to\n // the task queue. Repeat this until a duplicate is found\n synchronized (mBlockedTasks) {\n while(mBlockedTasks.peek()!=null && \n !mTaskQueue.contains(mBlockedTasks.peek()) && \n !mActiveTasks.contains(mBlockedTasks.peek())){\n Runnable runnable = mBlockedTasks.poll();\n if(runnable!=null){\n mThreadPool.execute(runnable);\n }\n }\n }\n super.afterExecute(r, t);\n }\n };\n\n // Calculate the cache size\n final int actualCacheSize = \n ((int) (Runtime.getRuntime().maxMemory() / 1024)) / cacheSize;\n\n // Create the LRU cache\n // http://developer.android.com/reference/android/util/LruCache.html\n\n // The items are no longer recycled as they leave the cache, turns out this wasn't the right\n // way to go about this and often resulted in recycled bitmaps being drawn\n // http://stackoverflow.com/questions/10743381/when-should-i-recycle-a-bitmap-using-lrucache\n mBitmapCache = new LruCache<String, Bitmap>(actualCacheSize){\n protected int sizeOf(final String key, final Bitmap value) {\n return value.getByteCount() / 1024;\n }\n };\n }",
"TaskFactory getTaskFactory();",
"public void testForNThreads();",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"public ThreadPool getDefaultThreadPool();",
"private static void threadPoolWithExecute() {\n\n Executor executor = Executors.newFixedThreadPool(3);\n IntStream.range(1, 10)\n .forEach((i) -> {\n executor.execute(() -> {\n System.out.println(\"started task for id - \"+i);\n try {\n if (i == 8) {\n Thread.sleep(4000);\n } else {\n Thread.sleep(1000);\n }\n System.out.println(\"In runnable task for id -\" + i);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n });\n System.out.println(\"End of method .THis gets printed immdly since execute is not blocking call\");\n }",
"public Builder setThreadFactory(ThreadFactory threadFactory) {\n threadFactory_ = (threadFactory != null) ? threadFactory : Executors.defaultThreadFactory();\n return this;\n }",
"public static CacheManagerExecutorServiceFactory getInstance() {\n return SINGLETON;\n }",
"public void testCastNewSingleThreadExecutor() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n try {\n ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;\n shouldThrow();\n } catch (ClassCastException success) {}\n }\n }",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"public static void m18362a(Runnable runnable) {\n if (runnable == null) {\n return;\n }\n if (m18371b()) {\n f16362c.execute(runnable);\n if (Proxy.f16280c) {\n Log.e(\"TAG_PROXY_UTIL\", \"invoke in pool thread\");\n return;\n }\n return;\n }\n runnable.run();\n if (Proxy.f16280c) {\n Log.e(\"TAG_PROXY_UTIL\", \"invoke calling thread\");\n }\n }",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"@Override\n protected Thread createThread(final Runnable runnable, final String name) {\n return new Thread(runnable, Thread.currentThread().getName() + \"-exec\");\n }",
"static ElementMatcher.Junction<? super TypeDescription> createTypeMatcher() {\n return isSubTypeOf(ThreadPoolExecutor.class)\n // ScheduledThreadPoolExecutor is handled separately, via ScheduledFutureTaskInterceptor\n .and(not(isSubTypeOf(ScheduledThreadPoolExecutor.class)));\n }",
"public interface ThreadExecutor extends Executor {\n}",
"public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }",
"@Override\n\tpublic Thread newThread(Runnable r) {\n\t\t\n\t\tThread th = new Thread(r,\" custum Thread\");\n\t\treturn th;\n\t}",
"@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\r\n\tpublic static void main(String[] args) throws InterruptedException, ExecutionException{\n\t\tExecutorService e = Executors.newFixedThreadPool(2);\r\n//\t\tList<Future> list = new ArrayList<Future>();\r\n\t\tfor(int i=0;i<10;i++){\r\n\t\t\tCallable c = new JavaTestThread(i);\r\n\t\t\tFuture f = e.submit(c);\r\n\t\t\tSystem.out.println(\"-------\"+ f.get().toString());\r\n\t\t}\r\n\t\t\r\n\t\r\n\t\t\r\n\t}",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"public static Runnable decorate(ThreadPoolExecutor thiz, Runnable r) {\n /*\n * Here we handle the special case of this ThreadPoolExecutor (TPE) actually being an instance of\n * ScheduledThreadPoolExecutor (STPE). STPE subclasses TPE and doesn't override its remove() method.\n * When STPE.remove() is invoked, it actually invokes TPE.remove(). Thus despite ThreadPoolExecutorInterceptor\n * excluding STPE (and its subclasses) from interception, here we need to take this extra action to exclude\n * STPE.\n *\n * STPE uses a member class ScheduledFutureTask to manage delayed work. If the Runnable `r' is actually\n * a ScheduledFutureTask, then wrapping it here in a DecoratedRunnable will result in the check\n * `instanceof ScheduledFutureTask' failing in the implementation of `ScheduledThreadPoolExecutor$DelayedWorkQueue.indexOf',\n * which will result in a linear scan of the STPE's task queue instead of a constant-time lookup into\n * the array backing that queue. This performance regression may be dangerous in high-load scenarios.\n */\n if (thiz instanceof ScheduledThreadPoolExecutor) {\n return r;\n } else {\n return DecoratedRunnable.maybeCreate(r);\n }\n }",
"public WildflyHystrixConcurrencyStrategy(final ManagedThreadFactory threadFactory) {\n\t\t//\n\t\t// Used by CDI provider.\n\t\t\n\t\tthis.threadFactory = threadFactory;\n\t}",
"public void startThread() \n { \n ExecutorService taskList = \n Executors.newFixedThreadPool(2); \n for (int i = 0; i < 5; i++) \n { \n // Makes tasks available for execution. \n // At the appropriate time, calls run \n // method of runnable interface \n taskList.execute(new Counter(this, i + 1, \n \"task \" + (i + 1))); \n } \n \n // Shuts the thread that's watching to see if \n // you have added new tasks. \n taskList.shutdown(); \n }",
"ScheduledExecutorService getExecutorService();",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"public static void main(String[] args) {\n Runnable runnable = new Runnable() {\n @Override\n public void run() {\n for(int i =0; i<10000; i++){\n System.out.println(\n Thread.currentThread().getId() + \":\" + i\n );\n }\n }\n };\n\n // using functions, a bit cleaner\n Runnable runnable2 = () -> {\n for(int i =0; i<10000; i++){\n System.out.println(\n Thread.currentThread().getId() + \":\" + i\n );\n }\n };\n\n Thread thread = new Thread(runnable);\n thread.start();\n\n Thread thread2 = new Thread(runnable);\n thread2.start();\n\n Thread thread3 = new Thread(runnable);\n thread3.start();\n\n }",
"public static void main(String[] args) {\n ExecutorService threadPool = Executors.newCachedThreadPool();\n\n try{\n for (int i = 0; i < 10; i++) {\n threadPool.execute(() ->{\n System.out.println(Thread.currentThread().getName()+\"\\t 办理业务\");\n });\n //try {TimeUnit.SECONDS.sleep(1); } catch (InterruptedException e) {e.printStackTrace();}\n }\n\n } catch (Exception e) {\n e.printStackTrace();\n }finally {\n threadPool.shutdown();\n }\n\n\n\n }",
"public static ThreadPoolTaskScheduler createThreadPoolTaskScheduler(\r\n\t\t\tExecutorService executorService, \r\n\t\t\tFrequency frequency, String name, TimeZone timezone){\r\n\t\treturn new ThreadPoolTaskScheduler(executorService, frequency, name, timezone);\r\n\t}",
"@Test\n @DisplayName(\"Invoke Any\")\n void invokeAny() throws ExecutionException, InterruptedException {\n ExecutorService executor = Executors.newWorkStealingPool();\n\n List<Callable<String>> callables = Arrays.asList(\n callable(\"task1\", 2),\n callable(\"task2\", 1),\n callable(\"task3\", 3));\n\n String result = executor.invokeAny(callables);\n assertEquals(\"task2\", result);\n }",
"public static ScheduledExecutorService createNewScheduler() {\n return Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessors() * 2);\n }",
"private static void ThreadCreationOldWay() {\r\n\t\tThread t1 = new Thread(new Runnable() {\r\n\t\t\tpublic void run() {\r\n\t\t\t\tSystem.out.println(\"This is a runnable method done in old fashion < 1.8\");\r\n\t\t\t}\r\n\t\t});\r\n\t\tt1.start();\r\n\t}",
"public static void main(String[] args)\n {\n Runnable r1 = new Task1();\n // Creates Thread task\n Task2 r2 = new Task2();\n ExecutorService pool = Executors.newFixedThreadPool(MAX_T);\n\n pool.execute(r1);\n r2.start();\n\n // pool shutdown\n pool.shutdown();\n }",
"private void YeWuMethod(String name) {\n\n for (int j = 0; j < 10; j++) {\n\n\n// Runnable task = new RunnableTask();\n// Runnable ttlRunnable = TtlRunnable.get(task);\n\n// executor.execute(ttlRunnable);\n\n executor.execute(() -> {\n System.out.println(\"==========\"+name+\"===\"+threadLocal.get());\n });\n }\n\n// for (int i = 0; i < 10; i++) {\n// new Thread(() -> {\n// System.out.println(name+\"===\"+threadLocal.get());\n// }, \"input thread name\").start();\n// }\n\n\n\n\n }",
"private static void createThreadUsingLambdaExpressions() {\n\t\tRunnable r = () -> {System.out.println(\"Lambda Expression thread is executed.\");};\n\t\tThread t = new Thread(r);\n\t\tt.start();\n\t}",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public void testCallable2() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable(), one);\n assertSame(one, c.call());\n }",
"private void init(int threadCount, Type type) {\r\n //The backend starts to polling threads.\r\n mPoolThread=new Thread(){\r\n @Override\r\n public void run() {\r\n Looper.prepare();\r\n mPoolThreadHandler=new Handler(){\r\n @Override\r\n public void handleMessage(Message msg) {\r\n //take a thread from the thread pool and execute it.\r\n mThreadPool.execute(getTask());\r\n try {\r\n mSemaphoreThreadPool.acquire();\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n };\r\n //if this thread is finished, release a signal to the handler.\r\n mSemaphorePoolThreadHandler.release();\r\n Looper.loop();\r\n }\r\n };\r\n mPoolThread.start();\r\n //Get the maximum available memory for our service.\r\n int maxMemory= (int) Runtime.getRuntime().maxMemory();\r\n int cacheMemory = maxMemory / 8;//8\r\n mLruCache=new LruCache<String, Bitmap>(cacheMemory){\r\n @Override\r\n protected int sizeOf(String key, Bitmap value) {\r\n return value.getRowBytes()*value.getHeight();\r\n }\r\n };\r\n mThreadPool= Executors.newFixedThreadPool(threadCount);\r\n mTaskQueue=new LinkedList<>();\r\n mType=type==null? Type.LIFO:type;\r\n mSemaphoreThreadPool=new Semaphore(threadCount);\r\n\r\n }",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"public static ThreadPool getInstance()\r\n {\r\n if(instance == null)\r\n {\r\n instance = new ThreadPool();\r\n }\r\n return instance;\r\n }",
"@Override\r\n public Thread newThread(Runnable r) {\n Thread t = new Thread(r, \"example-runner\");\r\n t.setDaemon(true);\r\n return t;\r\n }",
"public static void main(String[] args) {\r\n\t\tMyThread thread = new MyThread();\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t}",
"public static void main(String args[]) {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n\t\t\n\t\t// Create a list to hold the Future object associated with Callable\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\n\n\t\t/**\n\t\t * Create MyCallable instance using Lambda expression which return\n\t\t * the thread name executing this callable task\n\t\t */\n\t\tCallable<String> callable = () -> {\n\t\t\tThread.sleep(2000);\n\t\t\treturn Thread.currentThread().getName();\n\t\t};\n\t\t\n\t\t/**\n\t\t * Submit Callable tasks to be executed by thread pool\n\t\t * Add Future to the list, we can get return value using Future\n\t\t **/\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tFuture<String> future = executor.submit(callable);\n\t\t\tfutureList.add(future);\n\t\t}\n\t\t\n\t\t/**\n\t\t * Print the return value of Future, notice the output delay\n\t\t * in console because Future.get() waits for task to get completed\n\t\t **/\n\t\tfor (Future<String> future : futureList) {\n\t\t\ttry {\n\t\t\t\tSystem.out.println(new Date() + \" | \" + future.get());\n\t\t\t} catch (InterruptedException | ExecutionException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\t// shut down the executor service.\n\t\texecutor.shutdown();\n\t}",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"public static void main(String[] args) {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(3);\n scheduledThreadPoolExecutor.setRemoveOnCancelPolicy(true);\n SystemOutUtil.println(\"start schedule\");\n scheduledThreadPoolExecutor.schedule(new DelayCallableTask(), 1000, TimeUnit.MILLISECONDS);\n RunnableScheduledFuture<?> rateFuture =\n (RunnableScheduledFuture<?>) scheduledThreadPoolExecutor\n .scheduleAtFixedRate(new FixRateRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n ScheduledFuture delayFuture =\n scheduledThreadPoolExecutor.scheduleWithFixedDelay(new FixDelayRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n SystemOutUtil.println(\"end schedule\");\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"start stop\");\n\n// scheduledThreadPoolExecutor.remove(rateFuture); // 无效\n rateFuture.cancel(false);\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n scheduledThreadPoolExecutor.shutdown();\n return;\n }",
"@Test\n @ConditionalIgnoreRule.ConditionalIgnore(condition = RunningOnGithubAction.class)\n public void testSuccess() throws Exception {\n int concurrency = 10;\n ExecutorService executorService = Executors.newFixedThreadPool(10);\n List<Future<?>> futures = new ArrayList<>();\n // create 10 threads, each open a connection and submit a query\n // after sleeping 15 seconds\n for (int idx = 0; idx < concurrency; idx++) {\n logger.fine(\"open a new connection and submit query \" + idx);\n final int queryIdx = idx;\n futures.add(\n executorService.submit(\n () -> {\n try {\n submitQuery(true, queryIdx);\n } catch (SQLException | InterruptedException e) {\n throw new IllegalStateException(\"task interrupted\", e);\n }\n }));\n }\n executorService.shutdown();\n for (int idx = 0; idx < concurrency; idx++) futures.get(idx).get();\n }",
"protected EventExecutor newChild(ThreadFactory threadFactory, Object... args) throws Exception {\n/* 57 */ return (EventExecutor)new LocalEventLoop(this, threadFactory);\n/* */ }",
"public FuncCallExecutor(ThreadRuntime rt) {\r\n\t\tthis.rt = rt;\r\n\t}",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testCallable1() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable());\n assertNull(c.call());\n }",
"private TestAcceptFactory() {\n this._pool = new DirectExecutor();\n }",
"private static void multiThreading(){\n\t\tSystem.out.println(\"\\nCreating new two separate instances of Singleton using Multi threading\");\n\t\tExecutorService service = Executors.newFixedThreadPool(2);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.shutdown();\n\t}",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"public TestInvoker()\n {\n super(new TestClient(), new ThreadPoolExecutorImpl(3));\n }",
"public static void main(String[] args) {\n ExecutorService es = Executors.newCachedThreadPool();\n es.execute(new Task(65));\n es.execute(new Task(5));\n System.out.println(\"结束执行!\");\n }",
"private Thread startTestThread(Runnable runnable) {\n Thread t = new Thread(runnable);\n t.setDaemon(true);\n return t;\n }",
"public ThreadPoolExecutorTracer(int corePoolSize, int maximumPoolSize, long keepAliveTime,\n TimeUnit unit, BlockingQueue<Runnable> workQueue, ThreadFactory threadFactory) {\n super(corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue, threadFactory);\n }",
"public static void main(String[] args) {\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\r\n\r\n\t\t//collection of multiple tasks which we are supposed to give to thread pool to perform\r\n\t\tList<CallableDemo> taskList = new ArrayList<CallableDemo>();\r\n\t\t//adding multiple tasks to collection (tasks are created using 'Callable' Interface.\r\n\t\ttaskList.add(new CallableDemo(\"first\"));\r\n\t\ttaskList.add(new CallableDemo(\"second\"));\r\n\t\ttaskList.add(new CallableDemo(\"third\"));\r\n\t\ttaskList.add(new CallableDemo(\"fourth\"));\r\n\t\ttaskList.add(new CallableDemo(\"fifth\"));\r\n\t\ttaskList.add(new CallableDemo(\"sixth\"));\r\n\t\ttaskList.add(new CallableDemo(\"seventh\"));\r\n\r\n\t\t//creating a thread pool of size four\r\n\t\tExecutorService threadPool = Executors.newFixedThreadPool(4);\r\n\t\t\r\n\t\tfor (CallableDemo task : taskList) {\r\n\t\t\tfutureList.add(threadPool.submit(task));\r\n\t\t}\r\n threadPool.shutdown();\r\n\t\tfor (Future<String> future : futureList) {\r\n\t\t\ttry {\r\n//\t\t\t\t System.out.println(future.get());\r\n\t\t\t\tSystem.out.println(future.get(1L, TimeUnit.SECONDS));\r\n\t\t\t} catch (InterruptedException | ExecutionException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}catch (TimeoutException e) {\r\n\t\t\t\tSystem.out.println(\"Sorry already waited for result for 1 second , can't wait anymore...\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t}"
] | [
"0.62284935",
"0.6080023",
"0.6014803",
"0.5887917",
"0.58762616",
"0.58698195",
"0.57630974",
"0.5736035",
"0.57247484",
"0.568378",
"0.5655777",
"0.5630085",
"0.5625458",
"0.56235856",
"0.561875",
"0.5614708",
"0.56144345",
"0.5585072",
"0.5550768",
"0.55237573",
"0.55061007",
"0.5498675",
"0.5484447",
"0.5484001",
"0.54620624",
"0.5458378",
"0.5443264",
"0.54054",
"0.53818244",
"0.5380087",
"0.5378108",
"0.53639716",
"0.5356258",
"0.53237027",
"0.5322776",
"0.5316558",
"0.53017807",
"0.5270457",
"0.52440614",
"0.522908",
"0.522213",
"0.5218538",
"0.5216887",
"0.521175",
"0.521076",
"0.5209508",
"0.52094895",
"0.5200273",
"0.51935494",
"0.5187547",
"0.5185786",
"0.51705796",
"0.51585454",
"0.51579654",
"0.5147036",
"0.5140124",
"0.5117137",
"0.5108316",
"0.5107023",
"0.5106929",
"0.50964123",
"0.5090305",
"0.5086573",
"0.50860417",
"0.50844336",
"0.50623494",
"0.5052503",
"0.5049847",
"0.50435954",
"0.50425196",
"0.5040143",
"0.50398076",
"0.5029755",
"0.50085866",
"0.50028",
"0.49939486",
"0.49906412",
"0.49906054",
"0.4987778",
"0.4978877",
"0.49776655",
"0.49625292",
"0.4958996",
"0.49579775",
"0.49524963",
"0.49436125",
"0.49243015",
"0.49187633",
"0.4914175",
"0.489055",
"0.48882526",
"0.48871887",
"0.48800528",
"0.48790962",
"0.48645246",
"0.4858925",
"0.4846516",
"0.48354977",
"0.48215082",
"0.48184383"
] | 0.6286632 | 0 |
A newCachedThreadPool with null ThreadFactory throws NPE | public void testNewCachedThreadPool3() {
try {
ExecutorService e = Executors.newCachedThreadPool(null);
shouldThrow();
} catch (NullPointerException success) {}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@Override\n protected ExecutorService createDefaultExecutorService() {\n return null;\n }",
"public ThreadPool getDefaultThreadPool();",
"@Test(expected = NullPointerException.class)\n public void testConstructorNPE2() throws NullPointerException {\n Executors.newCachedThreadPool();\n new BoundedCompletionService<Void>(null);\n shouldThrow();\n }",
"@Override\r\n\tpublic Thread newThread(Runnable arg0) {\n\t\treturn null;\r\n\t}",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public void testNewSingleThreadExecutor3() {\n try {\n ExecutorService e = Executors.newSingleThreadExecutor(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@PostConstruct\r\n\tprivate void init() {\n\t threadPool = Executors.newCachedThreadPool();\r\n\t}",
"public void initialize() {\n service = Executors.newCachedThreadPool();\n }",
"public ThreadLocal() {}",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public static CacheManagerExecutorServiceFactory getInstance() {\n return SINGLETON;\n }",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"public void testCallableNPE2() {\n try {\n Callable c = Executors.callable((Runnable) null, one);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public ThreadPool()\r\n {\r\n // 20 seconds of inactivity and a worker gives up\r\n suicideTime = 20000;\r\n // half a second for the oldest job in the queue before\r\n // spawning a worker to handle it\r\n spawnTime = 500;\r\n jobs = null;\r\n activeThreads = 0;\r\n askedToStop = false;\r\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"protected ThreadPool getPool()\r\n {\r\n return threadPool_;\r\n }",
"public void testCallableNPE1() {\n try {\n Callable c = Executors.callable((Runnable) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private void initThreadPool(int numOfThreadsInPool, int[][] resultMat, Observer listener) {\n for(int i=0;i<numOfThreadsInPool; i++){\r\n PoolThread newPoolThread = new PoolThread(m_TaskQueue, resultMat);\r\n newPoolThread.AddResultMatListener(listener);\r\n m_Threads.add(newPoolThread);\r\n }\r\n // Start all Threads:\r\n for(PoolThread currThread: m_Threads){\r\n currThread.start();\r\n }\r\n }",
"ActorThreadPool getThreadPool();",
"public HotrodCacheFactory() {\n }",
"public static ThreadPool getInstance()\r\n {\r\n if(instance == null)\r\n {\r\n instance = new ThreadPool();\r\n }\r\n return instance;\r\n }",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public ThreadPool getThreadPool(String threadpoolId) throws NoSuchThreadPoolException;",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }",
"private void init(int threadCount, Type type) {\r\n //The backend starts to polling threads.\r\n mPoolThread=new Thread(){\r\n @Override\r\n public void run() {\r\n Looper.prepare();\r\n mPoolThreadHandler=new Handler(){\r\n @Override\r\n public void handleMessage(Message msg) {\r\n //take a thread from the thread pool and execute it.\r\n mThreadPool.execute(getTask());\r\n try {\r\n mSemaphoreThreadPool.acquire();\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n };\r\n //if this thread is finished, release a signal to the handler.\r\n mSemaphorePoolThreadHandler.release();\r\n Looper.loop();\r\n }\r\n };\r\n mPoolThread.start();\r\n //Get the maximum available memory for our service.\r\n int maxMemory= (int) Runtime.getRuntime().maxMemory();\r\n int cacheMemory = maxMemory / 8;//8\r\n mLruCache=new LruCache<String, Bitmap>(cacheMemory){\r\n @Override\r\n protected int sizeOf(String key, Bitmap value) {\r\n return value.getRowBytes()*value.getHeight();\r\n }\r\n };\r\n mThreadPool= Executors.newFixedThreadPool(threadCount);\r\n mTaskQueue=new LinkedList<>();\r\n mType=type==null? Type.LIFO:type;\r\n mSemaphoreThreadPool=new Semaphore(threadCount);\r\n\r\n }",
"public void testCallable1() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable());\n assertNull(c.call());\n }",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"@Override\n\tpublic ThreadPoolExecutor getThreadPool(final HystrixThreadPoolKey threadPoolKey,\n\t\t\tfinal HystrixProperty<Integer> corePoolSize, final HystrixProperty<Integer> maximumPoolSize,\n\t\t\tfinal HystrixProperty<Integer> keepAliveTime, final TimeUnit unit,\n\t\t\tfinal BlockingQueue<Runnable> workQueue) {\n\n\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - default [threadPoolKey=\" + threadPoolKey.name() + \", corePoolSize=\"\n\t\t\t\t+ corePoolSize.get() + \", maximumPoolSize=\" + maximumPoolSize.get() + \", keepAliveTime=\"\n\t\t\t\t+ keepAliveTime.get() + \", unit=\" + unit.name() + \"], override with [threadPoolKey=\"\n\t\t\t\t+ threadPoolKey.name() + \", corePoolSize=\" + CORE_POOL_SIZE + \", maximumPoolSize=\" + MAX_POOL_SIZE\n\t\t\t\t+ \", keepAliveTime=\" + KEEP_ALIVE_TIME + \", unit=\" + TimeUnit.SECONDS.name() + \"]\");\n\n\t\tif (threadFactory != null) {\n\t\t\t// All threads will run as part of this application component.\n\t\t\tfinal ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(CORE_POOL_SIZE, MAX_POOL_SIZE,\n\t\t\t\t\tKEEP_ALIVE_TIME, TimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(BLOCKING_QUEUE_SIZE),\n\t\t\t\t\tthis.threadFactory);\n\n\t\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - initialized threadpool executor [threadPoolKey=\"\n\t\t\t\t\t+ threadPoolKey.name() + \"]\");\n\n\t\t\treturn threadPoolExecutor;\n\t\t} else {\n\t\t\tLOGGER.warn(LOG_PREFIX + \"getThreadPool - fallback to Hystrix default thread pool executor.\");\n\n\t\t\treturn super.getThreadPool(threadPoolKey, corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue);\n\t\t}\n\t}",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"private synchronized WorkerThread getThread() {\n\t\tfor (int i = 0; i < this.threadPool.size(); ++i) {\n\t\t\tif (this.threadPool.get(i).available()) {\n\t\t\t\tthis.threadPool.get(i).setAvailable(false);\n\t\t\t\treturn this.threadPool.get(i);\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"public static ExecutorService m22730c() {\n if (f20302c == null) {\n synchronized (C7258h.class) {\n if (f20302c == null) {\n f20302c = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.IO).mo18996a(), true);\n }\n }\n }\n return f20302c;\n }",
"public ThreadFactory threadFactory() {\n return threadFactory_;\n }",
"public void initialize() {\n\n\t\t// Initialize taskList\n\t\tthis.taskList = new LinkedList<Task>();\n\n\t\t// create a new thread for total size of pool\n\t\tfor (int i = 0; i < this.poolSize; ++i) {\n\t\t\tthreadPool.add(new WorkerThread(this));\n\t\t}\n\n\t\t// Start each thread in thread pool\n\t\tfor (WorkerThread t : threadPool) {\n\t\t\tnew Thread(t).start();\n\t\t}\n\n\t}",
"@Override // java.lang.ThreadLocal\n public final AnonymousClass0jT initialValue() {\n return new AnonymousClass0jT();\n }",
"public final /* bridge */ /* synthetic */ Object mo6445a() {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(1, (ThreadFactory) this.f9355a.mo6445a());\n cazf.m127593a(scheduledThreadPoolExecutor, \"Cannot return null from a non-@Nullable @Provides method\");\n return scheduledThreadPoolExecutor;\n }",
"public void testCallableNPE3() {\n try {\n Callable c = Executors.callable((PrivilegedAction) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"public static ExecutorService m22732e() {\n if (f20304e == null) {\n synchronized (C7258h.class) {\n if (f20304e == null) {\n f20304e = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.BACKGROUND).mo18996a(), true);\n }\n }\n }\n return f20304e;\n }",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public void testCastNewSingleThreadExecutor() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n try {\n ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;\n shouldThrow();\n } catch (ClassCastException success) {}\n }\n }",
"public static Executor m13822l() {\n synchronized (f12483o) {\n if (f12471c == null) {\n f12471c = AsyncTask.THREAD_POOL_EXECUTOR;\n }\n }\n return f12471c;\n }",
"@PostConstruct\r\n public void init() {\r\n \t//registerNotificationCallback(null); //to register taskexecution engine as default\r\n ThreadFactory namedThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"MARM-thread-%d\").build();\r\n \texecutor = Executors.newFixedThreadPool(10, namedThreadFactory);\r\n\r\n ThreadFactory brokerThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"Broker-thread-%d\").build();\r\n brokerExecutor = Executors.newFixedThreadPool(10, brokerThreadFactory);\r\n\r\n ThreadFactory logThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"LOG-thread-%d\").setPriority(Thread.MIN_PRIORITY).build();\r\n logExecutor = Executors.newFixedThreadPool(10, logThreadFactory);\r\n broker.registerInputListener(this);\r\n broker.registerControlListener(this);\r\n }",
"private GDMThreadFactory(){}",
"public static ExecutorService m22731d() {\n if (f20303d == null) {\n synchronized (C7258h.class) {\n if (f20303d == null) {\n f20303d = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.DEFAULT).mo18996a(), true);\n }\n }\n }\n return f20303d;\n }",
"public LocalEventLoopGroup(int nThreads, ThreadFactory threadFactory) {\n/* 51 */ super(nThreads, threadFactory, new Object[0]);\n/* */ }",
"public ForkJoinPoolMgr() {\n }",
"public ImageManager(final Context context, final int cacheSize, \n final int threads ){\n\n // Instantiate the three queues. The task queue uses a custom comparator to \n // change the ordering from FIFO (using the internal comparator) to respect\n // request priorities. If two requests have equal priorities, they are \n // sorted according to creation date\n mTaskQueue = new PriorityBlockingQueue<Runnable>(QUEUE_SIZE, \n new ImageThreadComparator());\n mActiveTasks = new ConcurrentLinkedQueue<Runnable>();\n mBlockedTasks = new ConcurrentLinkedQueue<Runnable>();\n\n // The application context\n mContext = context;\n\n // Create a new threadpool using the taskQueue\n mThreadPool = new ThreadPoolExecutor(threads, threads, \n Long.MAX_VALUE, TimeUnit.SECONDS, mTaskQueue){\n\n\n @Override\n protected void beforeExecute(final Thread thread, final Runnable run) {\n // Before executing a request, place the request on the active queue\n // This prevents new duplicate requests being placed in the active queue\n mActiveTasks.add(run);\n super.beforeExecute(thread, run);\n }\n\n @Override\n protected void afterExecute(final Runnable r, final Throwable t) {\n // After a request has finished executing, remove the request from\n // the active queue, this allows new duplicate requests to be submitted\n mActiveTasks.remove(r);\n\n // Perform a quick check to see if there are any remaining requests in\n // the blocked queue. Peek the head and check for duplicates in the \n // active and task queues. If no duplicates exist, add the request to\n // the task queue. Repeat this until a duplicate is found\n synchronized (mBlockedTasks) {\n while(mBlockedTasks.peek()!=null && \n !mTaskQueue.contains(mBlockedTasks.peek()) && \n !mActiveTasks.contains(mBlockedTasks.peek())){\n Runnable runnable = mBlockedTasks.poll();\n if(runnable!=null){\n mThreadPool.execute(runnable);\n }\n }\n }\n super.afterExecute(r, t);\n }\n };\n\n // Calculate the cache size\n final int actualCacheSize = \n ((int) (Runtime.getRuntime().maxMemory() / 1024)) / cacheSize;\n\n // Create the LRU cache\n // http://developer.android.com/reference/android/util/LruCache.html\n\n // The items are no longer recycled as they leave the cache, turns out this wasn't the right\n // way to go about this and often resulted in recycled bitmaps being drawn\n // http://stackoverflow.com/questions/10743381/when-should-i-recycle-a-bitmap-using-lrucache\n mBitmapCache = new LruCache<String, Bitmap>(actualCacheSize){\n protected int sizeOf(final String key, final Bitmap value) {\n return value.getByteCount() / 1024;\n }\n };\n }",
"public ResourcePoolImpl() {\r\n this((ResourcePool) null);\r\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"public static ExecutorService m22734g() {\n if (f20306g == null) {\n synchronized (C7258h.class) {\n if (f20306g == null) {\n f20306g = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.SERIAL).mo18996a(), true);\n }\n }\n }\n return f20306g;\n }",
"private ThreadUtil() {\n \n }",
"public TestInvoker()\n {\n super(new TestClient(), new ThreadPoolExecutorImpl(3));\n }",
"public static ScheduledExecutorService m22733f() {\n if (f20305f == null) {\n synchronized (C7258h.class) {\n if (f20305f == null) {\n f20305f = (ScheduledExecutorService) C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.SCHEDULED).mo18993a(1).mo18996a(), true);\n }\n }\n }\n return f20305f;\n }",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }",
"private ConnectionPool() {\n connections = new LinkedBlockingQueue<>(DEFAULT_POOL_SIZE);\n this.init();\n }",
"public AbstractConcurrentTestCase() {\n mainThread = Thread.currentThread();\n }",
"public void testCallableNPE4() {\n try {\n Callable c = Executors.callable((PrivilegedExceptionAction) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"@Override\n\tpublic Task constructInstance(Robot robot) {\n\t\treturn null;\n\t}",
"private ThreadUtil() {\n }",
"private UniqueElementSingleThreadWorker()\n {\n _state = ActivityState.INITIALIZING;\n _taskQueue = new UniqueTagQueue<String, Runnable>();\n \n _taskThread = new Thread(\"UniqueElementSingleThreadWorker-\" + COUNTER.incrementAndGet())\n {\n @Override\n public void run()\n {\n while(true)\n {\n try\n {\n Runnable task = _taskQueue.blockingPop();\n if(task == SHUTDOWN_TASK)\n {\n break;\n }\n task.run();\n }\n catch(InterruptedException ex) { }\n //Catch run time exceptions that the runnable might throw so that the thread does not die\n catch(RuntimeException ex)\n {\n ErrorReporter.reportUncaughtException(ex);\n }\n }\n \n _state = ActivityState.SHUT_DOWN;\n }\n };\n }",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"protected DefaultPromise()\r\n/* 44: */ {\r\n/* 45: 83 */ this.executor = null;\r\n/* 46: */ }",
"public CachingConnectionFactory() {\n\t\tthis((String) null);\n\t}",
"PooledThread()\n {\n setDaemon(true);\n\n start();\n }",
"TaskFactory getTaskFactory();",
"private TestAcceptFactory() {\n this._pool = new DirectExecutor();\n }",
"private void initThread() {\r\n\t\tthreadPreviewDataToImageData = new ThreadPreviewDataToImageData();\r\n\t\t// threadPreviewDataToFakePictureImageData = new\r\n\t\t// ThreadPreviewDataToFakePictureImageData();\r\n\t\t// threadPreviewYUVDecode = new ThreadPreviewYUVDecode();\r\n\r\n\t\tthreadPreviewDataToImageData.start();\r\n\t\t/*\r\n\t\t * if (CameraConfigure.isUseFakeImageData) { //\r\n\t\t * threadPreviewDataToFakePictureImageData.start(); } else {\r\n\t\t * //threadPreviewYUVDecode.start(); }\r\n\t\t */\r\n\r\n\t\t/** preview callback to ThreadPreviewDataToImageData */\r\n\t\tif (null == BlockingQueuePreviewData.getBlockingQueuePreviewData()) {\r\n\t\t\tnew BlockingQueuePreviewData();\r\n\t\t}\r\n\t\t/** ThreadPreviewDataToImageData to ThreadQRcodeDecode */\r\n\t\tif (null == BlockingQueueGrayByteData.getBlockingQueueGrayByteData()) {\r\n\t\t\tnew BlockingQueueGrayByteData();\r\n\t\t}\r\n\t\t/** ThreadPreviewDataToImageData to ThreadBarcodeDecode */\r\n\t\tif (null == BlockingQueueGrayByteDataArray\r\n\t\t\t\t.getBlockingQueueGrayByteDataArray()) {\r\n\t\t\tnew BlockingQueueGrayByteDataArray();\r\n\t\t}\r\n\t\t/** ThreadPreviewDataToImageData to ThreadBCardScanning */\r\n\t\tif (null == BlockingQueueGrayByteDataPreviewData\r\n\t\t\t\t.getBlockingQueueGrayByteDataPreviewData()) {\r\n\t\t\tnew BlockingQueueGrayByteDataPreviewData();\r\n\t\t}\r\n\t\t/*\r\n\t\t * if (null == BlockingQueueByteArray.getBlockingQueueByteArray()) { new\r\n\t\t * BlockingQueueByteArray(); }\r\n\t\t */\r\n\r\n\t\t/*\r\n\t\t * if (null == BlockingQueueFakePictureImageData\r\n\t\t * .getBlockingQueueFakePictureImageData()) { new\r\n\t\t * BlockingQueueFakePictureImageData(); }\r\n\t\t */\r\n\t}",
"public ExecutorService m33643a() {\n return (ExecutorService) C15521i.a(this.f28354a.m25442b(), \"Cannot return null from a non-@Nullable @Provides method\");\n }",
"private CameraExecutors() {\n }",
"ObjectPool() {\n deadTime = DEFAULT_DEADTIME;\n lock = new Hashtable<T, Long>();\n unlock = new Hashtable<T, Long>();\n }",
"@Override\n\t\t\tprotected void beforeExecute(Thread t, Runnable r) {\n\t\t\t\tint qsize = getQueue().size();\n\t\t\t\tif(initCorePoolSize>0&&getCorePoolSize()<getMaximumPoolSize()\n\t\t\t\t\t&& qsize > 0 && (qsize%divisor) == 0){\n\t\t\t\t\tsetCorePoolSize(getCorePoolSize()+1); // 进行动态增加\n\t\t\t\t}\n\t\t\t}",
"public void testCallable2() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable(), one);\n assertSame(one, c.call());\n }",
"public NamedThreadFactory(String name)\n {\n this(name, null);\n }",
"ScheduledExecutorService getExecutorService();",
"@Override\n\t\tpublic ThreadSynchroniser createThreadSynchroniser() {\n\t\t\tthrow new IllegalStateException(\"Mock \" + ThreadSynchroniser.class.getSimpleName() + \" for \"\n\t\t\t\t\t+ SupplierTypeBuilder.class.getSimpleName() + \" can not be used\");\n\t\t}",
"public TaskThread(ThreadPool threadPool) {\n super(threadPool.getThreadGroup(), \"Task: Idle\");\n this.threadPool = threadPool;\n threadId = ThreadPool.getUniqueThreadId();\n System.out.println(\"threadId Created:\" + threadId);\n }",
"@Test\n @DisplayName(\"SingleThread Executor + shutdown\")\n void firstExecutorService() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n executor.submit(this::printThreadName);\n\n shutdownExecutor(executor);\n assertThrows(RejectedExecutionException.class, () -> executor.submit(this::printThreadName));\n }",
"public JobManagerHolder() {\n this.instance = null;\n }",
"public static Executor buildExecutor() {\n GrpcRegisterConfig config = Singleton.INST.get(GrpcRegisterConfig.class);\n if (null == config) {\n return null;\n }\n final String threadpool = Optional.ofNullable(config.getThreadpool()).orElse(Constants.CACHED);\n switch (threadpool) {\n case Constants.SHARED:\n try {\n return SpringBeanUtils.getInstance().getBean(ShenyuThreadPoolExecutor.class);\n } catch (NoSuchBeanDefinitionException t) {\n throw new ShenyuException(\"shared thread pool is not enable, config ${shenyu.sharedPool.enable} in your xml/yml !\", t);\n }\n case Constants.FIXED:\n case Constants.EAGER:\n case Constants.LIMITED:\n throw new UnsupportedOperationException();\n case Constants.CACHED:\n default:\n return null;\n }\n }",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"public ImageLoader(Context context){\n fileCache=new FileCache(context);\n executorService=Executors.newFixedThreadPool(5);\n }",
"public static synchronized HotspotThreadMBean getHotspotThreadMBean()\n/* */ {\n/* 302 */ if (hsThreadMBean == null) {\n/* 303 */ hsThreadMBean = new HotspotThread(jvm);\n/* */ }\n/* 305 */ return hsThreadMBean;\n/* */ }",
"public Callable<?> getInitializationTask()\n {\n return isBuilt() || baseCfs.isEmpty() ? null : getBuildIndexTask();\n }",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"@PreDestroy\r\n\tprivate void deinit() {\n\t if ((threadPool != null) &&\r\n\t (!threadPool.isShutdown())) {\r\n\t \r\n\t threadPool.shutdown();\r\n\t threadPool = null;\r\n }\r\n\t}",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"public void mo4671a() {\n if (this.f3109a == null || this.f3109a.isShutdown()) {\n this.f3109a = new C1122b(new ThreadPoolExecutor(1, 1, 0, TimeUnit.MILLISECONDS, new PriorityBlockingQueue()));\n }\n this.f3114f = true;\n }",
"public static synchronized SimpleTimer getInstance(int threadPoolSize) {\n if (instance == null) {\n instance = new SimpleTimer(threadPoolSize);\n SimpleTimer.instanceThreadPoolSize = threadPoolSize;\n } else {\n if (SimpleTimer.instanceThreadPoolSize != threadPoolSize) {\n log.warn(\"Asked to create SimpleTimer with thread pool size {}, existing instance has {}\",\n threadPoolSize, instanceThreadPoolSize);\n }\n }\n return instance;\n }"
] | [
"0.7106065",
"0.7025443",
"0.6940468",
"0.6734056",
"0.6456616",
"0.6418117",
"0.63256854",
"0.62741643",
"0.6247198",
"0.6205201",
"0.6168833",
"0.6112017",
"0.6106656",
"0.60664827",
"0.6041328",
"0.6019585",
"0.5936152",
"0.5906643",
"0.59020144",
"0.58992034",
"0.58664954",
"0.5862562",
"0.5849971",
"0.58472264",
"0.58430225",
"0.5812086",
"0.58052003",
"0.5801858",
"0.579975",
"0.5786651",
"0.57818115",
"0.5755952",
"0.57557815",
"0.5747692",
"0.5746085",
"0.56964165",
"0.56563056",
"0.564567",
"0.5628386",
"0.5628022",
"0.5623049",
"0.5615775",
"0.55829173",
"0.5580771",
"0.55761623",
"0.5552599",
"0.5466072",
"0.54647917",
"0.54493326",
"0.5427507",
"0.54264957",
"0.54204947",
"0.5403049",
"0.5394646",
"0.5378727",
"0.5377393",
"0.5364056",
"0.5361231",
"0.53600144",
"0.53551626",
"0.53407496",
"0.5329875",
"0.5321544",
"0.5301468",
"0.52941805",
"0.5267913",
"0.52425486",
"0.5234664",
"0.523296",
"0.5219933",
"0.52181095",
"0.5209939",
"0.52081716",
"0.51960653",
"0.5181874",
"0.5161944",
"0.5151883",
"0.51322335",
"0.5129972",
"0.5126568",
"0.512291",
"0.51206666",
"0.5113549",
"0.5112647",
"0.5111564",
"0.51098776",
"0.5107851",
"0.5104935",
"0.5102621",
"0.5079487",
"0.50719434",
"0.50647646",
"0.5062459",
"0.50621635",
"0.50613666",
"0.50549316",
"0.50525475",
"0.5038331",
"0.5028358",
"0.50268006"
] | 0.79828906 | 0 |
A new SingleThreadExecutor can execute runnables | public void testNewSingleThreadExecutor1() {
final ExecutorService e = Executors.newSingleThreadExecutor();
try (PoolCleaner cleaner = cleaner(e)) {
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public interface ThreadExecutor extends Executor {\n}",
"private static void threadPoolWithExecute() {\n\n Executor executor = Executors.newFixedThreadPool(3);\n IntStream.range(1, 10)\n .forEach((i) -> {\n executor.execute(() -> {\n System.out.println(\"started task for id - \"+i);\n try {\n if (i == 8) {\n Thread.sleep(4000);\n } else {\n Thread.sleep(1000);\n }\n System.out.println(\"In runnable task for id -\" + i);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n });\n System.out.println(\"End of method .THis gets printed immdly since execute is not blocking call\");\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public void testCastNewSingleThreadExecutor() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n try {\n ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;\n shouldThrow();\n } catch (ClassCastException success) {}\n }\n }",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"public void testNewSingleThreadExecutor3() {\n try {\n ExecutorService e = Executors.newSingleThreadExecutor(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public interface IHttpThreadExecutor {\n public void addTask(Runnable runnable);\n}",
"@NonNull\n public static Executor directExecutor() {\n return DirectExecutor.getInstance();\n }",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"private synchronized void execute(TestRunnerThread testRunnerThread) {\n boolean hasSpace = false;\n while(!hasSpace) {\n threadLock.lock();\n try {\n hasSpace = currentThreads.size()<capacity;\n }\n finally {\n threadLock.unlock();\n }\n }\n \n //Adding thread to list and executing it\n threadLock.lock();\n try {\n currentThreads.add(testRunnerThread);\n testRunnerThread.setThreadPoolListener(this);\n Thread thread = new Thread(testRunnerThread);\n //System.out.println(\"Starting thread for \"+testRunnerThread.getTestRunner().getTestName());\n thread.start();\n }\n finally {\n threadLock.unlock();\n }\n }",
"public static Executor getInstance() {\n Object object = sDirectExecutor;\n if (object != null) {\n return sDirectExecutor;\n }\n object = DirectExecutor.class;\n synchronized (object) {\n DirectExecutor directExecutor = sDirectExecutor;\n if (directExecutor == null) {\n sDirectExecutor = directExecutor = new DirectExecutor();\n }\n return sDirectExecutor;\n }\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tMyThread myThread=new MyThread();\n\t\t//用Excutors 线程执行器类创建可扩展的线程池\n\t\tExecutorService executor=Executors.newCachedThreadPool();\n\t\t//将实现类对象提交到线程池进行管理\n\t\tFuture<Object> result1=executor.submit(myThread);\n\t\tFuture<Object> result2=executor.submit(myThread);\n\t\texecutor.shutdown();\n\t\tSystem.out.println(result1.get());\n\t\tSystem.out.println(result2.get());\n\t}",
"void setThreadedAsyncMode(boolean useExecutor);",
"public abstract boolean execute(String[] args) throws InterruptedException;",
"private UniqueElementSingleThreadWorker()\n {\n _state = ActivityState.INITIALIZING;\n _taskQueue = new UniqueTagQueue<String, Runnable>();\n \n _taskThread = new Thread(\"UniqueElementSingleThreadWorker-\" + COUNTER.incrementAndGet())\n {\n @Override\n public void run()\n {\n while(true)\n {\n try\n {\n Runnable task = _taskQueue.blockingPop();\n if(task == SHUTDOWN_TASK)\n {\n break;\n }\n task.run();\n }\n catch(InterruptedException ex) { }\n //Catch run time exceptions that the runnable might throw so that the thread does not die\n catch(RuntimeException ex)\n {\n ErrorReporter.reportUncaughtException(ex);\n }\n }\n \n _state = ActivityState.SHUT_DOWN;\n }\n };\n }",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"public SequentialExecutor(Executor executor)\r\n {\r\n myExecutor = Utilities.checkNull(executor, \"executor\");\r\n }",
"public void testOfferInExecutor() {\n final SynchronousQueue q = new SynchronousQueue();\n ExecutorService executor = Executors.newFixedThreadPool(2);\n final Integer one = new Integer(1);\n\n executor.execute(new Runnable() {\n public void run() {\n threadAssertFalse(q.offer(one));\n try {\n threadAssertTrue(q.offer(one, MEDIUM_DELAY_MS, TimeUnit.MILLISECONDS));\n threadAssertEquals(0, q.remainingCapacity());\n }\n catch (InterruptedException e) {\n threadUnexpectedException();\n }\n }\n });\n\n executor.execute(new Runnable() {\n public void run() {\n try {\n Thread.sleep(SMALL_DELAY_MS);\n threadAssertEquals(one, q.take());\n }\n catch (InterruptedException e) {\n threadUnexpectedException();\n }\n }\n });\n\n joinPool(executor);\n\n }",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"public static void main(String[] args) throws Exception, ExecutionException {\n\t\tScheduledExecutorService service=Executors.newSingleThreadScheduledExecutor();\r\n\t\tList<Callable> list=new ArrayList();\r\n\t\tlist.add(new MyCallableBTest());\r\n\t\tlist.add(new MyCallableATest());\r\n\t\tservice.scheduleAtFixedRate(new MyRunnable(),4l,4L,TimeUnit.SECONDS);\r\n\t\t//ScheduledFuture<String> future2=service.schedule(list.get(1),4L,TimeUnit.SECONDS);\r\n\t //System.out.println(future1.get());\r\n\t //System.out.println(future2.get());\r\n\t}",
"@Override\n\tpublic void execute() {\n\t\tThreadPool pool=ThreadPool.getInstance();\n\t\tpool.beginTaskRun(this);\n\t}",
"private ExecutorService getDroneThreads() {\n\t\treturn droneThreads;\n\t}",
"public static void main(String[] args) {\n\t\tExecutorService pool = Executors.newFixedThreadPool(3);\n\t\t//ExecutorService pool = Executors.newSingleThreadExecutor();\n\t\t\n\t\tExecutorService pool2 = Executors.newCachedThreadPool();\n\t\t//this pool2 will add more thread into pool(when no other thread running), the new thread do not need to wait.\n\t\t//pool2 will delete un runing thread(unrun for 60 secs)\n\t\tThread t1 = new MyThread();\n\t\tThread t2 = new MyThread();\n\t\tThread t3 = new MyThread();\n\n\t\tpool.execute(t1);\n\t\tpool.execute(t2);\n\t\tpool.execute(t3);\n\t\tpool.shutdown();\n\t\t\n\t}",
"public void runInExecutor() {\n this.executor.execute(this.callback);\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"private static void multiThreading(){\n\t\tSystem.out.println(\"\\nCreating new two separate instances of Singleton using Multi threading\");\n\t\tExecutorService service = Executors.newFixedThreadPool(2);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.shutdown();\n\t}",
"private CameraExecutors() {\n }",
"public boolean hasExecutor() {\n return result.hasExecutor();\n }",
"@Test\n @DisplayName(\"Invoke Any\")\n void invokeAny() throws ExecutionException, InterruptedException {\n ExecutorService executor = Executors.newWorkStealingPool();\n\n List<Callable<String>> callables = Arrays.asList(\n callable(\"task1\", 2),\n callable(\"task2\", 1),\n callable(\"task3\", 3));\n\n String result = executor.invokeAny(callables);\n assertEquals(\"task2\", result);\n }",
"@Test\n @DisplayName(\"SingleThread Executor + shutdown\")\n void firstExecutorService() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n executor.submit(this::printThreadName);\n\n shutdownExecutor(executor);\n assertThrows(RejectedExecutionException.class, () -> executor.submit(this::printThreadName));\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n for (int i = 0; i < 10; i++) {\n \tCallable worker = new WorkerThread1(\"\" + i);\n \tFuture future = executor.submit(worker);\n \tSystem.out.println(\"Results\"+future.get());\n //executor.execute(worker);\n }\n executor.shutdown();\n while (!executor.isTerminated()) {\n }\n System.out.println(\"Finished all threads\");\n }",
"public interface ThreadApi {\n Future executeInBackground(Runnable task);\n boolean executeInMainThread(Runnable task);\n boolean executeInMainThread(Runnable task, long delay);\n}",
"void runInAudioThread(Runnable runnable) {\n executor.execute(runnable);\n }",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"protected void executeThread() {\n if (thread == null || !thread.isAlive()) {\n thread = new Thread(() -> {\n while (!queries.isEmpty() && !disconnect) {\n queries.remove().execute(queryRunner, connection);\n }\n if (disconnect) {\n disconnect();\n }\n });\n thread.start();\n }\n }",
"public static void main(String[] args) {\n ExecutorService es = Executors.newCachedThreadPool();\n es.execute(new Task(65));\n es.execute(new Task(5));\n System.out.println(\"结束执行!\");\n }",
"public abstract ScheduledExecutorService getWorkExecutor();",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tExecutorService executor = Executors.newFixedThreadPool(THREAD_POOL_SIZE);\n\n\t\tCallableInterfaceDemo counter = new CallableInterfaceDemo();\n\n\t\tFuture<String> future1 = executor.submit(counter); // Producer\n\t\tFuture<String> future2 = executor.submit(counter); // Producer\n\n\t\tSystem.out.println(Thread.currentThread().getName() + \" executing ...\");\n\n\t\t// asynchronously get from the worker threads\n\t\tSystem.out.println(future1.get());\n\t\tSystem.out.println(future2.get());\n\n\t}",
"@SuppressWarnings({\"unused\", \"unchecked\"})\n public void execute(Executor executor, IN... ins) {\n asyncTask.executeOnExecutor(executor, ins);\n }",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"public interface IExecutor {\n void execute(Runnable runnable);\n void shutdown();\n void shutdownNow();\n}",
"@Test\n public void testSingleton() throws InterruptedException{\n Singleton[] results = new Singleton[threadNumber];\n\n for(int i=0; i<threadNumber; i++) {\n final int finalI = i;\n executor.execute(() -> {\n try {\n long threadId = Thread.currentThread().getId();\n logger.info(\"[Thread-\" + threadId + \"] is running\");\n results[finalI] = Singleton.getInstance();\n logger.info(\"[Thread-\" + threadId + \"] is finished\");\n }\n catch (Throwable t) {\n logger.error(t, t.getCause());\n }\n });\n }\n executor.shutdown();\n executor.awaitTermination(10, TimeUnit.SECONDS);\n\n long count = Arrays.stream(results).distinct().count();\n assertEquals(\"Instance number supposed to be only one, but you got \" + count, expectInstances, count);\n }",
"private static void threadPoolWithSubmit() throws InterruptedException, ExecutionException {\n Executor executor = Executors.newFixedThreadPool(1);\n Callable<String> callable=()->{\n try{\n Thread.sleep(4000);\n System.out.println(\"In callable\");\n Thread.sleep(4000);\n System.out.println(\"In runnable for task id 1\");\n }catch(Exception e){\n e.printStackTrace();\n }\n return \"success\";\n };\n Future<String> future =((ExecutorService) executor).submit(callable);\n System.out.println(\"Future result - \"+future.get()+\" Future is blocking as it blocks until result is obtained\");\n System.out.println(\"End of method \");\n ((ExecutorService) executor).shutdown();\n /*Output\n In callable\n In runnable for task id 1\n Future result - success Future is blocking as it blocks until result is obtained\n End of method\n */\n }",
"public static void main(String[] args) {\r\n\t\tMyThread thread = new MyThread();\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t}",
"public static void main(String[] args) {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(2, 2, 0, TimeUnit.NANOSECONDS, new ArrayBlockingQueue<>(10));\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"all task over!\");\n threadPoolExecutor.shutdown();\n }",
"public interface Executor<Work extends Runnable> {\n void execute(Work work);\n\n void shutdown();\n\n void addWorks(Work work);\n\n void removeWorks(int num);\n\n int getWorkSize();\n}",
"private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public static void main(String args[]) throws Exception\n {\n ImplementsRunnable rc = new ImplementsRunnable();\n Thread t1 = new Thread(rc);\n t1.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t2 = new Thread(rc);\n t2.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t3 = new Thread(rc);\n t3.start();\n \n // Modification done here. Only one object is shered by multiple threads\n // here also.\n ExtendsThread extendsThread = new ExtendsThread();\n Thread thread11 = new Thread(extendsThread);\n thread11.start();\n Thread.sleep(1000);\n Thread thread12 = new Thread(extendsThread);\n thread12.start();\n Thread.sleep(1000);\n Thread thread13 = new Thread(extendsThread);\n thread13.start();\n Thread.sleep(1000);\n }",
"public static void main(String[] args) throws InterruptedException {\n\t\tObservable.just(\"hi\",\"hello\",\"okay\").subscribe(z -> System.out.print(z));\n\t\t\n\t\t// creating observable using create in lambda style[Sync]\n\t\tObservable.create( f ->{\n\t\t\t\t\t\t\tf.onNext(\"hello\");\n\t\t\t\t\t\t\tif( f.isUnsubscribed() ){\n\t\t\t\t\t\t\t\treturn; \n\t\t\t\t\t\t\t}}).subscribe( s -> System.out.println(s));\n\t\t\n\t\t\n\t\tExecutorService executor = Executors.newSingleThreadExecutor();\n\t\tSystem.out.println(\"----\"+Thread.currentThread().getName());\n\t\t\n\t\t// creating observable using create in lambda style[Async]\n\t\tObservable.create(f -> {executor.submit(() ->{\n\t\t\t f.onNext(Thread.currentThread().getName());\n\t \t});}).subscribe(s -> {System.out.println(Thread.currentThread().getName()); \n\t \t\t\t\t\t\t\tSystem.out.println(s);} );\n\t\t\n\t\t// creating observable using create in lambda style[Async + observerOn]\n\t\tObservable.create(f -> {executor.submit(() ->{\n\t\t\t f.onNext(Thread.currentThread().getName());\n\t \t});}).observeOn(Schedulers.newThread()).subscribe(s -> {System.out.println(Thread.currentThread().getName()); \n\t \t\t\t\t\t\t\tSystem.out.println(s);} );\n\n\t\t\n\t\t// creating observable using create in lambda style[Async + subscribeOn]\n\t\tObservable.create(f -> {executor.submit(() ->{\n\t\t\t f.onNext(Thread.currentThread().getName());\n\t \t});}).subscribeOn(Schedulers.newThread()).subscribe(s -> {System.out.println(Thread.currentThread().getName()); \n\t \t\t\t\t\t\t\tSystem.out.println(s);} );\n\n\t\t\n\t\tList<Integer> result = new ArrayList<Integer>();\n\t\t//bulk API simulation\n\t\tObservable<Integer> obs = Observable.just(1,2,3,4,5,6).map(userId ->{\n\t\t\t//make mysql call\n\t\t try { System.out.println(\"---\"+Thread.currentThread().getName());\n\t\t\treturn makeSqlCall(userId);\n\t\t\t\n\t\t} catch (InterruptedException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn 0;\n\t\t});\n\t\t\t\t\n\t obs.subscribeOn(Schedulers.io()).subscribe(id ->{ result.add(id);System.out.println(Thread.currentThread().getName());});\n\t for(Integer x: result){System.out.print(x+\" - \");}\n\t\t\n\t}",
"private void YeWuMethod(String name) {\n\n for (int j = 0; j < 10; j++) {\n\n\n// Runnable task = new RunnableTask();\n// Runnable ttlRunnable = TtlRunnable.get(task);\n\n// executor.execute(ttlRunnable);\n\n executor.execute(() -> {\n System.out.println(\"==========\"+name+\"===\"+threadLocal.get());\n });\n }\n\n// for (int i = 0; i < 10; i++) {\n// new Thread(() -> {\n// System.out.println(name+\"===\"+threadLocal.get());\n// }, \"input thread name\").start();\n// }\n\n\n\n\n }",
"public static void main(String[] args) {\n Runnable r1 = () -> {\n String thread = Thread.currentThread().getName();\n log.info(\"{} getting lock\", thread);\n lock.lock();\n log.info(\"{}, increment to {}\", thread, count++);\n log.info(\"{} unlock\", thread);\n lock.unlock();\n\n };\n\n for (int i=0; i <= 5; i++){\n executorService.execute(r1);\n }\n\n executorService.shutdown();\n\n }",
"protected EventExecutor executor()\r\n/* 49: */ {\r\n/* 50: 87 */ return this.executor;\r\n/* 51: */ }",
"@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\r\n\tpublic static void main(String[] args) throws InterruptedException, ExecutionException{\n\t\tExecutorService e = Executors.newFixedThreadPool(2);\r\n//\t\tList<Future> list = new ArrayList<Future>();\r\n\t\tfor(int i=0;i<10;i++){\r\n\t\t\tCallable c = new JavaTestThread(i);\r\n\t\t\tFuture f = e.submit(c);\r\n\t\t\tSystem.out.println(\"-------\"+ f.get().toString());\r\n\t\t}\r\n\t\t\r\n\t\r\n\t\t\r\n\t}",
"public static void main(String args[]) {\n\t\t (new Thread(new Threads_and_Executors())).start();\r\n}",
"@Override\n\tpublic boolean allowMultithreading()\n\t{\n\t\treturn true;\n\t}",
"ScheduledExecutorService getExecutorService();",
"public void execute(Runnable runnable) {\n executorService.execute(runnable);\n }",
"public void runInThread() {\n\t\tTaskRunner taskRunner = Dep.get(TaskRunner.class);\n\t\tATask atask = new ATask<Object>(getClass().getSimpleName()) {\n\t\t\t@Override\n\t\t\tprotected Object run() throws Exception {\n\t\t\t\tBuildTask.this.run();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\t\n\t\t};\n\t\ttaskRunner.submitIfAbsent(atask);\n\t}",
"public void execute() throws InterruptedException;",
"@Test\n public void multithreaded() throws Exception {\n Session session = mock(Session.class);\n DeduplicatingExecutor executor =\n new DeduplicatingExecutor(session, TimeUnit.SECONDS.toMillis(1L));\n BoundStatement statement = mock(BoundStatement.class);\n when(session.executeAsync(statement))\n .thenAnswer(invocationOnMock -> mock(ResultSetFuture.class));\n\n int loopCount = 1000;\n CountDownLatch latch = new CountDownLatch(loopCount);\n ExecutorService exec = Executors.newFixedThreadPool(10);\n\n Collection<ListenableFuture<?>> futures = new ConcurrentLinkedDeque<>();\n for (int i = 0; i < loopCount; i++) {\n exec.execute(() -> {\n futures.add(executor.maybeExecuteAsync(statement, \"foo\"));\n futures.add(executor.maybeExecuteAsync(statement, \"bar\"));\n latch.countDown();\n });\n }\n latch.await();\n\n ImmutableSet<ListenableFuture<?>> distinctFutures = ImmutableSet.copyOf(futures);\n\n assertThat(distinctFutures).hasSize(2);\n\n // expire the result\n Thread.sleep(1000L);\n\n // Sanity check: we don't memoize after we should have expired.\n assertThat(executor.maybeExecuteAsync(statement, \"foo\"))\n .isNotIn(distinctFutures);\n assertThat(executor.maybeExecuteAsync(statement, \"bar\"))\n .isNotIn(distinctFutures);\n }",
"@Test\n @ConditionalIgnoreRule.ConditionalIgnore(condition = RunningOnGithubAction.class)\n public void testSuccess() throws Exception {\n int concurrency = 10;\n ExecutorService executorService = Executors.newFixedThreadPool(10);\n List<Future<?>> futures = new ArrayList<>();\n // create 10 threads, each open a connection and submit a query\n // after sleeping 15 seconds\n for (int idx = 0; idx < concurrency; idx++) {\n logger.fine(\"open a new connection and submit query \" + idx);\n final int queryIdx = idx;\n futures.add(\n executorService.submit(\n () -> {\n try {\n submitQuery(true, queryIdx);\n } catch (SQLException | InterruptedException e) {\n throw new IllegalStateException(\"task interrupted\", e);\n }\n }));\n }\n executorService.shutdown();\n for (int idx = 0; idx < concurrency; idx++) futures.get(idx).get();\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testDefaultsToMainThread() throws Exception {\n\n Executor executor = new LooperExecutor();\n final CountDownLatch latch = new CountDownLatch(1);\n executor.execute(new Runnable() {\n @Override\n public void run() {\n assertEquals(\"running on ui thread\", Looper.getMainLooper(), Looper.myLooper());\n latch.countDown();\n }\n });\n latch.await();\n }",
"public static GlideExecutor m21519e() {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(0, Integer.MAX_VALUE, f23336b, TimeUnit.MILLISECONDS, new SynchronousQueue(), new C8962a(\"source-unlimited\", UncaughtThrowableStrategy.f23340b, false));\n return new GlideExecutor(threadPoolExecutor);\n }",
"@Override\n protected void beforeExecute(final Thread thread, final Runnable run) {\n mActiveTasks.add(run);\n super.beforeExecute(thread, run);\n }",
"public void testPollInExecutor() {\n final SynchronousQueue q = new SynchronousQueue();\n ExecutorService executor = Executors.newFixedThreadPool(2);\n executor.execute(new Runnable() {\n public void run() {\n threadAssertNull(q.poll());\n try {\n threadAssertTrue(null != q.poll(MEDIUM_DELAY_MS, TimeUnit.MILLISECONDS));\n threadAssertTrue(q.isEmpty());\n }\n catch (InterruptedException e) {\n threadUnexpectedException();\n }\n }\n });\n\n executor.execute(new Runnable() {\n public void run() {\n try {\n Thread.sleep(SMALL_DELAY_MS);\n q.put(new Integer(1));\n }\n catch (InterruptedException e) {\n threadUnexpectedException();\n }\n }\n });\n\n joinPool(executor);\n }",
"ActorThreadPool getThreadPool();",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"public void testExecuteInParallel_Collection_ThreadPoolExecutor() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks, ParallelUtil.createThreadPool( 1 ) );\n assertEquals( result.size(), tasks.size() );\n }",
"public static void main(String[] args) {\n SomeRunnable obj1 = new SomeRunnable();\n SomeRunnable obj2 = new SomeRunnable();\n SomeRunnable obj3 = new SomeRunnable();\n \n System.out.println(\"obj1 = \"+obj1);\n System.out.println(\"obj2 = \"+obj2);\n System.out.println(\"obj3 = \"+obj3);\n \n //Create fixed Thread pool, here pool of 2 thread will created\n ExecutorService pool = Executors.newFixedThreadPool(3);\n ExecutorService pool2 = Executors.newFixedThreadPool(2);\n pool.execute(obj1);\n pool.execute(obj2);\n pool2.execute(obj3);\n \n pool.shutdown();\n pool2.shutdown();\n }",
"public static void main(String[] args) throws InterruptedException,\n ExecutionException {\n ExecutorService executor = Executors\n .newFixedThreadPool(THREAD_POOL_SIZE);\n\n Future future1 = executor.submit(new Counter());\n Future future2 = executor.submit(new Counter());\n\n System.out.println(Thread.currentThread().getName() + \" executing ...\");\n\n //asynchronously get from the worker threads\n System.out.println(future1.get());\n System.out.println(future2.get());\n\n }",
"public abstract T executor(@Nullable Executor executor);",
"public static Executor buildExecutor() {\n GrpcRegisterConfig config = Singleton.INST.get(GrpcRegisterConfig.class);\n if (null == config) {\n return null;\n }\n final String threadpool = Optional.ofNullable(config.getThreadpool()).orElse(Constants.CACHED);\n switch (threadpool) {\n case Constants.SHARED:\n try {\n return SpringBeanUtils.getInstance().getBean(ShenyuThreadPoolExecutor.class);\n } catch (NoSuchBeanDefinitionException t) {\n throw new ShenyuException(\"shared thread pool is not enable, config ${shenyu.sharedPool.enable} in your xml/yml !\", t);\n }\n case Constants.FIXED:\n case Constants.EAGER:\n case Constants.LIMITED:\n throw new UnsupportedOperationException();\n case Constants.CACHED:\n default:\n return null;\n }\n }",
"public interface Executor<E>{\n\t\tvoid execute(E object);\n\t}",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"public void run(){\n //logic to execute in a thread \n }",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public interface Executor {\n void setTask(Task task);\n Task getTask();\n void startTask();\n}",
"public static Executor m13822l() {\n synchronized (f12483o) {\n if (f12471c == null) {\n f12471c = AsyncTask.THREAD_POOL_EXECUTOR;\n }\n }\n return f12471c;\n }",
"@Test(timeout = 10000)\n public void testMultipleCallsReturnTheSameObjectInDifferentThreads() throws Exception {\n\n // Create 10000 tasks and inside each callable instantiate the singleton class\n final List<Callable<S>> tasks = new ArrayList<>();\n for (int i = 0; i < 10000; i++) {\n tasks.add(this.singletonInstanceMethod::get);\n }\n\n // Use up to 8 concurrent threads to handle the tasks\n final ExecutorService executorService = Executors.newFixedThreadPool(8);\n final List<Future<S>> results = executorService.invokeAll(tasks);\n\n // wait for all of the threads to complete\n final S expectedInstance = this.singletonInstanceMethod.get();\n for (Future<S> res : results) {\n final S instance = res.get();\n assertNotNull(instance);\n assertSame(expectedInstance, instance);\n }\n\n // tidy up the executor\n executorService.shutdown();\n\n }",
"public interface Executor<T> {\n\n void submit(T arg);\n\n}",
"public static void testES() {\n ExecutorService es = Executors.newFixedThreadPool(2);\n for (int i = 0; i < 10; i++)\n es.execute(new TestTask());\n }",
"private static Future<?> directExecute(Runnable runnable, long delay) {\n Future<?> future = null;\n if (delay > 0) {\n /* no serial, but a delay: schedule the task */\n if (!(executor instanceof ScheduledExecutorService)) {\n throw new IllegalArgumentException(\"The executor set does not support scheduling\");\n }\n ScheduledExecutorService scheduledExecutorService = (ScheduledExecutorService) executor;\n future = scheduledExecutorService.schedule(runnable, delay, TimeUnit.MILLISECONDS);\n } else {\n if (executor instanceof ExecutorService) {\n ExecutorService executorService = (ExecutorService) executor;\n future = executorService.submit(runnable);\n } else {\n /* non-cancellable task */\n executor.execute(runnable);\n }\n }\n return future;\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executorService = new ThreadPoolExecutor(3, 10, 1L, TimeUnit.SECONDS,\n new LinkedBlockingQueue<>(20),\n Executors.defaultThreadFactory(),\n new ThreadPoolExecutor.AbortPolicy());\n ABC abc = new ABC();\n try {\n for (int i = 1; i <= 10; i++) {\n executorService.execute(abc::print5);\n executorService.execute(abc::print10);\n executorService.execute(abc::print15);\n }\n\n }finally {\n executorService.shutdown();\n }\n }",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"protected EventExecutor executor()\r\n/* 27: */ {\r\n/* 28: 58 */ EventExecutor e = super.executor();\r\n/* 29: 59 */ if (e == null) {\r\n/* 30: 60 */ return channel().eventLoop();\r\n/* 31: */ }\r\n/* 32: 62 */ return e;\r\n/* 33: */ }",
"public interface RegistryExecutor extends Executor {\n ExecutionContext getExecutionContext();\n\n void setRunner(RegistryDelegate<? extends RegistryTask> delegate);\n\n void start();\n\n void stop();\n}",
"public void execute() {\n ExecutionList executionList = this;\n // MONITORENTER : executionList\n if (this.executed) {\n // MONITOREXIT : executionList\n return;\n }\n this.executed = true;\n RunnableExecutorPair list = this.runnables;\n this.runnables = null;\n // MONITOREXIT : executionList\n RunnableExecutorPair reversedList = null;\n do {\n if (list == null) {\n while (reversedList != null) {\n ExecutionList.executeListener((Runnable)reversedList.runnable, (Executor)reversedList.executor);\n reversedList = reversedList.next;\n }\n return;\n }\n RunnableExecutorPair tmp = list;\n list = list.next;\n tmp.next = reversedList;\n reversedList = tmp;\n } while (true);\n }",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static void main(String[] args) {\n ExecutorService threadPool = Executors.newCachedThreadPool();\n\n try{\n for (int i = 0; i < 10; i++) {\n threadPool.execute(() ->{\n System.out.println(Thread.currentThread().getName()+\"\\t 办理业务\");\n });\n //try {TimeUnit.SECONDS.sleep(1); } catch (InterruptedException e) {e.printStackTrace();}\n }\n\n } catch (Exception e) {\n e.printStackTrace();\n }finally {\n threadPool.shutdown();\n }\n\n\n\n }",
"public Move startThreads() throws Exception {\n ThreadPoolExecutor executor = (ThreadPoolExecutor) Executors.newFixedThreadPool(4);\n ArrayList<Thread> threadBots = new ArrayList<>();\n\n for (Move move : moves) {\n board.doMove(move);\n Thread threadBot = new Thread(new Runnable() {\n @Override\n public void run() {\n return;\n }\n });\n board.undoMove();\n threadBots.add(threadBot);\n executor.execute(threadBot);\n }\n executor.shutdown();\n executor.awaitTermination(Long.MAX_VALUE, TimeUnit.NANOSECONDS);\n\n //int return_index = maxMinIndex(threadBots, board.getSideToMove());\n if (executor.isTerminated()) {\n for (int i = 0; i < moves.size(); i++) {\n //evaluations.add(threadBots.get(i).return_value);\n }\n }\n\n double ret;\n if (board.getSideToMove() == Side.BLACK) {\n ret = Collections.min(evaluations); // min/max -> bot is black/white\n } else {\n ret = Collections.max(evaluations);\n }\n //System.out.println(ret);\n\n //System.out.println(threadBots.get(return_index).return_value);\n //double after = System.currentTimeMillis();\n //double durationMS = (after - before);\n //System.out.println(\"Time: \" + durationMS + \" ms\");\n //System.out.println(\"Bots possible moves: \" + moves);\n //return moves.get(return_index);\n\n //System.out.println(evaluations);\n //System.out.println(moves.get(evaluations.indexOf(ret)));\n return (moves.get(evaluations.indexOf(ret)));\n }",
"@Override\n public void run() {\n mRunnable.onPreExecute();\n mExecutor.onPreExecuteCallback(mRunnable);\n }"
] | [
"0.7046557",
"0.6530956",
"0.65187436",
"0.6336594",
"0.63001096",
"0.6285842",
"0.62422657",
"0.61904365",
"0.61297035",
"0.6085775",
"0.6067942",
"0.6058564",
"0.6016937",
"0.5942038",
"0.5909074",
"0.5888382",
"0.5877324",
"0.58646846",
"0.58632606",
"0.5859741",
"0.5856516",
"0.58500636",
"0.58424085",
"0.58393",
"0.58291805",
"0.57891595",
"0.5780356",
"0.5767772",
"0.5733105",
"0.57284904",
"0.5711056",
"0.5694417",
"0.56933147",
"0.5690626",
"0.5690463",
"0.5687925",
"0.5686717",
"0.5683092",
"0.56701595",
"0.5669975",
"0.5668771",
"0.56621045",
"0.5653261",
"0.56532395",
"0.5646746",
"0.5645937",
"0.5642024",
"0.5640729",
"0.5635712",
"0.5627593",
"0.5615597",
"0.56113166",
"0.55969197",
"0.55963176",
"0.55959314",
"0.5594311",
"0.5594056",
"0.55862415",
"0.55856425",
"0.5584378",
"0.5582936",
"0.55801344",
"0.5574459",
"0.5563783",
"0.55603844",
"0.55578595",
"0.55577016",
"0.5553148",
"0.5542542",
"0.5539545",
"0.5537387",
"0.55348796",
"0.5530118",
"0.55242306",
"0.5521736",
"0.55197936",
"0.5519142",
"0.55170155",
"0.5513988",
"0.5512871",
"0.55028063",
"0.5494896",
"0.5489829",
"0.5466668",
"0.5460398",
"0.5458811",
"0.54472595",
"0.5441719",
"0.5430595",
"0.5418733",
"0.54153043",
"0.54139644",
"0.5409784",
"0.54061395",
"0.5404822",
"0.54031223",
"0.54004276",
"0.5390665",
"0.5389571",
"0.5366193"
] | 0.70716035 | 0 |
A new SingleThreadExecutor with given ThreadFactory can execute runnables | public void testNewSingleThreadExecutor2() {
final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());
try (PoolCleaner cleaner = cleaner(e)) {
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public interface ThreadExecutor extends Executor {\n}",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"public void testCastNewSingleThreadExecutor() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n try {\n ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;\n shouldThrow();\n } catch (ClassCastException success) {}\n }\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public Builder setThreadFactory(ThreadFactory threadFactory) {\n threadFactory_ = (threadFactory != null) ? threadFactory : Executors.defaultThreadFactory();\n return this;\n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"protected EventExecutor newChild(ThreadFactory threadFactory, Object... args) throws Exception {\n/* 57 */ return (EventExecutor)new LocalEventLoop(this, threadFactory);\n/* */ }",
"public void testPrivilegedThreadFactory() throws Exception {\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final ClassLoader thisccl = Thread.currentThread().getContextClassLoader();\n // android-note: Removed unsupported access controller check.\n // final AccessControlContext thisacc = AccessController.getContext();\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n assertSame(thisccl, current.getContextClassLoader());\n //assertEquals(thisacc, AccessController.getContext());\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.privilegedThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }};\n\n runWithPermissions(r,\n new RuntimePermission(\"getClassLoader\"),\n new RuntimePermission(\"setContextClassLoader\"),\n new RuntimePermission(\"modifyThread\"));\n }",
"public void testNewSingleThreadExecutor3() {\n try {\n ExecutorService e = Executors.newSingleThreadExecutor(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public interface RunnableFactory {\n\n\t/**\n\t * Yields a new instance of the runnable.\n\t */\n\n Runnable mk();\n}",
"public interface IHttpThreadExecutor {\n public void addTask(Runnable runnable);\n}",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"@Override\n protected Thread createThread(final Runnable runnable, final String name) {\n return new Thread(runnable, Thread.currentThread().getName() + \"-exec\");\n }",
"@Override\r\n public Thread newThread(Runnable r) {\n Thread t = new Thread(r, \"example-runner\");\r\n t.setDaemon(true);\r\n return t;\r\n }",
"private static void threadPoolWithExecute() {\n\n Executor executor = Executors.newFixedThreadPool(3);\n IntStream.range(1, 10)\n .forEach((i) -> {\n executor.execute(() -> {\n System.out.println(\"started task for id - \"+i);\n try {\n if (i == 8) {\n Thread.sleep(4000);\n } else {\n Thread.sleep(1000);\n }\n System.out.println(\"In runnable task for id -\" + i);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n });\n System.out.println(\"End of method .THis gets printed immdly since execute is not blocking call\");\n }",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public WildflyHystrixConcurrencyStrategy(final ManagedThreadFactory threadFactory) {\n\t\t//\n\t\t// Used by CDI provider.\n\t\t\n\t\tthis.threadFactory = threadFactory;\n\t}",
"public ThreadFactory threadFactory() {\n return threadFactory_;\n }",
"public static void main(String[] args) {\n\t\tExecutorService pool = Executors.newFixedThreadPool(3);\n\t\t//ExecutorService pool = Executors.newSingleThreadExecutor();\n\t\t\n\t\tExecutorService pool2 = Executors.newCachedThreadPool();\n\t\t//this pool2 will add more thread into pool(when no other thread running), the new thread do not need to wait.\n\t\t//pool2 will delete un runing thread(unrun for 60 secs)\n\t\tThread t1 = new MyThread();\n\t\tThread t2 = new MyThread();\n\t\tThread t3 = new MyThread();\n\n\t\tpool.execute(t1);\n\t\tpool.execute(t2);\n\t\tpool.execute(t3);\n\t\tpool.shutdown();\n\t\t\n\t}",
"@Test\n @DisplayName(\"SingleThread Executor + shutdown\")\n void firstExecutorService() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n executor.submit(this::printThreadName);\n\n shutdownExecutor(executor);\n assertThrows(RejectedExecutionException.class, () -> executor.submit(this::printThreadName));\n }",
"private static void createThreadUsingLambdaExpressions() {\n\t\tRunnable r = () -> {System.out.println(\"Lambda Expression thread is executed.\");};\n\t\tThread t = new Thread(r);\n\t\tt.start();\n\t}",
"private synchronized void execute(TestRunnerThread testRunnerThread) {\n boolean hasSpace = false;\n while(!hasSpace) {\n threadLock.lock();\n try {\n hasSpace = currentThreads.size()<capacity;\n }\n finally {\n threadLock.unlock();\n }\n }\n \n //Adding thread to list and executing it\n threadLock.lock();\n try {\n currentThreads.add(testRunnerThread);\n testRunnerThread.setThreadPoolListener(this);\n Thread thread = new Thread(testRunnerThread);\n //System.out.println(\"Starting thread for \"+testRunnerThread.getTestRunner().getTestName());\n thread.start();\n }\n finally {\n threadLock.unlock();\n }\n }",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"public static void main(String[] args) {\n SomeRunnable obj1 = new SomeRunnable();\n SomeRunnable obj2 = new SomeRunnable();\n SomeRunnable obj3 = new SomeRunnable();\n \n System.out.println(\"obj1 = \"+obj1);\n System.out.println(\"obj2 = \"+obj2);\n System.out.println(\"obj3 = \"+obj3);\n \n //Create fixed Thread pool, here pool of 2 thread will created\n ExecutorService pool = Executors.newFixedThreadPool(3);\n ExecutorService pool2 = Executors.newFixedThreadPool(2);\n pool.execute(obj1);\n pool.execute(obj2);\n pool2.execute(obj3);\n \n pool.shutdown();\n pool2.shutdown();\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public static void main(String[] args) {\r\n\t\tMyThread thread = new MyThread();\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t}",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@NonNull\n public static Executor directExecutor() {\n return DirectExecutor.getInstance();\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"private ExecutorService getDroneThreads() {\n\t\treturn droneThreads;\n\t}",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"private static void multiThreading(){\n\t\tSystem.out.println(\"\\nCreating new two separate instances of Singleton using Multi threading\");\n\t\tExecutorService service = Executors.newFixedThreadPool(2);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.shutdown();\n\t}",
"public static Executor buildExecutor() {\n GrpcRegisterConfig config = Singleton.INST.get(GrpcRegisterConfig.class);\n if (null == config) {\n return null;\n }\n final String threadpool = Optional.ofNullable(config.getThreadpool()).orElse(Constants.CACHED);\n switch (threadpool) {\n case Constants.SHARED:\n try {\n return SpringBeanUtils.getInstance().getBean(ShenyuThreadPoolExecutor.class);\n } catch (NoSuchBeanDefinitionException t) {\n throw new ShenyuException(\"shared thread pool is not enable, config ${shenyu.sharedPool.enable} in your xml/yml !\", t);\n }\n case Constants.FIXED:\n case Constants.EAGER:\n case Constants.LIMITED:\n throw new UnsupportedOperationException();\n case Constants.CACHED:\n default:\n return null;\n }\n }",
"public static void main(String args[]) throws Exception\n {\n ImplementsRunnable rc = new ImplementsRunnable();\n Thread t1 = new Thread(rc);\n t1.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t2 = new Thread(rc);\n t2.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t3 = new Thread(rc);\n t3.start();\n \n // Modification done here. Only one object is shered by multiple threads\n // here also.\n ExtendsThread extendsThread = new ExtendsThread();\n Thread thread11 = new Thread(extendsThread);\n thread11.start();\n Thread.sleep(1000);\n Thread thread12 = new Thread(extendsThread);\n thread12.start();\n Thread.sleep(1000);\n Thread thread13 = new Thread(extendsThread);\n thread13.start();\n Thread.sleep(1000);\n }",
"@Override\n\tpublic Thread newThread(Runnable r) {\n\t\t\n\t\tThread th = new Thread(r,\" custum Thread\");\n\t\treturn th;\n\t}",
"public static void main(String[] args) throws Exception, ExecutionException {\n\t\tScheduledExecutorService service=Executors.newSingleThreadScheduledExecutor();\r\n\t\tList<Callable> list=new ArrayList();\r\n\t\tlist.add(new MyCallableBTest());\r\n\t\tlist.add(new MyCallableATest());\r\n\t\tservice.scheduleAtFixedRate(new MyRunnable(),4l,4L,TimeUnit.SECONDS);\r\n\t\t//ScheduledFuture<String> future2=service.schedule(list.get(1),4L,TimeUnit.SECONDS);\r\n\t //System.out.println(future1.get());\r\n\t //System.out.println(future2.get());\r\n\t}",
"public static void main(String[] args) throws Exception {\n\t\tThread t1 = new Thread(\"t1\") {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\tlog.debug(\"this is t1\");\n\t\t\t}\n\t\t};\n\t\tt1.start();\n\t\t\n\t\t\n\t\t//create by runnable\n\t\tThread t2 = new Thread(()->log.debug(\"this is t2\"),\"t2\");\n\t\tt2.start();\n\t\t\n\t\t//create by futuretask, futureTask is created by callable\n\t\tFutureTask<Integer> futureTask = new FutureTask<>(() -> {\n\t\t\tlog.debug(\"this is t3\");\n\t\t\treturn 100;\n\t\t});\n\t\tnew Thread(futureTask,\"t3\").start();\n\t\tlog.debug(\"{}\",futureTask.get());\n\t\t\n\t\tRunnable t4 = ()->{log.debug(\"test\");};\n\t\tt4.run();\n\t\t\n\n\t}",
"protected EventExecutorFactory getExecutorFactory() {\n\t\treturn executorFactory;\n\t}",
"@Test\n @DisplayName(\"Invoke Any\")\n void invokeAny() throws ExecutionException, InterruptedException {\n ExecutorService executor = Executors.newWorkStealingPool();\n\n List<Callable<String>> callables = Arrays.asList(\n callable(\"task1\", 2),\n callable(\"task2\", 1),\n callable(\"task3\", 3));\n\n String result = executor.invokeAny(callables);\n assertEquals(\"task2\", result);\n }",
"@Bean(destroyMethod = \"shutdown\")\n public Executor threadPoolTaskExecutor(@Value(\"${thread.size}\") String argThreadSize) {\n this.threadSize = Integer.parseInt(argThreadSize);\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(this.threadSize);\n executor.setKeepAliveSeconds(15);\n executor.initialize();\n return executor;\n }",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"public static ScheduledExecutorService createNewScheduler() {\n return Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessors() * 2);\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executorService = new ThreadPoolExecutor(3, 10, 1L, TimeUnit.SECONDS,\n new LinkedBlockingQueue<>(20),\n Executors.defaultThreadFactory(),\n new ThreadPoolExecutor.AbortPolicy());\n ABC abc = new ABC();\n try {\n for (int i = 1; i <= 10; i++) {\n executorService.execute(abc::print5);\n executorService.execute(abc::print10);\n executorService.execute(abc::print15);\n }\n\n }finally {\n executorService.shutdown();\n }\n }",
"public static void main(String[] args) {\n Runnable r1 = () -> {\n String thread = Thread.currentThread().getName();\n log.info(\"{} getting lock\", thread);\n lock.lock();\n log.info(\"{}, increment to {}\", thread, count++);\n log.info(\"{} unlock\", thread);\n lock.unlock();\n\n };\n\n for (int i=0; i <= 5; i++){\n executorService.execute(r1);\n }\n\n executorService.shutdown();\n\n }",
"public SequentialExecutor(Executor executor)\r\n {\r\n myExecutor = Utilities.checkNull(executor, \"executor\");\r\n }",
"public static Runnable decorate(ThreadPoolExecutor thiz, Runnable r) {\n /*\n * Here we handle the special case of this ThreadPoolExecutor (TPE) actually being an instance of\n * ScheduledThreadPoolExecutor (STPE). STPE subclasses TPE and doesn't override its remove() method.\n * When STPE.remove() is invoked, it actually invokes TPE.remove(). Thus despite ThreadPoolExecutorInterceptor\n * excluding STPE (and its subclasses) from interception, here we need to take this extra action to exclude\n * STPE.\n *\n * STPE uses a member class ScheduledFutureTask to manage delayed work. If the Runnable `r' is actually\n * a ScheduledFutureTask, then wrapping it here in a DecoratedRunnable will result in the check\n * `instanceof ScheduledFutureTask' failing in the implementation of `ScheduledThreadPoolExecutor$DelayedWorkQueue.indexOf',\n * which will result in a linear scan of the STPE's task queue instead of a constant-time lookup into\n * the array backing that queue. This performance regression may be dangerous in high-load scenarios.\n */\n if (thiz instanceof ScheduledThreadPoolExecutor) {\n return r;\n } else {\n return DecoratedRunnable.maybeCreate(r);\n }\n }",
"ScheduledExecutorService getExecutorService();",
"ActorThreadPool getThreadPool();",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static Executor getInstance() {\n Object object = sDirectExecutor;\n if (object != null) {\n return sDirectExecutor;\n }\n object = DirectExecutor.class;\n synchronized (object) {\n DirectExecutor directExecutor = sDirectExecutor;\n if (directExecutor == null) {\n sDirectExecutor = directExecutor = new DirectExecutor();\n }\n return sDirectExecutor;\n }\n }",
"void setThreadedAsyncMode(boolean useExecutor);",
"static ElementMatcher.Junction<? super TypeDescription> createTypeMatcher() {\n return isSubTypeOf(ThreadPoolExecutor.class)\n // ScheduledThreadPoolExecutor is handled separately, via ScheduledFutureTaskInterceptor\n .and(not(isSubTypeOf(ScheduledThreadPoolExecutor.class)));\n }",
"@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\r\n\tpublic static void main(String[] args) throws InterruptedException, ExecutionException{\n\t\tExecutorService e = Executors.newFixedThreadPool(2);\r\n//\t\tList<Future> list = new ArrayList<Future>();\r\n\t\tfor(int i=0;i<10;i++){\r\n\t\t\tCallable c = new JavaTestThread(i);\r\n\t\t\tFuture f = e.submit(c);\r\n\t\t\tSystem.out.println(\"-------\"+ f.get().toString());\r\n\t\t}\r\n\t\t\r\n\t\r\n\t\t\r\n\t}",
"private Thread startTestThread(Runnable runnable) {\n Thread t = new Thread(runnable);\n t.setDaemon(true);\n return t;\n }",
"public static void main(String[] args) {\n Runnable runnable = new Runnable() {\n @Override\n public void run() {\n for(int i =0; i<10000; i++){\n System.out.println(\n Thread.currentThread().getId() + \":\" + i\n );\n }\n }\n };\n\n // using functions, a bit cleaner\n Runnable runnable2 = () -> {\n for(int i =0; i<10000; i++){\n System.out.println(\n Thread.currentThread().getId() + \":\" + i\n );\n }\n };\n\n Thread thread = new Thread(runnable);\n thread.start();\n\n Thread thread2 = new Thread(runnable);\n thread2.start();\n\n Thread thread3 = new Thread(runnable);\n thread3.start();\n\n }",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void startTaskRunnerThread() {\n canRunTaskThread.set(true);\n new Thread(new Runnable() {\n @Override\n public void run() {\n try {\n log(\"Starting task: \" + getClassName());\n task();\n } catch (InterruptedException e) {\n e.printStackTrace();\n } finally {\n log(\"Finished task: \" + getClassName());\n canRunTaskThread.set(false);\n }\n }\n }).start();\n }",
"TaskFactory getTaskFactory();",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"@Bean(name = \"process-response\")\n\tpublic Executor threadPoolTaskExecutor() {\n\t\tThreadPoolTaskExecutor x = new ThreadPoolTaskExecutor();\n\t\tx.setCorePoolSize(poolProcessResponseCorePoolSize);\n\t\tx.setMaxPoolSize(poolProcessResponseMaxPoolSize);\n\t\treturn x;\n\t}",
"public interface Executor<Work extends Runnable> {\n void execute(Work work);\n\n void shutdown();\n\n void addWorks(Work work);\n\n void removeWorks(int num);\n\n int getWorkSize();\n}",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tMyThread myThread=new MyThread();\n\t\t//用Excutors 线程执行器类创建可扩展的线程池\n\t\tExecutorService executor=Executors.newCachedThreadPool();\n\t\t//将实现类对象提交到线程池进行管理\n\t\tFuture<Object> result1=executor.submit(myThread);\n\t\tFuture<Object> result2=executor.submit(myThread);\n\t\texecutor.shutdown();\n\t\tSystem.out.println(result1.get());\n\t\tSystem.out.println(result2.get());\n\t}",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public interface RegistryExecutor extends Executor {\n ExecutionContext getExecutionContext();\n\n void setRunner(RegistryDelegate<? extends RegistryTask> delegate);\n\n void start();\n\n void stop();\n}",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n for (int i = 0; i < 10; i++) {\n \tCallable worker = new WorkerThread1(\"\" + i);\n \tFuture future = executor.submit(worker);\n \tSystem.out.println(\"Results\"+future.get());\n //executor.execute(worker);\n }\n executor.shutdown();\n while (!executor.isTerminated()) {\n }\n System.out.println(\"Finished all threads\");\n }",
"private UniqueElementSingleThreadWorker()\n {\n _state = ActivityState.INITIALIZING;\n _taskQueue = new UniqueTagQueue<String, Runnable>();\n \n _taskThread = new Thread(\"UniqueElementSingleThreadWorker-\" + COUNTER.incrementAndGet())\n {\n @Override\n public void run()\n {\n while(true)\n {\n try\n {\n Runnable task = _taskQueue.blockingPop();\n if(task == SHUTDOWN_TASK)\n {\n break;\n }\n task.run();\n }\n catch(InterruptedException ex) { }\n //Catch run time exceptions that the runnable might throw so that the thread does not die\n catch(RuntimeException ex)\n {\n ErrorReporter.reportUncaughtException(ex);\n }\n }\n \n _state = ActivityState.SHUT_DOWN;\n }\n };\n }",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"public interface ThreadApi {\n Future executeInBackground(Runnable task);\n boolean executeInMainThread(Runnable task);\n boolean executeInMainThread(Runnable task, long delay);\n}",
"public interface RecipeExecutor {\n\n /**\n * Submit a Test recipe for asynchronous execution.\n *\n * @param recipe Test recipe to be executed.\n * @return an instance of <code>Execution</code> containing the current state of execution\n */\n Execution submitRecipe(TestRecipe recipe);\n\n /**\n * Submit a Test recipe for synchronous execution.\n *\n * @param recipe Test recipe to be executed.\n * @return an instance of <code>Execution</code> containing the execution result\n */\n Execution executeRecipe(TestRecipe recipe);\n\n /**\n * @return List of all the execution stored on server\n */\n// List<Execution> getExecutions();\n\n /**\n * Adds an execution listener, used when a recipe is submitted for asynchronous execution.\n *\n * @param listener listener to be added\n */\n void addExecutionListener(ExecutionListener listener);\n\n /**\n * Removes the provided listener\n *\n * @param listener listener to be removed\n */\n void removeExecutionListener(ExecutionListener listener);\n\n /**\n * Adds a recipe filter for preprocessing generated recipes\n *\n * @param recipeFilter\n */\n\n void addRecipeFilter(RecipeFilter recipeFilter);\n\n /**\n * Removes an existing recipe filter\n *\n * @param recipeFilter\n */\n\n void removeRecipeFilter(RecipeFilter recipeFilter);\n\n /**\n * @return executionMode <code>ExecutionMode.LOCAL</code> if running locally, <code>ExecutionMode.LOCAL</code> otherwise (when running on TestEngine)\n */\n ExecutionMode getExecutionMode();\n}",
"public static void main(String[] args) {\n\t\tBlockingQueue queue = new LinkedBlockingQueue(4);\n\n\t\t// Thread factory below is used to create new threads\n\t\tThreadFactory thFactory = Executors.defaultThreadFactory();\n\n\t\t// Rejection handler in case the task get rejected\n\t\tRejectTaskHandler rth = new RejectTaskHandler();\n\t\t// ThreadPoolExecutor constructor to create its instance\n\t\t// public ThreadPoolExecutor(int corePoolSize,int maximumPoolSize,long\n\t\t// keepAliveTime,\n\t\t// TimeUnit unit,BlockingQueue workQueue ,ThreadFactory\n\t\t// threadFactory,RejectedExecutionHandler handler) ;\n\t\tThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(1, 2, 10L, TimeUnit.MILLISECONDS, queue,\n\t\t\t\tthFactory, rth);\n\n\t\tfor (int i = 1; i <= 10; i++) {\n\t\t\tDataFileReader df = new DataFileReader(\"File \" + i);\n\t\t\tSystem.out.println(\"A new file has been added to read : \" + df.getFileName());\n\t\t\t// Submitting task to executor\n\t\t\tthreadPoolExecutor.execute(df);\n\t\t}\n\t\tthreadPoolExecutor.shutdown();\n\t}",
"private void YeWuMethod(String name) {\n\n for (int j = 0; j < 10; j++) {\n\n\n// Runnable task = new RunnableTask();\n// Runnable ttlRunnable = TtlRunnable.get(task);\n\n// executor.execute(ttlRunnable);\n\n executor.execute(() -> {\n System.out.println(\"==========\"+name+\"===\"+threadLocal.get());\n });\n }\n\n// for (int i = 0; i < 10; i++) {\n// new Thread(() -> {\n// System.out.println(name+\"===\"+threadLocal.get());\n// }, \"input thread name\").start();\n// }\n\n\n\n\n }",
"public static void main(String[] args) {\n\t\tThreadTest test= new ThreadTest();\n\t\ttest.start();\n\t\t\n\t\t// creating thread by implementing Runnable interface\n\t\tRunnable runnable = new Runnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\tSystem.out.println(\" Creating thread by implement Runnable Interface\");\n\t\t\t}\n\t\t};\n\t\t\t\n\t\tThread test2 = new Thread(runnable);\n\t\ttest2.start();\n\t\t\n\t\t// Runnable is a Functional Interface which having only one abstract method\n\t\tRunnable functionalInterface = ()-> System.out.println(\" creating thread using lembda expression\");\n\t\tThread test3 = new Thread(functionalInterface);\n\t\ttest3.start();\n\t\t\n\n\n\t\t\n\t}",
"@Test\n @ConditionalIgnoreRule.ConditionalIgnore(condition = RunningOnGithubAction.class)\n public void testSuccess() throws Exception {\n int concurrency = 10;\n ExecutorService executorService = Executors.newFixedThreadPool(10);\n List<Future<?>> futures = new ArrayList<>();\n // create 10 threads, each open a connection and submit a query\n // after sleeping 15 seconds\n for (int idx = 0; idx < concurrency; idx++) {\n logger.fine(\"open a new connection and submit query \" + idx);\n final int queryIdx = idx;\n futures.add(\n executorService.submit(\n () -> {\n try {\n submitQuery(true, queryIdx);\n } catch (SQLException | InterruptedException e) {\n throw new IllegalStateException(\"task interrupted\", e);\n }\n }));\n }\n executorService.shutdown();\n for (int idx = 0; idx < concurrency; idx++) futures.get(idx).get();\n }",
"public ThreadPoolExecutor create_blocking_thread_pool( String name, int threads, int queue_size )\n {\n NamedThreadPoolExecutor ret = new NamedThreadPoolExecutor( name, queue_size, threads, threads, 60, TimeUnit.MINUTES);\n \n pool_list.add( ret );\n\n return ret;\n }",
"private TestAcceptFactory() {\n this._pool = new DirectExecutor();\n }",
"public interface IExecutor {\n void execute(Runnable runnable);\n void shutdown();\n void shutdownNow();\n}",
"protected Runnable createTileRunner(Tile tile) {\r\n return new TileRunner();\r\n }",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"private CameraExecutors() {\n }",
"void runInThread(Runnable runnable) {\n try {\n Thread thread = new Thread(runnable::run);\n thread.start();\n } catch (Exception ex) {\n log.info(ex.getMessage());\n }\n\n }",
"private static void ThreadCreationLambdaWay() {\r\n\t\tThread t2 = new Thread(() -> {\r\n\t\t\tSystem.out.println(\"This is a runnable method done in Lambda Expressions > 1.8\");\r\n\t\t});\r\n\t\tt2.start();\r\n\t\t\r\n\t\t// Other way\r\n\t\t\r\n\t\tThread t3 = new Thread(() -> System.out.println(\"This is runnable method done in single line Lambda expressions > 1.8\"));\r\n\t\tt3.start();\r\n\t}",
"public abstract ScheduledExecutorService getWorkExecutor();",
"public static void main(String args[]) {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n\t\t\n\t\t// Create a list to hold the Future object associated with Callable\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\n\n\t\t/**\n\t\t * Create MyCallable instance using Lambda expression which return\n\t\t * the thread name executing this callable task\n\t\t */\n\t\tCallable<String> callable = () -> {\n\t\t\tThread.sleep(2000);\n\t\t\treturn Thread.currentThread().getName();\n\t\t};\n\t\t\n\t\t/**\n\t\t * Submit Callable tasks to be executed by thread pool\n\t\t * Add Future to the list, we can get return value using Future\n\t\t **/\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tFuture<String> future = executor.submit(callable);\n\t\t\tfutureList.add(future);\n\t\t}\n\t\t\n\t\t/**\n\t\t * Print the return value of Future, notice the output delay\n\t\t * in console because Future.get() waits for task to get completed\n\t\t **/\n\t\tfor (Future<String> future : futureList) {\n\t\t\ttry {\n\t\t\t\tSystem.out.println(new Date() + \" | \" + future.get());\n\t\t\t} catch (InterruptedException | ExecutionException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\t// shut down the executor service.\n\t\texecutor.shutdown();\n\t}",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"private static SimpleProcessExecutor newSimpleProcessExecutor() {\n return new SimpleProcessExecutor(new TestProcessManagerFactory().newProcessManager());\n }",
"public static void main(String[] args) {\n\n ArrayList<Cliente> clientes = new ArrayList<>();\n\n for (int i = 1; i < Math.random()*5+2; i++) {\n clientes.add(new Cliente(\"Cliente\" + i));\n }\n for (Cliente cliente : clientes){\n ExecutorService executor = Executors.newSingleThreadExecutor();\n executor.submit(() -> {\n\n cliente.run();\n executor.shutdown();\n\n });\n }\n }",
"public static ResettableExceptionHandlingExecutorService newSingleThreadExecutor(String prefix, boolean daemon)\n {\n return newSingleThreadExecutor(prefix, daemon, -1);\n }",
"public FuncCallExecutor(ThreadRuntime rt) {\r\n\t\tthis.rt = rt;\r\n\t}",
"public static void main(String[] args) throws InterruptedException {\n\t\tObservable.just(\"hi\",\"hello\",\"okay\").subscribe(z -> System.out.print(z));\n\t\t\n\t\t// creating observable using create in lambda style[Sync]\n\t\tObservable.create( f ->{\n\t\t\t\t\t\t\tf.onNext(\"hello\");\n\t\t\t\t\t\t\tif( f.isUnsubscribed() ){\n\t\t\t\t\t\t\t\treturn; \n\t\t\t\t\t\t\t}}).subscribe( s -> System.out.println(s));\n\t\t\n\t\t\n\t\tExecutorService executor = Executors.newSingleThreadExecutor();\n\t\tSystem.out.println(\"----\"+Thread.currentThread().getName());\n\t\t\n\t\t// creating observable using create in lambda style[Async]\n\t\tObservable.create(f -> {executor.submit(() ->{\n\t\t\t f.onNext(Thread.currentThread().getName());\n\t \t});}).subscribe(s -> {System.out.println(Thread.currentThread().getName()); \n\t \t\t\t\t\t\t\tSystem.out.println(s);} );\n\t\t\n\t\t// creating observable using create in lambda style[Async + observerOn]\n\t\tObservable.create(f -> {executor.submit(() ->{\n\t\t\t f.onNext(Thread.currentThread().getName());\n\t \t});}).observeOn(Schedulers.newThread()).subscribe(s -> {System.out.println(Thread.currentThread().getName()); \n\t \t\t\t\t\t\t\tSystem.out.println(s);} );\n\n\t\t\n\t\t// creating observable using create in lambda style[Async + subscribeOn]\n\t\tObservable.create(f -> {executor.submit(() ->{\n\t\t\t f.onNext(Thread.currentThread().getName());\n\t \t});}).subscribeOn(Schedulers.newThread()).subscribe(s -> {System.out.println(Thread.currentThread().getName()); \n\t \t\t\t\t\t\t\tSystem.out.println(s);} );\n\n\t\t\n\t\tList<Integer> result = new ArrayList<Integer>();\n\t\t//bulk API simulation\n\t\tObservable<Integer> obs = Observable.just(1,2,3,4,5,6).map(userId ->{\n\t\t\t//make mysql call\n\t\t try { System.out.println(\"---\"+Thread.currentThread().getName());\n\t\t\treturn makeSqlCall(userId);\n\t\t\t\n\t\t} catch (InterruptedException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn 0;\n\t\t});\n\t\t\t\t\n\t obs.subscribeOn(Schedulers.io()).subscribe(id ->{ result.add(id);System.out.println(Thread.currentThread().getName());});\n\t for(Integer x: result){System.out.print(x+\" - \");}\n\t\t\n\t}",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public void runInThread() {\n\t\tTaskRunner taskRunner = Dep.get(TaskRunner.class);\n\t\tATask atask = new ATask<Object>(getClass().getSimpleName()) {\n\t\t\t@Override\n\t\t\tprotected Object run() throws Exception {\n\t\t\t\tBuildTask.this.run();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\t\n\t\t};\n\t\ttaskRunner.submitIfAbsent(atask);\n\t}",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }"
] | [
"0.6373823",
"0.60498536",
"0.5993801",
"0.5892734",
"0.58380765",
"0.58209115",
"0.5817539",
"0.5810148",
"0.57851666",
"0.5728959",
"0.5726606",
"0.5706181",
"0.5681519",
"0.5647635",
"0.56137335",
"0.5588258",
"0.5573986",
"0.5573961",
"0.5560554",
"0.55366296",
"0.5535197",
"0.5519197",
"0.5513424",
"0.5511732",
"0.5484844",
"0.54789424",
"0.54733306",
"0.54620385",
"0.54584473",
"0.54440284",
"0.5441757",
"0.5434086",
"0.5427783",
"0.5379234",
"0.5375192",
"0.5339503",
"0.5316721",
"0.5310013",
"0.5302071",
"0.5301087",
"0.5299614",
"0.5269235",
"0.52638733",
"0.5251324",
"0.52493536",
"0.52422166",
"0.52333444",
"0.52292216",
"0.5218728",
"0.52175784",
"0.52161306",
"0.52151006",
"0.52120036",
"0.5202188",
"0.51973015",
"0.518889",
"0.51867336",
"0.5177355",
"0.5168644",
"0.51677674",
"0.5167161",
"0.51573837",
"0.5145706",
"0.5138418",
"0.51283866",
"0.51239735",
"0.5123631",
"0.5122514",
"0.5120941",
"0.51176244",
"0.5105136",
"0.5098024",
"0.50942737",
"0.5090735",
"0.5088029",
"0.50862956",
"0.5086138",
"0.5078638",
"0.50781405",
"0.50760704",
"0.5069136",
"0.50670356",
"0.5063776",
"0.50465727",
"0.5042742",
"0.5039958",
"0.5026944",
"0.5026739",
"0.5026248",
"0.5025997",
"0.50248444",
"0.50154024",
"0.50152695",
"0.5010424",
"0.50095963",
"0.50093305",
"0.50092864",
"0.500225",
"0.49974203",
"0.4994281"
] | 0.6503955 | 0 |
A new SingleThreadExecutor with null ThreadFactory throws NPE | public void testNewSingleThreadExecutor3() {
try {
ExecutorService e = Executors.newSingleThreadExecutor(null);
shouldThrow();
} catch (NullPointerException success) {}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n protected ExecutorService createDefaultExecutorService() {\n return null;\n }",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@Test\n @DisplayName(\"SingleThread Executor + shutdown\")\n void firstExecutorService() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n executor.submit(this::printThreadName);\n\n shutdownExecutor(executor);\n assertThrows(RejectedExecutionException.class, () -> executor.submit(this::printThreadName));\n }",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"@Override\r\n\tpublic Thread newThread(Runnable arg0) {\n\t\treturn null;\r\n\t}",
"public void testNewCachedThreadPool3() {\n try {\n ExecutorService e = Executors.newCachedThreadPool(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"private static synchronized Executor getDefaultExecutor() {\n return sDefaultExecutor == null ? sDefaultExecutor = new Executor(1)\n : sDefaultExecutor;\n }",
"@Override\n\tpublic Executor getExecutor() {\n\t\treturn null;\n\t}",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"@Test(expected = NullPointerException.class)\n public void testConstructorNPE2() throws NullPointerException {\n Executors.newCachedThreadPool();\n new BoundedCompletionService<Void>(null);\n shouldThrow();\n }",
"private UniqueElementSingleThreadWorker()\n {\n _state = ActivityState.INITIALIZING;\n _taskQueue = new UniqueTagQueue<String, Runnable>();\n \n _taskThread = new Thread(\"UniqueElementSingleThreadWorker-\" + COUNTER.incrementAndGet())\n {\n @Override\n public void run()\n {\n while(true)\n {\n try\n {\n Runnable task = _taskQueue.blockingPop();\n if(task == SHUTDOWN_TASK)\n {\n break;\n }\n task.run();\n }\n catch(InterruptedException ex) { }\n //Catch run time exceptions that the runnable might throw so that the thread does not die\n catch(RuntimeException ex)\n {\n ErrorReporter.reportUncaughtException(ex);\n }\n }\n \n _state = ActivityState.SHUT_DOWN;\n }\n };\n }",
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public void testCastNewSingleThreadExecutor() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n try {\n ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;\n shouldThrow();\n } catch (ClassCastException success) {}\n }\n }",
"public SequentialExecutor(Executor executor)\r\n {\r\n myExecutor = Utilities.checkNull(executor, \"executor\");\r\n }",
"@Override\r\n\tpublic Executor getAsyncExecutor() {\n\t\treturn null;\r\n\t}",
"@NonNull\n public static Executor directExecutor() {\n return DirectExecutor.getInstance();\n }",
"public static Executor buildExecutor() {\n GrpcRegisterConfig config = Singleton.INST.get(GrpcRegisterConfig.class);\n if (null == config) {\n return null;\n }\n final String threadpool = Optional.ofNullable(config.getThreadpool()).orElse(Constants.CACHED);\n switch (threadpool) {\n case Constants.SHARED:\n try {\n return SpringBeanUtils.getInstance().getBean(ShenyuThreadPoolExecutor.class);\n } catch (NoSuchBeanDefinitionException t) {\n throw new ShenyuException(\"shared thread pool is not enable, config ${shenyu.sharedPool.enable} in your xml/yml !\", t);\n }\n case Constants.FIXED:\n case Constants.EAGER:\n case Constants.LIMITED:\n throw new UnsupportedOperationException();\n case Constants.CACHED:\n default:\n return null;\n }\n }",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"public final /* bridge */ /* synthetic */ Object mo6445a() {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(1, (ThreadFactory) this.f9355a.mo6445a());\n cazf.m127593a(scheduledThreadPoolExecutor, \"Cannot return null from a non-@Nullable @Provides method\");\n return scheduledThreadPoolExecutor;\n }",
"private ThreadUtil() {\n \n }",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"private CameraExecutors() {\n }",
"public void testCallableNPE2() {\n try {\n Callable c = Executors.callable((Runnable) null, one);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public abstract T executor(@Nullable Executor executor);",
"@PostConstruct\r\n\tprivate void init() {\n\t threadPool = Executors.newCachedThreadPool();\r\n\t}",
"public AbstractConcurrentTestCase() {\n mainThread = Thread.currentThread();\n }",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testCallable1() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable());\n assertNull(c.call());\n }",
"@Override\n\tpublic Task constructInstance(Robot robot) {\n\t\treturn null;\n\t}",
"public static Executor getInstance() {\n Object object = sDirectExecutor;\n if (object != null) {\n return sDirectExecutor;\n }\n object = DirectExecutor.class;\n synchronized (object) {\n DirectExecutor directExecutor = sDirectExecutor;\n if (directExecutor == null) {\n sDirectExecutor = directExecutor = new DirectExecutor();\n }\n return sDirectExecutor;\n }\n }",
"@PostConstruct\r\n public void init() {\r\n \t//registerNotificationCallback(null); //to register taskexecution engine as default\r\n ThreadFactory namedThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"MARM-thread-%d\").build();\r\n \texecutor = Executors.newFixedThreadPool(10, namedThreadFactory);\r\n\r\n ThreadFactory brokerThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"Broker-thread-%d\").build();\r\n brokerExecutor = Executors.newFixedThreadPool(10, brokerThreadFactory);\r\n\r\n ThreadFactory logThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"LOG-thread-%d\").setPriority(Thread.MIN_PRIORITY).build();\r\n logExecutor = Executors.newFixedThreadPool(10, logThreadFactory);\r\n broker.registerInputListener(this);\r\n broker.registerControlListener(this);\r\n }",
"@Test(expected = NullPointerException.class)\n public void testSubmitNPE2() throws Exception {\n CompletionService<Boolean> ecs = new BoundedCompletionService<Boolean>(\n new ExecutorCompletionService<Boolean>(e));\n Runnable r = null;\n ecs.submit(r, Boolean.TRUE);\n shouldThrow();\n }",
"protected EventExecutor newChild(ThreadFactory threadFactory, Object... args) throws Exception {\n/* 57 */ return (EventExecutor)new LocalEventLoop(this, threadFactory);\n/* */ }",
"protected DefaultPromise()\r\n/* 44: */ {\r\n/* 45: 83 */ this.executor = null;\r\n/* 46: */ }",
"public ThreadLocal() {}",
"public void initialize() {\n service = Executors.newCachedThreadPool();\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public ThreadPool getDefaultThreadPool();",
"public void testCallableNPE1() {\n try {\n Callable c = Executors.callable((Runnable) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public ThreadFactory threadFactory() {\n return threadFactory_;\n }",
"private ThreadUtil() {\n }",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static Executor m13822l() {\n synchronized (f12483o) {\n if (f12471c == null) {\n f12471c = AsyncTask.THREAD_POOL_EXECUTOR;\n }\n }\n return f12471c;\n }",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"private ExecutorService getDroneThreads() {\n\t\treturn droneThreads;\n\t}",
"public interface ThreadExecutor extends Executor {\n}",
"public static CacheManagerExecutorServiceFactory getInstance() {\n return SINGLETON;\n }",
"public void testDefaultsToMainThread() throws Exception {\n\n Executor executor = new LooperExecutor();\n final CountDownLatch latch = new CountDownLatch(1);\n executor.execute(new Runnable() {\n @Override\n public void run() {\n assertEquals(\"running on ui thread\", Looper.getMainLooper(), Looper.myLooper());\n latch.countDown();\n }\n });\n latch.await();\n }",
"private GDMThreadFactory(){}",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"public Executor getExecutor() {\n\t\t\t\treturn null;\n\t\t\t}",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private static SimpleProcessExecutor newSimpleProcessExecutor() {\n return new SimpleProcessExecutor(new TestProcessManagerFactory().newProcessManager());\n }",
"@Override\r\n public Thread newThread(Runnable r) {\n Thread t = new Thread(r, \"example-runner\");\r\n t.setDaemon(true);\r\n return t;\r\n }",
"private TestAcceptFactory() {\n this._pool = new DirectExecutor();\n }",
"public static PriorityExecutorSupplier getInstance() {\n return SingletonHolder.INSTANCE;\n }",
"public DefaultPromise(EventExecutor executor)\r\n/* 36: */ {\r\n/* 37: 75 */ if (executor == null) {\r\n/* 38: 76 */ throw new NullPointerException(\"executor\");\r\n/* 39: */ }\r\n/* 40: 78 */ this.executor = executor;\r\n/* 41: */ }",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"PooledThread()\n {\n setDaemon(true);\n\n start();\n }",
"protected EventExecutorFactory getExecutorFactory() {\n\t\treturn executorFactory;\n\t}",
"public TestInvoker()\n {\n super(new TestClient(), new ThreadPoolExecutorImpl(3));\n }",
"protected EventExecutor executor()\r\n/* 27: */ {\r\n/* 28: 58 */ EventExecutor e = super.executor();\r\n/* 29: 59 */ if (e == null) {\r\n/* 30: 60 */ return channel().eventLoop();\r\n/* 31: */ }\r\n/* 32: 62 */ return e;\r\n/* 33: */ }",
"@Override\n\t\tpublic ThreadSynchroniser createThreadSynchroniser() {\n\t\t\tthrow new IllegalStateException(\"Mock \" + ThreadSynchroniser.class.getSimpleName() + \" for \"\n\t\t\t\t\t+ SupplierTypeBuilder.class.getSimpleName() + \" can not be used\");\n\t\t}",
"ScheduledExecutorService getExecutorService();",
"public static ResettableExceptionHandlingExecutorService newSingleThreadExecutor(String prefix, boolean daemon)\n {\n return newSingleThreadExecutor(prefix, daemon, -1);\n }",
"public Executor getMainThreadExecutor() {\n return mMainThreadExecutor;\n }",
"protected EventExecutor executor()\r\n/* 49: */ {\r\n/* 50: 87 */ return this.executor;\r\n/* 51: */ }",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public ExecutorService m33643a() {\n return (ExecutorService) C15521i.a(this.f28354a.m25442b(), \"Cannot return null from a non-@Nullable @Provides method\");\n }",
"public static ExecutorService getMainExecutorService() {\n return executorService;\n }",
"@Test(expected = NullPointerException.class)\n public void testSubmitNPE() throws Exception {\n CompletionService<Void> completionService = new BoundedCompletionService<Void>(\n new ExecutorCompletionService<Void>(e));\n Callable<Void> c = null;\n completionService.submit(c);\n shouldThrow();\n }",
"@NonNull\n public Executor getExecutor() {\n return mExecutor;\n }",
"ThreadStart createThreadStart();",
"@Override\n protected Thread createThread(final Runnable runnable, final String name) {\n return new Thread(runnable, Thread.currentThread().getName() + \"-exec\");\n }",
"@Override\n public Executor generate(int type) {\n return null;\n }",
"public static ExecutorService m22732e() {\n if (f20304e == null) {\n synchronized (C7258h.class) {\n if (f20304e == null) {\n f20304e = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.BACKGROUND).mo18996a(), true);\n }\n }\n }\n return f20304e;\n }",
"ResilientExecutionUtil() {\n // do nothing\n }",
"public void testPrivilegedThreadFactory() throws Exception {\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final ClassLoader thisccl = Thread.currentThread().getContextClassLoader();\n // android-note: Removed unsupported access controller check.\n // final AccessControlContext thisacc = AccessController.getContext();\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n assertSame(thisccl, current.getContextClassLoader());\n //assertEquals(thisacc, AccessController.getContext());\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.privilegedThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }};\n\n runWithPermissions(r,\n new RuntimePermission(\"getClassLoader\"),\n new RuntimePermission(\"setContextClassLoader\"),\n new RuntimePermission(\"modifyThread\"));\n }",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"public ExecutionFactoryImpl() {\n\t\tsuper();\n\t}",
"ActorThreadPool getThreadPool();",
"public void testCallableNPE3() {\n try {\n Callable c = Executors.callable((PrivilegedAction) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"public void testCallable2() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable(), one);\n assertSame(one, c.call());\n }",
"private synchronized WorkerThread getThread() {\n\t\tfor (int i = 0; i < this.threadPool.size(); ++i) {\n\t\t\tif (this.threadPool.get(i).available()) {\n\t\t\t\tthis.threadPool.get(i).setAvailable(false);\n\t\t\t\treturn this.threadPool.get(i);\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}",
"private static void multiThreading(){\n\t\tSystem.out.println(\"\\nCreating new two separate instances of Singleton using Multi threading\");\n\t\tExecutorService service = Executors.newFixedThreadPool(2);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.shutdown();\n\t}",
"public NamedThreadFactory(String name)\n {\n this(name, null);\n }",
"TaskFactory getTaskFactory();",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"public FuncCallExecutor(ThreadRuntime rt) {\r\n\t\tthis.rt = rt;\r\n\t}",
"public void createThread() {\n }",
"public WildflyHystrixConcurrencyStrategy(final ManagedThreadFactory threadFactory) {\n\t\t//\n\t\t// Used by CDI provider.\n\t\t\n\t\tthis.threadFactory = threadFactory;\n\t}",
"public Builder setThreadFactory(ThreadFactory threadFactory) {\n threadFactory_ = (threadFactory != null) ? threadFactory : Executors.defaultThreadFactory();\n return this;\n }",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }"
] | [
"0.7044971",
"0.701917",
"0.70033735",
"0.6456199",
"0.6373457",
"0.6365218",
"0.63019973",
"0.62990135",
"0.6295157",
"0.6225891",
"0.6152439",
"0.6150687",
"0.6121072",
"0.6112016",
"0.6085198",
"0.6063539",
"0.6053164",
"0.60204196",
"0.60029566",
"0.5934551",
"0.5934414",
"0.5901353",
"0.5888296",
"0.5880694",
"0.5849597",
"0.58458567",
"0.5830885",
"0.58190304",
"0.5811948",
"0.58110464",
"0.58017987",
"0.579566",
"0.57796556",
"0.5778003",
"0.57687855",
"0.57682294",
"0.57681644",
"0.5727707",
"0.5725815",
"0.57147986",
"0.5708456",
"0.5699711",
"0.56923246",
"0.5680157",
"0.5657325",
"0.56499046",
"0.5648721",
"0.5635217",
"0.563027",
"0.56251246",
"0.5622028",
"0.5608274",
"0.56037855",
"0.55978954",
"0.5586069",
"0.5573424",
"0.5550595",
"0.55424696",
"0.5515903",
"0.55151534",
"0.55141795",
"0.5487272",
"0.54839796",
"0.5477422",
"0.5477365",
"0.547411",
"0.54733354",
"0.546417",
"0.5442575",
"0.54201436",
"0.54110676",
"0.5405143",
"0.5399716",
"0.5399245",
"0.5383174",
"0.53753424",
"0.53716344",
"0.53587455",
"0.5358619",
"0.53462476",
"0.534289",
"0.53395975",
"0.5334446",
"0.53303796",
"0.5312833",
"0.53056896",
"0.5302332",
"0.52739555",
"0.5270305",
"0.52651733",
"0.5263921",
"0.5261878",
"0.5260267",
"0.52561986",
"0.5237684",
"0.5237409",
"0.52371675",
"0.5236758",
"0.5233261",
"0.5226579"
] | 0.74290174 | 0 |
A new SingleThreadExecutor cannot be casted to concrete implementation | public void testCastNewSingleThreadExecutor() {
final ExecutorService e = Executors.newSingleThreadExecutor();
try (PoolCleaner cleaner = cleaner(e)) {
try {
ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;
shouldThrow();
} catch (ClassCastException success) {}
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface ThreadExecutor extends Executor {\n}",
"public abstract T executor(@Nullable Executor executor);",
"@NonNull\n public static Executor directExecutor() {\n return DirectExecutor.getInstance();\n }",
"public interface Executor<T> {\n\n void submit(T arg);\n\n}",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private ExecutorTransformer(Executor executor) {\n super();\n iExecutor = executor;\n }",
"public abstract ScheduledExecutorService getWorkExecutor();",
"public interface IHttpThreadExecutor {\n public void addTask(Runnable runnable);\n}",
"public interface Executor<E>{\n\t\tvoid execute(E object);\n\t}",
"protected EventExecutor executor()\r\n/* 49: */ {\r\n/* 50: 87 */ return this.executor;\r\n/* 51: */ }",
"public static Executor buildExecutor() {\n GrpcRegisterConfig config = Singleton.INST.get(GrpcRegisterConfig.class);\n if (null == config) {\n return null;\n }\n final String threadpool = Optional.ofNullable(config.getThreadpool()).orElse(Constants.CACHED);\n switch (threadpool) {\n case Constants.SHARED:\n try {\n return SpringBeanUtils.getInstance().getBean(ShenyuThreadPoolExecutor.class);\n } catch (NoSuchBeanDefinitionException t) {\n throw new ShenyuException(\"shared thread pool is not enable, config ${shenyu.sharedPool.enable} in your xml/yml !\", t);\n }\n case Constants.FIXED:\n case Constants.EAGER:\n case Constants.LIMITED:\n throw new UnsupportedOperationException();\n case Constants.CACHED:\n default:\n return null;\n }\n }",
"public static Executor getInstance() {\n Object object = sDirectExecutor;\n if (object != null) {\n return sDirectExecutor;\n }\n object = DirectExecutor.class;\n synchronized (object) {\n DirectExecutor directExecutor = sDirectExecutor;\n if (directExecutor == null) {\n sDirectExecutor = directExecutor = new DirectExecutor();\n }\n return sDirectExecutor;\n }\n }",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public interface ExecutorService {\n\n\n /**\n * beat 心跳\n * @return\n */\n public ReturnT<String> beat();\n\n\n public ReturnT<String> idleBeat(int jobId);\n\n\n /**\n * kill 掉某个job\n * @param jobId\n * @return\n */\n public ReturnT<String> kill(int jobId);\n\n\n /**\n * 记录掉某个日志\n * @param logDateTim\n * @param logId\n * @param fromLineNum\n * @return\n */\n public ReturnT<LogResult> log(long logDateTim, int logId, int fromLineNum);\n\n\n /**\n * 执行某个任务\n * @param triggerParam\n * @return\n */\n public ReturnT<String> run(TriggerParam triggerParam);\n\n}",
"public interface Executor<Work extends Runnable> {\n void execute(Work work);\n\n void shutdown();\n\n void addWorks(Work work);\n\n void removeWorks(int num);\n\n int getWorkSize();\n}",
"public interface RegistryExecutor extends Executor {\n ExecutionContext getExecutionContext();\n\n void setRunner(RegistryDelegate<? extends RegistryTask> delegate);\n\n void start();\n\n void stop();\n}",
"public SequentialExecutor(Executor executor)\r\n {\r\n myExecutor = Utilities.checkNull(executor, \"executor\");\r\n }",
"public interface a {\n Thread a();\n\n void a(Runnable runnable);\n\n Executor b();\n\n Executor c();\n}",
"public interface IExecutorBase {\n <T> T call(ICallable<T> callable) throws Exception;\n\n <T1, T2> IMVal2<T1, T2> call(ICallable<T1> callable1, ICallable<T2> callable2) throws Exception;\n\n <T1, T2, T3> IMVal3<T1, T2, T3> call(ICallable<T1> callable1, ICallable<T2> callable2, ICallable<T3> callable3) throws Exception;\n}",
"public static GlideExecutor m21519e() {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(0, Integer.MAX_VALUE, f23336b, TimeUnit.MILLISECONDS, new SynchronousQueue(), new C8962a(\"source-unlimited\", UncaughtThrowableStrategy.f23340b, false));\n return new GlideExecutor(threadPoolExecutor);\n }",
"protected EventExecutor executor()\r\n/* 27: */ {\r\n/* 28: 58 */ EventExecutor e = super.executor();\r\n/* 29: 59 */ if (e == null) {\r\n/* 30: 60 */ return channel().eventLoop();\r\n/* 31: */ }\r\n/* 32: 62 */ return e;\r\n/* 33: */ }",
"@Override\n public ScheduledExecutorService getSchedExecService() {\n return channelExecutor;\n }",
"@Override\n protected ExecutorService createDefaultExecutorService() {\n return null;\n }",
"@Override\r\n\tpublic Executor getAsyncExecutor() {\n\t\treturn null;\r\n\t}",
"@Override\n\tpublic Executor getExecutor() {\n\t\treturn null;\n\t}",
"protected EventExecutor newChild(ThreadFactory threadFactory, Object... args) throws Exception {\n/* 57 */ return (EventExecutor)new LocalEventLoop(this, threadFactory);\n/* */ }",
"protected abstract void execute() throws InterruptedException, SenseException;",
"public interface DodonaExecutor {\n\t/**\n\t * Executes the given call, synchronously.\n\t *\n\t * @param call the call to execute\n\t * @param indicator the progress indicator\n\t * @param <T> return type of the response\n\t * @return the response from the call\n\t */\n\t@Nonnull\n\t<T> T execute(Function<? super DodonaClient, T> call,\n\t ProgressIndicator indicator);\n\t\n\t/**\n\t * Executes the given call, asynchronously.\n\t *\n\t * @param project the project\n\t * @param title the dialog title\n\t * @param cancellable whether this request can be cancelled\n\t * @param indicator the progress indicator\n\t * @param call the call to execute\n\t * @param <T> return type of the response\n\t * @return the response from the call\n\t */\n\t@Nonnull\n\t<T> DodonaFuture<T> execute(@Nullable Project project,\n\t String title,\n\t boolean cancellable,\n\t ProgressIndicator indicator,\n\t Function<? super DodonaClient, ? extends T> call);\n\t\n\t/**\n\t * Executes the given call, asynchronously.\n\t *\n\t * @param call the call to execute\n\t * @param <T> type of the response\n\t * @return the response from the call\n\t */\n\t@Nonnull\n\t<T> DodonaFuture<T> execute(Function<? super DodonaClient, ? extends T> call);\n}",
"public interface ITaskHandler {\n\n\t/**\n\t * It is called in a separate thread to handle the task.\n\t * Parameters are thoes given in the addTask()\n\t * This method should not been called directly.\n\t * \n\t * @param pTaskType\n\t * @param pParam\n\t * @throws IllegalArgumentException\n\t */\n\tvoid handleTask(ITaskType pTaskType, Object pParam) throws IllegalArgumentException;\n}",
"public interface IExecutor {\n void execute(Runnable runnable);\n void shutdown();\n void shutdownNow();\n}",
"public void testNewSingleThreadExecutor3() {\n try {\n ExecutorService e = Executors.newSingleThreadExecutor(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"@Override\n\t\tpublic ThreadSynchroniser createThreadSynchroniser() {\n\t\t\tthrow new IllegalStateException(\"Mock \" + ThreadSynchroniser.class.getSimpleName() + \" for \"\n\t\t\t\t\t+ SupplierTypeBuilder.class.getSimpleName() + \" can not be used\");\n\t\t}",
"@Override\n public ExecutorService getWrapped() {\n return es;\n }",
"public interface BaseUseCase<R> {\n Single<R> execute();\n}",
"protected DefaultPromise()\r\n/* 44: */ {\r\n/* 45: 83 */ this.executor = null;\r\n/* 46: */ }",
"public final /* bridge */ /* synthetic */ Object mo6445a() {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(1, (ThreadFactory) this.f9355a.mo6445a());\n cazf.m127593a(scheduledThreadPoolExecutor, \"Cannot return null from a non-@Nullable @Provides method\");\n return scheduledThreadPoolExecutor;\n }",
"public interface Interactor extends Runnable {\n}",
"public interface Executor {\n void setTask(Task task);\n Task getTask();\n void startTask();\n}",
"public interface AbstractScheduledFutureC02560jD<V> extends ScheduledFuture<V>, AnonymousClass1XI<V> {\n}",
"@NonNull\n public Executor getExecutor() {\n return mExecutor;\n }",
"interface Runnable {\n void execute() throws Throwable;\n default void run() {\n try {\n execute();\n } catch(Throwable t) {\n throw new RuntimeException(t);\n }\n }\n }",
"@Override\n protected void execute() {\n }",
"@Override\n protected void execute() {\n }",
"@Override\n protected void execute() {\n }",
"private CameraExecutors() {\n }",
"private ThreadUtil() {\n throw new UnsupportedOperationException(\"This class is non-instantiable\"); //$NON-NLS-1$\n }",
"public abstract T execute() throws Exception;",
"private static Executor getExecutor(final Message message) {\n Endpoint endpoint = message.getExchange().get(Endpoint.class);\n Executor executor = endpoint.getService().getExecutor();\n \n if (executor == null || SynchronousExecutor.isA(executor)) {\n // need true asynchrony\n Bus bus = message.getExchange().get(Bus.class);\n if (bus != null) {\n WorkQueueManager workQueueManager =\n bus.getExtension(WorkQueueManager.class);\n Executor autoWorkQueue =\n workQueueManager.getNamedWorkQueue(\"ws-addressing\");\n executor = autoWorkQueue != null\n ? autoWorkQueue\n : workQueueManager.getAutomaticWorkQueue();\n } else {\n executor = OneShotAsyncExecutor.getInstance();\n }\n }\n message.getExchange().put(Executor.class, executor);\n return executor;\n }",
"@Override\r\n\tpublic void executer() {\n\t}",
"@Override\n protected void execute() {\n \n }",
"private SerialExecutor(T identifier) {\n this.identifier = identifier;\n }",
"public interface SingletonTask extends Task {\n}",
"public Executor getExecutor() {\n return executor;\n }",
"@Override\n public void execute() {}",
"protected DdlExecutorImpl() {\n }",
"public interface ISimpleWorkExecManager extends IAsyncWorkExecManager<IAsyncWorker, IAsyncWorker>\n{\n\n\tpublic static final ISimpleWorkExecManager INSTANCE = new SimpleWorkExecManagerImpl();\n}",
"public Executor getExecutor() {\n Object o = getReference(\"ant.executor\");\n if (o == null) {\n String classname = getProperty(\"ant.executor.class\");\n if (classname == null) {\n classname = DefaultExecutor.class.getName();\n }\n log(\"Attempting to create object of type \" + classname, MSG_DEBUG);\n try {\n o = Class.forName(classname, true, coreLoader).newInstance();\n } catch (ClassNotFoundException seaEnEfEx) {\n //try the current classloader\n try {\n o = Class.forName(classname).newInstance();\n } catch (Exception ex) {\n log(ex.toString(), MSG_ERR);\n }\n } catch (Exception ex) {\n log(ex.toString(), MSG_ERR);\n }\n if (o == null) {\n throw new BuildException(\n \"Unable to obtain a Target Executor instance.\");\n }\n setExecutor((Executor) o);\n }\n return (Executor) o;\n }",
"@Override\n protected void execute() {\n \n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"ResilientExecutionUtil() {\n // do nothing\n }",
"private interface CheckedRunnable {\n void run() throws Exception;\n }",
"public interface IExecutorBuilder {\n /**\n * Build IExecutor implementation.\n * @return IExecutor\n */\n IExecutor build();\n}",
"public interface Interactor extends Runnable {\n void run();\n}",
"public abstract void submit(Runnable runnable);",
"@Override\n protected void execute() {\n\n }",
"public abstract void execute(Task t);",
"public interface PostExecutionThread {\n Scheduler getScheduler();\n}",
"public interface PostExecutionThread {\n Scheduler getScheduler();\n}",
"public interface PostExecutionThread {\n Scheduler getScheduler();\n}",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"@Override\n public void execute() {\n }",
"public interface Service extends Runnable {\n\n}",
"public interface Task<T> {\n T execute();\n}",
"public ExecutorProxy(final ExecutorService executor) {\n\t\tthis.executor = executor;\n\t}",
"public interface TaskBase {\n public void executeTask();\n\n}",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tMyThread myThread=new MyThread();\n\t\t//用Excutors 线程执行器类创建可扩展的线程池\n\t\tExecutorService executor=Executors.newCachedThreadPool();\n\t\t//将实现类对象提交到线程池进行管理\n\t\tFuture<Object> result1=executor.submit(myThread);\n\t\tFuture<Object> result2=executor.submit(myThread);\n\t\texecutor.shutdown();\n\t\tSystem.out.println(result1.get());\n\t\tSystem.out.println(result2.get());\n\t}",
"public FuncCallExecutor(ThreadRuntime rt) {\r\n\t\tthis.rt = rt;\r\n\t}",
"static ElementMatcher.Junction<? super TypeDescription> createTypeMatcher() {\n return isSubTypeOf(ThreadPoolExecutor.class)\n // ScheduledThreadPoolExecutor is handled separately, via ScheduledFutureTaskInterceptor\n .and(not(isSubTypeOf(ScheduledThreadPoolExecutor.class)));\n }",
"private static SimpleProcessExecutor newSimpleProcessExecutor() {\n return new SimpleProcessExecutor(new TestProcessManagerFactory().newProcessManager());\n }",
"private FlowExecutorUtils()\r\n {\r\n // Private constructor to prevent instantiation\r\n }",
"private ThreadUtil() {\n \n }",
"public interface ThreadPool<Job extends Runnable> {\n\n void execute(Job job);\n\n void shutDown();\n\n void addWorkers(int num);\n\n void removeWorkers(int num);\n\n int getJobSize();\n\n}",
"@Override\n\tpublic void execute() {\n\t\tThreadPool pool=ThreadPool.getInstance();\n\t\tpool.beginTaskRun(this);\n\t}",
"public interface ExecutionContext {\n}",
"public interface TaskFactoryInterface<T> {\n T get();\n}",
"public DefaultPromise(EventExecutor executor)\r\n/* 36: */ {\r\n/* 37: 75 */ if (executor == null) {\r\n/* 38: 76 */ throw new NullPointerException(\"executor\");\r\n/* 39: */ }\r\n/* 40: 78 */ this.executor = executor;\r\n/* 41: */ }",
"public ActivityIdentifier submit(Activity activity) throws NoSuitableExecutorException;",
"private UniqueElementSingleThreadWorker()\n {\n _state = ActivityState.INITIALIZING;\n _taskQueue = new UniqueTagQueue<String, Runnable>();\n \n _taskThread = new Thread(\"UniqueElementSingleThreadWorker-\" + COUNTER.incrementAndGet())\n {\n @Override\n public void run()\n {\n while(true)\n {\n try\n {\n Runnable task = _taskQueue.blockingPop();\n if(task == SHUTDOWN_TASK)\n {\n break;\n }\n task.run();\n }\n catch(InterruptedException ex) { }\n //Catch run time exceptions that the runnable might throw so that the thread does not die\n catch(RuntimeException ex)\n {\n ErrorReporter.reportUncaughtException(ex);\n }\n }\n \n _state = ActivityState.SHUT_DOWN;\n }\n };\n }",
"@Override\r\n\tvoid execute(Runnable task);",
"public Class getReadTask(SelectorThread selectorThread);",
"@Override\n public void execute(final Task<T> task) {\n }",
"@Override\r\n\tpublic void execute() throws Exception {\n\t\t\r\n\t}",
"public void execute() throws InterruptedException;",
"abstract public void run() throws Exception;",
"ScheduledExecutorService getExecutorService();",
"@Override\n public void execute() {\n \n \n }",
"abstract void run() throws Exception;",
"@Override\r\n\tprotected void execute() {\r\n\t}",
"public static Executor m13822l() {\n synchronized (f12483o) {\n if (f12471c == null) {\n f12471c = AsyncTask.THREAD_POOL_EXECUTOR;\n }\n }\n return f12471c;\n }",
"public static void main(String args[]) throws Exception\n {\n ImplementsRunnable rc = new ImplementsRunnable();\n Thread t1 = new Thread(rc);\n t1.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t2 = new Thread(rc);\n t2.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t3 = new Thread(rc);\n t3.start();\n \n // Modification done here. Only one object is shered by multiple threads\n // here also.\n ExtendsThread extendsThread = new ExtendsThread();\n Thread thread11 = new Thread(extendsThread);\n thread11.start();\n Thread.sleep(1000);\n Thread thread12 = new Thread(extendsThread);\n thread12.start();\n Thread.sleep(1000);\n Thread thread13 = new Thread(extendsThread);\n thread13.start();\n Thread.sleep(1000);\n }"
] | [
"0.7375924",
"0.66472745",
"0.6350426",
"0.6197253",
"0.60984236",
"0.60926497",
"0.60592324",
"0.60362214",
"0.6013583",
"0.5993712",
"0.5986656",
"0.59260976",
"0.587074",
"0.58471215",
"0.58321655",
"0.5813613",
"0.5810744",
"0.5787835",
"0.5775828",
"0.5763942",
"0.5728055",
"0.5720721",
"0.57083535",
"0.57003546",
"0.56983864",
"0.5692438",
"0.56852263",
"0.56745535",
"0.5669617",
"0.5655555",
"0.5642669",
"0.56363845",
"0.56358576",
"0.5618937",
"0.5616373",
"0.5596603",
"0.55941665",
"0.55871844",
"0.556855",
"0.5546992",
"0.5521647",
"0.5512096",
"0.5512096",
"0.5512096",
"0.54995286",
"0.54993033",
"0.5497414",
"0.54892176",
"0.54831946",
"0.54619443",
"0.5445117",
"0.54362595",
"0.5435555",
"0.5431827",
"0.54271156",
"0.5426737",
"0.5416519",
"0.5412442",
"0.5410494",
"0.53992355",
"0.53987294",
"0.5395503",
"0.53953654",
"0.5390443",
"0.53836995",
"0.5380379",
"0.537095",
"0.537095",
"0.537095",
"0.53663486",
"0.5361283",
"0.5356217",
"0.53547084",
"0.5344724",
"0.534468",
"0.5324239",
"0.5305742",
"0.52951974",
"0.5294875",
"0.5285974",
"0.5281978",
"0.52766556",
"0.52748466",
"0.52748054",
"0.52743506",
"0.5263482",
"0.52570504",
"0.5253414",
"0.52381307",
"0.5234641",
"0.5229806",
"0.5223614",
"0.5223335",
"0.5216493",
"0.5212235",
"0.52053165",
"0.52047616",
"0.5200823",
"0.5198867",
"0.5193319"
] | 0.7309522 | 1 |
A new newFixedThreadPool can execute runnables | public void testNewFixedThreadPool1() {
final ExecutorService e = Executors.newFixedThreadPool(2);
try (PoolCleaner cleaner = cleaner(e)) {
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"private static void threadPoolWithExecute() {\n\n Executor executor = Executors.newFixedThreadPool(3);\n IntStream.range(1, 10)\n .forEach((i) -> {\n executor.execute(() -> {\n System.out.println(\"started task for id - \"+i);\n try {\n if (i == 8) {\n Thread.sleep(4000);\n } else {\n Thread.sleep(1000);\n }\n System.out.println(\"In runnable task for id -\" + i);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n });\n System.out.println(\"End of method .THis gets printed immdly since execute is not blocking call\");\n }",
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"private void initThreadPool(int numOfThreadsInPool, int[][] resultMat, Observer listener) {\n for(int i=0;i<numOfThreadsInPool; i++){\r\n PoolThread newPoolThread = new PoolThread(m_TaskQueue, resultMat);\r\n newPoolThread.AddResultMatListener(listener);\r\n m_Threads.add(newPoolThread);\r\n }\r\n // Start all Threads:\r\n for(PoolThread currThread: m_Threads){\r\n currThread.start();\r\n }\r\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public static void main(String[] args) {\n\t\tExecutorService pool = Executors.newFixedThreadPool(3);\n\t\t//ExecutorService pool = Executors.newSingleThreadExecutor();\n\t\t\n\t\tExecutorService pool2 = Executors.newCachedThreadPool();\n\t\t//this pool2 will add more thread into pool(when no other thread running), the new thread do not need to wait.\n\t\t//pool2 will delete un runing thread(unrun for 60 secs)\n\t\tThread t1 = new MyThread();\n\t\tThread t2 = new MyThread();\n\t\tThread t3 = new MyThread();\n\n\t\tpool.execute(t1);\n\t\tpool.execute(t2);\n\t\tpool.execute(t3);\n\t\tpool.shutdown();\n\t\t\n\t}",
"public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }",
"public static void main(String[] args) {\n SomeRunnable obj1 = new SomeRunnable();\n SomeRunnable obj2 = new SomeRunnable();\n SomeRunnable obj3 = new SomeRunnable();\n \n System.out.println(\"obj1 = \"+obj1);\n System.out.println(\"obj2 = \"+obj2);\n System.out.println(\"obj3 = \"+obj3);\n \n //Create fixed Thread pool, here pool of 2 thread will created\n ExecutorService pool = Executors.newFixedThreadPool(3);\n ExecutorService pool2 = Executors.newFixedThreadPool(2);\n pool.execute(obj1);\n pool.execute(obj2);\n pool2.execute(obj3);\n \n pool.shutdown();\n pool2.shutdown();\n }",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"ActorThreadPool getThreadPool();",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public interface ThreadPool<Job extends Runnable> {\n\n void execute(Job job);\n\n void shutDown();\n\n void addWorkers(int num);\n\n void removeWorkers(int num);\n\n int getJobSize();\n\n}",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testExecuteInParallel_Collection_ThreadPoolExecutor() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks, ParallelUtil.createThreadPool( 1 ) );\n assertEquals( result.size(), tasks.size() );\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"public ThreadPool getDefaultThreadPool();",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"public void testForNThreads();",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executorService = new ThreadPoolExecutor(3, 10, 1L, TimeUnit.SECONDS,\n new LinkedBlockingQueue<>(20),\n Executors.defaultThreadFactory(),\n new ThreadPoolExecutor.AbortPolicy());\n ABC abc = new ABC();\n try {\n for (int i = 1; i <= 10; i++) {\n executorService.execute(abc::print5);\n executorService.execute(abc::print10);\n executorService.execute(abc::print15);\n }\n\n }finally {\n executorService.shutdown();\n }\n }",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"@Override\n\tpublic void execute() {\n\t\tThreadPool pool=ThreadPool.getInstance();\n\t\tpool.beginTaskRun(this);\n\t}",
"public boolean newThreadPoolAvailable() {\n\t\tif (this.serverConnectorUsed+1 <= MAX_THREADS) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"public static void main(String[] args) {\n\t\tBlockingQueue queue = new LinkedBlockingQueue(4);\n\n\t\t// Thread factory below is used to create new threads\n\t\tThreadFactory thFactory = Executors.defaultThreadFactory();\n\n\t\t// Rejection handler in case the task get rejected\n\t\tRejectTaskHandler rth = new RejectTaskHandler();\n\t\t// ThreadPoolExecutor constructor to create its instance\n\t\t// public ThreadPoolExecutor(int corePoolSize,int maximumPoolSize,long\n\t\t// keepAliveTime,\n\t\t// TimeUnit unit,BlockingQueue workQueue ,ThreadFactory\n\t\t// threadFactory,RejectedExecutionHandler handler) ;\n\t\tThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(1, 2, 10L, TimeUnit.MILLISECONDS, queue,\n\t\t\t\tthFactory, rth);\n\n\t\tfor (int i = 1; i <= 10; i++) {\n\t\t\tDataFileReader df = new DataFileReader(\"File \" + i);\n\t\t\tSystem.out.println(\"A new file has been added to read : \" + df.getFileName());\n\t\t\t// Submitting task to executor\n\t\t\tthreadPoolExecutor.execute(df);\n\t\t}\n\t\tthreadPoolExecutor.shutdown();\n\t}",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public static void main(String[] args) {\n ExecutorService es = Executors.newCachedThreadPool();\n es.execute(new Task(65));\n es.execute(new Task(5));\n System.out.println(\"结束执行!\");\n }",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static void main(String[] args)\n {\n Runnable r1 = new Task1();\n // Creates Thread task\n Task2 r2 = new Task2();\n ExecutorService pool = Executors.newFixedThreadPool(MAX_T);\n\n pool.execute(r1);\n r2.start();\n\n // pool shutdown\n pool.shutdown();\n }",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"public static void main(String[] args) {\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\r\n\r\n\t\t//collection of multiple tasks which we are supposed to give to thread pool to perform\r\n\t\tList<CallableDemo> taskList = new ArrayList<CallableDemo>();\r\n\t\t//adding multiple tasks to collection (tasks are created using 'Callable' Interface.\r\n\t\ttaskList.add(new CallableDemo(\"first\"));\r\n\t\ttaskList.add(new CallableDemo(\"second\"));\r\n\t\ttaskList.add(new CallableDemo(\"third\"));\r\n\t\ttaskList.add(new CallableDemo(\"fourth\"));\r\n\t\ttaskList.add(new CallableDemo(\"fifth\"));\r\n\t\ttaskList.add(new CallableDemo(\"sixth\"));\r\n\t\ttaskList.add(new CallableDemo(\"seventh\"));\r\n\r\n\t\t//creating a thread pool of size four\r\n\t\tExecutorService threadPool = Executors.newFixedThreadPool(4);\r\n\t\t\r\n\t\tfor (CallableDemo task : taskList) {\r\n\t\t\tfutureList.add(threadPool.submit(task));\r\n\t\t}\r\n threadPool.shutdown();\r\n\t\tfor (Future<String> future : futureList) {\r\n\t\t\ttry {\r\n//\t\t\t\t System.out.println(future.get());\r\n\t\t\t\tSystem.out.println(future.get(1L, TimeUnit.SECONDS));\r\n\t\t\t} catch (InterruptedException | ExecutionException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}catch (TimeoutException e) {\r\n\t\t\t\tSystem.out.println(\"Sorry already waited for result for 1 second , can't wait anymore...\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t}",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n for (int i = 0; i < 10; i++) {\n \tCallable worker = new WorkerThread1(\"\" + i);\n \tFuture future = executor.submit(worker);\n \tSystem.out.println(\"Results\"+future.get());\n //executor.execute(worker);\n }\n executor.shutdown();\n while (!executor.isTerminated()) {\n }\n System.out.println(\"Finished all threads\");\n }",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"public static void main(String[] args) {\r\n\t\tMyThread thread = new MyThread();\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t}",
"private synchronized void addTask(Runnable runnable) {\r\n mTaskQueue.add(runnable);\r\n try {\r\n if (mPoolThreadHandler==null){\r\n mSemaphorePoolThreadHandler.acquire();\r\n }\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n\r\n mPoolThreadHandler.sendEmptyMessage(0x110);\r\n }",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"public interface IHttpThreadExecutor {\n public void addTask(Runnable runnable);\n}",
"public static void main(String[] args) {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(threadNum, threadNum, 10L, TimeUnit.SECONDS, linkedBlockingDeque);\n\n final CountDownLatch countDownLatch = new CountDownLatch(NUM);\n\n long start = System.currentTimeMillis();\n\n for (int i = 0; i < NUM; i++) {\n threadPoolExecutor.execute(\n () -> {\n inventory--;\n System.out.println(\"线程执行:\" + Thread.currentThread().getName());\n\n countDownLatch.countDown();\n }\n );\n }\n\n threadPoolExecutor.shutdown();\n\n try {\n countDownLatch.await();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n long end = System.currentTimeMillis();\n System.out.println(\"执行线程数:\" + NUM + \" 总耗时:\" + (end - start) + \" 库存数为:\" + inventory);\n }",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\r\n\tpublic static void main(String[] args) throws InterruptedException, ExecutionException{\n\t\tExecutorService e = Executors.newFixedThreadPool(2);\r\n//\t\tList<Future> list = new ArrayList<Future>();\r\n\t\tfor(int i=0;i<10;i++){\r\n\t\t\tCallable c = new JavaTestThread(i);\r\n\t\t\tFuture f = e.submit(c);\r\n\t\t\tSystem.out.println(\"-------\"+ f.get().toString());\r\n\t\t}\r\n\t\t\r\n\t\r\n\t\t\r\n\t}",
"public static void main(String args[]) {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n\t\t\n\t\t// Create a list to hold the Future object associated with Callable\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\n\n\t\t/**\n\t\t * Create MyCallable instance using Lambda expression which return\n\t\t * the thread name executing this callable task\n\t\t */\n\t\tCallable<String> callable = () -> {\n\t\t\tThread.sleep(2000);\n\t\t\treturn Thread.currentThread().getName();\n\t\t};\n\t\t\n\t\t/**\n\t\t * Submit Callable tasks to be executed by thread pool\n\t\t * Add Future to the list, we can get return value using Future\n\t\t **/\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tFuture<String> future = executor.submit(callable);\n\t\t\tfutureList.add(future);\n\t\t}\n\t\t\n\t\t/**\n\t\t * Print the return value of Future, notice the output delay\n\t\t * in console because Future.get() waits for task to get completed\n\t\t **/\n\t\tfor (Future<String> future : futureList) {\n\t\t\ttry {\n\t\t\t\tSystem.out.println(new Date() + \" | \" + future.get());\n\t\t\t} catch (InterruptedException | ExecutionException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\t// shut down the executor service.\n\t\texecutor.shutdown();\n\t}",
"private synchronized void execute(TestRunnerThread testRunnerThread) {\n boolean hasSpace = false;\n while(!hasSpace) {\n threadLock.lock();\n try {\n hasSpace = currentThreads.size()<capacity;\n }\n finally {\n threadLock.unlock();\n }\n }\n \n //Adding thread to list and executing it\n threadLock.lock();\n try {\n currentThreads.add(testRunnerThread);\n testRunnerThread.setThreadPoolListener(this);\n Thread thread = new Thread(testRunnerThread);\n //System.out.println(\"Starting thread for \"+testRunnerThread.getTestRunner().getTestName());\n thread.start();\n }\n finally {\n threadLock.unlock();\n }\n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"public static void main(String[] args)\n\t{\n\t\tint coreCount = Runtime.getRuntime().availableProcessors();\n\t\t//Create the pool\n\t\tExecutorService ec = Executors.newCachedThreadPool(); //Executors.newFixedThreadPool(coreCount);\n\t\tfor(int i=0;i<100;i++) \n\t\t{\n\t\t\t//Thread t = new Thread(new Task());\n\t\t\t//t.start();\n\t\t\tec.execute(new Task());\n\t\t\tSystem.out.println(\"Thread Name under main method:-->\"+Thread.currentThread().getName());\n\t\t}\n\t\t\n\t\t//for scheduling tasks\n\t\tScheduledExecutorService service = Executors.newScheduledThreadPool(10);\n\t\tservice.schedule(new Task(), 10, TimeUnit.SECONDS);\n\t\t\n\t\t//task to run repetatively 10 seconds after previous taks completes\n\t\tservice.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\t\t\n\t}",
"public static void main(String[] args){ new ThreadPoolBlockingServer().processRequests(); }",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"@Test\n\tpublic void addNormalConcurrentTP10_1000() throws Exception {\n\t\tExecutorService exec = Executors.newFixedThreadPool(10);\n\t\tfinal AtomicInteger count = new AtomicInteger(0);\n\t\t\n\t\tretryManager.registerCallback(new RetryCallback() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic boolean onEvent(RetryHolder retry) throws Exception {\n\t\t\t\t\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}, TYPE);\n\t\t\n\t\tfor (int i=0;i<1000;i++) {\n\t\t\texec.submit(new Runnable() {\n\t\t\t\t\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\tRetryHolder holder = new RetryHolder(\"id-local\"+ count.getAndIncrement(), TYPE,new Exception(),\"Object\");\n\t\t\t\t\t\n\t\t\t\t\tretryManager.addRetry(holder);\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t\texec.shutdown();\n\t\texec.awaitTermination(10, TimeUnit.SECONDS);\n\t\tint localQueueSize = retryManager.getLocalQueuer().size(TYPE);\n\t\tAssert.assertEquals(0,localQueueSize);\n\t\tAssert.assertEquals(1000, retryManager.getH1().getMap(TYPE).size() );\n\t\t\t\t\n\t\t//synchronous add, check immediately\t\t\n\t\tfor (int i=0;i<1000;i++ ) {\n\t\t\tAssert.assertNotNull(\n\t\t\t\t\tretryManager.getH1().getMap(TYPE).get(\"id-local\"+i)\n\t\t\t\t\t);\n\t\t\tretryManager.removeRetry(\"id-local\"+i, TYPE);\n\t\t}\n\t\t\n\t}",
"protected abstract void createPool();",
"public static void main(String[] args) {\n ExecutorService threadPool = Executors.newCachedThreadPool();\n\n try{\n for (int i = 0; i < 10; i++) {\n threadPool.execute(() ->{\n System.out.println(Thread.currentThread().getName()+\"\\t 办理业务\");\n });\n //try {TimeUnit.SECONDS.sleep(1); } catch (InterruptedException e) {e.printStackTrace();}\n }\n\n } catch (Exception e) {\n e.printStackTrace();\n }finally {\n threadPool.shutdown();\n }\n\n\n\n }",
"public ThreadPool()\r\n {\r\n // 20 seconds of inactivity and a worker gives up\r\n suicideTime = 20000;\r\n // half a second for the oldest job in the queue before\r\n // spawning a worker to handle it\r\n spawnTime = 500;\r\n jobs = null;\r\n activeThreads = 0;\r\n askedToStop = false;\r\n }",
"@Override\n\tpublic ThreadPoolExecutor getThreadPool(final HystrixThreadPoolKey threadPoolKey,\n\t\t\tfinal HystrixProperty<Integer> corePoolSize, final HystrixProperty<Integer> maximumPoolSize,\n\t\t\tfinal HystrixProperty<Integer> keepAliveTime, final TimeUnit unit,\n\t\t\tfinal BlockingQueue<Runnable> workQueue) {\n\n\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - default [threadPoolKey=\" + threadPoolKey.name() + \", corePoolSize=\"\n\t\t\t\t+ corePoolSize.get() + \", maximumPoolSize=\" + maximumPoolSize.get() + \", keepAliveTime=\"\n\t\t\t\t+ keepAliveTime.get() + \", unit=\" + unit.name() + \"], override with [threadPoolKey=\"\n\t\t\t\t+ threadPoolKey.name() + \", corePoolSize=\" + CORE_POOL_SIZE + \", maximumPoolSize=\" + MAX_POOL_SIZE\n\t\t\t\t+ \", keepAliveTime=\" + KEEP_ALIVE_TIME + \", unit=\" + TimeUnit.SECONDS.name() + \"]\");\n\n\t\tif (threadFactory != null) {\n\t\t\t// All threads will run as part of this application component.\n\t\t\tfinal ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(CORE_POOL_SIZE, MAX_POOL_SIZE,\n\t\t\t\t\tKEEP_ALIVE_TIME, TimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(BLOCKING_QUEUE_SIZE),\n\t\t\t\t\tthis.threadFactory);\n\n\t\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - initialized threadpool executor [threadPoolKey=\"\n\t\t\t\t\t+ threadPoolKey.name() + \"]\");\n\n\t\t\treturn threadPoolExecutor;\n\t\t} else {\n\t\t\tLOGGER.warn(LOG_PREFIX + \"getThreadPool - fallback to Hystrix default thread pool executor.\");\n\n\t\t\treturn super.getThreadPool(threadPoolKey, corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue);\n\t\t}\n\t}",
"int getExecutorPoolSize();",
"private static void threadPoolWithSubmit() throws InterruptedException, ExecutionException {\n Executor executor = Executors.newFixedThreadPool(1);\n Callable<String> callable=()->{\n try{\n Thread.sleep(4000);\n System.out.println(\"In callable\");\n Thread.sleep(4000);\n System.out.println(\"In runnable for task id 1\");\n }catch(Exception e){\n e.printStackTrace();\n }\n return \"success\";\n };\n Future<String> future =((ExecutorService) executor).submit(callable);\n System.out.println(\"Future result - \"+future.get()+\" Future is blocking as it blocks until result is obtained\");\n System.out.println(\"End of method \");\n ((ExecutorService) executor).shutdown();\n /*Output\n In callable\n In runnable for task id 1\n Future result - success Future is blocking as it blocks until result is obtained\n End of method\n */\n }",
"public void runTask(Runnable task) {\n\t\tthreadPool.execute(task);\r\n\t\t// System.out.println(\"Queue Size after assigning the\r\n\t\t// task..\"+queue.size() );\r\n\t\t// System.out.println(\"Pool Size after assigning the\r\n\t\t// task..\"+threadPool.getActiveCount() );\r\n\t\t// System.out.println(\"Task count..\"+threadPool.getTaskCount() );\r\n\t\tSystem.out.println(\"Task count..\" + queue.size());\r\n\r\n\t}",
"public void testNewCachedThreadPool3() {\n try {\n ExecutorService e = Executors.newCachedThreadPool(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(2, 2, 0, TimeUnit.NANOSECONDS, new ArrayBlockingQueue<>(10));\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"all task over!\");\n threadPoolExecutor.shutdown();\n }",
"public MultiThreadBatchTaskEngine(int aNThreads)\n {\n setMaxThreads(aNThreads);\n }",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"private Thread[] newThreadArray() { \r\n\t int n_cpus = Runtime.getRuntime().availableProcessors(); \r\n\t return new Thread[n_cpus]; \r\n\t }",
"private ExecutorService getDroneThreads() {\n\t\treturn droneThreads;\n\t}",
"public static void testES() {\n ExecutorService es = Executors.newFixedThreadPool(2);\n for (int i = 0; i < 10; i++)\n es.execute(new TestTask());\n }",
"public static void main(String[] args) {\n\n ScheduledExecutorService service = Executors.newScheduledThreadPool(4);\n\n //task to run after 10 seconds delay\n service.schedule(new Task(), 10, TimeUnit.SECONDS);\n\n //task to repeatedly every 10 seconds\n service.scheduleAtFixedRate(new Task(), 15, 10, TimeUnit.SECONDS);\n\n //task to run repeatedly 10 seconds after previous task completes\n service.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\n\n for (int i = 0; i < 100; i++) {\n System.out.println(\"task number - \" + i + \" \");\n service.execute(new Task());\n }\n System.out.println(\"Thread name: \" + Thread.currentThread().getName());\n\n }",
"public static void main(String[] args) {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(3);\n scheduledThreadPoolExecutor.setRemoveOnCancelPolicy(true);\n SystemOutUtil.println(\"start schedule\");\n scheduledThreadPoolExecutor.schedule(new DelayCallableTask(), 1000, TimeUnit.MILLISECONDS);\n RunnableScheduledFuture<?> rateFuture =\n (RunnableScheduledFuture<?>) scheduledThreadPoolExecutor\n .scheduleAtFixedRate(new FixRateRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n ScheduledFuture delayFuture =\n scheduledThreadPoolExecutor.scheduleWithFixedDelay(new FixDelayRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n SystemOutUtil.println(\"end schedule\");\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"start stop\");\n\n// scheduledThreadPoolExecutor.remove(rateFuture); // 无效\n rateFuture.cancel(false);\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n scheduledThreadPoolExecutor.shutdown();\n return;\n }",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"private void run() {\n log.log(Level.INFO, \"Starting multiple evaluation of {0} tasks\", tasks.size());\n boolean done = tasks.isEmpty();\n while (!done) {\n boolean hasFreeTasks = true;\n while (hasCapacity() && hasFreeTasks) {\n File task = getFreeTask();\n if (task == null) {\n hasFreeTasks = false;\n } else {\n EvaluatorHandle handle = new EvaluatorHandle();\n if (handle.createEvaluator(task, log, isResume)) {\n log.fine(\"Created new evaluation handler\");\n evaluations.add(handle);\n }\n }\n }\n\n log.log(Level.INFO, \"Tasks in progress: {0}, Unfinished tasks: {1}\", new Object[]{evaluations.size(), tasks.size()});\n try {\n Thread.sleep(5000);\n } catch (InterruptedException ex) {\n //Bla bla\n }\n checkRunningEvaluations();\n done = tasks.isEmpty();\n }\n\n }",
"int getExecutorCorePoolSize();",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"int getExecutorLargestPoolSize();",
"protected ThreadPool getPool()\r\n {\r\n return threadPool_;\r\n }",
"@Test\n @DisplayName(\"Invoke Any\")\n void invokeAny() throws ExecutionException, InterruptedException {\n ExecutorService executor = Executors.newWorkStealingPool();\n\n List<Callable<String>> callables = Arrays.asList(\n callable(\"task1\", 2),\n callable(\"task2\", 1),\n callable(\"task3\", 3));\n\n String result = executor.invokeAny(callables);\n assertEquals(\"task2\", result);\n }",
"int getExecutorMaximumPoolSize();",
"public static void main(String args[]) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n //create a list to hold the Future object associated with Callable\n Map<Integer, Future<String>> map = new HashMap<Integer, Future<String>>();\n //Create MyCallable instance\n for (int i = 0; i < 10; i++) {\n Callable<String> callable = new MyCallable(\"\" + i);\n //submit Callable tasks to be executed by thread pool\n Future<String> future = executor.submit(callable);\n\n //add Future to the list, we can get return value using Future\n map.put(i, future);\n }\n System.out.println(\"Assigned\");\n map.forEach(MyCallable::handleResult);\n// for (Future<String> fut : list) {\n// try {\n// //print the return value of Future, notice the output delay in console\n// // because Future.get() waits for task to get completed\n// System.out.println(new Date() + \"::\" + fut.get());\n// } catch (InterruptedException e) {\n// e.printStackTrace();\n// } catch (ExecutionException e) {\n// System.out.println(\"Handled in main thread - Crash\");\n// }\n// }\n System.out.println(\"About to shutdown\");\n //shut down the executor service now\n executor.shutdown();\n System.out.println(\"Shutdown\");\n }",
"int getPoolSize();",
"@Bean(destroyMethod = \"shutdown\")\n public Executor threadPoolTaskExecutor(@Value(\"${thread.size}\") String argThreadSize) {\n this.threadSize = Integer.parseInt(argThreadSize);\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(this.threadSize);\n executor.setKeepAliveSeconds(15);\n executor.initialize();\n return executor;\n }",
"@Bean(name = \"process-response\")\n\tpublic Executor threadPoolTaskExecutor() {\n\t\tThreadPoolTaskExecutor x = new ThreadPoolTaskExecutor();\n\t\tx.setCorePoolSize(poolProcessResponseCorePoolSize);\n\t\tx.setMaxPoolSize(poolProcessResponseMaxPoolSize);\n\t\treturn x;\n\t}",
"public static void main(String[] args){\n\t\tint tamPool=Integer.parseInt(args[0]);\r\n\t\tSystem.out.println(\"Cuantos numero quiere lanzar?\");\r\n\t\tn=Integer.parseInt(args[1]);\r\n\t\tlong time_start, time_end;\r\n\t\tint numeros=n/tamPool;\r\n\t\tThread []hilos= new Thread[tamPool];\r\n\t\ttime_start = System.currentTimeMillis();\r\n\t\t//System.out.println(\"Numeros: \"+numeros);\r\n\t\tint grueso=numeros;\r\n\t\t\t//ExecutorService exec = Executors.newCachedThreadPool();\r\n\t\t\tfor(int i=0;i<tamPool;++i){\r\n\t\t\t\thilos[i]= new Thread(new piParalelo(numeros));\r\n\t\t\t\thilos[i].start();\r\n\t\t\t//System.out.println(i+\" : \"+grueso);\r\n\t\t\t//exec.execute(new piParalelo(numeros));\r\n\t\t\tif((grueso+numeros)>=n)numeros=n-grueso;\r\n\t\t\telse grueso+=numeros;\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\tfor(int i=0;i<tamPool;++i){\r\n\t\t\t\ttry{\r\n\t\t\t\thilos[i].join();\r\n\t\t\t\t}catch(Exception e){}\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t/**try{\r\n\t\t\texec.shutdown();\r\n\t\t\texec.awaitTermination(1, TimeUnit.DAYS);\r\n\t\t\t}catch(Exception e){}*/\r\n\t\tPI=4*((double)atomico.get()/(double)n);\r\n\t\tSystem.out.println(\"La aproximacion del numero PI por montecarlo es: \"+PI);\r\n\t\ttime_end = System.currentTimeMillis();\r\n\t\tSystem.out.println(\"the task has taken \"+ ( time_end - time_start ) +\" milliseconds\");\r\n\t\t\t\t\t\t\t}",
"public static void main(String[] args) {\n Runnable r1 = () -> {\n String thread = Thread.currentThread().getName();\n log.info(\"{} getting lock\", thread);\n lock.lock();\n log.info(\"{}, increment to {}\", thread, count++);\n log.info(\"{} unlock\", thread);\n lock.unlock();\n\n };\n\n for (int i=0; i <= 5; i++){\n executorService.execute(r1);\n }\n\n executorService.shutdown();\n\n }",
"public void testExecuteInParallel_Collection() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks );\n assertEquals( result.size(), tasks.size() );\n }",
"public void execute(final DispatchTask task, final DeliverTask callback)\n {\n // Note that we associate a callback with a task via the thread used to \n // execute the task. In general, a free slot in the pool (i.e., m_pool[i] is \n // null) can be used to set-up a new thread. Also note that we need to \n // update the LRU index if we change the pool.\n synchronized(m_lock)\n {\n if(m_closed)\n {\n // We are closed hence, spin-of a new thread for the new task.\n final PooledThread result = new PooledThread();\n \n // Set-up the thread and associate the task with the callback.\n result.reset(task, callback);\n \n // release the thread immediately since we don't pool anymore.\n result.release();\n \n return;\n }\n \n // Search in the pool for a free thread.\n for (int i = 0; i < m_pool.length; i++)\n {\n // o.k. we found a free slot now set-up a new thread for it.\n if (null == m_pool[i])\n {\n m_pool[i] = new PooledThread();\n\n m_pool[i].reset(task, callback);\n \n m_index.add(new Integer(i));\n \n return;\n }\n else if (m_pool[i].available())\n {\n // we found a free thread now set it up.\n m_pool[i].reset(task, callback);\n \n final Integer idx = new Integer(i);\n \n m_index.remove(idx);\n \n m_index.add(idx);\n \n return;\n }\n }\n\n // The pool is full and no threads are available hence, spin-off a new\n // thread and add it to the pool while decoupling the least recently used\n // one. This assumes that older threads are likely to take longer to \n // become available again then younger ones.\n final int pos = ((Integer) m_index.remove(0)).intValue();\n \n m_index.add(new Integer(pos));\n \n m_pool[pos].release();\n\n m_pool[pos] = new PooledThread();\n\n m_pool[pos].reset(task, callback);\n }\n }",
"public static void main(String[] args) {\n\t\tExecutorService executor = Executors.newFixedThreadPool(1);\r\n\t\t\r\n\t\t// Submit tasks to the executor, which is also the pool?\r\n\t\texecutor.execute(new PrintChar('a', 100));\r\n\t\texecutor.execute(new PrintChar('b', 100));\r\n\t\texecutor.execute(new PrintNum(100));\r\n\t\t\r\n\t\t// Shutdown the executor\r\n\t\texecutor.shutdown();\r\n\t\t\r\n\t}",
"public void startThread() \n { \n ExecutorService taskList = \n Executors.newFixedThreadPool(2); \n for (int i = 0; i < 5; i++) \n { \n // Makes tasks available for execution. \n // At the appropriate time, calls run \n // method of runnable interface \n taskList.execute(new Counter(this, i + 1, \n \"task \" + (i + 1))); \n } \n \n // Shuts the thread that's watching to see if \n // you have added new tasks. \n taskList.shutdown(); \n }",
"static ExecutorService boundedNamedCachedExecutorService(int maxThreadBound, String poolName, long keepalive, int queueSize, RejectedExecutionHandler abortPolicy) {\n\n ThreadFactory threadFactory = new NamedThreadFactory(poolName);\n LinkedBlockingQueue<Runnable> queue = new LinkedBlockingQueue<Runnable>(queueSize);\n\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(\n maxThreadBound,\n maxThreadBound,\n keepalive,\n TimeUnit.SECONDS,\n queue,\n threadFactory,\n abortPolicy\n );\n\n threadPoolExecutor.allowCoreThreadTimeOut(true);\n\n return threadPoolExecutor;\n }",
"void submitAndWaitForAll(Iterable<Runnable> tasks);",
"public abstract void submit(Runnable runnable);",
"@Override\n\t\t\tprotected void beforeExecute(Thread t, Runnable r) {\n\t\t\t\tint qsize = getQueue().size();\n\t\t\t\tif(initCorePoolSize>0&&getCorePoolSize()<getMaximumPoolSize()\n\t\t\t\t\t&& qsize > 0 && (qsize%divisor) == 0){\n\t\t\t\t\tsetCorePoolSize(getCorePoolSize()+1); // 进行动态增加\n\t\t\t\t}\n\t\t\t}",
"public interface Executor<Work extends Runnable> {\n void execute(Work work);\n\n void shutdown();\n\n void addWorks(Work work);\n\n void removeWorks(int num);\n\n int getWorkSize();\n}",
"private void completionService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n ExecutorCompletionService<String> completionService = new ExecutorCompletionService<String>(executor);\n for (final String printRequest : printRequests) {\n// ListenableFuture<String> printer = completionService.submit(new Printer(printRequest));\n completionService.submit(new Printer(printRequest));\n }\n try {\n for (int t = 0, n = printRequests.size(); t < n; t++) {\n Future<String> f = completionService.take();\n System.out.print(f.get());\n }\n } catch (InterruptedException | ExecutionException e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n\n }",
"public static void main(String [] args) {\n\t\tExecutorService executor= Executors.newFixedThreadPool(2);\n\t\t\n\t\t//add the tasks that the threadpook executor should run\n\t\tfor(int i=0;i<5;i++) {\n\t\t\texecutor.submit(new Processor(i));\n\t\t}\n\t\t\n\t\t//shutdown after all have started\n\t\texecutor.shutdown();\n\t\t\n\t\tSystem.out.println(\"all submitted\");\n\t\t\n\t\t//wait 1 day till al the threads are finished \n\t\ttry {\n\t\t\texecutor.awaitTermination(1, TimeUnit.DAYS);\n\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"all completed\");\n\t\t\n\t}",
"ScheduledExecutorService getExecutorService();"
] | [
"0.7172644",
"0.6886567",
"0.685927",
"0.6632945",
"0.66283894",
"0.65816295",
"0.65438056",
"0.65070564",
"0.6497593",
"0.6392227",
"0.62993705",
"0.6291912",
"0.6286407",
"0.62736887",
"0.6263639",
"0.624488",
"0.62435627",
"0.6236415",
"0.62149256",
"0.6213128",
"0.6204833",
"0.62039447",
"0.61891305",
"0.61829364",
"0.61556846",
"0.6134244",
"0.61209726",
"0.61172026",
"0.6112416",
"0.6102933",
"0.6099736",
"0.6094862",
"0.60154235",
"0.60151666",
"0.59941113",
"0.59897035",
"0.5981467",
"0.5965432",
"0.5961729",
"0.59072655",
"0.5898115",
"0.58814925",
"0.58754975",
"0.5873819",
"0.587036",
"0.58631307",
"0.58404744",
"0.5829885",
"0.5816319",
"0.581423",
"0.58135474",
"0.58117634",
"0.58016014",
"0.57759535",
"0.5775496",
"0.57729626",
"0.5771336",
"0.57706213",
"0.5761487",
"0.57481915",
"0.5733594",
"0.57238984",
"0.56963736",
"0.56960773",
"0.5688067",
"0.5682254",
"0.5661289",
"0.56576484",
"0.5652798",
"0.56492656",
"0.5639505",
"0.5631428",
"0.56196713",
"0.5619175",
"0.5609097",
"0.5603139",
"0.5602085",
"0.5592923",
"0.5586346",
"0.5585701",
"0.55783266",
"0.55768704",
"0.55744517",
"0.5572468",
"0.556749",
"0.5565649",
"0.5560318",
"0.5553363",
"0.55471945",
"0.55426306",
"0.5533042",
"0.55275965",
"0.55274445",
"0.5518579",
"0.5515505",
"0.5508052",
"0.55056506",
"0.5505531",
"0.5499132",
"0.54980075"
] | 0.7154762 | 1 |
A new newFixedThreadPool with given ThreadFactory can execute runnables | public void testNewFixedThreadPool2() {
final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());
try (PoolCleaner cleaner = cleaner(e)) {
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"private void initThreadPool(int numOfThreadsInPool, int[][] resultMat, Observer listener) {\n for(int i=0;i<numOfThreadsInPool; i++){\r\n PoolThread newPoolThread = new PoolThread(m_TaskQueue, resultMat);\r\n newPoolThread.AddResultMatListener(listener);\r\n m_Threads.add(newPoolThread);\r\n }\r\n // Start all Threads:\r\n for(PoolThread currThread: m_Threads){\r\n currThread.start();\r\n }\r\n }",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public static void main(String[] args) {\n SomeRunnable obj1 = new SomeRunnable();\n SomeRunnable obj2 = new SomeRunnable();\n SomeRunnable obj3 = new SomeRunnable();\n \n System.out.println(\"obj1 = \"+obj1);\n System.out.println(\"obj2 = \"+obj2);\n System.out.println(\"obj3 = \"+obj3);\n \n //Create fixed Thread pool, here pool of 2 thread will created\n ExecutorService pool = Executors.newFixedThreadPool(3);\n ExecutorService pool2 = Executors.newFixedThreadPool(2);\n pool.execute(obj1);\n pool.execute(obj2);\n pool2.execute(obj3);\n \n pool.shutdown();\n pool2.shutdown();\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public interface RunnableFactory {\n\n\t/**\n\t * Yields a new instance of the runnable.\n\t */\n\n Runnable mk();\n}",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"public static void main(String[] args) {\n\t\tExecutorService pool = Executors.newFixedThreadPool(3);\n\t\t//ExecutorService pool = Executors.newSingleThreadExecutor();\n\t\t\n\t\tExecutorService pool2 = Executors.newCachedThreadPool();\n\t\t//this pool2 will add more thread into pool(when no other thread running), the new thread do not need to wait.\n\t\t//pool2 will delete un runing thread(unrun for 60 secs)\n\t\tThread t1 = new MyThread();\n\t\tThread t2 = new MyThread();\n\t\tThread t3 = new MyThread();\n\n\t\tpool.execute(t1);\n\t\tpool.execute(t2);\n\t\tpool.execute(t3);\n\t\tpool.shutdown();\n\t\t\n\t}",
"public interface ThreadPool<Job extends Runnable> {\n\n void execute(Job job);\n\n void shutDown();\n\n void addWorkers(int num);\n\n void removeWorkers(int num);\n\n int getJobSize();\n\n}",
"public static void main(String[] args) {\n\t\tBlockingQueue queue = new LinkedBlockingQueue(4);\n\n\t\t// Thread factory below is used to create new threads\n\t\tThreadFactory thFactory = Executors.defaultThreadFactory();\n\n\t\t// Rejection handler in case the task get rejected\n\t\tRejectTaskHandler rth = new RejectTaskHandler();\n\t\t// ThreadPoolExecutor constructor to create its instance\n\t\t// public ThreadPoolExecutor(int corePoolSize,int maximumPoolSize,long\n\t\t// keepAliveTime,\n\t\t// TimeUnit unit,BlockingQueue workQueue ,ThreadFactory\n\t\t// threadFactory,RejectedExecutionHandler handler) ;\n\t\tThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(1, 2, 10L, TimeUnit.MILLISECONDS, queue,\n\t\t\t\tthFactory, rth);\n\n\t\tfor (int i = 1; i <= 10; i++) {\n\t\t\tDataFileReader df = new DataFileReader(\"File \" + i);\n\t\t\tSystem.out.println(\"A new file has been added to read : \" + df.getFileName());\n\t\t\t// Submitting task to executor\n\t\t\tthreadPoolExecutor.execute(df);\n\t\t}\n\t\tthreadPoolExecutor.shutdown();\n\t}",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }",
"public ThreadPool getDefaultThreadPool();",
"public static ThreadPoolExecutor getBoundedCachedThreadPool(\n\t\t\tint maxCachedThread, long timeout, TimeUnit unit,\n\t\t\tThreadFactory threadFactory) {\n\t\tThreadPoolExecutor boundedCachedThreadPool = new ThreadPoolExecutor(\n\t\t\t\tmaxCachedThread, maxCachedThread, timeout, unit,\n\t\t\t\tnew LinkedBlockingQueue<Runnable>(), threadFactory);\n\t\t// allow the core pool threads timeout and terminate\n\t\tboundedCachedThreadPool.allowCoreThreadTimeOut(true);\n\t\treturn boundedCachedThreadPool;\n\t}",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"ActorThreadPool getThreadPool();",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"public void testForNThreads();",
"@Override\n\tpublic ThreadPoolExecutor getThreadPool(final HystrixThreadPoolKey threadPoolKey,\n\t\t\tfinal HystrixProperty<Integer> corePoolSize, final HystrixProperty<Integer> maximumPoolSize,\n\t\t\tfinal HystrixProperty<Integer> keepAliveTime, final TimeUnit unit,\n\t\t\tfinal BlockingQueue<Runnable> workQueue) {\n\n\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - default [threadPoolKey=\" + threadPoolKey.name() + \", corePoolSize=\"\n\t\t\t\t+ corePoolSize.get() + \", maximumPoolSize=\" + maximumPoolSize.get() + \", keepAliveTime=\"\n\t\t\t\t+ keepAliveTime.get() + \", unit=\" + unit.name() + \"], override with [threadPoolKey=\"\n\t\t\t\t+ threadPoolKey.name() + \", corePoolSize=\" + CORE_POOL_SIZE + \", maximumPoolSize=\" + MAX_POOL_SIZE\n\t\t\t\t+ \", keepAliveTime=\" + KEEP_ALIVE_TIME + \", unit=\" + TimeUnit.SECONDS.name() + \"]\");\n\n\t\tif (threadFactory != null) {\n\t\t\t// All threads will run as part of this application component.\n\t\t\tfinal ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(CORE_POOL_SIZE, MAX_POOL_SIZE,\n\t\t\t\t\tKEEP_ALIVE_TIME, TimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(BLOCKING_QUEUE_SIZE),\n\t\t\t\t\tthis.threadFactory);\n\n\t\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - initialized threadpool executor [threadPoolKey=\"\n\t\t\t\t\t+ threadPoolKey.name() + \"]\");\n\n\t\t\treturn threadPoolExecutor;\n\t\t} else {\n\t\t\tLOGGER.warn(LOG_PREFIX + \"getThreadPool - fallback to Hystrix default thread pool executor.\");\n\n\t\t\treturn super.getThreadPool(threadPoolKey, corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue);\n\t\t}\n\t}",
"public ThreadPoolExecutor create_blocking_thread_pool( String name, int threads, int queue_size )\n {\n NamedThreadPoolExecutor ret = new NamedThreadPoolExecutor( name, queue_size, threads, threads, 60, TimeUnit.MINUTES);\n \n pool_list.add( ret );\n\n return ret;\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executorService = new ThreadPoolExecutor(3, 10, 1L, TimeUnit.SECONDS,\n new LinkedBlockingQueue<>(20),\n Executors.defaultThreadFactory(),\n new ThreadPoolExecutor.AbortPolicy());\n ABC abc = new ABC();\n try {\n for (int i = 1; i <= 10; i++) {\n executorService.execute(abc::print5);\n executorService.execute(abc::print10);\n executorService.execute(abc::print15);\n }\n\n }finally {\n executorService.shutdown();\n }\n }",
"public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }",
"private static void threadPoolWithExecute() {\n\n Executor executor = Executors.newFixedThreadPool(3);\n IntStream.range(1, 10)\n .forEach((i) -> {\n executor.execute(() -> {\n System.out.println(\"started task for id - \"+i);\n try {\n if (i == 8) {\n Thread.sleep(4000);\n } else {\n Thread.sleep(1000);\n }\n System.out.println(\"In runnable task for id -\" + i);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n });\n System.out.println(\"End of method .THis gets printed immdly since execute is not blocking call\");\n }",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"public boolean newThreadPoolAvailable() {\n\t\tif (this.serverConnectorUsed+1 <= MAX_THREADS) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"public void testExecuteInParallel_Collection_ThreadPoolExecutor() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks, ParallelUtil.createThreadPool( 1 ) );\n assertEquals( result.size(), tasks.size() );\n }",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"TaskFactory getTaskFactory();",
"public MultiThreadBatchTaskEngine(int aNThreads)\n {\n setMaxThreads(aNThreads);\n }",
"private TestRunnableResult runRunnable(ModelFactory factory, TestRunnable runnable) {\n\t\tTestRunnableResult result = new TestRunnableResult();\n\t\tlong startMem, endMem, start, end;\n\t\tstartMem = ManagementFactory.getMemoryMXBean().getHeapMemoryUsage().getUsed();\n\t\tstart = System.currentTimeMillis();\n\t\tresult.returned = runnable.run(factory);\n\t\tend = System.currentTimeMillis();\n\t\tresult.usedTime = end - start;\n\t\tendMem = ManagementFactory.getMemoryMXBean().getHeapMemoryUsage().getUsed();\n\t\tresult.usedMemory = endMem - startMem;\n\t\treturn result;\n\t}",
"public LocalEventLoopGroup(int nThreads, ThreadFactory threadFactory) {\n/* 51 */ super(nThreads, threadFactory, new Object[0]);\n/* */ }",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\r\n\tpublic static void main(String[] args) throws InterruptedException, ExecutionException{\n\t\tExecutorService e = Executors.newFixedThreadPool(2);\r\n//\t\tList<Future> list = new ArrayList<Future>();\r\n\t\tfor(int i=0;i<10;i++){\r\n\t\t\tCallable c = new JavaTestThread(i);\r\n\t\t\tFuture f = e.submit(c);\r\n\t\t\tSystem.out.println(\"-------\"+ f.get().toString());\r\n\t\t}\r\n\t\t\r\n\t\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\r\n\t\tMyThread thread = new MyThread();\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t}",
"public static void main(String[] args)\n {\n Runnable r1 = new Task1();\n // Creates Thread task\n Task2 r2 = new Task2();\n ExecutorService pool = Executors.newFixedThreadPool(MAX_T);\n\n pool.execute(r1);\n r2.start();\n\n // pool shutdown\n pool.shutdown();\n }",
"protected EventExecutor newChild(ThreadFactory threadFactory, Object... args) throws Exception {\n/* 57 */ return (EventExecutor)new LocalEventLoop(this, threadFactory);\n/* */ }",
"private TestAcceptFactory() {\n this._pool = new DirectExecutor();\n }",
"public static void main(String args[]) {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n\t\t\n\t\t// Create a list to hold the Future object associated with Callable\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\n\n\t\t/**\n\t\t * Create MyCallable instance using Lambda expression which return\n\t\t * the thread name executing this callable task\n\t\t */\n\t\tCallable<String> callable = () -> {\n\t\t\tThread.sleep(2000);\n\t\t\treturn Thread.currentThread().getName();\n\t\t};\n\t\t\n\t\t/**\n\t\t * Submit Callable tasks to be executed by thread pool\n\t\t * Add Future to the list, we can get return value using Future\n\t\t **/\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tFuture<String> future = executor.submit(callable);\n\t\t\tfutureList.add(future);\n\t\t}\n\t\t\n\t\t/**\n\t\t * Print the return value of Future, notice the output delay\n\t\t * in console because Future.get() waits for task to get completed\n\t\t **/\n\t\tfor (Future<String> future : futureList) {\n\t\t\ttry {\n\t\t\t\tSystem.out.println(new Date() + \" | \" + future.get());\n\t\t\t} catch (InterruptedException | ExecutionException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\t// shut down the executor service.\n\t\texecutor.shutdown();\n\t}",
"@Bean(destroyMethod = \"shutdown\")\n public Executor threadPoolTaskExecutor(@Value(\"${thread.size}\") String argThreadSize) {\n this.threadSize = Integer.parseInt(argThreadSize);\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(this.threadSize);\n executor.setKeepAliveSeconds(15);\n executor.initialize();\n return executor;\n }",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"public ThreadFactory threadFactory() {\n return threadFactory_;\n }",
"public interface IHttpThreadExecutor {\n public void addTask(Runnable runnable);\n}",
"private synchronized void execute(TestRunnerThread testRunnerThread) {\n boolean hasSpace = false;\n while(!hasSpace) {\n threadLock.lock();\n try {\n hasSpace = currentThreads.size()<capacity;\n }\n finally {\n threadLock.unlock();\n }\n }\n \n //Adding thread to list and executing it\n threadLock.lock();\n try {\n currentThreads.add(testRunnerThread);\n testRunnerThread.setThreadPoolListener(this);\n Thread thread = new Thread(testRunnerThread);\n //System.out.println(\"Starting thread for \"+testRunnerThread.getTestRunner().getTestName());\n thread.start();\n }\n finally {\n threadLock.unlock();\n }\n }",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"public static ScheduledExecutorService createNewScheduler() {\n return Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessors() * 2);\n }",
"public static void main(String[] args)\n\t{\n\t\tint coreCount = Runtime.getRuntime().availableProcessors();\n\t\t//Create the pool\n\t\tExecutorService ec = Executors.newCachedThreadPool(); //Executors.newFixedThreadPool(coreCount);\n\t\tfor(int i=0;i<100;i++) \n\t\t{\n\t\t\t//Thread t = new Thread(new Task());\n\t\t\t//t.start();\n\t\t\tec.execute(new Task());\n\t\t\tSystem.out.println(\"Thread Name under main method:-->\"+Thread.currentThread().getName());\n\t\t}\n\t\t\n\t\t//for scheduling tasks\n\t\tScheduledExecutorService service = Executors.newScheduledThreadPool(10);\n\t\tservice.schedule(new Task(), 10, TimeUnit.SECONDS);\n\t\t\n\t\t//task to run repetatively 10 seconds after previous taks completes\n\t\tservice.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\t\t\n\t}",
"public static void main(String[] args) {\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\r\n\r\n\t\t//collection of multiple tasks which we are supposed to give to thread pool to perform\r\n\t\tList<CallableDemo> taskList = new ArrayList<CallableDemo>();\r\n\t\t//adding multiple tasks to collection (tasks are created using 'Callable' Interface.\r\n\t\ttaskList.add(new CallableDemo(\"first\"));\r\n\t\ttaskList.add(new CallableDemo(\"second\"));\r\n\t\ttaskList.add(new CallableDemo(\"third\"));\r\n\t\ttaskList.add(new CallableDemo(\"fourth\"));\r\n\t\ttaskList.add(new CallableDemo(\"fifth\"));\r\n\t\ttaskList.add(new CallableDemo(\"sixth\"));\r\n\t\ttaskList.add(new CallableDemo(\"seventh\"));\r\n\r\n\t\t//creating a thread pool of size four\r\n\t\tExecutorService threadPool = Executors.newFixedThreadPool(4);\r\n\t\t\r\n\t\tfor (CallableDemo task : taskList) {\r\n\t\t\tfutureList.add(threadPool.submit(task));\r\n\t\t}\r\n threadPool.shutdown();\r\n\t\tfor (Future<String> future : futureList) {\r\n\t\t\ttry {\r\n//\t\t\t\t System.out.println(future.get());\r\n\t\t\t\tSystem.out.println(future.get(1L, TimeUnit.SECONDS));\r\n\t\t\t} catch (InterruptedException | ExecutionException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}catch (TimeoutException e) {\r\n\t\t\t\tSystem.out.println(\"Sorry already waited for result for 1 second , can't wait anymore...\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t}",
"private void init(int threadCount, Type type) {\r\n //The backend starts to polling threads.\r\n mPoolThread=new Thread(){\r\n @Override\r\n public void run() {\r\n Looper.prepare();\r\n mPoolThreadHandler=new Handler(){\r\n @Override\r\n public void handleMessage(Message msg) {\r\n //take a thread from the thread pool and execute it.\r\n mThreadPool.execute(getTask());\r\n try {\r\n mSemaphoreThreadPool.acquire();\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n };\r\n //if this thread is finished, release a signal to the handler.\r\n mSemaphorePoolThreadHandler.release();\r\n Looper.loop();\r\n }\r\n };\r\n mPoolThread.start();\r\n //Get the maximum available memory for our service.\r\n int maxMemory= (int) Runtime.getRuntime().maxMemory();\r\n int cacheMemory = maxMemory / 8;//8\r\n mLruCache=new LruCache<String, Bitmap>(cacheMemory){\r\n @Override\r\n protected int sizeOf(String key, Bitmap value) {\r\n return value.getRowBytes()*value.getHeight();\r\n }\r\n };\r\n mThreadPool= Executors.newFixedThreadPool(threadCount);\r\n mTaskQueue=new LinkedList<>();\r\n mType=type==null? Type.LIFO:type;\r\n mSemaphoreThreadPool=new Semaphore(threadCount);\r\n\r\n }",
"public Builder setThreadFactory(ThreadFactory threadFactory) {\n threadFactory_ = (threadFactory != null) ? threadFactory : Executors.defaultThreadFactory();\n return this;\n }",
"@Bean(name = \"process-response\")\n\tpublic Executor threadPoolTaskExecutor() {\n\t\tThreadPoolTaskExecutor x = new ThreadPoolTaskExecutor();\n\t\tx.setCorePoolSize(poolProcessResponseCorePoolSize);\n\t\tx.setMaxPoolSize(poolProcessResponseMaxPoolSize);\n\t\treturn x;\n\t}",
"public void testNewCachedThreadPool3() {\n try {\n ExecutorService e = Executors.newCachedThreadPool(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public ThreadPool()\r\n {\r\n // 20 seconds of inactivity and a worker gives up\r\n suicideTime = 20000;\r\n // half a second for the oldest job in the queue before\r\n // spawning a worker to handle it\r\n spawnTime = 500;\r\n jobs = null;\r\n activeThreads = 0;\r\n askedToStop = false;\r\n }",
"ScheduledExecutorService getExecutorService();",
"public static ThreadPool getInstance()\r\n {\r\n if(instance == null)\r\n {\r\n instance = new ThreadPool();\r\n }\r\n return instance;\r\n }",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n for (int i = 0; i < 10; i++) {\n \tCallable worker = new WorkerThread1(\"\" + i);\n \tFuture future = executor.submit(worker);\n \tSystem.out.println(\"Results\"+future.get());\n //executor.execute(worker);\n }\n executor.shutdown();\n while (!executor.isTerminated()) {\n }\n System.out.println(\"Finished all threads\");\n }",
"private ExecutorService getDroneThreads() {\n\t\treturn droneThreads;\n\t}",
"@Test\n @DisplayName(\"Invoke Any\")\n void invokeAny() throws ExecutionException, InterruptedException {\n ExecutorService executor = Executors.newWorkStealingPool();\n\n List<Callable<String>> callables = Arrays.asList(\n callable(\"task1\", 2),\n callable(\"task2\", 1),\n callable(\"task3\", 3));\n\n String result = executor.invokeAny(callables);\n assertEquals(\"task2\", result);\n }",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"public static void main(String[] args) {\n Runnable runnable = new Runnable() {\n @Override\n public void run() {\n for(int i =0; i<10000; i++){\n System.out.println(\n Thread.currentThread().getId() + \":\" + i\n );\n }\n }\n };\n\n // using functions, a bit cleaner\n Runnable runnable2 = () -> {\n for(int i =0; i<10000; i++){\n System.out.println(\n Thread.currentThread().getId() + \":\" + i\n );\n }\n };\n\n Thread thread = new Thread(runnable);\n thread.start();\n\n Thread thread2 = new Thread(runnable);\n thread2.start();\n\n Thread thread3 = new Thread(runnable);\n thread3.start();\n\n }",
"public void testCastNewSingleThreadExecutor() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n try {\n ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;\n shouldThrow();\n } catch (ClassCastException success) {}\n }\n }",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"public static void testES() {\n ExecutorService es = Executors.newFixedThreadPool(2);\n for (int i = 0; i < 10; i++)\n es.execute(new TestTask());\n }",
"private Thread[] newThreadArray() { \r\n\t int n_cpus = Runtime.getRuntime().availableProcessors(); \r\n\t return new Thread[n_cpus]; \r\n\t }",
"public static void main(String[] args) {\n ExecutorService threadPool = Executors.newCachedThreadPool();\n\n try{\n for (int i = 0; i < 10; i++) {\n threadPool.execute(() ->{\n System.out.println(Thread.currentThread().getName()+\"\\t 办理业务\");\n });\n //try {TimeUnit.SECONDS.sleep(1); } catch (InterruptedException e) {e.printStackTrace();}\n }\n\n } catch (Exception e) {\n e.printStackTrace();\n }finally {\n threadPool.shutdown();\n }\n\n\n\n }",
"public static void main(String[] args) {\n ExecutorService es = Executors.newCachedThreadPool();\n es.execute(new Task(65));\n es.execute(new Task(5));\n System.out.println(\"结束执行!\");\n }",
"public ThreadPoolExecutorTracer(int corePoolSize, int maximumPoolSize, long keepAliveTime,\n TimeUnit unit, BlockingQueue<Runnable> workQueue, ThreadFactory threadFactory) {\n super(corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue, threadFactory);\n }",
"public void startThread() \n { \n ExecutorService taskList = \n Executors.newFixedThreadPool(2); \n for (int i = 0; i < 5; i++) \n { \n // Makes tasks available for execution. \n // At the appropriate time, calls run \n // method of runnable interface \n taskList.execute(new Counter(this, i + 1, \n \"task \" + (i + 1))); \n } \n \n // Shuts the thread that's watching to see if \n // you have added new tasks. \n taskList.shutdown(); \n }",
"public static void main(String[] args){ new ThreadPoolBlockingServer().processRequests(); }",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@Override\n\tpublic Thread newThread(Runnable r) {\n\t\t\n\t\tThread th = new Thread(r,\" custum Thread\");\n\t\treturn th;\n\t}",
"int getExecutorPoolSize();",
"public WildflyHystrixConcurrencyStrategy(final ManagedThreadFactory threadFactory) {\n\t\t//\n\t\t// Used by CDI provider.\n\t\t\n\t\tthis.threadFactory = threadFactory;\n\t}",
"@Override\r\n public Thread newThread(Runnable r) {\n Thread t = new Thread(r, \"example-runner\");\r\n t.setDaemon(true);\r\n return t;\r\n }",
"public interface ThreadExecutor extends Executor {\n}",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"public static void main(String[] args) {\n if(args.length != 1) {\n System.err.println(\"Usage: java Ufficio <numero_persone>\");\n System.exit(1);\n }\n\n int numPersone = Integer.parseInt(args[0]);\n\n // Creo una coda bloccante per memorizzare i task (persone) in attesa nella sala1.\n BlockingQueue<Runnable> sala1 = new LinkedBlockingDeque<Runnable>();\n\n // Creo una coda bloccante per memorizzare i task (persone) in attesa nella sala2.\n BlockingQueue<Runnable> sala2 = new ArrayBlockingQueue<Runnable>(dimSala2);\n\n // Creo un pool di thread con al massimo 'numSportelli' thread.\n ExecutorService sportelli = new ThreadPoolExecutor(\n numSportelli, // Numero di thread da mantenere nel pool.\n numSportelli, // Numero massimo di thread possibili nel pool.\n 0L, // Tempo di keep-alive per i thread.\n TimeUnit.SECONDS,\n sala2, // Coda bloccante per i task.\n new RejectedExecutionHandler() {\n @Override\n public void rejectedExecution(Runnable persona, ThreadPoolExecutor sportelli) {\n try {\n sportelli.getQueue().put(persona);\n } catch(InterruptedException e) {\n System.err.println(\"Interruzione put (sala2).\");\n }\n }\n } // Politica di rifiuto: la persona rifiutata in sala2 aspetta che sia libera\n );\n\n // Creazione dei task (persone).\n for(int i = 1; i <= numPersone; i++) {\n sala1.add(new Persona(i));\n }\n\n // Sposto le persone dalla sala1 in sala2.\n for(int i = 1; i <= numPersone; i++) {\n try {\n sportelli.execute(sala1.take());\n } catch(RejectedExecutionException e) {\n System.err.printf(\"Persona %d: sala2 esaurita\\n\", i);\n } catch(InterruptedException e) {\n e.printStackTrace();\n }\n }\n\n sportelli.shutdown(); // Chiudo gli sportelli, dopo che la sala2 è vuota\n }",
"public static void main(String[] args) {\n\n ScheduledExecutorService service = Executors.newScheduledThreadPool(4);\n\n //task to run after 10 seconds delay\n service.schedule(new Task(), 10, TimeUnit.SECONDS);\n\n //task to repeatedly every 10 seconds\n service.scheduleAtFixedRate(new Task(), 15, 10, TimeUnit.SECONDS);\n\n //task to run repeatedly 10 seconds after previous task completes\n service.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\n\n for (int i = 0; i < 100; i++) {\n System.out.println(\"task number - \" + i + \" \");\n service.execute(new Task());\n }\n System.out.println(\"Thread name: \" + Thread.currentThread().getName());\n\n }",
"public static void main(String [] args) {\n\t\tExecutorService executor= Executors.newFixedThreadPool(2);\n\t\t\n\t\t//add the tasks that the threadpook executor should run\n\t\tfor(int i=0;i<5;i++) {\n\t\t\texecutor.submit(new Processor(i));\n\t\t}\n\t\t\n\t\t//shutdown after all have started\n\t\texecutor.shutdown();\n\t\t\n\t\tSystem.out.println(\"all submitted\");\n\t\t\n\t\t//wait 1 day till al the threads are finished \n\t\ttry {\n\t\t\texecutor.awaitTermination(1, TimeUnit.DAYS);\n\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"all completed\");\n\t\t\n\t}",
"public static void main(String[] args) {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(3);\n scheduledThreadPoolExecutor.setRemoveOnCancelPolicy(true);\n SystemOutUtil.println(\"start schedule\");\n scheduledThreadPoolExecutor.schedule(new DelayCallableTask(), 1000, TimeUnit.MILLISECONDS);\n RunnableScheduledFuture<?> rateFuture =\n (RunnableScheduledFuture<?>) scheduledThreadPoolExecutor\n .scheduleAtFixedRate(new FixRateRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n ScheduledFuture delayFuture =\n scheduledThreadPoolExecutor.scheduleWithFixedDelay(new FixDelayRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n SystemOutUtil.println(\"end schedule\");\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"start stop\");\n\n// scheduledThreadPoolExecutor.remove(rateFuture); // 无效\n rateFuture.cancel(false);\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n scheduledThreadPoolExecutor.shutdown();\n return;\n }",
"int getExecutorLargestPoolSize();",
"static ExecutorService boundedNamedCachedExecutorService(int maxThreadBound, String poolName, long keepalive, int queueSize, RejectedExecutionHandler abortPolicy) {\n\n ThreadFactory threadFactory = new NamedThreadFactory(poolName);\n LinkedBlockingQueue<Runnable> queue = new LinkedBlockingQueue<Runnable>(queueSize);\n\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(\n maxThreadBound,\n maxThreadBound,\n keepalive,\n TimeUnit.SECONDS,\n queue,\n threadFactory,\n abortPolicy\n );\n\n threadPoolExecutor.allowCoreThreadTimeOut(true);\n\n return threadPoolExecutor;\n }"
] | [
"0.6574999",
"0.63586587",
"0.6282074",
"0.61708266",
"0.6155707",
"0.6104234",
"0.6100526",
"0.5955829",
"0.5937834",
"0.5899761",
"0.5896704",
"0.58858716",
"0.58777654",
"0.5847829",
"0.5824794",
"0.5817545",
"0.5809743",
"0.57958883",
"0.5794031",
"0.5770858",
"0.5747284",
"0.5707362",
"0.57059705",
"0.57019824",
"0.56919795",
"0.56880206",
"0.5671352",
"0.5660462",
"0.5632674",
"0.5627584",
"0.56227165",
"0.5607639",
"0.5585286",
"0.5550225",
"0.5545456",
"0.5530634",
"0.5505326",
"0.55051523",
"0.5486791",
"0.54634655",
"0.5455144",
"0.54418945",
"0.54337263",
"0.54333836",
"0.54280525",
"0.54175603",
"0.5387595",
"0.53654224",
"0.5342465",
"0.53368616",
"0.5329934",
"0.53263724",
"0.5324185",
"0.5320116",
"0.5314331",
"0.5292835",
"0.52800083",
"0.52778184",
"0.5273419",
"0.52678573",
"0.5266294",
"0.52621627",
"0.5207001",
"0.5203045",
"0.51912165",
"0.5189241",
"0.5181954",
"0.51724005",
"0.5151385",
"0.5144048",
"0.5143111",
"0.51335245",
"0.51201916",
"0.5118148",
"0.5105636",
"0.51022875",
"0.510176",
"0.5097582",
"0.5089178",
"0.5087319",
"0.5081783",
"0.50738233",
"0.5071173",
"0.5068186",
"0.50544167",
"0.50535333",
"0.5050811",
"0.5043636",
"0.5041079",
"0.5036257",
"0.5028884",
"0.5027471",
"0.50127524",
"0.5010099",
"0.5010073",
"0.5006939",
"0.50060767",
"0.50059915",
"0.4999614",
"0.49966297"
] | 0.6457985 | 1 |
A new newFixedThreadPool with null ThreadFactory throws NPE | public void testNewFixedThreadPool3() {
try {
ExecutorService e = Executors.newFixedThreadPool(2, null);
shouldThrow();
} catch (NullPointerException success) {}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewCachedThreadPool3() {\n try {\n ExecutorService e = Executors.newCachedThreadPool(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"@Override\n protected ExecutorService createDefaultExecutorService() {\n return null;\n }",
"public ThreadPool getDefaultThreadPool();",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"public void testNewSingleThreadExecutor3() {\n try {\n ExecutorService e = Executors.newSingleThreadExecutor(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"@Test(expected = NullPointerException.class)\n public void testConstructorNPE2() throws NullPointerException {\n Executors.newCachedThreadPool();\n new BoundedCompletionService<Void>(null);\n shouldThrow();\n }",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@PostConstruct\r\n\tprivate void init() {\n\t threadPool = Executors.newCachedThreadPool();\r\n\t}",
"public ThreadPool()\r\n {\r\n // 20 seconds of inactivity and a worker gives up\r\n suicideTime = 20000;\r\n // half a second for the oldest job in the queue before\r\n // spawning a worker to handle it\r\n spawnTime = 500;\r\n jobs = null;\r\n activeThreads = 0;\r\n askedToStop = false;\r\n }",
"@Override\r\n\tpublic Thread newThread(Runnable arg0) {\n\t\treturn null;\r\n\t}",
"public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"public void initialize() {\n service = Executors.newCachedThreadPool();\n }",
"private void initThreadPool(int numOfThreadsInPool, int[][] resultMat, Observer listener) {\n for(int i=0;i<numOfThreadsInPool; i++){\r\n PoolThread newPoolThread = new PoolThread(m_TaskQueue, resultMat);\r\n newPoolThread.AddResultMatListener(listener);\r\n m_Threads.add(newPoolThread);\r\n }\r\n // Start all Threads:\r\n for(PoolThread currThread: m_Threads){\r\n currThread.start();\r\n }\r\n }",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"protected ThreadPool getPool()\r\n {\r\n return threadPool_;\r\n }",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public LocalEventLoopGroup(int nThreads, ThreadFactory threadFactory) {\n/* 51 */ super(nThreads, threadFactory, new Object[0]);\n/* */ }",
"ActorThreadPool getThreadPool();",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public ThreadLocal() {}",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }",
"public void initialize() {\n\n\t\t// Initialize taskList\n\t\tthis.taskList = new LinkedList<Task>();\n\n\t\t// create a new thread for total size of pool\n\t\tfor (int i = 0; i < this.poolSize; ++i) {\n\t\t\tthreadPool.add(new WorkerThread(this));\n\t\t}\n\n\t\t// Start each thread in thread pool\n\t\tfor (WorkerThread t : threadPool) {\n\t\t\tnew Thread(t).start();\n\t\t}\n\n\t}",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"private void init(int threadCount, Type type) {\r\n //The backend starts to polling threads.\r\n mPoolThread=new Thread(){\r\n @Override\r\n public void run() {\r\n Looper.prepare();\r\n mPoolThreadHandler=new Handler(){\r\n @Override\r\n public void handleMessage(Message msg) {\r\n //take a thread from the thread pool and execute it.\r\n mThreadPool.execute(getTask());\r\n try {\r\n mSemaphoreThreadPool.acquire();\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n };\r\n //if this thread is finished, release a signal to the handler.\r\n mSemaphorePoolThreadHandler.release();\r\n Looper.loop();\r\n }\r\n };\r\n mPoolThread.start();\r\n //Get the maximum available memory for our service.\r\n int maxMemory= (int) Runtime.getRuntime().maxMemory();\r\n int cacheMemory = maxMemory / 8;//8\r\n mLruCache=new LruCache<String, Bitmap>(cacheMemory){\r\n @Override\r\n protected int sizeOf(String key, Bitmap value) {\r\n return value.getRowBytes()*value.getHeight();\r\n }\r\n };\r\n mThreadPool= Executors.newFixedThreadPool(threadCount);\r\n mTaskQueue=new LinkedList<>();\r\n mType=type==null? Type.LIFO:type;\r\n mSemaphoreThreadPool=new Semaphore(threadCount);\r\n\r\n }",
"public ThreadPool getThreadPool(String threadpoolId) throws NoSuchThreadPoolException;",
"public void testCallableNPE2() {\n try {\n Callable c = Executors.callable((Runnable) null, one);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public static ThreadPool getInstance()\r\n {\r\n if(instance == null)\r\n {\r\n instance = new ThreadPool();\r\n }\r\n return instance;\r\n }",
"public void testCallable1() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable());\n assertNull(c.call());\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"public void testCallableNPE1() {\n try {\n Callable c = Executors.callable((Runnable) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"@PostConstruct\r\n public void init() {\r\n \t//registerNotificationCallback(null); //to register taskexecution engine as default\r\n ThreadFactory namedThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"MARM-thread-%d\").build();\r\n \texecutor = Executors.newFixedThreadPool(10, namedThreadFactory);\r\n\r\n ThreadFactory brokerThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"Broker-thread-%d\").build();\r\n brokerExecutor = Executors.newFixedThreadPool(10, brokerThreadFactory);\r\n\r\n ThreadFactory logThreadFactory = new ThreadFactoryBuilder().setNameFormat(\"LOG-thread-%d\").setPriority(Thread.MIN_PRIORITY).build();\r\n logExecutor = Executors.newFixedThreadPool(10, logThreadFactory);\r\n broker.registerInputListener(this);\r\n broker.registerControlListener(this);\r\n }",
"@Override\n\tpublic ThreadPoolExecutor getThreadPool(final HystrixThreadPoolKey threadPoolKey,\n\t\t\tfinal HystrixProperty<Integer> corePoolSize, final HystrixProperty<Integer> maximumPoolSize,\n\t\t\tfinal HystrixProperty<Integer> keepAliveTime, final TimeUnit unit,\n\t\t\tfinal BlockingQueue<Runnable> workQueue) {\n\n\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - default [threadPoolKey=\" + threadPoolKey.name() + \", corePoolSize=\"\n\t\t\t\t+ corePoolSize.get() + \", maximumPoolSize=\" + maximumPoolSize.get() + \", keepAliveTime=\"\n\t\t\t\t+ keepAliveTime.get() + \", unit=\" + unit.name() + \"], override with [threadPoolKey=\"\n\t\t\t\t+ threadPoolKey.name() + \", corePoolSize=\" + CORE_POOL_SIZE + \", maximumPoolSize=\" + MAX_POOL_SIZE\n\t\t\t\t+ \", keepAliveTime=\" + KEEP_ALIVE_TIME + \", unit=\" + TimeUnit.SECONDS.name() + \"]\");\n\n\t\tif (threadFactory != null) {\n\t\t\t// All threads will run as part of this application component.\n\t\t\tfinal ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(CORE_POOL_SIZE, MAX_POOL_SIZE,\n\t\t\t\t\tKEEP_ALIVE_TIME, TimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(BLOCKING_QUEUE_SIZE),\n\t\t\t\t\tthis.threadFactory);\n\n\t\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - initialized threadpool executor [threadPoolKey=\"\n\t\t\t\t\t+ threadPoolKey.name() + \"]\");\n\n\t\t\treturn threadPoolExecutor;\n\t\t} else {\n\t\t\tLOGGER.warn(LOG_PREFIX + \"getThreadPool - fallback to Hystrix default thread pool executor.\");\n\n\t\t\treturn super.getThreadPool(threadPoolKey, corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue);\n\t\t}\n\t}",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }",
"private TestAcceptFactory() {\n this._pool = new DirectExecutor();\n }",
"public ForkJoinPoolMgr() {\n }",
"public ThreadedListenerManager(ExecutorService pool) {\n\t\tmanagerNumber = MANAGER_COUNT.getAndIncrement();\n\t\tthis.pool = pool;\n\t}",
"public void testCastNewSingleThreadExecutor() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n try {\n ThreadPoolExecutor tpe = (ThreadPoolExecutor)e;\n shouldThrow();\n } catch (ClassCastException success) {}\n }\n }",
"private GDMThreadFactory(){}",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"public ThreadFactory threadFactory() {\n return threadFactory_;\n }",
"public void initialize() {\n if (factory == null || poolName == null)\n throw new IllegalStateException(\"Factory and Name must be set before pool initialization!\");\n if (initialized)\n throw new IllegalStateException(\"Cannot initialize more than once!\");\n initialized = true;\n permits = new FIFOSemaphore(maxSize);\n factory.poolStarted(this);\n lastGC = System.currentTimeMillis();\n //fill pool to min size\n fillToMin();\n /*\n int max = maxSize <= 0 ? minSize : Math.min(minSize, maxSize);\n Collection cs = new LinkedList();\n for(int i=0; i<max; i++)\n {\n cs.add(getObject(null));\n }\n while (Iterator i = cs.iterator(); i.hasNext();)\n {\n releaseObject(i.next());\n } // end of while ()\n */\n collector.addPool(this);\n }",
"@Test\n @DisplayName(\"SingleThread Executor + shutdown\")\n void firstExecutorService() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n executor.submit(this::printThreadName);\n\n shutdownExecutor(executor);\n assertThrows(RejectedExecutionException.class, () -> executor.submit(this::printThreadName));\n }",
"PooledThread()\n {\n setDaemon(true);\n\n start();\n }",
"public LocalEventLoopGroup(int nThreads) {\n/* 41 */ this(nThreads, null);\n/* */ }",
"private ConnectionPool() {\n connections = new LinkedBlockingQueue<>(DEFAULT_POOL_SIZE);\n this.init();\n }",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"protected ForkJoinWorkerThread(ForkJoinPool pool) {\n<<<<<<< HEAD\n super(pool.nextWorkerName());\n this.pool = pool;\n int k = pool.registerWorker(this);\n poolIndex = k;\n eventCount = ~k & SMASK; // clear wait count\n locallyFifo = pool.locallyFifo;\n Thread.UncaughtExceptionHandler ueh = pool.ueh;\n if (ueh != null)\n setUncaughtExceptionHandler(ueh);\n setDaemon(true);\n }",
"@PostConstruct\n public void init() {\n threadPoolTaskScheduler.scheduleWithFixedDelay(this::process, Instant.now(), Duration.ofSeconds(30));\n }",
"public static ExecutorService m22730c() {\n if (f20302c == null) {\n synchronized (C7258h.class) {\n if (f20302c == null) {\n f20302c = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.IO).mo18996a(), true);\n }\n }\n }\n return f20302c;\n }",
"private synchronized WorkerThread getThread() {\n\t\tfor (int i = 0; i < this.threadPool.size(); ++i) {\n\t\t\tif (this.threadPool.get(i).available()) {\n\t\t\t\tthis.threadPool.get(i).setAvailable(false);\n\t\t\t\treturn this.threadPool.get(i);\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}",
"private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public static ExecutorService m22734g() {\n if (f20306g == null) {\n synchronized (C7258h.class) {\n if (f20306g == null) {\n f20306g = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.SERIAL).mo18996a(), true);\n }\n }\n }\n return f20306g;\n }",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"protected DefaultPromise()\r\n/* 44: */ {\r\n/* 45: 83 */ this.executor = null;\r\n/* 46: */ }",
"protected abstract void createPool();",
"TaskFactory getTaskFactory();",
"public void testCallableNPE3() {\n try {\n Callable c = Executors.callable((PrivilegedAction) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public final /* bridge */ /* synthetic */ Object mo6445a() {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(1, (ThreadFactory) this.f9355a.mo6445a());\n cazf.m127593a(scheduledThreadPoolExecutor, \"Cannot return null from a non-@Nullable @Provides method\");\n return scheduledThreadPoolExecutor;\n }",
"public TestInvoker()\n {\n super(new TestClient(), new ThreadPoolExecutorImpl(3));\n }",
"public static ExecutorService m22732e() {\n if (f20304e == null) {\n synchronized (C7258h.class) {\n if (f20304e == null) {\n f20304e = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.BACKGROUND).mo18996a(), true);\n }\n }\n }\n return f20304e;\n }",
"public TaskThread(ThreadPool threadPool) {\n super(threadPool.getThreadGroup(), \"Task: Idle\");\n this.threadPool = threadPool;\n threadId = ThreadPool.getUniqueThreadId();\n System.out.println(\"threadId Created:\" + threadId);\n }",
"public ResourcePoolImpl() {\r\n this((ResourcePool) null);\r\n }",
"@Override\n\tpublic Task constructInstance(Robot robot) {\n\t\treturn null;\n\t}",
"private ExecutorService getDroneThreads() {\n\t\treturn droneThreads;\n\t}",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static ExecutorService m22731d() {\n if (f20303d == null) {\n synchronized (C7258h.class) {\n if (f20303d == null) {\n f20303d = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.DEFAULT).mo18996a(), true);\n }\n }\n }\n return f20303d;\n }",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"ScheduledExecutorService getExecutorService();",
"private Thread[] newThreadArray() { \r\n\t int n_cpus = Runtime.getRuntime().availableProcessors(); \r\n\t return new Thread[n_cpus]; \r\n\t }",
"public AbstractParallelAlgorithm()\n {\n this(null);\n }",
"public static CacheManagerExecutorServiceFactory getInstance() {\n return SINGLETON;\n }",
"private CollectTaskPool() {\n\t\tsuper();\n\t}",
"protected Smp(int maxThreads) {\r\n\tmaxThreads = Math.max(1,maxThreads);\r\n\tthis.maxThreads = maxThreads;\r\n\tif (maxThreads>1) {\r\n\t\tthis.taskGroup = new FJTaskRunnerGroup(maxThreads);\r\n\t}\r\n\telse { // avoid parallel overhead\r\n\t\tthis.taskGroup = null;\r\n\t}\r\n}",
"protected EventExecutor newChild(ThreadFactory threadFactory, Object... args) throws Exception {\n/* 57 */ return (EventExecutor)new LocalEventLoop(this, threadFactory);\n/* */ }",
"public ExecutorService m33643a() {\n return (ExecutorService) C15521i.a(this.f28354a.m25442b(), \"Cannot return null from a non-@Nullable @Provides method\");\n }",
"public static Executor m13822l() {\n synchronized (f12483o) {\n if (f12471c == null) {\n f12471c = AsyncTask.THREAD_POOL_EXECUTOR;\n }\n }\n return f12471c;\n }",
"public void testCallableNPE4() {\n try {\n Callable c = Executors.callable((PrivilegedExceptionAction) null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public ThreadedListenerManager() {\n\t\tmanagerNumber = MANAGER_COUNT.getAndIncrement();\n\t\tBasicThreadFactory factory = new BasicThreadFactory.Builder()\n\t\t\t\t.namingPattern(\"listenerPool\" + managerNumber + \"-thread%d\")\n\t\t\t\t.daemon(true)\n\t\t\t\t.build();\n\t\tThreadPoolExecutor defaultPool = (ThreadPoolExecutor) Executors.newCachedThreadPool(factory);\n\t\tdefaultPool.allowCoreThreadTimeOut(true);\n\t\tthis.pool = defaultPool;\n\t}",
"protected StealingThread(StealingPool pool) throws IOException {\n if (pool == null) throw new NullPointerException();\n this.pool = pool;\n this.ioManager = new NioManager();\n // Note: poolIndex is set by pool during construction\n // Remaining initialization is deferred to onStart\n }",
"@Override // java.lang.ThreadLocal\n public final AnonymousClass0jT initialValue() {\n return new AnonymousClass0jT();\n }",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"private static synchronized Executor getDefaultExecutor() {\n return sDefaultExecutor == null ? sDefaultExecutor = new Executor(1)\n : sDefaultExecutor;\n }",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"@ProviderType\npublic interface ThreadPoolMBean {\n\n /**\n * Retrieve the block policy of the thread pool.\n * \n * @return the block policy\n */\n String getBlockPolicy();\n\n /**\n * Retrieve the active count from the pool's Executor.\n * \n * @return the active count or -1 if the thread pool does not have an Executor\n */\n int getExecutorActiveCount();\n\n /**\n * Retrieve the completed task count from the pool's Executor.\n * \n * @return the completed task count or -1 if the thread pool does not have an Executor\n */\n long getExecutorCompletedTaskCount();\n\n /**\n * Retrieve the core pool size from the pool's Executor.\n * \n * @return the core pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorCorePoolSize();\n\n /**\n * Retrieve the largest pool size from the pool's Executor.\n * \n * @return the largest pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorLargestPoolSize();\n\n /**\n * Retrieve the maximum pool size from the pool's Executor.\n * \n * @return the maximum pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorMaximumPoolSize();\n\n\n /**\n * Retrieve the pool size from the pool's Executor.\n * \n * @return the pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorPoolSize();\n\n\n /**\n * Retrieve the task count from the pool's Executor. This is the total number of tasks, which\n * have ever been scheduled to this threadpool. They might have been processed yet or not.\n * \n * @return the task count or -1 if the thread pool does not have an Executor\n */\n long getExecutorTaskCount();\n \n \n /**\n * Retrieve the number of tasks in the work queue of the pool's Executor. These are the\n * tasks which have been already submitted to the threadpool, but which are not yet executed.\n * @return the number of tasks in the work queue -1 if the thread pool does not have an Executor\n */\n long getExcutorTasksInWorkQueueCount();\n\n /**\n * Return the configured max thread age.\n *\n * @return The configured max thread age.\n * @deprecated Since version 1.1.1 always returns -1 as threads are no longer retired\n * but instead the thread locals are cleaned up (<a href=\"https://issues.apache.org/jira/browse/SLING-6261\">SLING-6261</a>)\n */\n @Deprecated\n long getMaxThreadAge();\n\n /**\n * Return the configured keep alive time.\n * \n * @return The configured keep alive time.\n */\n long getKeepAliveTime();\n\n /**\n * Return the configured maximum pool size.\n * \n * @return The configured maximum pool size.\n */\n int getMaxPoolSize();\n\n /**\n * Return the minimum pool size.\n * \n * @return The minimum pool size.\n */\n int getMinPoolSize();\n\n /**\n * Return the name of the thread pool\n * \n * @return the name\n */\n String getName();\n\n /**\n * Return the configuration pid of the thread pool.\n * \n * @return the pid\n */\n String getPid();\n\n /**\n * Return the configured priority of the thread pool.\n * \n * @return the priority\n */\n String getPriority();\n\n /**\n * Return the configured queue size.\n * \n * @return The configured queue size.\n */\n int getQueueSize();\n\n /**\n * Return the configured shutdown wait time in milliseconds.\n * \n * @return The configured shutdown wait time.\n */\n int getShutdownWaitTimeMs();\n\n /**\n * Return whether or not the thread pool creates daemon threads.\n * \n * @return The daemon configuration.\n */\n boolean isDaemon();\n\n /**\n * Return whether or not the thread pool is configured to shutdown gracefully.\n * \n * @return The graceful shutdown configuration.\n */\n boolean isShutdownGraceful();\n\n /**\n * Return whether or not the thread pool is in use.\n * \n * @return The used state of the pool.\n */\n boolean isUsed();\n\n}",
"@Override\n\t\t\tprotected void beforeExecute(Thread t, Runnable r) {\n\t\t\t\tint qsize = getQueue().size();\n\t\t\t\tif(initCorePoolSize>0&&getCorePoolSize()<getMaximumPoolSize()\n\t\t\t\t\t&& qsize > 0 && (qsize%divisor) == 0){\n\t\t\t\t\tsetCorePoolSize(getCorePoolSize()+1); // 进行动态增加\n\t\t\t\t}\n\t\t\t}",
"public ObjectPool() {\n }"
] | [
"0.7415301",
"0.720249",
"0.7147715",
"0.71385926",
"0.6943975",
"0.6750585",
"0.65135384",
"0.64957917",
"0.63587564",
"0.63559157",
"0.6352082",
"0.6348036",
"0.63211167",
"0.62340844",
"0.62330556",
"0.6207553",
"0.6201797",
"0.61878437",
"0.61704487",
"0.6141263",
"0.60785794",
"0.60027814",
"0.5966698",
"0.5953852",
"0.5943833",
"0.59390926",
"0.5925728",
"0.5880941",
"0.58803594",
"0.5872095",
"0.5840556",
"0.5836396",
"0.58252156",
"0.5817402",
"0.5815617",
"0.5813182",
"0.5805515",
"0.5769392",
"0.57630414",
"0.57448214",
"0.57438564",
"0.5716213",
"0.5692754",
"0.56888944",
"0.568194",
"0.56295437",
"0.56052774",
"0.5587969",
"0.5539055",
"0.55330545",
"0.551798",
"0.5517713",
"0.55042803",
"0.5487824",
"0.5486137",
"0.54723895",
"0.5458092",
"0.5456383",
"0.54515237",
"0.544626",
"0.54364663",
"0.54272735",
"0.54124916",
"0.5406626",
"0.53760827",
"0.53710324",
"0.53671706",
"0.535136",
"0.53480506",
"0.534523",
"0.5344395",
"0.5339875",
"0.53389126",
"0.53376985",
"0.53196615",
"0.53179115",
"0.53070587",
"0.5304647",
"0.52987504",
"0.5277932",
"0.52774864",
"0.52631253",
"0.52599156",
"0.5239985",
"0.52385473",
"0.5217565",
"0.5214812",
"0.5214604",
"0.5184628",
"0.51779777",
"0.5175973",
"0.51641476",
"0.5156604",
"0.5155269",
"0.51529235",
"0.51450163",
"0.51241595",
"0.5120522",
"0.5119916",
"0.5117818"
] | 0.77599525 | 0 |
A new newFixedThreadPool with 0 threads throws IAE | public void testNewFixedThreadPool4() {
try {
ExecutorService e = Executors.newFixedThreadPool(0);
shouldThrow();
} catch (IllegalArgumentException success) {}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public void testNewCachedThreadPool3() {\n try {\n ExecutorService e = Executors.newCachedThreadPool(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@Override\n protected ExecutorService createDefaultExecutorService() {\n return null;\n }",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public ThreadPool getDefaultThreadPool();",
"public ThreadPool()\r\n {\r\n // 20 seconds of inactivity and a worker gives up\r\n suicideTime = 20000;\r\n // half a second for the oldest job in the queue before\r\n // spawning a worker to handle it\r\n spawnTime = 500;\r\n jobs = null;\r\n activeThreads = 0;\r\n askedToStop = false;\r\n }",
"public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }",
"private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private void init(int threadCount, Type type) {\r\n //The backend starts to polling threads.\r\n mPoolThread=new Thread(){\r\n @Override\r\n public void run() {\r\n Looper.prepare();\r\n mPoolThreadHandler=new Handler(){\r\n @Override\r\n public void handleMessage(Message msg) {\r\n //take a thread from the thread pool and execute it.\r\n mThreadPool.execute(getTask());\r\n try {\r\n mSemaphoreThreadPool.acquire();\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n };\r\n //if this thread is finished, release a signal to the handler.\r\n mSemaphorePoolThreadHandler.release();\r\n Looper.loop();\r\n }\r\n };\r\n mPoolThread.start();\r\n //Get the maximum available memory for our service.\r\n int maxMemory= (int) Runtime.getRuntime().maxMemory();\r\n int cacheMemory = maxMemory / 8;//8\r\n mLruCache=new LruCache<String, Bitmap>(cacheMemory){\r\n @Override\r\n protected int sizeOf(String key, Bitmap value) {\r\n return value.getRowBytes()*value.getHeight();\r\n }\r\n };\r\n mThreadPool= Executors.newFixedThreadPool(threadCount);\r\n mTaskQueue=new LinkedList<>();\r\n mType=type==null? Type.LIFO:type;\r\n mSemaphoreThreadPool=new Semaphore(threadCount);\r\n\r\n }",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"private void initThreadPool(int numOfThreadsInPool, int[][] resultMat, Observer listener) {\n for(int i=0;i<numOfThreadsInPool; i++){\r\n PoolThread newPoolThread = new PoolThread(m_TaskQueue, resultMat);\r\n newPoolThread.AddResultMatListener(listener);\r\n m_Threads.add(newPoolThread);\r\n }\r\n // Start all Threads:\r\n for(PoolThread currThread: m_Threads){\r\n currThread.start();\r\n }\r\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"public LocalEventLoopGroup(int nThreads, ThreadFactory threadFactory) {\n/* 51 */ super(nThreads, threadFactory, new Object[0]);\n/* */ }",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"public void initialize() {\n service = Executors.newCachedThreadPool();\n }",
"public CacheThreadPool(final int size)\n {\n synchronized (m_lock)\n {\n m_pool = new PooledThread[size];\n \n // We assume that a list is expanded once it reaches half of its capacity\n // and it doesn't harm if the assumption is wrong.\n m_index = new ArrayList(size + 1 + (size / 2));\n }\n }",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"@PostConstruct\r\n\tprivate void init() {\n\t threadPool = Executors.newCachedThreadPool();\r\n\t}",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testForNThreads();",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"ActorThreadPool getThreadPool();",
"@Override\r\n public int getMaxConcurrentProcessingInstances() {\r\n return 1;\r\n }",
"public LocalEventLoopGroup(int nThreads) {\n/* 41 */ this(nThreads, null);\n/* */ }",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"public void testNewSingleThreadExecutor3() {\n try {\n ExecutorService e = Executors.newSingleThreadExecutor(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"private CollectTaskPool() {\n\t\tsuper();\n\t}",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"private Thread[] newThreadArray() { \r\n\t int n_cpus = Runtime.getRuntime().availableProcessors(); \r\n\t return new Thread[n_cpus]; \r\n\t }",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }",
"@Override\n\t\t\tprotected void beforeExecute(Thread t, Runnable r) {\n\t\t\t\tint qsize = getQueue().size();\n\t\t\t\tif(initCorePoolSize>0&&getCorePoolSize()<getMaximumPoolSize()\n\t\t\t\t\t&& qsize > 0 && (qsize%divisor) == 0){\n\t\t\t\t\tsetCorePoolSize(getCorePoolSize()+1); // 进行动态增加\n\t\t\t\t}\n\t\t\t}",
"@VisibleForTesting\n static int getInstanceThreadPoolSize() {\n return instanceThreadPoolSize;\n }",
"public void initialize() {\n if (factory == null || poolName == null)\n throw new IllegalStateException(\"Factory and Name must be set before pool initialization!\");\n if (initialized)\n throw new IllegalStateException(\"Cannot initialize more than once!\");\n initialized = true;\n permits = new FIFOSemaphore(maxSize);\n factory.poolStarted(this);\n lastGC = System.currentTimeMillis();\n //fill pool to min size\n fillToMin();\n /*\n int max = maxSize <= 0 ? minSize : Math.min(minSize, maxSize);\n Collection cs = new LinkedList();\n for(int i=0; i<max; i++)\n {\n cs.add(getObject(null));\n }\n while (Iterator i = cs.iterator(); i.hasNext();)\n {\n releaseObject(i.next());\n } // end of while ()\n */\n collector.addPool(this);\n }",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public static ExecutorService m22734g() {\n if (f20306g == null) {\n synchronized (C7258h.class) {\n if (f20306g == null) {\n f20306g = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.SERIAL).mo18996a(), true);\n }\n }\n }\n return f20306g;\n }",
"protected Smp(int maxThreads) {\r\n\tmaxThreads = Math.max(1,maxThreads);\r\n\tthis.maxThreads = maxThreads;\r\n\tif (maxThreads>1) {\r\n\t\tthis.taskGroup = new FJTaskRunnerGroup(maxThreads);\r\n\t}\r\n\telse { // avoid parallel overhead\r\n\t\tthis.taskGroup = null;\r\n\t}\r\n}",
"protected ThreadPool getPool()\r\n {\r\n return threadPool_;\r\n }",
"protected ForkJoinWorkerThread(ForkJoinPool pool) {\n<<<<<<< HEAD\n super(pool.nextWorkerName());\n this.pool = pool;\n int k = pool.registerWorker(this);\n poolIndex = k;\n eventCount = ~k & SMASK; // clear wait count\n locallyFifo = pool.locallyFifo;\n Thread.UncaughtExceptionHandler ueh = pool.ueh;\n if (ueh != null)\n setUncaughtExceptionHandler(ueh);\n setDaemon(true);\n }",
"@Test\n\tpublic void addNormalConcurrentTP10_1000() throws Exception {\n\t\tExecutorService exec = Executors.newFixedThreadPool(10);\n\t\tfinal AtomicInteger count = new AtomicInteger(0);\n\t\t\n\t\tretryManager.registerCallback(new RetryCallback() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic boolean onEvent(RetryHolder retry) throws Exception {\n\t\t\t\t\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}, TYPE);\n\t\t\n\t\tfor (int i=0;i<1000;i++) {\n\t\t\texec.submit(new Runnable() {\n\t\t\t\t\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\tRetryHolder holder = new RetryHolder(\"id-local\"+ count.getAndIncrement(), TYPE,new Exception(),\"Object\");\n\t\t\t\t\t\n\t\t\t\t\tretryManager.addRetry(holder);\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t\texec.shutdown();\n\t\texec.awaitTermination(10, TimeUnit.SECONDS);\n\t\tint localQueueSize = retryManager.getLocalQueuer().size(TYPE);\n\t\tAssert.assertEquals(0,localQueueSize);\n\t\tAssert.assertEquals(1000, retryManager.getH1().getMap(TYPE).size() );\n\t\t\t\t\n\t\t//synchronous add, check immediately\t\t\n\t\tfor (int i=0;i<1000;i++ ) {\n\t\t\tAssert.assertNotNull(\n\t\t\t\t\tretryManager.getH1().getMap(TYPE).get(\"id-local\"+i)\n\t\t\t\t\t);\n\t\t\tretryManager.removeRetry(\"id-local\"+i, TYPE);\n\t\t}\n\t\t\n\t}",
"@Test(expected = NullPointerException.class)\n public void testConstructorNPE2() throws NullPointerException {\n Executors.newCachedThreadPool();\n new BoundedCompletionService<Void>(null);\n shouldThrow();\n }",
"ObjectPool() {\n deadTime = DEFAULT_DEADTIME;\n lock = new Hashtable<T, Long>();\n unlock = new Hashtable<T, Long>();\n }",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"public static ExecutorService m22730c() {\n if (f20302c == null) {\n synchronized (C7258h.class) {\n if (f20302c == null) {\n f20302c = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.IO).mo18996a(), true);\n }\n }\n }\n return f20302c;\n }",
"private ConnectionPool() {\n connections = new LinkedBlockingQueue<>(DEFAULT_POOL_SIZE);\n this.init();\n }",
"@Override\r\n\tpublic Thread newThread(Runnable arg0) {\n\t\treturn null;\r\n\t}",
"ThreadCounterRunner() {}",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public boolean newThreadPoolAvailable() {\n\t\tif (this.serverConnectorUsed+1 <= MAX_THREADS) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"public static ExecutorService m22732e() {\n if (f20304e == null) {\n synchronized (C7258h.class) {\n if (f20304e == null) {\n f20304e = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.BACKGROUND).mo18996a(), true);\n }\n }\n }\n return f20304e;\n }",
"public void initialize() {\n\n\t\t// Initialize taskList\n\t\tthis.taskList = new LinkedList<Task>();\n\n\t\t// create a new thread for total size of pool\n\t\tfor (int i = 0; i < this.poolSize; ++i) {\n\t\t\tthreadPool.add(new WorkerThread(this));\n\t\t}\n\n\t\t// Start each thread in thread pool\n\t\tfor (WorkerThread t : threadPool) {\n\t\t\tnew Thread(t).start();\n\t\t}\n\n\t}",
"public void testCallable1() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable());\n assertNull(c.call());\n }",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"@Test\n public void testParallelOnce() {\n final int count = 100000;\n final int threads = 4;\n final int perThread = count / threads;\n Cache<Integer, Integer> c =\n builder()\n .entryCapacity(-1)\n .weigher((key, value) -> value)\n .maximumWeight(MAX_VALUE)\n .build();\n AtomicInteger offset = new AtomicInteger();\n Runnable inserter = () -> {\n int start = offset.getAndAdd(perThread);\n int end = start + perThread;\n for (int i = start; i < end; i++) {\n c.put(i, i);\n }\n for (int i = start; i < end; i++) {\n c.remove(i);\n }\n };\n ThreadingStressTester tst = new ThreadingStressTester();\n tst.setOneShotMode(true);\n tst.setOneShotTimeoutMillis(MAX_FINISH_WAIT_MILLIS);\n tst.addTask(threads, inserter);\n tst.run();\n assertThat(getInfo().getTotalWeight())\n .as(\"total weight is 0\")\n .isEqualTo(0);\n }",
"public void setInitialThreadCount(int threads)\n { _threadPool.setInitialSize(threads);\n }",
"public void setLowWaterThreadCount(int threads)\n { _threadPool.setMinAvailable(threads);\n }",
"PooledThread()\n {\n setDaemon(true);\n\n start();\n }",
"public MultiThreadBatchTaskEngine(int aNThreads)\n {\n setMaxThreads(aNThreads);\n }",
"public AbstractConcurrentTestCase() {\n mainThread = Thread.currentThread();\n }",
"public TestInvoker()\n {\n super(new TestClient(), new ThreadPoolExecutorImpl(3));\n }",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"public void startThread() {\n\t\tif (this.serverConnectorUsed <= Byte.MAX_VALUE) {\n\t\t\tthis.serverConnectorUsed++;\n\t\t\tLOG.info(\"Running new thread. Now pool is \"+Integer.toString(MAX_THREADS-this.serverConnectorUsed)+\" / \"+Integer.toString(MAX_THREADS));\n\t\t}\n\t}",
"public static ExecutorService m21543a() {\n return f19854a;\n }",
"public void doAllTasks() throws Exception {\n final GenericInitializer<E,T> initializer = config.getInitializer();\n final TaskFactory<E,T,GenericInitializer<E,T>> initTaskFac = config.getInitFactory();\n final ObjectCache<GenericInitializer<E,T>> initCache = new ObjectCache<>(2*threads,initializer);\n \n final long sT = System.currentTimeMillis();\n List<Task<T>> initTasks = comm.getInitialTasks(maxTasks,myID);\n final long mT = System.currentTimeMillis();\n initFetchTimeMS += mT-sT;\n initChunksGotten++;\n \n do{\n noInits = initTasks.size();\n if(noInits == 0){\n // nothing to be done, kinda weird.\n System.out.println(\"WARNING: No tasks gotten for threading backend \" + myID + \" continuing but wondering...\");\n break;\n }\n // kind of subptimal but we need to get the ID offset\n currIDStart = (int) initTasks.get(0).getDummyAnswer(myID).getResult().getID();\n \n if(DEBUG){System.out.println(\"DEBUG: Starting with ID \" + currIDStart + \" we have \" + initTasks.size() + \" tasks to init.\");}\n\n final long tOff = System.currentTimeMillis();\n doXXX(threads, initTaskFac, initCache, initTasks);\n final long tMid = System.currentTimeMillis();\n initWorkTimeMS += (tMid-tOff);\n \n final boolean doneYet = synchronizePools(true);\n if(!doneYet){\n initTasks = comm.getInitialTasks(maxTasks,myID);\n initChunksGotten++;\n } else {\n initTasks.clear(); // not strictly necessary, I think\n }\n final long tEnd = System.currentTimeMillis();\n initFetchTimeMS += (tEnd-tMid);\n \n } while(!initTasks.isEmpty());\n \n // merge pools, technically this should have happened before already. However, this does not hurt and synchronizes even further.\n synchronizePools(false);\n \n ISINIT = false;\n \n // then do globopt tasks (setup task factory and cachers)\n final GenericGlobalOptimization<E,T> globopt = config.getGlobalOptimization();\n final ObjectCache<GenericGlobalOptimization<E,T>> globCache = new ObjectCache<>(2*threads,globopt);\n TaskFactory<E,T,GenericGlobalOptimization<E,T>> globTasks = new GlobTaskFactory<>();\n\n while(!comm.isEverythingDone()){\n \n final long tOff = System.currentTimeMillis();\n doXXX(threads, globTasks, globCache, (int) currIDStart, (int) tasksGotten);\n final long tMid = System.currentTimeMillis();\n optWorkTimeMS += (tMid-tOff);\n \n final boolean done = synchronizePools(false);\n final long tEnd = System.currentTimeMillis();\n optFetchTimeMS += (tEnd-tMid);\n \n if(done) {break;}\n }\n }",
"@VisibleForTesting\n void killIoThreads() {\n ioThreadPool.shutdownNow();\n }",
"int getExecutorCorePoolSize();",
"int getPoolSize();",
"private BlocksPool() {\n this(DEFAULT_BLOCK_SIZE_BYTES);\n }",
"public AbstractParallelAlgorithm()\n {\n this(null);\n }",
"@Test\n public void launchesEventhandlerThreadpoolMaxsizeTest() {\n // TODO: test launchesEventhandlerThreadpoolMaxsize\n }",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"public static GlideExecutor m21519e() {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(0, Integer.MAX_VALUE, f23336b, TimeUnit.MILLISECONDS, new SynchronousQueue(), new C8962a(\"source-unlimited\", UncaughtThrowableStrategy.f23340b, false));\n return new GlideExecutor(threadPoolExecutor);\n }",
"public ObjectPool() {\n }",
"public ThreadLocal() {}",
"public MapWorkPool(int nThreads) {\n\t\tthis.nThreads = nThreads;\n\n\t}",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"public void setHighWaterThreadCount(int threads)\n { _threadPool.setMaxSize(threads);\n }",
"public static void testES() {\n ExecutorService es = Executors.newFixedThreadPool(2);\n for (int i = 0; i < 10; i++)\n es.execute(new TestTask());\n }",
"public ThreadedListenerManager(ExecutorService pool) {\n\t\tmanagerNumber = MANAGER_COUNT.getAndIncrement();\n\t\tthis.pool = pool;\n\t}",
"@Test\n public void eternal_retry0s() {\n Cache<Integer, Integer> c = new Cache2kBuilder<Integer, Integer>() {}\n .eternal(true)\n .retryInterval(0, TimeUnit.SECONDS)\n /* ... set loader ... */\n .build();\n target.setCache(c);\n assertTrue(extractHandler() instanceof TimingHandler.EternalImmediate);\n }",
"int getMaximumPoolSize();",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"@Test\n\tpublic void sameThreadPoolDueToAffinity() throws Exception {\n\t\tString previousCore = null;\n\t\tfor (int i = 0; i < 100; i++) {\n\n\t\t\t// GET entry\n\t\t\tMockHttpResponse response = this.server.send(MockHttpServer.mockRequest(\"/\"));\n\t\t\tString html = response.getEntity(null);\n\t\t\tassertEquals(200, response.getStatus().getStatusCode(), \"Should be successful: \" + html);\n\n\t\t\t// Parse out the core\n\t\t\tPattern pattern = Pattern.compile(\".*CORE-(\\\\d+)-.*\", Pattern.DOTALL);\n\t\t\tMatcher matcher = pattern.matcher(html);\n\t\t\tassertTrue(matcher.matches(), \"Should be able to obtain thread affinity core\");\n\t\t\tString core = matcher.group(1);\n\n\t\t\t// Ensure same as previous core (ignoring first call)\n\t\t\tif (previousCore != null) {\n\t\t\t\tassertEquals(previousCore, core, \"Should be locked to same core\");\n\t\t\t}\n\n\t\t\t// Set up for next call\n\t\t\tpreviousCore = core;\n\t\t}\n\t}",
"@Test\n\tpublic static void testNonThreadLocal() {\n\t\tExecutorService service = Executors.newCachedThreadPool();\n\n\t\tRunnable task = new Runnable() {\n\t\t\tNonThreadLocal<AtomicInteger> tlocal = new NonThreadLocal<AtomicInteger>() {\n\t\t\t\t@Override\n\t\t\t\tpublic AtomicInteger initialValue() {\n\t\t\t\t\treturn new AtomicInteger(1);\n\t\t\t\t}\n\t\t\t};\n\n\t\t\tpublic void run() {\n\t\t\t\tSystem.out.println(Thread.currentThread().getName() + \" start with value: \" + tlocal.get());\n\t\t\t\ttry {\n\t\t\t\t\tTimeUnit.SECONDS.sleep(1);\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\tint res;\n//\t\t\t\tsynchronized (\"ABC\") {\n\t\t\t\t\tres = tlocal.get().addAndGet(1);\n\t\t\t\t\ttry {\n\t\t\t\t\t\tTimeUnit.SECONDS.sleep(1);\n\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t\ttlocal.set(new AtomicInteger(res));\n//\t\t\t\t}\n\t\t\t\tSystem.out.println(Thread.currentThread().getName() + \" ends with value: \" + res);\n\t\t\t}\n\t\t};\n\t\tfor (int i = 0; i < 5; i++)\n\t\t\tservice.submit(task);\n\t\tservice.shutdown();\n\n\t}",
"@Test\n\tpublic void ShutdownTest()\n\t{\n\t\tThreadPool testThreadPool = new ThreadPool(new SongValidator(),2,100);\n\t\ttestThreadPool.shutdown();\n\t\tassertTrue(testThreadPool.getAvailableExpirator()==null);\n\t}",
"static ExecutorService boundedNamedCachedExecutorService(int maxThreadBound, String poolName, long keepalive, int queueSize, RejectedExecutionHandler abortPolicy) {\n\n ThreadFactory threadFactory = new NamedThreadFactory(poolName);\n LinkedBlockingQueue<Runnable> queue = new LinkedBlockingQueue<Runnable>(queueSize);\n\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(\n maxThreadBound,\n maxThreadBound,\n keepalive,\n TimeUnit.SECONDS,\n queue,\n threadFactory,\n abortPolicy\n );\n\n threadPoolExecutor.allowCoreThreadTimeOut(true);\n\n return threadPoolExecutor;\n }",
"private synchronized void addTask(Runnable runnable) {\r\n mTaskQueue.add(runnable);\r\n try {\r\n if (mPoolThreadHandler==null){\r\n mSemaphorePoolThreadHandler.acquire();\r\n }\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n\r\n mPoolThreadHandler.sendEmptyMessage(0x110);\r\n }",
"public ImageManager(final Context context, final int cacheSize, \n final int threads ){\n\n // Instantiate the three queues. The task queue uses a custom comparator to \n // change the ordering from FIFO (using the internal comparator) to respect\n // request priorities. If two requests have equal priorities, they are \n // sorted according to creation date\n mTaskQueue = new PriorityBlockingQueue<Runnable>(QUEUE_SIZE, \n new ImageThreadComparator());\n mActiveTasks = new ConcurrentLinkedQueue<Runnable>();\n mBlockedTasks = new ConcurrentLinkedQueue<Runnable>();\n\n // The application context\n mContext = context;\n\n // Create a new threadpool using the taskQueue\n mThreadPool = new ThreadPoolExecutor(threads, threads, \n Long.MAX_VALUE, TimeUnit.SECONDS, mTaskQueue){\n\n\n @Override\n protected void beforeExecute(final Thread thread, final Runnable run) {\n // Before executing a request, place the request on the active queue\n // This prevents new duplicate requests being placed in the active queue\n mActiveTasks.add(run);\n super.beforeExecute(thread, run);\n }\n\n @Override\n protected void afterExecute(final Runnable r, final Throwable t) {\n // After a request has finished executing, remove the request from\n // the active queue, this allows new duplicate requests to be submitted\n mActiveTasks.remove(r);\n\n // Perform a quick check to see if there are any remaining requests in\n // the blocked queue. Peek the head and check for duplicates in the \n // active and task queues. If no duplicates exist, add the request to\n // the task queue. Repeat this until a duplicate is found\n synchronized (mBlockedTasks) {\n while(mBlockedTasks.peek()!=null && \n !mTaskQueue.contains(mBlockedTasks.peek()) && \n !mActiveTasks.contains(mBlockedTasks.peek())){\n Runnable runnable = mBlockedTasks.poll();\n if(runnable!=null){\n mThreadPool.execute(runnable);\n }\n }\n }\n super.afterExecute(r, t);\n }\n };\n\n // Calculate the cache size\n final int actualCacheSize = \n ((int) (Runtime.getRuntime().maxMemory() / 1024)) / cacheSize;\n\n // Create the LRU cache\n // http://developer.android.com/reference/android/util/LruCache.html\n\n // The items are no longer recycled as they leave the cache, turns out this wasn't the right\n // way to go about this and often resulted in recycled bitmaps being drawn\n // http://stackoverflow.com/questions/10743381/when-should-i-recycle-a-bitmap-using-lrucache\n mBitmapCache = new LruCache<String, Bitmap>(actualCacheSize){\n protected int sizeOf(final String key, final Bitmap value) {\n return value.getByteCount() / 1024;\n }\n };\n }",
"@Test (timeout=180000)\n public void testHbckThreadpooling() throws Exception {\n TableName table =\n TableName.valueOf(\"tableDupeStartKey\");\n try {\n // Create table with 4 regions\n setupTable(table);\n\n // limit number of threads to 1.\n Configuration newconf = new Configuration(conf);\n newconf.setInt(\"hbasefsck.numthreads\", 1);\n assertNoErrors(doFsck(newconf, false));\n\n // We should pass without triggering a RejectedExecutionException\n } finally {\n cleanupTable(table);\n }\n }"
] | [
"0.74492854",
"0.6935998",
"0.6881092",
"0.67339855",
"0.6620809",
"0.6546968",
"0.6533831",
"0.64518344",
"0.6367379",
"0.63422287",
"0.62211806",
"0.6159708",
"0.6151389",
"0.6139049",
"0.6129588",
"0.6114435",
"0.6008699",
"0.6001511",
"0.59468853",
"0.5917783",
"0.59048223",
"0.58947194",
"0.5889644",
"0.585135",
"0.5787449",
"0.57654643",
"0.57368296",
"0.5730196",
"0.5718404",
"0.5678691",
"0.5673534",
"0.566997",
"0.56653905",
"0.56645346",
"0.56630033",
"0.56305206",
"0.56257445",
"0.56235355",
"0.5607312",
"0.55912703",
"0.55751395",
"0.55703324",
"0.5566907",
"0.55597323",
"0.55525285",
"0.55434036",
"0.55357295",
"0.55356187",
"0.55245584",
"0.55050355",
"0.5504516",
"0.55035794",
"0.5501912",
"0.5495987",
"0.5489943",
"0.5478449",
"0.5476344",
"0.5475467",
"0.5473789",
"0.5473039",
"0.5471723",
"0.54642004",
"0.5461662",
"0.54597366",
"0.5452897",
"0.54059666",
"0.53706366",
"0.5364878",
"0.53647333",
"0.53638",
"0.53595006",
"0.53539133",
"0.53473204",
"0.5343026",
"0.5338788",
"0.53325415",
"0.53323096",
"0.5331846",
"0.5330631",
"0.5327686",
"0.5320957",
"0.53173584",
"0.5315075",
"0.5312763",
"0.5310111",
"0.53088695",
"0.5306415",
"0.53045464",
"0.52952474",
"0.5286479",
"0.5284912",
"0.5282442",
"0.5282177",
"0.52771777",
"0.5276226",
"0.5275447",
"0.52751744",
"0.52690905",
"0.52666426",
"0.524802"
] | 0.78610384 | 0 |
An unconfigurable newFixedThreadPool can execute runnables | public void testUnconfigurableExecutorService() {
final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));
try (PoolCleaner cleaner = cleaner(e)) {
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
e.execute(new NoOpRunnable());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public ThreadPool getDefaultThreadPool();",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"private static void threadPoolWithExecute() {\n\n Executor executor = Executors.newFixedThreadPool(3);\n IntStream.range(1, 10)\n .forEach((i) -> {\n executor.execute(() -> {\n System.out.println(\"started task for id - \"+i);\n try {\n if (i == 8) {\n Thread.sleep(4000);\n } else {\n Thread.sleep(1000);\n }\n System.out.println(\"In runnable task for id -\" + i);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n });\n System.out.println(\"End of method .THis gets printed immdly since execute is not blocking call\");\n }",
"public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }",
"ActorThreadPool getThreadPool();",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"public void testForNThreads();",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public boolean newThreadPoolAvailable() {\n\t\tif (this.serverConnectorUsed+1 <= MAX_THREADS) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"public static void main(String[] args) {\n\t\tExecutorService pool = Executors.newFixedThreadPool(3);\n\t\t//ExecutorService pool = Executors.newSingleThreadExecutor();\n\t\t\n\t\tExecutorService pool2 = Executors.newCachedThreadPool();\n\t\t//this pool2 will add more thread into pool(when no other thread running), the new thread do not need to wait.\n\t\t//pool2 will delete un runing thread(unrun for 60 secs)\n\t\tThread t1 = new MyThread();\n\t\tThread t2 = new MyThread();\n\t\tThread t3 = new MyThread();\n\n\t\tpool.execute(t1);\n\t\tpool.execute(t2);\n\t\tpool.execute(t3);\n\t\tpool.shutdown();\n\t\t\n\t}",
"private static void useCachedThreadPool() {\n ExecutorService executor = Executors.newCachedThreadPool();\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n\n executor.execute(() -> {\n System.out.println(\"==========\");\n });\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 100).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }",
"public interface ThreadPool<Job extends Runnable> {\n\n void execute(Job job);\n\n void shutDown();\n\n void addWorkers(int num);\n\n void removeWorkers(int num);\n\n int getJobSize();\n\n}",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"public static void main(String[] args) {\n ThreadPoolExecutor executorService = new ThreadPoolExecutor(3, 10, 1L, TimeUnit.SECONDS,\n new LinkedBlockingQueue<>(20),\n Executors.defaultThreadFactory(),\n new ThreadPoolExecutor.AbortPolicy());\n ABC abc = new ABC();\n try {\n for (int i = 1; i <= 10; i++) {\n executorService.execute(abc::print5);\n executorService.execute(abc::print10);\n executorService.execute(abc::print15);\n }\n\n }finally {\n executorService.shutdown();\n }\n }",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"public static void main(String[] args) {\n SomeRunnable obj1 = new SomeRunnable();\n SomeRunnable obj2 = new SomeRunnable();\n SomeRunnable obj3 = new SomeRunnable();\n \n System.out.println(\"obj1 = \"+obj1);\n System.out.println(\"obj2 = \"+obj2);\n System.out.println(\"obj3 = \"+obj3);\n \n //Create fixed Thread pool, here pool of 2 thread will created\n ExecutorService pool = Executors.newFixedThreadPool(3);\n ExecutorService pool2 = Executors.newFixedThreadPool(2);\n pool.execute(obj1);\n pool.execute(obj2);\n pool2.execute(obj3);\n \n pool.shutdown();\n pool2.shutdown();\n }",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testExecuteInParallel_Collection_ThreadPoolExecutor() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks, ParallelUtil.createThreadPool( 1 ) );\n assertEquals( result.size(), tasks.size() );\n }",
"int getExecutorPoolSize();",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"int getExecutorLargestPoolSize();",
"int getExecutorMaximumPoolSize();",
"public void testGetNumThreads_ThreadPoolExecutor()\n {\n System.out.println( \"getNumThreads\" );\n int numThreads = 10;\n PA pa = new PA();\n assertEquals( 0, ParallelUtil.getNumThreads( pa.getThreadPool() ) );\n \n pa.threadPool = ParallelUtil.createThreadPool( 10 ); \n \n int result = ParallelUtil.getNumThreads( pa.getThreadPool() );\n assertEquals( numThreads, result );\n }",
"public void testUnconfigurableScheduledExecutorService() throws Exception {\n final ScheduledExecutorService p =\n Executors.unconfigurableScheduledExecutorService\n (Executors.newScheduledThreadPool(2));\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"private void initThreadPool(int numOfThreadsInPool, int[][] resultMat, Observer listener) {\n for(int i=0;i<numOfThreadsInPool; i++){\r\n PoolThread newPoolThread = new PoolThread(m_TaskQueue, resultMat);\r\n newPoolThread.AddResultMatListener(listener);\r\n m_Threads.add(newPoolThread);\r\n }\r\n // Start all Threads:\r\n for(PoolThread currThread: m_Threads){\r\n currThread.start();\r\n }\r\n }",
"@Test\n @DisplayName(\"Invoke Any\")\n void invokeAny() throws ExecutionException, InterruptedException {\n ExecutorService executor = Executors.newWorkStealingPool();\n\n List<Callable<String>> callables = Arrays.asList(\n callable(\"task1\", 2),\n callable(\"task2\", 1),\n callable(\"task3\", 3));\n\n String result = executor.invokeAny(callables);\n assertEquals(\"task2\", result);\n }",
"public static void main(String[] args) {\n\t\tBlockingQueue queue = new LinkedBlockingQueue(4);\n\n\t\t// Thread factory below is used to create new threads\n\t\tThreadFactory thFactory = Executors.defaultThreadFactory();\n\n\t\t// Rejection handler in case the task get rejected\n\t\tRejectTaskHandler rth = new RejectTaskHandler();\n\t\t// ThreadPoolExecutor constructor to create its instance\n\t\t// public ThreadPoolExecutor(int corePoolSize,int maximumPoolSize,long\n\t\t// keepAliveTime,\n\t\t// TimeUnit unit,BlockingQueue workQueue ,ThreadFactory\n\t\t// threadFactory,RejectedExecutionHandler handler) ;\n\t\tThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(1, 2, 10L, TimeUnit.MILLISECONDS, queue,\n\t\t\t\tthFactory, rth);\n\n\t\tfor (int i = 1; i <= 10; i++) {\n\t\t\tDataFileReader df = new DataFileReader(\"File \" + i);\n\t\t\tSystem.out.println(\"A new file has been added to read : \" + df.getFileName());\n\t\t\t// Submitting task to executor\n\t\t\tthreadPoolExecutor.execute(df);\n\t\t}\n\t\tthreadPoolExecutor.shutdown();\n\t}",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public static void main(String[] args) {\r\n\t\tMyThread thread = new MyThread();\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t\tfixedExecutorService.execute(thread);\r\n\t}",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"public void testNewCachedThreadPool3() {\n try {\n ExecutorService e = Executors.newCachedThreadPool(null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"public static void main(String[] args){ new ThreadPoolBlockingServer().processRequests(); }",
"int getExecutorCorePoolSize();",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"@Bean(destroyMethod = \"shutdown\")\n public Executor threadPoolTaskExecutor(@Value(\"${thread.size}\") String argThreadSize) {\n this.threadSize = Integer.parseInt(argThreadSize);\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(this.threadSize);\n executor.setKeepAliveSeconds(15);\n executor.initialize();\n return executor;\n }",
"public static void main(String[] args) {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(3);\n scheduledThreadPoolExecutor.setRemoveOnCancelPolicy(true);\n SystemOutUtil.println(\"start schedule\");\n scheduledThreadPoolExecutor.schedule(new DelayCallableTask(), 1000, TimeUnit.MILLISECONDS);\n RunnableScheduledFuture<?> rateFuture =\n (RunnableScheduledFuture<?>) scheduledThreadPoolExecutor\n .scheduleAtFixedRate(new FixRateRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n ScheduledFuture delayFuture =\n scheduledThreadPoolExecutor.scheduleWithFixedDelay(new FixDelayRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n SystemOutUtil.println(\"end schedule\");\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"start stop\");\n\n// scheduledThreadPoolExecutor.remove(rateFuture); // 无效\n rateFuture.cancel(false);\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n scheduledThreadPoolExecutor.shutdown();\n return;\n }",
"public static void main(String[] args) {\n ExecutorService es = Executors.newCachedThreadPool();\n es.execute(new Task(65));\n es.execute(new Task(5));\n System.out.println(\"结束执行!\");\n }",
"public static void main(String args[]) {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n\t\t\n\t\t// Create a list to hold the Future object associated with Callable\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\n\n\t\t/**\n\t\t * Create MyCallable instance using Lambda expression which return\n\t\t * the thread name executing this callable task\n\t\t */\n\t\tCallable<String> callable = () -> {\n\t\t\tThread.sleep(2000);\n\t\t\treturn Thread.currentThread().getName();\n\t\t};\n\t\t\n\t\t/**\n\t\t * Submit Callable tasks to be executed by thread pool\n\t\t * Add Future to the list, we can get return value using Future\n\t\t **/\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tFuture<String> future = executor.submit(callable);\n\t\t\tfutureList.add(future);\n\t\t}\n\t\t\n\t\t/**\n\t\t * Print the return value of Future, notice the output delay\n\t\t * in console because Future.get() waits for task to get completed\n\t\t **/\n\t\tfor (Future<String> future : futureList) {\n\t\t\ttry {\n\t\t\t\tSystem.out.println(new Date() + \" | \" + future.get());\n\t\t\t} catch (InterruptedException | ExecutionException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\t// shut down the executor service.\n\t\texecutor.shutdown();\n\t}",
"@Override\n\tpublic ThreadPoolExecutor getThreadPool(final HystrixThreadPoolKey threadPoolKey,\n\t\t\tfinal HystrixProperty<Integer> corePoolSize, final HystrixProperty<Integer> maximumPoolSize,\n\t\t\tfinal HystrixProperty<Integer> keepAliveTime, final TimeUnit unit,\n\t\t\tfinal BlockingQueue<Runnable> workQueue) {\n\n\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - default [threadPoolKey=\" + threadPoolKey.name() + \", corePoolSize=\"\n\t\t\t\t+ corePoolSize.get() + \", maximumPoolSize=\" + maximumPoolSize.get() + \", keepAliveTime=\"\n\t\t\t\t+ keepAliveTime.get() + \", unit=\" + unit.name() + \"], override with [threadPoolKey=\"\n\t\t\t\t+ threadPoolKey.name() + \", corePoolSize=\" + CORE_POOL_SIZE + \", maximumPoolSize=\" + MAX_POOL_SIZE\n\t\t\t\t+ \", keepAliveTime=\" + KEEP_ALIVE_TIME + \", unit=\" + TimeUnit.SECONDS.name() + \"]\");\n\n\t\tif (threadFactory != null) {\n\t\t\t// All threads will run as part of this application component.\n\t\t\tfinal ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(CORE_POOL_SIZE, MAX_POOL_SIZE,\n\t\t\t\t\tKEEP_ALIVE_TIME, TimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(BLOCKING_QUEUE_SIZE),\n\t\t\t\t\tthis.threadFactory);\n\n\t\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - initialized threadpool executor [threadPoolKey=\"\n\t\t\t\t\t+ threadPoolKey.name() + \"]\");\n\n\t\t\treturn threadPoolExecutor;\n\t\t} else {\n\t\t\tLOGGER.warn(LOG_PREFIX + \"getThreadPool - fallback to Hystrix default thread pool executor.\");\n\n\t\t\treturn super.getThreadPool(threadPoolKey, corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue);\n\t\t}\n\t}",
"private static void threadPoolInit() {\n ExecutorService service = Executors.newCachedThreadPool();\n try {\n for (int i = 1; i <= 10; i++) {\n service.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" 办理业务...\");\n });\n try {\n TimeUnit.MILLISECONDS.sleep(1L);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n } finally {\n service.shutdown();\n }\n }",
"private synchronized void addTask(Runnable runnable) {\r\n mTaskQueue.add(runnable);\r\n try {\r\n if (mPoolThreadHandler==null){\r\n mSemaphorePoolThreadHandler.acquire();\r\n }\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n\r\n mPoolThreadHandler.sendEmptyMessage(0x110);\r\n }",
"@Override\n protected ExecutorService createDefaultExecutorService() {\n return null;\n }",
"public interface IHttpThreadExecutor {\n public void addTask(Runnable runnable);\n}",
"public static void main(String[] args)\n {\n Runnable r1 = new Task1();\n // Creates Thread task\n Task2 r2 = new Task2();\n ExecutorService pool = Executors.newFixedThreadPool(MAX_T);\n\n pool.execute(r1);\n r2.start();\n\n // pool shutdown\n pool.shutdown();\n }",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"public static void main(String[] args)\n\t{\n\t\tint coreCount = Runtime.getRuntime().availableProcessors();\n\t\t//Create the pool\n\t\tExecutorService ec = Executors.newCachedThreadPool(); //Executors.newFixedThreadPool(coreCount);\n\t\tfor(int i=0;i<100;i++) \n\t\t{\n\t\t\t//Thread t = new Thread(new Task());\n\t\t\t//t.start();\n\t\t\tec.execute(new Task());\n\t\t\tSystem.out.println(\"Thread Name under main method:-->\"+Thread.currentThread().getName());\n\t\t}\n\t\t\n\t\t//for scheduling tasks\n\t\tScheduledExecutorService service = Executors.newScheduledThreadPool(10);\n\t\tservice.schedule(new Task(), 10, TimeUnit.SECONDS);\n\t\t\n\t\t//task to run repetatively 10 seconds after previous taks completes\n\t\tservice.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\t\t\n\t}",
"public void testCallable1() throws Exception {\n Callable c = Executors.callable(new NoOpRunnable());\n assertNull(c.call());\n }",
"public ThreadPool()\r\n {\r\n // 20 seconds of inactivity and a worker gives up\r\n suicideTime = 20000;\r\n // half a second for the oldest job in the queue before\r\n // spawning a worker to handle it\r\n spawnTime = 500;\r\n jobs = null;\r\n activeThreads = 0;\r\n askedToStop = false;\r\n }",
"ScheduledExecutorService getExecutorService();",
"@Override\n\tpublic void execute() {\n\t\tThreadPool pool=ThreadPool.getInstance();\n\t\tpool.beginTaskRun(this);\n\t}",
"public MultiThreadBatchTaskEngine(int aNThreads)\n {\n setMaxThreads(aNThreads);\n }",
"public boolean isPoolingEnabled();",
"int getPoolSize();",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"@Test\n public void launchesEventhandlerThreadpoolMaxsizeTest() {\n // TODO: test launchesEventhandlerThreadpoolMaxsize\n }",
"@Test\n\tpublic void addNormalConcurrentTP10_1000() throws Exception {\n\t\tExecutorService exec = Executors.newFixedThreadPool(10);\n\t\tfinal AtomicInteger count = new AtomicInteger(0);\n\t\t\n\t\tretryManager.registerCallback(new RetryCallback() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic boolean onEvent(RetryHolder retry) throws Exception {\n\t\t\t\t\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}, TYPE);\n\t\t\n\t\tfor (int i=0;i<1000;i++) {\n\t\t\texec.submit(new Runnable() {\n\t\t\t\t\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\tRetryHolder holder = new RetryHolder(\"id-local\"+ count.getAndIncrement(), TYPE,new Exception(),\"Object\");\n\t\t\t\t\t\n\t\t\t\t\tretryManager.addRetry(holder);\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t\texec.shutdown();\n\t\texec.awaitTermination(10, TimeUnit.SECONDS);\n\t\tint localQueueSize = retryManager.getLocalQueuer().size(TYPE);\n\t\tAssert.assertEquals(0,localQueueSize);\n\t\tAssert.assertEquals(1000, retryManager.getH1().getMap(TYPE).size() );\n\t\t\t\t\n\t\t//synchronous add, check immediately\t\t\n\t\tfor (int i=0;i<1000;i++ ) {\n\t\t\tAssert.assertNotNull(\n\t\t\t\t\tretryManager.getH1().getMap(TYPE).get(\"id-local\"+i)\n\t\t\t\t\t);\n\t\t\tretryManager.removeRetry(\"id-local\"+i, TYPE);\n\t\t}\n\t\t\n\t}",
"@SuppressWarnings({ \"rawtypes\", \"unchecked\" })\r\n\tpublic static void main(String[] args) throws InterruptedException, ExecutionException{\n\t\tExecutorService e = Executors.newFixedThreadPool(2);\r\n//\t\tList<Future> list = new ArrayList<Future>();\r\n\t\tfor(int i=0;i<10;i++){\r\n\t\t\tCallable c = new JavaTestThread(i);\r\n\t\t\tFuture f = e.submit(c);\r\n\t\t\tSystem.out.println(\"-------\"+ f.get().toString());\r\n\t\t}\r\n\t\t\r\n\t\r\n\t\t\r\n\t}",
"@Override\n\t\t\tprotected void beforeExecute(Thread t, Runnable r) {\n\t\t\t\tint qsize = getQueue().size();\n\t\t\t\tif(initCorePoolSize>0&&getCorePoolSize()<getMaximumPoolSize()\n\t\t\t\t\t&& qsize > 0 && (qsize%divisor) == 0){\n\t\t\t\t\tsetCorePoolSize(getCorePoolSize()+1); // 进行动态增加\n\t\t\t\t}\n\t\t\t}",
"@Bean(name = \"process-response\")\n\tpublic Executor threadPoolTaskExecutor() {\n\t\tThreadPoolTaskExecutor x = new ThreadPoolTaskExecutor();\n\t\tx.setCorePoolSize(poolProcessResponseCorePoolSize);\n\t\tx.setMaxPoolSize(poolProcessResponseMaxPoolSize);\n\t\treturn x;\n\t}",
"public static void main(String[] args) {\n\t\tList<Future<String>> futureList = new ArrayList<Future<String>>();\r\n\r\n\t\t//collection of multiple tasks which we are supposed to give to thread pool to perform\r\n\t\tList<CallableDemo> taskList = new ArrayList<CallableDemo>();\r\n\t\t//adding multiple tasks to collection (tasks are created using 'Callable' Interface.\r\n\t\ttaskList.add(new CallableDemo(\"first\"));\r\n\t\ttaskList.add(new CallableDemo(\"second\"));\r\n\t\ttaskList.add(new CallableDemo(\"third\"));\r\n\t\ttaskList.add(new CallableDemo(\"fourth\"));\r\n\t\ttaskList.add(new CallableDemo(\"fifth\"));\r\n\t\ttaskList.add(new CallableDemo(\"sixth\"));\r\n\t\ttaskList.add(new CallableDemo(\"seventh\"));\r\n\r\n\t\t//creating a thread pool of size four\r\n\t\tExecutorService threadPool = Executors.newFixedThreadPool(4);\r\n\t\t\r\n\t\tfor (CallableDemo task : taskList) {\r\n\t\t\tfutureList.add(threadPool.submit(task));\r\n\t\t}\r\n threadPool.shutdown();\r\n\t\tfor (Future<String> future : futureList) {\r\n\t\t\ttry {\r\n//\t\t\t\t System.out.println(future.get());\r\n\t\t\t\tSystem.out.println(future.get(1L, TimeUnit.SECONDS));\r\n\t\t\t} catch (InterruptedException | ExecutionException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}catch (TimeoutException e) {\r\n\t\t\t\tSystem.out.println(\"Sorry already waited for result for 1 second , can't wait anymore...\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t}",
"public static void main(String[] args) {\n\n ScheduledExecutorService service = Executors.newScheduledThreadPool(4);\n\n //task to run after 10 seconds delay\n service.schedule(new Task(), 10, TimeUnit.SECONDS);\n\n //task to repeatedly every 10 seconds\n service.scheduleAtFixedRate(new Task(), 15, 10, TimeUnit.SECONDS);\n\n //task to run repeatedly 10 seconds after previous task completes\n service.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\n\n for (int i = 0; i < 100; i++) {\n System.out.println(\"task number - \" + i + \" \");\n service.execute(new Task());\n }\n System.out.println(\"Thread name: \" + Thread.currentThread().getName());\n\n }",
"private synchronized void execute(TestRunnerThread testRunnerThread) {\n boolean hasSpace = false;\n while(!hasSpace) {\n threadLock.lock();\n try {\n hasSpace = currentThreads.size()<capacity;\n }\n finally {\n threadLock.unlock();\n }\n }\n \n //Adding thread to list and executing it\n threadLock.lock();\n try {\n currentThreads.add(testRunnerThread);\n testRunnerThread.setThreadPoolListener(this);\n Thread thread = new Thread(testRunnerThread);\n //System.out.println(\"Starting thread for \"+testRunnerThread.getTestRunner().getTestName());\n thread.start();\n }\n finally {\n threadLock.unlock();\n }\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(threadNum, threadNum, 10L, TimeUnit.SECONDS, linkedBlockingDeque);\n\n final CountDownLatch countDownLatch = new CountDownLatch(NUM);\n\n long start = System.currentTimeMillis();\n\n for (int i = 0; i < NUM; i++) {\n threadPoolExecutor.execute(\n () -> {\n inventory--;\n System.out.println(\"线程执行:\" + Thread.currentThread().getName());\n\n countDownLatch.countDown();\n }\n );\n }\n\n threadPoolExecutor.shutdown();\n\n try {\n countDownLatch.await();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n long end = System.currentTimeMillis();\n System.out.println(\"执行线程数:\" + NUM + \" 总耗时:\" + (end - start) + \" 库存数为:\" + inventory);\n }",
"int getMaximumPoolSize();",
"@ProviderType\npublic interface ThreadPoolMBean {\n\n /**\n * Retrieve the block policy of the thread pool.\n * \n * @return the block policy\n */\n String getBlockPolicy();\n\n /**\n * Retrieve the active count from the pool's Executor.\n * \n * @return the active count or -1 if the thread pool does not have an Executor\n */\n int getExecutorActiveCount();\n\n /**\n * Retrieve the completed task count from the pool's Executor.\n * \n * @return the completed task count or -1 if the thread pool does not have an Executor\n */\n long getExecutorCompletedTaskCount();\n\n /**\n * Retrieve the core pool size from the pool's Executor.\n * \n * @return the core pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorCorePoolSize();\n\n /**\n * Retrieve the largest pool size from the pool's Executor.\n * \n * @return the largest pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorLargestPoolSize();\n\n /**\n * Retrieve the maximum pool size from the pool's Executor.\n * \n * @return the maximum pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorMaximumPoolSize();\n\n\n /**\n * Retrieve the pool size from the pool's Executor.\n * \n * @return the pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorPoolSize();\n\n\n /**\n * Retrieve the task count from the pool's Executor. This is the total number of tasks, which\n * have ever been scheduled to this threadpool. They might have been processed yet or not.\n * \n * @return the task count or -1 if the thread pool does not have an Executor\n */\n long getExecutorTaskCount();\n \n \n /**\n * Retrieve the number of tasks in the work queue of the pool's Executor. These are the\n * tasks which have been already submitted to the threadpool, but which are not yet executed.\n * @return the number of tasks in the work queue -1 if the thread pool does not have an Executor\n */\n long getExcutorTasksInWorkQueueCount();\n\n /**\n * Return the configured max thread age.\n *\n * @return The configured max thread age.\n * @deprecated Since version 1.1.1 always returns -1 as threads are no longer retired\n * but instead the thread locals are cleaned up (<a href=\"https://issues.apache.org/jira/browse/SLING-6261\">SLING-6261</a>)\n */\n @Deprecated\n long getMaxThreadAge();\n\n /**\n * Return the configured keep alive time.\n * \n * @return The configured keep alive time.\n */\n long getKeepAliveTime();\n\n /**\n * Return the configured maximum pool size.\n * \n * @return The configured maximum pool size.\n */\n int getMaxPoolSize();\n\n /**\n * Return the minimum pool size.\n * \n * @return The minimum pool size.\n */\n int getMinPoolSize();\n\n /**\n * Return the name of the thread pool\n * \n * @return the name\n */\n String getName();\n\n /**\n * Return the configuration pid of the thread pool.\n * \n * @return the pid\n */\n String getPid();\n\n /**\n * Return the configured priority of the thread pool.\n * \n * @return the priority\n */\n String getPriority();\n\n /**\n * Return the configured queue size.\n * \n * @return The configured queue size.\n */\n int getQueueSize();\n\n /**\n * Return the configured shutdown wait time in milliseconds.\n * \n * @return The configured shutdown wait time.\n */\n int getShutdownWaitTimeMs();\n\n /**\n * Return whether or not the thread pool creates daemon threads.\n * \n * @return The daemon configuration.\n */\n boolean isDaemon();\n\n /**\n * Return whether or not the thread pool is configured to shutdown gracefully.\n * \n * @return The graceful shutdown configuration.\n */\n boolean isShutdownGraceful();\n\n /**\n * Return whether or not the thread pool is in use.\n * \n * @return The used state of the pool.\n */\n boolean isUsed();\n\n}",
"public void testDefaultThreadFactory() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n try {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n } catch (SecurityException ok) {\n // Also pass if not allowed to change setting\n }\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }",
"public static GlideExecutor m21519e() {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(0, Integer.MAX_VALUE, f23336b, TimeUnit.MILLISECONDS, new SynchronousQueue(), new C8962a(\"source-unlimited\", UncaughtThrowableStrategy.f23340b, false));\n return new GlideExecutor(threadPoolExecutor);\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n for (int i = 0; i < 10; i++) {\n \tCallable worker = new WorkerThread1(\"\" + i);\n \tFuture future = executor.submit(worker);\n \tSystem.out.println(\"Results\"+future.get());\n //executor.execute(worker);\n }\n executor.shutdown();\n while (!executor.isTerminated()) {\n }\n System.out.println(\"Finished all threads\");\n }",
"public static void main(String[] args) {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(2, 2, 0, TimeUnit.NANOSECONDS, new ArrayBlockingQueue<>(10));\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"all task over!\");\n threadPoolExecutor.shutdown();\n }",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public interface Executor<Work extends Runnable> {\n void execute(Work work);\n\n void shutdown();\n\n void addWorks(Work work);\n\n void removeWorks(int num);\n\n int getWorkSize();\n}",
"public static void main(String[] args) {\n ExecutorService threadPool = Executors.newCachedThreadPool();\n\n try{\n for (int i = 0; i < 10; i++) {\n threadPool.execute(() ->{\n System.out.println(Thread.currentThread().getName()+\"\\t 办理业务\");\n });\n //try {TimeUnit.SECONDS.sleep(1); } catch (InterruptedException e) {e.printStackTrace();}\n }\n\n } catch (Exception e) {\n e.printStackTrace();\n }finally {\n threadPool.shutdown();\n }\n\n\n\n }",
"void submitAndWaitForAll(Iterable<Runnable> tasks);",
"public static void main(String args[])\n {\n\t ScheduledExecutorService executorService= Executors.newScheduledThreadPool(2);\n\t Runnable task1=new RunnableChild(\"task1\");\n\t Runnable task2=new RunnableChild(\"task2\");\n\t Runnable task3=new RunnableChild(\"task3\");\n\t executorService.submit(task1);\n\t executorService.submit(task2);\n\t executorService.submit(task3);\n\t executorService.schedule(task1,20, TimeUnit.SECONDS);\n\t System.out.println(\"*******shutting down called\");\n\t executorService.shutdown();\n }",
"interface Runnable {\n void execute() throws Throwable;\n default void run() {\n try {\n execute();\n } catch(Throwable t) {\n throw new RuntimeException(t);\n }\n }\n }",
"public interface ThreadExecutor extends Executor {\n}",
"protected abstract void createPool();",
"static ExecutorService boundedNamedCachedExecutorService(int maxThreadBound, String poolName, long keepalive, int queueSize, RejectedExecutionHandler abortPolicy) {\n\n ThreadFactory threadFactory = new NamedThreadFactory(poolName);\n LinkedBlockingQueue<Runnable> queue = new LinkedBlockingQueue<Runnable>(queueSize);\n\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(\n maxThreadBound,\n maxThreadBound,\n keepalive,\n TimeUnit.SECONDS,\n queue,\n threadFactory,\n abortPolicy\n );\n\n threadPoolExecutor.allowCoreThreadTimeOut(true);\n\n return threadPoolExecutor;\n }",
"public EngineConcurrency() {\n Runtime runtime = Runtime.getRuntime();\n int threads = runtime.availableProcessors();\n if (threads > 1) {\n threads++;\n }\n this.executor = Executors.newFixedThreadPool(threads);\n }",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"public abstract void submit(Runnable runnable);",
"protected ThreadPool getPool()\r\n {\r\n return threadPool_;\r\n }",
"public static void main(String args[]) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n //create a list to hold the Future object associated with Callable\n Map<Integer, Future<String>> map = new HashMap<Integer, Future<String>>();\n //Create MyCallable instance\n for (int i = 0; i < 10; i++) {\n Callable<String> callable = new MyCallable(\"\" + i);\n //submit Callable tasks to be executed by thread pool\n Future<String> future = executor.submit(callable);\n\n //add Future to the list, we can get return value using Future\n map.put(i, future);\n }\n System.out.println(\"Assigned\");\n map.forEach(MyCallable::handleResult);\n// for (Future<String> fut : list) {\n// try {\n// //print the return value of Future, notice the output delay in console\n// // because Future.get() waits for task to get completed\n// System.out.println(new Date() + \"::\" + fut.get());\n// } catch (InterruptedException e) {\n// e.printStackTrace();\n// } catch (ExecutionException e) {\n// System.out.println(\"Handled in main thread - Crash\");\n// }\n// }\n System.out.println(\"About to shutdown\");\n //shut down the executor service now\n executor.shutdown();\n System.out.println(\"Shutdown\");\n }"
] | [
"0.70430773",
"0.6852535",
"0.673844",
"0.6681156",
"0.6555826",
"0.65535015",
"0.6504719",
"0.626137",
"0.62439007",
"0.62385195",
"0.6229549",
"0.6206264",
"0.6196264",
"0.6187316",
"0.6183845",
"0.6178413",
"0.6134481",
"0.6133776",
"0.6100384",
"0.60999155",
"0.6060156",
"0.6056727",
"0.60175526",
"0.5994021",
"0.59823835",
"0.5980842",
"0.5954037",
"0.5951284",
"0.5940622",
"0.5934233",
"0.588106",
"0.587526",
"0.5865893",
"0.584526",
"0.5835883",
"0.5835708",
"0.58253396",
"0.5823577",
"0.58206743",
"0.58179027",
"0.5811806",
"0.58094776",
"0.5807805",
"0.58026755",
"0.5796729",
"0.5795973",
"0.5787329",
"0.5755659",
"0.5720181",
"0.5717245",
"0.57036275",
"0.570296",
"0.57002825",
"0.5692685",
"0.5685255",
"0.56751174",
"0.56728935",
"0.5660113",
"0.5652542",
"0.5651624",
"0.5639871",
"0.56306684",
"0.5619727",
"0.56092936",
"0.5599805",
"0.5572358",
"0.5572184",
"0.55676454",
"0.5563575",
"0.55442274",
"0.55310667",
"0.5530685",
"0.5525063",
"0.551904",
"0.5506411",
"0.5495727",
"0.54924315",
"0.5488313",
"0.5482263",
"0.54769695",
"0.54696506",
"0.54640526",
"0.5457752",
"0.54569006",
"0.54435444",
"0.5441159",
"0.5440043",
"0.5436141",
"0.54314995",
"0.5427563",
"0.54197776",
"0.5414238",
"0.54029703",
"0.53901345",
"0.538843",
"0.53783005",
"0.5376472",
"0.5375454",
"0.53557247",
"0.53544056"
] | 0.60825986 | 20 |
a newSingleThreadScheduledExecutor successfully runs delayed task | public void testNewSingleThreadScheduledExecutor() throws Exception {
final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();
try (PoolCleaner cleaner = cleaner(p)) {
final CountDownLatch proceed = new CountDownLatch(1);
final Runnable task = new CheckedRunnable() {
public void realRun() {
await(proceed);
}};
long startTime = System.nanoTime();
Future f = p.schedule(Executors.callable(task, Boolean.TRUE),
timeoutMillis(), MILLISECONDS);
assertFalse(f.isDone());
proceed.countDown();
assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));
assertSame(Boolean.TRUE, f.get());
assertTrue(f.isDone());
assertFalse(f.isCancelled());
assertTrue(millisElapsedSince(startTime) >= timeoutMillis());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void runPeriodic() {\n boolean ok = ScheduledFutureTask.super.runAndReset();\n boolean down = isShutdown();\n // Reschedule if not cancelled and not shutdown or policy allows\n if (ok && !down) {\n updateNextExecutionTime();\n MeasurableScheduler.super.getQueue().add(this);\n }\n // This might have been the final executed delayed\n // task. Wake up threads to check.\n else if (down)\n interruptIdleWorkers();\n }",
"@Scheduled(fixedDelay = 3000)\n\tpublic void scheduleTaskWithFixedDelay() {\n\t\tlog.info(\"Fixed Delay Task :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t\t//Sleep TimeUnit\n//\t\ttry {\n//\t\t\tTimeUnit.SECONDS.sleep(5);\n//\t\t} catch (Exception e) {\n//\t\t\tlog.error(\"Ran into an error {}\", e);\n//\t throw new IllegalStateException(e);\n//\t\t}\n\t}",
"private void scheduledTask() {\n connectToNewViews();\n removeDisconnectedViews();\n try {\n Thread.sleep(SCHEDULED_TASK_PERIOD);\n // Scheduling future execution\n\n synchronized (threadPool) {\n if (!threadPool.isShutdown()) {\n threadPool.execute(this::scheduledTask);\n }\n }\n } catch (InterruptedException e) {\n Thread.currentThread().interrupt();\n }\n }",
"@Scheduled(fixedDelay=5000) //indicamos que esta tarea se repetira cada 5 segundos \n\tpublic void doTask() {\n\t\tLOGGER.info(\"Time is: \"+ new Date());\n\t}",
"ScheduledFuture<?> scheduleTask(long delay, Runnable runnable) {\n return timeoutTaskExecutor.schedule(runnable, delay, TimeUnit.MILLISECONDS);\n }",
"@Test\n @DisplayName(\"Scheduled Future\")\n void testScheduledFuture() throws InterruptedException {\n ScheduledExecutorService executor = Executors.newScheduledThreadPool(1);\n ScheduledFuture<String> future = executor.schedule(this::getThreadName, 3, TimeUnit.SECONDS);\n\n TimeUnit.MILLISECONDS.sleep(1337);\n long remainingTime = future.getDelay(TimeUnit.MILLISECONDS);\n\n assertThat(remainingTime).isBetween(1650L, 1670L);\n }",
"private void schedule() {\n service.scheduleDelayed(task, schedulingInterval);\n isScheduled = true;\n }",
"void executeAsync(long delayMs, Runnable task);",
"public void run() {\n long start = System.nanoTime();\n try {\n activeCount.inc();\n long delay = start - nextExecutionTime;//实践执行时间-理论应该执行的实际点\n taskExecutionDelay.record(delay, TimeUnit.NANOSECONDS);\n // real logic\n if (isPeriodic())\n runPeriodic();\n else\n ScheduledFutureTask.super.run();\n } finally {\n activeCount.dec();\n taskExecutionTime.record(System.currentTimeMillis() - start, TimeUnit.MILLISECONDS);\n }\n }",
"void scheduleTask(long delay) {\n executorService.schedule(\n backgroundTask, delay, TimeUnit.MILLISECONDS);\n }",
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"private static Future<?> directExecute(Runnable runnable, long delay) {\n Future<?> future = null;\n if (delay > 0) {\n /* no serial, but a delay: schedule the task */\n if (!(executor instanceof ScheduledExecutorService)) {\n throw new IllegalArgumentException(\"The executor set does not support scheduling\");\n }\n ScheduledExecutorService scheduledExecutorService = (ScheduledExecutorService) executor;\n future = scheduledExecutorService.schedule(runnable, delay, TimeUnit.MILLISECONDS);\n } else {\n if (executor instanceof ExecutorService) {\n ExecutorService executorService = (ExecutorService) executor;\n future = executorService.submit(runnable);\n } else {\n /* non-cancellable task */\n executor.execute(runnable);\n }\n }\n return future;\n }",
"@Scheduled(fixedRate = 2000, initialDelay = 5000)\n\tpublic void scheduleTaskWithInitialDelay() {\n\t\tlog.info(\"Fixed Rate Task With Initial Delay :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"public Future<?> scheduleOneShot(long delay, Runnable runnable) {\n\t\tif (!Raptor.getInstance().isDisposed() && !isDisposed) {\n\t\t\ttry {\n\t\t\t\treturn executor.schedule(new RunnableExceptionDecorator(\n\t\t\t\t\t\trunnable), delay, TimeUnit.MILLISECONDS);\n\t\t\t} catch (RejectedExecutionException rej) {\n\t\t\t\tif (!Raptor.getInstance().isDisposed()) {\n\t\t\t\t\tLOG.error(\"Error executing runnable in scheduleOneShot: \",\n\t\t\t\t\t\t\trej);\n\t\t\t\t\tthreadDump();\n\t\t\t\t\tRaptor.getInstance().onError(\n\t\t\t\t\t\t\t\"ThreadServie has no more threads. A thread dump can be found at \"\n\t\t\t\t\t\t\t\t\t+ THREAD_DUMP_FILE_PATH);\n\t\t\t\t}\n\t\t\t\treturn null;\n\t\t\t}\n\t\t} else {\n\t\t\tLOG.info(\"Veoting runnable \" + runnable + \" raptor is disposed.\");\n\t\t\treturn null;\n\t\t}\n\t}",
"private void beginSchedule(){\n\t\tDivaApp.getInstance().submitScheduledTask(new RandomUpdater(this), RandomUpdater.DELAY, RandomUpdater.PERIOD);\n\t}",
"public long runScheduledPendingTasks() {\n/* */ try {\n/* 597 */ return this.loop.runScheduledTasks();\n/* 598 */ } catch (Exception e) {\n/* 599 */ recordException(e);\n/* 600 */ return this.loop.nextScheduledTask();\n/* */ } \n/* */ }",
"@Scheduled(fixedRate = 2000, initialDelay = 5000)\n public void scheduleTaskWithInitialDelay() {\n logger.info(\"Fixed Rate Task with Initial Delay :: Execution Time - {}\", formatter.format(LocalDateTime.now()));\n }",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"@Override\n public void execute() {\n Time.sleep(3000);\n Starting.execute();\n }",
"@Override\n public boolean isDelayedExecutionSupported()\n {\n return true;\n }",
"@Scheduled(fixedRate = 2000)\n\tpublic void scheduleTaskWithFixedRate() {\n\t\tlog.info(\"Fixed Rate Task :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()) );\n\t}",
"@Override\n public void doTask() throws InterruptedException {\n Thread.sleep(5000);\n }",
"public void schedule() {\n cancel();\n timer.schedule(new TimerTask() {\n @Override\n public void run() {\n runnable.run();\n }\n }, delay);\n }",
"public static void main(String[] args) {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(3);\n scheduledThreadPoolExecutor.setRemoveOnCancelPolicy(true);\n SystemOutUtil.println(\"start schedule\");\n scheduledThreadPoolExecutor.schedule(new DelayCallableTask(), 1000, TimeUnit.MILLISECONDS);\n RunnableScheduledFuture<?> rateFuture =\n (RunnableScheduledFuture<?>) scheduledThreadPoolExecutor\n .scheduleAtFixedRate(new FixRateRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n ScheduledFuture delayFuture =\n scheduledThreadPoolExecutor.scheduleWithFixedDelay(new FixDelayRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n SystemOutUtil.println(\"end schedule\");\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"start stop\");\n\n// scheduledThreadPoolExecutor.remove(rateFuture); // 无效\n rateFuture.cancel(false);\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n scheduledThreadPoolExecutor.shutdown();\n return;\n }",
"@Test\n public void testTask() throws InterruptedException {\n\n SchedulingRunnable task1 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task1, \"0/15 * * * * ?\");\n Thread.sleep(10000);\n\n SchedulingRunnable task2 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task2, \"0/8 * * * * ?\");\n // 便于观察\n\n Thread.sleep(3000000);\n }",
"private void scheduleNext() {\n lock.lock();\n try {\n active = tasks.poll();\n if (active != null) {\n executor.execute(active);\n terminating.signalAll();\n } else {\n //As soon as a SerialExecutor is empty, we remove it from the executors map.\n if (lock.isHeldByCurrentThread() && isEmpty() && this == serialExecutorMap.get(identifier)) {\n serialExecutorMap.remove(identifier);\n terminating.signalAll();\n if (state == State.SHUTDOWN && serialExecutorMap.isEmpty()) {\n executor.shutdown();\n }\n }\n }\n } finally {\n lock.unlock();\n }\n }",
"public void run(){\n Timer time = new Timer(); // Instantiate Timer Object\n\n ScheduledClass st = new ScheduledClass(this.job,this.shm,time,this.stopp); // Instantiate SheduledTask class\n time.schedule(st, 0, this.periodicwait); // Create Repetitively task for every 1 secs\n }",
"private void handleActionOnce() {\n // TODO: Handle action\n try {\n Executors.newScheduledThreadPool(1).submit(new NewsReceiveTask(getApplicationContext() , true));\n } catch (Exception e) {\n e.printStackTrace();\n }\n }",
"public void schedule(Runnable job, long delay, TimeUnit unit);",
"ScheduledExecutorService getScheduledExecutorService();",
"private void scheduleJob() {\n Log.d(TAG, \"Long lived task is done.\");\n }",
"public void startTaskTriggerCheckerThread() {\n new Thread(new Runnable() {\n @Override\n public void run() {\n canRunEnqueueTaskThread.set(true);\n while(canRunEnqueueTaskThread.get()) {\n try {\n Thread.sleep(1000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n if(taskEnqueued.get() || canRunTaskThread.get()) { //do not enqueue the task if an instance of that task is already enqueued or running.\n continue;\n //log(PrioritizedReactiveTask.this.getClass().getSimpleName() + \" already in queue or is currently executing\");\n } else if(shouldTaskActivate()) {\n System.out.println(\"Thread \" + Thread.currentThread().getId() + \" enqueued task: \" + this.getClass().getSimpleName());\n taskQueue.add(PrioritizedReactiveTask.this);\n activeTasks.add(PrioritizedReactiveTask.this);\n taskEnqueued.set(true);\n try {\n Thread.sleep(5000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n }\n }).start();\n }",
"private void async(Runnable runnable) {\n Bukkit.getScheduler().runTaskAsynchronously(KitSQL.getInstance(), runnable);\n }",
"public static void syncLater(long delay, Run runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\trunnable.run();\n\t\t\t}\n\t\t}.runTaskLater(AreaShop.getInstance(), delay);\n\t}",
"public void testUnconfigurableScheduledExecutorService() throws Exception {\n final ScheduledExecutorService p =\n Executors.unconfigurableScheduledExecutorService\n (Executors.newScheduledThreadPool(2));\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public void runPendingTasks() {\n/* */ try {\n/* 578 */ this.loop.runTasks();\n/* 579 */ } catch (Exception e) {\n/* 580 */ recordException(e);\n/* */ } \n/* */ \n/* */ try {\n/* 584 */ this.loop.runScheduledTasks();\n/* 585 */ } catch (Exception e) {\n/* 586 */ recordException(e);\n/* */ } \n/* */ }",
"private void onComplete(int duration) {\n\t\t\n\t\tservice = Executors.newSingleThreadExecutor();\n\n\t\ttry {\n\t\t Runnable r = new Runnable() {\n\t\t @Override\n\t\t public void run() {\n\t\t // Database task\n\t\t \tcontrollerVars.setPlays(false);\n\t\t }\n\t\t };\n\t\t Future<?> f = service.submit(r);\n\n\t\t f.get(duration, TimeUnit.MILLISECONDS); // attempt the task for two minutes\n\t\t}\n\t\tcatch (final InterruptedException e) {\n\t\t // The thread was interrupted during sleep, wait or join\n\t\t}\n\t\tcatch (final TimeoutException e) {\n\t\t // Took too long!\n\t\t}\n\t\tcatch (final ExecutionException e) {\n\t\t // An exception from within the Runnable task\n\t\t}\n\t\tfinally {\n\t\t service.shutdown();\n\t\t}\t\t\n\t}",
"void restartEventsWithDelay(final boolean longDelay, final boolean alsoRescan, final boolean unblockEventsRun,\n final int logType)\n {\n if (longDelay) {\n\n Data workData = new Data.Builder()\n .putBoolean(PhoneProfilesService.EXTRA_ALSO_RESCAN, alsoRescan)\n .putBoolean(PhoneProfilesService.EXTRA_UNBLOCK_EVENTS_RUN, unblockEventsRun)\n .putInt(PhoneProfilesService.EXTRA_LOG_TYPE, logType)\n .build();\n\n OneTimeWorkRequest restartEventsWithDelayWorker;\n restartEventsWithDelayWorker =\n new OneTimeWorkRequest.Builder(RestartEventsWithDelayWorker.class)\n .addTag(RestartEventsWithDelayWorker.WORK_TAG_2)\n .setInputData(workData)\n .setInitialDelay(15, TimeUnit.SECONDS)\n .build();\n try {\n if (PPApplicationStatic.getApplicationStarted(true, true)) {\n WorkManager workManager = PPApplication.getWorkManagerInstance();\n if (workManager != null) {\n\n// //if (PPApplicationStatic.logEnabled()) {\n// ListenableFuture<List<WorkInfo>> statuses;\n// statuses = workManager.getWorkInfosForUniqueWork(RestartEventsWithDelayWorker.WORK_TAG);\n// try {\n// List<WorkInfo> workInfoList = statuses.get();\n// } catch (Exception ignored) {\n// }\n// //}\n\n// PPApplicationStatic.logE(\"[WORKER_CALL] DataWrapper.restartEventsWithDelay\", \"xxx\");\n //workManager.enqueue(restartEventsWithDelayWorker);\n //if (replace)\n workManager.enqueueUniqueWork(RestartEventsWithDelayWorker.WORK_TAG_2, ExistingWorkPolicy.REPLACE, restartEventsWithDelayWorker);\n //else\n // workManager.enqueueUniqueWork(RestartEventsWithDelayWorker.WORK_TAG_APPEND, ExistingWorkPolicy.APPEND_OR_REPLACE, restartEventsWithDelayWorker);\n }\n }\n } catch (Exception e) {\n PPApplicationStatic.recordException(e);\n }\n } else {\n// PPApplicationStatic.logE(\"[EXECUTOR_CALL] ***** DataWrapper.restartEventsWithDelay\", \"schedule\");\n\n final Context appContext = context.getApplicationContext();\n //final ScheduledExecutorService worker = Executors.newSingleThreadScheduledExecutor();\n Runnable runnable = () -> {\n// long start = System.currentTimeMillis();\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] ***** DataWrapper.restartEventsWithDelay\", \"--------------- START\");\n\n PowerManager powerManager = (PowerManager) appContext.getSystemService(Context.POWER_SERVICE);\n PowerManager.WakeLock wakeLock = null;\n try {\n if (powerManager != null) {\n wakeLock = powerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, PPApplication.PACKAGE_NAME + \":DataWrapper_restartEventsWithDelay\");\n wakeLock.acquire(10 * 60 * 1000);\n }\n\n //PPExecutors.doRestartEventsWithDelay(alsoRescan, unblockEventsRun, logType, context);\n\n DataWrapper dataWrapper = new DataWrapper(appContext, false, 0, false, 0, 0, 0f);\n if (logType != PPApplication.ALTYPE_UNDEFINED)\n PPApplicationStatic.addActivityLog(appContext, logType, null, null, \"\");\n //dataWrapper.restartEvents(unblockEventsRun, true, true, false);\n dataWrapper.restartEventsWithRescan(alsoRescan, unblockEventsRun, false, false, true, false);\n //dataWrapper.invalidateDataWrapper();\n\n\n// long finish = System.currentTimeMillis();\n// long timeElapsed = finish - start;\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] ***** DataWrapper.restartEventsWithDelay\", \"--------------- END - timeElapsed=\"+timeElapsed);\n } catch (Exception e) {\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] PPApplication.startHandlerThread\", Log.getStackTraceString(e));\n PPApplicationStatic.recordException(e);\n } finally {\n if ((wakeLock != null) && wakeLock.isHeld()) {\n try {\n wakeLock.release();\n } catch (Exception ignored) {\n }\n }\n //worker.shutdown();\n }\n };\n PPApplicationStatic.createDelayedEventsHandlerExecutor();\n PPApplication.delayedEventsHandlerExecutor.schedule(runnable, 5, TimeUnit.SECONDS);\n }\n }",
"public static void asyncLater(long delay, Run runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\trunnable.run();\n\t\t\t}\n\t\t}.runTaskLaterAsynchronously(AreaShop.getInstance(), delay);\n\t}",
"private void scheduleJob() {\n\n }",
"private SleeperTask()\r\n\t{\r\n\t\ttimer = new Timer();\r\n\t\tprovider = null;\r\n\t\taction = \"\";\r\n\t\tverbose = false;\r\n\t\tsetRepeat(5);\r\n\t}",
"@Scheduled(fixedDelay = 15000)\n\tpublic void scheduleFixedDelayTask() {\n\t\t\n\t\tList<Tx> listaTx = txRepo.findAll();\n\t\t\n\t\tfor (Tx tx : listaTx) {\n\t\t\tif(tx.getStatus().equals(TxStatus.PENDING)) {\n\t\t\t\tSystem.out.println(\n\t\t\t\t\t \"Fixed delay task - \" + System.currentTimeMillis() / 20000);\n\t\t\t\t//to be implemented\n\t\t\t\t\n\t\t\t\tString auth = \"Bearer \" + tx.getSbi().getBitcoinAddress();\n\t\t\t\tHttpHeaders headers = new HttpHeaders();\n\t\t\t\theaders.add(\"Authorization\", auth);\n\t\t\t\t\n\t\t\t\tInteger orderId = tx.getorder_id();\n\t\t\t\t\n\t\t\t\tGetOrderResponseDTO getOrderDTO = new GetOrderResponseDTO();\n\t\t\t\t\n\t\t\t ResponseEntity<Object> responseEntity = new RestTemplate().exchange(\"https://api-sandbox.coingate.com/v2/orders/\" + orderId, HttpMethod.GET,\n\t\t\t\t\t\tnew HttpEntity<Object>(getOrderDTO, headers), Object.class);\n\t\t\t \n\t\t\t \n\t\t\t ObjectMapper mapper = new ObjectMapper();\n\t\t\t\tmapper.configure(Feature.ALLOW_UNQUOTED_FIELD_NAMES, true);\n\t\t\t\tGetOrderResponseDTO gorResponse = new GetOrderResponseDTO();\n\t\t\n\t\t\t\tgorResponse = mapper.convertValue(responseEntity.getBody(), GetOrderResponseDTO.class);\n\t\t\n\t\t\t \n\t\t\t System.out.println(\"Order status: \" + gorResponse.getStatus());\n\t\t\t\t\n\t\t\t if(gorResponse.getStatus().equals(\"paid\") || \n\t\t\t \t\tgorResponse.getStatus().equals(\"invalid\") || \n\t\t\t \t\tgorResponse.getStatus().equals(\"expired\") || \n\t\t\t \t\tgorResponse.getStatus().equals(\"canceled\")) {\n\t\t\t \t\n\t\t\t \t//naredne tri linije mi nisu nista jasne zasto sam ovo radio pre mesec dana\n\t\t\t \tTx tx2 = new Tx();\n\t\t \t\ttx2 = txRepo.findByusername(gorResponse.getId());\n\t\t \t\tSystem.out.println(\"TX: \" + tx2.getorder_id());\n\t\t \t\t\n\t\t \t\tRestTemplate restTemplate = new RestTemplate();\n\t\t \t\t\n\t\t \t\tTxInfoDto txInfo;\n\t\t\t \t\n\t\t\t \tif(gorResponse.getStatus().equals(\"paid\")) {\n\t\t\t \t\t\n\t\t\t \t\ttx.setStatus(TxStatus.PAID);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.SUCCESS, \"https://localhost:8764/bitCoin\");\n\t\t\t \t\t\t\n\t\t\t \t} else if(gorResponse.getStatus().equals(\"invalid\")) {\n\t\t\t \t\ttx.setStatus(TxStatus.FAILED);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.FAILED, \"https://localhost:8764/bitCoin\");\n\t\t\t \t} else if(gorResponse.getStatus().equals(\"expired\")){\n\t\t\t \t\ttx.setStatus(TxStatus.EXPIRED);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.FAILED, \"https://localhost:8764/bitCoin\");\n\t\t\t \t} else {\n\t\t\t \t\ttx.setStatus(TxStatus.CANCELED);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.ERROR, \"https://localhost:8764/bitCoin\");\n\t\t\t \t}\n\t\t\t \t\n\t\t\t \ttxRepo.save(tx);\n\t\t \t\tResponseEntity<TxInfoDto> r = restTemplate.postForEntity(\"https://localhost:8111/request/updateTxAfterPaymentIsFinished\", txInfo, TxInfoDto.class);\n\t\t \t\n\t\t\t \t\n\t\t\t \t\n\t\t\t \t\n\t\t\t \t\n\t\t\t }\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\tSystem.out.println(\"Nikom nista\");\n\t\t\t\tlogger.info(\"Scheduled is working...\");\n\t\t\t}\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Nema transakcija :(\");\n\t\t\n\t/*\tif(IS_CREATE) {\n\t\t\tSystem.out.println(\n\t\t\t\t \"Fixed delay task - \" + System.currentTimeMillis() / 20000);\n\t\t\t\t\t\t \t\n\t\t String authToken = STATIC_TOKEN;\n\t\t \n\t\t\tHttpHeaders headers = new HttpHeaders();\n\t\t\theaders.add(\"Authorization\", authToken);\n\t\t\t\n\t\t\tSystem.out.println(\"authtoken : \" + authToken);\n\t\t \n\t\t\tGetOrderResponseDTO getOrderDTO = new GetOrderResponseDTO();\n\t\t\t\n\t\t ResponseEntity<Object> responseEntity = new RestTemplate().exchange(\"https://api-sandbox.coingate.com/v2/orders/\" + STATIC_ID, HttpMethod.GET,\n\t\t\t\t\tnew HttpEntity<Object>(getOrderDTO, headers), Object.class);\n\t\t \n\t\t \n\t\t ObjectMapper mapper = new ObjectMapper();\n\t\t\tmapper.configure(Feature.ALLOW_UNQUOTED_FIELD_NAMES, true);\n\t\t\tGetOrderResponseDTO gorResponse = new GetOrderResponseDTO();\n\t\n\t\t\tgorResponse = mapper.convertValue(responseEntity.getBody(), GetOrderResponseDTO.class);\n\t\n\t\t \n\t\t System.out.println(\"Order status: \" + gorResponse.getStatus());\n\t\t \n\t\t if(gorResponse.getStatus().equals(\"paid\") || gorResponse.getStatus().equals(\"invalid\") || gorResponse.getStatus().equals(\"expired\")) {\n\t\t \t\n\t\t \t/*Tx tx = new Tx();\n\t \t\ttx = txRepo.findByOrder_Id(gorResponse.getId());\n\t \t\tSystem.out.println(\"TX: \" + tx.getorder_id());\n\t\t \t\n\t\t \tif(gorResponse.getStatus().equals(\"paid\")) {\n\t\t \t\t//promenimo u bazi\n\t\t \t\t//txRepo.getOne((Integer)gorResponse.getId());\n\t\t \t\ttx.setStatus(TxStatus.PAID);\n\t\t \t\t\n\t\t \t} else if(gorResponse.getStatus().equals(\"invalid\")) {\n\t\t \t\ttx.setStatus(TxStatus.FAILED);\n\t\t \t} else {\n\t\t \t\ttx.setStatus(TxStatus.EXPIRED);\n\t\t \t}\n\t\t \t\n\t\t \ttxRepo.save(tx);*/\n\t\t /*\t\n\t\t \tIS_CREATE = false;\n\t\t }\n\t\t\t\t\t \n\t\t\t\t \n\t\t} else {\n\t\t\tSystem.out.println(\"Nikom nista\");\n\t\t\tlogger.info(\"Scheduled is working...\");\n\t\t}*/\n\t\t\n\t \n\t \n\t}",
"public static void main(String[] args) {\n\n ScheduledExecutorService service = Executors.newScheduledThreadPool(4);\n\n //task to run after 10 seconds delay\n service.schedule(new Task(), 10, TimeUnit.SECONDS);\n\n //task to repeatedly every 10 seconds\n service.scheduleAtFixedRate(new Task(), 15, 10, TimeUnit.SECONDS);\n\n //task to run repeatedly 10 seconds after previous task completes\n service.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\n\n for (int i = 0; i < 100; i++) {\n System.out.println(\"task number - \" + i + \" \");\n service.execute(new Task());\n }\n System.out.println(\"Thread name: \" + Thread.currentThread().getName());\n\n }",
"public static void main(String[] args) throws Exception, ExecutionException {\n\t\tScheduledExecutorService service=Executors.newSingleThreadScheduledExecutor();\r\n\t\tList<Callable> list=new ArrayList();\r\n\t\tlist.add(new MyCallableBTest());\r\n\t\tlist.add(new MyCallableATest());\r\n\t\tservice.scheduleAtFixedRate(new MyRunnable(),4l,4L,TimeUnit.SECONDS);\r\n\t\t//ScheduledFuture<String> future2=service.schedule(list.get(1),4L,TimeUnit.SECONDS);\r\n\t //System.out.println(future1.get());\r\n\t //System.out.println(future2.get());\r\n\t}",
"public void runDelayedTasks(Class<? extends Task> taskClass) {\n log.info(\"Running delayed tasks...\");\n serializeExecutionOfTasks(delayedTasks, taskClass);\n }",
"@Override\n\t\t\tpublic void run() {\n\t\t\t\tstartRecallJobTask();\n\t\t\t\tmHandler.postDelayed(mHandlerTask, INTERVAL);\n\t\t\t}",
"@Override\r\n\t\tpublic void run() {\n\t\t\tSystem.out.println(\"updateThread\");\r\n\t\t\thandler.postDelayed(updateThread, 3000);\r\n\t\t}",
"public ScheduledFuture<?> schedule(Runnable task, long delay) {\n return executor.schedule(task, delay, TimeUnit.MILLISECONDS);\n }",
"public static void main(String[] args) throws Exception {\n ScheduledExecutorService exec = Executors.newScheduledThreadPool(3);// 3 threads\n\n System.out.println(\"TIME: \" + dateFormatter.format(new Date()));\n\n\n ScheduledFuture<?> sf1 = exec.schedule(new ScheduledTaskB(3000), 4,TimeUnit.SECONDS); // TASK-1\n ScheduledFuture<?> sf2 = exec.schedule(new CalculationTaskD(0,3,3000), 6, TimeUnit.SECONDS); // TASK-2\n\n exec.schedule(new ScheduledTaskB(0), 8, TimeUnit.SECONDS);\n ScheduledFuture<?> sf4 = exec.schedule(new CalculationTaskD(3,4,0), 10 , TimeUnit.SECONDS); // TASK-4\n\n exec.shutdown();\n sf1.cancel(true);\n sf2.cancel(true);\n\n // GET RESULTS ////////////////////////////////////////////////////////////\n\n System.out.println(\"\\n\\n\\nGetting results: \");\n\n /*\n .get() blocks until result is available\n */\n System.out.println(\"TASK-1: \" + sf1.get() + \"\\n\");\n System.out.println(\"TASK-2: \" + sf2.get() + \"\\n\");\n System.out.println(\"TASK-4: \" + sf4.get() + \"\\n\");\n\n\n\n\n\n }",
"@Override\n public void run() {\n // 获取最近一次执行时间并将其格式化。\n SimpleDateFormat simpleDateFormat = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");\n System.out.println(\"Scheduled exec time is: \" + simpleDateFormat.format(scheduledExecutionTime()));\n System.out.println(\"Dancing...\");\n }",
"public <T> ValueFuture<T> schedule(Callable<T> job, long delay, TimeUnit unit);",
"@Override\n\tpublic void execute() {\n\t\tif (!Variables.decreaseTask) {\n\t\t\tVariables.decreaseTask = true;\n\t\t} else {\n\t\t\tVariables.taskAmount--;\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Killing npcs\");\n\t\t\n\t\tif (Variables.status != \"Completing task...\") {\n\t\tVariables.status = \"Completing task...\";\n\t\t}\n\t\t\n\t\tNpc[] slayerMonster = Npcs.getNearest(slayerMonsterFilter);\n\n\t\ttry {\n\t\tslayerMonster[0].interact(1);\n\t\t} catch (ArrayIndexOutOfBoundsException | NullPointerException e) {\n\t\t\t\n\t\t} \n\t\t\n\t\tTime.sleep(new SleepCondition() {\n\t\t\t@Override\n\t\t\tpublic boolean isValid() {\n\t\t\t\treturn Players.getMyPlayer().isInCombat();\n\t\t\t}\n\t\t}, 5000);\n\t\t\n\t\tTime.sleep(new SleepCondition() {\n\t\t\t@Override\n\t\t\tpublic boolean isValid() {\n\t\t\t\treturn !Players.getMyPlayer().isInCombat();\n\t\t\t}\n\t\t}, 5000);\n\t}",
"private void startGameAfterDelay() {\n int delay = (int) (double) DiaConfig.SECONDS_UNTIL_START.get() * MinecraftConstants.TICKS_PER_SECOND + 1;\n\n this.startingTask = new BukkitRunnable() {\n @Override\n public void run() {\n startGame();\n }\n }.runTaskLater(DiaHuntPlugin.getInstance(), delay);\n }",
"@Test\n public void testDelay() {\n long future = System.currentTimeMillis() + (rc.getRetryDelay() * 1000L);\n\n rc.delay();\n\n assertTrue(System.currentTimeMillis() >= future);\n }",
"public synchronized void execute() {\n\t\tthis.timeoutFuture = SCHEDULER.schedule(this::processTimeout, 5, TimeUnit.SECONDS);\n\t\tthis.statuses.put(this.localNode.getInfo(), NodeStatus.Unasked);\n\t\tcheckFinishAndProcess();\n\t}",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }",
"@Scheduled\n\tpublic void executeNotification();",
"public void testPeriodic() {\n Scheduler.getInstance().run();\n }",
"@Override\npublic void run() {\n perform();\t\n}",
"public static void syncTimer(long period, RunResult<Boolean> runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\tif(!runnable.run()) {\n\t\t\t\t\tthis.cancel();\n\t\t\t\t}\n\t\t\t}\n\t\t}.runTaskTimer(AreaShop.getInstance(), 0, period);\n\t}",
"@Override\n public void autonomousPeriodic() {\n \n Scheduler.getInstance().run();\n \n }",
"@Override\r\n protected Object doInBackground() throws Exception {\n try {\r\n Thread.sleep(5500);\r\n\r\n } catch (Exception e) {}\r\n return null;\r\n }",
"@PostConstruct\n public void postConstruct() {\n execService = Executors.newScheduledThreadPool(1);\n scheduledFuture = execService.scheduleAtFixedRate(this, 0, PUSH_REPEAT_DELAY, TimeUnit.MILLISECONDS);\n }",
"@Override\n public void runTasks() {\n BukkitTask task1 = new BukkitRunnable() {\n long start = 0;\n long now = 0;\n\n @Override\n public void run() {\n start = now;\n now = System.currentTimeMillis();\n long tdiff = now - start;\n\n if (tdiff > 0) {\n instTps = (float) (1000 / tdiff);\n }\n }\n }.runTaskTimer(Aurora.getInstance(), 0, 1);\n\n //Task to populate avgTps\n BukkitTask task2 = new BukkitRunnable() {\n ArrayList<Float> tpsList = new ArrayList<>();\n\n @Override\n public void run() {\n Float totalTps = 0f;\n\n tpsList.add(instTps);\n //Remove old tps after 15s\n if (tpsList.size() >= 15) {\n tpsList.remove(0);\n }\n for (Float f : tpsList) {\n totalTps += f;\n }\n avgTps = totalTps / tpsList.size();\n }\n }.runTaskTimerAsynchronously(Aurora.getInstance(), 20, 20);\n\n //Add to runnables[]\n runnables = new BukkitTask[]{task1, task2};\n }",
"@Override\n public void run() {\n task.run();\n }",
"private void startrun() {\n mHandler.postDelayed(mPollTask, POLL_INTERVAL);\n\t}",
"@Override\n\tpublic void execute() {\n\t\tThreadPool pool=ThreadPool.getInstance();\n\t\tpool.beginTaskRun(this);\n\t}",
"static void scheduleWork(final boolean shortInterval) {\n if (shortInterval) {\n _cancelWork(false);\n //PPApplication.sleep(5000);\n _scheduleWork(true);\n\n /*PPApplication.startHandlerThreadPPScanners();\n final Handler __handler = new Handler(PPApplication.handlerThreadPPScanners.getLooper());\n __handler.post(() -> {\n// PPApplicationStatic.logE(\"[IN_THREAD_HANDLER] PPApplication.startHandlerThreadPPScanners\", \"START run - from=SearchCalendarEventsWorker.scheduleWork\" + \" shortInterval=true\");\n _cancelWork();\n PPApplication.sleep(5000);\n _scheduleWork(true);\n });*/\n }\n else\n _scheduleWork(false);\n }",
"boolean isDelayed();",
"@Override\n public ScheduledFuture<?> schedule(Runnable task, Trigger trigger) {\n if (!canRun()) {\n return null;\n }\n return super.schedule(task, trigger);\n }",
"@Override\n protected void onPostExecute(Void aVoid) {\n if (checkDelay.onDownloadImageTaskCheck()) {\n checkDelay.onDelayDownloadingError();\n }\n }",
"@Override\n\tpublic void run() {\n\t\t\n\t // Inizializza nome thread\n\t Thread.currentThread().setName(\"Timer\");\n\t \n\t // Richiama procedura di gestione aggiornamento configurazione\n\t update();\n }",
"private void setupBukkitManaRegenerationTask(){\n\t\tif(time <= 0) return;\n\t\t\n\t\tif(bukkitTaskID > 0){\n\t\t\tBukkit.getScheduler().cancelTask(bukkitTaskID);\n\t\t}\n\t\t\n\t\tif(bukkitTaskID < 0 || !Bukkit.getScheduler().isQueued(bukkitTaskID)){\n\n\t\t\tint tickTime = time * 20;\t\t\t\n\t\t\tbukkitTaskID = Bukkit.getScheduler().scheduleSyncRepeatingTask((JavaPlugin)plugin, new Runnable() {\n\t\t\t\t\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\tfor(AbstractTraitHolder holder : ManaRegenerationTrait.this.getTraitHolders()){\n\t\t\t\t\t\tfor(RaCPlayer player : holder.getHolderManager().getAllPlayersOfHolder(holder)){\n\t\t\t\t\t\t\tif(player != null && player.isOnline()){\n\t\t\t\t\t\t\t\tdouble modValue = modifyToPlayer(player, value, \"value\");\n\t\t\t\t\t\t\t\tBukkit.getPluginManager().callEvent(new ManaRegenerationEvent(player.getPlayer(), modValue));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}, tickTime, tickTime);\n\t\t}\n\t}",
"ScheduledFutureTask(Callable<V> callable, long ns) {\n super(callable);\n this.nextExecutionTime = ns;\n this.period = 0;\n this.sequenceNumber = sequencer.getAndIncrement();\n }",
"public void begin() {\n\t\t\tGeneralThreadPool.getInstance().schedule(this, 3000);\n\t\t}",
"public void begin() {\n\t\t\tGeneralThreadPool.getInstance().schedule(this, 3000);\n\t\t}",
"public void run()\r\n/* 49: */ {\r\n/* 50:170 */ if (!TrafficCounter.this.monitorActive) {\r\n/* 51:171 */ return;\r\n/* 52: */ }\r\n/* 53:173 */ TrafficCounter.this.resetAccounting(TrafficCounter.milliSecondFromNano());\r\n/* 54:174 */ if (TrafficCounter.this.trafficShapingHandler != null) {\r\n/* 55:175 */ TrafficCounter.this.trafficShapingHandler.doAccounting(TrafficCounter.this);\r\n/* 56: */ }\r\n/* 57:177 */ TrafficCounter.this.scheduledFuture = TrafficCounter.this.executor.schedule(this, TrafficCounter.this.checkInterval.get(), TimeUnit.MILLISECONDS);\r\n/* 58: */ }",
"public void autonomousPeriodic() \n {\n Scheduler.getInstance().run();\n }",
"public void start()\n {\n if (task != -1) {\n return;\n }\n\n task = Bukkit.getScheduler().scheduleSyncRepeatingTask(library.getPlugin(), this, 5, 1);\n }",
"public void scheduledUpdate() {\n\n if (isUpdating.compareAndSet(false, true)) {\n\n if (getCurrentChannel() != null) {\n\n updateData();\n }\n }\n\n timer.cancel();\n timer.purge();\n\n timer = new Timer();\n timer.scheduleAtFixedRate(new UpdateTask(), 3600000,\n 3600000);\n\n }",
"public static void scheduleEndingTask(Runnable t, long ms, long initialDelay) {\n try {\n SERVICE.scheduleAtFixedRate(t, initialDelay, ms, TimeUnit.MILLISECONDS);\n } catch (TaskComplete e) {\n //ignored\n //Client.logger.error(\"An error has occurred while executing an asynchronous task!\", e);\n return;\n }catch(Exception e){\n Client.logger.error(\"An error has occurred while executing an asynchronous task!\", e);\n }\n }",
"public static void asyncTimer(long period, RunResult<Boolean> runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\tif(!runnable.run()) {\n\t\t\t\t\tthis.cancel();\n\t\t\t\t}\n\t\t\t}\n\t\t}.runTaskTimerAsynchronously(AreaShop.getInstance(), 0, period);\n\t}",
"@Override\n public void run() {\n schedule();\n }",
"@Scheduled(cron=\"0 0 * * * *\")\r\n\tpublic void task(){\r\n\t\t\r\n\t\ttry{\r\n\t\t\tloginUsers();\r\n\t\t}catch(Exception e){\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"@Override\n protected void onPreExecute(){\n //do before task doing in background\n }",
"@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\t\n\t}",
"@Override\n\t\tprotected String[] doInBackground(Void... params) {\n\t\t\ttry {\n\t\t\t\tThread.sleep(3000);\n\t\t\t\ttimes++;\n\t\t\t} catch (InterruptedException e) {\n\t\t\t}\n\t\t\treturn null;\n\t\t}",
"@Override\n\tpublic void run() {\n\t\tdb.i(\"PowerupRunnable commiting spawn\");\n\t\tif (a.fightInProgress) {\n\t\t\t\n\t\t\tpum.calcPowerupSpawn(a);\n\t\t} else {\n\t\t\t// deactivate the auto saving task\n\t\t\tBukkit.getServer().getScheduler().cancelTask(pum.SPAWN_ID);\n\t\t}\n\t}",
"public void schedule(MessageSender sender) {\n\t\tmScheduler = new Timer();\n\t\tif(!mRegisterdListeners.isEmpty()) {\n\t\t\tfor(int i = 0; i < mRegisterdListeners.size(); i++) {\n\t\t\t\tmArduinoTasks.add(new ArduinoTask(sender,mRegisterdListeners.get(i).getSensor().getSensorId(), mArduinoService.getContainer()));\n\t\t\t\tLog.d(TAG, \"rate: \" + mRegisterdListeners.get(i).getSampleRate());\t\n\t\t\t}\n\t\t\tfor(int i = 0; i < mArduinoTasks.size(); i++) {\n\t\t\t\tmScheduler.scheduleAtFixedRate(mArduinoTasks.get(i), (r.nextInt(2000 - 1010 + 1) + 1000) * (i + 1), mRegisterdListeners.get(i).getSampleRate());\n\t\t\t}\n\t\t}\n\t}",
"ScheduledFuture<?> scheduleAtFixedRate(Runnable publisher, long period, TimeUnit timeUnit, ProbeLevel probeLevel);",
"@Override\n public void run() {\n runTask();\n\n }",
"private static void execute(EventExecutor executor, Runnable task)\r\n/* 592: */ {\r\n/* 593: */ try\r\n/* 594: */ {\r\n/* 595:670 */ executor.execute(task);\r\n/* 596: */ }\r\n/* 597: */ catch (Throwable t)\r\n/* 598: */ {\r\n/* 599:672 */ rejectedExecutionLogger.error(\"Failed to submit a listener notification task. Event loop shut down?\", t);\r\n/* 600: */ }\r\n/* 601: */ }",
"private void invokePostRefreshTasks(boolean success) {\r\n Vector tasksToRun = null;\r\n \r\n synchronized(postRefreshTasks) {\r\n int size = postRefreshTasks.size();\r\n if(size > 0) {\r\n tasksToRun = new Vector(size);\r\n for(int i=0; i<size; i++) {\r\n Object[] element = (Object[])postRefreshTasks.elementAt(i);\r\n // Add the task if the refresh was successful, or if the\r\n // task does not depend on a successful refresh.\r\n if(success || !((Boolean)element[1]).booleanValue()) {\r\n tasksToRun.addElement((Runnable)element[0]);\r\n }\r\n }\r\n postRefreshTasks.removeAllElements();\r\n }\r\n }\r\n \r\n if(tasksToRun != null) {\r\n int size = tasksToRun.size();\r\n for(int i=0; i<size; i++) {\r\n mailStoreServices.invokeLater((Runnable)tasksToRun.elementAt(i));\r\n }\r\n }\r\n }",
"public void autonomousPeriodic() {\r\n Scheduler.getInstance().run();\r\n }",
"private Task taskCreator(int seconds){\n return new Task() {\n\n @Override\n protected Object call() throws Exception {\n for(int i=0; i<seconds;i++){\n Thread.sleep(1000);\n updateProgress(i+1, seconds);\n\n }\n return true;\n }\n };\n }",
"ScheduledExecutorService getExecutorService();",
"@Override\n\t\t\tprotected Boolean doInBackground(Void... params) {\n\t\t\t\ttry {\n\t\t\t\t\tThread.sleep(200);\n\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\treturn false;\n\t\t\t}",
"@Override\n public void autonomousPeriodic()\n {\n Scheduler.getInstance().run();\n }",
"private void startSaveBaseTrace() {\n scheduledThreadSaveBaseTrace = new ScheduledThreadPoolExecutor(5);\n scheduledThreadSaveBaseTrace.scheduleAtFixedRate(new CommTaskUtils.TaskSaveBaseTrace(newBaseTrace, type),\n 0, 8, TimeUnit.SECONDS);\n }",
"@Override\n public void run() {\n //如果本延迟任务已经执行,那么做个标识标注本清楚任务已经执行,然后手按下的时候那里就不会移除本任务\n b = false;\n cleanLine();\n }"
] | [
"0.67787766",
"0.6532767",
"0.6485708",
"0.64654326",
"0.6405001",
"0.6359963",
"0.63524115",
"0.6289068",
"0.62847537",
"0.62659305",
"0.6265618",
"0.62583625",
"0.61419433",
"0.61418134",
"0.6098422",
"0.60940397",
"0.6089948",
"0.6052775",
"0.6026015",
"0.60177875",
"0.6016743",
"0.6002975",
"0.59732014",
"0.59115845",
"0.58682656",
"0.5864046",
"0.5853629",
"0.5838563",
"0.583494",
"0.57863235",
"0.5785838",
"0.5784763",
"0.5779254",
"0.5752119",
"0.5733092",
"0.57013345",
"0.5669225",
"0.56658816",
"0.56582487",
"0.56577396",
"0.56530356",
"0.56145126",
"0.5595073",
"0.55943096",
"0.5569279",
"0.55617744",
"0.55292976",
"0.55158544",
"0.55141866",
"0.55123657",
"0.5502346",
"0.55011094",
"0.5498808",
"0.54913384",
"0.54878867",
"0.5484818",
"0.5481325",
"0.5452078",
"0.5449651",
"0.54239595",
"0.5414759",
"0.5412093",
"0.5407493",
"0.5406006",
"0.5401152",
"0.5400489",
"0.53892577",
"0.53856343",
"0.5380369",
"0.5371304",
"0.53606147",
"0.53556377",
"0.5354537",
"0.5353695",
"0.5352548",
"0.5352548",
"0.5352272",
"0.5351162",
"0.53469956",
"0.53424966",
"0.5342363",
"0.5336028",
"0.53330415",
"0.53309566",
"0.53301686",
"0.532606",
"0.53259385",
"0.53226924",
"0.5321185",
"0.53203493",
"0.5315821",
"0.5313002",
"0.5310658",
"0.53095293",
"0.5309038",
"0.5307062",
"0.5295706",
"0.5295498",
"0.529424",
"0.52907884"
] | 0.6579664 | 1 |
a newScheduledThreadPool successfully runs delayed task | public void testNewScheduledThreadPool() throws Exception {
final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);
try (PoolCleaner cleaner = cleaner(p)) {
final CountDownLatch proceed = new CountDownLatch(1);
final Runnable task = new CheckedRunnable() {
public void realRun() {
await(proceed);
}};
long startTime = System.nanoTime();
Future f = p.schedule(Executors.callable(task, Boolean.TRUE),
timeoutMillis(), MILLISECONDS);
assertFalse(f.isDone());
proceed.countDown();
assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));
assertSame(Boolean.TRUE, f.get());
assertTrue(f.isDone());
assertFalse(f.isCancelled());
assertTrue(millisElapsedSince(startTime) >= timeoutMillis());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void scheduledTask() {\n connectToNewViews();\n removeDisconnectedViews();\n try {\n Thread.sleep(SCHEDULED_TASK_PERIOD);\n // Scheduling future execution\n\n synchronized (threadPool) {\n if (!threadPool.isShutdown()) {\n threadPool.execute(this::scheduledTask);\n }\n }\n } catch (InterruptedException e) {\n Thread.currentThread().interrupt();\n }\n }",
"private void runPeriodic() {\n boolean ok = ScheduledFutureTask.super.runAndReset();\n boolean down = isShutdown();\n // Reschedule if not cancelled and not shutdown or policy allows\n if (ok && !down) {\n updateNextExecutionTime();\n MeasurableScheduler.super.getQueue().add(this);\n }\n // This might have been the final executed delayed\n // task. Wake up threads to check.\n else if (down)\n interruptIdleWorkers();\n }",
"public long runScheduledPendingTasks() {\n/* */ try {\n/* 597 */ return this.loop.runScheduledTasks();\n/* 598 */ } catch (Exception e) {\n/* 599 */ recordException(e);\n/* 600 */ return this.loop.nextScheduledTask();\n/* */ } \n/* */ }",
"ScheduledFuture<?> scheduleTask(long delay, Runnable runnable) {\n return timeoutTaskExecutor.schedule(runnable, delay, TimeUnit.MILLISECONDS);\n }",
"@Scheduled(fixedDelay = 3000)\n\tpublic void scheduleTaskWithFixedDelay() {\n\t\tlog.info(\"Fixed Delay Task :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t\t//Sleep TimeUnit\n//\t\ttry {\n//\t\t\tTimeUnit.SECONDS.sleep(5);\n//\t\t} catch (Exception e) {\n//\t\t\tlog.error(\"Ran into an error {}\", e);\n//\t throw new IllegalStateException(e);\n//\t\t}\n\t}",
"public static void main(String[] args) {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(3);\n scheduledThreadPoolExecutor.setRemoveOnCancelPolicy(true);\n SystemOutUtil.println(\"start schedule\");\n scheduledThreadPoolExecutor.schedule(new DelayCallableTask(), 1000, TimeUnit.MILLISECONDS);\n RunnableScheduledFuture<?> rateFuture =\n (RunnableScheduledFuture<?>) scheduledThreadPoolExecutor\n .scheduleAtFixedRate(new FixRateRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n ScheduledFuture delayFuture =\n scheduledThreadPoolExecutor.scheduleWithFixedDelay(new FixDelayRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n SystemOutUtil.println(\"end schedule\");\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"start stop\");\n\n// scheduledThreadPoolExecutor.remove(rateFuture); // 无效\n rateFuture.cancel(false);\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n scheduledThreadPoolExecutor.shutdown();\n return;\n }",
"private void schedule() {\n service.scheduleDelayed(task, schedulingInterval);\n isScheduled = true;\n }",
"public void run() {\n long start = System.nanoTime();\n try {\n activeCount.inc();\n long delay = start - nextExecutionTime;//实践执行时间-理论应该执行的实际点\n taskExecutionDelay.record(delay, TimeUnit.NANOSECONDS);\n // real logic\n if (isPeriodic())\n runPeriodic();\n else\n ScheduledFutureTask.super.run();\n } finally {\n activeCount.dec();\n taskExecutionTime.record(System.currentTimeMillis() - start, TimeUnit.MILLISECONDS);\n }\n }",
"ScheduledExecutorService getScheduledExecutorService();",
"@Scheduled(fixedRate = 2000, initialDelay = 5000)\n\tpublic void scheduleTaskWithInitialDelay() {\n\t\tlog.info(\"Fixed Rate Task With Initial Delay :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"public void runPendingTasks() {\n/* */ try {\n/* 578 */ this.loop.runTasks();\n/* 579 */ } catch (Exception e) {\n/* 580 */ recordException(e);\n/* */ } \n/* */ \n/* */ try {\n/* 584 */ this.loop.runScheduledTasks();\n/* 585 */ } catch (Exception e) {\n/* 586 */ recordException(e);\n/* */ } \n/* */ }",
"@Scheduled(fixedRate = 2000, initialDelay = 5000)\n public void scheduleTaskWithInitialDelay() {\n logger.info(\"Fixed Rate Task with Initial Delay :: Execution Time - {}\", formatter.format(LocalDateTime.now()));\n }",
"void executeAsync(long delayMs, Runnable task);",
"@Test\n @DisplayName(\"Scheduled Future\")\n void testScheduledFuture() throws InterruptedException {\n ScheduledExecutorService executor = Executors.newScheduledThreadPool(1);\n ScheduledFuture<String> future = executor.schedule(this::getThreadName, 3, TimeUnit.SECONDS);\n\n TimeUnit.MILLISECONDS.sleep(1337);\n long remainingTime = future.getDelay(TimeUnit.MILLISECONDS);\n\n assertThat(remainingTime).isBetween(1650L, 1670L);\n }",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"void scheduleTask(long delay) {\n executorService.schedule(\n backgroundTask, delay, TimeUnit.MILLISECONDS);\n }",
"private void beginSchedule(){\n\t\tDivaApp.getInstance().submitScheduledTask(new RandomUpdater(this), RandomUpdater.DELAY, RandomUpdater.PERIOD);\n\t}",
"public Future<?> scheduleOneShot(long delay, Runnable runnable) {\n\t\tif (!Raptor.getInstance().isDisposed() && !isDisposed) {\n\t\t\ttry {\n\t\t\t\treturn executor.schedule(new RunnableExceptionDecorator(\n\t\t\t\t\t\trunnable), delay, TimeUnit.MILLISECONDS);\n\t\t\t} catch (RejectedExecutionException rej) {\n\t\t\t\tif (!Raptor.getInstance().isDisposed()) {\n\t\t\t\t\tLOG.error(\"Error executing runnable in scheduleOneShot: \",\n\t\t\t\t\t\t\trej);\n\t\t\t\t\tthreadDump();\n\t\t\t\t\tRaptor.getInstance().onError(\n\t\t\t\t\t\t\t\"ThreadServie has no more threads. A thread dump can be found at \"\n\t\t\t\t\t\t\t\t\t+ THREAD_DUMP_FILE_PATH);\n\t\t\t\t}\n\t\t\t\treturn null;\n\t\t\t}\n\t\t} else {\n\t\t\tLOG.info(\"Veoting runnable \" + runnable + \" raptor is disposed.\");\n\t\t\treturn null;\n\t\t}\n\t}",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public static void main(String[] args) {\n\n ScheduledExecutorService service = Executors.newScheduledThreadPool(4);\n\n //task to run after 10 seconds delay\n service.schedule(new Task(), 10, TimeUnit.SECONDS);\n\n //task to repeatedly every 10 seconds\n service.scheduleAtFixedRate(new Task(), 15, 10, TimeUnit.SECONDS);\n\n //task to run repeatedly 10 seconds after previous task completes\n service.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\n\n for (int i = 0; i < 100; i++) {\n System.out.println(\"task number - \" + i + \" \");\n service.execute(new Task());\n }\n System.out.println(\"Thread name: \" + Thread.currentThread().getName());\n\n }",
"public void testUnconfigurableScheduledExecutorService() throws Exception {\n final ScheduledExecutorService p =\n Executors.unconfigurableScheduledExecutorService\n (Executors.newScheduledThreadPool(2));\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public void schedule() {\n cancel();\n timer.schedule(new TimerTask() {\n @Override\n public void run() {\n runnable.run();\n }\n }, delay);\n }",
"@Scheduled(fixedRate = 2000)\n\tpublic void scheduleTaskWithFixedRate() {\n\t\tlog.info(\"Fixed Rate Task :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()) );\n\t}",
"@Scheduled(fixedDelay=5000) //indicamos que esta tarea se repetira cada 5 segundos \n\tpublic void doTask() {\n\t\tLOGGER.info(\"Time is: \"+ new Date());\n\t}",
"ScheduledExecutorService getExecutorService();",
"@Override\n\tpublic void execute() {\n\t\tThreadPool pool=ThreadPool.getInstance();\n\t\tpool.beginTaskRun(this);\n\t}",
"public static void main(String[] args) throws Exception {\n ScheduledExecutorService exec = Executors.newScheduledThreadPool(3);// 3 threads\n\n System.out.println(\"TIME: \" + dateFormatter.format(new Date()));\n\n\n ScheduledFuture<?> sf1 = exec.schedule(new ScheduledTaskB(3000), 4,TimeUnit.SECONDS); // TASK-1\n ScheduledFuture<?> sf2 = exec.schedule(new CalculationTaskD(0,3,3000), 6, TimeUnit.SECONDS); // TASK-2\n\n exec.schedule(new ScheduledTaskB(0), 8, TimeUnit.SECONDS);\n ScheduledFuture<?> sf4 = exec.schedule(new CalculationTaskD(3,4,0), 10 , TimeUnit.SECONDS); // TASK-4\n\n exec.shutdown();\n sf1.cancel(true);\n sf2.cancel(true);\n\n // GET RESULTS ////////////////////////////////////////////////////////////\n\n System.out.println(\"\\n\\n\\nGetting results: \");\n\n /*\n .get() blocks until result is available\n */\n System.out.println(\"TASK-1: \" + sf1.get() + \"\\n\");\n System.out.println(\"TASK-2: \" + sf2.get() + \"\\n\");\n System.out.println(\"TASK-4: \" + sf4.get() + \"\\n\");\n\n\n\n\n\n }",
"ScheduledFutureTask(Callable<V> callable, long ns) {\n super(callable);\n this.nextExecutionTime = ns;\n this.period = 0;\n this.sequenceNumber = sequencer.getAndIncrement();\n }",
"public void schedule(Runnable job, long delay, TimeUnit unit);",
"private static Future<?> directExecute(Runnable runnable, long delay) {\n Future<?> future = null;\n if (delay > 0) {\n /* no serial, but a delay: schedule the task */\n if (!(executor instanceof ScheduledExecutorService)) {\n throw new IllegalArgumentException(\"The executor set does not support scheduling\");\n }\n ScheduledExecutorService scheduledExecutorService = (ScheduledExecutorService) executor;\n future = scheduledExecutorService.schedule(runnable, delay, TimeUnit.MILLISECONDS);\n } else {\n if (executor instanceof ExecutorService) {\n ExecutorService executorService = (ExecutorService) executor;\n future = executorService.submit(runnable);\n } else {\n /* non-cancellable task */\n executor.execute(runnable);\n }\n }\n return future;\n }",
"@Test\n public void testTask() throws InterruptedException {\n\n SchedulingRunnable task1 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task1, \"0/15 * * * * ?\");\n Thread.sleep(10000);\n\n SchedulingRunnable task2 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task2, \"0/8 * * * * ?\");\n // 便于观察\n\n Thread.sleep(3000000);\n }",
"public void runDelayedTasks(Class<? extends Task> taskClass) {\n log.info(\"Running delayed tasks...\");\n serializeExecutionOfTasks(delayedTasks, taskClass);\n }",
"public void begin() {\n\t\t\tGeneralThreadPool.getInstance().schedule(this, 3000);\n\t\t}",
"public void begin() {\n\t\t\tGeneralThreadPool.getInstance().schedule(this, 3000);\n\t\t}",
"public void run(){\n Timer time = new Timer(); // Instantiate Timer Object\n\n ScheduledClass st = new ScheduledClass(this.job,this.shm,time,this.stopp); // Instantiate SheduledTask class\n time.schedule(st, 0, this.periodicwait); // Create Repetitively task for every 1 secs\n }",
"private SleeperTask()\r\n\t{\r\n\t\ttimer = new Timer();\r\n\t\tprovider = null;\r\n\t\taction = \"\";\r\n\t\tverbose = false;\r\n\t\tsetRepeat(5);\r\n\t}",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"@PostConstruct\n public void postConstruct() {\n execService = Executors.newScheduledThreadPool(1);\n scheduledFuture = execService.scheduleAtFixedRate(this, 0, PUSH_REPEAT_DELAY, TimeUnit.MILLISECONDS);\n }",
"private void scheduleNext() {\n lock.lock();\n try {\n active = tasks.poll();\n if (active != null) {\n executor.execute(active);\n terminating.signalAll();\n } else {\n //As soon as a SerialExecutor is empty, we remove it from the executors map.\n if (lock.isHeldByCurrentThread() && isEmpty() && this == serialExecutorMap.get(identifier)) {\n serialExecutorMap.remove(identifier);\n terminating.signalAll();\n if (state == State.SHUTDOWN && serialExecutorMap.isEmpty()) {\n executor.shutdown();\n }\n }\n }\n } finally {\n lock.unlock();\n }\n }",
"ScheduledFutureTask(Runnable r, V result, long ns) {\n super(r, result);\n this.nextExecutionTime = ns;\n this.period = 0;\n this.sequenceNumber = sequencer.getAndIncrement();\n }",
"ScheduledFuture<?> scheduleAtFixedRate(Runnable publisher, long period, TimeUnit timeUnit, ProbeLevel probeLevel);",
"public ScheduledFuture<?> schedule(Runnable task, long delay) {\n return executor.schedule(task, delay, TimeUnit.MILLISECONDS);\n }",
"private void handleActionOnce() {\n // TODO: Handle action\n try {\n Executors.newScheduledThreadPool(1).submit(new NewsReceiveTask(getApplicationContext() , true));\n } catch (Exception e) {\n e.printStackTrace();\n }\n }",
"public void startTaskTriggerCheckerThread() {\n new Thread(new Runnable() {\n @Override\n public void run() {\n canRunEnqueueTaskThread.set(true);\n while(canRunEnqueueTaskThread.get()) {\n try {\n Thread.sleep(1000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n if(taskEnqueued.get() || canRunTaskThread.get()) { //do not enqueue the task if an instance of that task is already enqueued or running.\n continue;\n //log(PrioritizedReactiveTask.this.getClass().getSimpleName() + \" already in queue or is currently executing\");\n } else if(shouldTaskActivate()) {\n System.out.println(\"Thread \" + Thread.currentThread().getId() + \" enqueued task: \" + this.getClass().getSimpleName());\n taskQueue.add(PrioritizedReactiveTask.this);\n activeTasks.add(PrioritizedReactiveTask.this);\n taskEnqueued.set(true);\n try {\n Thread.sleep(5000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n }\n }).start();\n }",
"ScheduledFutureTask(Runnable r, V result, long ns, long period) {\n this(r, result, ns, period, false);\n }",
"private void invokePostRefreshTasks(boolean success) {\r\n Vector tasksToRun = null;\r\n \r\n synchronized(postRefreshTasks) {\r\n int size = postRefreshTasks.size();\r\n if(size > 0) {\r\n tasksToRun = new Vector(size);\r\n for(int i=0; i<size; i++) {\r\n Object[] element = (Object[])postRefreshTasks.elementAt(i);\r\n // Add the task if the refresh was successful, or if the\r\n // task does not depend on a successful refresh.\r\n if(success || !((Boolean)element[1]).booleanValue()) {\r\n tasksToRun.addElement((Runnable)element[0]);\r\n }\r\n }\r\n postRefreshTasks.removeAllElements();\r\n }\r\n }\r\n \r\n if(tasksToRun != null) {\r\n int size = tasksToRun.size();\r\n for(int i=0; i<size; i++) {\r\n mailStoreServices.invokeLater((Runnable)tasksToRun.elementAt(i));\r\n }\r\n }\r\n }",
"@Override\n public void runTasks() {\n BukkitTask task1 = new BukkitRunnable() {\n long start = 0;\n long now = 0;\n\n @Override\n public void run() {\n start = now;\n now = System.currentTimeMillis();\n long tdiff = now - start;\n\n if (tdiff > 0) {\n instTps = (float) (1000 / tdiff);\n }\n }\n }.runTaskTimer(Aurora.getInstance(), 0, 1);\n\n //Task to populate avgTps\n BukkitTask task2 = new BukkitRunnable() {\n ArrayList<Float> tpsList = new ArrayList<>();\n\n @Override\n public void run() {\n Float totalTps = 0f;\n\n tpsList.add(instTps);\n //Remove old tps after 15s\n if (tpsList.size() >= 15) {\n tpsList.remove(0);\n }\n for (Float f : tpsList) {\n totalTps += f;\n }\n avgTps = totalTps / tpsList.size();\n }\n }.runTaskTimerAsynchronously(Aurora.getInstance(), 20, 20);\n\n //Add to runnables[]\n runnables = new BukkitTask[]{task1, task2};\n }",
"public synchronized void execute(Runnable task) throws Exception{\n \n if(threadPoolExecutor.isShutdown()){\n \tSystem.out.println(\"Thread pool \" + \"\" + \" is being Shutdown.\\n\"\n \t\t\t\t\t+ \"No tasks are allowed to be scheduled.\");\n \n }\n //add the task to the queue\n //this will cause a thread in the work pool to pick this up and execute\n queue.put(task);\n System.out.println(\"task has been added.\");\n }",
"@PostConstruct\n public void init() {\n threadPoolTaskScheduler.scheduleWithFixedDelay(this::process, Instant.now(), Duration.ofSeconds(30));\n }",
"private void runScheduleTasks() {\r\n // To minimize the time the lock is held, make a copy of the array\r\n // with the tasks while holding the lock then release the lock and\r\n // execute the tasks\r\n List<Runnable> tasksCopy;\r\n synchronized (taskLock) {\r\n if (tasks.isEmpty()) { return; } \r\n tasksCopy = tasks;\r\n tasks = new ArrayList<Runnable>(4);\r\n }\r\n for (Runnable task : tasksCopy) {\r\n task.run();\r\n } \r\n }",
"void schedule(long delay, TimeUnit unit) {\r\n\t\tthis.delay = delay;\r\n\t\tthis.unit = unit;\r\n\t\tif (monitor != null) {\r\n\t\t\tmonitor.cancel(false);\r\n\t\t\tmonitor = pool.scheduleWithFixedDelay(sync, delay, delay, unit);\r\n\t\t}\r\n\t}",
"public static void main(String args[])\n {\n\t ScheduledExecutorService executorService= Executors.newScheduledThreadPool(2);\n\t Runnable task1=new RunnableChild(\"task1\");\n\t Runnable task2=new RunnableChild(\"task2\");\n\t Runnable task3=new RunnableChild(\"task3\");\n\t executorService.submit(task1);\n\t executorService.submit(task2);\n\t executorService.submit(task3);\n\t executorService.schedule(task1,20, TimeUnit.SECONDS);\n\t System.out.println(\"*******shutting down called\");\n\t executorService.shutdown();\n }",
"public void calibrateAndRunTask(){\n calibrateMaxConcurrentActions();\n\n runTasks();\n }",
"public ScheduledFuture<?> schedule(Runnable task, long delay, long period) {\n return executor.scheduleWithFixedDelay(task, delay, period, TimeUnit.MILLISECONDS);\n }",
"public static void scheduleEndingTask(Runnable t, long ms, long initialDelay) {\n try {\n SERVICE.scheduleAtFixedRate(t, initialDelay, ms, TimeUnit.MILLISECONDS);\n } catch (TaskComplete e) {\n //ignored\n //Client.logger.error(\"An error has occurred while executing an asynchronous task!\", e);\n return;\n }catch(Exception e){\n Client.logger.error(\"An error has occurred while executing an asynchronous task!\", e);\n }\n }",
"@Override\n public void run() {\n task.run();\n }",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"public <T> ValueFuture<T> schedule(Callable<T> job, long delay, TimeUnit unit);",
"protected void onQueued() {}",
"void restartEventsWithDelay(final boolean longDelay, final boolean alsoRescan, final boolean unblockEventsRun,\n final int logType)\n {\n if (longDelay) {\n\n Data workData = new Data.Builder()\n .putBoolean(PhoneProfilesService.EXTRA_ALSO_RESCAN, alsoRescan)\n .putBoolean(PhoneProfilesService.EXTRA_UNBLOCK_EVENTS_RUN, unblockEventsRun)\n .putInt(PhoneProfilesService.EXTRA_LOG_TYPE, logType)\n .build();\n\n OneTimeWorkRequest restartEventsWithDelayWorker;\n restartEventsWithDelayWorker =\n new OneTimeWorkRequest.Builder(RestartEventsWithDelayWorker.class)\n .addTag(RestartEventsWithDelayWorker.WORK_TAG_2)\n .setInputData(workData)\n .setInitialDelay(15, TimeUnit.SECONDS)\n .build();\n try {\n if (PPApplicationStatic.getApplicationStarted(true, true)) {\n WorkManager workManager = PPApplication.getWorkManagerInstance();\n if (workManager != null) {\n\n// //if (PPApplicationStatic.logEnabled()) {\n// ListenableFuture<List<WorkInfo>> statuses;\n// statuses = workManager.getWorkInfosForUniqueWork(RestartEventsWithDelayWorker.WORK_TAG);\n// try {\n// List<WorkInfo> workInfoList = statuses.get();\n// } catch (Exception ignored) {\n// }\n// //}\n\n// PPApplicationStatic.logE(\"[WORKER_CALL] DataWrapper.restartEventsWithDelay\", \"xxx\");\n //workManager.enqueue(restartEventsWithDelayWorker);\n //if (replace)\n workManager.enqueueUniqueWork(RestartEventsWithDelayWorker.WORK_TAG_2, ExistingWorkPolicy.REPLACE, restartEventsWithDelayWorker);\n //else\n // workManager.enqueueUniqueWork(RestartEventsWithDelayWorker.WORK_TAG_APPEND, ExistingWorkPolicy.APPEND_OR_REPLACE, restartEventsWithDelayWorker);\n }\n }\n } catch (Exception e) {\n PPApplicationStatic.recordException(e);\n }\n } else {\n// PPApplicationStatic.logE(\"[EXECUTOR_CALL] ***** DataWrapper.restartEventsWithDelay\", \"schedule\");\n\n final Context appContext = context.getApplicationContext();\n //final ScheduledExecutorService worker = Executors.newSingleThreadScheduledExecutor();\n Runnable runnable = () -> {\n// long start = System.currentTimeMillis();\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] ***** DataWrapper.restartEventsWithDelay\", \"--------------- START\");\n\n PowerManager powerManager = (PowerManager) appContext.getSystemService(Context.POWER_SERVICE);\n PowerManager.WakeLock wakeLock = null;\n try {\n if (powerManager != null) {\n wakeLock = powerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, PPApplication.PACKAGE_NAME + \":DataWrapper_restartEventsWithDelay\");\n wakeLock.acquire(10 * 60 * 1000);\n }\n\n //PPExecutors.doRestartEventsWithDelay(alsoRescan, unblockEventsRun, logType, context);\n\n DataWrapper dataWrapper = new DataWrapper(appContext, false, 0, false, 0, 0, 0f);\n if (logType != PPApplication.ALTYPE_UNDEFINED)\n PPApplicationStatic.addActivityLog(appContext, logType, null, null, \"\");\n //dataWrapper.restartEvents(unblockEventsRun, true, true, false);\n dataWrapper.restartEventsWithRescan(alsoRescan, unblockEventsRun, false, false, true, false);\n //dataWrapper.invalidateDataWrapper();\n\n\n// long finish = System.currentTimeMillis();\n// long timeElapsed = finish - start;\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] ***** DataWrapper.restartEventsWithDelay\", \"--------------- END - timeElapsed=\"+timeElapsed);\n } catch (Exception e) {\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] PPApplication.startHandlerThread\", Log.getStackTraceString(e));\n PPApplicationStatic.recordException(e);\n } finally {\n if ((wakeLock != null) && wakeLock.isHeld()) {\n try {\n wakeLock.release();\n } catch (Exception ignored) {\n }\n }\n //worker.shutdown();\n }\n };\n PPApplicationStatic.createDelayedEventsHandlerExecutor();\n PPApplication.delayedEventsHandlerExecutor.schedule(runnable, 5, TimeUnit.SECONDS);\n }\n }",
"@Override\n public void doTask() throws InterruptedException {\n Thread.sleep(5000);\n }",
"@Override\n public void configureTasks(ScheduledTaskRegistrar scheduledTaskRegistrar) {\n final ThreadPoolTaskScheduler threadPoolTaskScheduler = new ThreadPoolTaskScheduler();\n threadPoolTaskScheduler.setPoolSize(scheduledTaskPoolSize);\n threadPoolTaskScheduler.setThreadNamePrefix(scheduledTaskThreadPrefix);\n threadPoolTaskScheduler.initialize();\n scheduledTaskRegistrar.setTaskScheduler(threadPoolTaskScheduler);\n }",
"public static void main(String[] args) throws Exception, ExecutionException {\n\t\tScheduledExecutorService service=Executors.newSingleThreadScheduledExecutor();\r\n\t\tList<Callable> list=new ArrayList();\r\n\t\tlist.add(new MyCallableBTest());\r\n\t\tlist.add(new MyCallableATest());\r\n\t\tservice.scheduleAtFixedRate(new MyRunnable(),4l,4L,TimeUnit.SECONDS);\r\n\t\t//ScheduledFuture<String> future2=service.schedule(list.get(1),4L,TimeUnit.SECONDS);\r\n\t //System.out.println(future1.get());\r\n\t //System.out.println(future2.get());\r\n\t}",
"@Override\n protected void afterExecute(final Runnable r, final Throwable t) {\n mActiveTasks.remove(r);\n\n // Perform a quick check to see if there are any remaining requests in\n // the blocked queue. Peek the head and check for duplicates in the \n // active and task queues. If no duplicates exist, add the request to\n // the task queue. Repeat this until a duplicate is found\n synchronized (mBlockedTasks) {\n while(mBlockedTasks.peek()!=null && \n !mTaskQueue.contains(mBlockedTasks.peek()) && \n !mActiveTasks.contains(mBlockedTasks.peek())){\n Runnable runnable = mBlockedTasks.poll();\n if(runnable!=null){\n mThreadPool.execute(runnable);\n }\n }\n }\n super.afterExecute(r, t);\n }",
"public static void asyncLater(long delay, Run runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\trunnable.run();\n\t\t\t}\n\t\t}.runTaskLaterAsynchronously(AreaShop.getInstance(), delay);\n\t}",
"private void scheduleJob() {\n\n }",
"@Override\n public boolean isDelayedExecutionSupported()\n {\n return true;\n }",
"@Override\n protected void doStart() {\n threadPool.schedule(this.cacheCleaner, this.cleanInterval, ThreadPool.Names.SAME);\n }",
"private void async(Runnable runnable) {\n Bukkit.getScheduler().runTaskAsynchronously(KitSQL.getInstance(), runnable);\n }",
"private synchronized void addTask(Runnable runnable) {\r\n mTaskQueue.add(runnable);\r\n try {\r\n if (mPoolThreadHandler==null){\r\n mSemaphorePoolThreadHandler.acquire();\r\n }\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n\r\n mPoolThreadHandler.sendEmptyMessage(0x110);\r\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"@Override\n\t\t\tpublic void run() {\n\t\t\t\tstartRecallJobTask();\n\t\t\t\tmHandler.postDelayed(mHandlerTask, INTERVAL);\n\t\t\t}",
"private void startrun() {\n mHandler.postDelayed(mPollTask, POLL_INTERVAL);\n\t}",
"private static void threadPoolWithSubmit() throws InterruptedException, ExecutionException {\n Executor executor = Executors.newFixedThreadPool(1);\n Callable<String> callable=()->{\n try{\n Thread.sleep(4000);\n System.out.println(\"In callable\");\n Thread.sleep(4000);\n System.out.println(\"In runnable for task id 1\");\n }catch(Exception e){\n e.printStackTrace();\n }\n return \"success\";\n };\n Future<String> future =((ExecutorService) executor).submit(callable);\n System.out.println(\"Future result - \"+future.get()+\" Future is blocking as it blocks until result is obtained\");\n System.out.println(\"End of method \");\n ((ExecutorService) executor).shutdown();\n /*Output\n In callable\n In runnable for task id 1\n Future result - success Future is blocking as it blocks until result is obtained\n End of method\n */\n }",
"public abstract ScheduledExecutorService getWorkExecutor();",
"public static void syncLater(long delay, Run runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\trunnable.run();\n\t\t\t}\n\t\t}.runTaskLater(AreaShop.getInstance(), delay);\n\t}",
"@Override\n\t\tpublic void run() {\n\t\t\tArrayBlockingQueue<ByteBuffer> cachedBuffers = null;\n\t\t\tScheduledFuture<?> futureP = null;\n\t\t\tScheduledFuture<?> futureA = null;\n\t\t\tScheduledFuture<?> futureB = null;\n\t\t\ttry {\n\t\t\t\tScheduledThreadPoolExecutor executor = new ScheduledThreadPoolExecutor(1, new ThreadFactory() {\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic Thread newThread(@Nonnull Runnable r) {\n\t\t\t\t\t\tThread t = new Thread(THREAD_GROUP, r);\n\t\t\t\t\t\tt.setDaemon(true);\n\t\t\t\t\t\treturn t;\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tByteBuffer b = ByteBuffer.wrap(genId);\n\t\t\t\tb.putInt(workerId);\n\t\t\t\tb.putLong(Long.reverse(System.nanoTime()) ^ System.currentTimeMillis());\n\t\t\t\tb.putInt(ThreadLocalFixedSeedRandom.current().nextInt());\n\t\t\t\tb.flip();\n\t\t\t\tb.get(genId);\n\n\t\t\t\t// tasks should be removed if the future is canceled\n\t\t\t\texecutor.setRemoveOnCancelPolicy(true);\n\n\t\t\t\t// make sure shutdown removes all pending tasks\n\t\t\t\texecutor.setContinueExistingPeriodicTasksAfterShutdownPolicy(false);\n\t\t\t\texecutor.setExecuteExistingDelayedTasksAfterShutdownPolicy(false);\n\n\t\t\t\tcachedBuffers = new ArrayBlockingQueue<>(CACHED_BUFFERS);\n\t\t\t\tfor (int i = 0; i < CACHED_BUFFERS; i++) {\n\t\t\t\t\tByteBuffer buff = ByteBuffer.allocate(BUFFER_SIZE);\n\t\t\t\t\tif (rustMode) {\n\t\t\t\t\t\tbuff.order(ByteOrder.LITTLE_ENDIAN);\n\t\t\t\t\t}\n\t\t\t\t\tcachedBuffers.add(buff);\n\t\t\t\t}\n\n\t\t\t\tint personSize = personsGenerator.itemSize();\n\t\t\t\tint auctionSize = auctionsGenerator.itemSize();\n\t\t\t\tint bidSize = bidGenerator.itemSize();\n\n\t\t\t\tlong ratio = targetPartitionSize / TOTAL_EVENT_RATIO;\n\t\t\t\tlong personsToGenerate = (PERSON_EVENT_RATIO * ratio) / personSize;\n\t\t\t\tlong auctionsToGenerate = (AUCTION_EVENT_RATIO * ratio) / auctionSize;\n\t\t\t\tlong bidsToGenerate = (BID_EVENT_RATIO * ratio) / auctionSize;\n\t\t\t\tlong recordsToGenerate = personsToGenerate + auctionsToGenerate + bidsToGenerate;\n\n\t\t\t\tint itemsPerBufferPerson = (BUFFER_SIZE - METADATA_SIZE) / personSize;\n\t\t\t\tint itemsPerBufferAuction = (BUFFER_SIZE - METADATA_SIZE) / auctionSize;\n\t\t\t\tint itemsPerBufferBid = (BUFFER_SIZE - METADATA_SIZE) / bidSize;\n\n\t\t\t\tAtomicLong sharedCounterPerson = new AtomicLong();\n\t\t\t\tAtomicLong sharedCounterAuction = new AtomicLong();\n\t\t\t\tAtomicLong sharedCounterBid = new AtomicLong();\n\n\t\t\t\tstarter.countDown();\n\t\t\t\tfairStarter.await();\n\n\t\t\t\tThroughtputLogger personLogger = new ThroughtputLogger(sharedCounterPerson, csvDirectory, name, topicNamePerson + \"-\" + workerId, 5, personSize);\n\t\t\t\tfutureP = executor.scheduleAtFixedRate(personLogger, 5, 5, TimeUnit.SECONDS);\n\n\t\t\t\tThroughtputLogger auctionLogger = new ThroughtputLogger(sharedCounterAuction, csvDirectory, name, topicNameAuction + \"-\" + workerId,5, auctionSize);\n\t\t\t\tfutureA = executor.scheduleAtFixedRate(auctionLogger, 6, 5, TimeUnit.SECONDS);\n\n\t\t\t\tThroughtputLogger bidsLogger = new ThroughtputLogger(sharedCounterBid, csvDirectory, name, topicNameBid + \"-\" + workerId,5, bidSize);\n\t\t\t\tfutureB = executor.scheduleAtFixedRate(bidsLogger, 6, 5, TimeUnit.SECONDS);\n\n\t\t\t\tdouble startMs = System.currentTimeMillis();\n\t\t\t\tlong sentBytes = 0;\n\t\t\t\tThreadLocalFixedSeedRandom randomness = ThreadLocalFixedSeedRandom.current();\n\n\n\t\t\t\tlong desiredThroughputBytesPerSecondMax = desiredThroughputBytesPerSecond;\n\t\t\t\tlong desiredThroughputBytesPerSecondMin = varyingWorkload ? 1024 * 1024 : desiredThroughputBytesPerSecond; // 1 MB/s\n\t\t\t\tlong throughputDelta = varyingWorkload ? 512 * 1024 : 0;\n\t\t\t\tlong currentThroughput = desiredThroughputBytesPerSecondMin;\n\t\t\t\tlong throughputChangeTimestamp = 0;\n\n\t\t\t\tRateLimiter throughputThrottler = RateLimiter.create(currentThroughput, 5, TimeUnit.SECONDS);\n\t\t\t\tLOG.debug(\"Create throughputThrottler for {} -> << {} MB/sec : {} MB/sec >>\",\n\t\t\t\t\t\tworkerId, desiredThroughputBytesPerSecondMin / ONE_MEGABYTE, desiredThroughputBytesPerSecondMax / ONE_MEGABYTE);\n\t\t\t\tint chkP = personsGenerator.genChecksum();\n\t\t\t\tint chkA = auctionsGenerator.genChecksum();\n\t\t\t\tint chkB = bidGenerator.genChecksum();\n\t\t\t\tlong pendingPerson = (recordsToGenerate / TOTAL_EVENT_RATIO) * PERSON_EVENT_RATIO;\n\t\t\t\tlong pendingAuctions = (recordsToGenerate / TOTAL_EVENT_RATIO) * AUCTION_EVENT_RATIO;\n\t\t\t\tlong pendingBids = (recordsToGenerate / TOTAL_EVENT_RATIO) * BID_EVENT_RATIO;\n\t\t\t\tlong sentBytesDelta = 0;\n\t\t\t\tByteBuffer bufP = cachedBuffers.take();\n\t\t\t\tByteBuffer bufA = cachedBuffers.take();\n\t\t\t\tByteBuffer bufB = cachedBuffers.take();\n\t\t\t\tbufA.putInt(chkA);\n\t\t\t\tbufP.putInt(chkP);\n\t\t\t\tbufB.putInt(chkB);\n\t\t\t\tint itemsInThisBufferA = (int) Math.min(itemsPerBufferAuction, pendingAuctions);\n\t\t\t\tint itemsInThisBufferP = (int) Math.min(itemsPerBufferPerson, pendingPerson);\n\t\t\t\tint itemsInThisBufferB = (int) Math.min(itemsPerBufferBid, pendingBids);\n\t\t\t\tlong backlogPerson = pendingPerson - itemsInThisBufferP;\n\t\t\t\tlong backlogAuction = pendingAuctions - itemsInThisBufferA;\n\t\t\t\tlong backlogBid = pendingBids - itemsInThisBufferA;\n\t\t\t\tbufP.putInt(itemsInThisBufferP);\n\t\t\t\tbufP.putLong(backlogPerson);\n\t\t\t\tbufA.putInt(itemsInThisBufferA);\n\t\t\t\tbufA.putLong(backlogAuction);\n\t\t\t\tbufB.putInt(itemsInThisBufferB);\n\t\t\t\tbufB.putLong(backlogBid);\n\n\t\t\t\tlong sentPersons = 0;\n\t\t\t\tlong sentAuctions = 0;\n\t\t\t\tlong sentBids = 0;\n\t\t\t\tlong eventId = 0;\n\n\t\t\t\tfor (; eventId < recordsToGenerate; eventId++) {\n\n\t\t\t\t\tfinal long timestamp = System.currentTimeMillis();\n\n\t\t\t\t\tlong rem = eventId % TOTAL_EVENT_RATIO;\n\t\t\t\t\tif (rem < PERSON_EVENT_RATIO) {\n\t\t\t\t\t\tpersonsGenerator.writeItem(eventId, timestamp, randomness, bufP);\n\t\t\t\t\t\tpendingPerson--;\n\t\t\t\t\t\tif (bufP.remaining() < personSize) {\n\t\t\t\t\t\t\tbufP.position(bufP.position() + bufP.remaining());\n\t\t\t\t\t\t\tProducerRecord<byte[], ByteBuffer> kafkaRecord = new ProducerRecord<>(topicNamePerson, targetPartition, genId, bufP);\n\t\t\t\t\t\t\tkafkaProducerPersons.send(kafkaRecord, new InternalCallback(cachedBuffers, bufP, sharedCounterPerson, itemsInThisBufferP));\n\t\t\t\t\t\t\tsentPersons += itemsInThisBufferP;\n\t\t\t\t\t\t\tbufP = cachedBuffers.take();\n\t\t\t\t\t\t\tbufP.putInt(chkP);\n\t\t\t\t\t\t\titemsInThisBufferP = (int) Math.min(itemsPerBufferPerson, pendingPerson);\n\t\t\t\t\t\t\tbacklogPerson = pendingPerson - itemsInThisBufferP;\n\t\t\t\t\t\t\tbufP.putInt(itemsInThisBufferP);\n\t\t\t\t\t\t\tbufP.putLong(backlogPerson);\n\t\t\t\t\t\t\tsentBytes += BUFFER_SIZE;\n\t\t\t\t\t\t\tsentBytesDelta += BUFFER_SIZE;\n\t\t\t\t\t\t\tthroughputThrottler.acquire(BUFFER_SIZE);\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (rem < (PERSON_EVENT_RATIO + AUCTION_EVENT_RATIO)) {\n\t\t\t\t\t\tauctionsGenerator.writeItem(eventId, timestamp, randomness, bufA);\n\t\t\t\t\t\tpendingAuctions--;\n\t\t\t\t\t\tif (bufA.remaining() < auctionSize) {\n\t\t\t\t\t\t\tbufA.position(bufA.position() + bufA.remaining());\n\t\t\t\t\t\t\tProducerRecord<byte[], ByteBuffer> kafkaRecord = new ProducerRecord<>(topicNameAuction, targetPartition, genId, bufA);\n\t\t\t\t\t\t\tkafkaProducerAuctions.send(kafkaRecord, new InternalCallback(cachedBuffers, bufA, sharedCounterAuction, itemsInThisBufferA));\n\t\t\t\t\t\t\tsentAuctions += itemsInThisBufferA;\n\t\t\t\t\t\t\tbufA = cachedBuffers.take();\n\t\t\t\t\t\t\tbufA.putInt(chkA);\n\t\t\t\t\t\t\titemsInThisBufferA = (int) Math.min(itemsPerBufferAuction, pendingAuctions);\n\t\t\t\t\t\t\tbacklogAuction = pendingAuctions - itemsInThisBufferA;\n\t\t\t\t\t\t\tbufA.putInt(itemsInThisBufferA);\n\t\t\t\t\t\t\tbufA.putLong(backlogAuction);\n\t\t\t\t\t\t\tsentBytes += BUFFER_SIZE;\n\t\t\t\t\t\t\tsentBytesDelta += BUFFER_SIZE;\n\t\t\t\t\t\t\tthroughputThrottler.acquire(BUFFER_SIZE);\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tbidGenerator.writeItem(eventId, timestamp, randomness, bufB);\n\t\t\t\t\t\tpendingBids--;\n\t\t\t\t\t\tif (bufB.remaining() < bidSize) {\n\t\t\t\t\t\t\tbufB.position(bufB.position() + bufB.remaining());\n\t\t\t\t\t\t\tProducerRecord<byte[], ByteBuffer> kafkaRecord = new ProducerRecord<>(topicNameBid, targetPartition, genId, bufB);\n\t\t\t\t\t\t\tkafkaProducerBids.send(kafkaRecord, new InternalCallback(cachedBuffers, bufB, sharedCounterBid, itemsInThisBufferB));\n\t\t\t\t\t\t\tsentBids += itemsInThisBufferB;\n\t\t\t\t\t\t\tbufB = cachedBuffers.take();\n\t\t\t\t\t\t\tbufB.putInt(chkB);\n\t\t\t\t\t\t\titemsInThisBufferB = (int) Math.min(itemsPerBufferBid, pendingBids);\n\t\t\t\t\t\t\tbacklogBid = pendingBids - itemsInThisBufferB;\n\t\t\t\t\t\t\tbufB.putInt(itemsInThisBufferB);\n\t\t\t\t\t\t\tbufB.putLong(backlogBid);\n\t\t\t\t\t\t\tsentBytes += BUFFER_SIZE;\n\t\t\t\t\t\t\tsentBytesDelta += BUFFER_SIZE;\n\t\t\t\t\t\t\tthroughputThrottler.acquire(BUFFER_SIZE);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n//\n\n\t\t\t\t\tif (sentBytesDelta > LOGGING_THRESHOLD) {\n\t\t\t\t\t\tLOG.info(\"{} has just sent {} MB to kafka in {} sec - rate limiter {} bytes/sec\",\n\t\t\t\t\t\t\t\tname,\n\t\t\t\t\t\t\t\tsentBytes / ONE_MEGABYTE,\n\t\t\t\t\t\t\t\t(timestamp - startMs) / 1_000,\n\t\t\t\t\t\t\t\tthroughputThrottler.getRate());\n\t\t\t\t\t\tsentBytesDelta = 0;\n\t\t\t\t\t}\n\n\t\t\t\t\tif ((timestamp - throughputChangeTimestamp) > 10_000) {\n\t\t\t\t\t\tcurrentThroughput += throughputDelta;\n\t\t\t\t\t\tif (currentThroughput > desiredThroughputBytesPerSecondMax) {\n\t\t\t\t\t\t\tthroughputDelta = -throughputDelta;\n\t\t\t\t\t\t} else if (currentThroughput < desiredThroughputBytesPerSecondMin) {\n\t\t\t\t\t\t\tcurrentThroughput = desiredThroughputBytesPerSecondMin;\n\t\t\t\t\t\t\tthroughputDelta = -throughputDelta;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tthroughputThrottler.setRate(currentThroughput);\n\t\t\t\t\t\tthroughputChangeTimestamp = timestamp;\n\t\t\t\t\t\tLOG.debug(\"Throttler changed to {}\", currentThroughput);\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t\twhile (!sharedCounterPerson.compareAndSet(sentPersons, 0)) {\n\t\t\t\t\tThread.sleep(100);\n\t\t\t\t}\n\t\t\t\twhile (!sharedCounterAuction.compareAndSet(sentAuctions, 0)) {\n\t\t\t\t\tThread.sleep(100);\n\t\t\t\t}\n\t\t\t\twhile (!sharedCounterAuction.compareAndSet(sentBids, 0)) {\n\t\t\t\t\tThread.sleep(100);\n\t\t\t\t}\n\t\t\t\tdouble end = System.currentTimeMillis();\n\t\t\t\tdouble diff = end - startMs;\n\t\t\t\tLOG.info(\"{} is finished after {} msec and {} GBs and {} items with an overall throughput of {}\",\n\t\t\t\t\t\tname,\n\t\t\t\t\t\tdiff,\n\t\t\t\t\t\tsentBytes / ONE_GIGABYTE,\n\t\t\t\t\t\trecordsToGenerate,\n\t\t\t\t\t\t(sentBytes * 1_000.0) / (diff * ONE_GIGABYTE));\n\t\t\t} catch (Throwable error) {\n\t\t\t\tLOG.error(\"Error: {}\", error);\n\t\t\t} finally {\n\t\t\t\tif (cachedBuffers != null) {\n\t\t\t\t\tcachedBuffers.clear();\n\t\t\t\t}\n\t\t\t\tkafkaProducerAuctions.close();\n\t\t\t\tkafkaProducerPersons.close();\n\t\t\t\tkafkaProducerBids.close();\n\t\t\t\tcontroller.countDown();\n\t\t\t\tif (futureA != null) {\n\t\t\t\t\tfutureA.cancel(false);\n\t\t\t\t}\n\t\t\t\tif (futureP != null) {\n\t\t\t\t\tfutureP.cancel(false);\n\t\t\t\t}\n\t\t\t\tif (futureB != null) {\n\t\t\t\t\tfutureB.cancel(false);\n\t\t\t\t}\n\t\t\t}\n\t\t}",
"static void scheduleWork(final boolean shortInterval) {\n if (shortInterval) {\n _cancelWork(false);\n //PPApplication.sleep(5000);\n _scheduleWork(true);\n\n /*PPApplication.startHandlerThreadPPScanners();\n final Handler __handler = new Handler(PPApplication.handlerThreadPPScanners.getLooper());\n __handler.post(() -> {\n// PPApplicationStatic.logE(\"[IN_THREAD_HANDLER] PPApplication.startHandlerThreadPPScanners\", \"START run - from=SearchCalendarEventsWorker.scheduleWork\" + \" shortInterval=true\");\n _cancelWork();\n PPApplication.sleep(5000);\n _scheduleWork(true);\n });*/\n }\n else\n _scheduleWork(false);\n }",
"public void schedule(String name, long initialDelay, long period, TimeUnit tunit, OpLevel severity) {\n\t\tif (future == null || future.isCancelled()) {\n\t\t\tactivityTask = newActivityTask(logger, name, severity);\n\t\t\tfuture = scheduler.scheduleAtFixedRate(activityTask, initialDelay, period, tunit);\n\t\t} else {\n\t\t\tthrow new IllegalStateException(\"Already scheduled\");\n\t\t}\n\t}",
"@PostConstruct\n public void setUpTasks() {\n final Iterable<Task> findAll = taskService.findAll();\n if (findAll != null) {\n findAll.forEach(task -> {\n\n final RunnableTask runnableTask = new RunnableTask(task.getId(), runTaskService);\n\n if (task.getCronExpression() != null) {\n log.info(\"Adding cron schedule for {} : {}\", task.getId(), task.getCronExpression());\n threadPoolTaskScheduler.schedule(runnableTask, new CronTrigger(task.getCronExpression()));\n }\n else if (task.getDelayPeriod() > 0) {\n log.info(\"Adding periodic schedule for {} : {}\", task.getId(), task.getDelayPeriod());\n threadPoolTaskScheduler.schedule(runnableTask, new PeriodicTrigger(task.getDelayPeriod()));\n }\n else {\n log.error(\"Invalid task {}\", task.getId());\n }\n\n });\n }\n }",
"@Scheduled(fixedDelay = 15000)\n\tpublic void scheduleFixedDelayTask() {\n\t\t\n\t\tList<Tx> listaTx = txRepo.findAll();\n\t\t\n\t\tfor (Tx tx : listaTx) {\n\t\t\tif(tx.getStatus().equals(TxStatus.PENDING)) {\n\t\t\t\tSystem.out.println(\n\t\t\t\t\t \"Fixed delay task - \" + System.currentTimeMillis() / 20000);\n\t\t\t\t//to be implemented\n\t\t\t\t\n\t\t\t\tString auth = \"Bearer \" + tx.getSbi().getBitcoinAddress();\n\t\t\t\tHttpHeaders headers = new HttpHeaders();\n\t\t\t\theaders.add(\"Authorization\", auth);\n\t\t\t\t\n\t\t\t\tInteger orderId = tx.getorder_id();\n\t\t\t\t\n\t\t\t\tGetOrderResponseDTO getOrderDTO = new GetOrderResponseDTO();\n\t\t\t\t\n\t\t\t ResponseEntity<Object> responseEntity = new RestTemplate().exchange(\"https://api-sandbox.coingate.com/v2/orders/\" + orderId, HttpMethod.GET,\n\t\t\t\t\t\tnew HttpEntity<Object>(getOrderDTO, headers), Object.class);\n\t\t\t \n\t\t\t \n\t\t\t ObjectMapper mapper = new ObjectMapper();\n\t\t\t\tmapper.configure(Feature.ALLOW_UNQUOTED_FIELD_NAMES, true);\n\t\t\t\tGetOrderResponseDTO gorResponse = new GetOrderResponseDTO();\n\t\t\n\t\t\t\tgorResponse = mapper.convertValue(responseEntity.getBody(), GetOrderResponseDTO.class);\n\t\t\n\t\t\t \n\t\t\t System.out.println(\"Order status: \" + gorResponse.getStatus());\n\t\t\t\t\n\t\t\t if(gorResponse.getStatus().equals(\"paid\") || \n\t\t\t \t\tgorResponse.getStatus().equals(\"invalid\") || \n\t\t\t \t\tgorResponse.getStatus().equals(\"expired\") || \n\t\t\t \t\tgorResponse.getStatus().equals(\"canceled\")) {\n\t\t\t \t\n\t\t\t \t//naredne tri linije mi nisu nista jasne zasto sam ovo radio pre mesec dana\n\t\t\t \tTx tx2 = new Tx();\n\t\t \t\ttx2 = txRepo.findByusername(gorResponse.getId());\n\t\t \t\tSystem.out.println(\"TX: \" + tx2.getorder_id());\n\t\t \t\t\n\t\t \t\tRestTemplate restTemplate = new RestTemplate();\n\t\t \t\t\n\t\t \t\tTxInfoDto txInfo;\n\t\t\t \t\n\t\t\t \tif(gorResponse.getStatus().equals(\"paid\")) {\n\t\t\t \t\t\n\t\t\t \t\ttx.setStatus(TxStatus.PAID);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.SUCCESS, \"https://localhost:8764/bitCoin\");\n\t\t\t \t\t\t\n\t\t\t \t} else if(gorResponse.getStatus().equals(\"invalid\")) {\n\t\t\t \t\ttx.setStatus(TxStatus.FAILED);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.FAILED, \"https://localhost:8764/bitCoin\");\n\t\t\t \t} else if(gorResponse.getStatus().equals(\"expired\")){\n\t\t\t \t\ttx.setStatus(TxStatus.EXPIRED);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.FAILED, \"https://localhost:8764/bitCoin\");\n\t\t\t \t} else {\n\t\t\t \t\ttx.setStatus(TxStatus.CANCELED);\n\t\t\t \t\ttxInfo = new TxInfoDto(tx.getorder_id(), TxStatusReqHandler.ERROR, \"https://localhost:8764/bitCoin\");\n\t\t\t \t}\n\t\t\t \t\n\t\t\t \ttxRepo.save(tx);\n\t\t \t\tResponseEntity<TxInfoDto> r = restTemplate.postForEntity(\"https://localhost:8111/request/updateTxAfterPaymentIsFinished\", txInfo, TxInfoDto.class);\n\t\t \t\n\t\t\t \t\n\t\t\t \t\n\t\t\t \t\n\t\t\t \t\n\t\t\t }\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\tSystem.out.println(\"Nikom nista\");\n\t\t\t\tlogger.info(\"Scheduled is working...\");\n\t\t\t}\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Nema transakcija :(\");\n\t\t\n\t/*\tif(IS_CREATE) {\n\t\t\tSystem.out.println(\n\t\t\t\t \"Fixed delay task - \" + System.currentTimeMillis() / 20000);\n\t\t\t\t\t\t \t\n\t\t String authToken = STATIC_TOKEN;\n\t\t \n\t\t\tHttpHeaders headers = new HttpHeaders();\n\t\t\theaders.add(\"Authorization\", authToken);\n\t\t\t\n\t\t\tSystem.out.println(\"authtoken : \" + authToken);\n\t\t \n\t\t\tGetOrderResponseDTO getOrderDTO = new GetOrderResponseDTO();\n\t\t\t\n\t\t ResponseEntity<Object> responseEntity = new RestTemplate().exchange(\"https://api-sandbox.coingate.com/v2/orders/\" + STATIC_ID, HttpMethod.GET,\n\t\t\t\t\tnew HttpEntity<Object>(getOrderDTO, headers), Object.class);\n\t\t \n\t\t \n\t\t ObjectMapper mapper = new ObjectMapper();\n\t\t\tmapper.configure(Feature.ALLOW_UNQUOTED_FIELD_NAMES, true);\n\t\t\tGetOrderResponseDTO gorResponse = new GetOrderResponseDTO();\n\t\n\t\t\tgorResponse = mapper.convertValue(responseEntity.getBody(), GetOrderResponseDTO.class);\n\t\n\t\t \n\t\t System.out.println(\"Order status: \" + gorResponse.getStatus());\n\t\t \n\t\t if(gorResponse.getStatus().equals(\"paid\") || gorResponse.getStatus().equals(\"invalid\") || gorResponse.getStatus().equals(\"expired\")) {\n\t\t \t\n\t\t \t/*Tx tx = new Tx();\n\t \t\ttx = txRepo.findByOrder_Id(gorResponse.getId());\n\t \t\tSystem.out.println(\"TX: \" + tx.getorder_id());\n\t\t \t\n\t\t \tif(gorResponse.getStatus().equals(\"paid\")) {\n\t\t \t\t//promenimo u bazi\n\t\t \t\t//txRepo.getOne((Integer)gorResponse.getId());\n\t\t \t\ttx.setStatus(TxStatus.PAID);\n\t\t \t\t\n\t\t \t} else if(gorResponse.getStatus().equals(\"invalid\")) {\n\t\t \t\ttx.setStatus(TxStatus.FAILED);\n\t\t \t} else {\n\t\t \t\ttx.setStatus(TxStatus.EXPIRED);\n\t\t \t}\n\t\t \t\n\t\t \ttxRepo.save(tx);*/\n\t\t /*\t\n\t\t \tIS_CREATE = false;\n\t\t }\n\t\t\t\t\t \n\t\t\t\t \n\t\t} else {\n\t\t\tSystem.out.println(\"Nikom nista\");\n\t\t\tlogger.info(\"Scheduled is working...\");\n\t\t}*/\n\t\t\n\t \n\t \n\t}",
"@Override\n public void run() {\n runTask();\n\n }",
"@Test\n public void testDelay() {\n long future = System.currentTimeMillis() + (rc.getRetryDelay() * 1000L);\n\n rc.delay();\n\n assertTrue(System.currentTimeMillis() >= future);\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"@Scheduled(cron = \"0 0 9-17 * * MON-FRI\")\n\tpublic void scheduleTaskWeekly() {\n\t\tlog.info(\"Cron Task :: Execution Time Every 9 - 17 O'clock Every Weekdays - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"private void scheduleTasks() {\n\t\ttimer.scheduleAtFixedRate(new TimerTask() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\t// Prepare JSON Ping Message\n\t\t\t\ttry {\n\t\t\t\t\tObjectMapper mapper = new ObjectMapper();\n\t\t\t\t\tObjectNode objectNode = mapper.createObjectNode();\n\t\t\t\t\tobjectNode.put(\"type\", \"PING\");\n\n\t\t\t\t\twebSocket.sendText(mapper.writerWithDefaultPrettyPrinter().writeValueAsString(objectNode));\n\n\t\t\t\t\tlog.debug(\"Send Ping to Twitch PubSub. (Keep-Connection-Alive)\");\n\t\t\t\t} catch (Exception ex) {\n\t\t\t\t\tlog.error(\"Failed to Ping Twitch PubSub. ({})\", ex.getMessage());\n\t\t\t\t\treconnect();\n\t\t\t\t}\n\n\t\t\t}\n\t\t}, 7000, 282000);\n\t}",
"@Override\npublic void run() {\n perform();\t\n}",
"private Task taskCreator(int seconds){\n return new Task() {\n\n @Override\n protected Object call() throws Exception {\n for(int i=0; i<seconds;i++){\n Thread.sleep(1000);\n updateProgress(i+1, seconds);\n\n }\n return true;\n }\n };\n }",
"private synchronized boolean scheduleSession(SessionTask task, long delay) {\n if (state == STOPPED) return false;\n if (timer == null) timer = new Timer(\"ScanManager\");\n tasklist.add(task);\n timer.schedule(task,delay);\n return true;\n }",
"@Override\n public void scheduler(Task task) {\n task.setStatus(Task.STATUS_RUNNING);\n for (int q = 0; q < quantum; q++) {\n task.addElapsedTime(1);\n generateLog(task);\n TIME++;\n addTasksToRun();\n if (task.getElapsedTime() >= task.getTotalTime()) {\n task.setStatus(Task.STATUS_FINISHED);\n return;\n }\n }\n task.setStatus(Task.STATUS_READY);\n }",
"private TimerTask getTask() {\n\t\tfinal TimedTask tt = this;\n\t\treturn new TimerTask() {\n\t\t\tpublic void run() {\n\t\t\t\ttask();\n\t\t\t\ttt._nextTaskHasRan = true;\n\t\t\t}\n\t\t};\n\t}",
"protected abstract void scheduleSuspicions();",
"@Override\n public void addTasksToRun() {\n //gets the tasks that are ready for execution from the list with new tasks\n List<Task> collect = tasks.stream().filter((task) -> (task.getDate() == TIME))\n .collect(Collectors.toList());\n //sort the tasks inserted. The sort is based in \"priority\" value for all the tasks.\n collect.sort(new Comparator<Task>() {\n @Override\n public int compare(Task o1, Task o2) {\n return o1.getPriority() - o2.getPriority();\n }\n });\n //Change the status of tasks for READY\n collect.stream().forEach((task) -> {\n task.setStatus(Task.STATUS_READY);\n });\n //Adds the tasks to the queue of execution\n tasksScheduler.addAll(collect);\n\n //Removes it from list of new tasks\n tasks.removeAll(collect);\n }",
"@Override\n public void run() {\n schedule();\n }",
"@Override\n\t\tpublic void run() {\n\t\t\ttask();\n\t\t}",
"protected void execute() {\n super.execute ();\n \n // processTasks is ordinarily only called when tasks have accumulated\n // in the buffer and the buffer dispatch condition has been met.\n // \n // This ensures that if there are delayed tasks, they are re-examined,\n // whether there's something in the buffer or not.\n //\n // Fix for bug #13455\n\n if (!delayedTasks.isEmpty ()) {\n processTasks (new ArrayList());\n }\n }",
"public void testPeriodic() {\n Scheduler.getInstance().run();\n }",
"private void scheduleRecurringTasks() {\n\t\t//created directories expected by the system to exist\n\t\tUtil.initializeDataDirectories();\n\n\t\tTestManager.initializeTests();\n\n\t\t// Gets all the periodic tasks and runs them.\n\t\t// If you need to create a new periodic task, add another enum instance to PeriodicTasks.PeriodicTask\n\t\tSet<PeriodicTasks.PeriodicTask> periodicTasks = EnumSet.allOf(PeriodicTasks.PeriodicTask.class);\n\t\tfor (PeriodicTasks.PeriodicTask task : periodicTasks) {\n\t\t\tif (R.IS_FULL_STAREXEC_INSTANCE || !task.fullInstanceOnly) {\n\t\t\t\ttaskScheduler.scheduleWithFixedDelay(task.task, task.delay, task.period.get(), task.unit);\n\t\t\t}\n\t\t}\n\n\t\ttry {\n\t\t\tPaginationQueries.loadPaginationQueries();\n\t\t} catch (Exception e) {\n\t\t\tlog.error(\"unable to correctly load pagination queries\");\n\t\t\tlog.error(e.getMessage(), e);\n\t\t}\n\t}",
"public SseController() {\n ScheduledExecutorService scheduledPool = Executors.newScheduledThreadPool(4);\n scheduledPool.scheduleWithFixedDelay(changeState, 0, 1, TimeUnit.SECONDS);\n }",
"public Integer threadDelay();"
] | [
"0.7236823",
"0.70600593",
"0.6727243",
"0.67061895",
"0.663097",
"0.66304153",
"0.6535021",
"0.6531509",
"0.64821666",
"0.6422245",
"0.6401466",
"0.637604",
"0.62836355",
"0.62767786",
"0.62553436",
"0.62311333",
"0.6229418",
"0.62156487",
"0.619482",
"0.6182855",
"0.6152842",
"0.61453867",
"0.6119276",
"0.61170757",
"0.6111166",
"0.6097961",
"0.6097488",
"0.606298",
"0.6058418",
"0.60523593",
"0.6016826",
"0.60071194",
"0.5998096",
"0.5998096",
"0.5957853",
"0.5943969",
"0.59413975",
"0.5920956",
"0.5911224",
"0.5909234",
"0.589242",
"0.5887317",
"0.5869478",
"0.58363974",
"0.5831707",
"0.58287305",
"0.5809005",
"0.5798608",
"0.57881284",
"0.57556224",
"0.5754396",
"0.5751021",
"0.57495403",
"0.57220805",
"0.57153064",
"0.5710337",
"0.57060343",
"0.56941277",
"0.5685169",
"0.5663688",
"0.56335074",
"0.56286824",
"0.5624068",
"0.5617799",
"0.5614841",
"0.5608792",
"0.56012577",
"0.559455",
"0.5586114",
"0.5583009",
"0.5579793",
"0.5573507",
"0.5572441",
"0.5567192",
"0.5557262",
"0.5553931",
"0.5522349",
"0.55203795",
"0.551394",
"0.5509718",
"0.5508873",
"0.55071414",
"0.5489664",
"0.5489256",
"0.5483299",
"0.54760057",
"0.5469003",
"0.5467612",
"0.54664624",
"0.54571676",
"0.545181",
"0.544284",
"0.5438923",
"0.54379743",
"0.5434154",
"0.5430087",
"0.5420989",
"0.542008",
"0.54191226",
"0.5419024"
] | 0.7105438 | 1 |
an unconfigurable newScheduledThreadPool successfully runs delayed task | public void testUnconfigurableScheduledExecutorService() throws Exception {
final ScheduledExecutorService p =
Executors.unconfigurableScheduledExecutorService
(Executors.newScheduledThreadPool(2));
try (PoolCleaner cleaner = cleaner(p)) {
final CountDownLatch proceed = new CountDownLatch(1);
final Runnable task = new CheckedRunnable() {
public void realRun() {
await(proceed);
}};
long startTime = System.nanoTime();
Future f = p.schedule(Executors.callable(task, Boolean.TRUE),
timeoutMillis(), MILLISECONDS);
assertFalse(f.isDone());
proceed.countDown();
assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));
assertSame(Boolean.TRUE, f.get());
assertTrue(f.isDone());
assertFalse(f.isCancelled());
assertTrue(millisElapsedSince(startTime) >= timeoutMillis());
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void testNewScheduledThreadPool() throws Exception {\n final ScheduledExecutorService p = Executors.newScheduledThreadPool(2);\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"private void runPeriodic() {\n boolean ok = ScheduledFutureTask.super.runAndReset();\n boolean down = isShutdown();\n // Reschedule if not cancelled and not shutdown or policy allows\n if (ok && !down) {\n updateNextExecutionTime();\n MeasurableScheduler.super.getQueue().add(this);\n }\n // This might have been the final executed delayed\n // task. Wake up threads to check.\n else if (down)\n interruptIdleWorkers();\n }",
"private void scheduledTask() {\n connectToNewViews();\n removeDisconnectedViews();\n try {\n Thread.sleep(SCHEDULED_TASK_PERIOD);\n // Scheduling future execution\n\n synchronized (threadPool) {\n if (!threadPool.isShutdown()) {\n threadPool.execute(this::scheduledTask);\n }\n }\n } catch (InterruptedException e) {\n Thread.currentThread().interrupt();\n }\n }",
"@Scheduled(fixedDelay = 3000)\n\tpublic void scheduleTaskWithFixedDelay() {\n\t\tlog.info(\"Fixed Delay Task :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t\t//Sleep TimeUnit\n//\t\ttry {\n//\t\t\tTimeUnit.SECONDS.sleep(5);\n//\t\t} catch (Exception e) {\n//\t\t\tlog.error(\"Ran into an error {}\", e);\n//\t throw new IllegalStateException(e);\n//\t\t}\n\t}",
"public long runScheduledPendingTasks() {\n/* */ try {\n/* 597 */ return this.loop.runScheduledTasks();\n/* 598 */ } catch (Exception e) {\n/* 599 */ recordException(e);\n/* 600 */ return this.loop.nextScheduledTask();\n/* */ } \n/* */ }",
"ScheduledExecutorService getScheduledExecutorService();",
"public static void main(String[] args) {\n ScheduledThreadPoolExecutor scheduledThreadPoolExecutor = new ScheduledThreadPoolExecutor(3);\n scheduledThreadPoolExecutor.setRemoveOnCancelPolicy(true);\n SystemOutUtil.println(\"start schedule\");\n scheduledThreadPoolExecutor.schedule(new DelayCallableTask(), 1000, TimeUnit.MILLISECONDS);\n RunnableScheduledFuture<?> rateFuture =\n (RunnableScheduledFuture<?>) scheduledThreadPoolExecutor\n .scheduleAtFixedRate(new FixRateRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n ScheduledFuture delayFuture =\n scheduledThreadPoolExecutor.scheduleWithFixedDelay(new FixDelayRunnableTask(), 1000, 1000, TimeUnit.MILLISECONDS);\n SystemOutUtil.println(\"end schedule\");\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"start stop\");\n\n// scheduledThreadPoolExecutor.remove(rateFuture); // 无效\n rateFuture.cancel(false);\n try {\n Thread.sleep(1000 * 10);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n scheduledThreadPoolExecutor.shutdown();\n return;\n }",
"@Scheduled(fixedRate = 2000, initialDelay = 5000)\n\tpublic void scheduleTaskWithInitialDelay() {\n\t\tlog.info(\"Fixed Rate Task With Initial Delay :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"@Scheduled(fixedRate = 2000, initialDelay = 5000)\n public void scheduleTaskWithInitialDelay() {\n logger.info(\"Fixed Rate Task with Initial Delay :: Execution Time - {}\", formatter.format(LocalDateTime.now()));\n }",
"ScheduledFuture<?> scheduleTask(long delay, Runnable runnable) {\n return timeoutTaskExecutor.schedule(runnable, delay, TimeUnit.MILLISECONDS);\n }",
"private void schedule() {\n service.scheduleDelayed(task, schedulingInterval);\n isScheduled = true;\n }",
"public void runPendingTasks() {\n/* */ try {\n/* 578 */ this.loop.runTasks();\n/* 579 */ } catch (Exception e) {\n/* 580 */ recordException(e);\n/* */ } \n/* */ \n/* */ try {\n/* 584 */ this.loop.runScheduledTasks();\n/* 585 */ } catch (Exception e) {\n/* 586 */ recordException(e);\n/* */ } \n/* */ }",
"public void testNewSingleThreadScheduledExecutor() throws Exception {\n final ScheduledExecutorService p = Executors.newSingleThreadScheduledExecutor();\n try (PoolCleaner cleaner = cleaner(p)) {\n final CountDownLatch proceed = new CountDownLatch(1);\n final Runnable task = new CheckedRunnable() {\n public void realRun() {\n await(proceed);\n }};\n long startTime = System.nanoTime();\n Future f = p.schedule(Executors.callable(task, Boolean.TRUE),\n timeoutMillis(), MILLISECONDS);\n assertFalse(f.isDone());\n proceed.countDown();\n assertSame(Boolean.TRUE, f.get(LONG_DELAY_MS, MILLISECONDS));\n assertSame(Boolean.TRUE, f.get());\n assertTrue(f.isDone());\n assertFalse(f.isCancelled());\n assertTrue(millisElapsedSince(startTime) >= timeoutMillis());\n }\n }",
"public void run() {\n long start = System.nanoTime();\n try {\n activeCount.inc();\n long delay = start - nextExecutionTime;//实践执行时间-理论应该执行的实际点\n taskExecutionDelay.record(delay, TimeUnit.NANOSECONDS);\n // real logic\n if (isPeriodic())\n runPeriodic();\n else\n ScheduledFutureTask.super.run();\n } finally {\n activeCount.dec();\n taskExecutionTime.record(System.currentTimeMillis() - start, TimeUnit.MILLISECONDS);\n }\n }",
"public void mo37770b() {\n ArrayList<RunnableC3181a> arrayList = f7234c;\n if (arrayList != null) {\n Iterator<RunnableC3181a> it = arrayList.iterator();\n while (it.hasNext()) {\n ThreadPoolExecutorFactory.getScheduledExecutor().execute(it.next());\n }\n f7234c.clear();\n }\n }",
"ScheduledExecutorService getExecutorService();",
"private void beginSchedule(){\n\t\tDivaApp.getInstance().submitScheduledTask(new RandomUpdater(this), RandomUpdater.DELAY, RandomUpdater.PERIOD);\n\t}",
"@Scheduled(fixedRate = 2000)\n\tpublic void scheduleTaskWithFixedRate() {\n\t\tlog.info(\"Fixed Rate Task :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()) );\n\t}",
"void executeAsync(long delayMs, Runnable task);",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"@Test\n @DisplayName(\"Scheduled Future\")\n void testScheduledFuture() throws InterruptedException {\n ScheduledExecutorService executor = Executors.newScheduledThreadPool(1);\n ScheduledFuture<String> future = executor.schedule(this::getThreadName, 3, TimeUnit.SECONDS);\n\n TimeUnit.MILLISECONDS.sleep(1337);\n long remainingTime = future.getDelay(TimeUnit.MILLISECONDS);\n\n assertThat(remainingTime).isBetween(1650L, 1670L);\n }",
"public static void main(String[] args) {\n\n ScheduledExecutorService service = Executors.newScheduledThreadPool(4);\n\n //task to run after 10 seconds delay\n service.schedule(new Task(), 10, TimeUnit.SECONDS);\n\n //task to repeatedly every 10 seconds\n service.scheduleAtFixedRate(new Task(), 15, 10, TimeUnit.SECONDS);\n\n //task to run repeatedly 10 seconds after previous task completes\n service.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\n\n for (int i = 0; i < 100; i++) {\n System.out.println(\"task number - \" + i + \" \");\n service.execute(new Task());\n }\n System.out.println(\"Thread name: \" + Thread.currentThread().getName());\n\n }",
"void scheduleTask(long delay) {\n executorService.schedule(\n backgroundTask, delay, TimeUnit.MILLISECONDS);\n }",
"public Future<?> scheduleOneShot(long delay, Runnable runnable) {\n\t\tif (!Raptor.getInstance().isDisposed() && !isDisposed) {\n\t\t\ttry {\n\t\t\t\treturn executor.schedule(new RunnableExceptionDecorator(\n\t\t\t\t\t\trunnable), delay, TimeUnit.MILLISECONDS);\n\t\t\t} catch (RejectedExecutionException rej) {\n\t\t\t\tif (!Raptor.getInstance().isDisposed()) {\n\t\t\t\t\tLOG.error(\"Error executing runnable in scheduleOneShot: \",\n\t\t\t\t\t\t\trej);\n\t\t\t\t\tthreadDump();\n\t\t\t\t\tRaptor.getInstance().onError(\n\t\t\t\t\t\t\t\"ThreadServie has no more threads. A thread dump can be found at \"\n\t\t\t\t\t\t\t\t\t+ THREAD_DUMP_FILE_PATH);\n\t\t\t\t}\n\t\t\t\treturn null;\n\t\t\t}\n\t\t} else {\n\t\t\tLOG.info(\"Veoting runnable \" + runnable + \" raptor is disposed.\");\n\t\t\treturn null;\n\t\t}\n\t}",
"ScheduledFutureTask(Callable<V> callable, long ns) {\n super(callable);\n this.nextExecutionTime = ns;\n this.period = 0;\n this.sequenceNumber = sequencer.getAndIncrement();\n }",
"@PostConstruct\n public void init() {\n threadPoolTaskScheduler.scheduleWithFixedDelay(this::process, Instant.now(), Duration.ofSeconds(30));\n }",
"private static Future<?> directExecute(Runnable runnable, long delay) {\n Future<?> future = null;\n if (delay > 0) {\n /* no serial, but a delay: schedule the task */\n if (!(executor instanceof ScheduledExecutorService)) {\n throw new IllegalArgumentException(\"The executor set does not support scheduling\");\n }\n ScheduledExecutorService scheduledExecutorService = (ScheduledExecutorService) executor;\n future = scheduledExecutorService.schedule(runnable, delay, TimeUnit.MILLISECONDS);\n } else {\n if (executor instanceof ExecutorService) {\n ExecutorService executorService = (ExecutorService) executor;\n future = executorService.submit(runnable);\n } else {\n /* non-cancellable task */\n executor.execute(runnable);\n }\n }\n return future;\n }",
"@Test\n public void testTask() throws InterruptedException {\n\n SchedulingRunnable task1 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task1, \"0/15 * * * * ?\");\n Thread.sleep(10000);\n\n SchedulingRunnable task2 = new SchedulingRunnable(\"demoTask\", \"taskWithParams\", \"aaa\",\"111\");\n cronTaskRegistrar.addCronTask(task2, \"0/8 * * * * ?\");\n // 便于观察\n\n Thread.sleep(3000000);\n }",
"public void schedule() {\n cancel();\n timer.schedule(new TimerTask() {\n @Override\n public void run() {\n runnable.run();\n }\n }, delay);\n }",
"private SleeperTask()\r\n\t{\r\n\t\ttimer = new Timer();\r\n\t\tprovider = null;\r\n\t\taction = \"\";\r\n\t\tverbose = false;\r\n\t\tsetRepeat(5);\r\n\t}",
"ScheduledFuture<?> scheduleAtFixedRate(Runnable publisher, long period, TimeUnit timeUnit, ProbeLevel probeLevel);",
"public void runDelayedTasks(Class<? extends Task> taskClass) {\n log.info(\"Running delayed tasks...\");\n serializeExecutionOfTasks(delayedTasks, taskClass);\n }",
"public void schedule(Runnable job, long delay, TimeUnit unit);",
"@Scheduled(fixedDelay=5000) //indicamos que esta tarea se repetira cada 5 segundos \n\tpublic void doTask() {\n\t\tLOGGER.info(\"Time is: \"+ new Date());\n\t}",
"@PostConstruct\n public void postConstruct() {\n execService = Executors.newScheduledThreadPool(1);\n scheduledFuture = execService.scheduleAtFixedRate(this, 0, PUSH_REPEAT_DELAY, TimeUnit.MILLISECONDS);\n }",
"@Override\n public void configureTasks(ScheduledTaskRegistrar scheduledTaskRegistrar) {\n final ThreadPoolTaskScheduler threadPoolTaskScheduler = new ThreadPoolTaskScheduler();\n threadPoolTaskScheduler.setPoolSize(scheduledTaskPoolSize);\n threadPoolTaskScheduler.setThreadNamePrefix(scheduledTaskThreadPrefix);\n threadPoolTaskScheduler.initialize();\n scheduledTaskRegistrar.setTaskScheduler(threadPoolTaskScheduler);\n }",
"@Override\n public boolean isDelayedExecutionSupported()\n {\n return true;\n }",
"@Override\n\tpublic void execute() {\n\t\tThreadPool pool=ThreadPool.getInstance();\n\t\tpool.beginTaskRun(this);\n\t}",
"public void calibrateAndRunTask(){\n calibrateMaxConcurrentActions();\n\n runTasks();\n }",
"private void handleActionOnce() {\n // TODO: Handle action\n try {\n Executors.newScheduledThreadPool(1).submit(new NewsReceiveTask(getApplicationContext() , true));\n } catch (Exception e) {\n e.printStackTrace();\n }\n }",
"private void scheduleNext() {\n lock.lock();\n try {\n active = tasks.poll();\n if (active != null) {\n executor.execute(active);\n terminating.signalAll();\n } else {\n //As soon as a SerialExecutor is empty, we remove it from the executors map.\n if (lock.isHeldByCurrentThread() && isEmpty() && this == serialExecutorMap.get(identifier)) {\n serialExecutorMap.remove(identifier);\n terminating.signalAll();\n if (state == State.SHUTDOWN && serialExecutorMap.isEmpty()) {\n executor.shutdown();\n }\n }\n }\n } finally {\n lock.unlock();\n }\n }",
"public void begin() {\n\t\t\tGeneralThreadPool.getInstance().schedule(this, 3000);\n\t\t}",
"public void begin() {\n\t\t\tGeneralThreadPool.getInstance().schedule(this, 3000);\n\t\t}",
"public abstract ScheduledExecutorService getWorkExecutor();",
"public static void main(String[] args) throws Exception {\n ScheduledExecutorService exec = Executors.newScheduledThreadPool(3);// 3 threads\n\n System.out.println(\"TIME: \" + dateFormatter.format(new Date()));\n\n\n ScheduledFuture<?> sf1 = exec.schedule(new ScheduledTaskB(3000), 4,TimeUnit.SECONDS); // TASK-1\n ScheduledFuture<?> sf2 = exec.schedule(new CalculationTaskD(0,3,3000), 6, TimeUnit.SECONDS); // TASK-2\n\n exec.schedule(new ScheduledTaskB(0), 8, TimeUnit.SECONDS);\n ScheduledFuture<?> sf4 = exec.schedule(new CalculationTaskD(3,4,0), 10 , TimeUnit.SECONDS); // TASK-4\n\n exec.shutdown();\n sf1.cancel(true);\n sf2.cancel(true);\n\n // GET RESULTS ////////////////////////////////////////////////////////////\n\n System.out.println(\"\\n\\n\\nGetting results: \");\n\n /*\n .get() blocks until result is available\n */\n System.out.println(\"TASK-1: \" + sf1.get() + \"\\n\");\n System.out.println(\"TASK-2: \" + sf2.get() + \"\\n\");\n System.out.println(\"TASK-4: \" + sf4.get() + \"\\n\");\n\n\n\n\n\n }",
"ScheduledFutureTask(Runnable r, V result, long ns, long period) {\n this(r, result, ns, period, false);\n }",
"@PostConstruct\n public void setUpTasks() {\n final Iterable<Task> findAll = taskService.findAll();\n if (findAll != null) {\n findAll.forEach(task -> {\n\n final RunnableTask runnableTask = new RunnableTask(task.getId(), runTaskService);\n\n if (task.getCronExpression() != null) {\n log.info(\"Adding cron schedule for {} : {}\", task.getId(), task.getCronExpression());\n threadPoolTaskScheduler.schedule(runnableTask, new CronTrigger(task.getCronExpression()));\n }\n else if (task.getDelayPeriod() > 0) {\n log.info(\"Adding periodic schedule for {} : {}\", task.getId(), task.getDelayPeriod());\n threadPoolTaskScheduler.schedule(runnableTask, new PeriodicTrigger(task.getDelayPeriod()));\n }\n else {\n log.error(\"Invalid task {}\", task.getId());\n }\n\n });\n }\n }",
"public void startTaskTriggerCheckerThread() {\n new Thread(new Runnable() {\n @Override\n public void run() {\n canRunEnqueueTaskThread.set(true);\n while(canRunEnqueueTaskThread.get()) {\n try {\n Thread.sleep(1000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n if(taskEnqueued.get() || canRunTaskThread.get()) { //do not enqueue the task if an instance of that task is already enqueued or running.\n continue;\n //log(PrioritizedReactiveTask.this.getClass().getSimpleName() + \" already in queue or is currently executing\");\n } else if(shouldTaskActivate()) {\n System.out.println(\"Thread \" + Thread.currentThread().getId() + \" enqueued task: \" + this.getClass().getSimpleName());\n taskQueue.add(PrioritizedReactiveTask.this);\n activeTasks.add(PrioritizedReactiveTask.this);\n taskEnqueued.set(true);\n try {\n Thread.sleep(5000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n }\n }\n }).start();\n }",
"@Override\n public void disabledPeriodic() {\n\tScheduler.getInstance().run();\n }",
"public static void main(String args[])\n {\n\t ScheduledExecutorService executorService= Executors.newScheduledThreadPool(2);\n\t Runnable task1=new RunnableChild(\"task1\");\n\t Runnable task2=new RunnableChild(\"task2\");\n\t Runnable task3=new RunnableChild(\"task3\");\n\t executorService.submit(task1);\n\t executorService.submit(task2);\n\t executorService.submit(task3);\n\t executorService.schedule(task1,20, TimeUnit.SECONDS);\n\t System.out.println(\"*******shutting down called\");\n\t executorService.shutdown();\n }",
"void restartEventsWithDelay(final boolean longDelay, final boolean alsoRescan, final boolean unblockEventsRun,\n final int logType)\n {\n if (longDelay) {\n\n Data workData = new Data.Builder()\n .putBoolean(PhoneProfilesService.EXTRA_ALSO_RESCAN, alsoRescan)\n .putBoolean(PhoneProfilesService.EXTRA_UNBLOCK_EVENTS_RUN, unblockEventsRun)\n .putInt(PhoneProfilesService.EXTRA_LOG_TYPE, logType)\n .build();\n\n OneTimeWorkRequest restartEventsWithDelayWorker;\n restartEventsWithDelayWorker =\n new OneTimeWorkRequest.Builder(RestartEventsWithDelayWorker.class)\n .addTag(RestartEventsWithDelayWorker.WORK_TAG_2)\n .setInputData(workData)\n .setInitialDelay(15, TimeUnit.SECONDS)\n .build();\n try {\n if (PPApplicationStatic.getApplicationStarted(true, true)) {\n WorkManager workManager = PPApplication.getWorkManagerInstance();\n if (workManager != null) {\n\n// //if (PPApplicationStatic.logEnabled()) {\n// ListenableFuture<List<WorkInfo>> statuses;\n// statuses = workManager.getWorkInfosForUniqueWork(RestartEventsWithDelayWorker.WORK_TAG);\n// try {\n// List<WorkInfo> workInfoList = statuses.get();\n// } catch (Exception ignored) {\n// }\n// //}\n\n// PPApplicationStatic.logE(\"[WORKER_CALL] DataWrapper.restartEventsWithDelay\", \"xxx\");\n //workManager.enqueue(restartEventsWithDelayWorker);\n //if (replace)\n workManager.enqueueUniqueWork(RestartEventsWithDelayWorker.WORK_TAG_2, ExistingWorkPolicy.REPLACE, restartEventsWithDelayWorker);\n //else\n // workManager.enqueueUniqueWork(RestartEventsWithDelayWorker.WORK_TAG_APPEND, ExistingWorkPolicy.APPEND_OR_REPLACE, restartEventsWithDelayWorker);\n }\n }\n } catch (Exception e) {\n PPApplicationStatic.recordException(e);\n }\n } else {\n// PPApplicationStatic.logE(\"[EXECUTOR_CALL] ***** DataWrapper.restartEventsWithDelay\", \"schedule\");\n\n final Context appContext = context.getApplicationContext();\n //final ScheduledExecutorService worker = Executors.newSingleThreadScheduledExecutor();\n Runnable runnable = () -> {\n// long start = System.currentTimeMillis();\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] ***** DataWrapper.restartEventsWithDelay\", \"--------------- START\");\n\n PowerManager powerManager = (PowerManager) appContext.getSystemService(Context.POWER_SERVICE);\n PowerManager.WakeLock wakeLock = null;\n try {\n if (powerManager != null) {\n wakeLock = powerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, PPApplication.PACKAGE_NAME + \":DataWrapper_restartEventsWithDelay\");\n wakeLock.acquire(10 * 60 * 1000);\n }\n\n //PPExecutors.doRestartEventsWithDelay(alsoRescan, unblockEventsRun, logType, context);\n\n DataWrapper dataWrapper = new DataWrapper(appContext, false, 0, false, 0, 0, 0f);\n if (logType != PPApplication.ALTYPE_UNDEFINED)\n PPApplicationStatic.addActivityLog(appContext, logType, null, null, \"\");\n //dataWrapper.restartEvents(unblockEventsRun, true, true, false);\n dataWrapper.restartEventsWithRescan(alsoRescan, unblockEventsRun, false, false, true, false);\n //dataWrapper.invalidateDataWrapper();\n\n\n// long finish = System.currentTimeMillis();\n// long timeElapsed = finish - start;\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] ***** DataWrapper.restartEventsWithDelay\", \"--------------- END - timeElapsed=\"+timeElapsed);\n } catch (Exception e) {\n// PPApplicationStatic.logE(\"[IN_EXECUTOR] PPApplication.startHandlerThread\", Log.getStackTraceString(e));\n PPApplicationStatic.recordException(e);\n } finally {\n if ((wakeLock != null) && wakeLock.isHeld()) {\n try {\n wakeLock.release();\n } catch (Exception ignored) {\n }\n }\n //worker.shutdown();\n }\n };\n PPApplicationStatic.createDelayedEventsHandlerExecutor();\n PPApplication.delayedEventsHandlerExecutor.schedule(runnable, 5, TimeUnit.SECONDS);\n }\n }",
"ScheduledFutureTask(Runnable r, V result, long ns) {\n super(r, result);\n this.nextExecutionTime = ns;\n this.period = 0;\n this.sequenceNumber = sequencer.getAndIncrement();\n }",
"public ScheduledFuture<?> schedule(Runnable task, long delay) {\n return executor.schedule(task, delay, TimeUnit.MILLISECONDS);\n }",
"@Override\n public void runTasks() {\n BukkitTask task1 = new BukkitRunnable() {\n long start = 0;\n long now = 0;\n\n @Override\n public void run() {\n start = now;\n now = System.currentTimeMillis();\n long tdiff = now - start;\n\n if (tdiff > 0) {\n instTps = (float) (1000 / tdiff);\n }\n }\n }.runTaskTimer(Aurora.getInstance(), 0, 1);\n\n //Task to populate avgTps\n BukkitTask task2 = new BukkitRunnable() {\n ArrayList<Float> tpsList = new ArrayList<>();\n\n @Override\n public void run() {\n Float totalTps = 0f;\n\n tpsList.add(instTps);\n //Remove old tps after 15s\n if (tpsList.size() >= 15) {\n tpsList.remove(0);\n }\n for (Float f : tpsList) {\n totalTps += f;\n }\n avgTps = totalTps / tpsList.size();\n }\n }.runTaskTimerAsynchronously(Aurora.getInstance(), 20, 20);\n\n //Add to runnables[]\n runnables = new BukkitTask[]{task1, task2};\n }",
"public void run(){\n Timer time = new Timer(); // Instantiate Timer Object\n\n ScheduledClass st = new ScheduledClass(this.job,this.shm,time,this.stopp); // Instantiate SheduledTask class\n time.schedule(st, 0, this.periodicwait); // Create Repetitively task for every 1 secs\n }",
"void schedule(long delay, TimeUnit unit) {\r\n\t\tthis.delay = delay;\r\n\t\tthis.unit = unit;\r\n\t\tif (monitor != null) {\r\n\t\t\tmonitor.cancel(false);\r\n\t\t\tmonitor = pool.scheduleWithFixedDelay(sync, delay, delay, unit);\r\n\t\t}\r\n\t}",
"public void schedule(String name, long initialDelay, long period, TimeUnit tunit, OpLevel severity) {\n\t\tif (future == null || future.isCancelled()) {\n\t\t\tactivityTask = newActivityTask(logger, name, severity);\n\t\t\tfuture = scheduler.scheduleAtFixedRate(activityTask, initialDelay, period, tunit);\n\t\t} else {\n\t\t\tthrow new IllegalStateException(\"Already scheduled\");\n\t\t}\n\t}",
"public void testPeriodic() {\n Scheduler.getInstance().run();\n }",
"protected abstract void scheduleSuspicions();",
"private void runScheduleTasks() {\r\n // To minimize the time the lock is held, make a copy of the array\r\n // with the tasks while holding the lock then release the lock and\r\n // execute the tasks\r\n List<Runnable> tasksCopy;\r\n synchronized (taskLock) {\r\n if (tasks.isEmpty()) { return; } \r\n tasksCopy = tasks;\r\n tasks = new ArrayList<Runnable>(4);\r\n }\r\n for (Runnable task : tasksCopy) {\r\n task.run();\r\n } \r\n }",
"public ScheduledFuture<?> schedule(Runnable task, long delay, long period) {\n return executor.scheduleWithFixedDelay(task, delay, period, TimeUnit.MILLISECONDS);\n }",
"public static void scheduleEndingTask(Runnable t, long ms, long initialDelay) {\n try {\n SERVICE.scheduleAtFixedRate(t, initialDelay, ms, TimeUnit.MILLISECONDS);\n } catch (TaskComplete e) {\n //ignored\n //Client.logger.error(\"An error has occurred while executing an asynchronous task!\", e);\n return;\n }catch(Exception e){\n Client.logger.error(\"An error has occurred while executing an asynchronous task!\", e);\n }\n }",
"private void invokePostRefreshTasks(boolean success) {\r\n Vector tasksToRun = null;\r\n \r\n synchronized(postRefreshTasks) {\r\n int size = postRefreshTasks.size();\r\n if(size > 0) {\r\n tasksToRun = new Vector(size);\r\n for(int i=0; i<size; i++) {\r\n Object[] element = (Object[])postRefreshTasks.elementAt(i);\r\n // Add the task if the refresh was successful, or if the\r\n // task does not depend on a successful refresh.\r\n if(success || !((Boolean)element[1]).booleanValue()) {\r\n tasksToRun.addElement((Runnable)element[0]);\r\n }\r\n }\r\n postRefreshTasks.removeAllElements();\r\n }\r\n }\r\n \r\n if(tasksToRun != null) {\r\n int size = tasksToRun.size();\r\n for(int i=0; i<size; i++) {\r\n mailStoreServices.invokeLater((Runnable)tasksToRun.elementAt(i));\r\n }\r\n }\r\n }",
"public <T> ValueFuture<T> schedule(Callable<T> job, long delay, TimeUnit unit);",
"private void scheduleJob() {\n\n }",
"public DynamicSchedule(TaskScheduler scheduler, Runnable task, int delay) {\n\t this.scheduler = scheduler;\n\t this.task = task;\n\t reset(delay);\n\t }",
"public synchronized void execute(Runnable task) throws Exception{\n \n if(threadPoolExecutor.isShutdown()){\n \tSystem.out.println(\"Thread pool \" + \"\" + \" is being Shutdown.\\n\"\n \t\t\t\t\t+ \"No tasks are allowed to be scheduled.\");\n \n }\n //add the task to the queue\n //this will cause a thread in the work pool to pick this up and execute\n queue.put(task);\n System.out.println(\"task has been added.\");\n }",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"public static void activateNonFixedTaskScheduling(Week week, NonFixedTask taskToSchedule){\n NonFixedTask NonFixedTaskToPut = Scheduler.ScheduleTaskInWeek(week, taskToSchedule);\n Putter.putTask(week, NonFixedTaskToPut);\n }",
"private void scheduleRecurringTasks() {\n\t\t//created directories expected by the system to exist\n\t\tUtil.initializeDataDirectories();\n\n\t\tTestManager.initializeTests();\n\n\t\t// Gets all the periodic tasks and runs them.\n\t\t// If you need to create a new periodic task, add another enum instance to PeriodicTasks.PeriodicTask\n\t\tSet<PeriodicTasks.PeriodicTask> periodicTasks = EnumSet.allOf(PeriodicTasks.PeriodicTask.class);\n\t\tfor (PeriodicTasks.PeriodicTask task : periodicTasks) {\n\t\t\tif (R.IS_FULL_STAREXEC_INSTANCE || !task.fullInstanceOnly) {\n\t\t\t\ttaskScheduler.scheduleWithFixedDelay(task.task, task.delay, task.period.get(), task.unit);\n\t\t\t}\n\t\t}\n\n\t\ttry {\n\t\t\tPaginationQueries.loadPaginationQueries();\n\t\t} catch (Exception e) {\n\t\t\tlog.error(\"unable to correctly load pagination queries\");\n\t\t\tlog.error(e.getMessage(), e);\n\t\t}\n\t}",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"public SynchronousTimeLimitedTask() {\n _steps = new ArrayDeque<BooleanSupplier>();\n }",
"static void scheduleWork(final boolean shortInterval) {\n if (shortInterval) {\n _cancelWork(false);\n //PPApplication.sleep(5000);\n _scheduleWork(true);\n\n /*PPApplication.startHandlerThreadPPScanners();\n final Handler __handler = new Handler(PPApplication.handlerThreadPPScanners.getLooper());\n __handler.post(() -> {\n// PPApplicationStatic.logE(\"[IN_THREAD_HANDLER] PPApplication.startHandlerThreadPPScanners\", \"START run - from=SearchCalendarEventsWorker.scheduleWork\" + \" shortInterval=true\");\n _cancelWork();\n PPApplication.sleep(5000);\n _scheduleWork(true);\n });*/\n }\n else\n _scheduleWork(false);\n }",
"@Override\n protected void afterExecute(final Runnable r, final Throwable t) {\n mActiveTasks.remove(r);\n\n // Perform a quick check to see if there are any remaining requests in\n // the blocked queue. Peek the head and check for duplicates in the \n // active and task queues. If no duplicates exist, add the request to\n // the task queue. Repeat this until a duplicate is found\n synchronized (mBlockedTasks) {\n while(mBlockedTasks.peek()!=null && \n !mTaskQueue.contains(mBlockedTasks.peek()) && \n !mActiveTasks.contains(mBlockedTasks.peek())){\n Runnable runnable = mBlockedTasks.poll();\n if(runnable!=null){\n mThreadPool.execute(runnable);\n }\n }\n }\n super.afterExecute(r, t);\n }",
"@Override\n public ScheduledFuture<?> schedule(Runnable task, Trigger trigger) {\n if (!canRun()) {\n return null;\n }\n return super.schedule(task, trigger);\n }",
"@Override\n public void doTask() throws InterruptedException {\n Thread.sleep(5000);\n }",
"static ScheduledExecutorService m52657a() {\n return (ScheduledExecutorService) C7258h.m22724a(C7265m.m22758a(ThreadPoolType.SCHEDULED).mo18993a(1).mo18996a());\n }",
"public static void main(String[] args) throws Exception, ExecutionException {\n\t\tScheduledExecutorService service=Executors.newSingleThreadScheduledExecutor();\r\n\t\tList<Callable> list=new ArrayList();\r\n\t\tlist.add(new MyCallableBTest());\r\n\t\tlist.add(new MyCallableATest());\r\n\t\tservice.scheduleAtFixedRate(new MyRunnable(),4l,4L,TimeUnit.SECONDS);\r\n\t\t//ScheduledFuture<String> future2=service.schedule(list.get(1),4L,TimeUnit.SECONDS);\r\n\t //System.out.println(future1.get());\r\n\t //System.out.println(future2.get());\r\n\t}",
"public void a() {\n NamedRunnable active;\n synchronized (this.mTasks) {\n if (!this.mTasks.isEmpty()) {\n this.mActive = this.mTasks.remove(0);\n } else {\n this.mActive = null;\n com.alipay.mobile.common.task.Log.v(TAG, \"mTasks is empty.\");\n }\n active = this.mActive;\n }\n if (active != null) {\n com.alipay.mobile.common.task.Log.d(TAG, \"StandardPipeline.scheduleNext()\");\n if (this.a != null) {\n this.a.execute(active);\n return;\n }\n throw new RuntimeException(\"The StandardPipeline's Executor is null.\");\n }\n com.alipay.mobile.common.task.Log.d(TAG, \"StandardPipeline.scheduleNext(mTasks is empty)\");\n }",
"@Override\n\tprotected void executeInternal(JobExecutionContext context,\n\t\t\tInteger channelId, Integer applicationId)\n\t\t\tthrows JobExecutionException {\n\t\t\n\t\t\n\t\tTaskManager taskManager = SpringUtil.getBean(TaskManager.class);\n\t\t\n\t\t//TODO 这里没法确定channel code,所以没法通过common notify packet方式生成task\n\t\t//不是很好\n\t\t//个人觉得没必要再单独生成一个额外的扫尾task,可以直接在扫尾的cron job中执行\n\t\tTask task = SpringUtil.getBean(SaoweiTask.class);\n\t\t//TODO 上下文的处理,系统级task上下文,这里暂时塞0吧,没啥关系\n\t\tChannelService channelService = SpringUtil.getBean(ChannelService.class);\n\t\tApplicationService applicationService = SpringUtil.getBean(ApplicationService.class);\n\t\tChannel channel = channelService.getChannelByCode(\"SYSTEM\");\n\t\tList<Application> applications = applicationService.getApplicationsByChannelId(channel.getId());\n\t\tApplication application = applications.get(0);\n\t\tTaskTemplateService templateService = SpringUtil.getBean(TaskTemplateService.class);\n\t\tTaskTemplate template = templateService.getTaskTemplateByTypeAndSubType(\"SYSTEM\", \"saowei\");\n\t\ttry {\n\t\t\ttask.setDataId(String.valueOf(System.nanoTime()));\n\t\t\ttask.setData(\"\");\n\t\t\ttask.setTemplate(template);\n\t\t\t\n\t\t\ttask.getContext().setChannelCode(channel.getCode());\n\t\t\ttask.getContext().setChannelId(channel.getId());\n\t\t\ttask.getContext().setApplicationCode(application.getCode());\n\t\t\ttask.getContext().setApplicationId(application.getId());\n\t\t\ttask.getContext().setStoreId(application.getStoreId());\n\t\t\t\n\t\t\tif (context.getMergedJobDataMap().containsKey(Constant.SCHEDULE_PARAM_TASK_RERUN_DELAY)) {\n\t\t\t\tString taskRerunDelay = (String)context.getMergedJobDataMap().get(Constant.SCHEDULE_PARAM_TASK_RERUN_DELAY);\n\t\t\t\ttask.getContext().put(Constant.SCHEDULE_PARAM_TASK_RERUN_DELAY, taskRerunDelay);\n\t\t\t}\n\t\t\t\n\t\t\ttaskManager.executeTask(task);\n\t\t} catch (TaskException e) {\n\t\t\t//e.printStackTrace();\n\t\t\tLOGGER.error(\"扫尾job运行失败\", e);\n\t\t\tthrow new JobExecutionException(e);\n\t\t}\n\t}",
"private synchronized void addTask(Runnable runnable) {\r\n mTaskQueue.add(runnable);\r\n try {\r\n if (mPoolThreadHandler==null){\r\n mSemaphorePoolThreadHandler.acquire();\r\n }\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n\r\n mPoolThreadHandler.sendEmptyMessage(0x110);\r\n }",
"public String scheduleAFixedDelayJob(Object instance,\n String methodName,\n Class<?>[] inputTypes,\n Object[] inputParams,\n long initialDelay,\n long taskDelay,\n TimeUnit timeUnit);",
"public static void asyncLater(long delay, Run runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\trunnable.run();\n\t\t\t}\n\t\t}.runTaskLaterAsynchronously(AreaShop.getInstance(), delay);\n\t}",
"@Bean\n public ThreadPoolTaskScheduler iotTaskScheduler(){\n ThreadPoolTaskScheduler threadPoolTaskScheduler\n = new ThreadPoolTaskScheduler();\n threadPoolTaskScheduler.setPoolSize(10);\n threadPoolTaskScheduler.setThreadNamePrefix(\n \"iotTaskScheduler\");\n return threadPoolTaskScheduler;\n }",
"@Override\n public void run() {\n task.run();\n }",
"@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\t\n\t}",
"@Test\n public void testNoSkipDelayedBy()\n throws Exception\n {\n workflowConfig.getNestedOrSetEmpty(\"schedule\")\n .set(\"daily>\", \"12:00:00\");\n\n // Indicate that there is no active attempt for this workflow\n when(sessionStore.getActiveAttemptsOfWorkflow(eq(PROJECT_ID), eq(WORKFLOW_NAME), anyInt(), any(Optional.class)))\n .thenReturn(ImmutableList.of());\n\n // Run the schedule executor at now + 1\n scheduleExecutor.runScheduleOnce(now.plusSeconds(1));\n\n // Verify the task was started.\n verify(scheduleExecutor).startSchedule(any(StoredSchedule.class), any(Scheduler.class), any(StoredWorkflowDefinitionWithProject.class));\n\n // Verify that the schedule progressed to the next time\n verify(scs).updateNextScheduleTimeAndLastSessionTime(SCHEDULE_ID, nextScheduleTime, now);\n }",
"private void setupCheckLockTimerTask(String processName, LocalDateTime until, LockRestorer lockerRestorer,\n LocalDateTime now, String unlockKey) {\n if (lockerRestorer != null) {\n final long delayTime = getDelayTimeInMilliseconds(now, until);\n final long renewTime = Duration.between(now, until).toMillis();\n processMap.put(processName + unlockKey, lockerRestorer);\n final CheckLockTimerTask timerTask = new CheckLockTimerTask(this, processName, unlockKey, renewTime);\n if (scheduledExecutorService == null) {\n final Map<String, ScheduledExecutorService> scheduledExecutors = applicationContext.getBeansOfType(ScheduledExecutorService.class);\n if (scheduledExecutors.size() > 0) {\n if (scheduledExecutors.size() == 1) {\n scheduledExecutorService = scheduledExecutors.values().iterator().next();\n } else {\n scheduledExecutorService = scheduledExecutors.get(preferredScheduledExecutorService);\n }\n }\n Assert.notNull(scheduledExecutorService, \"Scheduled executor service not found!\");\n }\n scheduledExecutorService.scheduleAtFixedRate(timerTask, delayTime, renewTime, TimeUnit.MILLISECONDS);\n }\n }",
"protected void onQueued() {}",
"public synchronized void schedule(SchedulerTask schedulerTask, SchedulerTaskState initialState)\n {\n ScheduleIterator iterator = schedulerTask.iterator();\n if (timer == null)\n\t\t\tthrow new IllegalStateException(\"Scheduler '\" + getId() + \"' has already been canceled\");\n \n if (this.scheduledTimerTasks.containsKey(schedulerTask.getKey()))\n throw new IllegalStateException(\"Task '\" + schedulerTask.getKey() + \"' has already been scheduled by scheduler '\" + getId() + \"'\");\n \n // register task to be scheduled\n schedulerTask.schedule(this, initialState);\n\n // determine the next execution time\n Date nextExecution = getNextExecution(iterator);\n if (nextExecution == null)\n {\n // no execution desired -> cancel\n schedulerTask.setState(SchedulerTaskState.CANCELED);\n return;\n }\n \n // register for HSQL\n if (schedulerTask.isVisible())\n {\n IDataAccessor accessor = AdminApplicationProvider.newDataAccessor();\n IDataTransaction transaction = accessor.newTransaction();\n try\n {\n // ensure to create an entry in dapplication because of relation constraint\n // Note: Currently this is only needed for ReportRollOutTask since there might\n // exist scheduled reports related to undeployed applications!\n //\n String applName = schedulerTask.getApplicationName();\n Version applVersion = schedulerTask.getApplicationVersion();\n if (applName != null)\n DeployManager.ensureTransientApplication(accessor, transaction, applName);\n else\n {\n // assign tasks with no specific application to the admin application\n //\n applName = DeployManager.ADMIN_APPLICATION_NAME;\n applVersion = Version.ADMIN;\n }\n \n IDataTable table = accessor.getTable(Enginetask.NAME);\n IDataTableRecord record = table.newRecord(transaction);\n record.setValue(transaction, Enginetask.schedulerid, getId());\n record.setValue(transaction, Enginetask.taskid, schedulerTask.getKey());\n // because of long task names (e.g. R\n record.setStringValueWithTruncation(transaction, Enginetask.name, schedulerTask.getName());\n if (schedulerTask.getScope() != null)\n record.setValue(transaction, Enginetask.scope, schedulerTask.getScope().toString());\n record.setStringValueWithTruncation(transaction, Enginetask.taskdetails, schedulerTask.getTaskDetails());\n record.setValue(transaction, Enginetask.ownerid, schedulerTask.getTaskOwner());\n record.setValue(transaction, Enginetask.applicationname, applName);\n record.setValue(transaction, Enginetask.applicationversion, applVersion);\n record.setValue(transaction, Enginetask.taskstatus, schedulerTask.getState().getName());\n record.setValue(transaction, Enginetask.nextexecution, nextExecution);\n transaction.commit();\n } \n catch (Exception ex)\n {\n // just release a warning since the task itself has been registered for the timer\n if (logger.isWarnEnabled())\n\t\t\t\t{\n\t\t\t\t\tlogger.warn(\"Could not register task in DB: \" + schedulerTask, ex);\n\t\t\t\t}\n }\n finally\n {\n transaction.close();\n }\n }\n \n // Schedule the new task the first time\n //\n SchedulerTimerTask timerTask = new SchedulerTimerTask(schedulerTask, iterator);\n scheduledTimerTasks.put(schedulerTask.getKey(), timerTask);\n timer.schedule(timerTask, nextExecution);\n }",
"public void testTimedCallable() throws Exception {\n final ExecutorService[] executors = {\n Executors.newSingleThreadExecutor(),\n Executors.newCachedThreadPool(),\n Executors.newFixedThreadPool(2),\n Executors.newScheduledThreadPool(2),\n };\n\n final Runnable sleeper = new CheckedInterruptedRunnable() {\n public void realRun() throws InterruptedException {\n delay(LONG_DELAY_MS);\n }};\n\n List<Thread> threads = new ArrayList<Thread>();\n for (final ExecutorService executor : executors) {\n threads.add(newStartedThread(new CheckedRunnable() {\n public void realRun() {\n Future future = executor.submit(sleeper);\n assertFutureTimesOut(future);\n }}));\n }\n for (Thread thread : threads)\n awaitTermination(thread);\n for (ExecutorService executor : executors)\n joinPool(executor);\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"@Override\n protected void doStart() {\n threadPool.schedule(this.cacheCleaner, this.cleanInterval, ThreadPool.Names.SAME);\n }",
"private void startrun() {\n mHandler.postDelayed(mPollTask, POLL_INTERVAL);\n\t}",
"@Scheduled(cron = \"0 0 9-17 * * MON-FRI\")\n\tpublic void scheduleTaskWeekly() {\n\t\tlog.info(\"Cron Task :: Execution Time Every 9 - 17 O'clock Every Weekdays - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public void initAlgorithm() {\n executor.scheduleAtFixedRate(scheduledThoughtsProducer::periodicalThoughtsCheck, 1, 5,TimeUnit.MINUTES);\n// executor.scheduleAtFixedRate(scheduledThoughtsProducer::periodicalThoughtsCheck, 2, 10,TimeUnit.SECONDS);\n\n // every day perform random thought dice roll\n // also roll for random time: 10am - 9pm\n Cron4j.scheduler.schedule(Cron4j.EVERY_DAY_AT_10_AM, () -> {\n int produceThoughtDice = (int) (Math.random() * 3); // 66% yes, 33% no\n if (produceThoughtDice < 2) {\n int timeShift = (int) (Math.random() * 12); // 0-11\n executor.schedule(scheduledThoughtsProducer::periodicalThoughtProduceSuitable, timeShift, TimeUnit.HOURS);\n } else {\n System.out.println(\"Thought not produced today because of the dice: \" + produceThoughtDice);\n }\n });\n// Cron4j.scheduler.schedule(Cron4j.EVERY_MINUTE, () -> {\n// executor.schedule(scheduledThoughtsProducer::periodicalThoughtProduceSuitable, 0, TimeUnit.SECONDS);\n// });\n\n // every week perform a statistical overview\n // should be not very long and with a lot of variations\n Cron4j.scheduler.schedule(Cron4j.EVERY_WEEK_SUNDAY_18_PM, () -> {\n// Cron4j.scheduler.schedule(Cron4j.EVERY_MINUTE, () -> {\n executor.schedule(scheduledThoughtsProducer::periodicalWeeklyThoughts, 0, TimeUnit.SECONDS);\n });\n\n // start the scheduler\n Cron4j.scheduler.start();\n }",
"public static void main(String[] args) {\r\n\t\tScheduledExecutorService execService = Executors.newScheduledThreadPool(1);\r\n\t\t/*\r\n\t\t * Runnable task created as MyTask\r\n\t\t */\r\n\t\tMyTask myTask = new MyTask();\r\n\t\t/*\r\n\t\t * ScheduledExecutorService will run or schedule the myTask after 5 seconds(only one time scheduled)\r\n\t\t * @param task to complete\r\n\t\t * @param start after 5 seconds\r\n\t\t * @param time unit for execution\r\n\t\t */\r\n\t\texecService.schedule(myTask, 5, TimeUnit.SECONDS);\r\n\t\t/*\r\n\t\t * scheduleAtFixedRate method of ScheduledExecutorService will execute after certain interval\r\n\t\t * @param task to complete\r\n\t\t * @param first start after 0 seconds\r\n\t\t * @param run after every 5 seconds\r\n\t\t * @param time unit for execution\r\n\t\t */\r\n\t\t//execService.scheduleAtFixedRate(myTask, 0, 5, TimeUnit.SECONDS);\r\n\t\t\r\n\t\t/*\r\n\t\t * while using scheduleAtFixedRate, shutdown method should not be called.\r\n\t\t * otherwise it will execute only one time.\r\n\t\t */\r\n\t\texecService.shutdown();\r\n\t}",
"public static void syncLater(long delay, Run runnable) {\n\t\tnew BukkitRunnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\trunnable.run();\n\t\t\t}\n\t\t}.runTaskLater(AreaShop.getInstance(), delay);\n\t}",
"@Test\n @SneakyThrows\n void test() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n\n Runnable runnable = () -> {\n System.out.println(\"this is a new thread !!\");\n System.out.println(\"===============\");\n try {\n Thread.sleep(3000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n };\n\n for (int i = 0; i < 3; i++) {\n executor.submit(runnable);\n }\n Thread.sleep(10 * 1000);\n\n executor.shutdown();\n\n }"
] | [
"0.72077656",
"0.71684086",
"0.7163372",
"0.67716396",
"0.6743569",
"0.6643054",
"0.6619646",
"0.658632",
"0.65660775",
"0.65652156",
"0.64955014",
"0.64943933",
"0.6365527",
"0.63384694",
"0.63333565",
"0.6282191",
"0.6221466",
"0.62105983",
"0.6189641",
"0.61824477",
"0.6176111",
"0.61588395",
"0.6140232",
"0.6126053",
"0.6119868",
"0.6119478",
"0.6107254",
"0.60589105",
"0.60441035",
"0.6043137",
"0.60386556",
"0.60031635",
"0.5989824",
"0.597977",
"0.594785",
"0.5943829",
"0.59317976",
"0.5917953",
"0.5908485",
"0.5875258",
"0.58667266",
"0.5850916",
"0.5850916",
"0.58152825",
"0.5805321",
"0.5800907",
"0.5798439",
"0.5789605",
"0.5789189",
"0.57867503",
"0.577274",
"0.5749474",
"0.5739347",
"0.57369137",
"0.57267106",
"0.5721347",
"0.572037",
"0.5719917",
"0.570967",
"0.5698064",
"0.5687027",
"0.56786615",
"0.5660346",
"0.5645655",
"0.56314087",
"0.5627515",
"0.56240624",
"0.5623978",
"0.56015974",
"0.55942667",
"0.5583214",
"0.55631995",
"0.5551438",
"0.5531913",
"0.5524869",
"0.5523294",
"0.5522762",
"0.55164045",
"0.55111337",
"0.5507664",
"0.55065674",
"0.5504631",
"0.5502735",
"0.55016285",
"0.55013853",
"0.54996663",
"0.5499392",
"0.54935926",
"0.54892427",
"0.5486703",
"0.54756814",
"0.5474509",
"0.5472795",
"0.5470451",
"0.5464789",
"0.5455859",
"0.5454882",
"0.545386",
"0.5448996",
"0.5443764"
] | 0.68004364 | 3 |
Future.get on submitted tasks will time out if they compute too long. | public void testTimedCallable() throws Exception {
final ExecutorService[] executors = {
Executors.newSingleThreadExecutor(),
Executors.newCachedThreadPool(),
Executors.newFixedThreadPool(2),
Executors.newScheduledThreadPool(2),
};
final Runnable sleeper = new CheckedInterruptedRunnable() {
public void realRun() throws InterruptedException {
delay(LONG_DELAY_MS);
}};
List<Thread> threads = new ArrayList<Thread>();
for (final ExecutorService executor : executors) {
threads.add(newStartedThread(new CheckedRunnable() {
public void realRun() {
Future future = executor.submit(sleeper);
assertFutureTimesOut(future);
}}));
}
for (Thread thread : threads)
awaitTermination(thread);
for (ExecutorService executor : executors)
joinPool(executor);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"V m19259a(long j) throws TimeoutException, CancellationException, ExecutionException, InterruptedException {\n if (tryAcquireSharedNanos(-1, j)) {\n return getValue();\n }\n throw new TimeoutException(\"Timeout waiting for task.\");\n }",
"Future_<V> submit(Callable_<V> task);",
"V get() throws PromiseBrokenException, InterruptedException;",
"@Override\n\tpublic V get(long timeout, TimeUnit unit) {\n\t\tV result = null;\n\t\ttry {\n\t\t\tresult = fTask.get(timeout, unit);\n\t\t} catch (InterruptedException | ExecutionException | TimeoutException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn result;\n\t}",
"Callable<E> getTask();",
"@Override\n public Object get() throws InterruptedException, ExecutionException {\n return getSafely();\n }",
"Future_<V> take() throws InterruptedException;",
"V get(long timeout, TimeUnit timeUnit) throws PromiseBrokenException, TimeoutException, InterruptedException;",
"private static void threadPoolWithSubmit() throws InterruptedException, ExecutionException {\n Executor executor = Executors.newFixedThreadPool(1);\n Callable<String> callable=()->{\n try{\n Thread.sleep(4000);\n System.out.println(\"In callable\");\n Thread.sleep(4000);\n System.out.println(\"In runnable for task id 1\");\n }catch(Exception e){\n e.printStackTrace();\n }\n return \"success\";\n };\n Future<String> future =((ExecutorService) executor).submit(callable);\n System.out.println(\"Future result - \"+future.get()+\" Future is blocking as it blocks until result is obtained\");\n System.out.println(\"End of method \");\n ((ExecutorService) executor).shutdown();\n /*Output\n In callable\n In runnable for task id 1\n Future result - success Future is blocking as it blocks until result is obtained\n End of method\n */\n }",
"@Override\n\tpublic V get() {\n\t\tV result = null;\n\t\ttry {\n\t\t\tresult = fTask.get();\n\t\t} catch (InterruptedException | ExecutionException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn result;\n\t}",
"public Future<?> stress() throws InterruptedException, ExecutionException {\n if (future != null) {\n future.get();\n }\n return executor.submit(new Callable<Object>() {\n public Object call() throws Exception {\n stressInternal();\n return null;\n }\n });\n }",
"T get() throws InterruptedException, LightExecutionException;",
"default T await() {\n return await(0, TimeUnit.NANOSECONDS);\n }",
"@Test\n public void testTakeWillWaitTillSubmitCompletes() {\n final BoundedCompletionService<String> ecs = new BoundedCompletionService<String>(\n new ExecutorCompletionService<String>(e));\n final int delaySecs = 1;\n try {\n Assert.assertNull(ecs.poll());\n Thread t = new Thread() {\n @Override\n public void run() {\n ecs.submit(new StringDelayableCallable(\"String delayab\", delaySecs));\n }\n };\n t.start();\n long t1 = System.nanoTime();\n Future<String> f = ecs.take();\n Assert.assertNotNull(f);\n Assert.assertTrue(f.isDone());\n long t2 = System.nanoTime();\n System.out.println(t2 - t1);\n Assert.assertTrue(t2 > t1 + delaySecs * 100000000L); // Need to check that take will wait till submit completes\n } catch (Exception ex) {\n unexpectedException();\n }\n }",
"public static void main(String[] args) throws InterruptedException {\n\r\n FutureService futureService = new FutureService();\r\n Future<String> future = futureService.submit(() -> {\r\n try {\r\n Thread.sleep(10_000);\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n return \"FINISH\";\r\n }, System.out::println);\r\n System.out.println(\"================\");\r\n System.out.println(\"do other thing.\");\r\n Thread.sleep(1_000L);\r\n System.out.println(\"================\");\r\n\r\n// System.out.println(future.get());\r\n }",
"@Test\n public void testTake() {\n \tBoundedCompletionService<String> ecs = new BoundedCompletionService<String>(\n new ExecutorCompletionService<String>(e));\n try {\n Callable<String> c = new StringTask();\n ecs.submit(c);\n Future<String> f = ecs.take();\n Assert.assertTrue(f.isDone());\n } catch (Exception ex) {\n unexpectedException();\n }\n }",
"<T> CompletableFuture<T> submit(Integer key, Callable<T> request);",
"@Test\n public void testFutureWithoutDone() throws Exception {\n Callable<String> task = new Callable<String>() {\n public String call() throws Exception {\n // do something that takes some time\n LOG.info(\"Starting to process task\");\n Thread.sleep(5000);\n LOG.info(\"Task is now done\");\n return \"Camel rocks\";\n }\n };\n\n // this is the thread pool we will use\n ExecutorService executor = Executors.newCachedThreadPool();\n\n // now submit the task to the thread pool\n // and get the Future handle back so we can later get the result\n LOG.info(\"Submitting task to ExecutorService\");\n Future<String> future = executor.submit(task);\n LOG.info(\"Task submitted and we got a Future handle\");\n\n // instead of testing when we are done we can just get\n // the result and it will automatic wait until the task is done\n String answer = future.get();\n LOG.info(\"The answer is: \" + answer);\n }",
"@Override\n public <V> HugeTask<V> waitUntilTaskCompleted(Id id)\n throws TimeoutException {\n long timeout = this.graph.configuration()\n .get(CoreOptions.TASK_WAIT_TIMEOUT);\n return this.waitUntilTaskCompleted(id, timeout, 1L);\n }",
"Task poll();",
"final Runnable pollLocalTask() {\n return locallyDeqTask();\n }",
"private DispatchTask next()\n {\n synchronized (m_lock)\n {\n while (null == m_runnable)\n {\n if (m_released)\n {\n return null;\n }\n\n try\n {\n m_lock.wait();\n } catch (InterruptedException e)\n {\n // Not needed\n }\n }\n\n return m_runnable;\n }\n }",
"CompletableFuture<?> submit(Runnable request);",
"void put( long number,Future<T> t);",
"DurationTracker timeSpentTaskWait();",
"public static void main(String[] args) throws Exception {\n FutureTask<String> futureTask = new FutureTask<String>(new Callable<String>() {\n @Override\n public String call() throws Exception {\n Thread.sleep(10000);\n System.out.println(\"thread done ...\");\n return \"hello world\";\n }\n });\n futureTask.run();\n// executorService.submit(futureTask);\n System.out.println(futureTask.get());\n// executorService.shutdown();\n }",
"public interface Future\n{\n\n public abstract boolean cancel(boolean flag);\n\n public abstract boolean isCancelled();\n\n public abstract boolean isDone();\n\n public abstract Object get()\n throws ExecutionException, InterruptedException;\n\n public abstract Object get(long l, TimeUnit timeunit)\n throws ExecutionException, InterruptedException, TimeoutException;\n}",
"java.util.concurrent.Future<GetJobRunResult> getJobRunAsync(GetJobRunRequest getJobRunRequest);",
"public static Task getCurrentTask(Fiber paramFiber)\n/* 194 */ throws Pausable { return null; }",
"V m19258a() throws CancellationException, ExecutionException, InterruptedException {\n acquireSharedInterruptibly(-1);\n return getValue();\n }",
"public Promise<V> await()\r\n/* 207: */ throws InterruptedException\r\n/* 208: */ {\r\n/* 209:242 */ if (isDone()) {\r\n/* 210:243 */ return this;\r\n/* 211: */ }\r\n/* 212:246 */ if (Thread.interrupted()) {\r\n/* 213:247 */ throw new InterruptedException(toString());\r\n/* 214: */ }\r\n/* 215:250 */ synchronized (this)\r\n/* 216: */ {\r\n/* 217:251 */ while (!isDone())\r\n/* 218: */ {\r\n/* 219:252 */ checkDeadLock();\r\n/* 220:253 */ incWaiters();\r\n/* 221: */ try\r\n/* 222: */ {\r\n/* 223:255 */ wait();\r\n/* 224: */ }\r\n/* 225: */ finally\r\n/* 226: */ {\r\n/* 227:257 */ decWaiters();\r\n/* 228: */ }\r\n/* 229: */ }\r\n/* 230: */ }\r\n/* 231:261 */ return this;\r\n/* 232: */ }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n ExecutorService executorService = Executors.newSingleThreadExecutor();\n\n System.out.println(\"submitted callable task to calculate factorial of 10\");\n Future<Long> result10 = executorService.submit(new FactorialCalculator(10));\n\n System.out.println(\"submitted callable task to calculate factorial of 15\");\n Future<Long> result15 = executorService.submit(new FactorialCalculator(15));\n\n System.out.println(\"submitted callable task to calculate factorial of 20\");\n Future<Long> result20 = executorService.submit(new FactorialCalculator(20));\n\n System.out.println(\"Calling get method of FutureUsage to fetch result of factorial 10\");\n long factorialOf10 = result10.get();\n System.out.println(\"factorial of 10 is : \" + factorialOf10);\n\n System.out.println(\"Calling get method of FutureUsage to get result of factorial 15\");\n long factorialOf15 = result15.get();\n System.out.println(\"factorial of 15 is : \" + factorialOf15);\n\n System.out.println(\"Calling get method of FutureUsage to get result of factorial 20\");\n long factorialOf20 = result20.get();\n System.out.println(\"factorial of 20 is : \" + factorialOf20);\n }",
"public void testThread() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n // result of the thread\n Future<String> future = null;\n\n future = executor.submit(new TestTask());\n try {\n String result = future.get(2000, TimeUnit.MILLISECONDS);\n System.out.println(result);\n } catch (InterruptedException e) {\n e.printStackTrace();\n } catch (ExecutionException e) {\n e.printStackTrace();\n } catch (TimeoutException e) {\n System.out.println(\"the execution was terminated after 5 s\");\n boolean cancelled = future.cancel(true);\n System.out.println(cancelled);\n\n\n }\n\n try {\n System.out.println(\"attempt to shutdown executor\");\n executor.shutdown();\n executor.awaitTermination(5, TimeUnit.SECONDS);\n }\n catch (InterruptedException e) {\n System.err.println(\"tasks interrupted\");\n }\n finally {\n if (!executor.isTerminated()) {\n System.err.println(\"cancel non-finished tasks\");\n }\n executor.shutdownNow();\n System.out.println(\"shutdown finished\");\n }\n\n }",
"private synchronized Task takeTask() {\n while (true) {\n Task task = null;\n if (runningActions < maxConcurrentActions) {\n task = runnableActions.poll();\n }\n if (task == null) {\n task = runnableTasks.poll();\n }\n\n if (task != null) {\n runningTasks++;\n if (task.isAction()) {\n runningActions++;\n }\n return task;\n }\n\n if (isExhausted()) {\n return null;\n }\n\n try {\n wait();\n } catch (InterruptedException e) {\n throw new AssertionError();\n }\n }\n }",
"public static void main(String[] args)\n {\n ExecutorService executorService = Executors.newCachedThreadPool();\n Future<Integer> future = executorService.submit(new Callable<Integer>() {\n public Integer call()\n {\n Random random = new Random();\n int duration = random.nextInt(500);\n System.out.println(\"Starting...\");\n try {\n Thread.sleep(duration);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"Finished\");\n return duration;\n }\n });\n executorService.shutdown();\n try {\n System.out.println(\"result is : \"+future.get());\n\n\n } catch (InterruptedException e) {\n e.printStackTrace();\n } catch (ExecutionException e) {\n e.printStackTrace();\n }\n System.out.println(\"future object done? :\"+future.isDone());\n System.out.println(\"future object cancelled? :\"+future.isCancelled());\n }",
"public static ExecutorService m22734g() {\n if (f20306g == null) {\n synchronized (C7258h.class) {\n if (f20306g == null) {\n f20306g = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.SERIAL).mo18996a(), true);\n }\n }\n }\n return f20306g;\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n CompletableFuture<String> future = CompletableFuture.supplyAsync(new Supplier<String>() {\n @Override\n public String get() {\n try {\n TimeUnit.SECONDS.sleep(1);\n } catch (InterruptedException e) {\n throw new IllegalStateException(e);\n }\n return \"Result of the asynchronous computation\";\n }\n });\n\n// Block and get the result of the Future\n String result = future.get();\n System.out.println(result);\n }",
"public int waitFor() throws Exception {\n \n int result = future.get();\n service.shutdown();\n return result;\n }",
"@Test\n public void testPoll1() {\n \tBoundedCompletionService<String> ecs = new BoundedCompletionService<String>(\n new ExecutorCompletionService<String>(e));\n try {\n Assert.assertNull(ecs.poll());\n Callable<String> c = new StringTask();\n ecs.submit(c);\n Thread.sleep(SHORT_DELAY_MS);\n for (;;) {\n Future<String> f = ecs.poll();\n if (f != null) {\n Assert.assertTrue(f.isDone());\n break;\n }\n }\n } catch (Exception ex) {\n unexpectedException();\n }\n }",
"@Test\n @DisplayName(\"Future with result\")\n void testFutureWithResult() throws ExecutionException, InterruptedException {\n final ExecutorService executor = Executors.newSingleThreadExecutor();\n final Future<String> future = executor.submit(this::getThreadName);\n\n // check if the future has already been finished. this isn't the case since the above callable sleeps for one second before returning the integer\n assertFalse(future.isDone());\n // calling the method get() blocks the current thread and waits until the callable completes before returning the actual result\n final String result = future.get();\n // now the future is finally done\n assertTrue(future.isDone());\n\n assertThat(result).matches(Pattern.compile(\"Thread \\\"pool-\\\\d-thread-\\\\d\\\"\"));\n }",
"<T> CompletableFuture<T> submit(Callable<T> request);",
"protected abstract long waitOnQueue();",
"public static <T> T callTask(Task<T> tsk,long timeout) throws StackingException\n {\n try {\n Future<Task> future = getInstance().doExecute(tsk);\n if(timeout == 0)\n future.get();\n else\n future.get(timeout,TimeUnit.MILLISECONDS);\n if(tsk.getException() != null) {\n throw new StackingException(tsk.getException());\n }\n return tsk.getReturn();\n }\n catch(InterruptedException ex) {\n throw new StackingException(ex);\n }\n catch(ExecutionException ex) {\n throw new StackingException(ex);\n }\n catch(TimeoutException ex) {\n throw new StackingException(ex);\n }\n }",
"DispatchTask getTask()\n {\n synchronized (m_lock)\n {\n return m_runnable;\n }\n }",
"CompletableFuture<CalculationResult> goInfiniteAsync();",
"@Test\n public void testFutureWithDone() throws Exception {\n Callable<String> task = new Callable<String>() {\n public String call() throws Exception {\n // do something that takes some time\n LOG.info(\"Starting to process task\");\n Thread.sleep(5000);\n LOG.info(\"Task is now done\");\n return \"Camel rocks\";\n }\n };\n\n // this is the thread pool we will use\n ExecutorService executor = Executors.newCachedThreadPool();\n\n // now submit the task to the thread pool\n // and get the Future handle back so we can later get the result\n LOG.info(\"Submitting task to ExecutorService\");\n Future<String> future = executor.submit(task);\n LOG.info(\"Task submitted and we got a Future handle\");\n\n // test when we are done\n boolean done = false;\n while (!done) {\n done = future.isDone();\n LOG.info(\"Is the task done? \" + done);\n if (!done) {\n Thread.sleep(2000);\n }\n }\n\n // and get the answer\n String answer = future.get();\n LOG.info(\"The answer is: \" + answer);\n }",
"public synchronized Object get() throws InterruptedException {\n while (pool.isEmpty()) {\n wait();\n }\n Object result = pool.remove(0);\n notifyAll();\n return result;\n }",
"public Future<?> putAsync(final String key, final String value) throws ExecutionException, InterruptedException {\n if (future != null) {\n future.get();\n }\n return executor.submit(new Callable<Object>() {\n public Object call() throws Exception {\n return remoteCache.put(key, value);\n }\n });\n }",
"private synchronized Task taskGet() {\n\t\treturn this.taskList.remove();\n\t}",
"public void await() {\n for (final Future<Void> future : futures) {\n try {\n future.get();\n } catch (final Throwable e) {\n LOGGER.error(\"Scheduled blob storage job threw an exception.\", e);\n }\n }\n futures.clear();\n }",
"public Future<Integer> getValue() {\n GetValue getValue = new GetValue(this.generator);\n return this.scheduled.schedule(getValue, this.delay, TimeUnit.MILLISECONDS);\n }",
"@Override\n protected Promise<? extends String> run(final Context context) throws Exception\n {\n context.run(innerTask);\n\n return Promises.value(\"value\");\n }",
"public void get(final Task task) {\n }",
"public Optional<Task> getATask() {\n HttpHeaders headers = new HttpHeaders();\n headers.setAccept(List.of(MediaType.APPLICATION_JSON));\n\n ResponseEntity<Task> responseEntity = restTemplate.exchange(\n queueUrl + \"/getATask\",\n HttpMethod.GET,\n new HttpEntity<>(headers),\n Task.class);\n\n return Optional.ofNullable(responseEntity.getBody());\n }",
"public void awaitTermination() throws InterruptedException, ExecutionException {\n executor.awaitTermination(1, TimeUnit.SECONDS);\n if (future != null) {\n future.get();\n }\n }",
"@Test\n public void testTaskNeedingOtherTasksToCheckIfDoneWithTimeout() throws InterruptedException, TaskException {\n final ScheduledPoolingTask<Integer> scheduledPoolingTask = this.createFakeScheduledPoolingTask(1, 1, 7, 8, 100);\n\n final Task<Integer> simpleTask = this.createFakeSimpleTask(2);\n\n final TaskDependingOnOtherTasksExample task = new TaskDependingOnOtherTasksExample.Builder()\n .willTake(2)\n .withTimeout(10)\n .withDependingTask(simpleTask)\n .withDependingTask(scheduledPoolingTask)\n .build();\n\n task.execute();\n\n assertTrue(\"The task should be finished ok\", task.isDone());\n\n assertTrue(\"The simple should be finished NO ok\", simpleTask.isDone());\n assertTrue(\"The scheduled should be finished ok\", !scheduledPoolingTask.isDone());\n\n assertTrue(\"The task should be finished ok\", task.getResult()==0);\n assertTrue(\"The simpleTask should be finished ok\", simpleTask.getResult()==0);\n assertTrue(\"The scheduledPoolingTask should be finished ok\", scheduledPoolingTask.getResult()==1);\n\n\n }",
"private Runnable pollSubmission() {\n StealingPool p = pool;\n while (p.hasQueuedSubmissions()) {\n Runnable t;\n if (tryActivate() && (t = p.pollSubmission()) != null)\n return t;\n }\n return null;\n }",
"@Override\n\tpublic synchronized void waitAllTasks() throws ExecutionException, InterruptedException {\n\t\twaitTasks(key -> true);\n\t}",
"public ChannelProgressivePromise awaitUninterruptibly()\r\n/* 113: */ {\r\n/* 114:144 */ super.awaitUninterruptibly();\r\n/* 115:145 */ return this;\r\n/* 116: */ }",
"@Test\n public void testPoll2() {\n \tBoundedCompletionService<String> ecs = new BoundedCompletionService<String>(\n new ExecutorCompletionService<String>(e));\n try {\n Assert.assertNull(ecs.poll());\n Callable<String> c = new StringTask();\n ecs.submit(c);\n Future<String> f = ecs.poll(SHORT_DELAY_MS, TimeUnit.MILLISECONDS);\n if (f != null) Assert.assertTrue(f.isDone());\n } catch (Exception ex) {\n unexpectedException();\n }\n }",
"@Override\n protected Promise<? extends String> run(final Context context) throws Exception\n {\n context.run(innerTask);\n\n return Promises.value(\"value\");\n }",
"public void run()\r\n/* 996: */ {\r\n/* 997:838 */ if (DefaultPromise.this.listeners == null) {\r\n/* 998: */ for (;;)\r\n/* 999: */ {\r\n/* :00:840 */ GenericFutureListener<?> l = (GenericFutureListener)poll();\r\n/* :01:841 */ if (l == null) {\r\n/* :02: */ break;\r\n/* :03: */ }\r\n/* :04:844 */ DefaultPromise.notifyListener0(DefaultPromise.this, l);\r\n/* :05: */ }\r\n/* :06: */ }\r\n/* :07:849 */ DefaultPromise.execute(DefaultPromise.this.executor(), this);\r\n/* :08: */ }",
"public <T> List<T> runPerPartyTasks(List<Callable<T>> tasks) {\n try {\n List<Future<T>> results = executor.invokeAll(tasks, 90L,\n TimeUnit.SECONDS);\n // this is a bit of a mess...\n @SuppressWarnings(\"unchecked\")\n List<T> unwrappedResults = results.stream().map(future -> {\n try {\n return future.get();\n } catch (CancellationException e) {\n System.err.println(\"Task cancelled due to time-out\");\n e.printStackTrace();\n } catch (InterruptedException e) {\n System.err.println(\"Task execution failed\");\n e.printStackTrace();\n } catch (ExecutionException e) {\n // This is very ugly, but we want to be able to receive the checked\n // exceptions thrown\n return (T) e.getCause();\n }\n return null;\n }).collect(Collectors.toList());\n return unwrappedResults;\n } catch (InterruptedException e) {\n System.err.println(\"Task execution failed\");\n e.printStackTrace();\n }\n return new ArrayList<>();\n }",
"@Override\n public <INPUT, OUTPUT> OUTPUT run(CONTEXT context, INPUT input) throws Exception {\n long start = System.currentTimeMillis();\n OUTPUT result = null;\n Boolean isInit = initDagStruct();\n long initDagCost = System.currentTimeMillis() - start;\n long startGetFuture = System.currentTimeMillis();\n if (BooleanUtils.isTrue(isInit)) {\n Map<String, Boolean> conditionResult = concurrentMapSupplier.get();\n Map<String, CompletableFuture> futureMap = Maps.newHashMap();\n FutureContext futureContext = new FutureContext();\n CompletableFuture<OUTPUT> future = getFuture(dag.getEndPointKey(), conditionResult, futureMap, input, context, futureContext);\n long getFutureCost = System.currentTimeMillis() - startGetFuture;\n if (Objects.nonNull(future)) {\n long waitTime = timeout;\n try {\n waitTime = DagUtil.getTimeout(start, timeout, removeWaitTime);\n result = future.get(waitTime, TimeUnit.MILLISECONDS);\n } catch (Exception e) {\n future.cancel(true);\n Logger.onlineWarn(parentInstanceKey\n + \",future dag expect timeout:\" + timeout\n + \",init dag cost:\" + initDagCost\n + \",get future cost:\" + getFutureCost\n + \",actual get wait:\" + waitTime\n + \",actual cost:\" + (System.currentTimeMillis() - start));\n }\n }\n }\n return Objects.isNull(result) ? (OUTPUT)input : result;\n }",
"public final T getResult() {\n try {\n try {\n ForkJoinPool.managedBlock(this);\n } catch (InterruptedException e) {\n }\n return self();\n }catch(Throwable t){\n throw new RuntimeException(t);\n }\n }",
"public static ExecutorService m22730c() {\n if (f20302c == null) {\n synchronized (C7258h.class) {\n if (f20302c == null) {\n f20302c = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.IO).mo18996a(), true);\n }\n }\n }\n return f20302c;\n }",
"public void run() throws InterruptedException, ExecutionException {\n\t\tExecutorService exec = Executors.newCachedThreadPool();\n\t\tfor (Entry<Integer, Set<Task>> entry : map.entrySet()) {\n\t\t\tList<Future<?>> futures = new ArrayList<Future<?>>();\n\t\t\t\n\t\t\t// submit each task in the set to the executor\n\t\t\tfor (Task task : entry.getValue()){\n\t\t\t\tfutures.add(exec.submit(task));\n\t\t\t}\n\t\t\t\n\t\t\t// iterate the futures to see if all the tasks in the set have finished execution\n\t\t\tfor (Iterator<Future<?>> iterator = futures.iterator(); iterator.hasNext();) {\n\t\t\t\tFuture<?> future = (Future<?>) iterator.next();\n\t\t\t\tif (future.get() == null);\n\t\t\t}\n\t\t}\n\t\texec.shutdown();\n\t}",
"public Serializable asyncPop() {//can move on to another task before it finishes.\n Serializable temp = null;\n boolean finished = false;\n while(!finished){\n if(taskQueue.isEmpty()){\n try {\n Thread.sleep(1000);//1 second\n } catch (InterruptedException ex) {\n Logger.getLogger(BasicMsgQ.class.getName()).log(Level.SEVERE, null, ex);\n }\n }else{\n temp = taskQueue.removeFirst();\n finished = true;\n } \n }\n return temp;\n }",
"@Test\n public void testTake2() {\n \tBoundedCompletionService<String> ecs = new BoundedCompletionService<String>(\n new ExecutorCompletionService<String>(e));\n try {\n Callable<String> c = new StringTask();\n Future<String> f1 = ecs.submit(c);\n Future<String> f2 = ecs.take();\n Assert.assertSame(f1, f2);\n } catch (Exception ex) {\n unexpectedException();\n }\n }",
"@Test\n public void testTakeWontWaitWithinSemaphoreSize() {\n final int factor = 4;\n final int semaphoreSize = 5;\n final int iterations = semaphoreSize * factor;\n final BoundedCompletionService<String> ecs = new BoundedCompletionService<String>(\n new ExecutorCompletionService<String>(e), semaphoreSize);\n final int delaySecs = 1;\n try {\n Assert.assertNull(ecs.poll());\n Thread t = new Thread() {\n @Override\n public void run() {\n for (int i = 0; i < iterations; i++)\n ecs.submit(new StringDelayableCallable(\"String delayab\", delaySecs));\n }\n };\n t.start();\n for (int i = 0; i < factor; i++)\n for (int j = 0; j < semaphoreSize; j++) {\n long t1 = System.nanoTime();\n Future<String> f = ecs.take();\n long t2 = System.nanoTime();\n Assert.assertNotNull(f);\n Assert.assertTrue(f.isDone());\n System.out.println(\"t2-t1(ms):\" + (t2 - t1) / 1000000L);\n if (j == 0)\n Assert.assertTrue((t2 - t1) / 1000000L > 0L); // it should be milliseconds at the boundary of semaphore size\n else {\n Assert.assertTrue((t2 - t1) / 100000000L == 0L);//it should not be decaseconds\n Assert.assertTrue((t2 - t1) / 1000L > 0L); //it should be in microseconds here\n }\n }\n } catch (Exception ex) {\n unexpectedException();\n }\n }",
"public static ExecutorService m22732e() {\n if (f20304e == null) {\n synchronized (C7258h.class) {\n if (f20304e == null) {\n f20304e = C7268n.m22763a().mo18997a(C7265m.m22758a(ThreadPoolType.BACKGROUND).mo18996a(), true);\n }\n }\n }\n return f20304e;\n }",
"public Serializable pop() throws InterruptedException {\n Serializable temp = null;\n if(taskQueue.isEmpty()){\n waitForThread();//blocks for taskQueue.\n }\n temp = taskQueue.removeFirst();\n threadLimit++;\n \n return temp;\n }",
"public abstract void task() throws InterruptedException;",
"@Nullable\n\tfinal T blockingGet() {\n\t\tif (Schedulers.isInNonBlockingThread()) {\n\t\t\tthrow new IllegalStateException(\"block()/blockFirst()/blockLast() are blocking, which is not supported in thread \" + Thread.currentThread().getName());\n\t\t}\n\t\tif (getCount() != 0) {\n\t\t\ttry {\n\t\t\t\tawait();\n\t\t\t}\n\t\t\tcatch (InterruptedException ex) {\n\t\t\t\tdispose();\n\t\t\t\tThread.currentThread().interrupt();\n\t\t\t\tthrow Exceptions.propagate(ex);\n\t\t\t}\n\t\t}\n\n\t\tThrowable e = error;\n\t\tif (e != null) {\n\t\t\tRuntimeException re = Exceptions.propagate(e);\n\t\t\t//this is ok, as re is always a new non-singleton instance\n\t\t\tre.addSuppressed(new Exception(\"#block terminated with an error\"));\n\t\t\tthrow re;\n\t\t}\n\t\treturn value;\n\t}",
"public T take() throws InterruptedException, IOException {\n lock.lock();\n try {\n T wrapper = this.dequeue();\n if (wrapper == null) {\n while ((wrapper = this.dequeue()) == null) {\n logger.debug(\"Waiting for take condition\");\n await();\n }\n }\n return wrapper;\n } finally {\n lock.unlock();\n }\n }",
"public E poll() {\n try {\n return b(2, (Long) null, (TimeUnit) null);\n } catch (InterruptedException unused) {\n return null;\n }\n }",
"public Promise<V> awaitUninterruptibly()\r\n/* 247: */ {\r\n/* 248:277 */ if (isDone()) {\r\n/* 249:278 */ return this;\r\n/* 250: */ }\r\n/* 251:281 */ boolean interrupted = false;\r\n/* 252:282 */ synchronized (this)\r\n/* 253: */ {\r\n/* 254:283 */ while (!isDone())\r\n/* 255: */ {\r\n/* 256:284 */ checkDeadLock();\r\n/* 257:285 */ incWaiters();\r\n/* 258: */ try\r\n/* 259: */ {\r\n/* 260:287 */ wait();\r\n/* 261: */ }\r\n/* 262: */ catch (InterruptedException e)\r\n/* 263: */ {\r\n/* 264:290 */ interrupted = true;\r\n/* 265: */ }\r\n/* 266: */ finally\r\n/* 267: */ {\r\n/* 268:292 */ decWaiters();\r\n/* 269: */ }\r\n/* 270: */ }\r\n/* 271: */ }\r\n/* 272:297 */ if (interrupted) {\r\n/* 273:298 */ Thread.currentThread().interrupt();\r\n/* 274: */ }\r\n/* 275:301 */ return this;\r\n/* 276: */ }",
"public long runScheduledPendingTasks() {\n/* */ try {\n/* 597 */ return this.loop.runScheduledTasks();\n/* 598 */ } catch (Exception e) {\n/* 599 */ recordException(e);\n/* 600 */ return this.loop.nextScheduledTask();\n/* */ } \n/* */ }",
"private Object getTask(Runnable runnable)\r\n {\r\n Object innerTask = \r\n ObservableExecutors.getInnerTask(runnable, Object.class);\r\n if (innerTask != null)\r\n {\r\n return innerTask;\r\n }\r\n return runnable;\r\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException{\n new Thread(future1).start();\n //Main thread can do own required thing first\n doOwnThing();\n //At the needed time, main thread can get the result\n System.out.println(future1.isDone());\n System.out.println(future1.isCancelled());\n System.out.println(future1.get());\n future1.cancel(false);\n System.out.println(future1.isDone());\n System.out.println(future1.isCancelled());\n \n \n new Thread(future2).start();\n doOwnThing();\n System.out.println(future2.get());\n }",
"Future timeoutIn(long timeout, TimeUnit timeUnit);",
"public Optional<PickingRequest> getTask() {\n return Optional.ofNullable(task);\n }",
"void await(long timeout, TimeUnit unit) throws InterruptedException;",
"public static void main(String[] args) throws Exception {\n ScheduledExecutorService exec = Executors.newScheduledThreadPool(3);// 3 threads\n\n System.out.println(\"TIME: \" + dateFormatter.format(new Date()));\n\n\n ScheduledFuture<?> sf1 = exec.schedule(new ScheduledTaskB(3000), 4,TimeUnit.SECONDS); // TASK-1\n ScheduledFuture<?> sf2 = exec.schedule(new CalculationTaskD(0,3,3000), 6, TimeUnit.SECONDS); // TASK-2\n\n exec.schedule(new ScheduledTaskB(0), 8, TimeUnit.SECONDS);\n ScheduledFuture<?> sf4 = exec.schedule(new CalculationTaskD(3,4,0), 10 , TimeUnit.SECONDS); // TASK-4\n\n exec.shutdown();\n sf1.cancel(true);\n sf2.cancel(true);\n\n // GET RESULTS ////////////////////////////////////////////////////////////\n\n System.out.println(\"\\n\\n\\nGetting results: \");\n\n /*\n .get() blocks until result is available\n */\n System.out.println(\"TASK-1: \" + sf1.get() + \"\\n\");\n System.out.println(\"TASK-2: \" + sf2.get() + \"\\n\");\n System.out.println(\"TASK-4: \" + sf4.get() + \"\\n\");\n\n\n\n\n\n }",
"public abstract T await();",
"@Override\n public void execute(final Task<T> task, final long wait, final TimeUnit unit) {\n }",
"@SuppressWarnings(\"unchecked\")\n\tpublic V get(long n, TimeUnit unit) {\n\t\tV result = null;\n\t\ttry {\n\t\t\tresult = (V) future.result(Duration.create(n, unit),\n\t\t\t\t\tDEFAULT_CAN_AWAIT);\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn result;\n\t}",
"public synchronized PartialSolution getWork() {\n\t\tif (tasks.size() == 0) { // workpool gol\n\t\t\tnWaiting++;\n\t\t\t/* condtitie de terminare:\n\t\t\t * nu mai exista nici un task in workpool si nici un worker nu e activ \n\t\t\t */\n\t\t\tif (nWaiting == nThreads) {\n\t\t\t\tready = true;\n\t\t\t\t/* problema s-a terminat, anunt toti ceilalti workeri */\n\t\t\t\tnotifyAll();\n\t\t\t\treturn null;\n\t\t\t} else {\n\t\t\t\twhile (!ready && tasks.size() == 0) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tthis.wait();\n\t\t\t\t\t} catch(Exception e) {e.printStackTrace();}\n\t\t\t\t}\n\n\t\t\t\tif (ready){\n\t\t\t\t\t/* s-a terminat prelucrarea */\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\tnWaiting--;\t\t\n\t\t\t}\n\t\t}\n\t\treturn tasks.remove();\n\n\t}",
"public ChannelProgressivePromise await()\r\n/* 106: */ throws InterruptedException\r\n/* 107: */ {\r\n/* 108:138 */ super.await();\r\n/* 109:139 */ return this;\r\n/* 110: */ }",
"public static Executor m13822l() {\n synchronized (f12483o) {\n if (f12471c == null) {\n f12471c = AsyncTask.THREAD_POOL_EXECUTOR;\n }\n }\n return f12471c;\n }",
"public Task get(int index){\n return tasks.get(index);\n }",
"Future<T> then(Runnable result);",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"@Test\n @DisplayName(\"Scheduled Future\")\n void testScheduledFuture() throws InterruptedException {\n ScheduledExecutorService executor = Executors.newScheduledThreadPool(1);\n ScheduledFuture<String> future = executor.schedule(this::getThreadName, 3, TimeUnit.SECONDS);\n\n TimeUnit.MILLISECONDS.sleep(1337);\n long remainingTime = future.getDelay(TimeUnit.MILLISECONDS);\n\n assertThat(remainingTime).isBetween(1650L, 1670L);\n }",
"public E take() throws InterruptedException {\n return b(0, (Long) null, (TimeUnit) null);\n }",
"public Task getTask() { return task; }",
"private CompletableFuture<Response> getExceptionalCF(Throwable t) {\n if ((t instanceof CompletionException) || (t instanceof ExecutionException)) {\n if (t.getCause() != null) {\n t = t.getCause();\n }\n }\n if (cancelled && t instanceof IOException) {\n t = new HttpTimeoutException(\"request timed out\");\n }\n return MinimalFuture.failedFuture(t);\n }",
"private List<Pair<SettableFuture<Object>, Collection<SolrInputDocument>>> getDocs() throws InterruptedException\n {\n List<Pair<SettableFuture<Object>, Collection<SolrInputDocument>>> tasks = new ArrayList<>(batchSize);\n int collectedDocs = 0;\n\n lock.lock();\n try\n {\n //Wait on the queue not being empty for up to 250 milliseconds\n long waitRemaining = TimeUnit.MILLISECONDS.toNanos(250);\n while (waitRemaining > 0 & taskQueue.isEmpty() & keepRunning)\n {\n waitRemaining = queueNotEmpty.awaitNanos(waitRemaining);\n }\n\n //Timed out polling so block on needing more runners\n //Rather then add another loop and indentation return an empty list\n //to restart the loop\n if (waitRemaining <= 0 & keepRunning)\n {\n runners--;\n needMoreRunner.await();\n runners++;\n return tasks;\n }\n\n //Pull stuff out of the queue until there are batchSize docs\n //Tracks # of docs collected as well as the weight impact on the queue\n while (collectedDocs < batchSize & !taskQueue.isEmpty())\n {\n Pair<SettableFuture<Object>, Collection<SolrInputDocument>> p = taskQueue.poll();\n int size = p.right.size();\n collectedDocs += size;\n queueWeight -= size;\n tasks.add(p);\n }\n\n //If we didn't drain the queue, then signal the next waiter on the queue\n if (!taskQueue.isEmpty())\n {\n queueNotEmpty.signal();\n }\n\n //If the queue is no longer full wake up anyone waiting to offer\n if (queueWeight < maxQueueWeight)\n {\n queueNotFull.signal();\n }\n }\n finally\n {\n lock.unlock();\n }\n return tasks;\n }",
"@Test\n public void iterateTests() throws Exception {\n final int nThreads = 100;\n ExecutorService executor = Executors.newFixedThreadPool(nThreads);\n final AtomicReference<Throwable> ex = new AtomicReference<>(null);\n final int nTasks = 10_000;\n final CountDownLatch latch = new CountDownLatch(nTasks);\n final ConcurrentHashMap<Integer, Future<?>> map = new ConcurrentHashMap<>();\n for (int i = 0; i < nTasks; i++) {\n final int j = i;\n map.put(j, executor.submit(new Runnable() {\n public void run() {\n try {\n testSubmitSilentWithParamMutation();\n testSubmitSilentWithParamMutationUncacheable();\n } catch (Throwable t) {\n ex.compareAndSet(null, t);\n } finally {\n latch.countDown();\n map.remove(j);\n }\n }}));\n }\n System.out.println(\"Waiting on latch\");\n while (!latch.await(30, TimeUnit.SECONDS)) {\n System.out.println(\"Waiting, \" + latch.getCount() + \" outstanding\");\n System.out.println(\"Waiting keys \" + map.keySet());\n }\n executor.shutdown();\n System.out.println(\"Waiting, on executor\");\n executor.awaitTermination(30, TimeUnit.SECONDS);\n executor.shutdownNow();\n if (ex.get() != null) {\n Assert.assertNull(ex.get());\n }\n }",
"public static <U> void main(String[] args) {\n\t\t\n\t\tExecutorService service = Executors.newFixedThreadPool(10);\n\t\t//String orderValue = \"\";\n\t\tFuture<String> order1 = service.submit(()->{return \"GetOrders111\";});\n\t\ttry {\n\t\t\tString orders = order1.get();\n\t\t\t//orderValue = orders;\n\t\t\tFuture<String> orderEnrich = service.submit(()->{return \"enrichingOrders : \"+orders;});\n\t\t\tFuture<String> orderReconciliation = service.submit(()->{return \"orderReconciliation : \"+orders;});\n\t\t\tFuture<String> orderAutoCreate = service.submit(()->{return \"orderAutoCreate : \"+orders;});\n\t\t} catch (InterruptedException | ExecutionException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t//In above code if too many heavy loaded tasks are there then its a big problem, for ex. get order is fetching millions of records and other services need to wait above code is going to fail.\n\t\t\n\t\tProcessOrder p = (String s)->{System.out.println(\"S \"+s); return 0;};\n\t\t//Solution\n\t\tCompletableFuture<String> cfuture = new CompletableFuture<>();\n\t\tfor(int i = 0; i < 10; i++) {\n\t\t\tcfuture.supplyAsync(()->{return \"GetOrders111\";})\n\t\t\t\t\t\t.thenApply((x)->{return \"enrichingOrders\";})\n\t\t\t\t\t\t.thenApply((x)->{return \"orderReconciliation\";})\n\t\t\t\t\t\t.thenAccept((x)->{System.out.println(\"orderAutoCreate\");});\n\t\t}\n\t\t\n\t}",
"@Override\n\tpublic synchronized <T> Future<T> runTask(final Object key, final Supplier<T> task, final Predicate<Object> predicate) {\n\n\t\tlog.info(\"Add task '{}' to task queue.\", key);\n\t\tCompletableFuture<Void> futuresToWait = CompletableFuture.allOf(tasks.stream()\n\t\t\t\t.filter(e -> areKeysMatched(e.key, predicate))\n\t\t\t\t.map(e -> e.value)\n\t\t\t\t.toArray(CompletableFuture[]::new));\n\n\t\tCompletableFuture<T> future = futuresToWait.thenApplyAsync(aVoid -> task.get(), executor)\n\t\t\t\t.exceptionally(t -> {\n\t\t\t\t\tlog.error(\"Error in task: \" + key, t);\n\t\t\t\t\tthrow new SyncRunnerException(\"Error in task with key: \" + key, t);\n\t\t\t\t}\n\t\t);\n\t\ttasks.add(new ImmutablePair<>(key, future));\n\t\treturn future;\n\t}"
] | [
"0.6242825",
"0.61916685",
"0.61274385",
"0.6084953",
"0.6037387",
"0.60134447",
"0.59675765",
"0.5924886",
"0.58773667",
"0.5813602",
"0.5808056",
"0.57163656",
"0.5675867",
"0.56449306",
"0.56325525",
"0.56103474",
"0.5582323",
"0.5533586",
"0.5501042",
"0.5496935",
"0.54948825",
"0.54879373",
"0.5456681",
"0.542984",
"0.5427531",
"0.5422168",
"0.5392136",
"0.53883797",
"0.53748333",
"0.53608966",
"0.53538024",
"0.5345825",
"0.5344919",
"0.53383005",
"0.532939",
"0.52887124",
"0.52678394",
"0.5263943",
"0.52496547",
"0.52480686",
"0.5244367",
"0.5235094",
"0.52343273",
"0.5220097",
"0.5214584",
"0.5203754",
"0.52015233",
"0.5192717",
"0.5189719",
"0.51556903",
"0.514902",
"0.5143419",
"0.5137383",
"0.5133311",
"0.5126313",
"0.5125051",
"0.5124821",
"0.5123416",
"0.51064175",
"0.5105341",
"0.5101105",
"0.51008",
"0.5096662",
"0.50935805",
"0.5092852",
"0.50874853",
"0.5086155",
"0.5081139",
"0.5067692",
"0.50398904",
"0.50363064",
"0.50313234",
"0.50279546",
"0.5022317",
"0.50132155",
"0.500511",
"0.50023216",
"0.49989253",
"0.4994068",
"0.49878898",
"0.49878675",
"0.4987712",
"0.49861106",
"0.49790058",
"0.49716938",
"0.49710077",
"0.496724",
"0.49664554",
"0.49663377",
"0.49655613",
"0.4948664",
"0.49485213",
"0.49443486",
"0.49317113",
"0.49276647",
"0.49091345",
"0.49055263",
"0.4898054",
"0.48930526",
"0.48926434",
"0.48893273"
] | 0.0 | -1 |
ThreadPoolExecutor using defaultThreadFactory has specified group, priority, daemon status, and name | public void testDefaultThreadFactory() throws Exception {
final ThreadGroup egroup = Thread.currentThread().getThreadGroup();
final CountDownLatch done = new CountDownLatch(1);
Runnable r = new CheckedRunnable() {
public void realRun() {
try {
Thread current = Thread.currentThread();
assertTrue(!current.isDaemon());
assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);
ThreadGroup g = current.getThreadGroup();
SecurityManager s = System.getSecurityManager();
if (s != null)
assertTrue(g == s.getThreadGroup());
else
assertTrue(g == egroup);
String name = current.getName();
assertTrue(name.endsWith("thread-1"));
} catch (SecurityException ok) {
// Also pass if not allowed to change setting
}
done.countDown();
}};
ExecutorService e = Executors.newSingleThreadExecutor(Executors.defaultThreadFactory());
try (PoolCleaner cleaner = cleaner(e)) {
e.execute(r);
await(done);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public ThreadPool getDefaultThreadPool();",
"@Override\n protected ExecutorService createDefaultExecutorService() {\n return null;\n }",
"public NamedThreadFactory(String name)\n {\n this(name, null);\n }",
"public ExecutorService createExecutor() {\n return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName,\n 1, 5);\n }",
"ActorThreadPool getThreadPool();",
"@Override\n public ExecutorService newThreadPool(ThreadPoolProfile profile, ThreadFactory threadFactory) {\n if (profile.isDefaultProfile()) {\n return vertxExecutorService;\n } else {\n return super.newThreadPool(profile, threadFactory);\n }\n }",
"@Bean\n @ConditionalOnMissingBean(Executor.class)\n @ConditionalOnProperty(name = \"async\", prefix = \"slack\", havingValue = \"true\")\n public Executor threadPool() {\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(5);\n executor.setMaxPoolSize(30);\n executor.setQueueCapacity(20);\n executor.setThreadNamePrefix(\"slack-thread\");\n return executor;\n }",
"@Test\n void test3() {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(1,1,10L, TimeUnit.SECONDS,new LinkedBlockingDeque<>(2),new ThreadPoolExecutor.DiscardPolicy());\n for (int i = 0; i < 10; i++) {\n executor.execute(new Runnable() {\n @Override\n public void run() {\n System.out.println(Thread.currentThread().getName()+\"输出\");\n }\n });\n }\n }",
"public void testPrivilegedThreadFactory() throws Exception {\n final CountDownLatch done = new CountDownLatch(1);\n Runnable r = new CheckedRunnable() {\n public void realRun() throws Exception {\n final ThreadGroup egroup = Thread.currentThread().getThreadGroup();\n final ClassLoader thisccl = Thread.currentThread().getContextClassLoader();\n // android-note: Removed unsupported access controller check.\n // final AccessControlContext thisacc = AccessController.getContext();\n Runnable r = new CheckedRunnable() {\n public void realRun() {\n Thread current = Thread.currentThread();\n assertTrue(!current.isDaemon());\n assertTrue(current.getPriority() <= Thread.NORM_PRIORITY);\n ThreadGroup g = current.getThreadGroup();\n SecurityManager s = System.getSecurityManager();\n if (s != null)\n assertTrue(g == s.getThreadGroup());\n else\n assertTrue(g == egroup);\n String name = current.getName();\n assertTrue(name.endsWith(\"thread-1\"));\n assertSame(thisccl, current.getContextClassLoader());\n //assertEquals(thisacc, AccessController.getContext());\n done.countDown();\n }};\n ExecutorService e = Executors.newSingleThreadExecutor(Executors.privilegedThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(r);\n await(done);\n }\n }};\n\n runWithPermissions(r,\n new RuntimePermission(\"getClassLoader\"),\n new RuntimePermission(\"setContextClassLoader\"),\n new RuntimePermission(\"modifyThread\"));\n }",
"ScheduledExecutorService getExecutorService();",
"public UseCaseThreadPoolScheduler() {\n\t\tthis.threadPoolExecutor = new ThreadPoolExecutor(POOL_SIZE, MAX_POOL_SIZE, TIMEOUT,\n\t\t\t\tTimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(POOL_SIZE));\n\t}",
"protected synchronized ExecutorService getService() {\r\n if(service == null) {\r\n //System.out.println(\"creating an executor service with a threadpool of size \" + threadPoolSize);\r\n service = Executors.newFixedThreadPool(threadPoolSize, new ThreadFactory() {\r\n private int count = 0;\r\n \r\n public Thread newThread(Runnable r) {\r\n Thread t = new Thread(r, \"tile-pool-\" + count++);\r\n t.setPriority(Thread.MIN_PRIORITY);\r\n t.setDaemon(true);\r\n return t;\r\n }\r\n });\r\n }\r\n return service;\r\n }",
"@Override\n\tpublic ThreadPoolExecutor getThreadPool(final HystrixThreadPoolKey threadPoolKey,\n\t\t\tfinal HystrixProperty<Integer> corePoolSize, final HystrixProperty<Integer> maximumPoolSize,\n\t\t\tfinal HystrixProperty<Integer> keepAliveTime, final TimeUnit unit,\n\t\t\tfinal BlockingQueue<Runnable> workQueue) {\n\n\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - default [threadPoolKey=\" + threadPoolKey.name() + \", corePoolSize=\"\n\t\t\t\t+ corePoolSize.get() + \", maximumPoolSize=\" + maximumPoolSize.get() + \", keepAliveTime=\"\n\t\t\t\t+ keepAliveTime.get() + \", unit=\" + unit.name() + \"], override with [threadPoolKey=\"\n\t\t\t\t+ threadPoolKey.name() + \", corePoolSize=\" + CORE_POOL_SIZE + \", maximumPoolSize=\" + MAX_POOL_SIZE\n\t\t\t\t+ \", keepAliveTime=\" + KEEP_ALIVE_TIME + \", unit=\" + TimeUnit.SECONDS.name() + \"]\");\n\n\t\tif (threadFactory != null) {\n\t\t\t// All threads will run as part of this application component.\n\t\t\tfinal ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(CORE_POOL_SIZE, MAX_POOL_SIZE,\n\t\t\t\t\tKEEP_ALIVE_TIME, TimeUnit.SECONDS, new ArrayBlockingQueue<Runnable>(BLOCKING_QUEUE_SIZE),\n\t\t\t\t\tthis.threadFactory);\n\n\t\t\tLOGGER.debug(LOG_PREFIX + \"getThreadPool - initialized threadpool executor [threadPoolKey=\"\n\t\t\t\t\t+ threadPoolKey.name() + \"]\");\n\n\t\t\treturn threadPoolExecutor;\n\t\t} else {\n\t\t\tLOGGER.warn(LOG_PREFIX + \"getThreadPool - fallback to Hystrix default thread pool executor.\");\n\n\t\t\treturn super.getThreadPool(threadPoolKey, corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue);\n\t\t}\n\t}",
"@Test\n @DisplayName(\"SingleThread Executor + shutdown\")\n void firstExecutorService() {\n ExecutorService executor = Executors.newSingleThreadExecutor();\n executor.submit(this::printThreadName);\n\n shutdownExecutor(executor);\n assertThrows(RejectedExecutionException.class, () -> executor.submit(this::printThreadName));\n }",
"private GDMThreadFactory(){}",
"@Singleton\n\t@Provides\n\tExecutorService provideExecutorService() {\n\t\tThreadFactory threadFactory = new ThreadFactory() {\n\t\t\tprivate final AtomicInteger threadNumber = new AtomicInteger(1);\n\n\t\t\t@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\t// Two-digit counter, used in load test.\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}\n\t\t};\n\t\treturn threadCount >= 0\n\t\t\t\t? Executors.newFixedThreadPool(threadCount, threadFactory)\n\t\t\t\t: Executors.newCachedThreadPool(threadFactory);\n\t}",
"@Bean(destroyMethod = \"shutdown\")\n public Executor threadPoolTaskExecutor(@Value(\"${thread.size}\") String argThreadSize) {\n this.threadSize = Integer.parseInt(argThreadSize);\n ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();\n executor.setCorePoolSize(this.threadSize);\n executor.setKeepAliveSeconds(15);\n executor.initialize();\n return executor;\n }",
"@Override\n public int getProcessorType() {\n return OperationExecutors.HIGH_PRIORITY_EXECUTOR;\n }",
"public ThreadPool getThreadPool(int numericIdForThreadpool) throws NoSuchThreadPoolException;",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"private ExecutorService getDroneThreads() {\n\t\treturn droneThreads;\n\t}",
"public void testNewSingleThreadExecutor2() {\n final ExecutorService e = Executors.newSingleThreadExecutor(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private void initExecService() {\n try {\n executorService = Executors.newFixedThreadPool(NO_OF_THREADS);\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n }",
"public LocalEventLoopGroup(int nThreads, ThreadFactory threadFactory) {\n/* 51 */ super(nThreads, threadFactory, new Object[0]);\n/* */ }",
"public static Executor buildExecutor() {\n GrpcRegisterConfig config = Singleton.INST.get(GrpcRegisterConfig.class);\n if (null == config) {\n return null;\n }\n final String threadpool = Optional.ofNullable(config.getThreadpool()).orElse(Constants.CACHED);\n switch (threadpool) {\n case Constants.SHARED:\n try {\n return SpringBeanUtils.getInstance().getBean(ShenyuThreadPoolExecutor.class);\n } catch (NoSuchBeanDefinitionException t) {\n throw new ShenyuException(\"shared thread pool is not enable, config ${shenyu.sharedPool.enable} in your xml/yml !\", t);\n }\n case Constants.FIXED:\n case Constants.EAGER:\n case Constants.LIMITED:\n throw new UnsupportedOperationException();\n case Constants.CACHED:\n default:\n return null;\n }\n }",
"@Test\r\n\tpublic void test()\r\n\t{\n\t\t\r\n\t\tThreadPoolManager.addPool(\"1,UD,12,12,30000,200000\");\r\n//\t\tThreadPoolManager.addPool(\"2,UD,12,12,30000,200000\");\r\n\r\n// ThreadPoolManager.init(params);\r\n// ThreadPoolManager.getPool(\"1\");\r\n\t\t\r\n//\t\tThread t = new Thread(this.testCreaterun());\r\n//\t\tBaseTask\r\n\t\tBaseTask b = this.testCreaterun();\r\n\t\tThreadPoolManager.submit(\"1\", b);\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\tThreadPoolManager.shutdownNow(\"1\");\r\n\t\t\r\n\t\tSystemUtil.sleep(2000);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tSystemUtil.sleepForever();\r\n\t}",
"public abstract ScheduledExecutorService getWorkExecutor();",
"public interface ThreadExecutor extends Executor {\n}",
"int getExecutorCorePoolSize();",
"public void testNewFixedThreadPool2() {\n final ExecutorService e = Executors.newFixedThreadPool(2, new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public ThreadPoolExecutor create_blocking_thread_pool( String name, int threads, int queue_size )\n {\n NamedThreadPoolExecutor ret = new NamedThreadPoolExecutor( name, queue_size, threads, threads, 60, TimeUnit.MINUTES);\n \n pool_list.add( ret );\n\n return ret;\n }",
"@Bean(name = \"process-response\")\n\tpublic Executor threadPoolTaskExecutor() {\n\t\tThreadPoolTaskExecutor x = new ThreadPoolTaskExecutor();\n\t\tx.setCorePoolSize(poolProcessResponseCorePoolSize);\n\t\tx.setMaxPoolSize(poolProcessResponseMaxPoolSize);\n\t\treturn x;\n\t}",
"@Override\n public ScheduledExecutorService getSchedExecService() {\n return channelExecutor;\n }",
"public void testNewFixedThreadPool1() {\n final ExecutorService e = Executors.newFixedThreadPool(2);\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public ThreadPool()\r\n {\r\n // 20 seconds of inactivity and a worker gives up\r\n suicideTime = 20000;\r\n // half a second for the oldest job in the queue before\r\n // spawning a worker to handle it\r\n spawnTime = 500;\r\n jobs = null;\r\n activeThreads = 0;\r\n askedToStop = false;\r\n }",
"public ThreadPool getThreadPool(String threadpoolId) throws NoSuchThreadPoolException;",
"public void testNewSingleThreadExecutor1() {\n final ExecutorService e = Executors.newSingleThreadExecutor();\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"protected EventExecutor newChild(ThreadFactory threadFactory, Object... args) throws Exception {\n/* 57 */ return (EventExecutor)new LocalEventLoop(this, threadFactory);\n/* */ }",
"@ProviderType\npublic interface ThreadPoolMBean {\n\n /**\n * Retrieve the block policy of the thread pool.\n * \n * @return the block policy\n */\n String getBlockPolicy();\n\n /**\n * Retrieve the active count from the pool's Executor.\n * \n * @return the active count or -1 if the thread pool does not have an Executor\n */\n int getExecutorActiveCount();\n\n /**\n * Retrieve the completed task count from the pool's Executor.\n * \n * @return the completed task count or -1 if the thread pool does not have an Executor\n */\n long getExecutorCompletedTaskCount();\n\n /**\n * Retrieve the core pool size from the pool's Executor.\n * \n * @return the core pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorCorePoolSize();\n\n /**\n * Retrieve the largest pool size from the pool's Executor.\n * \n * @return the largest pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorLargestPoolSize();\n\n /**\n * Retrieve the maximum pool size from the pool's Executor.\n * \n * @return the maximum pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorMaximumPoolSize();\n\n\n /**\n * Retrieve the pool size from the pool's Executor.\n * \n * @return the pool size or -1 if the thread pool does not have an Executor\n */\n int getExecutorPoolSize();\n\n\n /**\n * Retrieve the task count from the pool's Executor. This is the total number of tasks, which\n * have ever been scheduled to this threadpool. They might have been processed yet or not.\n * \n * @return the task count or -1 if the thread pool does not have an Executor\n */\n long getExecutorTaskCount();\n \n \n /**\n * Retrieve the number of tasks in the work queue of the pool's Executor. These are the\n * tasks which have been already submitted to the threadpool, but which are not yet executed.\n * @return the number of tasks in the work queue -1 if the thread pool does not have an Executor\n */\n long getExcutorTasksInWorkQueueCount();\n\n /**\n * Return the configured max thread age.\n *\n * @return The configured max thread age.\n * @deprecated Since version 1.1.1 always returns -1 as threads are no longer retired\n * but instead the thread locals are cleaned up (<a href=\"https://issues.apache.org/jira/browse/SLING-6261\">SLING-6261</a>)\n */\n @Deprecated\n long getMaxThreadAge();\n\n /**\n * Return the configured keep alive time.\n * \n * @return The configured keep alive time.\n */\n long getKeepAliveTime();\n\n /**\n * Return the configured maximum pool size.\n * \n * @return The configured maximum pool size.\n */\n int getMaxPoolSize();\n\n /**\n * Return the minimum pool size.\n * \n * @return The minimum pool size.\n */\n int getMinPoolSize();\n\n /**\n * Return the name of the thread pool\n * \n * @return the name\n */\n String getName();\n\n /**\n * Return the configuration pid of the thread pool.\n * \n * @return the pid\n */\n String getPid();\n\n /**\n * Return the configured priority of the thread pool.\n * \n * @return the priority\n */\n String getPriority();\n\n /**\n * Return the configured queue size.\n * \n * @return The configured queue size.\n */\n int getQueueSize();\n\n /**\n * Return the configured shutdown wait time in milliseconds.\n * \n * @return The configured shutdown wait time.\n */\n int getShutdownWaitTimeMs();\n\n /**\n * Return whether or not the thread pool creates daemon threads.\n * \n * @return The daemon configuration.\n */\n boolean isDaemon();\n\n /**\n * Return whether or not the thread pool is configured to shutdown gracefully.\n * \n * @return The graceful shutdown configuration.\n */\n boolean isShutdownGraceful();\n\n /**\n * Return whether or not the thread pool is in use.\n * \n * @return The used state of the pool.\n */\n boolean isUsed();\n\n}",
"public void testUnconfigurableExecutorService() {\n final ExecutorService e = Executors.unconfigurableExecutorService(Executors.newFixedThreadPool(2));\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"private static synchronized Executor getDefaultExecutor() {\n return sDefaultExecutor == null ? sDefaultExecutor = new Executor(1)\n : sDefaultExecutor;\n }",
"public static ResettableExceptionHandlingExecutorService newSingleThreadExecutor(String prefix, boolean daemon)\n {\n return newSingleThreadExecutor(prefix, daemon, -1);\n }",
"public interface ThreadPool {\n /**\n * Returns the number of threads in the thread pool.\n */\n int getPoolSize();\n /**\n * Returns the maximum size of the thread pool.\n */\n int getMaximumPoolSize();\n /**\n * Returns the keep-alive time until the thread suicides after it became\n * idle (milliseconds unit).\n */\n int getKeepAliveTime();\n\n void setMaximumPoolSize(int maximumPoolSize);\n void setKeepAliveTime(int keepAliveTime);\n\n /**\n * Starts thread pool threads and starts forwarding events to them.\n */\n void start();\n /**\n * Stops all thread pool threads.\n */\n void stop();\n \n\n}",
"ScheduledExecutorService getScheduledExecutorService();",
"protected ThreadPool getPool()\r\n {\r\n return threadPool_;\r\n }",
"public static ThreadPoolTaskScheduler createThreadPoolTaskScheduler(\r\n\t\t\tExecutorService executorService, \r\n\t\t\tFrequency frequency, String name, TimeZone timezone){\r\n\t\treturn new ThreadPoolTaskScheduler(executorService, frequency, name, timezone);\r\n\t}",
"public static void main(String[] args) {\n ThreadPoolExecutor executorService = new ThreadPoolExecutor(3, 10, 1L, TimeUnit.SECONDS,\n new LinkedBlockingQueue<>(20),\n Executors.defaultThreadFactory(),\n new ThreadPoolExecutor.AbortPolicy());\n ABC abc = new ABC();\n try {\n for (int i = 1; i <= 10; i++) {\n executorService.execute(abc::print5);\n executorService.execute(abc::print10);\n executorService.execute(abc::print15);\n }\n\n }finally {\n executorService.shutdown();\n }\n }",
"int getExecutorPoolSize();",
"public SingleWorkerPoolExecutor() {\n this.worker = new Worker(taskQueue);\n\n // Nothing bad as worker is blocked by an emptiness of a task\n // queue. Adding to this task queue will be possible after worker pool\n // finishes construction\n worker.start();\n }",
"public static ExecutorService daemonTwoThreadService(){\n return Executors.newFixedThreadPool(2,new ThreadFactory(){\n\n @Override\n public Thread newThread(Runnable r) {\n Thread t= Executors.defaultThreadFactory().newThread(r);\n t.setDaemon(true);\n return t;\n }\n });\n }",
"public ThreadPoolExecutor getForLightWeightBackgroundTasks() {\n return mForLightWeightBackgroundTasks;\n }",
"public static void main(String[] args) {\n\n var pool = Executors.newFixedThreadPool(5);\n Future outcome = pool.submit(() -> 1);\n\n }",
"public static ListenableThreadPoolExecutor newOptimalSizedExecutorService(String name, int priority) {\r\n\t\tint processors = Runtime.getRuntime().availableProcessors();\r\n\t\tint threads = processors > 1 ? processors - 1 : 1;\r\n\t\treturn new ListenableThreadPoolExecutor(name, threads, priority);\r\n\t}",
"public static void main(String[] args) {\n ExecutorService executor = Executors.newFixedThreadPool(5);\n\n for (int i = 0; i < 10; i++) {\n Runnable worker = new WorkerThreadSand(\" \" + i);\n executor.execute(worker);\n }\n executor.shutdown();\n\n// nasty path for executor\n try {\n ExecutorService nastyExecutor = Executors.newSingleThreadExecutor();\n nastyExecutor.execute(null);\n }catch (Exception e){\n System.out.println(\"Nulls don't work\");\n }\n\n\n System.out.println(\"Finished all threads\");\n\n }",
"public void testCreateThreadPool_0args()\n {\n System.out.println( \"createThreadPool\" );\n ThreadPoolExecutor result = ParallelUtil.createThreadPool();\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool(\n ParallelUtil.OPTIMAL_THREADS );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n }",
"public static ExecutorService getMainExecutorService() {\n return executorService;\n }",
"public static void main(String args[])\n {\n\t ScheduledExecutorService executorService= Executors.newScheduledThreadPool(2);\n\t Runnable task1=new RunnableChild(\"task1\");\n\t Runnable task2=new RunnableChild(\"task2\");\n\t Runnable task3=new RunnableChild(\"task3\");\n\t executorService.submit(task1);\n\t executorService.submit(task2);\n\t executorService.submit(task3);\n\t executorService.schedule(task1,20, TimeUnit.SECONDS);\n\t System.out.println(\"*******shutting down called\");\n\t executorService.shutdown();\n }",
"public Builder setThreadFactory(ThreadFactory threadFactory) {\n threadFactory_ = (threadFactory != null) ? threadFactory : Executors.defaultThreadFactory();\n return this;\n }",
"@Test\n public void launchesEventhandlerThreadpoolPriorityTest() {\n // TODO: test launchesEventhandlerThreadpoolPriority\n }",
"public static void main(String[] args) {\n\t\tBlockingQueue queue = new LinkedBlockingQueue(4);\n\n\t\t// Thread factory below is used to create new threads\n\t\tThreadFactory thFactory = Executors.defaultThreadFactory();\n\n\t\t// Rejection handler in case the task get rejected\n\t\tRejectTaskHandler rth = new RejectTaskHandler();\n\t\t// ThreadPoolExecutor constructor to create its instance\n\t\t// public ThreadPoolExecutor(int corePoolSize,int maximumPoolSize,long\n\t\t// keepAliveTime,\n\t\t// TimeUnit unit,BlockingQueue workQueue ,ThreadFactory\n\t\t// threadFactory,RejectedExecutionHandler handler) ;\n\t\tThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(1, 2, 10L, TimeUnit.MILLISECONDS, queue,\n\t\t\t\tthFactory, rth);\n\n\t\tfor (int i = 1; i <= 10; i++) {\n\t\t\tDataFileReader df = new DataFileReader(\"File \" + i);\n\t\t\tSystem.out.println(\"A new file has been added to read : \" + df.getFileName());\n\t\t\t// Submitting task to executor\n\t\t\tthreadPoolExecutor.execute(df);\n\t\t}\n\t\tthreadPoolExecutor.shutdown();\n\t}",
"@Override\n protected Thread createThread(final Runnable runnable, final String name) {\n return new Thread(runnable, Thread.currentThread().getName() + \"-exec\");\n }",
"int getExecutorLargestPoolSize();",
"public static void main(String[] args) {\n\t\tExecutorService pool = Executors.newFixedThreadPool(3);\n\t\t//ExecutorService pool = Executors.newSingleThreadExecutor();\n\t\t\n\t\tExecutorService pool2 = Executors.newCachedThreadPool();\n\t\t//this pool2 will add more thread into pool(when no other thread running), the new thread do not need to wait.\n\t\t//pool2 will delete un runing thread(unrun for 60 secs)\n\t\tThread t1 = new MyThread();\n\t\tThread t2 = new MyThread();\n\t\tThread t3 = new MyThread();\n\n\t\tpool.execute(t1);\n\t\tpool.execute(t2);\n\t\tpool.execute(t3);\n\t\tpool.shutdown();\n\t\t\n\t}",
"public LocalEventLoopGroup(int nThreads) {\n/* 41 */ this(nThreads, null);\n/* */ }",
"public void testCreateThreadPool_int()\n {\n System.out.println( \"createThreadPool\" );\n int numRequestedThreads = 0;\n ThreadPoolExecutor result = ParallelUtil.createThreadPool( ParallelUtil.OPTIMAL_THREADS );\n ThreadPoolExecutor expected = ParallelUtil.createThreadPool( -1 );\n assertEquals( expected.getMaximumPoolSize(), result.getMaximumPoolSize() );\n \n result = ParallelUtil.createThreadPool( -1 );\n assertTrue( result.getMaximumPoolSize() > 0 );\n \n numRequestedThreads = 10;\n result = ParallelUtil.createThreadPool( numRequestedThreads );\n assertEquals( numRequestedThreads, result.getMaximumPoolSize() );\n }",
"public static void main(String [] args) {\n\t\tExecutorService executor= Executors.newFixedThreadPool(2);\n\t\t\n\t\t//add the tasks that the threadpook executor should run\n\t\tfor(int i=0;i<5;i++) {\n\t\t\texecutor.submit(new Processor(i));\n\t\t}\n\t\t\n\t\t//shutdown after all have started\n\t\texecutor.shutdown();\n\t\t\n\t\tSystem.out.println(\"all submitted\");\n\t\t\n\t\t//wait 1 day till al the threads are finished \n\t\ttry {\n\t\t\texecutor.awaitTermination(1, TimeUnit.DAYS);\n\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"all completed\");\n\t\t\n\t}",
"public void testNewCachedThreadPool2() {\n final ExecutorService e = Executors.newCachedThreadPool(new SimpleThreadFactory());\n try (PoolCleaner cleaner = cleaner(e)) {\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n e.execute(new NoOpRunnable());\n }\n }",
"public void testNewFixedThreadPool4() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(0);\n shouldThrow();\n } catch (IllegalArgumentException success) {}\n }",
"public WorkerPool(String name) {\n this.name = name;\n\n log = LogFactory.getLog(WorkerPool.class.getName() + \":\" + name);\n }",
"public static ThreadPoolTaskScheduler createThreadPoolTaskScheduler(\r\n\t\t\tint poolSize, \r\n\t\t\tFrequency frequency, String name){\r\n\t\treturn new ThreadPoolTaskScheduler(poolSize, frequency, name, null);\r\n\t}",
"public void testNewFixedThreadPool3() {\n try {\n ExecutorService e = Executors.newFixedThreadPool(2, null);\n shouldThrow();\n } catch (NullPointerException success) {}\n }",
"public TaskThread(ThreadPool threadPool) {\n super(threadPool.getThreadGroup(), \"Task: Idle\");\n this.threadPool = threadPool;\n threadId = ThreadPool.getUniqueThreadId();\n System.out.println(\"threadId Created:\" + threadId);\n }",
"public static ThreadPoolTaskScheduler createThreadPoolTaskScheduler(\r\n\t\t\tint poolSize, \r\n\t\t\tFrequency frequency, String name, TimeZone timezone){\r\n\t\treturn new ThreadPoolTaskScheduler(poolSize, frequency, name, timezone);\r\n\t}",
"Executor getWorkerpool() {\n\t return pool.getWorkerpool();\n\t}",
"TaskFactory getTaskFactory();",
"public static void main(String[] args) {\n ExecutorService es = Executors.newCachedThreadPool();\n es.execute(new Task(65));\n es.execute(new Task(5));\n System.out.println(\"结束执行!\");\n }",
"public TaskThread(ThreadPool threadPool, String tName) {\n super(threadPool.getThreadGroup(), \"Task: Idle\");\n this.threadPool = threadPool;\n this.threadName = tName;\n threadId = ThreadPool.getUniqueThreadId();\n\n System.out.println(\"threadId Created:\" + threadId);\n }",
"public static void main(String[] args)\n\t{\n\t\tint coreCount = Runtime.getRuntime().availableProcessors();\n\t\t//Create the pool\n\t\tExecutorService ec = Executors.newCachedThreadPool(); //Executors.newFixedThreadPool(coreCount);\n\t\tfor(int i=0;i<100;i++) \n\t\t{\n\t\t\t//Thread t = new Thread(new Task());\n\t\t\t//t.start();\n\t\t\tec.execute(new Task());\n\t\t\tSystem.out.println(\"Thread Name under main method:-->\"+Thread.currentThread().getName());\n\t\t}\n\t\t\n\t\t//for scheduling tasks\n\t\tScheduledExecutorService service = Executors.newScheduledThreadPool(10);\n\t\tservice.schedule(new Task(), 10, TimeUnit.SECONDS);\n\t\t\n\t\t//task to run repetatively 10 seconds after previous taks completes\n\t\tservice.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\t\t\n\t}",
"void setExecutorService(ExecutorService executorService);",
"private void ejecutorDeServicio(){\r\n dbExeccutor = Executors.newFixedThreadPool(\r\n 1, \r\n new databaseThreadFactory()\r\n ); \r\n }",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\n\t\tExecutorService executor = Executors.newFixedThreadPool(5);\n for (int i = 0; i < 10; i++) {\n \tCallable worker = new WorkerThread1(\"\" + i);\n \tFuture future = executor.submit(worker);\n \tSystem.out.println(\"Results\"+future.get());\n //executor.execute(worker);\n }\n executor.shutdown();\n while (!executor.isTerminated()) {\n }\n System.out.println(\"Finished all threads\");\n }",
"public static void main(String[] args) throws ExecutionException, InterruptedException {\n ExecutorService executorService=Executors.newScheduledThreadPool(5);\n try{\n for (int i = 0; i < 10; i++) {\n Future<String> futures = executorService.submit(new TestCallable());\n System.out.println(\"result---------------------\"+futures.get());\n }\n }catch (Exception e){\n e.printStackTrace();\n }finally {\n executorService.shutdown();\n }\n }",
"int getExecutorMaximumPoolSize();",
"WorkProcessor(BlockingQueue<Integer> queue) {\n this.queue = queue;\n ThreadFactoryBuilder builder = new ThreadFactoryBuilder();\n builder.setNameFormat(\"Thread-%d\");\n builder.setUncaughtExceptionHandler((t, e) -> logError(\"Error \\t\" + e.getMessage(), e));\n executor = Executors.newFixedThreadPool(NUM_THREAD, builder.build());\n }",
"public SimulatorThreadGroup(String name) {\n\t\tsuper(name);\n\t}",
"@Context\r\npublic interface ThreadContext\r\n{\r\n /**\r\n * Get the minimum thread level.\r\n *\r\n * @param min the default minimum value\r\n * @return the minimum thread level\r\n */\r\n int getMin( int min );\r\n \r\n /**\r\n * Return maximum thread level.\r\n *\r\n * @param max the default maximum value\r\n * @return the maximum thread level\r\n */\r\n int getMax( int max );\r\n \r\n /**\r\n * Return the deamon flag.\r\n *\r\n * @param flag true if a damon thread \r\n * @return the deamon thread policy\r\n */\r\n boolean getDaemon( boolean flag );\r\n \r\n /**\r\n * Get the thread pool name.\r\n *\r\n * @param name the pool name\r\n * @return the name\r\n */\r\n String getName( String name );\r\n \r\n /**\r\n * Get the thread pool priority.\r\n *\r\n * @param priority the thread pool priority\r\n * @return the priority\r\n */\r\n int getPriority( int priority );\r\n \r\n /**\r\n * Get the maximum idle time.\r\n *\r\n * @param idle the default maximum idle time\r\n * @return the maximum idle time in milliseconds\r\n */\r\n int getIdle( int idle );\r\n \r\n}",
"public ThreadPoolExecutorTracer(int corePoolSize, int maximumPoolSize, long keepAliveTime,\n TimeUnit unit, BlockingQueue<Runnable> workQueue, ThreadFactory threadFactory) {\n super(corePoolSize, maximumPoolSize, keepAliveTime, unit, workQueue, threadFactory);\n }",
"protected ForkJoinWorkerThread(ForkJoinPool pool) {\n<<<<<<< HEAD\n super(pool.nextWorkerName());\n this.pool = pool;\n int k = pool.registerWorker(this);\n poolIndex = k;\n eventCount = ~k & SMASK; // clear wait count\n locallyFifo = pool.locallyFifo;\n Thread.UncaughtExceptionHandler ueh = pool.ueh;\n if (ueh != null)\n setUncaughtExceptionHandler(ueh);\n setDaemon(true);\n }",
"public ThreadedListenerManager() {\n\t\tmanagerNumber = MANAGER_COUNT.getAndIncrement();\n\t\tBasicThreadFactory factory = new BasicThreadFactory.Builder()\n\t\t\t\t.namingPattern(\"listenerPool\" + managerNumber + \"-thread%d\")\n\t\t\t\t.daemon(true)\n\t\t\t\t.build();\n\t\tThreadPoolExecutor defaultPool = (ThreadPoolExecutor) Executors.newCachedThreadPool(factory);\n\t\tdefaultPool.allowCoreThreadTimeOut(true);\n\t\tthis.pool = defaultPool;\n\t}",
"@Override\n\t\t\tpublic Thread newThread(final Runnable r) {\n\t\t\t\tint id = threadNumber.getAndIncrement();\n\t\t\t\tString threadName = leftPad(String.valueOf(id), 2, \"0\");\n\t\t\t\tThread th = new Thread(r);\n\t\t\t\tth.setName(threadName);\n\t\t\t\tth.setDaemon(false);\n\t\t\t\treturn th;\n\t\t\t}",
"public ShutdownSuppressingExecutorServiceAdapter(TaskExecutor taskExecutor) {\n\t\tsuper(taskExecutor);\n\t}",
"public static void main(String[] args) {\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(2, 2, 0, TimeUnit.NANOSECONDS, new ArrayBlockingQueue<>(10));\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task A over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n threadPoolExecutor.execute(() -> {\n System.out.println(Thread.currentThread().getName() + \" Task B over!\");\n semaphore.release();\n });\n\n try {\n semaphore.acquire(2);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n System.out.println(\"all task over!\");\n threadPoolExecutor.shutdown();\n }",
"public interface ExecutorService {\n\n\n /**\n * beat 心跳\n * @return\n */\n public ReturnT<String> beat();\n\n\n public ReturnT<String> idleBeat(int jobId);\n\n\n /**\n * kill 掉某个job\n * @param jobId\n * @return\n */\n public ReturnT<String> kill(int jobId);\n\n\n /**\n * 记录掉某个日志\n * @param logDateTim\n * @param logId\n * @param fromLineNum\n * @return\n */\n public ReturnT<LogResult> log(long logDateTim, int logId, int fromLineNum);\n\n\n /**\n * 执行某个任务\n * @param triggerParam\n * @return\n */\n public ReturnT<String> run(TriggerParam triggerParam);\n\n}",
"public interface ThreadPool<Job extends Runnable> {\n\n void execute(Job job);\n\n void shutDown();\n\n void addWorkers(int num);\n\n void removeWorkers(int num);\n\n int getJobSize();\n\n}",
"public static void main(String[] args) {\n\t\tExecutorService es = new Executors.\n\t}",
"static ExecutorService boundedNamedCachedExecutorService(int maxThreadBound, String poolName, long keepalive, int queueSize, RejectedExecutionHandler abortPolicy) {\n\n ThreadFactory threadFactory = new NamedThreadFactory(poolName);\n LinkedBlockingQueue<Runnable> queue = new LinkedBlockingQueue<Runnable>(queueSize);\n\n ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(\n maxThreadBound,\n maxThreadBound,\n keepalive,\n TimeUnit.SECONDS,\n queue,\n threadFactory,\n abortPolicy\n );\n\n threadPoolExecutor.allowCoreThreadTimeOut(true);\n\n return threadPoolExecutor;\n }",
"public TestInvoker()\n {\n super(new TestClient(), new ThreadPoolExecutorImpl(3));\n }",
"private void normalExecutorService() {\n ListeningExecutorService executor = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(numberOfThreadsInThePool));\n try {\n Set<Future<String>> printTaskFutures = new HashSet<Future<String>>();\n for (final String printRequest : printRequests) {\n// Future<String> printer = executor.submit(new Printer(printRequest));\n ListenableFuture<String> printer = executor.submit(new Printer(printRequest));\n printTaskFutures.add(printer);\n// Futures.addCallback(printer, new FutureCallback<String>() {\n// // we want this handler to run immediately after we push the big red button!\n// public void onSuccess(String explosion) {\n//// walkAwayFrom(explosion);\n// }\n//\n// public void onFailure(Throwable thrown) {\n//// battleArchNemesis(); // escaped the explosion!\n// }\n// });\n }\n for (Future<String> future : printTaskFutures) {\n System.out.print(future.get());\n\n }\n } catch (Exception e) {\n Thread.currentThread().interrupt();\n } finally {\n// if (executor != null) {\n executor.shutdownNow();\n// }\n }\n }",
"public AgentThreadFactory(String agentName)\n {\n this.agentName = agentName;\n }",
"public static void main(String[] args) {\n ExecutorService threadPool = Executors.newCachedThreadPool();\n\n try{\n for (int i = 0; i < 10; i++) {\n threadPool.execute(() ->{\n System.out.println(Thread.currentThread().getName()+\"\\t 办理业务\");\n });\n //try {TimeUnit.SECONDS.sleep(1); } catch (InterruptedException e) {e.printStackTrace();}\n }\n\n } catch (Exception e) {\n e.printStackTrace();\n }finally {\n threadPool.shutdown();\n }\n\n\n\n }"
] | [
"0.6785512",
"0.6641957",
"0.6521807",
"0.64724976",
"0.6350054",
"0.63274413",
"0.6303769",
"0.62401867",
"0.621776",
"0.61935407",
"0.61266",
"0.60664976",
"0.6066467",
"0.6051026",
"0.6019021",
"0.59847504",
"0.59794575",
"0.59766734",
"0.59531814",
"0.59131294",
"0.58955836",
"0.58908075",
"0.58588517",
"0.5839358",
"0.58367664",
"0.5836764",
"0.5833833",
"0.5829244",
"0.58223534",
"0.580472",
"0.57819235",
"0.57765067",
"0.57285714",
"0.5723255",
"0.57047075",
"0.5703487",
"0.5684714",
"0.56617856",
"0.56549704",
"0.56521386",
"0.56504655",
"0.5641151",
"0.5634658",
"0.5625277",
"0.5624046",
"0.56126165",
"0.56122404",
"0.5597258",
"0.558857",
"0.5577199",
"0.5575655",
"0.5575026",
"0.556139",
"0.5547947",
"0.55427366",
"0.5526507",
"0.5513715",
"0.5500763",
"0.54931295",
"0.5491988",
"0.5485933",
"0.5477167",
"0.5475077",
"0.54637927",
"0.5452421",
"0.5451208",
"0.54481626",
"0.54456306",
"0.54407454",
"0.542087",
"0.53976303",
"0.5394137",
"0.5386039",
"0.53749853",
"0.53725296",
"0.53393596",
"0.53380394",
"0.5337079",
"0.53344166",
"0.5322738",
"0.5314751",
"0.5307673",
"0.53075093",
"0.5301566",
"0.5295183",
"0.52875125",
"0.5285751",
"0.5285294",
"0.5282785",
"0.52755886",
"0.527071",
"0.5266908",
"0.52642417",
"0.5259613",
"0.5255853",
"0.5255149",
"0.5250704",
"0.5244461",
"0.52375823",
"0.52330047"
] | 0.77024835 | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.