query_id
string
corpus_id
string
query
string
code
string
label
int64
8ff0672ecf4a58c8ad26ccb43589229f
0701ae6d3d565833dda736cb079b86f0
将字节数组内每个字节值反转。<para>用255减之。</para>
namespace Mozi.HttpEmbedded.Extension public static class Others public static byte[] Revert(this byte[] data) { Array.Reverse(data); return data; }
0
fa60a6ec58dc2c8cb7e3124e24b88b22
3492f5ab986ad813c6c3e541e6389e0f
Function Name: RTC_1_DayOfWeek Calculates Day Of Week value use Zeller's congruence. Day Of Week value.
IDATE& idt ) { idt.wday = tddyw( tddiy( idt), idt.year ); return idt.wday; }
0
843cff28aa0ee9e3271477bb7dd1b272
f3c5facca9dc76a46eda659b4e60ee20
This setter calculates the new possible moves once the position has changed.
public class Function public static void setMoves() { moves = new ArrayList<Integer>(); for(int y = 0; y < 4; y++) { for(int x = 0; x < 4; x++) { int square = 0; int cells[] = new int[4]; int cellInd = 0; for(int dy = 0; dy < 2; dy++) { for(int dx = 0; dx < 2; dx++) { cells[cellInd++] ...
1
3a2346b2db8fb6d1229af99056cc3ecd
6d39c7a82dff24af7a13c3c4688444fb
通用,吐司提示。显示时长自定义
if(context == null) return; context = context.getApplicationContext(); Toast mToast = new Toast(context); TextView mTextView = new TextView(context); mTextView.setGravity(Gravity.CENTER); mTextView.setTextColor(Color.WHITE); mTextView.setBackgroundColor(0xbb000000); int p = dip2px(context, 10); mTe...
1
bf98ca150ad803631a62f46d6814ddae
b6827a4630add1069f59a1ae2c2e71c4
Returns the list of known resellers.
@NotNull @NotContainsNulls List<SOBeard> responsibles ();
0
530735bef290e18944fca81abe5743c9
9a3a98005fc51f56918965e4714f97f6
Unsets the value of the '{@link Gtm.Delivery#getReplacedDeliveryId <em>Replaced Delivery Id</em>}' attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
void unsetDeliveryAddress();
0
dfd40edab47d49ef1eeaaef24307324f
788b31c62fb1b2a6e591d646909fd250
统计定时任务个数
public class TaskDaoImpl extends BaseDao implements ITaskDao public long count (Map<String, String> param) throws SQLException { return (Integer) getSqlMapClient().queryForObject("Task.count", param); }
1
ffd99b11a9cb5543d4e441106efeb747
9ad54f16dae23d047302c285f62ca2e2
查询模块树的下一级,不按权限过滤
public List<Cat> queryChidren(String parentId,String moduleId){ String sql = "SELECT * FROM "+tableName + " WHERE " + "module_id=? " + (parentId!=null && !parentId.trim().equals("")?" and parent_id=? ":"") + "order by sorter"; List<?> list = dao.query(sql, parentId!=null && !parentId.trim().equals...
1
c2f610051a0c7e1115b00e4e4eacee4f
f874a230271e53a55e2fc513d266a563
Allelic fraction of the "other" (non-ref, non-alt) alleles among all fragments at this site.
public class AllelicCount implements Locatable public double estimateAltAlleleFraction() { if (refReadCount + altReadCount == 0) { return Double.NaN; } return (double) altReadCount / (refReadCount + altReadCount); }
0
451d8c78a1a8b504d87d9620e2ded68d
3156ee672893174ab9cc04a02bc72271
negative value: buffer below threshold, buffer almost empty positive value: buffer above threshold, buffer filling
FilterStatus_t moving_avg_fill_buffer(MovingAverageFilter_t *filter, int16_t *data, int16_t *y) { if(filter->initialized) { return FilterError; } FIFO_t *fifo_ptr = &filter->fifo; uint32_t window_size = filter->window_size; if(FIFO_write(fifo_ptr, data, window_size, NULL) != FIFO_OK) ...
0
1486f709fee1dff30b404c4b269dfa0d
669fafce1897bc46dea0f4d7be98c5e3
This is the Recursive approach for finding the Max of the Linked List
{ int val,left,right,max = INT_MIN; if(root != NULL){ val = root->data; left = findMax(root->left); right = findMax(root->right); if(left > right) max = left; else max = right; if(max < val) max = val; } return max; }
0
296f5ca2d8c74d6949ff4fd833bac5d6
80c4ad0fead73ae00cce59f2553f042f
Gets (as xml) array of all "groundStations" elements
org.apache.xmlbeans.XmlString insertNewGroundStations(int i);
0
40d0473fdd06c98b31aa8584df599543
d4c68497f6e08637840569ae855e9749
Returns whether step labels should be displayed or not.
public void setShowLabels( Boolean isShowLabels );
0
6b0611921ca1d8b44068b62e839c085f
77e52c5fbe88d1b452c1247a924a1883
Get artwork url (logo) 100x100
class User def logo_url_thumb140 logo.try(:thumb140).try(:url) end
0
9da6e5d4af600902e43cf94c45ce4b30
552f4d51c0e4072b94d285b269a1c406
creates login session details for agent
class Accounts_Model_Login extends FFR_Model_Base public function saveUser($data) { $userData = array(); $userData['user_id'] = $data['user_id']; $userData['user_username'] = $data['agent_username']; $userData['user_password'] = $data['agent_password']; $userData['user_active'] = $data...
0
fb126e70a0529422f35c45f2fd35a10a
f0d85b9940a8da87301fe296560ab31d
Initializes the offset calculator with calculations' parameters.
{ mradoffset = new double[2]; if (segment < 12) { mradoffset[0] = pixelOffset[0] / 17; mradoffset[1] = pixelOffset[1] / 15; } else if (segment > 11 && segment < 35) { mradoffset[0] = pixelOffs...
1
f91d1a3fd5bd1d5c8fcc7c609883ca0f
837ff6f8cd38a375156982e1426c47db
Function for getting Genetic Profile Data
$response['gender'] = $gender; $response['bloodGroup'] = $bloodGroup; $response['fatherName'] = $fatherName; $response['motherName'] = $motherName; $response['dob'] = $dob; return $response; }
0
757901c803dbead9350347ae5528780c
4b32156a2af4f02aec46e3c1796014f5
Default supported formats. Use ResetSupportedFormats to over write.
class mod_workshop_portfolio_caller extends portfolio_module_caller_base public static function base_supported_formats() { return [ PORTFOLIO_FORMAT_RICHHTML, PORTFOLIO_FORMAT_LEAP2A, ]; }
1
a13c16dc2f6e7bcfd0ea0f087b7aeee3
7ee46f412558d781489b9b51b069fee1
POST /owners/:owner_id/addresses
class AddressesController def create @address = @owner.build_address(address_params) if @address.save render json: @address else render error: { message: "Não foi possível criar esse endereco :( "}, status: 400 end end
1
efc3c18da98370861ff2ce7b8948ce73
b18492fc08629af89a868bb192bb3da3
This method returns the value of the database column system_menus.ct_user
class BaseUsersTemplatesModel extends DbModel public function getDatasource2() { if ((bool) $this->_result) { if (array_key_exists(7, $this->_result)) return (int) $this->_result[7]; else parent::throwGetColException('Not set UsersTemplatesModel::getDatasource2', __LINE__, __FILE__); } else return parent::t...
0
00b5d821f3eed02e091e8706d8c8e5d8
e1ed5bb9b70ce579df03bff2f6dd455d
Display recognition feedback to user
class EventEngine(object): def show_feedback(self, correct): flip_every = self.feedback_flip_every[int(correct)] for frame in xrange(self.feedback_frames): if not frame % flip_every: self.fix.color = -1 * self.fix.color self.fix.draw() self.win.flip()
1
fe9afb4139c0482cc8435599a2154ec4
cf3fb2b4d5e3488b4c1db07cd6215749
start on a fresh line
void new_line(void) { int row, col; if (cur_row == ROWS - 1) { for (row = 0; row < ROWS - 1; ++row) { for (col = 0; col < COLS; ++col) { SCREEN_CHAR(row, col) = SCREEN_CHAR(row + 1, col); } } } else { ++cur_row; } for (col = 0; col < COLS; ++col) { SCREEN_CHAR(cur_row, col) = NORMAL_COLOR | ' '; ...
1
0f1f41512b7ba37ced2e4728a5995dae
25c7782534e56d0707e827456fab9f9f
Retourne le début de la sélection
bool DifficulteFen::getSelection_debutant() { return m_debutant->isChecked(); }
0
55262d445207f1046799fb5ae1f379e9
fead8635b407aa423fbfd042b4828812
Récupération du nombre d'enregistrements 'LogUtilisateur' enfants
{ SQLiteDataReader count = Database.GetSql("select count(*) from Familles;"); int res = 0; if (count.Read()) { res = count.GetInt32(0); } return res; }
0
03d518e1527ef7d34c28d86dca3bea24
d06382530debca15728abfb82e0fef57
Checks if all spaces are occupied
Boolean result = true; for (Integer space : boardArray) { if (space == 0) { result = false; } } return result; }
1
e8c36f6573fdf029eb250c9fe9c75d5c
b0ad59cdeeb5f492798b52ca5f5a24ec
send subscribe message to the given phone number
const SNS = new AWS.SNS(); return SNS.publish({ Message: message, PhoneNumber: phoneNumber, }).promise(); }
1
57c1f1ebca68f9127645a9f034a98295
163b33ae7bdbe30fba5303600ea8eb7b
广告类型ID => 广告类型名称
typeId_dict = { '12':'艺人', '13':'风格', '14':'厂牌', '15':'场所', '16':'电音节', '17':'事件', '11':'其他' } return typeId_dict[typeId]
0
222aa617ba7eb0ce5177cb3af730d35f
9bc8ae88d27a19a20ff02b8c682ee269
Gets the VCD variables with their id string.
if self.each_signal.any? then self.each_signal do |sig| sig.get_vars_with_idstr(vars_with_idstr) end else vars_with_idstr[self] = HDLRuby::High.vcd_idstr(self) end return vars_with_idstr end
1
1c4efd2bce3ed4aa88cac751f8ee9c24
11d284625831c6fd17fa87c7f9180988
对单一NALU的RTP包进行解包为原始的H264帧,同时输出当前Package的序列号
{ int old_index = 0; int packet_count = 0; int total_len = 0; int packet_nal_len = 0; while (src_len-old_index > 60*1024) { if (packet_count == 0) { PacketVideoFrame(src_buff+old_index, 60*1024, dest_buff+total_len, packet_nal_len); } else { PacketVideoFrame(src_buff+old_index, 60*10...
0
fe3e8e252e7819a215bb3d93690f8bd6
52b7d1cfc09a1b38054a9fe7d03cc5dd
METADATA_MASK
{ u16 smc = metadata[offset | 3] & 0x03; if (smc != 0) { partial_clear_metadata(offset, region); return CPU_ALERT_SMC; } return CPU_ALERT_NONE; }
0
b8ef5c8fc4dbaa440309726d637a3101
ca6641d4fcef52120af690c2297c4f4a
Wait for an element to appear identified by CSS.
class FunctionalTestCase(StaticLiveServerTestCase): def wait_until(self, selector, timeout=3): WebDriverWait(self.driver, timeout).until( expected_conditions.presence_of_element_located( (By.CSS_SELECTOR, selector) ) ) return self
1
a1b9dd49fc6c1d6533f3070a0370cf33
cc5f3f6019b3255a0c4d1997c7a3406a
Returns a basename for a root file that is input or output of a given step for given physics
return "%s.%s%s" % (splitext(basename(interval_file))[0], splitext(basename(peak_file))[0], (".%s" % distance if distance is not None else ""))
0
c25073693f43f1370bb422ff1682ab24
0156e9ca71f6d243c33749ea69938fed
## Retrieves a file from synapse to local disk and returns its local path
syn <- function( id, dlc = "~/data/AMP-AD" ) { synGet( id, downloadLocation = dlc )@filePath }
1
c068b548ec1affbcd9f0cfdb10e9fbb6
cd3b429295ec930ffd950741b3cdb81c
r"""Apply the sigmoid function to input. The **Sigmoid** function is defined as: .. math:: \text{Sigmoid}(x) = \frac{1}{1 + \exp(-x)}
def hard_sigmoid(x, name=None): return gen_popnn_ops.ipu_hard_sigmoid(x, name=name)
0
c0bed77bcc1a3cf977c34bbabac4ca14
0639c000ddf0230e0c980a55e08a5867
Returns a string html table with the students, categories and their notes.
class ViewComponent extends Manager private function get_courses_table_html(CourseType $course_type) { }
0
9be3ee11f2daa5e0d9502cbb5af777aa
44450449ed81e6d119b9b545f077ee50
11.Delete Pending Request(int requestId)
public class ElevatorSubsystem public boolean deleteRequest(int requestID) { return requestDB.deleteRequest(requestID); }
1
772ac9a7a069135de911f8e68671f50c
429ff9f8a9f6e295a23c4bbf911ba14c
Sets the number of hash tables.
public final class SetMaxTables extends SetMultiUserParameter public void setTables(int i) { if (i < 1) { throw new IllegalValueException("illegal %d", i); } tables = i; }
1
13d524f3085a6dbb6e045e2370d85c7f
9a57824e8198e007c76c11d8293dbfd8
Subroutine to compute moment tensor components
firstmomenttensor = numpy.zeros((3,3)) totalatoms=numpy.size(dmatrix[:,0]) temp = numpy.zeros((totalatoms,9)) for i in range(totalatoms): temp[i,0]= dmatrix[i,0]*(dmatrix[i,2]**2 + dmatrix[i,3]**2) temp[i,1]= -1*(dmatrix[i,0]*dmatrix[i,1]*dmatrix[i,2]) temp[i,2]= -1*(dmatrix[i...
1
e5a753562478b7696a5925039970a09b
1475ca5029713272be01d2c00f6bd9ab
Get authors shortcut, to get Authors from DatasetSubmission.
def getZipAuthor(): return zipAuthor
0
58b7ca310e68d9dcbd58f62dd6bcfcc4
be0d33c7b53872fa1ab439e7cde11e70
Returns the Locked User message for given username and password
{ SecUtil::checkUserName($userName, 'userName'); $reason = null; $query = sprintf('select locked_out, locked_out_message from %s where user_name = $1::character varying(20)', self::getQualifiedTableName('users')); $db = self::getMembershipDatabase(); $list = $db->loadArray($query, array($userName)); if (co...
0
424c01f66abef5c0c2a22f1cb2bf837a
a2f146410e8d67bb46ccac4288f64ef5
Фунция очистки слайдера
$(".err_shtapik").css('display','none'); if ($("#slide_shtapik").css('top') == '-280px'){ $("#slide_shtapik").animate({top:"-1px"},300); $("#select_shtapik").css({ 'border':'none', 'backgroundColor':'#4d90fe', 'color':'#fff', 'box-shadow':'none', '-webkit-box-shadow':'none', '-moz-box-shadow':...
0
45eaa55e495ff00cd61c85b0647fc233
009ff0bebe69abe6f7351fbdc294a1be
Metodo para ilustrar resultados de calculate() en la UI
String res = ""; res += "+: " + addResult.toString() + " "; res += "x: " + scaleResult.toString() + " "; TextView tx = (TextView) findViewById(R.id.result); tx.setVisibility(View.VISIBLE); tx.setText(res); ((TextView) findViewById(R.id.val1_desencriptado)) .setText(firstValueRetrieved.toString()); ...
1
dca6c1d65f91a7b7d5211ce710f27aea
e899d978a7d41841d05b1851f8e589dc
Add random prefix to the filename to prevent filename duplicates.
class Metric: def _add_prefix(self): length = len(self.key) path = str(self.local / f"{self.target}/{self.filter}/") files = os.listdir(path) [os.rename(os.path.join(path,fil),os.path.join(path,f"{self.key}_{fil}")) for fil in files \ if fil.split("_")[0] != self.key and fil[-3:...
0
c84732c1578bd9d13a79fa82fe686d51
d420bbaa5a9e9b3313609fbb7f0854ef
Devuelve todas las comidas
{ try { $meals=Meal::all(); $response["data"]=$meals; $response["status"]=true; return response()->json($response); } catch (Exception $e) { $response=[]; $response["error"]=$e->getMessage(); $response["status"]=f...
1
754f32b54d88e4817adeed287f991e23
20556f62eecf74a2dea6ee1808be68a8
攻击力计算加成值,返回一个数组,这个数组应该是乘算
local laArray = { 0.30, 0.30, 0.30, 0.10}; if (voProductionData.ManpowerTotal < 30 and voProductionData.LandCountTotal > 30) or voProductionData.ManpowerTotal < 10 then laArray = { 0.0, 0.50, 0.35, 0.15}; elseif voProductionData.Year <= 1939 and not(voProductionData.IsAtWar) then la...
1
b0fc23f98662ddaeb672a714d69d37d8
f542c7a00745457a5faeb795ca06db11
Retourne, sous forme de chaine de caractère HTML, le chemin jusqu'au block.
{ $screenshot_file = array_merge( glob($this->get_block_dir() . "/*.jpg"), glob($this->get_block_dir() . "/*.jpeg"), glob($this->get_block_dir() . "/*.png") ); if ( $screenshot_file && is_array($screenshot_file) && count...
0
9adc1cdf7c1a0dbc0bac739eae3db046
d3c02197ece031f24d7561b812e706f7
Converts different boolean strings to an integer value
public class Configuration public static int attrToBoolean(String attr) { if (attr == null) { return 0; } if (attr.equalsIgnoreCase("yes")) { return 1; } if (attr.equalsIgnoreCase("true")) { return 1; } if (attr.equalsIgnoreCase("1")) { return 1; } if (attr.equals...
1
9ee466e00a1e6b0ad4563ad9152d7989
a884a8042785f7eb0cbc09f92681e899
Renders smtp from field
{ $sBody = $this->fieldBodyText; $oText = new TCMSTextField(); $oText->content = $sBody; $sBody = $oText->GetPlainTextWordSave(null, $this->aMailData); reset($this->aMailData); return $sBody; }
0
ebca60f1a977e1827361672c16a42f0f
969231ffe35635b24d23c7a8548f7590
Sets the value of the '{@link iso.std.iso.is._13584._32.ed._1.tech.xml.schema.ontoml.APOSTERIORIVIEWOFType#getCorrespondingProperties <em>Corresponding Properties</em>}' containment reference. <!-- begin-user-doc --> <!-- end-user-doc -->
void setCorrespondingProperties(CORRESPONDINGPROPERTIESType value);
1
923ad768382bf03ea4109c7136a1064d
067305d5126aaa3c5814b7bb8a364022
first element = size
def size(w): return w[0]
1
64946d0ec46d3e5c3fcf369830a7f79f
84b26053690b8b88d17ef864ca7224f5
用户输入标签的时候,自动下拉提示
if($this->validation->is_ajax_request() == FALSE){ echo "Error: access forbidden"; return FALSE; } $this->load->model('Tagging_model','Tagging'); if(!$this->input->post('tag')){ return FALSE; } else { $tag = $this->input->post('tag'); } $matches = $this->Tagging->search_tags($tag); if(!$matc...
1
8239d5ce1f0f9492363a233c608b6010
ddc1f191094721f359cb330ed0e4f4f1
r"""Check whether a given function is the zero function. This checks the identity of the given function with a particular zero function. This can be useful if expressions/evaluators actually use/return this _zero_function() function object when they know this is correct.
class Polyhedron_ZZ(Polyhedron_base): def _is_zero(self, x): return x==0
0
01bf09ccdada6ed563750dc2148bca9b
839909ffb8d3244073e09a1a22f78d1e
Atualiza os arquivos com as informacoes dos temas das proposicoes. Esta funcao nao tem custo alto de execucao, no entanto nao deve ser executada se a lista de temas ja estiver registrada dado que o mesmo nao muda com frequencia
if self.arquivo_etapa1 != self.__arquivo_etapa1: self.data_upload_etapa1 = timezone.now() if self.arquivo_etapa2 != self.__arquivo_etapa2: self.data_upload_etapa2 = timezone.now() if self.parecer1_etapa1 != self.__parecer1_etapa1: self.data_upload_p1e1 = timez...
0
b49b080132e0ec5019174b07a3b0b02e
af8a212e65a0ea55532da26fb0506386
Removes the right child of this node.
{ if (right == null) return left; else { right = right.removeRightmost(); return this; } }
0
08177b5e7ef3a54776147b81cab89fb2
d29d9c1d72c3ee70d42159b2a6f48949
Install project dependencies using poetry.
if os.path.exists(os.path.join(self.doc_dir, 'requirements.txt')): pip_out_log = BytesIO() pip_err_log = BytesIO() pip = sh.pip.bake(_cwd=self.doc_dir) pip.install('-r', 'requirements.txt', _out=pip_out_log, _err=pip...
0
52fb4813c4a29213e16c2532ed12ea90
79f04d52577b3680946cd6071a1d40c0
Helper function for TSEL filter. Calculates the lift value for every node in a given graph.
node_feats: Tensor ) -> Tuple[Tensor, Tensor, Tensor, Tensor]: assert sorted_dist_inds.ndim == 2 assert (sorted_dist_inds.shape[0] == sorted_dist_inds.shape[1] == node_feats.shape[0]) knn_graph = sorted_dist_inds[:, 1:se...
0
add8e1db3dd22751494a8af559f8eb87
5d527b33f47889f9ac18eed4bdefa74a
Affiche le formulaire d'envoi de musique
class MusicController extends Controller public function create() { return view('music.formmusic'); }
1
14575feafb960e114630711a3168b60f
02b9a81728f215c4d75064e074bb4ec5
servlist : servid
SERLIST = Sel_backend(backid) if SERLIST: ser = servers.split(',') Write_file(backid, ser) return True else: return False
0
aca6a46d43c291a3ce6cd647158d2ef4
951e1b91f6cb34169de530780e33c104
Enables all SSL protocols, if previously disabled.
namespace SalesForcePartnerCnn public class SalesForceHelperPartner public static void SfProtocolConn() { ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12 | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls; }
1
d86aa95cae1fce7fdc53cf241b13a011
181195a38ef5ecd0615e1d72f41730d9
A command which replies with a message.
public class CommandReply public static CommandReply ofReply(String command, MessageChannel channel, EmbedBuilder message, long targetMessageId) { return ofReply(command, channel, new MessageBuilder(message).build(), targetMessageId); }
1
616437fec1b6f3b03c4ba54a255a62a2
bb2462f27d9614f283f57bd4dbeb06b8
Get list of defined public methods.
class view extends osmXml{ public function getNamesOfPublicMethods(){ return array( "viewNow" ); }
1
4767275b507be0c1039d8ea895812114
4e1dac7b4097eee49d7284f6bfed3703
測試回傳層級內使用者資料帶入不合法的顯示筆數
class LevelControllerTest extends ControllerTest public function testGetLevelUsersByInvalidMaxResults() { $this->setExpectedException( 'InvalidArgumentException', 'Invalid max_results', 150610005 ); $parameters = [ 'first_result' => 0, ...
1
ac4755b28bcdb5ff4815610a57f866e3
5db8e9589c9a21ca419cb15b8961d8d2
Resetting procedure to recover from STC locking feasibility issues.
public class KVStoreImpl implements KVStore, Cloneable private void tryResolveSSLHandshakeError() { final String storeName = dispatcher.getTopologyManager().getTopology().getKVStoreName(); RegistryUtils.resetRegistryCSF(storeName); final RepGroupStateTable repGroupStateTable = ...
0
060f44dd817f17629915a205d85d473a
8e9ff4ff297b7c436910d8f1f2ceeeb2
Sets a list of predefined values that must be shown in the combo.
class TRequiredListValidator extends TValidator function setRequiredSelections($value) { $this->setViewState('RequiredSelections',$value,''); }
0
5f43f0493dc70b767e407e33e5de8198
e0cf378026a8bb83965cbedcb339faca
Allocates a position which can hold a coordinates in objective or display CRS.
class Point extends Geometry public static function xyEmpty(int $srid = 0) : Point { return new Point(CoordinateSystem::xy($srid)); }
1
751520678250fc04d1d3c2f5be58c872
7c5002174b1ed365d87be47d81aa63ee
Valor Vendido no mês
public class FaturacaoProduto implements Serializable{ public int getQuantidadeVendidaP(){ int count = 0; for(int i = 0; i<12; i++){ for (int j = 0; j < 3; j++) { count += this.quantidadeP[i][j]; } } return count; }
0
ee2fe6c804de97a1456b5e86e7d73fb3
593a9efd6b014751cdb480c4915a578f
We clone $config so that if the same Configuration object is used for multiple API instances, the host changes made in the ::contentProvider(), ::marketplace(), and ::supplier() methods don't affect the other API instances.
class SortersConfig implements EntityConfigInterface public function __clone() { $this->items = ConfigUtil::cloneItems($this->items); $this->fields = ConfigUtil::cloneObjects($this->fields); }
1
c5a6649037486dfd640b3064e54b3d4b
9f7d4836b4bb355019f9ae4666170b41
@brief Grab FSK data
{ static char prev_byte = 0, current_byte = 0; if (INTGetFlag(INT_SOURCE_UART_RX(SPEKTRUM_UART))){ while(U3STAbits.URXDA) { current_byte = UARTGetDataByte(SPEKTRUM_UART); if ((current_byte == 0x01) && (prev_byte == 0x03)){ SPEKTRUM_rawData.index = 0; ...
1
bfe33cbd20d64ea081094d5588068581
32b8788eccff0ff0d6dd0a1b32b83249
Returns :py:class:`~.Delete` instance and passed arguments are used for list of tables from which really data should be deleted. But probably you want to use :py:func:`~.delete_from` instead.
def delete(*tables): return Delete(*tables)
1
b6d4ace667f9b4378a3a15f8d1a7249b
b6a0d9b88626ea57f69bc323c4a38d7d
Create an instance of {@link DeleteSystem }
@XmlRegistry public class ObjectFactory public DeleteUnitRequest createDeleteUnitRequest() { return new DeleteUnitRequest(); }
0
74c8147598d9fa4d4643603fad2edc39
242915e63c6c41dc92376bb588470055
Returns a dict of resource id mapped to data product id based on hasSource association.
source_info = get_using_identifier(identifier, format=FORMAT_FULL_RECORD) if source_info.data_product_metadata_schema: return source_info.data_product_metadata_schema else: return []
0
7eff1424ebb73cac39cc1b927515bc26
ee97bdf5aa6e8b4773598e27b82058f4
exitsIncidenciaAlumnebyData --> Indica si existeix una incidència per un alumne i dia Per justificar faltes a futur.
$c = array(); $fechas = db_query("select fecha from citas"); while($fila = mysqli_fetch_array($fechas)){ $fecha = strtotime($fila['fecha']); $anio = date('Y', $fecha); $mes = date('m', $fecha); $mes = ltrim($mes, '0'); $dia = date('d', ...
0
fb472cdecdeefb9aa777987d0dc76d0c
67399ae4f31723f3bcd7a03216beb5de
Delete all video items in the database
public class SqliteManager public boolean deleteAllFromLocalVideoType() { return sqLiteDatabase.delete("local_video_type", null, null) > 0; }
1
6480fbc5dc1f004c1db1f72750b20653
e8c6443767f3536df2c2a5a99b843146
取得运行时MyClass的属性
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); MyClass myClass = new MyClass(); MyClass2 myClass2 = new MyClass2(); myClass2.MyProperty = 12; myClass.MyProperty = new Lis...
0
ea6c54993c3e50bd9984e6e0ebf9ca4f
6973134decbc0be9b0c47a69072202fd
Write the chemistry function declarations.
WriteVarDecls(FILE *file, routine_t *rt) { u_int i; fprintf(file, "\tRequest *In0P = (Request *) InHeadP;\n"); for (i = 1; i <= rt->rtMaxRequestPos; i++) fprintf(file, "\tRequest *In%dP = NULL;\n", i); fprintf(file, "\tReply *OutP = (Reply *) OutHeadP;\n"); if (rt->rtNumReplyVar > 1) fprintf(file, "\tunsigned ...
0
acf4a59c5bf6a967764e0d7263238a2e
4e931c4a2e7f17c80729991f4e13b2c6
Send the reboot command to any cRios connected on the network -> Extracted from https://github.com/rbmj/netconsole, license unknown
{ var port = OpenPort(); try { port.Write("\r\nreboot\r\n"); while (true) { var line = port.ReadLine().Trim(); if (line == "OK.") return; } } finall...
1
0e081a731a32500d4c6e60ac28406fd8
6fe029acaae27ea34282210f11539b57
Esta funcion es llamada por el boton de decodificacion. Ademas esta funcion crea un hilo para que la ventana que usa openCV para mostrar la imagen y no se cierrren todas las ventanas creadas.
class Ventana(QtGui.QDialog, Ui_Form): def __aceptar(self): self.thread.setData(self.__plugin, self.__notificador, self.__imagenesIn, self.__imagenesOut, self) self.thread.start()
1
9c2b87819843d80d0a145a2f6c3148ea
18c9b8466fdfb43c8e212a0ea712b349
Returns the meta object for the reference '{@link edu.cmu.sei.aadl.errorannex.ErrorModelImplementation#getErrorModelType <em>Error Model Type</em>}'. <!-- begin-user-doc --> <!-- end-user-doc -->
EReference getComponentErrorModelProperty_InplaceErrorModelType();
0
f8ac7c6e8e123ae945f603191fff2fb4
b6463c634034bb2d1a2b595131849d6a
Forcedfully processes a campaign
class Campaigns extends SendCampaignSMS public function running() { $this->status = self::STATUS_PROCESSING; $this->run_at = Carbon::now(); $this->save(); }
0
33c79d2aea89ae62f27be03514f00c60
a6bfcee5a249f1d483d882d83595e209
gibt die Rechnungsadresse zurück.
public String getAdres();
1
6f3ae772ee01ae1b3d1cbda3d652d2fa
f7d8bdca59b5f597dfb2fe4288e6bc60
PUT /forums/:id
forum_id = request.params["forum_id"] name = request.json_body['name'] description = request.json_body['description'] try: forum = bb.get_forum(forum_id) except ForumNotFound: request.errors.add('body', 'not_found', '%s not found in database.' % "category")...
1
d2278a41dd7da18f05528cfb5d6bb35c
122163b7e2735fe67061f31f82cfad8c
Opens a standard text box.
void textBox();
0
a5b9e73748b2fadbfb80a1420b76fde6
f0ba0a4f782fab290b93e501d7cd31f2
해당 systemID의 로그파일 핸들을 반환한다.
{ String[] r = new String[nLogFil]; System.arraycopy(SimLogPat, 0, r, 0, nLogFil); return r; }
0
ca8ad5ea0db600d300ccf55185962e65
8524e3e6768a043f4710d6a79bf454a3
heaves all elements from stack, saving to disk if necessary
int my_stack_write(struct my_stack *stack, char *filename) { if (stack == NULL) return -1; struct my_stack *aux_stack = my_stack_init(stack->size); int counter = 0; int writtenBytes; if (aux_stack==NULL) return -1; struct my_stack_node *aux_node = NULL; struct my_stack_node *index = st...
1
3332c49ecc3f0d2feb4f5bce6b2e01aa
6c70e3e622f6090155e561cfd8ac1523
建立无向图的邻接表结构
void createDG(Graph &G){ scanf(&G.vexnum,&G.arcnum); for(i=0;i<G.vexnum;i++){ scanf(&G.vexs[i].data); G.vexs[i].firstarc=null; } for(k=0;<G.arcnum;k++){ scanf(&v1,&v2,&w); i=LocateVex(G,v1); j=LocateVex(G,v2); if(G.vexs[i].firstarc==null){ p=(A...
0
44b6a1ef29eab14a1199501de270cf29
12a3274c563acb46c65519bb40badfac
Decrease quantity for the movie based on the given quantity
this.quantity -= quantity; if(this.quantity <= 0) { this.quantity = 1; } this.triggerQuantityUpdatedEvent(); }
1
725b9771ac333699cbbcbcfac19bae74
0c52e2211a885ce2d2157aab3f550803
绑定财富排行
public class RankServiceImpl implements RankService private void wealthRankStat(long statTime) { List<User> users = userService.listOrderByCopperDesc(0, 10); List<WealthRankBO> ranks = new ArrayList<WealthRankBO>(); for (int i = 0; i < users.size(); i++) { WealthRankBO bo = new WealthRankBO(); User user = u...
1
cf64aefac133f2e5edd2e1f71845fda0
86157508dfa3abaf9ad7c05ed5a3aa0c
ファイルを読み取り、デリゲートを使用して各行を処理するメソッド
{ using (StringReader reader = new StringReader(fileContent)) { string line; while ((line = reader.ReadLine()) != null) { handler(line); } } }
1
d078477ab188a99b29ff120e954c0c2c
9263db875f4ad4f74a5392fbb91e53e9
turns on the turbo
void setTurboOn();
1
7d36b4cd6736657c934c37ab8a860431
80c1ce42e0e59dc113aa9e4beef02c06
Restore the frames if they were minimized
namespace Novell_Mass_Attribute_Changer public class Main_Screen : System.Windows.Forms.Form private void RestoreMe() { if (!this.Visible) { this.Visible = true; } if (this.WindowState == FormWindowState.Minimized) { this.WindowState = FormWindowState.Normal; } this.BringToFront(); }
1
7339fee03fd2855a2b29e80eb4700803
bcd1367a3925c002f84520ca31fb8e7a
Exception if template already exists in database
class ThemeRepositoryTest extends LaranixTestCase public function testAddThemeThatExists() { $this->expectException(KeyExistsException::class); $this->repository->add($this->getSettings()); }
1
563a7894add7f291446f8969be48308e
20ab9caccb5241e236b4234749ea292f
Returns True if the Kalimba processor is clocked.
class AbstractPort(AbstractBus): def is_clock(self): raise NotImplementedError
0
18f5cc8fe4fca1c71576165f09008d10
61af092df90b9bd99474359aabe267c9
code for picking an input cluster (#1)
function clusterAssignment(){ }
0
2dc155743f60f35ca59f5c8297dd693e
b1aa75a154a6021dfb199d5ec43e9586
Display list of employees
{ return inertia('Employee/Index', [ 'employees' => Employee::all()->map(function ($emp) { return [ 'id' => $emp->id, 'fname' => $emp->fname, 'lname' => $emp->lname, 'name' => $emp->user->name, ...
1
53c9b5fb124b3f9efe773e746a63c996
69b82ae7303bd8300dbcea2a582fdb62
Create an IP Pool Creates a new IPv4 or IPv6 address pool. Required parameters are allocation_ranges and cidr. Optional parameters are display_name, description, dns_nameservers, dns_suffix, and gateway_ip.
class PolicyNetworkingIPManagementIPAddressPoolsIPPoolsApi def create_or_patch_ip_address_pool_subnet_0(ip_pool_id, ip_subnet_id, ip_address_pool_subnet, opts = {}) create_or_patch_ip_address_pool_subnet_0_with_http_info(ip_pool_id, ip_subnet_id, ip_address_pool_subnet, opts) nil end
0
094b8c670308f7b2e1f552d47b55e53d
8a59e6189704a0a8af24610e528facbe
write_byte(val) Perform SPI Write Byte transaction.
CyFxSpiWriteByte ( uint8_t data) { uint8_t i = 0; for (i = 0; i < 8; i++) { CyU3PGpioSetValue (FX3_SPI_MOSI, ((data >> (7 - i)) & 0x01)); CyU3PBusyWait (1); CyFxSpiSetClockValue (CyTrue); CyU3PBusyWait (1); CyFxSpiSetClockValue (CyFalse); } return CY_U...
1
c994ee6c720f4e7b3972a7c687eca56a
990eb6238b08f050a4ed5930247860cd
営業活動画面の登録ボタン押下時の処理を行います.
PositionRegistBeanInterface regist = platform().positionRegist(); PositionDtoInterface dto = regist.getInitDto(); setDtoFields(dto); regist.insert(dto); if (mospParams.hasErrorMessage()) { addInsertFailedMessage(); return; } commit(); addInsertNewMessage(); setEditUpdateMode(dto.getPositionCode(...
1
2ea94aed09ccdeb5a4b27519e59f318b
970561b4f2c310fbfdd2583b5ddccd43
Gets Collaborations for specified Artist.
Set<Collaboration> collaborations = graph.get(actor); if (collaborations == null) { return new Collaboration[0]; } else { return collaborations.toArray(new Collaboration[0]); } }
1
7944c5428e2d11e0d98a60f292d68053
22d497536d7b96fc79c5ff3010ec6fb5
Load selected collection point for given shipping address ID.
class SnapshotInformationManagement private function collectAddressData(CartInterface $quote) { $shippingAddressArray = []; $shippingAddress = $quote->getShippingAddress(); if ($shippingAddress->getPostcode()) { $shippingAddressArray['id'] = $shippingAddress->getCustomerAddressId...
0
e3dc6286bc1c253f516f43f70c2581a8
e790c158c68aabc3aa76242d34b41e54
makes the checkpoint animation fade in and then fade out
local fadeOut = HFLFadeOut:create(0.25) local delayTime0 = HFLDelayTime:create(0.2) local fadeIn = HFLFadeIn:create(0.25) local seq = HFLSequence:create({fadeOut,delayTime0,fadeIn}) return seq end
0