query_id
string
corpus_id
string
query
string
code
string
label
int64
2cc3cd52126fefa81f97b0ba25128971
aa11efd37cfc8e9dd1c4805ec9dd1f18
Collapses multiple mesh faces, with greater/less than edge length, based on the principles found in Stan Melax's mesh reduction PDF, see http://pomax.nihongoresources.com/downloads/PolygonReduction.pdf
{ if (vertices.Count <= 3) return; bool[] mergeMe = new bool[vertices.Count]; int newNVertices = vertices.Count; for (int i = 0; i < vertices.Count; ++i) { int lower = (i == 0) ? (vertices.Count - 1) : (i - 1); ...
0
2c425714e4396b6efe666af91fabbdda
6106d37b03872bad17a79ab59afb044e
Places the currently selected node into edit mode.
{ if (!_treeCtrl.LabelEdit || _treeCtrl.SelectedNode == null) return; _treeCtrl.SelectedNode.BeginEdit(); }
1
45b64be6e5a471fbd46482cccc5f6d59
6f8f6f3370d6b0730854539c3d1001bc
==== Получение данных по заказанной музыке ====
$musicFileName= ROOT_DIR."\datas\gameMasterData\musicDataList.json"; $musicJson = file_get_contents($musicFileName); $musicArray = mb_convert_encoding($musicJson, 'UTF8', 'ASCII,JIS,UTF-8,EUC-JP,SJIS-WIN'); $musicArray = json_decode($musicArray,true); $musicData = $musicArray[(int)$qdata["musicData"...
1
56be25dce4185074fc4af9c1779cf336
b2f24c1310a8c73389adac3bdc23de31
寻找参数上下限
maxorder = self.numorder(max) minorder = self.numorder(min) if maxorder - minorder >= 3: minlim = 0 maxlim = np.ceil(max / float(10**maxorder)) * 10**maxorder elif minorder - maxorder >= 3: minlim = np.floor(min / float(10**minorder)) * 10**minorder ...
1
ba283f919d23bc9ec8089c3ccf487a4b
cb6d67c4a2ba44972b68ac809c0f369e
更新短信插件信息
@RequestMapping(value = "/config/update", method = RequestMethod.POST) public Object updateConfig(@RequestBody SmsConfig config) { config.setClientId(EsSecurityHandler.clientId()); smsService.updateConfig(config); return JSONResult.success(config); }
1
8c7f2cd83ada10959c14e6ade6b436ca
35026de5e9686880ff62e4a142a51153
获取某时间段中,按月统计数据
List<Statistic> selectMonthByOrganIdBetween(@Param("id") String id, @Param("begin") LocalDateTime begin, @Param("end") LocalDateTime end);
1
db14eee5baa6cf39864e2030f23635f8
e817dfba47175d20bed55cc549b7076c
Добавление незначащих нулей
{ for (int i = 0; i < len; i++) s = s.insert(0, "0"); }
1
7a6e8c03336cf7160491614e656d27c4
14e81bb51e9a409b834e522936ed6ba5
Make sure we make a second request for port details if necessary.
const results = yield callWithSpinning(services.service.getService, { serviceUuid }); results.ports = JSON.parse(results.ports || '[]'); yield update({ service: results }); }
0
5c3b35d840e2cd785276554afb45be25
ca8f359ec2c28cd9da74860931eeb278
returns the directory's list belonging to the selected environment
LASSERT_NUM(args, "dir", 0); int i; for (i = 0; i < env->count; i++) { printf(" %3d: %s\n", i, env->syms[i]); } return lval_sexpr(); }
0
768194af5c351f456d5fe583223cee9a
80eb3600a053d4f6992b74521e6e860e
Get a count of all records from 'RequestType' table filtered by the WHERE clause e.g. --ORDER_DATE = '6/7/2005'-- or --ID=10-- or user='guest' etc.
namespace WebPortal.DataAccessLayer int GetCount();
0
3a4088e2b7a7897bf6f641a62ad90f96
a5f0dbf3638c2f529aa5c2c781dc3d94
Set the complexity and method for the password hash
namespace WebApplication public class Startup public void ConfigureServices(IServiceCollection services) { services.Configure<PasswordHasherOptions>(options => { options.HashAlgorithm = PasswordHasherAlgorithms.SHA1; options.SaltSize = 16; options.Iterations = 8192; }); services.AddPasswordHa...
1
8822cbe1aaae46474fa99100d838de48
289c74bf011a5259759a74ac2da88f67
RTS: Return from subroutine
class Chip8CPU: def _op_rts(self): self._PC = self._stackPop() + 2
1
ee733f93672243a8abfb41e6ef77a1da
bc0ccb724efafbe167afab7abd45d7cb
获取有订单的员工名单列表
{ StringBuilder strSql = new StringBuilder(); strSql.Append("select ID,EMPLOYEENO,`NAME`, e.DINGTALKUSERID FROM employee e where AVAILABLE = 1 and ID IN (SELECT employeeId FROM taskassignconfig)"); if (!string.IsNullOrEmpty(orderBy)) { strSql.Appe...
1
ad63a64b927e1b6730b50387df1ec9f2
4270d48b57f766b227df693f0efb61b9
rasgele karakter dizisi üretir
char verilenKarakterlerden(int karakter1, int karakter2, int karakter3, int karakter4, int karakter5){ while(1){ rastgeleUretilen = rastgeleKarakterUret(); if((rastgeleUretilen == karakter1) || (rastgeleUretilen == karakter2) || (rastgeleUretilen == karakter3) || (rastgeleUretilen == karakter4) || (...
0
290a6cbf1d53a1bfadf8774081974ee1
b1951e50511fd245931214135a997f63
Get the list of all installed sniffers.
class Sniff function getSniffers() : array { return $this->sniffers; }
1
3f6b4b704d47925d8a9c29e0484713d3
69c66ef13a2e3a1cd769ceb8d3757b96
Sets the read only field depending on if the node <see cref="IsAValue"/> or <see cref="HasAValue"/>.
{ Debug.Assert(!ReferenceEquals(this, Default), "Default should be immutable"); AccessDeletedValue = accessDeleted; return this; }
0
9137f3176eb2754d9b01e4643726e079
49cf9560bdcc062ca4036bdea93f8577
Returns true or false if value matches any WebGL enum
for (var p in gl) { if (gl[p] == value) { return p; } } return "0x" + value.toString(16); }
0
4c59cb62bc9031fbffd1750d8d4c287d
08bd80e0982a44c6acfeae22464dab71
Return the value associated with the column: lft.
class Taxonomy extends \ORM\Entity\Taxonomy implements \Doctrine\ORM\Proxy\Proxy public function getLft() { $this->__initializer__ && $this->__initializer__->__invoke($this, 'getLft', array()); return parent::getLft(); }
1
53f0a35d90ba9cc5c6bcd9a67ac6d2aa
cbd592f01d2a9d29956d91330c6a5492
Data do atendimento.
@ApiModel(description = "Objeto AtendimentoCliente") @javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen") public class AtendimentoClienteResponse public AtendimentoClienteResponse dataAtendimento(String dataAtendimento) { this.dataAtendimento = dataAtendimento; return this...
1
897106527d23b2cec92017fd776bf1f5
16b523dc9071d1923a6ad07c0cf97ea6
找出数组中两个数之和为target的所有不重复组合
nums.sort() res = [] n = len(nums) for i in range(len(nums)): if i >= 1 and nums[i] == nums[i - 1]: continue a = nums[i] sum3_target = target - a for j in range(i + 1, n): if j > i + 1 and nums[j] == nums[j -...
0
efdf6f809b1512d7c71b8b84184d7ecf
cc6b80596f63528a3c9210757276eeb5
Returns underground status data
def getStatus60(): global status60 status60 = q_status_get(q_status60, status60) return jsonify(status60)
0
6adfa0ecd27acc2e818ebd6c806ea9a7
77c6f611f5cc990bdc6e9ee33f4a12c4
Another test for series name containing invalid filename characters
class testCreateBarchart(unittest.TestCase): def test_are_create_barchart_params_valid_series_name_blank_str(self): print("@test_are_create_barchart_params_valid_series_name_blank_str") x_data = numpy.ones(3, dtype=numpy.float64) y_data = numpy.ones(3, dtype=numpy.float64) width = 1/1.5 ...
0
1f0037cc2b6cb6e4273483f91ec32a26
10e98e46c37ac2590479f23bc55cbd8a
检查资源版本,回调更新进度条
this.system.checkResourceVersion().subscribe(Endpoint.hotResourceVersion, (data: any)=> { let hotVersion: any = data || {}; if (hotVersion.release != this.hotUpdateTime) { switch (data.type) { case '0': ...
0
bfd382acd930c2f4b9cb89734bdd9daa
72c6d96a5c8e628e34b292e530b0b900
Set background color based on the current thresholds.
start = config.get('colors', 'downloads.bg.start') stop = config.get('colors', 'downloads.bg.stop') system = config.get('colors', 'downloads.bg.system') error = config.get('colors', 'downloads.bg.error') if self.error_msg is not None: assert not self.successful ...
1
69dddace148ceccaa8ec667ad903d4c9
a571789c3652875771d49c79702791da
++prefix
void ${proto.prefix}
0
b28b69d66fcaf4d762416209d2c1d2d5
f2cf3ef32a0b4c52945e6f77e897e7aa
called in tpl-submit.php before step three page content is displayed
public function getViewVarsForStep3(bool $blDBSettingsOK): array;
1
760e72a15101b6b788e9a64aa2030dcf
1b5af3314acc554690ec64013d03eb81
Parses BibTeX records into a dictionary of `.Document` instances
bibDic = {} with open(bibTexFile, "r", encoding="utf8") as f1: records = f1.read().split("\n@") for record in records[1:]: if ".pdf" in record.lower(): completeRecord = "\n@" + record record = record.strip().split("\n")[:-1] rTy...
0
12066d6049eb5cd3d0a77f488e2f5bd7
cb6eebc2357c544870f1894fb989c482
Sets the details about neighbouring edges in the mesh.
self.ExternalEdge = FalseTensor(col(self.Edge), device=self.Vertex.device) if not self.is_volumetric_mesh(): self.ExternalEdge = TrueTensor(col(self.Edge), device=self.Vertex.device) return self.ExternalEdge = self.ExternalVertex(self.Edge[0, :]) and self.ExternalVertex(s...
0
8f346f330e0a0ed9b668953e5609647d
d831f85486134f4fe88ff5d26ad898a7
개인 상점이 열렸음을 통보
namespace SagaMap.Scripting public abstract partial class Event public void OpenShopSell(ActorPC pc) { Packets.Server.SSMG_NPC_SHOP_SELL p = new SagaMap.Packets.Server.SSMG_NPC_SHOP_SELL(); MapClient client = GetMapClient(pc); p.Rate = (uint)(10 + pc.Status.sell_rate); ...
1
fc8f9fbad60690b9bfe96dfed94d58c3
74460b848643070fe530d8b4ea92688e
Output all Fractions
void printFractionArray( struct Fraction fArray[], int size) { for (int i = 0; i < size; i++) { printFraction(&(fArray[i])); printf(", "); } printf("\n"); }
1
e295802a0f61e6246619f5aa0d355e46
d0112ac23bb4413e00af9e07973c921a
Public method: get header menu list (vertical menu)
WebDriverWait(self.selenium, self.timeout).until( lambda s: len(s.find_elements(*self._site_navigation_menus_locator)) >= self._site_navigation_min_number_menus) from pages.regions.header_menu import HeaderMenu return [HeaderMenu(self.testsetup...
1
166d54f11623072c8150c4c069c597ca
a78b52766a67ba73bc93e2d4428b62c4
Retrieves and/or stores a user agent string, and returns the ID number for the DB record.
class tera_wurfl function _UserAgentInDB($ua){ $res = mysql_query("SELECT * FROM ".$this->devtable." WHERE user_agent LIKE ".$this->_sqlPrep($ua),$this->dbcon); $this->num_queries++; $curr_device = mysql_fetch_assoc($res); $ret = (mysql_num_rows($res) > 0)? $curr_device: false; return($ret); }
0
81cdb7464149b57c7ebf0e1f8b35a3a9
31ba2d4a69eb191d20f11653d2308dc3
divides Vector 2 by the value given if the value does not equal 0
function Vector2:div(val) assert(val ~= 0, "parameter val must not be 0") return Vector2(self.x / val, self.y / val) end
1
b29981f00f191a3bde9268f00b4499e9
90f4ce3836e59d636f2206e7180b6193
Converts a command or list of commands to a list of Command objects
public class DOSCommandHandler protected static List<String> makeCommandList(String... commands) { return new ArrayList<>(Arrays.asList(commands)); }
0
6c5c50879fa5217ac6f73dcfcf925875
ff324db9f2eb9dac284af22d56555416
删除系统,以及其下的模块和模块数据
public class ModuleManageService extends HibernateEntityDao<SysModule>{ public void deleteSysModule(SysModule sysModule){ SysModule sm = this.get(sysModule.getId()); Integer fatherId = null; if(sm!=null) fatherId=sysModule.getId(); this.remove(sm); }
0
aef8fb3519382b54d69c4e40851c7b75
7c180d83dbdd39b66093eb8792c4c080
Methode permet de voir si la case peut etre marcher dessus
function isWinable(){ var acessibleTiles = new Array(), accessible = false, quickCoor = [[1,0],[-1,0],[0,1],[0,-1]], newCaseI, newCaseJ, toSpreadTiles = new Array(), tile; for (var i = 0; i < taille; i++) { acessibleTiles[i]=new Array(); for (var j = 0; j < taille; j++) { aces...
0
7cc7aaa81097ce4b1639cf02a5b6ce77
7cbc9842eb9c61bfc8c045a9747bd1f6
關閉 LoginActivity 時解除登入監聽
public class EmailLoginActivity extends BasicActivity @Override public void onStop() { super.onStop(); if (mAuthListener != null) { mAuth.removeAuthStateListener(mAuthListener); } }
1
c32a66657f816a30fd026778eb9e2445
032e39b4cf888e32027a594bf85732b2
传入文件夹路径,经过mtcnn,faceNet得到features写入csv.
vector<string> files; vector<string> labels; get_files(imageDir_path, files); vector<float *> features; for (string file:files) { vector<float *> features_copy; Mat image = imread(imageDir_path + '/' + file); vector<array<int, 4>> coordinates; ...
1
36969fe9c14cab38e6ad5a514d158f12
c6e3e01718da3a5c4e58f0e5452c9f8f
@brief discover a cure to disease with a specific color,
void discovery_behave(volatile canbus *canbus_status) { #if defined(MJ818_) if (canbus_status->devices & _BV(MJ808)) { return; } #endif if (canbus_status->devices & _BV(LU)) { #if defined(MJ808_) util_led(UTIL_LED_GREEN_BLINK_1X); #endif return; } if (canbus_status->devices & _BV(...
0
37c2314bb9adec8018431cbc31d285da
d6c0803fcbf7fb66e57975c09c834c62
Test the copy constructor of the {@link RosterDefinition} class.
{ String definition = "101"; domain.setDefinition(definition); String gotDefinition = domain.getDefinition(); assertEquals(definition, gotDefinition); }
0
864801697aea2932569d87dda0ae1a10
0e5fefc6221c3ee9bca1d5b4fa82519f
\brief initializes true type font engine from SDL lib
int font_init() { #ifndef KUHL_UTIL_USE_FREETYPE return 0; #else if (FT_Init_FreeType(&lib)) { fprintf(stderr, "Could not initialize the FreeType library\n"); return 0; } return 1; #endif }
0
ea49db71e4cb60a36ec617f41ab0c656
fa82506770e0daa9faf8f7a81aafe032
刷新世界等级按钮状态
local player = GetPlayer() if self._mapLevelData == nil then return end for i = 1, 10 do local layout = seekNodeByName(self._RootPanelNode, PANEL_NAMELIST[i]) if self._mapLevelData[i]["index"] < player._MaxLevel then else for j = 1, 3 do local...
1
e59ce0dd16b904afaa48c158cdb35c89
626b298f3391cfd7abba6ce9b3a60e71
get current rotary angle in degrees
float chaosServo::GetAngle() { return curAngle; }
1
56af46961a13c2a9fac3587bbdae8b72
00fce6883f3d17565323877525815ecd
Sets a custom ringtone selected by the user
ContentValues cv = new ContentValues(); Uri uri = MediaStore.Audio.Media.getContentUriForPath(song.getmSongPath()); Cursor cursor = context.getContentResolver() .query(uri, null, MediaStore.MediaColumns.DATA + "=?", new String[] { song.getmSongPath() }, null); if (cursor.moveToFirst(...
1
22af482533012801d666d8b0104acafe
8ec77dfe1ff2002f37addcfb8b216c9f
displaying partial view with ingredient details and options for calculating values
{ if (id == null) { return new HttpStatusCodeResult(HttpStatusCode.BadRequest); } var recipe = await db.Recipes.FindAsync(id); if (recipe == null) { return HttpNotFound(); } var view =...
0
da641fe77c8486d3709b9d819f9968a2
9e1fb4a05a69b75bc31ef15291fd0e70
Get the maximum performance measurement from the set
namespace CX namespace Util CX_Millis CX_SegmentProfiler::max(void) { return Util::max(_durations); }
1
ab19e0308a6b5c997e3605ada885a848
88e606f0116a2ca68c46a37aa3f0ed1b
每轮计算时间的评估函数[Session对象,需要评测的运算算子,测试名称]
t=time() r=func() t=time()-t if not r: return t return t,r
0
503567336467857d8c3825e088d25a51
3528cce6691d383e5294b40f092f73d4
清除赠品预占库存
$goods_num = input('goods_num',0,'trim'); $goods_num = (int)$goods_num; if(empty($goods_num) && $goods_num !== 0){ $this->ajax_return('10490','invalid goods_num'); } $company_id = input('post.company_id','','trim'); if(empty($company_id)){ $this->a...
0
57ebafc43e79bed4832332495f840dee
c40e8a7cd11a09b300e9b9f53df5bae2
a1,a2を通る直線とb1,b2を通る直線の交点計算
def kouten(a1, b1, a2, b2): if a1 == a2: a1 += 0.001 x = -(b1-b2)/(a1-a2) y = a1 * x + b1 return x, y
1
2dd1ad3b0bbba993faa1b32a4fedd188
e1174f4d9d4ab71d1d53dcdc26c41ce4
Gets and removes session attribute
$method = $remove ? 'remove' : 'getValue'; $object = AH::$method( $_SESSION, $name ); return $object === null ? $object : unserialize( $object ); }
1
a49b414e144d835ee3b00ccdbee08539
4f4c2468cabe3e3fa7e272f6997e7e31
Visit async function definition
Token *async = eat_token_if(pc, TokenIdKeywordAsync); if (async == nullptr) return nullptr; AstNode *res = ast_create_node(pc, NodeTypeFnCallExpr, async); res->data.fn_call_expr.is_async = true; if (eat_token_if(pc, TokenIdCmpLessThan) != nullptr) { AstNode *prefix_expr = ast_expect(...
1
17966eb77e913d06e1a6403747a8d3e0
9be16a06e262130c85ca3b39881208a8
character limited excerpt
$length = 100; $text = get_the_excerpt(); $text = strip_tags($text); if(strlen($text)>$length){ $text = substr($text, 0, -(strlen($text) - $length)); $text_mass = explode(' ', $text); unset($text_mass[count($text_mass) - 1]); $text = implode(' ', $text_mass); $tex...
1
f362792f76784a935c57d6c1305c5c76
7a0c006f1125094aa456fca5fdf52a3a
Gets the base class name
abstract class Basis public static function getClass() { return OC_NS_SEP . get_called_class(); }
0
71a12e6b2ba2ce17861ada7ab09e6759
187f06df81ab4ac019cefb2508066b1d
Current unixtime (seconds)
class YRealTimeClockProxy extends _yocto_api.YFunctionProxy get_unixTime() { return this.liveFunc._unixTime; }
1
963098a9b7a2ea2e9f8e962b2c882349
bffbb4290ff1996ce69d6640ad14e16c
Retorna todos los mensajes de una incidencia
list(req, res) { return Note.findAll({ where: { incidentId: req.params.id }, include: userAttributes }) .then(note => { return res .status(200) .send({ data: { notes: note }, status: 'success' }); }) .catch(error => { errorLogs.catc...
1
55a39cfaaf54d1d6ccca318e0cd44fae
6c1c393c29c3f58d5e96831ea172db36
Attach a coupon to a flyer. Returns boolean: Does the flyer need more coupons?
class CLPR_Content_Generator extends APP_Content_Generator public function add_printable_coupon( $post_id ) { $image = APP_Content_Generator_Data::get_image(); if ( ! $image ) { return false; } $image_id = $this->import_attachment( $post_id, $image ); if ( ! $image_id ) { return false; } wp_set_obje...
0
f69a858aa2cec12db9830d9b31369443
bc3afd38d9fa9ed68d5c1a037f1c0765
Función encargada de cargar la conversación
class StudentStore async loadChat(): Promise<void> { const response = await this.amphitryonDAO.loadChat(this.chatToLoad); if (response) { if (response.ok) { this.chat = await response.json(); } else { void this.utils.manageErrorInResponse(response); } } }
1
adf0cb9a4b1c480320901b3a8fc010de
9639b144fbd9dde638802af323677484
配置的路由前缀和中间件
class ChatServiceProvider extends ServiceProvider private function routesConfigurations() { return [ 'prefix' => config('devschat.path'), 'namespace' => config('devschat.namespace'), 'middleware' => ['web','auth'], ]; }
1
db188919cacad4ef7b428c561d939e2c
10ce876af15c529eaa8ad3762855eccf
drag the window only by the means of head-bar
namespace dot_shop [Serializable] public partial class MainWindow : Window private void gridTopBar_MouseDown(object sender, MouseButtonEventArgs e) { if (e.ChangedButton == MouseButton.Left) this.DragMove(); }
1
fcb2eccba0cf30173d45c67da2259474
6aeb7a45f0dae899166e5155c3775776
compare entered values to value extracted from xml file
public class FirstMaintenanceBusinessEntering extends BaseWebDriver{ public boolean compareInsuranceStatus(String insuranceStatusString)throws Throwable{ if(insuranceStatusString.equals(insuranceStatus.getText())){ return true; } else { return false; } }
0
803b16e187821420c13eb2ccc8e1cfba
0b75f2a46d0df28d55fc3a7580159acd
remove YoastSEO JSON-LD to prevent plugin conflict
class Boost_SEO public function remove_rsd() { remove_action( 'wp_head', 'rsd_link' ); }
0
925fe181bc9ed8eda6af5b1858dc8144
27f1f3f37bde69eca8c4883da78e0014
Возвращает глобальный кластерный коэффициент
public class WeightedGraph public double getGlobalClusteringCoefficient(){ ArrayList<TreeSet<Integer>> triangles = new ArrayList<>(); ArrayList<TreeSet<Integer>> triplets = new ArrayList<>(); TreeSet<Integer> triangle; TreeSet<Integer> triplet; for (int node = 0; node < getNumNod...
1
1882e0ccf1ce1a94bddefb6c57ee9479
ecd0e94972c9d48fce0716079f1a1f5e
重写onMeasure设定最小宽高
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { super.onMeasure(widthMeasureSpec, heightMeasureSpec); int width = MeasureSpec.getSize(widthMeasureSpec); int height = MeasureSpec.getSize(heightMeasureSpec); setMeasuredDimension(Math.min(width, height), Math.min...
1
08b395749788a045f94178ddebf0207a
9fc7079f224c46a182ca20f9db5090b9
Perform the Sutherland-Hodgman polygon clipping. Since all side planes are pointing outwards the points that are *behind* the plane are kept.
std::vector<V2f> SutherlandHodgeman(std::vector<V2f> & out, int count) { PROFILE(SutherlandHodgeman); std::vector<V2f> in; const std::vector<Vec4f> planes = { {1, 0, 0, 1}, {-1, 0, 0, 1}, {0, 1, 0, 1}, {0, -1, 0, 1}, {0, 0, 1, 1}, {0, 0, -1, 1} }; ...
1
20c9b6beb07b62d0c61a3c4b78796556
8a9c14ac0322774e42920422ac938fcd
Unique initialization of the snps interface
class ScanInterface: def __init__(self, *args, **kwargs): pass
0
b818dea2d361505095edffe34a729543
88f83b9f33ecc3c05144e4e0963b34f0
Task to write samples to our server
c = "|/-\\" n = 0 while True: arr = np.random.rand(NUM_FEATURES) socket.send_multipart([ TOPIC, arr ]) time.sleep(1 / SAMPLE_RATE) n += 1 print(f"\r{c[n % 4]}", end="")
1
1d9406449ff8aad3e6a81b8efddd5d63
ec85ef45338fe8c1c0ac60b81af074c3
Handles the PostRequestHandlerExecute event of the Application control.
namespace ApplicationEvents public class MvcApplication : HttpApplication protected void Application_PostRequestHandlerExecute() { Debug.WriteLine("Application_PostRequestHandlerExecute"); Response.Write("<p>Application_PostRequestHandlerExecute</p>"); }
1
3530672aeb98315ed9d188d5a8862d97
ab4fd862dc5486dfb9e80bfbf3b6b0b2
Remove any user instance from this list.
public class UserList implements Serializable public void removeUserFromList(User u) { users.remove(u); }
1
faa69c90984157ca753d5b584bed38b7
eaf053191e587ddbcd1cec03ca5d7d72
Creates a non-editable widget to display the detailed stack trace.
assert EventQueue.isDispatchThread() : "Must be called on event thread"; final JLabel result = new FixedHeightLabel(); addUI(new ValidationUI() { @Override public void clearProblem() { result.setText(" "); result.setIcon(null); } @Override public void setProblem(final Problem problem) { ...
0
ff7fd9fc963fc736ebaa5d7293c30b4a
6845b903ee55d740bc7d9280e8dcb7c7
IDが既存した際のエラーメッセージ取得メソッド
const r = await Book.findByPk(id); return r ? null : invalidateMsg.invalidIdMsg; }
0
24bb8715a4020b75d7a578442e8d6a14
fac2b95ff476f20006def7731cad5d40
Returns <code>true</code> if JavaScript compression is enabled.
public class HtmlCompressor implements Compressor public boolean isCompressJavaScript() { return compressJavaScript; }
1
257b8a5a5a905028ce203b4d11bd1ec6
0c25a42f2ea6498711299d7e481d9c7e
Check to see if CopySourceTagsToRestoredResource property is set
namespace Amazon.SecurityHub.Model public partial class AwsRdsDbInstanceDetails internal bool IsSetCopyTagsToSnapshot() { return this._copyTagsToSnapshot.HasValue; }
0
66197215c84f1117d06a1a0b6be159fb
14efb90d175aefde6bc700354cc101e3
Enable navigation drawer.
@SuppressWarnings("Convert2Lambda") public class MainActivity extends AppCompatActivity implements FragmentManager.OnBackStackChangedListener, Theme.ChangeableTheme, BowlerFragment.BowlerCallback, LeagueEventFragment.LeagueEventCallback, SeriesFragment.SeriesCallb...
1
57afc9f7cf4cdc914cf082dcaa5c158e
d67756d9dd1ff5c0c7e8864f44817375
在鼠标放到head上时,显示排序箭头,离开时隐藏,点击箭头,按箭头命令排序。
$('.details').each(function (i) { $(this).mousedown(function () { $(".headPortrait").unbind("mouseenter"); $('.content').sortable(); $('.content').sortable('enable'); }); $(this).mouseup(function () { $('.content').sortable('disable'); ...
0
e699d5e33b489b86f936299329bc23e1
d5d1dc7abb4f0a9be02653760da5fa0e
Método para listar todos los ciclos que no tienen tutor
public List getCiclosDeProgramaSessionExperteByCriteria(CicloDePrograma ciclo);
0
f084f107e57fe03df12bd08321eca685
b569f3f956a41844b06125a95efa40c3
replaces an old instructor with a new instructor
DepartmentalInstructorDAO idao = DepartmentalInstructorDAO.getInstance(); org.hibernate.Session hibSession = idao.getSession(); Transaction tx = null; try { tx = hibSession.beginTransaction(); DepartmentalInstructor inst = null; String instrId = form.getInstructorId(); if (instrId!=null && instrId....
1
d762698928a638b7ac36700997a75119
92c016bf75b0cdae2888cdfd1b970219
function outputs the minimum number in the file
void findSmallestElement(int list[]) { int* min = min_element(list, list + 8); cout << *min<< "is the minimum number" << endl; }
0
6a7fa53f6e229ef85beb2300767b4e49
410745ec274977eaa037dfad2fc780f8
Print all student info (except email addresses)
class Student void printAll() { for(String info : studentArray) { if(info != null) { System.out.println(info); } } }
0
3319420c3464deea5a1358594c99fc9c
7b14a20668966ce72714c802331b41ad
Sets the repetition rate of the laser. Rate must be a positive integer from 1 to 5 (# of Hz allowed). Returns True on nominal response, False otherwise.
class FiberShootingGui(GUIBase): def set_frequency(self): if self.laser_status: self._fiber_shooting_logic.set_frequency(self._mw.frequency_spinBox.value()) else: pass return
0
1a0e1ece49cd40b4586e226b66b96f7a
aa905bd6ce1f3d54497e3215aa1077a7
Создание справочника замен
class MyWin(QtWidgets.QMainWindow): def make_dict(self): self.sql.execute ("""CREATE TABLE IF NOT EXISTS dictionary ( English TEXT, Russian TEXT) """) self.db.commit() for i in range (self.ui.tableWidget.rowCount ()): if self.ui.tableWidget.cellWidg...
1
d5c0e54fcab81bf652620aa4a498b5e5
f72b3f220e97297fed66155a25a51703
Update a software information to the database
{ try { return this.mySoftwareUpgradeAdapter.Update(this.myDS.SoftwareUpgrade); } catch (System.Data.ConstraintException) { throw; } }
1
4eedaa831ec709ec0d5b1b05edad7a34
3af8fc4b79912cad706d7d8ff8d16d27
Wrapper to scipy.optimize.leastsq to fit data to an arbitrary function.
errorfunction = lambda p: np.ravel(gaussianBG(*p)(*np.indices(data.shape)) - data) p, success = optimize.leastsq(errorfunction, guess) return p
1
2101fab85e31a28f0bfe9343bebe7d8d
edae890835d3f1f0187ca1873adf8d2d
Ensures ALL items in the given collection satisfy a predicate
public static class ListExtensions [Pure] public static bool ForAll<T>(this IEnumerable<T> list, Func<T, bool> pred) => LanguageExt.List.forall(list, pred);
1
b2a08472c79158beb4ed3f7067b81694
80e8197ad181e4bb71a0ba2238fa7842
returns a function when applied with an element checks if that element was expected in the right order
public function createConsecutiveCallback(InvokedCount $matcher, array $arguments, int $index = 0): \Closure { return static function (mixed $arg) use ($matcher, $arguments, $index): bool { $expectedArguments = $arguments[$matcher->numberOfInvocations() - 1]; $expectedArgument = $exp...
1
283e2b423313c7acfe06fb4ee7f9c8c0
c7ed7820471608adc4aa5ee06ce3b819
@brief Update simplebridge by ID Update operation of resource: simplebridge
delete_simplebridge_fdb_by_id(const std::string &name) { auto simplebridge = get_cube(name); simplebridge->delFdb(); }
0
5d533e7be473a8d413d389069be4e127
760a9cf8f3257321952a1bc45a1a5191
Forces a lateral change by the given amount (negative values indicate changing to the right, positive to the left). This will override any other lane change motivations but conform to safety-constraints as configured by laneChangeMode.
public abstract class Vehicle extends Entity public boolean changingLanes(double startX, double startY) { double xDir = startAngleCos; double yDir = startAngleSin; double midX = startX + VehicleLane.LANE_WIDTH*xDir; double midY = startY + VehicleLane.LANE_WIDTH*yDir; double endX = startX + VehicleLane.LANE_W...
0
2da143e566150d449288c6c8a97d6770
6daca1353b5d0f2806a0a29d26bd943a
Marks the specified entity for deletion. The entity will be deleted when <see cref="IDocumentSession.SaveChanges" /> is called. <para>WARNING: This method will not call beforeDelete listener!</para>
namespace Lib.Models public abstract class EntityBase<TKey> : IEntity<TKey> public virtual void MarkForDeletion() { IsDeleted = true; }
1
0d7ade9c855dd786f89f711741a3539f
7dd5097022fc23416092a4e653fb5dc8
Returns all first-order dependencies of an asset.
namespace MotionFramework.Resource string[] GetAllDependencies(string assetPath);
1
be13758fc0ea5dfd8a337f6acfd8cf16
eedda1a2cf3dd89e228ac9731628d9f0
Get the todo file instance
cwd, err := os.Getwd() if err != nil { return nil, err } return &Todos{filename: path.Join(cwd, "todos.json")}, nil }
1
66714506378e668c517e58d2fa8a4211
c56618c376845653ee04c53326bac6fa
Retrieves the parse mode. The parse mode, or NULL if the query was aborted.
public function getFetchMode() { return reset($this->fetchArgs); }
0
d15568b42b25b86428525c9d64781149
1b2153b62e7114831840cab24a73f583
validates suite attributes structure for creation
valid_paths = attrs['_valid_paths'] for dv in attrs.get('default_values', {}): if dv not in valid_paths: raise StructureError("%s: Error in default_values: can't find %s in structure" % (name, dv)) if mcs._is_nested_structure_in_list(valid_paths, dv): ...
1
9423e120cb5cc8089a41a28273b39f48
8da2e27f80c40192cc8c7f5453c9a278
Signals that {@code getClass} is used in the implementation of the {@code equals} method, instead of an {@code instanceof} check.
public boolean equals(Object object) { if (object instanceof Class) { if (getName() == null) { return ((Class)object).getName() == null; } return getName().equals(((Class)object).getName()); } return super.equals(object); }
0
a0f01be44cef39790448086b6c365833
b9447b23c22d1304f9dad87ed142da41
Add a bbcode to the bbcode-list
class Parser public function addCodeDefinition(CodeDefinition $definition) { $this->bbcodes[$definition->getTagName()][$definition->usesOption()] = $definition; return $this; }
1
5d6e957849f26ddf727edd63624a7375
91526b56802d38f02b0dce1571243ff6
Create child element {@odf.element draw:control}.
public abstract class TableTableCellElementBase extends OdfStylableElement public DrawCaptionElement newDrawCaptionElement() { DrawCaptionElement drawCaption = ((OdfFileDom) this.ownerDocument).newOdfElement(DrawCaptionElement.class); this.appendChild(drawCaption); return drawCaption; }
0
c1a394899b0493bd4e728306b532f6b1
97e50b940dcf36121b48ad2e1594a9b6
首次渲染时,组件挂载完成调用该方法,只执行一次
class HelloWorld extends PureComponent componentDidMount() { console.log('渲染ok') }
1
dc7ef78d722b2add3a8a5b9c3c7ef170
bbb8cf00149dd3f7fb0364e29c8e6615
设置关闭按钮样式
function CommonCostNode:setCloseMode() self._closeMode = true self._textName:setVisible(false) self._nodeNumPos:setPosition(cc.p(0, -40)) end
0
ea4c12c7dd2b4927a7816d73478df481
02c5bed5958f577fd289ff8cc6dae854
Creates a single-use token that represents the details for a person. Use this when creating or updating persons associated with a Connect account. See [the documentation](https://stripe.com/docs/connect/account-tokens) to learn more. See [Create a person token](https://stripe.com/docs/api/tokens/create_person) By defau...
class Client extends \Jane\OpenApiRuntime\Client\Psr7HttplugClient public function postTokens(\Stripe\Api\Model\V1TokensPostBody $payload, string $fetch = self::FETCH_OBJECT) { return $this->executePsr7Endpoint(new \Stripe\Api\Endpoint\PostTokens($payload), $fetch); }
1
184c0faaced6a2db7a97ae7ae9c4e919
686353f9a0957f99c47671f1697fbd98
SubstructureSearchパラメータ入力画面に戻る
public class KuracKuraChokuDataIn_EditFunction extends KitFunction private void back() { editList = (KuracKuraChokuDataInList) getSession(KEY_SS_EDITLIST); editDtList = (KuracKuraChokuDataInDtList) getSession(KEY_SS_EDITLIST_DT); editDtList.initListToMax(editDtList.size(), editForm.getMaxSuDt()); releaseHaita...
1
9b1f841b5134205065eeaa16739459a6
350b04c79ed849f232bee3c6554d4353
Funcion que retorna false si alguna casilla ha dejado de llenarse
class Game extends React.Component verificarGanar(){ var verificaF = true; var verificaC = true; for(var fila = 0; fila<this.state.filaSatisface.length && verificaF; fila++){ if(this.state.filaSatisface[fila] === undefined || this.state.filaSatisface[fila] === false){ verificaF = false; ...
0
bb062105c991e797169c95c7da39be67
ac72693b89f13d548382c471e264962a
************POWER OF A NUMBER***************
public class Factorial static int power(int b,int p){ if(p==0)return 1; else return b*power(b,p-1); }
1