query_id string | corpus_id string | query string | code string | label int64 |
|---|---|---|---|---|
b5adfb3bf638f5a6e99d3c29fdb2c01d | f2f15427befe7f0601f1a231ee0062d8 | 隐藏出牌结果 | function hideTingCards()
for index, card in pairs(getSelfCards()) do
card:setTingHint(false);
end
end | 0 |
de331f5dc895d0fa6548e73259c02b73 | ab705bb63c34756e7871bf584771663e | Append the given objects to a file, separated by tabs | {
string dataFile = filename;
using (TextWriter tw = Helpers.AppendStreamWriter(dataFile))
{
if (labels != null)
{
tw.WriteLine(string.Join("\t", labels));
}
foreach (var line in data.Select(x... | 1 |
0c9cb55a18060060b245866fe196e099 | 14d14c892fec9842b73abdef67b9614a | Set the find form service | class FindForm extends AbstractFindForm
public function init(): void
{
parent::init();
$this->setDtoComponent($this->getKeywordComponent());
$this->setActiveRecordClass(KeywordActiveRecord::class);
} | 0 |
4080ea8aa835c9e176e888cf6f81c3da | b8fc1ed73c97d4768d65e042b54c43ab | @brief Called when RR_GMM_GPRS_MS_RA_CAP_IE_IND is received from GMM | {
TRACE_FUNCTION( "ctrl_rrgrr_data_ind" );
switch( GET_STATE( CTRL ) )
{
case CTRL_IN_PROGRESS:
switch( grr_decode_rr((T_MSGBUF *)(&(rrgrr_data_ind->sdu))) )
{
case D_PDCH_ASS_CMD:
sig_ctrl_tc_pdch_assign_received (rrgrr_data_ind);
break;
case D_CHANGE_... | 0 |
67cfe1ad5fb11d8b5c7df78fc0f7ae3d | 323543c4af4562bef9ef56d0a423fee9 | Gets the dependencies of a given component's type, according to a given attribute type, and raising a <c>DependencyException</c> exception on dependency error. | namespace AlephVault.Unity.Layout
namespace Utils
public static class Assets
public static void CrossCheckDependencies<TargetType, DependencyType, A>(TargetType[] componentsList, DependencyType dependency) where A : Depends
{
CrossCheckDependencies<TargetType, DependencyType, A, ... | 1 |
a7dae45e03c3d11ff2c60c3eff11eb5b | e3d446c7b4b45366159e33a0ce57b15a | Constructor of the CouchdbClient class | self.host = None
self.port = None
self.collection = None
self.db = None | 0 |
f2184a923fc16a595c8059d7a6aa23e6 | f9830ea6f1ac86af5b1c136a1b85dad8 | delete radiative vector potential diagnostic | {
delArr3(ids->rhon, grd->nxn, grd->nyn);
delArr3(ids->rhoc, grd->nxc, grd->nyc);
delArr3(ids->Jx, grd->nxn, grd->nyn);
delArr3(ids->Jy, grd->nxn, grd->nyn);
delArr3(ids->Jz, grd->nxn, grd->nyn);
delArr3(ids->pxx, grd->nxn, grd->nyn);
delArr3(ids->pxy, grd->nxn, grd->nyn);
delArr3(ids->p... | 0 |
0f4b544ca312bcf9a4cf14f4e886dffa | 8767185ef83809abf5b2cdefab0e9a81 | Returns the meta object for the containment reference list '{@link com.ibm.ccl.soa.deploy.core.DeployModelObject#getAnnotations <em>Annotations</em>}'.
<!-- begin-user-doc --> <!-- end-user-doc --> | EReference getRelation_Annotations(); | 1 |
e7ada238c95ab9e7b3d51872bbf8daf8 | d4bc422cf784387d0b12f3dc03712fb3 | @brief Move to the next OLED screen | {
if(current_screen_pos + SHIFT > BUFFER_SIZE)
return;
else
{
current_screen_pos += SHIFT;
current_page++;
copy_to_screen();
}
} | 1 |
2492d766123f3e30a0c7599ec9bd01ad | 7a30851e32f73adf716bc6c3a12a39d0 | @brief Function for handling pstorage events. | static void pm_evt_handler(pm_evt_t const * p_evt)
{
ret_code_t err_code;
switch (p_evt->evt_id)
{
case PM_EVT_BONDED_PEER_CONNECTED:
{
NRF_LOG_INFO("Connected to a previously bonded device.\r\n");
} break;
case PM_EVT_CONN_SEC_SUCCEEDED:
{
NRF... | 0 |
c34e6c731b86fc80de8f9d0007d4ddff | 7a9719a17368830247a724712dbf3a15 | function called by filepath.Walk | filepath.Walk("./", func(path string, info os.FileInfo, err error) error {
fmt.Println(path)
return nil
});
} | 1 |
76acf759114b820d85b62367a124ffec | 4a5f6f2ca53241235f9d0bc5d3d9ccfc | 拷贝特效文件夹 | public static class DoCreateText{
public static void CopyFolder(string srcFolderPath, string destFolderPath)
{
#if !UNITY_WEBPLAYER
if (!IsFolderExists(srcFolderPath))
{
return;
}
CreateFolder(destFolderPath);
srcFolderPath = GetFullPath(srcFolderPath);
de... | 1 |
890e7899b4ace76c2222e45803e7944f | dfa341790bc71287dd772e1654464c60 | Test que comprueba que se marca pedido como no recibido sin fallos | id = 1
email = 'maximiliano@boscovich.com.ar'
respuesta = pedido.usuarioRegistrado(id, email) | 0 |
e86c9d6888b06a1c69ae7f137a5983b5 | 77219d1f520ac8a4c0d3b247783dd5bf | Asettaa arvon riippumattomalle muuttujalle. | public class Rivi
public void aseta(int indeksi, Color vari) {
rivi[indeksi] = vari;
} | 0 |
665f86acca8930aae2ab0a36351df630 | c295528ef10e0fba164bafa9ac041d6b | 分享单张图片到微信好友 | WXImageObject wxImageObject = new WXImageObject(bitmap);
WXMediaMessage msg = new WXMediaMessage(wxImageObject);
msg.mediaObject = wxImageObject;
Bitmap thumb = BitmapFactory.decodeResource(context.getResources(), R.mipmap.ic_launcher);
msg.thumbData = bmpToByteArray(thumb, true)... | 1 |
4172bb02fa43be9fa22ffd2e05dfd4cd | b29d2827e12e798321e71aae3bd824f1 | Convert the given dictionary to a message of type message_type. | def serialize_message(*args, **kwargs):
pass | 0 |
63b41ca1034d6ad0e66590055918ca8b | 71d5bf99ea3ee903c644d53ad16f8f74 | 针对where子句,要在前面插入连接符
一般第一个元素不加,但跟在分组后面的第一个元素要加 | public abstract class SqlCommOperImpl implements SqlCommOper{
private String concatSqlWhere(String sql,String whereStr){
String str = sql;
if(whereStr != null){
if(startWithKeyword(whereStr,"where"))
str += " "+whereStr;
else
str += " where "+whereStr;
}
return str;
} | 0 |
6b4e4333d56f5f86c5417554c78990ac | 638fc2808f1ecc562b3c323596fdbca6 | 各列の値を列平均から引く | def mean_col(col):
value_col = create_value_col(col)
return round(mean(value_col), 2) | 0 |
fdbd07d7ab025d17119ff81ef4013935 | 8a42c8eb42202b0707a619572f1b65c6 | Sets the property keys | namespace UtnEmall.Client.DataModel
public class UserActionClientDataDataAccess
private static void SetProperties()
{
properties = new Dictionary<string,Type>();
properties.Add("timestamp", typeof( System.DateTime ));
properties.Add("idUserActionClientData", typeof( int ));
properties.Add("actionType", t... | 1 |
001cb5a18734c5aec7fefe2d8f9a4c23 | 2a8bf9f2bf15bd804c5cecd90ee4746d | Обновляет таблицу связки пользователей на экзамен (добавляет , удаляет отмеченных) | {
$filterOptions = new Options($this->arResult["GRID_ID"]);
$filterOps = $filterOptions->getFilter();
foreach ($filterOps as $key => $value) {
if (empty($value)
&& ($key !== Gradebook::ATTEMPTS_CODE . '_from')
&& ($key !== Gradebook::ATTEMPTS_CODE... | 0 |
dee7af352baf78a347f6f8984eded3d1 | 78421e7ca4b382c45294ae523e0144b9 | 设置季节开课时间段 | {
if(!isset($input['time_list'])){
return $this->addTimeSection($input);
}
$this->startTrans();
$bid = intval($input['time_list'][0]['bid']);
$season = safe_str($input['time_list'][0]['season']);
$week_day = intval($input['time_list'][0]['week_day']);
... | 1 |
14ffb387c5b18de672cbc126afbdf033 | a5be33214db05ba33e74ebceed436b73 | Returns top channels | $channels = $this->createQuery()
->Where('publish = ?', 1)
->execute();
return $channels;
} | 0 |
3c4c491b4379ec9dc3c7a55b667ce428 | 87fb1e39da0d298a20a8500ac2984b6b | No operation in case of no support for DBG_LVL_MAC_FILTERING | soc_fe3200_drv_test_brdc_blk_filter(int unit, soc_reg_t reg, int *is_filtered)
{
SOCDNX_INIT_FUNC_DEFS;
*is_filtered = 0;
switch(reg)
{
case BRDC_FMAC_AC_ASYNC_FIFO_CONFIGURATIONr:
case BRDC_FMAC_AC_SBUS_BROADCAST_IDr:
case BRDC_FMAC_AC_SBUS_LAST_IN_CHAINr:
case BRDC_... | 0 |
fbb0db985440261262a7f2be2ecfd91d | c4cc3ea9b93edb0a9408af92872cfcb2 | 是否删除成功 | public class DeleteDatabaseResponse extends SdkResponse
public Boolean getIsSuccess() {
return isSuccess;
} | 1 |
7ff3ebbed3e3f48bb3d0ca28c1ab442a | 7fa9d51c7bc34655aff2e0a5b8eaccca | Retrieves a queued task from mock queue. | try {
return TASKS_QUEUE.take();
} catch (InterruptedException e) {
e.printStackTrace();
return null;
}
} | 1 |
7e0148ee5eb85f40b7891dc19fb02c53 | 1f45b49cc35eb519c8b5b70cda12ac40 | dá dano equivalente a (vida máxima total - vida atual + 10% do dano) em uma distância igual a distância de especial acumulada.(após o ataque, zera a distancia do especial e reduz vida máxima para 1) | {
float resultado = Mathf.Exp(-2 * Mathf.Log(10) * tempo / tempoDecaimento);
if (resultado > 0.01)
{
return resultado;
}
Destroy(gameObject);
return 0f;
} | 0 |
8a192d4d11b04a8e94d68bd8ee9916c0 | 12b9ce4c16058792267573cd6791b7ab | Reads a pixel from a pixel data array | if(n < _led_cnt) {
uint8_t *p = &pixels[n * 3];
return ((uint32_t)p[rOffset] << 16) |
((uint32_t)p[gOffset] << 8) |
(uint32_t)p[bOffset];
}
return 0;
} | 1 |
ff4ee79ff33b675eb2510dab4664468e | 8e49571797da0a9427888719c09b8dc3 | Jacobian of right-hand side of model | def Fx(t,x,u):
jac = np.zeros((x.shape[0],x.shape[0]))
jac[0,2] = -u[0]*np.sin(x[2])
jac[1,2] = u[0]*np.cos(x[2])
return jac | 1 |
4976a93ec4400598f67736472f4954cb | afd8689de3e73341600aa311052c6e1d | opens daylist file and gets list of all possible days to optimize | {
ListOfDays listOfDays = new ListOfDays();
string jsonString = await LoadJsonStringFromFile(_mealsFilename);
if (jsonString != null && jsonString.Length > 0)
{
listOfDays = JsonConvert.DeserializeObject<ListOfDays>(jsonString);
}
... | 1 |
dad39df6a9d967ef8b85888daf92406c | 0d6fc36d9f233b351b1faeecaa864772 | Potpisuje plain tekst danim certifikatom | {
int r = X509_TextDump(outputFile, certFile, 0);
return r;
} | 0 |
0260bef8acff190440175b7e46ea7971 | ca2a8e140733ae602247cf6c71e2b7c9 | Can get a 3x3 rotation matrix version of a matrix. | def MatrixLog3(R):
acosinput = (np.trace(R) - 1) / 2.0
if acosinput >= 1:
return np.zeros((3, 3))
elif acosinput <= -1:
if not NearZero(1 + R[2][2]):
omg = (1.0 / np.sqrt(2 * (1 + R[2][2]))) \
* np.array([R[0][2], R[1][2], 1 + R[2][2]])
elif not NearZero... | 0 |
a047f424fd9ce328932016229f8898a5 | 23e6a92d60c28fbe7d63828d316d3678 | Convert raw data into a series of consecutive MindRecord \
files after the raw data is verified against the schema.
Note:
Please refer to the Examples of :class:`mindspore.mindrecord.FileWriter` . | examples, label_list, max_seq_length, tokenizer, output_file):
schema = {
"input_ids": {"type": "int32", "shape": [-1]},
"input_mask": {"type": "int32", "shape": [-1]},
"segment_ids": {"type": "int32", "shape": [-1]},
"label_ids": {"type": "int32", "shape": [-1]},
}
w... | 1 |
8d9f8a94f7f7b47acfe51cf1acb92956 | a9dbb90bd0abdcec0a8a12c3ca666fe1 | Creates a button and adds it to the list of buttons stored by ButtonGroup | {
GameObject newButton = Instantiate(buttonPrefab);
newButton.transform.SetParent(toggleGroup, false);
RadioButton radioButton = newButton.GetComponent<RadioButton>();
radioButton.settingRadioButtons = this;
radioButton.radioID = buttons.Count;
... | 1 |
0bcb555beb50e413bb0ede333011f353 | d1ffde86d8c0f7beb929ee7a54af3acb | menu option: Find all employees by dep name | @Repository
public class Employeedao
@SuppressWarnings("unchecked")
public Iterable<Employee> getEmployeesByDepartment(String input) {
return em.createNamedStoredProcedureQuery("procedure-two").setParameter("emp_department", input).getResultList();
} | 1 |
ef57db3d5d88f2b65b8811707099a0c2 | dc3781adbf096bd04effe808ba78e590 | When called with valid parameters, a validation success should
be returned. The provided ticket should then be consumed. | (status, reason, service_ticket) = self.validate_ticket(proxysok=proxysok)
if status == 'OK':
return CASResponse.auth_success(service_ticket)
else:
return CASResponse.auth_failure(status, reason) | 1 |
4f302c4c0391db7b7943dc20ba861139 | 7e3d9ff39d032e1c809982c1d50d01ab | 重生,播放idle动画 | {
isDie = false;
anim.Play("idle");
isJump = false;
isContinue = true;
} | 1 |
eb397958a6865a2670fded360752a7ce | 5002cb62dd54b5b745bdf49e064eeb06 | Remove an idle callback.
Returns True if the handle was removed. | class UARTParser():
def del_line_callback(self, cbid):
if cbid in self._str_cbs:
del(self._str_cbs[cbid])
return True
return False | 1 |
472b95512e592ef83ec7a8df27dabe80 | c837af9b7bda2aa602b92c3584936eec | takes two genomes and returns a new child genome | genome population::progeny(pair<int,int> parents) {
genome parent1 = pop[parents.first];
genome parent2 = pop[parents.second];
return parent1+parent2;
} | 1 |
e4db7fe4bd85b83a911f7e40c2078138 | 4da493144004693fe8a89afc7e034b3d | Exit action for state 'Bienvenida'. | public class G_Escenarios extends javax.swing.JFrame
private void jButtonHaciaEActionPerformed(java.awt.event.ActionEvent evt) {
this.setVisible(false);
new Bienvenida().setVisible(true);
} | 0 |
e3f076e3cd6d21ebf0ee0ffd7dd01ecd | 359b4f1a5feec71e10ef5a918074e9d8 | Stop ignoring a kind of message. | public final class InGameController extends FreeColClientHolder
private synchronized void stopIgnoringMessage(String key) {
messagesToIgnore.remove(key);
logger.finer("Ignore message stop: " + key);
} | 1 |
884f7b7490371366fa591c1343cbc9cd | 14f08e21b387942e21a84fde12de34e4 | 获得对应标签的私有节点列表 | public List<NodeDto> listNodeByLabel(String label, Cluster cluster); | 1 |
5c1f53c6cf1fb64f8a514a6fa7892786 | 107afb3923a940ed136192d46a1b2ca3 | 查询miner信息列表 | public class RenwuDao
public static List<MinjingBean> queryMinjList(Object[] params) throws SQLException
{
if (params == null || params.length < 1)
{
return null;
}
return executor.queryListWithDBName(MinjingBean.class, CommonConstant.DBNAME_SQJW, "queryRenwumj", params);
} | 1 |
9c22a2d61ddead1654e508f49ecd222c | bd84f0d8c48b26a57829829fe714ebe0 | Sets a custom SVG attribute on the canvas. | if (element.attributes) {
element.attributes[attributeName] = attributeValue;
} else if (element.setAttribute) {
element.setAttribute(attributeName, attributeValue);
} else {
throw new AS3.Error("element " + element + " has neither an attributes field nor a setAttribute function");
}
... | 1 |
6817fac72f733420ddfaa6fd91275bca | d1efb7df01f66765664fb8635b4c6fb1 | Returns list of all images with their relative path | filecount = len([f for f in os.listdir(self.path) if os.path.isfile(os.path.join(self.path, f))])
images = np.empty(filecount, dtype='object')
cnt = 0
for filename in os.listdir(self.path):
fullFilename = os.path.join(self.path,filename)
images[... | 0 |
0257d0a10212ac7c2acbf470063e2c53 | b249ee9d3a29d7cd76a7c2ec9b070526 | 添加或删除检查类型 | public class WarningMsgAdapter extends BaseAdapter
public void addCheck(boolean isChecked) {
this.isChecked=isChecked;
notifyDataSetChanged();
} | 0 |
c5f2fffdd072222c2b4f77f08727c281 | 7b38553bb8eef21cb7d2f48dda13ea13 | 根据流程实例id取得已结束的任务
<pre>
修改日期 修改人 修改原因
2013-7-17 fang 新建
</pre> | public class GetBizCommentsAfterTaskCmd implements Command<List<BizComment>>, Serializable{
public Set<String> getfinishAct(String processInstId,CommandContext commandContext){
HistoricProcessInstanceEntity historicProcessInstance= commandContext.getHistoricProcessInstanceEntityManager().findHistoricProcessInstance(p... | 0 |
1a4664eccf0693f65b081bc77b7dc334 | df45daae333f221e0c61853dd499c156 | Searches for entreprise | class CompanyRepository extends ServiceEntityRepository
public function findBySearch($name, $allCompanies)
{
$qb = $this->createQueryBuilder('c')
->andWhere('c.id in (:allCompanies)')
->andWhere('c.isCompleted = true')
->andWhere('c.isValid = true')
->setParam... | 1 |
d0a2d552dac38740aa0fac615a535102 | 67cb619bf5dbd91c030a85a9ac25a0a4 | 通过XML获取图片地址 | {
string str = string.Empty;
Regex r = new Regex(@"<img\s+[^>]*\s*src\s*=\s*([']?)(?<url>\S+)'?[^>]*>",
RegexOptions.Compiled);
Match m = r.Match(text.ToLower());
if (m.Success)
str = m.Result("${url}").Replace("\"", "").Replace("'", "... | 1 |
5d31869d38bb58417e030e00005c02a7 | 80c911881ed65f3d9e041fa7d3a44ddb | Function to match all the rules and obtain a single value
the first match end the process.
Keyword arguments: | if target_attribute not in rules_dict.keys():
test_attribute = rules_dict['test_attributes']
char = data[test_attribute]
return parse_dict(rules_dict[char], data, target_attribute)
else:
return rules_dict[target_attribute] | 1 |
7e9ac8d5198ab2af6581851b7e7349af | 3db9fdb4f22b0bf73eb5ae70044cf208 | Event triggered upon torrent seeding start | namespace TorrentClientApp
public static class Program
private static void TorrentClient_TorrentLeeching(object sender, TorrentLeechingEventArgs e)
{
} | 0 |
fe05b68e1fb5d3bf32e393221b7c55c2 | 1e59033b2cbb1533bf6dfe5552e567c3 | True (default) when checking whether write-type is assignable from a source read-type. | fn can_read_from(data_type: DataType) -> bool {
Self::PHYSICAL_TYPE == data_type.physical_type()
} | 0 |
cd7153f7e7e190c235a8da89c7284cd5 | adc4025979253747c8362f3ec65b2a6d | Retrieve all facilities associated with a specific organization. | class OrganizationsApi
def find_facilities_by_organization(id, opts = {})
data, _status_code, _headers = find_facilities_by_organization_with_http_info(id, opts)
data
end | 1 |
381fa7676a09067b25d3442ad9b52ef9 | 8dde3d4af292639c188cca468322c51c | a map of all model elements that are simulated: element_id -> element | class HDLSimulationObject(HDLObject):
def state_elements(self):
return self._variables | 0 |
f2cd0596e77b8079a03075a5cb31279b | d75e9ce377471cd1045ca58b3e0d7f9b | Проверка просмотра прайс-листа | class PriceListTest extends TestCase
public function testCreateSuccess()
{
$response = $this->actingAs($this->user)->get(route('priceLists.create'));
$response->assertStatus(200);
} | 0 |
80ab7bc634ab9143b88ef2e4706c6ba0 | b7332a9f1b3ce9b36d83190eaa42d652 | Gets the current state of the dialog's lifecycle. | public abstract class SupportFragment extends Fragment implements SupportFragmentDelegate.SupportFragmentCompat
public LifecycleState getLifecycleState() {
return mLifecycleDelegate.getLifecycleState();
} | 0 |
ed79c25c4700f6e4c3668ebc63c5c5bf | ddbe904afb1ad0fd382cb8f6b4266e2f | 右上角拖动调整窗口大小。 | {
if (e.LeftButton == MouseButtonState.Pressed)
{
if (WindowState == WindowState.Maximized)
{
var point = PointToScreen(e.MouseDevice.GetPosition(this));
Left = point.X - (RestoreBounds.Width * 0.5);
Top = point.Y - 20;
WindowState = WindowState.Normal;
RectMax.Visibility = Visi... | 0 |
37f93b76e35ad35c80c1c79ec1aa4717 | c802a3fbf5fa1191723eb2d363d865c6 | 通过原始 json 文件为 img 图像绘制矩形框 | class SignLabel:
def show_image(self, image_file):
label_file = image_file.replace('.jpg', '.txt').replace('.jpeg', '.txt').replace('.png', '.txt')
print(image_file)
print(label_file)
image = cv2.imread(image_file)
h, w, c = image.shape
print('(h, w, c): (%d, %d, %d)' % (... | 0 |
28d7435df2bd35c891c8c4532ec6a34c | cd2a25fb21c4064870007625609c00b3 | Print a message detailing the incompatibility between the currently installed
product and the IDE in which it is currently executing. Typically,
{@link #isCompatibleWithIDE()} is called to determine if this method should be
called. Subclasses may override to change the generated message. | public class Workspace
@Nullable
public String getRequiredIJPluginMessage() {
return requiredIJPluginMessage;
} | 0 |
7896501a1d7aea2e81931de082ab7b9e | b995c19985ba484ec7209f7bfb0c7492 | 配种情况:估算受胎率 | class Girls extends Cache
public function conceive($player, $conceive_type) {
$today = date('Y-m-d');
$source = new Source('mother_child');
$mChild = $source->load($this->girl_id);
$starRateArr = array();
$skillRateArr = array();
if($conceive_type == 1) {
$conceive_count = $this->setCacheKey('conceive_... | 1 |
715960498cd9897fcc007854a7e804c3 | 74197f328948e71702cb998cee7cc76a | Set Perspective (0 to 100) | public void setPerspective( boolean onoff ); | 0 |
c5efbae527f83889804d0f6af1881903 | f669e7715912681b1daa62849b9c2be4 | 数据库中是否存在相同ID的APP,如果存在返回<code>true</code> | namespace ZK.BLL
public partial class WEBAPPS
public bool Exists(int APPID)
{
return dal.Exists(APPID);
} | 1 |
307462220c6b7f61179468de97d2afd9 | 0f3a3f3761de51da2710559be4ecb07e | Subscribes the poll command to the outputs of the PLL with the provided index. This includes the
PLL freqdelta, PLL error, and the PLL locked parameter (not working). | class HF2LIServer(LabradServer):
def subscribe_pll(self, c, PLL_index):
path = '/%s/plls/%d/*' % (self.dev_ID, PLL_index-1)
yield self.daq.subscribe(path) | 1 |
908edb6272d240c5e4133c8392399e02 | f4f2c30a9510e8f1403592dc50991997 | Method to delete all selected products | ObservableList<product_getset> productSelected, allProducts;
allProducts = table.getItems();
productSelected = table.getSelectionModel().getSelectedItems();
productSelected.forEach(allProducts::remove);
} | 1 |
35e5211cd14e6ffda5744fdc128e5b7b | ce355bb20a6f274a48f73810c024ac8d | Comprueba si los datos ya existen en la base de datos | log.debug(String.format("Datos %s %s %s", e.getPoints().toString(), e.getNameUser(), e.getTitleFilm()));
return userDao.findByNameLike(e.getNameUser()) != null &&
filmDao.findByTitleLike(e.getTitleFilm()) != null && e.getPoints()!= null;
} | 1 |
e0c702333e6f6ee2b23e237e0dd2d79c | d4965631a0f616dc141bfca5964d20cf | 获取n天前收盘价 | c = config()
time1 = getTime(day+num)
time2 = getTime(day)
stockName = stock["stockName"]
StockId = stock["id"]
data = {"stockName":stockName,"start":time1,"end":time2,"StockId":StockId}
url = c['url']+'/api/index/'+str(num)
r = requests.get(url,data=data)
return string.atof(r.text) | 1 |
9f69c277e1dbb05560f201e6480b1ae2 | b59d55055e39e3ae4709584a7c7dc64d | 【窗口】根据指定的进程Id,来查找可见窗口. | class SysCheck:
def get_hwnds_for_pid(self, pid):
def callback(hwnd, hwnds):
if win32gui.IsWindowVisible(hwnd) and win32gui.IsWindowEnabled(hwnd):
_, found_pid = win32process.GetWindowThreadProcessId(hwnd)
if found_pid == pid:
hwnds.append(hwnd)
... | 1 |
24356880c63426523a214011d100fd24 | 110dd8d6a2140d3dae01313f1cd50ef0 | Return test fail message. | public class TwoWayList_JML_Test
extends TwoWayList_JML_TestData
protected static abstract class OneTest extends TwoWayList_JML_Test
protected abstract java.lang.String failMessage
(org.jmlspecs.jmlrac.runtime.JMLAssertionError e); | 1 |
36adec48c65e672559f8a65745bdd260 | b9926e6b22abe63f30ac590e98dc4e41 | 刷新在线房源的在线天数 | class RunQueue Extends CI_Controller
public function DayOnline()
{
$this->data['online_date'] = isset($this->data['client_time']) ? date('Ymd', $this->data['client_time']) : date('Ymd');
$res = $this->check_online_uk($this->data['appid'], $this->data['accountid'], $this->data['serverid'], $this->dat... | 0 |
4bbc2ec2daed14a9ea4356fc4f241f86 | f368ec585c21cd0ae8b09a97339619db | Indica si la fra se sacara en papel preimpreso (true) o blanco (false) | public boolean getComprimido(); | 0 |
3b6f9fd1cf2836671f5c7c14d95484ff | 300337482a59260609b5ed61621e3ad2 | 商品退款-可退金额验证 | $data = db::name("service_goods")->where("id",intval($id))->where("order_id",$order_id)->field('id,order_id,service_name,num,refund,real_price,service_id')->find();
if(!$data){
$msg = ["result"=>false,'msg'=>'系统错误,请稍后重试'];
return $msg;
}else{
$val = array_diff_... | 1 |
e5f82b99c1bfad6fa3e98948ab0934b1 | c37df40761dc6e554c8e229548767069 | 请求寻宝开始 | function QiyuManager:RequestBeginYaBiao()
showLoading()
TFDirector:send(c2s.YABIAO, {})
end | 1 |
b354ce402caff0babba89b2f549018b6 | eb361bcb697f6b89264b32dca7b87366 | switch back to rendering to the back buffer | void RenderSystem::SetBackbufferAsRenderTarget()
{
D3D11RenderCommand_RenderTarget rc;
rc.SetRenderTargetTexture( NULL );
Submit( &rc );
} | 1 |
497011ebcd6696a4251b08bcd131478f | 04f49d3636183beba8136dc1cf89ddfe | 曜日を表示するヘッダ列を生成する。 | namespace Elf.PTLayer.Root.Gda
public partial class GdaSchMonth : BasePage
public string GetHeader(DateTime pSelDate)
{
StringBuilder retVal = new StringBuilder();
try
{
retVal.Append("<tr>\n");
for (DateTime i = pSelDate; i < pSelDate.Add... | 1 |
4bdc65c3569dddf627fdf75a16ea98de | 3407e0b30d8e23f53663a90146290dbc | Создание учётных записей учебной части | function createTeachers() {
var tch = schedulesAnswer.teachers, les = 0, day = 0, coordY, bezdna;
for (var i = 0; i < tch.length; i++) {
createSortTable('table_teacher');
$('.table_teacher').last().find('tr:first').children().text(tch[i].teacher.firstname + ' ' + tch[i].teacher.lastname).end()... | 0 |
59f9999ba4eaf19b0cf4e1d60b0ebdf9 | 54c923c315b2af13626ab623eb3069f6 | 异步调用存储过程 | params DbParameter[] parameters)
{
return ExecuteProcAsync(conn, procedureName, CancellationToken.None, parameters);
} | 1 |
c6d3e780b8cb50c4dcc39d561716a2a5 | 94cc690b8f6163bc3046ef9c3c1303a8 | Set split tools to active/inactive | class DataSplitter:
def active_tools(self):
tools_active = []
if self.logger:
tools_active.append(self.logger)
if self.ipc:
tools_active.append(self.ipc)
return tools_active | 0 |
38df001497ba20c9691229f5c336ece6 | 4c01e90c46b638732774a11bcaa58497 | 高级查询面板工具栏的刷新按钮事件函数 | namespace LibPanels
public partial class ManagementInfoManagement : Form
private void tsBtnRefresh_Click(object sender, EventArgs e)
{
RefreshData();
} | 1 |
f45518a68da4d2ac79e84610a34625c0 | cace16a6d353523c65bd70421bcdc4b0 | Confirms a certain order was sent to the company, and sets the time it was sent to the time the method was called. | namespace RhinoExample
void SendOrderConfirmationToCustomer(ICustomer customerThatHasOrdered, IProduct productOrderByCustomer, int orderAmount, int numberOfItemsOrdered); | 0 |
327053075b30893b4d5a1eceab115683 | 7bfa4f5b4ce60d98b8effc67fdf9a494 | 用递归方法求n的阶乘 | public class Demo4_14_2
public static int recursion(int n) {
if (n == 1) {
return 1;
} else if (n <= 0) {
return -1;
} else {
return recursion(n - 1) * n;
}
} | 1 |
185edbf543efd51f0da993bce1eb1033 | ba5fc182c4319024485bb7327fce41f9 | Lists schedules for a pool. | if environment is None:
raise SyntaxError('Environment has not been specified')
if expected_version is None:
headers = None
else:
headers = {'expected-version':expected_version}
request_endpoint = '/api/v1/environments/%s/schedule' % environment
... | 0 |
ddb47f483ac37a2ce5d0556fdf59b14b | 210a2e0376afee3921bb0dfc14ef8cdd | 通知原生页面加载完成 | reload(){
if (getCurrentPages().length != 0) {
getCurrentPages()[getCurrentPages().length - 1].onLoad()
}
} | 0 |
dce3556ef2540ccb8ebe5bf2aa311e47 | 1f3990365afadb4d59e3695907b4ad8d | Allows [re]setting stored password hash | final class Fake extends Basic implements Implementor
public function setPassword(string $old_pass, string $new_pass): bool
{
return $this->forcePassword($new_pass);
} | 1 |
1ded4f4eed04d5c5de99d1d509a41448 | 526d181d4d2cf7b46bd03e454d22235d | only update the latest layer | class LayerStateControl(WidgetControl):
def update_nb_layer(self, change: dict) -> None:
if len(change["new"]) == len(change["old"]):
return
self.nb_layer = len([lyr for lyr in change["new"] if not lyr.base])
modified_layer = list(set(change["new"]) ^ set(change["old"]))[0]
i... | 0 |
7604771a2b42b9d7e03f158632de0794 | 60862add3c1e011ae0adcc79694fa201 | 创建一个新的Vector2,其中包含两个向量的最大值 | namespace Raylib
public static partial class Raylib
[DllImport(nativeLibName,CallingConvention = CallingConvention.Cdecl)]
public static extern Vector3 Vector3Max(Vector3 v1, Vector3 v2); | 0 |
88a19be8494889cd7c4a9890593a9071 | a9ae992fed2774cbc87dbe101322d33a | Test case for data_context_path_computation_context_path_comp_serviceuuid_end_pointlocal_id_capacity_total_size_get | class TestTapiPathComputationController(BaseTestCase):
def test_data_context_path_computation_context_path_comp_serviceuuid_end_pointlocal_id_post(self):
tapi_path_computation_path_service_end_point = TapiPathComputationPathServiceEndPoint()
response = self.client.open(
'/data/context/path-c... | 0 |
b2b2da2eead18e71fc965fb57bc4bc95 | 37ce23d1d63f59d409e3637378dec8a1 | Update tools visible on hover | $('#tool > button').removeClass('font-weight-bold');
switch (tool) {
case 0:
$('.tool').html('Available');
dynamic['tool'] = 0;
$('#tool > .btn-success').addClass('font-weight-bold');
break;
case 1:
$('.tool').html('Prefer Not');
dynamic['tool'] = 1;
$('#tool > .btn-warning').addClass('font... | 0 |
a6ac399094c1b56fb0f8b42fcef277cd | bf3411b332e8669ba81cbb3c06e9f461 | 他人主页评论列表 | class UserController extends CommonController
public function comment_list()
{
$count = $this->model->table('comment')
->where('parent_id = 0 and user_id = ' . $this->user_id)
->count();
$filter['page'] = '{page}';
$offset = $this->pageLimit(url('comment_list', $filte... | 0 |
f0be00db6a238b0fad2b4f36a237daca | c17679d499fc46f091de2a96834be08a | 获取广播的状态
Get broadcast status value. | CompletableFuture<String> fetchBroadcastStatus(String msgId); | 1 |
aeb32c6d5f472c80171ddf5b8aff2177 | 4c946b27c14606b91ab1838dcb35edc0 | Busca el documento generado en un proceso determinado. | namespace IO.Swagger.Api
public partial class DocumentTicketsApi : IDocumentTicketsApi
public async System.Threading.Tasks.Task<System.IO.Stream> DocumentTicketsGetForProcessDocumentAsync (int? processdocid, int? processId, bool? forView = null)
{
ApiResponse<System.IO.Stream> localVarResponse ... | 1 |
e8f87d2583b1908353e8d9b5ea418e8d | 51d803a3ca3c8fabd42f8953b17cf45b | 新增商品屬性(如果商品已經存在會覆寫之前屬性設定) | public SpuPropertyDTO addSpuProperty(SpuPropertyDTO spuPropertyDTO) throws ItemException; | 1 |
b353ce87feb3a21b40b2db7c21e3c9c9 | 8235c3904eff092d628c7f6b9cd6bce4 | Gets note detail by providing issue_id and note_id | {
if(!$this->checkNoteOwner($id)){
return ['error' => 'access forbiden'];
}
$result = $this->repository->findWhere(['project_id' => $id, 'id' => $id_note ]);
if(isset($result['data']) && count($result['data']) == 1){
$result['data'] = $result['data'][0];
... | 1 |
1811d694f76556ae2739eaeaadf53621 | ce2d61301ab31f7bdeafa7f284d56ea0 | Sets Status.
The status of the `WALLET` payment. The status can be `AUTHORIZED`, `CAPTURED`, `VOIDED`, or
`FAILED`. | validator = EnumAttributeValidator.new('String', ["pending", "payment_required", "wire_pending", "payment_pending", "payment_held", "payment_authorized", "voided", "fraud_hold", "payment_deposited", "work_completed", "problem_flagged", "problem_resolve_requested", "problem_escalated", "completed", "cancelled", "r... | 0 |
e35b64308201eb39b4ec331559bbd4f0 | a9cda02b850274137dc85e71753ae789 | affichage du GAME OVER lorsque la balle n'est pas rattrapée par la raquette | glClear(GL_COLOR_BUFFER_BIT);
glLoadIdentity();
int screen_x, screen_y;
screen_x = 0;
screen_y = 0;
glBegin(GL_QUADS);
glColor3f(0, 0, 0);
glVertex2i(screen_x, screen_y);
glVertex2i(screen_x + GAME_WIDTH, screen_y);
glVertex2i(screen_x + GAME_WIDTH, screen_y + GAME_HEIGHT);
glVertex2i(screen_x, screen_y + GA... | 1 |
95e4a13541d7a56dd5b14a5d7468a967 | 153e52d7f13b5fae1cb1684c4c3e2d10 | Actualiza el status de las cards de los monstruos | public class MonsterCard : MonoBehaviour
void Update () {
} | 0 |
cc8ab42b0c270aacfd3d6f9ed1c12a4b | 93bbea396a9f05e60af5d3806306bcb7 | Dodaj iteme vrsta usluge u ComboBox | {
DataTable DTUsluge = Global.Database.GetVrstaUsluge();
foreach (DataRow row in DTUsluge.Rows)
{
comboBoxVrstaUsluge.Items.Add(row["naziv_usluge"].ToString());
}
} | 1 |
8aefba82bd78fd903ad41acc2931972e | 1609b0594481f92c314e6c3e6e5597ed | Gets both the observation space and action space. | class UR5Env(gym.Env):
def _setup_spaces(self):
self.observation_space = self._robot.observation_space
self.action_space = self._robot.action_space | 1 |
119b9eff7c590e07e9fcb6821d258f6a | a9529f752c3f4838cbd97c744e47f9ae | Log an error msg to file. | def error_logger(error_log, msg):
error_log.append(msg + '\r\n')
print(msg)
return None | 0 |
2f247139678dbec29e7d17b0949d2e02 | 2a6e266f4cdc86939040c279b44f4559 | 向该活动的所有参与者发送该活动已经被删除的通知 | class EventModelObserver
public function forceDeleted(Event $event)
{
$users = $this->getRemovalMailingList($event, true);
$user = Auth::user();
Notification::send($users, new EventDestroyedNotification($event->toArray(), $user->toArray()));
Log::channel('user_actions')
-... | 1 |
67d09cfbeb3e782d3dc534be12c9cd51 | 373efc756a1ff27d27ec8552b9a2a540 | Update the victim's state to logged out. | {
this.getClient(clientID).setVisitor(null);
String response = clientID + ",logout,success;";
updateClientStatus(clientID, response);
} | 1 |
76d8354d633a2dbcc9d8c338bc7a3b15 | bcf39245748104498084b607d06cbdc4 | Returns list of dictionaries for select call.
If fails to get query result after max_query_retries will
return None. | class RetrieverInterface(metaclass=ABCMeta):
def get_schedule(self,
**kwargs,
):
raise NotImplementedError | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.