query_id
string
corpus_id
string
query
string
code
string
label
int64
540b715ad71879714ca7b5fd926624ef
ed9a50319725b35cc2a84cf013cb05a9
Asserts that a set of elements are enabled on a screen
public class BrowserAssert extends BrowserAccess{ public static void assertElementDisabled(final Collection<Object> locators) throws Exception { for (Object each : locators){ WebDriverAsserts.assertElementDisabled(getLocator(each)); } }
0
1637836b8b3b1b2c6737ec43a01a4ab4
6fd2d47a69c6e5fed0d75c16bb92b2fe
移动时间轴定时任务的方法
function golMove() { clearInterval(mvTimer); var per = 0; mvTimer = setInterval(function () { per = mov.currentTime / mov.duration; mvZyanhGlobe.style.left = per * (mvZyhplan.offsetWidth - mvZyanhGlobe.offsetWidth) + 'px'; mvzyhProgress.style.width = per * 100 + '%'; }, 4) }
1
a88cd60b1eca27e7df55258f0d8070e2
766865ab632ffc67fcda623866720d4d
GET /users/:userid/available
return if (context.currentUserId() != null && context.currentUserId() == userId) context.require( requiredRoles = listOf(UserRole.Role.USER), successCommand = factory.userAvailableTime( userId = userId ) ...
1
4036f848b7f9838e0eb9a803be7741d9
abb0bd3b3815d856094841d45c681582
计算 x 与 y协方差的函数
def cov(x, y): x_mean = mean(x) y_mean = mean(y) data = [(x[i] - x_mean) * (y[i] - y_mean) for i in range(len(x))] return sum(data) / (len(data) - 1)
1
bd19ba87c3b682f99251851e79bebaa9
4362d2a7f8765eef7785f23083000075
Performs actions after receiving and before processing new historical data.
if self.exporter == None: self.logAnswer(ibapi.utils.current_fn_name(), vars()) return else: self.exporter.handleHistoricalDataEnd(reqId, start, end)
0
9d36d90d492d0834fe8f4657ee704c74
ab878e4812c28ca02efd19fa21ff3b54
Compute magnetic field at a set of points.
magfield(path, current, { _data: atPoint } = {}) { const n = 5; const d = 20 / n; function bAt(x, y, z, { _data: path }, current) { let b = math.zeros(3); const c = current * math.magneticConstant.value / 4.0 / math.PI; for (let i = 0; i < path.length - 1; i += 1) { const p1 = pa...
1
2d52911e783ec2ba32685bdcee11bc40
3a1282812c93284395947c05e74ff08c
Gets the cash letter header.
public function CashBox();
0
a40d2a1f0928e8a7ea29c178eadde845
ab315a3c617f741297f49b09ac5aa04b
핸드폰 인증번호 맞는지 확인
int phoneConfirm = (int) session. getAttribute("authNum"); String resultMsg = ""; if(phoneConfirmNum == phoneConfirm) { resultMsg = "OK"; }else { resultMsg = "NO"; } return resultMsg; }
1
d21cb2d6d84560ae10c257d228a094c6
78df066a417e7df78a5c4c62df421a68
Gibt das Modulkürzel zurück.
class Kml extends XmlParser public function getCode() { return 'kml'; }
1
68644baf6a1d2326613a11ec3add4615
8c52ec1217bfa1a21713fd503a99d134
[Chuc.Nguyen] - Lấy dữ liệu có điều kiện dùng Store
namespace VietBaIT.DROC.Objects.ObjectController public class Mod_TypeController public DataSet GetData(string Condition) { try { return DataAccess.ExecuteDataset(globalVariables.OleDbConnection, CommandType.Text, "SELECT *, 0 as OldPos FROM L_MODALITY_TYPE WHERE " + ...
0
fed2440853d852cf3db8ab0e44e51585
0cb0cbcf7a9e4a988ce5303839093ed2
根据id删除文章分类
$id=I('get.id'); $info=M('article_cat')->where("id=$id")->delete(); if($info){ echo 1; }else{ echo 2; } }
1
39423abb75b97e26ee0837bcceb4fbd2
c3d6e2cb2b09b7a5b93a375d1880a238
Commits the data of the <see cref="CancelGuildCreation" />.
{ lock (_contextLock) { if (_context == null) { return false; } return _context.Cancel(); } }
0
f44d3dbd1b144080714c3ac205f430db
df78ccadc5368be06c7bf6bf3a13f39a
Export to a ESRI Geodatabase file.
def save_gdf(gdf : GeoDataFrame, path, driver = 'ESRI Shapefile'): return to_export_friendly(gdf).to_file(path, driver = driver)
0
4e5b636801e4f6b1830b02c79070d1dd
1706e9b0ed95e9eb3d80e50ce9fb3fe7
亲属关系表新增页面跳转
@Controller @RequestMapping("/thirdUserRelation") public class ThirdUserRelationController extends BaseController @RequestMapping("/thirdUserRelation_add") public String thirdUserRelationAdd() { return PREFIX + "thirdUserRelation_add.html"; }
1
cc7a3661bb71e1c64ff2a6bb226a811c
2e4a655fa80619203a6a0f8e0986d675
Returns a list of admin objects
class AdminController extends Controller public function getListofAdmins() { return $this->oBlAdmin->getListofAdmins(); }
1
ed320ba14ba2c6e61e5fecdad6bb72ea
ef9a079537a6924741db74eb46ffb035
Checks that in the limit CvM coincides with MSE
class NeuralNetRegression_test(unittest.TestCase): def test_MSE(self): n = 50000 x = np.linspace(0,1,n) y_data = np.linspace(0,1,n) y_model = np.linspace(0,1,n) obj = NeuralNetRegression(x,y_model,y_model) self.assertEqual(obj.MSE(y_data=y_data, y_model = y_model),0)
0
aaec298e6004447fd1313c9532aea083
7ab2cd69ab0ad24c0ef5a9af94e0ee2a
Reveal the AppShowcaseView after a delay.
class WelcomeActivity : AppCompatActivity() , RequestListener<Drawable> private fun beginDelayTask() { Handler().postDelayed({ MainActivity.show(this) this.mDisposable?.dispose() this.finish() }, 2000) }
0
aa41286f3582e33b4126765fa99ed5d3
2bb67b11aba369c11e91079ee22fbe9b
Runs the main loop. Handles CLI history and restarting the command prompt.
history = FileHistory(self.history_path) command_completer = completer.CommandCompleter(client=self.client) print_figlet("PrivCloud", font="starwars", width=100) while True: try: input_text = prompt( u"%s $ " % self.name, ...
1
4402c7156da1db5b237a22ec4f620754
b3d7a8fe06dad61cd9165ba4896b610e
Use name of current assembly to construct NLog config filename
public class LogUtils extends Logger{ public static String getLogLevelConfigurationFilename() { return LogConfigurationPath + System.getProperty("file.separator") + "LOG_CONFIG_" + LevelNames[currentLevel] + ".xml"; }
0
d512e5043be64411b9923257552b72ac
8e4255b2e332796bed0b260d36c787a8
Sets the count alarms.
function SetAlarmCount() { $.get("/Home/GetAlarmCount", function (res) { $('#totalNum').attr("total", res); }); }
0
b9ba25b0d4c0f3f2ebd2d88d2eedbb71
5c27528277b0b5a9b8afc8470123db34
ham thu hien cap nhat thong tin tong dai cap nhan vao cuoc goi kết thúc
{ CapBacHoiVienDAO capBacHoiVienDAO = new CapBacHoiVienDAO(); CapBacHoiVienDTO capBacHienTai = capBacHoiVienDAO.LayCapBacTheoMa(dauThu1.MaCapBac); CapBacHoiVienBUS capBacHoiVienBUS = null; if (dau > 0) { CapBacHoiVienDTO capBacKeTiep = ...
0
300f8aefaa2cb9af4e1f8a40c622e0a9
216f83d39a16f0d730deac9f3409b580
RECUPERATION DE LA LISTE DES RECETTES POUR UN INGREDIENT DONNE
$().requeteAjax({ url : "/ajax/rAjax_recette.php", parametres : {fonction:'categorie',option:categorie}, reussie : function(reponse){recetteMaJListe(reponse);} }); }
0
fb3b5f0e8c274b67593d2f06d4313ac9
1e64d14012e1834c3f801798205a9b7a
Timeout, so reset the keyboard read variables
class NGPhone(PhoneConnection): def _timeout(self, length=None): self.__purgeKeyPresses() self.__purgeExpectedItems()
1
77be6e665129b9624216c2e21bfbed37
f82ae1d5e532601528fd0c3b707bd6de
删除该人员库及包含的所有的人员。同时,人员对应的所有人脸信息将被删除。若某人员同时存在多个人员库中,该人员不会被删除,但属于该人员库中的自定义描述字段信息会被删除,属于其他人员库的自定义描述字段信息不受影响。
try: params = request._serialize() body = self.call("DeletePersonSample", params) response = json.loads(body) if "Error" not in response["Response"]: model = models.DeletePersonSampleResponse() model._deserialize(response["Response"...
1
f3ede4a66f6862f56ec31b1592a74cdc
5f4e77558caad0e6e3664476d002170e
绑定一个字段的数据到数据对象中
function bindDataForField(containerId, keyName, val) { var container = $("#" + containerId); var control = container.find("[data-key='" + keyName + "']"); setControlVal(control, val); }
0
f34a2eb11b34d059b34904a5aaedf95b
363ae414895ef910062ab1419c0dd765
Called by WallstreetWebservices to register new Firm
namespace TravelAgency.WF.Account public partial class Manage : System.Web.UI.Page private tFirmy GetNewFirmData() { var f = GetFirmData(); FirmData.UpdateFirm(f, service); return f; }
0
c9520ca56866c20ed182c0ec3d2070ab
89337660cf6baf35728b99fc658fb658
Register PSR-0 autoloader. Do NOT use if you are using Composer to autoload dependencies.
class Autoloader private static function _registerPSR4() { spl_autoload_register(function ($class) { $sources = array( 'Zu\\Panda\\' => 'lib' . DIRECTORY_SEPARATOR ); $found = false; foreach ($sources as $_prefix => $_base_dir) { ...
0
40ac6b20bf9ab3490c61e4aae082de49
43f2a7cc60fb8e1158286adfdefc327e
Recebe dinheiro do cliente, porém não mais do que a dívida
public class Debito extends Conta public boolean levantar(double valor) { if(saldo >= valor) { saldo -= valor; return true; } return false; }
0
3f9957a8d399b3727078dd31f26a9850
463fc3ddd8cfed010c96cd8461a39570
預覽匯入CSV
namespace Com.Nidec.Mes.Common.Basic.MachineMaintenance.Form public partial class PQMDataViewerForm : FormCommonNCVP private void btnCSV_Click(object sender, EventArgs e) { try { RenewData(); timer2.Enabled = true; GetTable = new Thread...
0
57dd1064ed450ced1f1f3ae429809741
7194c7962e6e466b25406ed8e677343f
算出字串內的字各有多少個
void check(char *ary) { int i; char alpha[26]; int num[26]; for (i = 0; i < 26; i++) { alpha[i] = 'a' + i; num[i] = 0; } for (i = 0; ary[i] != 0; i++) { if ((ary[i] >= 'a') && (ary[i] <= 'z')) num[ary[i] - 'a']++; } for (i = 0; i < 26; i++) cout << alpha[i] << " : " << num[i]<<endl; }
1
5997d59e37deb84819c0a394f76b223f
8a565eb9eca299e07ec60d10ede2104c
Tests querying the modules prerequisite units, where there is no prereq
class ModuleInstCreateGroup(TestGroup): def module_query_empty(self): self.test_runner.run_module_query_empty()
1
3ef4a169a45176391edc44e5c7a892d4
60eb03c00f78872d2e78db3379f4d2b8
获取现在的动态密码
class LoginController extends SmsController public function selectPasswordAct () { $user = D('user'); $data = $user->selectPasswordAct(); $this->ajaxReturn($data); }
0
8d759a2a8e1adfd1b2eba298bb7acbee
3994c2f8aa01b9773e95b40ff40b2362
Wrapper to convert form element data to object.
if ( ! isset($elementData['object']) ) { return false; } $element_type_instance = ZNB()->elements_manager->getElement( $elementData[ 'object' ] ); if ( false === $element_type_instance ) { return false; } if ( ! $element_type_instance ) { return false; } $elementInstance = clone $element_type_i...
1
0ba6d83a829cbe4617cd0e456a0069ee
c481a2a5cedaa6712c45a62e4ac06068
容器的drop事件处理
export class MainPanelProvider initDropEvent() { const renderControlPanel = this.getControlPanelRoot(); renderControlPanel.addEventListener("dragenter", (event) => { event.preventDefault(); }); renderControlPanel.addEventListener("dragleave", (event) => { event.pr...
1
51703cb5685db589598a0ef409ee120c
4f40be352434790d8fcdb99752faee90
Tests that connector can be disabled.
await retry.try(async () => { const isEnabled = await this.getIsEnabled(); expect(isEnabled).to.be(false); }); }
1
b961bfcba37fba2c568b4ffa67fd7bdf
93eed2d928dc6624d9b9ac027e157663
init the parameter for matrix factorization. input: train -data matrix (D x N) num_features -Number of latent features for matrix factorization (K) output: user_features -user features matrix (K x N) item_features -movie features matrix (K x D)
class WRMFRecommender(MatrixFactorizationRecommender): def fit(self, train, item_features=None): if type(train) == csr_matrix: train = fast_sparse_matrix(train) num_users, num_items = train.shape self.U = self.init_factors(num_users, False) self.V = self.init_factors(num_it...
0
d6b3dc01b8713cea84da608add36210c
9b1699b1eb8862e482b2e8d01663c2c7
指定エリアのエリア種別がAS/RSかチェックを行います。
if (selectedAreaDatas.length <= 0) { $("#mpsModalAreaAlertError").txtCrossFade("エリアを選択してください"); return false; } else { return true; } }
0
d7979fb5a4ded5b19994d588a470bd68
65906904e66e49600753f05294be7f33
Écrit un octet dans un fichier binaire
{ unsigned char bytes[2]; bytes[0] = (val & 0xff); bytes[1] = ((val >> 8) & 0xff); fwrite(bytes, 1, 2, fp); }
0
402eaa6c30d02a0dafdbd48324c30428
96c4ed02b674165559387dc3df2a49f5
intに変換可能ならtrueを返す
namespace IchigoJamKeyBoard public partial class OptionMonitorForm : Form public static bool IsInteger(string stTarget) { int iNullable; return int.TryParse(stTarget, NumberStyles.Any, null, out iNullable); }
1
d3d882e3a5703bf92ea170b75823a70d
d79b31e6e6c5285ac6364f0141b515f9
Valid卷积
def conv2d(x, W): return tf.nn.conv2d(x, W, strides=[1, 1, 1, 1], padding="VALID")
1
ae3a0c1aae8026021e9a08e21dd6e3e9
e011511a3e0f1b3fbcc88e41d5ff22b0
one test source: def f(i): sum = 0 while i > 0: sum = sum + i i = i - 1 return sum
def sum_1ton(n): s = 0 while n > 0: s += n n -= 1 return s
1
ef34893aa50d0c586270350abc49cb23
6b48f04144fff44d652afd9959c57067
更新商户-产品费率
class Product extends Base public function updateCommission(){ $paramData = request()->post(); foreach ($paramData as $info){ $validate = $this->validate($info,(new CreateProductParams())->updateCommissionRules()); if(true !== $validate){ return apiReturn(['code'=...
1
460ac02b1cbf104e851c9360249f9a77
d05a1ca0f216ac5998d2c8e50efa83e7
Get idTransferencia
class EnvioDte extends Envio public function getID() { return isset($this->arreglo[$this->config['tipos'][$this->tipo]]['SetDTE']['@attributes']['ID']) ? $this->arreglo[$this->config['tipos'][$this->tipo]]['SetDTE']['@attributes']['ID'] : false; }
0
73007db0db0ead0676b1dca43baa9f02
71a4a97f6a4daf322dfbe3e7a066059c
Check if the current manifest (property 'Manifest') is valid for the current files in the package.
namespace RepoCat.Schemas public class SchemaValidator public List<string> ValidateManifest(XDocument xDoc) { return Validate(xDoc, this.ComponentManifestSchemas.Value); }
1
595659a639bb66644c62f2bc6bd0d48f
b4711b37984fde04c1788b2d3c36afd3
获取我的优惠券使用和未使用数量
public class CrmMyCashAction extends StrutsEntityAction<CrmUserCoupons, CrmUserCouponsManager> public ActionForward myCoupon(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) { String userId = request.getParameter("userid"); request.setAttribute("userId", userId...
1
880d049aae7325cd96e5986caf79ee16
e05a01a67aa36968cbdd1f1ed7be720c
Returns incremental file count of the snapshot
class Volume(object): def get_snapdiff(self, base, previous): volume_key = self.get_key_vol() if volume_key is None: error_message = "Unexistent volume name: %s" % self.volume_name return [], error_message base_snapshot_key, error_message = self.get_key_snapshot(base) ...
1
aea2595374f8ccf2be8b5b1ad286eb7f
4cafe3b3793d987d0c85f4bd1e027c1b
As User I want to see loading animation is shown while getting Top 25 stories
public void shouldTriggerErrorFlagAndResetProgressFlagWhenFailedToGetStories() { when(itemRepository.getTopStories()) .thenReturn(Observable.<List<Long>>error(new IOException())); newsListViewModel.loadNews(false); assertTrue(newsListViewModel.getShowError().get()); a...
0
1893f9289f037c8e3142ea9e26923647
a0537904bd30409b0fd567aaac9fabe7
插入单条宣讲会记录
void insert(BdScholarshipStory scholarshipStory);
1
a7c646ceba0ea19f1a8b12c3d0b99633
4d410f69f48024d4c5e2cbea7c29ab8f
Solves the all-pairs shortest path problem using Floyd Warshall algorithm
void floydWarshall (int graph[][V]) { }
1
a2fab4841173826c46e55c0af2d06266
fdea048a1c9e5706ffd75eae22399ee8
清空所有的未读消息, 改变read字段未true
{ if (m_messages->hasSetMessage()){ m_unreadCount = 0; CMessageVec::iterator it = m_messages->begin(); while (it != m_messages->end()){ (*it)->m_isReaded = true; it++; } } }
1
17067bdbbd505cca3a673e695243342f
7b683efa3880e65405814c62fcbe3ec6
Get the registration status for a course.
public class SemesterRegistrationDaoOperation implements SemesterRegistrationDaoInterface @Override public boolean getRegistrationStatus(int studentId) throws SQLException { try { PreparedStatement ps = conn.prepareStatement(SqlQueries.GET_REGISTRATION_STATUS); ps.setInt(1, studentId...
0
03e4a248e9b52ec7141ded32399f7be4
e1566607daf0e19b37d5d7c2d5010a37
Update tasks between multiple boards
try{ const { taskId, payload, type } = req.body; const board = await Board.findById(req.params.id); let newtasks = board.tasks; newtasks = newtasks.map((item) => { return item._id == taskId ? item = { ...item, ...payload } : item }); ...
0
0601bc3c537ff3f0a10e446846236755
5f2ae16ff03dfa3a0522500633592156
Move cursor right "delta" chars
class Cursor(ansi.AnsiCursor): def right(self,distance=1): print(super().FORWARD(distance),file=self.outfile,end='')
1
be9f147223f97e60501284959ba2dddc
df66ff6c53903a1972b61fca9c35893f
single threaded, recursive fibonacci implementation
if (n == 0) return 0 elsif ((n == 1) or (n == 2)) return 1 else return fib_recursive(n-1) + fib_recursive(n-2) end end
1
d16c640a3a88a18967743eae41e894f1
3d68084e72201e5649d7c1fce9140ebc
Generate an UUID, may be used to consistently generate the same UUID for a specific identifier and namespace.
class IUUIDGenerator(Interface): def __call__():
0
3caa98126845d2fad099ff73ce502eab
9e2580e657bbfbc35feef34e6fd68156
ウィンドウサイズのセット
class RecWindow(Ui_MainWindow): def set(self): self.dlg = Ui_SetDialog() self.dlg.setupUi(self.dlg) if self.dlg.exec_(): para = (int(self.dlg.lineEdit_w.text()), int(self.dlg.lineEdit_h.text())) try: self.mplwidget.set_para(para) except UnboundLocalError: ...
1
cc084a4c5dcfd294a2083c1773fbe1ef
8b00c1237aeb9a267df43727654744e6
Устанавливаем дефолтные настройки для кондиционера
namespace HDL_Buspro_Setup_Tool public class HVAC : ICloneable public void ReadDefaultInfo() { bytAutoRun = 0; bytModeONDelay = 1; bytModeOFFDelay = 1; bytFanONDelay = 1; bytFanOFFDelay = 1; bytCOrP = 0; bytHigh = 10; ...
1
8f8c318c629456c4c8ebef8e43ee69e5
4f332dc9b39420137bef93d01bf21585
Handles the SelectionChangeCommitted event of the LandCodeComboBox control.
{ int temprollyear; F36033LandCodesValuesData.ListLandCodeDataTable tempListlandCodeDataTable = new F36033LandCodesValuesData.ListLandCodeDataTable(); string filterLandCodeCondition; int.TryParse(this.RollYearTextBox.Text.Trim(), out temprollyear); if ...
0
42db7cf590c9d01ebf9ddc18fd0589f4
b97b00e4264e46ed8d61b6fb81328918
Добавляет название департамента, являющигося прямым потомком текущего.
{ builder.AppendLine(); SetIndentation(style); builder.Append(new string(' ', dept * Indent)); }
0
cee9b8b27be9b2fa8760b2667d713d92
8f988a7d56d3bf583e1ec08f586a9ad4
获取转场动画作用的View
public class ScaleEffect public void setAnimateView(View view) { this.view = view; }
0
79d2e948ffe57c6c4044b225529400e9
3687b986678d8cefc51a652c2dad143b
@brief get widget's information, the format of it is: NAME<> TYPE<> STATE<>
namespace hello QString WidgetExplorer::widgetInformation( const QWidget* widget ) const { QRect r( widget->geometry() ); const char* className( widget->metaObject()->className() ); QString out; QTextStream( &out ) << widget << " (" << className << ")" << " position: " <<...
0
e9ec9f9a1bd6f7c2ee2ff94271203cfd
be4a97fe4536506ee24969077b2640b3
Generate insert clause.
{ $ignoreSql = $query->getIsIgnore() ? ' IGNORE' : ''; $whatSql = $this->sanitizeTableName($query->getTableName()); $setSql = "\nSET " . $this->buildSetPart($query->getValues()); $onDuplicateKeyValues = $query->getOnDuplicateKeyValues(); $onDuplicateKeySql = ''; if (!...
1
5b01781f81588c300bb0af1290d203f2
daad35a14dfc610bd82d21a511b2061c
初始化密码txt到内存中
String pwd=""; for (int i = 0; i <cells.size() ; i++) { LockPatternView.Cell cell=cells.get(i); pwd+=cell.getIndex(); } SPutils.saveString(getApplication(), MyApplication.GESTURE_PASSWORD,pwd); }
0
eae1464c1220ff844851b4d1b2036076
179aabe7e47480a5d397b93793af7bb2
絶望
if (C101_KinbakuClub_Erica_Refuse == 1) { OverridenIntroText = GetText("LetOut"); C101_KinbakuClub_Erica_CurrentStage = 240; } if (C101_KinbakuClub_Erica_Refuse >= 3) { C101_KinbakuClub_Erica_Pleasure(4) } C101_KinbakuClub_Erica_Refuse++ }
0
8dbad9941dd8ce1ab917c4d500d525f4
f50d2b7fcc3e89c187d5f123b26d868f
Checks if removePrefix() removes the given prefix from the string.
{ $prefix = 'TestWithPrefix'; $randomId = StringUtils::getRandomUniqueId($prefix); $this->assertStringStartsWith($prefix, $randomId); $this->assertEquals(strlen($prefix) + 64, strlen($randomId)); }
0
87b4ec8afb0e8554bd7587de5fe63972
c1adda403e92664abcbeaf2bcb9b362f
methode qui retourne les Bac qui permet d'inscrire au cette fliere
class Flux_Ice extends Flux_Site{ function getListeForm(){ return $this->dbD->findByTronc('formSem'); }
0
64242f775794b1abe994db44d6d6919a
a3d8ede8cf45478a287811b60b78bf70
当前题目的总答题数
public class CollectionTableOperate public long allCaseNumBySubject(int question_id) { String sql = "select count(*) from " + Question_bank_field.COLLECTION_TABLENAME + " where " + Question_bank_field.question_id + " = '" + question_id + "'"; Cursor cursor = mDB.rawQuery(sql, null); ...
1
33a628bae6a09711a86ac7462e7026ea
106d5c75898649842d7abc2be02188c0
Verify that each parameter is guarded (throws exception if value is invalid). Can verify constructors and methods (if enabled).
namespace AzureCosmosContext.Options public class CosmosOptions public void Guard() { GuardNullOrEmpty(DatabaseId, nameof(DatabaseId)); GuardDefaultThroughput(); GuardThrottlingRetryOptions(ThrottlingRetryOptions); }
1
51c5749e1dc62daf28bfa8e4d57b497a
b1bad9c86405e56246ae186543b72028
设置发送缓冲区,返回原发送缓冲区的引用
class Connection public function setBuffer($buffer) { return $this->setReadBuffer($buffer) && $this->setWriteBuffer($buffer); }
0
caf4b82989eaa7b8853684edcbf0b3c1
9e0b36e5cf5e28233d39d37086a2f112
Command to stop gripper movement.
class MyCobotCommandGenerator(DataProcessor): def jog_stop(self): return self._mesg(ProtocolCode.JOG_STOP)
1
c50ff0b4fff85c6a4f87ce2986d503e3
f2b26e8e03e89570a3a9bc9d863f7e40
插入排序,递归实现
if (nNumToSort === 0) { return; } insertSortRecursion(ArrayInput, nNumToSort - 1); var keyItem = ArrayInput[nNumToSort]; var i = nNumToSort - 1; for (; i >= 0; --i) { if (ArrayInput[i] > keyItem) { ArrayInput[i + 1] = ArrayInput[i]; } else { ...
1
66df71d67744d6e18948054c997a9aeb
57a5a89bdeeba37b94f5742a4b7253b5
调度一个任务在延迟5秒后执行
public class ScheduleTask @Scheduled(initialDelay = 300000, fixedDelay = 300000) public void invokeEvery5Min() { LOGGER.debug("每5分钟尝试执行一次"); }
0
e2bb4b8b33614110f02e7d95dd8029d7
0807c9839f2cf06d7580ca9f10c782db
Metoda rozpoczyna działanie przycisku "Lista rezyserów".
if(Lista==null){ Lista = new JButton("Lista"); Lista.setBounds(290, 350, 100, 40); Lista.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { if(klient!=null) ...
0
f97d7e9c6d2495f355929b6b4fcce179
52dfd3461667e8d834805acd650922f4
Lee un seguimiento de la base de datos
DatabaseHelper dbHelper = new DatabaseHelper(context, SQL_NAME); @SuppressWarnings("unused") SQLiteDatabase db = dbHelper.getReadableDatabase(); }
0
8c473a27babc893acd212558476ec927
1310ab153b6fbb18abc32734c53bfaa2
获取法人证件号码
public abstract String getSfzhm() throws Throwable;
1
f5c67afd7fb75259ddb9822426e5abe1
7f61448ad6da3ef0f9cb03f40c5be655
We assume BigInteger is 0
cases like (1)
0
f0127d586af392d873c0fb69de36f12d
74a72cf4ca6b0f4b6f2f1df6f24461e2
Tests the {@link LibUsb#detachKernelDriver(DeviceHandle, int)} method with uninitialized device handle.
public class LibUsbTest @Test(expected = IllegalStateException.class) public void testGetDescriptorWithUninitializedHandle() { assumeUsbTestsEnabled(); LibUsb.getDescriptor(new DeviceHandle(), (byte) 0, (byte) 0, ByteBuffer.allocateDirect(1)); }
0
f2c71a592dbd944e8bb8fa42fc12bfc6
c29aca25184120bdbac63e556daad4bb
统计最近5天的借款总额
List<Map<String,Object>> countFifteenDaysNeedRepay();
0
cdaea6cccbb7c2493c20c05b606ae22c
f72b56ae5770f89a945c523399e7f56e
更新st_applet_comment对象
{ StringBuilder strSql=new StringBuilder(); strSql.Append("update ZLQ_COMMENT set "); strSql.Append("ZCT_CREATE_DATE=@ZCT_CREATE_DATE,"); strSql.Append("ZCT_CREATE_USER=@ZCT_CREATE_USER,"); strSql.Append("ZCT_LAST_UPDATE_DATE=@ZCT_LAST_UPDATE_DATE,"); strSql.Append("ZCT_LAST_UPDATE_USER=@ZCT_LAST_UP...
0
658aba26ac6af0bfff40f4fdc20ddefe
c80a0325e50c5f1ee6ff2208a907d3ce
Gibt alle KundenkontaktRows für den angegebenen Kunden zurück.
namespace Products.Data.Services public class ContactDataService public dsContacts.KundenkontaktListeDataTable GetKundenkontaktListe() { return this.myKundenkontaktListeAdapter.GetData(); }
0
188a7860a74e76223b32ce8fba7f965d
3388f938e5c819e3cb26e1f7be791263
Test the compression and reconstruction performance of the learned denoising auto-encoder.
def test_dense_ae(dim=24): X = make_timeseries_testdata(in_dim=dim) ae_model = DenseAutoencoder(in_size=dim) print(ae_model.score(X, X)) for _ in range(5): ae_model.train(X, X) print(ae_model.score(X, X))
1
bd46119fea132c979eba85a1767bb80f
418fbbccf6d0f4c11ef9719f2d2bf5aa
Makes it easier to place spawnpoints in Unity by drawing a visual sphere
public class ObjectSpawnerTexture : MonoBehaviour private void OnDrawGizmos() { Gizmos.DrawWireSphere(transform.position, 0.1f); }
1
cf654a0241875f6b530f3a1d538683d7
7eb128226a3ffd9632ac0a58940896ab
Obtener la lista de módulos de cualquier página del tipo pasado en typemodule
class PageController extends Controller public function index(Request $request) { if(!$request->ajax()) return redirect('/'); $num_per_page = 20; $module_filter = 0; if($request->module_filter > 0){ $module_filter = $request->module_filter; } $buscar = $re...
0
d89c77c13c0fe9b98e3d2838339296f5
81ceea5ca92ad515123e00fb464e9cb1
Generates the [pwtc_riderid_download] shortcode.
class PwtcMapdb_File public static function shortcode_upload_file($atts, $content) { $a = shortcode_atts(array('use_return' => 'no', 'accept' => ''), $atts); $use_return = $a['use_return'] == 'yes'; $accept_str = $a['accept']; $is_road_captain = false; $is_ride_leader = false; $current_user = ...
0
3e153b4315e65ba70b3017c2bd0790ad
c305240d65f7f9b6ebddac65906f2e9c
Load all enabled extensions.
if ( self::should_load() ) { foreach ( self::$extensions as $extension ) { $extension_file_glob = glob( JETPACK__PLUGIN_DIR . 'extensions/*/' . $extension . '/' . $extension . '.php' ); if ( ! empty( $extension_file_glob ) ) { include_once $extension_file_glob[0]; } } } }
1
a4a0f16b875dc087463e2dac2e782720
bf757afe6d5d2eaa3952aa866e0f2d04
Checks if there is cpf or cnpj registered in the system.
boolean isSetCpfOuCnpj();
1
4b0f467a490a2aee91a4ad31b9284c22
8d8c310bb6643f6778abee47f006f920
Gets a list of portfolios.
{ var options = new InvokeOptions(); options.RequestMarshaller = ListPortfoliosRequestMarshaller.Instance; options.ResponseUnmarshaller = ListPortfoliosResponseUnmarshaller.Instance; return Invoke<ListPortfoliosResponse>(request, options); }
1
2534ff7a5249d0bd3267374473b2c9f8
a1f9f27f786af7246196bcd3487b6e43
下载某天的数据
class TushareFetch(Hutu): def down_single_stock_day_data(self, ts_code): list_date = self.get_single_stock_list_date(ts_code) self.only_once_stock_daily_by_code( ts_code=ts_code, start_date=list_date, end_date=self.today_date)
0
f574c1c17d82d231c8f69d2f855a9f56
ae45bf1e3c89a649663cfaa683030df9
デフォルト値を持つ表示プロファイルを取得します。
class PublishConfigurationManager public function getDefaultProfile(): ?PublishProfile { return isset($this->profiles[0]) ? $this->profiles[0] : null; }
1
fc712a10e7e5724c1d4e5c8ed234648e
07b5a70a0de1033ef48806228a73886e
Gets the plugin version, as stated in the plugin description file (plugin.yml).
IMachineAdditionalItem additionalItem = null; for (IMachineAdditionalItem item : getAdditionals()) { if (item.getAdditionalId() == 30) { additionalItem = item; break; } } if (additionalItem != null) { MachineAdditional_Z_PluginVersion pluginVersion = (MachineAdditional_...
0
0c1861b4718dcf7ce9eaf8adbaee8877
4ff64371e3794d0a985a929a8afa0a17
The central services instance Kernel Patch level.
class Raptor extends \Slim\Slim public function getAppAspectKernel() { return $this->appAspectKernel; }
0
01c5bd58c6f9c692063924f0f02b47ae
e31698c810f4d0882b960536fe5d10a7
Discover is deprecated; use DiscoverCtx instead.
disc, err := discovery.NewMdnsService(ctx, h, DiscoveryInterval, DiscoveryServiceTag) if err != nil { return err } n := discoveryNotifee{h: h} disc.RegisterNotifee(&n) return nil }
0
50ef30de3ed0d0f4acfdd745b764c061
0e8d4d02978aa490069bfff43c730d2d
医护人员树积分碰撞检测 hpf 计算当前会员积分发生变化所引起的它的上级们的积分碰撞检测 卖出服务订单完成,卖家积分发生变化,引起的它的上级们的积分碰撞检测 积分碰撞由卖出服务订单完成触发的,不需要进行定时触发,是订单手动完成或者自动完成的内置函数 计算的是当前时刻的积分计算 此方法加入队列执行
$extarr = explode("_",$inv['ext1']); $clientid = $extarr[1]; $companyid = $extarr[0]; $ucinfo = $this->db->get_row("select CompanyID,CompanyName,CompanySigned,CompanyDatabase from ".DB_DATABASEU.DATATABLE."_order_company where CompanyID = ".$companyid." limit 0,1"); if(!empty($ucinfo['CompanyDatabase'])) $da...
0
88187308a3092f623d6996924f7ca0ab
125f931f4bb7f9f1acba99f5c4776bab
https://stackoverflow.com/a/33034768/1065880
function copyTextToClipboard(text) { var textArea = document.createElement('textarea'); textArea.style.position = 'fixed'; textArea.style.top = 0; textArea.style.left = 0; textArea.style.width = '2em'; textArea.style.height = '2em'; textArea.style.padding = 0; textArea.style.border = 'no...
1
8bbf03ef405364ba2cd384227cb934ed
a4bbcac91e9c32cfb6aef408dcaffa40
Audit the contents of the local document directory for an new additions. This directory contains documents administrators want to locally add through the file system (as an alternative to the REST API ADD).
public class Refresh extends IntentService private void CheckDocAdditions(List<DocumentTbl> server, List<DocumentTbl> local, String token) { localLoop: for (DocumentTbl jobdoc : server) { for (DocumentTbl document : local) { if (document.ServerId == jobdoc.ServerId) { ...
0
5df45ba0da2fabc43b39da7d4a4c3a5a
5f19e48d603bc0d91e60b810223d5a07
退款步骤详细信息
class NorderController extends Controller public function refund_detail(){ $id = I('post.order_detail_id'); if(!$id){ jsonRespons('false','参数错误',$this->token); } $info = M('OrderList')->where(array('id'=>$id))->field('id,order_id,refund_time,refund_content,status,goods_stat...
1
3ebb2cb8e1c23705ad2ec4ea539f17d1
523074ad724784451d0aaf4334ad2717
Writes name and value for a DateTimeOffset field.
namespace System.Text.JsonLab public void WriteAttribute(string name, DateTimeOffset value) { ReadOnlySpan<byte> nameSpan = MemoryMarshal.AsBytes(name.AsSpan()); int bytesNeeded = CalculateStartAttributeBytesNeeded(nameSpan, sizeof(byte)); WriteAttributeUtf8(nameSpan, bytesNe...
1
c029057c799652db4113a572640b9c75
cce1ac9be57d3e3d6733fc59dc52d4e0
수정할 인덱스, 데이터를 매개변수로 받아서 해당인덱스 데이터를 변경할 데이터로 수정
public class ItemData public void ItemUpdate(ITEM_DATA eIndex, object Data) { m_ItemData[(int)eIndex][eIndex] = Data; }
1
a66ca3aee5b9e2c3aca2baa76b88d9e8
3ebe3e01a3ac55a2fc2b7a598eca9844
for now, just pick the one with the smallest VMO list
{ PCPU_INFO minInfo = NULL; ULONG minCount = MAXULONG; ULONG index; for (index = 0; index < procCount; index++) { if (!cpuInfo[index].active) continue; if (cpuInfo[index].vmoCount < minCount) { minInfo = &cpuInfo[index]; minCount = cpuInfo[...
1
c2dab44ccd1d963e02faf6c3bc31b8f6
889fca7b5409b888b4329d5949c51045
Search events by name Properties: event_name1: string event_name2: string/Null per_page: integer how many users to be returned per page Returns: events: list of filtered events of length per_page next_page: link to the next page Raises: BadRequestError: if event_name1 not received
class EventService public function search($name, $sort, $page){ $repo = $this->om->getRepository(Event::class); return $repo->search($name, $sort, $page); }
1