sentence1 stringlengths 52 3.87M | sentence2 stringlengths 1 47.2k | label stringclasses 1
value |
|---|---|---|
public function postFleetsFleetIdMembers($fleetId, $invitation, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
$this->postFleetsFleetIdMembersWithHttpInfo($fleetId, $invitation, $datasource, $token, $userAgent, $xUserAgent);
} | Operation postFleetsFleetIdMembers
Create fleet invitation
@param int $fleetId ID for a fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PostFleetsFleetIdMembersInvitation $invitation Details of the invitation (required)
@param string $datasource The server name you would like data from (optional, default t... | entailment |
public function postFleetsFleetIdMembersAsync($fleetId, $invitation, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->postFleetsFleetIdMembersAsyncWithHttpInfo($fleetId, $invitation, $datasource, $token, $userAgent, $xUserAgent)
->then(
... | Operation postFleetsFleetIdMembersAsync
Create fleet invitation
@param int $fleetId ID for a fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PostFleetsFleetIdMembersInvitation $invitation Details of the invitation (required)
@param string $datasource The server name you would like data from (optional, defa... | entailment |
public function postFleetsFleetIdWings($fleetId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->postFleetsFleetIdWingsWithHttpInfo($fleetId, $datasource, $token, $userAgent, $xUserAgent);
return $response;
} | Operation postFleetsFleetIdWings
Create fleet wing
@param int $fleetId ID for a fleet (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param string $userAgent Client ident... | entailment |
public function postFleetsFleetIdWingsAsync($fleetId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->postFleetsFleetIdWingsAsyncWithHttpInfo($fleetId, $datasource, $token, $userAgent, $xUserAgent)
->then(
function ($response) {
... | Operation postFleetsFleetIdWingsAsync
Create fleet wing
@param int $fleetId ID for a fleet (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param string $userAgent Client ... | entailment |
public function postFleetsFleetIdWingsWingIdSquadsAsync($fleetId, $wingId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->postFleetsFleetIdWingsWingIdSquadsAsyncWithHttpInfo($fleetId, $wingId, $datasource, $token, $userAgent, $xUserAgent)
->the... | Operation postFleetsFleetIdWingsWingIdSquadsAsync
Create fleet squad
@param int $fleetId ID for a fleet (required)
@param int $wingId The wing_id to create squad in (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to... | entailment |
public function putFleetsFleetId($fleetId, $newSettings, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
$this->putFleetsFleetIdWithHttpInfo($fleetId, $newSettings, $datasource, $token, $userAgent, $xUserAgent);
} | Operation putFleetsFleetId
Update fleet
@param int $fleetId ID for a fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PutFleetsFleetIdNewSettings $newSettings What to update for this fleet (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param... | entailment |
public function putFleetsFleetIdAsync($fleetId, $newSettings, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->putFleetsFleetIdAsyncWithHttpInfo($fleetId, $newSettings, $datasource, $token, $userAgent, $xUserAgent)
->then(
functio... | Operation putFleetsFleetIdAsync
Update fleet
@param int $fleetId ID for a fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PutFleetsFleetIdNewSettings $newSettings What to update for this fleet (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@... | entailment |
public function putFleetsFleetIdMembersMemberIdAsync($fleetId, $memberId, $movement, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->putFleetsFleetIdMembersMemberIdAsyncWithHttpInfo($fleetId, $memberId, $movement, $datasource, $token, $userAgent, $xUserAgen... | Operation putFleetsFleetIdMembersMemberIdAsync
Move fleet member
@param int $fleetId ID for a fleet (required)
@param int $memberId The character ID of a member in this fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PutFleetsFleetIdMembersMemberIdMovement $movement Details of the invitation (required)
@pa... | entailment |
public function putFleetsFleetIdSquadsSquadIdAsync($fleetId, $naming, $squadId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->putFleetsFleetIdSquadsSquadIdAsyncWithHttpInfo($fleetId, $naming, $squadId, $datasource, $token, $userAgent, $xUserAgent)
... | Operation putFleetsFleetIdSquadsSquadIdAsync
Rename fleet squad
@param int $fleetId ID for a fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PutFleetsFleetIdSquadsSquadIdNaming $naming New name of the squad (required)
@param int $squadId The squad to rename (required)
@param string $datasource The server ... | entailment |
public function putFleetsFleetIdWingsWingId($fleetId, $naming, $wingId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
$this->putFleetsFleetIdWingsWingIdWithHttpInfo($fleetId, $naming, $wingId, $datasource, $token, $userAgent, $xUserAgent);
} | Operation putFleetsFleetIdWingsWingId
Rename fleet wing
@param int $fleetId ID for a fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PutFleetsFleetIdWingsWingIdNaming $naming New name of the wing (required)
@param int $wingId The wing to rename (required)
@param string $datasource The server name you woul... | entailment |
public function putFleetsFleetIdWingsWingIdAsync($fleetId, $naming, $wingId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->putFleetsFleetIdWingsWingIdAsyncWithHttpInfo($fleetId, $naming, $wingId, $datasource, $token, $userAgent, $xUserAgent)
-... | Operation putFleetsFleetIdWingsWingIdAsync
Rename fleet wing
@param int $fleetId ID for a fleet (required)
@param \nullx27\ESI\nullx27\ESI\Models\PutFleetsFleetIdWingsWingIdNaming $naming New name of the wing (required)
@param int $wingId The wing to rename (required)
@param string $datasource The server name you... | entailment |
public function setActivity($activity)
{
$allowedValues = $this->getActivityAllowableValues();
if (!in_array($activity, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'activity', must be one of '%s'",
... | Sets activity
@param string $activity activity string
@return $this | entailment |
public static function generateTranslationsFile($absoluteTranslationFileName)
{
$translations = array();
if (file_exists($absoluteTranslationFileName)) {
@include($absoluteTranslationFileName);
} else {
Cache::getInstance()->storeData($absoluteTranslationFileName, "<?... | Create translation file if not exists
@param string $absoluteTranslationFileName
@return array | entailment |
public static function setLocale($default = null)
{
$locale = self::extractLocale($default);
Logger::log('Set locale to project [' . $locale . ']');
// Load translations
putenv("LC_ALL=" . $locale);
setlocale(LC_ALL, $locale);
// Load the locale path
$locale_p... | Method to set the locale
@param string $default
@throws \Exception | entailment |
public function getCharactersCharacterIdAssets($characterId, $datasource = null, $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getCharactersCharacterIdAssetsWithHttpInfo($characterId, $datasource, $token, $userAgent, $xUserAgent);
return $response;
} | Operation getCharactersCharacterIdAssets
Get character assets
@param int $characterId Character id of the target character (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use, if preferred over a header (optional)
@p... | entailment |
public function getInsurancePrices($datasource = 'tranquility', $language = 'en-us', $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getInsurancePricesWithHttpInfo($datasource, $language, $userAgent, $xUserAgent);
return $response;
} | Operation getInsurancePrices
List insurance levels
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $language Language to use in the response (optional, default to en-us)
@param string $userAgent Client identifier, takes precedence over headers (op... | entailment |
public function getInsurancePricesAsync($datasource = 'tranquility', $language = 'en-us', $userAgent = null, $xUserAgent = null)
{
return $this->getInsurancePricesAsyncWithHttpInfo($datasource, $language, $userAgent, $xUserAgent)
->then(
function ($response) {
... | Operation getInsurancePricesAsync
List insurance levels
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $language Language to use in the response (optional, default to en-us)
@param string $userAgent Client identifier, takes precedence over header... | entailment |
public function map(array $verbs, string $uri, $callback): Route
{
if ($this->isControllerString($callback)) {
$callback = $this->normaliseCallbackString($callback);
}
return parent::map($verbs, $uri, $callback);
} | Map a router action to a set of Http verbs and a URI
@param array $verbs
@param string $uri
@param callable|string $callback
@return Rareloop\Router\Route | entailment |
private function normaliseCallbackString(string $callback) : string
{
@list($controller, $method) = explode('@', $callback);
if (class_exists($this->defaultControllerNamespace . $controller)) {
return $this->defaultControllerNamespace . $callback;
}
return $callback;
... | Add the default namespace to the Controller classname if required
@param string $callback
@return string | entailment |
public function listInvalidProperties()
{
$invalid_properties = [];
if ($this->container['characterId'] === null) {
$invalid_properties[] = "'characterId' can't be null";
}
if ($this->container['joinTime'] === null) {
$invalid_properties[] = "'joinTime' can't ... | show all the invalid properties with reasons.
@return array invalid properties with reasons | entailment |
public function valid()
{
if ($this->container['characterId'] === null) {
return false;
}
if ($this->container['joinTime'] === null) {
return false;
}
if ($this->container['role'] === null) {
return false;
}
$allowed_values ... | validate all the properties in the model
return true if all passed
@return bool True if all properteis are valid | entailment |
public function setRole($role)
{
$allowed_values = array('fleet_commander', 'wing_commander', 'squad_commander', 'squad_member');
if ((!in_array($role, $allowed_values))) {
throw new \InvalidArgumentException("Invalid value for 'role', must be one of 'fleet_commander', 'wing_commander', ... | Sets role
@param string $role Member’s role in fleet
@return $this | entailment |
public function reset()
{
$this->startTime = null;
$this->endTime = null;
$this->result = null;
$this->exception = null;
$this->status = TaskStatus::PLANNED;
return $this;
} | {@inheritdoc} | entailment |
public function mapCol(string $table, string $name, string $type, string $len = null): array
{
// Try to find by colsName
$colsName = $this->getColsNameMapping();
foreach ($colsName as $colRegex => $params) {
preg_match("/^$colRegex\$/i", $table. '.' . $name, $matches);
... | Will map cols first by looking for field name then by looking for field type
if the first returned nothing
@param string $table
@param string $name
@param string $type
@param mixed $len Used to get options from enum (stored in length)
@return array
@throws NeuralyzerGuesserException | entailment |
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['orderId'] === null) {
$invalidProperties[] = "'orderId' can't be null";
}
if ($this->container['typeId'] === null) {
$invalidProperties[] = "'typeId' can't be null";
... | Show all the invalid properties with reasons.
@return array invalid properties with reasons | entailment |
public function setEventType($eventType)
{
$allowed_values = array('tcu_defense', 'ihub_defense', 'station_defense', 'station_freeport');
if ((!in_array($eventType, $allowed_values))) {
throw new \InvalidArgumentException("Invalid value for 'eventType', must be one of 'tcu_defense', 'ihu... | Sets eventType
@param string $eventType Type of event this campaign is for. tcu_defense, ihub_defense and station_defense are referred to as \"Defense Events\", station_freeport as \"Freeport Events\".
@return $this | entailment |
public function write(array $fields): int
{
$options = $this->getCsvControl();
$delimiter = $options[0];
$enclosure = $options[1];
if (!empty($enclosure)) {
return $this->fputcsv($fields, $delimiter, $enclosure);
}
$fields = array_map(function ($field) us... | Write a CSV line either by PHP standard or manually when no $enclosure
@param array $fields
@return int | entailment |
public function getGrantableRolesAtHqAllowableValues()
{
return [
self::GRANTABLE_ROLES_AT_HQ_DIRECTOR,
self::GRANTABLE_ROLES_AT_HQ_PERSONNEL_MANAGER,
self::GRANTABLE_ROLES_AT_HQ_ACCOUNTANT,
self::GRANTABLE_ROLES_AT_HQ_SECURITY_OFFICER,
self::GRANT... | Gets allowable values of the enum
@return string[] | entailment |
public function getGrantableRolesAtOtherAllowableValues()
{
return [
self::GRANTABLE_ROLES_AT_OTHER_DIRECTOR,
self::GRANTABLE_ROLES_AT_OTHER_PERSONNEL_MANAGER,
self::GRANTABLE_ROLES_AT_OTHER_ACCOUNTANT,
self::GRANTABLE_ROLES_AT_OTHER_SECURITY_OFFICER,
... | Gets allowable values of the enum
@return string[] | entailment |
public function getRolesAllowableValues()
{
return [
self::ROLES_DIRECTOR,
self::ROLES_PERSONNEL_MANAGER,
self::ROLES_ACCOUNTANT,
self::ROLES_SECURITY_OFFICER,
self::ROLES_FACTORY_MANAGER,
self::ROLES_STATION_MANAGER,
self::... | Gets allowable values of the enum
@return string[] | entailment |
public function getRolesAtHqAllowableValues()
{
return [
self::ROLES_AT_HQ_DIRECTOR,
self::ROLES_AT_HQ_PERSONNEL_MANAGER,
self::ROLES_AT_HQ_ACCOUNTANT,
self::ROLES_AT_HQ_SECURITY_OFFICER,
self::ROLES_AT_HQ_FACTORY_MANAGER,
self::ROLES_A... | Gets allowable values of the enum
@return string[] | entailment |
public function setGrantableRoles($grantableRoles)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6', 'Hangar_Take_... | Sets grantableRoles
@param string[] $grantableRoles grantable_roles array
@return $this | entailment |
public function setGrantableRolesAtBase($grantableRolesAtBase)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6', '... | Sets grantableRolesAtBase
@param string[] $grantableRolesAtBase grantable_roles_at_base array
@return $this | entailment |
public function setGrantableRolesAtHq($grantableRolesAtHq)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6', 'Hang... | Sets grantableRolesAtHq
@param string[] $grantableRolesAtHq grantable_roles_at_hq array
@return $this | entailment |
public function setGrantableRolesAtOther($grantableRolesAtOther)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6',... | Sets grantableRolesAtOther
@param string[] $grantableRolesAtOther grantable_roles_at_other array
@return $this | entailment |
public function setRoles($roles)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6', 'Hangar_Take_7', 'Hangar_Query_... | Sets roles
@param string[] $roles roles array
@return $this | entailment |
public function setRolesAtBase($rolesAtBase)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6', 'Hangar_Take_7', 'H... | Sets rolesAtBase
@param string[] $rolesAtBase roles_at_base array
@return $this | entailment |
public function setRolesAtHq($rolesAtHq)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6', 'Hangar_Take_7', 'Hanga... | Sets rolesAtHq
@param string[] $rolesAtHq roles_at_hq array
@return $this | entailment |
public function setRolesAtOther($rolesAtOther)
{
$allowed_values = array('Director', 'Personnel_Manager', 'Accountant', 'Security_Officer', 'Factory_Manager', 'Station_Manager', 'Auditor', 'Hangar_Take_1', 'Hangar_Take_2', 'Hangar_Take_3', 'Hangar_Take_4', 'Hangar_Take_5', 'Hangar_Take_6', 'Hangar_Take_7', ... | Sets rolesAtOther
@param string[] $rolesAtOther roles_at_other array
@return $this | entailment |
public function save($key, $ttl)
{
$fileName = $this->getFileName($key);
if (!@file_put_contents($fileName, time() + $ttl)) {
return false;
}
return true;
} | {@inheritdoc} | entailment |
public function delete($key)
{
$fileName = $this->getFileName($key);
if (!file_exists($fileName)) {
return true;
}
if (!@unlink($fileName)) {
return false;
}
return true;
} | {@inheritdoc} | entailment |
public function exists($key)
{
$fileName = $this->getFileName($key);
if (!file_exists($fileName)) {
return false;
}
$content = file_get_contents($fileName);
return time() <= $content;
} | {@inheritdoc} | entailment |
protected function __parseRanges()
{
if (isset($this->__meta["labelRange"]) && is_array($this->__meta["labelRange"])) {
if (isset($this->__meta["valueRange"]) && is_array($this->__meta["valueRange"]) && count($this->__meta["labelRange"]) == count($this->__meta["valueRange"])) {
$... | Generate ranges
Supported meta keys for ranges:
- labelRange
- valueRange
- start
- end | entailment |
public function addField($label, $value, $selected = false, $meta = array())
{
$objOption = new SelectOption($label, $value, $selected, $meta);
$objOption->setMeta("parent", $this, true);
$this->__options->addObject($objOption);
return $objOption;
} | Add option element
@param string $label The option elements label
@param string $value The option elements value
@param boolean $selected True if this option should be selected by default
@param array $meta The meta array
@return \ValidFormBuilder\SelectOption | entailment |
public function addGroup($label)
{
$objGroup = new SelectGroup($label);
$objGroup->setMeta("parent", $this, true);
$this->__options->addObject($objGroup);
return $objGroup;
} | Add optgroup element
@param string $label The optgroup's label
@return \ValidFormBuilder\SelectGroup | entailment |
public function loadData(string $table, string $fname, array $fields, string $mode): string
{
$fields = implode(', ', $fields);
if ($this->pretend === false) {
if ($mode === 'update') {
$this->conn->query("TRUNCATE {$table}");
}
$pdo = $this->conn... | {@inheritdoc} | entailment |
public function setLocationType($locationType)
{
$allowed_values = array('station', 'structure');
if (!is_null($locationType) && (!in_array($locationType, $allowed_values))) {
throw new \InvalidArgumentException("Invalid value for 'locationType', must be one of 'station', 'structure'");
... | Sets locationType
@param string $locationType location_type string
@return $this | entailment |
public function setRole($role)
{
$allowedValues = $this->getRoleAllowableValues();
if (!in_array($role, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'role', must be one of '%s'",
implode("', '"... | Sets role
@param string $role Member’s role in fleet
@return $this | entailment |
public function getCharactersCharacterIdSearch($categories, $characterId, $search, $datasource = 'tranquility', $language = 'en-us', $strict = 'false', $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getCharactersCharacterIdSearchWithHttpInfo($categories, $characterId, $sear... | Operation getCharactersCharacterIdSearch
Search on a string
@param string[] $categories Type of entities to search for (required)
@param int $characterId An EVE character ID (required)
@param string $search The string to search on (required)
@param string $datasource The server name you would like data from (opti... | entailment |
public function getCharactersCharacterIdSearchAsync($categories, $characterId, $search, $datasource = 'tranquility', $language = 'en-us', $strict = 'false', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->getCharactersCharacterIdSearchAsyncWithHttpInfo($categories, $characterId, $searc... | Operation getCharactersCharacterIdSearchAsync
Search on a string
@param string[] $categories Type of entities to search for (required)
@param int $characterId An EVE character ID (required)
@param string $search The string to search on (required)
@param string $datasource The server name you would like data from ... | entailment |
public function getSearchAsync($categories, $search, $datasource = 'tranquility', $language = 'en-us', $strict = 'false', $userAgent = null, $xUserAgent = null)
{
return $this->getSearchAsyncWithHttpInfo($categories, $search, $datasource, $language, $strict, $userAgent, $xUserAgent)
->then(
... | Operation getSearchAsync
Search on a string
@param string[] $categories Type of entities to search for (required)
@param string $search The string to search on (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $language Language to use i... | entailment |
public function getRefTypeAllowableValues()
{
return [
self::REF_TYPE_ACCELERATION_GATE_FEE,
self::REF_TYPE_ADVERTISEMENT_LISTING_FEE,
self::REF_TYPE_AGENT_DONATION,
self::REF_TYPE_AGENT_LOCATION_SERVICES,
self::REF_TYPE_AGENT_MISCELLANEOUS,
... | Gets allowable values of the enum
@return string[] | entailment |
public function getFirstPartyTypeAllowableValues()
{
return [
self::FIRST_PARTY_TYPE_CHARACTER,
self::FIRST_PARTY_TYPE_CORPORATION,
self::FIRST_PARTY_TYPE_ALLIANCE,
self::FIRST_PARTY_TYPE_FACTION,
self::FIRST_PARTY_TYPE_SYSTEM,
];
} | Gets allowable values of the enum
@return string[] | entailment |
public function getSecondPartyTypeAllowableValues()
{
return [
self::SECOND_PARTY_TYPE_CHARACTER,
self::SECOND_PARTY_TYPE_CORPORATION,
self::SECOND_PARTY_TYPE_ALLIANCE,
self::SECOND_PARTY_TYPE_FACTION,
self::SECOND_PARTY_TYPE_SYSTEM,
];
... | Gets allowable values of the enum
@return string[] | entailment |
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['date'] === null) {
$invalidProperties[] = "'date' can't be null";
}
if ($this->container['refId'] === null) {
$invalidProperties[] = "'refId' can't be null";
}
... | Show all the invalid properties with reasons.
@return array invalid properties with reasons | entailment |
public function valid()
{
if ($this->container['date'] === null) {
return false;
}
if ($this->container['refId'] === null) {
return false;
}
if ($this->container['refType'] === null) {
return false;
}
$allowedValues = $this... | Validate all the properties in the model
return true if all passed
@return bool True if all properties are valid | entailment |
public function setRefType($refType)
{
$allowedValues = $this->getRefTypeAllowableValues();
if (!in_array($refType, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'refType', must be one of '%s'",
... | Sets refType
@param string $refType Transaction type, different type of transaction will populate different fields in `extra_info` Note: If you have an existing XML API application that is using ref_types, you will need to know which string ESI ref_type maps to which integer. You can use the following gist to see stri... | entailment |
public function setFirstPartyType($firstPartyType)
{
$allowedValues = $this->getFirstPartyTypeAllowableValues();
if (!is_null($firstPartyType) && !in_array($firstPartyType, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value... | Sets firstPartyType
@param string $firstPartyType first_party_type string
@return $this | entailment |
public function setSecondPartyType($secondPartyType)
{
$allowedValues = $this->getSecondPartyTypeAllowableValues();
if (!is_null($secondPartyType) && !in_array($secondPartyType, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid ... | Sets secondPartyType
@param string $secondPartyType second_party_type string
@return $this | entailment |
public static function extractHttpRoute($pattern)
{
$httpMethod = 'ALL';
$routePattern = $pattern;
if (false !== strpos($pattern, '#|#')) {
list($httpMethod, $routePattern) = explode('#|#', $pattern, 2);
}
return array(strtoupper($httpMethod), $routePattern);
... | @param $pattern
@return array | entailment |
public static function extractComponents($route, $pattern)
{
Logger::log('Extracting parts for the request to execute');
$url = parse_url(preg_replace("/\/\//", '/', $route));
$partialRoute = explode('/', $url['path']);
$partialPattern = explode('/', $pattern);
$get = [];
... | Método que extrae de la url los parámetros REST
@param string $route
@param string $pattern
@return array | entailment |
public static function compareSlashes($routePattern, $path)
{
$patternSeparator = count(explode('/', $routePattern));
if (preg_match('/\/$/', $routePattern)) {
$patternSeparator--;
}
$routePattern = preg_replace('/\/\{.*\}$/', '', $routePattern);
$cleanPatternSepa... | Function that checks if the long of the patterns match
@param $routePattern
@param $path
@return bool | entailment |
public static function matchRoutePattern($routePattern, $path)
{
$expr = preg_replace('/\{([^}]+)\}/', '###', $routePattern);
$expr = preg_quote($expr, '/');
$expr = str_replace('###', '(.*)', $expr);
$expr2 = preg_replace('/\(\.\*\)$/', '', $expr);
$matched = preg_match('/^'... | Método que compara la ruta web con la guardada en la cache
@param $routePattern
@param $path
@return bool | entailment |
public static function extractReflectionParams($sr, \ReflectionMethod $method)
{
$regex = $sr[1] ?: $sr[0];
$default = '';
$params = [];
$parameters = $method->getParameters();
$requirements = [];
/** @var \ReflectionParameter $param */
if (count($parameters) ... | Método que extrae los parámetros de una función
@param array $sr
@param \ReflectionMethod $method
@return array | entailment |
public static function extractReflectionVisibility($docComments)
{
preg_match('/@visible\ (.*)(\n|\r)/i', $docComments, $visible);
return !(array_key_exists(1, $visible) && false !== strpos($visible[1], 'false'));
} | Método que extrae la visibilidad de una ruta
@param string $docComments
@return bool | entailment |
public function getServicesAllowableValues()
{
return [
self::SERVICES_BOUNTY_MISSIONS,
self::SERVICES_ASSASINATION_MISSIONS,
self::SERVICES_COURIER_MISSIONS,
self::SERVICES_INTERBUS,
self::SERVICES_REPROCESSING_PLANT,
self::SERVICES_RE... | Gets allowable values of the enum
@return string[] | entailment |
public function setServices($services)
{
$allowedValues = $this->getServicesAllowableValues();
if (array_diff($services, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'services', must be one of '%s'",
... | Sets services
@param string[] $services services array
@return $this | entailment |
public static function getDBHelper(string $driver): string
{
$drivers = [
'pdo_mysql' => MySQL::class,
'mysql' => MySQL::class,
'mysql2' => MySQL::class,
'pdo_pgsql' => PostgreSQL::class,
'pgsql' => PostgreSQL::class,
'... | Find the right local driver from a php extension
@param string $driver
@throws \InvalidArgumentException
@return string | entailment |
public function evaluateExpression(string $expression)
{
$expressionLanguage = new ExpressionLanguage();
return $expressionLanguage->evaluate($expression, $this->services);
} | Evaluate an expression that would be in the most general case
an action coming from an Anonymization config
@param string $expression
@return mixed | entailment |
public function evaluateExpressions(array $expressions): array
{
$res = [];
foreach ($expressions as $expression) {
$res[] = $this->evaluateExpression($expression);
}
return $res;
} | Evaluate a list of expression
@param array $expressions
@return array | entailment |
private function configure(): void
{
$services = array_keys($this->container->findTaggedServiceIds('app.service'));
foreach ($services as $service) {
$service = $this->container->get($service);
$this->services[$service->getName()] = $service;
}
} | Configure that service by registering all services in an array
@return void | entailment |
public function getCharactersCharacterIdClones($characterId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getCharactersCharacterIdClonesWithHttpInfo($characterId, $datasource, $token, $userAgent, $xUserAgent);
return $response;
} | Operation getCharactersCharacterIdClones
Get clones
@param int $characterId An EVE character ID (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param string $userAgent Cl... | entailment |
public function getCharactersCharacterIdClonesAsync($characterId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->getCharactersCharacterIdClonesAsyncWithHttpInfo($characterId, $datasource, $token, $userAgent, $xUserAgent)
->then(
... | Operation getCharactersCharacterIdClonesAsync
Get clones
@param int $characterId An EVE character ID (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param string $userAge... | entailment |
public function getCharactersCharacterIdImplants($characterId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getCharactersCharacterIdImplantsWithHttpInfo($characterId, $datasource, $token, $userAgent, $xUserAgent);
return $response;
... | Operation getCharactersCharacterIdImplants
Get active implants
@param int $characterId An EVE character ID (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param string $u... | entailment |
public function getCharactersCharacterIdImplantsAsync($characterId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->getCharactersCharacterIdImplantsAsyncWithHttpInfo($characterId, $datasource, $token, $userAgent, $xUserAgent)
->then(
... | Operation getCharactersCharacterIdImplantsAsync
Get active implants
@param int $characterId An EVE character ID (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param stri... | entailment |
public function getLocationFlagAllowableValues()
{
return [
self::LOCATION_FLAG_AUTO_FIT,
self::LOCATION_FLAG_CARGO,
self::LOCATION_FLAG_CORPSE_BAY,
self::LOCATION_FLAG_DRONE_BAY,
self::LOCATION_FLAG_FLEET_HANGAR,
self::LOCATION_FLAG_DE... | Gets allowable values of the enum
@return string[] | entailment |
public function setLocationFlag($locationFlag)
{
$allowed_values = array('AutoFit', 'Cargo', 'CorpseBay', 'DroneBay', 'FleetHangar', 'Deliveries', 'HiddenModifiers', 'Hangar', 'HangarAll', 'LoSlot0', 'LoSlot1', 'LoSlot2', 'LoSlot3', 'LoSlot4', 'LoSlot5', 'LoSlot6', 'LoSlot7', 'MedSlot0', 'MedSlot1', 'MedSlo... | Sets locationFlag
@param string $locationFlag Indicates something about this item's storage location. The flag is used to differentiate between hangar divisions, drone bay, fitting location, and similar.
@return $this | entailment |
protected function execute(InputInterface $input, OutputInterface $output): void
{
$dumper = new \Symfony\Component\Config\Definition\Dumper\YamlReferenceDumper;
$config = $dumper->dump(
new \Edyan\Neuralyzer\Configuration\ConfigDefinition
);
$output->writeLn($config);
... | Execute the command
@param InputInterface $input
@param OutputInterface $output
@return void | entailment |
public function phar($opts = ['neuralyzer-version' => 'dev'])
{
if ((int)ini_get('phar.readonly') === 1) {
throw new \RuntimeException(
'You must have phar.readonly = 1 or run' . PHP_EOL .
'php -d phar.readonly=0 vendor/bin/robo (phar|release)'
);
... | Build an executable phar | entailment |
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['bloodlineId'] === null) {
$invalidProperties[] = "'bloodlineId' can't be null";
}
if ($this->container['name'] === null) {
$invalidProperties[] = "'name' can't be null";
... | Show all the invalid properties with reasons.
@return array invalid properties with reasons | entailment |
public function setError($field, $error = 'Error de validación')
{
$this->fields[$field]['error'] = $error;
$this->errors[$field] = $error;
return $this;
} | Método que añade un error para un campo del formulario
@param string $field
@param string $error
@return FormSchemaTrait | entailment |
protected function execute(InputInterface $input, OutputInterface $output): ?int
{
// Throw an exception immediately if we don't have the required DB parameter
if (empty($input->getOption('db'))) {
throw new \InvalidArgumentException('Database name is required (--db)');
}
... | @param InputInterface $input Symfony's Input Class for parameters and options
@param OutputInterface $output Symfony's Output Class to display info
@return null|int null or 0 if everything went fine, or an error code
@throws \Doctrine\DBAL\DBALException
@throws \Edyan\Neuralyzer\Exception\NeuralyzerException | entailment |
private function anonymizeTable(string $table): bool
{
$total = $this->getTotal($table);
if ($total === 0) {
$this->output->writeln("<info>$table is empty</info>");
return true;
}
$bar = new ProgressBar($this->output, $total);
$bar->setRedrawFrequenc... | Anonymize a specific table and display info about the job
@param string $table
@return bool | entailment |
private function getTotal(string $table): int
{
$config = $this->reader->getEntityConfig($table);
$limit = (int)$config['limit'];
if ($config['action'] === 'insert') {
return empty($limit) ? 100 : $limit;
}
$rows = $this->dbUtils->countResults($table);
if... | Define the total number of records to process for progress bar
@param string $table
@return int | entailment |
public function setDay($day)
{
if (($day > 6)) {
throw new \InvalidArgumentException('invalid value for $day when calling PutCorporationsCorporationIdStructuresStructureIdNewSchedule., must be smaller than or equal to 6.');
}
if (($day < 0)) {
throw new \InvalidArgum... | Sets day
@param int $day Day of the week, zero-indexed to Monday
@return $this | entailment |
public function setHour($hour)
{
if (($hour > 23)) {
throw new \InvalidArgumentException('invalid value for $hour when calling PutCorporationsCorporationIdStructuresStructureIdNewSchedule., must be smaller than or equal to 23.');
}
if (($hour < 0)) {
throw new \Inval... | Sets hour
@param int $hour Hour of the day evetime, zero-indexed to midnight
@return $this | entailment |
protected function configure(): void
{
// First command : Test the DB Connexion
$this->setName($this->command)
->setDescription(
'Validate a configuration for the Anonymizer'
)->setHelp(
'This command will validate that the configuration provid... | Configure the command
@return void | entailment |
protected function execute(InputInterface $input, OutputInterface $output): void
{
try {
$reader = new \Edyan\Neuralyzer\Configuration\Reader($input->getOption('file'));
} catch (\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException $e) {
throw new \Edy... | Execute the command
@param InputInterface $input
@param OutputInterface $output
@throws \Edyan\Neuralyzer\Exception\NeuralyzerConfigurationException
@throws \Edyan\Neuralyzer\Exception\NeuralyzerException
@return void | entailment |
public function createApiDocs($domain)
{
ini_set('memory_limit', -1);
ini_set('max_execution_time', -1);
$type = $this->getRequest()->get('type') ?: ApiController::PSFS_DOC;
$download = $this->getRequest()->get('download') ?: false;
$module = $this->srv->getModules($domain)... | @GET
@CACHE 600
@label Generador de documentación API
@route /{domain}/api/doc
@param string $domain
@return string JSON | entailment |
public function setShareholderType($shareholderType)
{
$allowedValues = $this->getShareholderTypeAllowableValues();
if (!in_array($shareholderType, $allowedValues)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value for 'shareholderType', m... | Sets shareholderType
@param string $shareholderType shareholder_type string
@return $this | entailment |
public function getSovereigntyCampaigns($datasource = 'tranquility', $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getSovereigntyCampaignsWithHttpInfo($datasource, $userAgent, $xUserAgent);
return $response;
} | Operation getSovereigntyCampaigns
List sovereignty campaigns
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $userAgent Client identifier, takes precedence over headers (optional)
@param string $xUserAgent Client identifier, takes precedence over ... | entailment |
public function getSovereigntyCampaignsAsync($datasource = 'tranquility', $userAgent = null, $xUserAgent = null)
{
return $this->getSovereigntyCampaignsAsyncWithHttpInfo($datasource, $userAgent, $xUserAgent)
->then(
function ($response) {
return $response[0];
... | Operation getSovereigntyCampaignsAsync
List sovereignty campaigns
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $userAgent Client identifier, takes precedence over headers (optional)
@param string $xUserAgent Client identifier, takes precedence ... | entailment |
public function getSovereigntyMap($datasource = 'tranquility', $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getSovereigntyMapWithHttpInfo($datasource, $userAgent, $xUserAgent);
return $response;
} | Operation getSovereigntyMap
List sovereignty of systems
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $userAgent Client identifier, takes precedence over headers (optional)
@param string $xUserAgent Client identifier, takes precedence over User-... | entailment |
public function getSovereigntyMapAsync($datasource = 'tranquility', $userAgent = null, $xUserAgent = null)
{
return $this->getSovereigntyMapAsyncWithHttpInfo($datasource, $userAgent, $xUserAgent)
->then(
function ($response) {
return $response[0];
... | Operation getSovereigntyMapAsync
List sovereignty of systems
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $userAgent Client identifier, takes precedence over headers (optional)
@param string $xUserAgent Client identifier, takes precedence over ... | entailment |
public function getSovereigntyStructuresAsync($datasource = 'tranquility', $userAgent = null, $xUserAgent = null)
{
return $this->getSovereigntyStructuresAsyncWithHttpInfo($datasource, $userAgent, $xUserAgent)
->then(
function ($response) {
return $response[0]... | Operation getSovereigntyStructuresAsync
List sovereignty structures
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $userAgent Client identifier, takes precedence over headers (optional)
@param string $xUserAgent Client identifier, takes precedenc... | entailment |
public function getCharactersCharacterIdContracts($characterId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getCharactersCharacterIdContractsWithHttpInfo($characterId, $datasource, $token, $userAgent, $xUserAgent);
return $response;
... | Operation getCharactersCharacterIdContracts
Get contracts
@param int $characterId An EVE character ID (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param string $userAg... | entailment |
public function getCharactersCharacterIdContractsAsync($characterId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->getCharactersCharacterIdContractsAsyncWithHttpInfo($characterId, $datasource, $token, $userAgent, $xUserAgent)
->then(
... | Operation getCharactersCharacterIdContractsAsync
Get contracts
@param int $characterId An EVE character ID (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access token to use if unable to set a header (optional)
@param string $u... | entailment |
public function getCharactersCharacterIdContractsContractIdBids($characterId, $contractId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getCharactersCharacterIdContractsContractIdBidsWithHttpInfo($characterId, $contractId, $datasource, $token,... | Operation getCharactersCharacterIdContractsContractIdBids
Get contract bids
@param int $characterId An EVE character ID (required)
@param int $contractId ID of a contract (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access to... | entailment |
public function getCharactersCharacterIdContractsContractIdBidsAsync($characterId, $contractId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
return $this->getCharactersCharacterIdContractsContractIdBidsAsyncWithHttpInfo($characterId, $contractId, $datasource, $token, ... | Operation getCharactersCharacterIdContractsContractIdBidsAsync
Get contract bids
@param int $characterId An EVE character ID (required)
@param int $contractId ID of a contract (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Acce... | entailment |
public function getCharactersCharacterIdContractsContractIdItems($characterId, $contractId, $datasource = 'tranquility', $token = null, $userAgent = null, $xUserAgent = null)
{
list($response) = $this->getCharactersCharacterIdContractsContractIdItemsWithHttpInfo($characterId, $contractId, $datasource, $toke... | Operation getCharactersCharacterIdContractsContractIdItems
Get contract items
@param int $characterId An EVE character ID (required)
@param int $contractId ID of a contract (required)
@param string $datasource The server name you would like data from (optional, default to tranquility)
@param string $token Access ... | entailment |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.