query_id
string
corpus_id
string
query
string
code
string
label
int64
62f86c14b1204d2cbcccf16e82938e19
4db46f7f3aae782c22725782137f513b
Testing scenario when server error on second page
{ $client = static::createClient(); $crawler = $client->request('GET', '/order/step2'); $this->assertFalse($crawler->filter('#order-step2')->count() > 0); }
0
3745ec3cfae36294493891a3f62c1029
190e3cc0e2f9e4432c5fb65936440a76
Displays all possible commands to choose a network error
View.print("Command not found:" + "\n" + View.STR_DISPLAY_ALL_COMPUTER + "\t" + View.STR_DISPLAY_ALL_LNK + "\t" + View.STR_DISPLAY_ALL_REPO + "\t" + View.STR_DISPLAY_SPECIFIC_COMP + "0" + "\t\t" + View.STR_DISPLAY_SPECIFIC_LINK + "0" + "\t\t" + View.STR_DISPLAY_...
0
944de7ec5739f502b2d86714831472ce
14f19ca2941b224df4ac551b34228975
Gets the parameter value to be passed to invoked method.
CacheInvocationParameter getValueParameter();
1
01d387b7484a1b7dba8fc7fa56e813b8
456d0d70633174d3ddb3accffdecdc1f
Get expositions.
self::$logger->debug ( __CLASS__ . '-' . __METHOD__ . ' begin' ); if (! isset ( $expositionId ) || $expositionId == null) { self::$logger->error ( 'expositionId parameter expected' ); throw new InvalidArgumentException ( 'expositionId parameter expected' ); } $list = array (); $expositionFilter = new Nu...
0
a9114aaec3625e6bd8fc69f0cfbb27b4
4c9ae576f3e5a471047ee4102c78d7ed
<PRE> 1. MethodName : getTreeGroupSummaryList 2. ClassName : AxisTreeBizComp 3. Commnet : 트리 조작 화면에서 보일 트리 그룹 리스트를 return 해 주는 method 4. 작성자 : Jack 5. 작성일 : 2011. 12. 6. 오후 4:35:32 </PRE>
public class GroupBiz public ArrayList<GroupModel> getSearchGroupNoTree(Connection con, String grpId, String grpName) throws SQLException { CmnCmbsortConfDao sortDao = new CmnCmbsortConfDao(con); CmnCmbsortConfModel sortMdl = sortDao.getCmbSortData(); GroupDao dao = new GroupDao(con)...
0
9616c19d8177a62b86728fb1ef7dc5e1
7c3b1014579102995a14b2ad52e92bd2
This routine parses all of the info out of the cal file. It calls the individual parse methods for each of the gauges based on the gauge flags. Each of the special gauge parse routines will return a dictionary with the cal info
class ProjectData(ResisticsBase): def getCalInfo(self): self.calFiles = getFilesInDirectory(self.calPath)
0
1d9a88b08c37c0f98cbeab141bf2b3f4
c933c8ae5e580a79d93425397c9db250
保存条件リストより、検索条件の項目の再現
{ if (!empty($result)) { $item_ids = array(); foreach ($result as $k => $v) { $item_ids[] = $v['Work']['target_datum_id']; } $this->Item = ClassRegistry::init('Item'); $params = array( 'conditions' => array( 'Item.id' => $item_ids, 'Item.is_deleted' => 0, ), 'recursive' => 0,...
0
ff96b2c15e8c8efa5d175769480544e3
157a732f4f3a8d0fa152b5e260b80ce8
If {@link #showAllProps} is false, only standard descriptors are considered.
static get showProperties() { return showProperties; }
0
e1cf628d1dee85948cedf52fbea1442d
2c10417d17e328c4ebdeab27a15e5a18
thêm tên cho các phần tử chưa có tên
{ List<PositionEntity> list = PositionDAL.GetAll(); if (list.Exists( delegate(PositionEntity oldEntity) { bool result =oldEntity.sName.Equals(entity.sName, StringComparison.OrdinalIgnoreCase); if(!CheckInsert) ...
0
ed028aceffbb8f6f629b7b2ac3f9318c
33baae1ff6b4aa119f4c5e701dd4ad2b
刷新当前的位置
const that = this; wx.showLoading({ title: '正在刷新位置', }); api.getLocation().then(res => { that.setData({ latitude: res.latitude, longitude: res.longitude }); wx.hideLoading(); }); }
1
205e72e4f3a6fa8d4dc014e73897ce3e
f8c2f896eb29f85cf2d3872b02a60561
Checks to see if a move between two sets of coordinates can be made for a Rook piece.
int tempLoc; boolean validCheck = true; if ((destination.getRank() == source.getRank() + 2) && ((destination.getFile() == source.getFile() + 1) || (destination.getFile() == source.getFile() - 1))) { tempLoc = (source.getRank() + 1) * 10 + source.getFile(); if (boardLoc.contains(tempLoc)) { validCheck = ...
0
bf6da0986635d46287bdbd3591a09d4a
0f667118ee10ebf6d86ecd666aa5dfc4
Returns the footer metadata; used by the `<layer-standard-message-view-container />`
{ return [ 'data' => [ 'type' => 'footer', 'footer_id' => $this->id, 'attributes' => [ 'site_name' => $this->site_name, 'site_note' => $this->site_note, 'site_address' => $this->site_addre...
1
5098acec0e9c4cddd407f148e71bf7a6
3371d3b206fddd3f2ca6dc1cb949d02f
Tests that a state handle is replaced.
{ $this->initializeProxy(); $that = get_class($this->proxy); $this->proxy->unregisterState(\substr($that, 0, \strrpos($that, '\\')).'\\States\\state2', $this->state1); $this->assertEquals(array('state1', 'state3'), $this->proxy->listAvailableStates()); }
1
0f58513053070941ee7a850787d10933
f8010b0cc4db6d2e08184011f747886c
Hook up collision events with their handlers
void CAW_Hitmarker::initialize() { g_pGameEventManager->AddListener(this, "player_hurt", false); g_pGameEventManager->AddListener(this, "bullet_impact", false); }
1
410516f163e036132a0d11a576278b65
f893c19a97b75430e1f37f17eba49500
Makes a KDE plot using the specified column in the dataframe.
def distribution_plot(df, column_name): sns.displot(df[column_name], bins=35)
0
f347137d4fc761627b6a1555b75ce88f
425067c506d2590d3fa826bfc5bd93c8
检测创建房间状态
self.driver.find_id(soucred_id + 'create_room').click() time.sleep(2) self.driver.find_id(soucred_id + 'check_normal').click() time.sleep(2) self.driver.find_id(soucred_id + 'crate_room').click() try: self.driver.wait_id(soucred_id + 'chat') except: ...
1
51b74a1ecd728845ba0dbc6dc11e2dc7
a91cee398c82733fab72cc4543ec3524
重新设置显示教师详细信息表格大小
{ ui->infobox->setEditTriggers(QAbstractItemView::NoEditTriggers); QHeaderView* headerView = ui->infobox->verticalHeader(); headerView->setHidden(true); ui->infobox->setSelectionBehavior(QTableWidget::SelectRows); ui->infobox->setShowGrid(false); ui->infobox->setColumnCount(2); ui->infobox->...
0
6a94202f969f0f188970650cefdfffcd
6275c818d9377738b5cf8c1ab5e9dad9
Override the group slug in permalinks with a group's full path
function buddyblogmusic_use_slug_in_permalink() { return apply_filters( 'buddyblogmusic_use_slug_in_permalink', false ); }
0
86b013614e8a3481b43fde57363affcf
7b6125bc69be787bc1064f95d270c7f4
Schreiben des Indexes im Backend. (Limit von Seiten der Tabelle von Kontrasten + weitere Aufrufe)
class IndexerPage extends BackendPage function OnIndex(){ $indexer_path = $this->Kernel->Package->Settings->GetItem("INDEXER", "IndexerPath")."indexer.phtml"; if(file_exists($indexer_path)){ ob_start(); $u=$this->Auth->userData; $POSTSecret = base64_encode($u["user_id"].":".$u["user_lo...
0
1ceb2c95b6359c28d89318ad23a3e654
22532f7e13ed6f2f9c519b7e3b817cdd
Simulate the gamma ray according to Butcher & Messel: Nuc Phys 20(1960), 15
double getGamma( double gammaC, double Ecm, double A1x, double A2x, double Z1x, double Z2x, double Lx ) { double Gamma; if( Ecm <= 0.0 ) { Gamma = 0.0; } else { if( A1x==0.0 || A2x==0.0 ) { Gamma = 2.0 * gammaC * gammaC; } ...
1
4494e5be705013eed59b0397653f4781
d0c60a37e0e6976cb0ad6e4b9e118fee
GET: Trademarks
class TrademarkController extends Controller public function index() { $data = ThuongHieu::latest()->paginate(2); return view('admin.trademark.index',['biendata' => $data]); }
1
3a7d89ba62c6e8eb06b1b5a51fea61d5
b934bfa47c3667e9dfc731e4ae1ffd4a
Clears the error message set in the MPD.
class SLMPClient(object): def clear_error(self, timeout=0): self.__cmd_format(timeout, const.SLMPCommand.ClearError, 0x00, b"")
1
b1505103e5fc405568470cc87367de17
b3735a4baa6bdd39698ed1be0594a3df
Check for an included file in the given include directories
{ int i; for (i = 0; i < num_include_dirs; i++) { if ( strncmp(srcfile, include_dirs[i], strlen(include_dirs[i])) == 0 ) return(TRUE); } return(FALSE); }
1
3ab305f1931e189c73dbfd5e5ab96229
abb76e26cd397987cdc8d636cf5405ad
创建签单的课程信息
{ $courseSign->class_id = $class->id; $courseSign->course_id = $courseId; $courseSign->sign_status = $status; $courseSign->sign_date = $course->day; $courseSign->is_used = 1; $courseSign->class_type_id = $class->type; $courseSign->operate_user_id = $operateUse...
1
c3805b8a6c368246e4c5c2cc67c317ee
74eb6e4c461a3186f32f2dfcfd534c77
ProvinceRepository constructor.
class ProvinceModel extends BaseModel public function __construct() { parent::__construct(); $this->dbClass = new ProvinceDb(ProvinceTable::TABLE_NAME); }
0
05b52042dd4195f2eb548b237ecd22b4
74b42187312f609953f883cc5627a58e
Método que define o alcance da máquina (altura da árvore que poderá alcançar)
public class MiniMax public void setMaxDepth(int maxDepth) { this.maxDepth = maxDepth;}
1
de491a337c472817dc3f09f9619ec375
eebbd036f86cd6b4b1e871a112632dcf
Some view mixins assume that the thing they're mixed with will define self.get_object. Therefore we provide a class that does only that, and which we can initialize to return whatever we need for the test.
class StringFieldTest(TestCase): def _get_target_object(self, *args, **kwargs): from pyny.fields import StringField return StringField(*args, **kwargs)
0
f9d956ac644af21817734a84804d4322
ba556bdfedd327a07fdc1684c05acb36
Crea una nueva categoría de artículos
public function createCategory();
1
10c5128f30eed119f1b9fbc339df98bf
0d610ac2551363f71ace589719088908
Retrieves a previously created assertion for a given request.
LOG.debug("ResponseString: " + responseString); final String assertion; if (responseString.contains(BEGIN_ASSERTION) && responseString.contains(END_ASSERTION)) { final int beginIndex = responseString.indexOf(BEGIN_ASSERTION); final int endIndex = responseString.indexOf(EN...
0
41170a143b95997061699cf806b7814e
0ddbaf9e85c4717b5f0717a57efd96a7
Httpレスポンスステータス実行結果を取得
abstract class AbstractResponse implements ResponseInterface, IteratorAggregate public function getStatus() { return $this->getResponseResult()->getStatus(); }
1
aa833de80fa582e4912b4ae0a497b9d6
4e0fb625b96dd7eba217763ff5893285
Return a list of user and setting pairs where the setting value matches the given wildcard string
return [get_pref_def_result(pref_def, user_prefs) for pref_def in pref_defs if if_query_str_matches(pref_def['id'], pref_key_query) or if_query_str_matches(pref_def['name'], pref_key_query)]
0
afac46d057227a937e9c49c9eed3be09
eceb70d4d37082c3b51cc3278ed69014
# Returns the Manhattan distance between two locations
x1 = (current-1) %/% grid_width y1 = (current-1) %% grid_width x2 = (target-1) %/% grid_width y2 = (target-1) %% grid_width return( myEuclideanDistance(c(x1,y1), c(x2,y2)) ) }
0
63fc2c7e516d2e4feca0ebb0e3e33df2
204bb88a3d12ac520fcc15316598467f
Handles the Elapsed event of the UntouchableTimer control.
namespace TomcatUI.Modules.UserInterventionPage.ViewModels public class UserInterventionPageViewModel : NavigationAwareViewModelBase private void OnTimerElapsed(object sender, ElapsedEventArgs e) { RaisePropertyChanged("LapsedTime"); }
1
afa957bc2dadd8cc3de923b7b0e7fdf6
7fcb10f8c6db5dca6ca7c440983a40f7
Return a position and velocity vector for a given date and time.
namespace larcfm Position Plan::position(double t) const{ return positionVelocity(t, false).first; }
0
49179b7c27665aea52a90bb15ba97b86
d1684a084815ac4b90bb779c2596e38e
Updates a single item by ID
class CRUDCollection(Generic[T]): def update(self, item_id: str, item: T) -> None: self._items_by_id[item_id] = item
1
e954320fce5fd89325eb35afa617de13
b831831fece6a1b5c7d8ec486251ca35
Performs Basic LICMi
static int licm (MIR_context_t ctx) { struct gen_ctx *gen_ctx = *gen_ctx_loc (ctx); #if !MIR_NO_GEN_DEBUG if (debug_file != NULL) print_loop_tree (ctx, FALSE); #endif BFS (ctx); calculate_dominators (ctx); VARR_TRUNC (bb_t, licm_temp_bbs, 0); VARR_TRUNC (bb_t, loop_bbs, 0); VARR_TRUNC (bb_insn_t, loop_st...
1
2520315c0dca9aa315f8e236c0f25e71
7fd8bc062210c5aec59cfab8b34e0f21
load danh sách bàn trống
namespace LuanVan.Areas.Admin.Controllers public class AdminController : Controller public ActionResult LstBanAn() { SelectList dsPa = new SelectList(dc.PhongAns.ToList(), "Phongan_id", "phongan_ten"); ViewBag.dsPha = dsPa; return View(); }
0
ddb3feeef7052ee81a9a527aea51d56d
aa2aec2fd2c3c32a664217598bec0d42
Only works with format like: 2021-05-29T09:00:00-04:00
function time_fromHuman(string) { if (string.match(/^[0-9]{4}-[0-9]{2}-[0-9]{2}/)) { string = string.replace(' ', 'T'); string += ':00.000Z'; time = Date.parse(string); time += (new Date()).getTimezoneOffset() * 60e3; } else { string = string.replace(' at', ''); time = Date.parse(string); } retu...
0
ff6a8d63e418f30fd0903589c9b721db
e94cdaf19ac9e386d22123039c706a6d
Glob route: '/path/*' - Rewritten to be a RegExp: ? becomes (.) * becomes (.*)
RegExp getTokenRegExp();
0
37b0116f668f029186f31682525726a3
9b3519a12f1c1d14918a7b2ddf934d17
Funcion encargada de activar/desactivar trabajadores
function disableEmployee(_id, _checked) { jQuery.ajax({ url: currentURL() + '/app/employee/enable', data: {'_id' : _id, '_enable' : _checked}, cache: false, contentType: 'application/x-www-form-urlencoded', type: 'POST', beforeSend: function(req) { showWaitDialog('Actualizando...'); ...
1
15fe072c47e1a75acd8ba03632878319
7f555bc0b0a671f8bd0bb3c6791171eb
State thread - periodical dump of the queues.
while not self.is_finish(): print('sending_queue:%d; sended_queue:%d; response_queue:%d' % (self.sending_queue.qsize(), self.sended_queue.qsize(), self.response_queue.qsize())) import objgraph objgraph.show_most_common_types() time.sleep(300)
1
9d9d4f762a413fcb2125a79f1ded289a
1d28186f3d396b4de9ee66a5f11cdd0b
Terminar el controlador del raton.
class JAMediaWebCam(GObject.GObject): def stop_rafagas(self): self.__set_estado("playing") if self.control_rafaga: GLib.source_remove(self.control_rafaga) self.control_rafaga = False
0
7351f65c23dd834990fc53b89971002a
68e6173acdf964cd3c003bbf704aeaf5
Tests the "community is inactive" fail condition
class AlertableTest extends TestCase public function testSchedulePresentationAFailInactiveCommunity() { $communityId = 7; $presentationLetter = 'A'; $this->_testSchedulePresFailInactiveCommunity($communityId, $presentationLetter); }
1
5514daf7c375a2bcd41a61f8f39c5b77
a69ebceb83e681db3181312fb62603e5
更新B类BO等级
{ boss_level = index; if (is_multi) { boss_level += 4; } ChangeStatusContent(boss_level); }
0
01e264b16bb168b1e546ad24d30656af
b2c71f329c0505899950677b61e51f7b
权限申请成功时打开摄像头
public void onSucceed(int requestCode, List<String> grantedPermissions) { if (requestCode == 101) { selectVideoFromCamera(); } }
1
4fbe62fc9adcc2cdaf4f54c2588aebab
16ec51eb089ab88a2c6b0b3be227517b
Get source page file format such as "XLF", "XML".
class GSC_Datafeed extends _GSC_AtomElement function getFileFormat() { $el = $this->getFirst(_GSC_Tags::$file_format); return $el->getAttribute('format'); }
1
3224b0eef492ad16b626ab3d966e13c9
e457febdaaf817d817035c0898795865
! Function that calls all the invkin modules and retrieves the computed joint velocities.
class inverse_kinematics(): def kinematics(self): self.ball_vel.xdot = (math.sqrt(3)*(self.motor_vel.w2-self.motor_vel.w3))/(3*math.cos(self.phi)) self.ball_vel.ydot = (self.motor_vel.w2 - 2*self.motor_vel.w1 + self.motor_vel.w3)/(3*math.cos(self.phi)) self.ball_vel.wdot = -(self.motor_vel.w1 + self.moto...
0
53c33463e52db95428ff464e1ae4e866
70960fedd7fb7226f41dc0998a04c6cf
Gets the number of cores available in this device, across all processors. <p>
public class TheCPU public native int getNumCores ();
1
a595820a4ae8a32b74161340ea96b9c8
82d4016b74bc81ee7617b831e166c5e8
初始化参数配置(这些参数是配置在SDK服务器上的一些敏感数据)
public void initConfigParams();
1
66040c5e1f08292c98cdb5ee8967ac26
200161dbef1c312d906a74fd930a6db8
Computes the batch size from number of batches and amount of training samples
def calc_batch_size(num_examples, batches_per_loop, batch_size): assert batch_size > 0 assert num_examples % batches_per_loop == 0 while num_examples % (batch_size * batches_per_loop) != 0: batch_size -= 1 return batch_size
1
bae06f9de9f2804d9ca4b12960868e07
080a1769dd881a245fea6f1ecc94f030
进入货物信息Detail信息页面
public String GoGoodsInfo(HttpServletResponse response,HttpServletRequest request,Model model){ UserInfo userInfo=(UserInfo) request.getSession().getAttribute("userInfo"); if(userInfo!=null && userInfo.getUserRole()!=null){ String GoodsInfo="货物管理"; model.addAttribute("GoodsInfo",GoodsInfo); return "tem...
0
0eaabcf1a8973ea8291a914e48a841e0
ada561a26ed85440d30d3a599a179ff6
рисуване на игрището
class Game: def draw(self): self.all_sprites.draw(self.sc) self.all_sprites.update() self.blocks_sprite.draw(self.sc) self.blocks_sprite.update() self.platform_sprites.draw(self.sc) self.platform_sprites.update() self.ball_sprite.draw(self.sc) self.ball_sp...
1
98b4e36371ad818d4d6346c48dca4db3
518eff24a029ebf9cbd883bd6ec5a965
Constructs the holdings dictionary that is "as of now
d = dict( (k,v) for k, v in [(s, 0.0) for s in self.symbol_list] ) d['cash'] = self.initial_capital d['commission'] = 0.0 d['total'] = self.initial_capital return d
1
9841398504c91dbeeba1c268e49b0d4a
71f8a7cbad43ad080348259b6356afb6
Set ownership of a faked file.
static int fg_chown(const char *path, uid_t uid, gid_t gid) { DEBUG("FG_CHOWN"); int r; if ((r = repo_chown(path, uid, gid)) < 0) return -ENOLINK; return 0; }
1
a303d99fcc1e46540738dcadb682b0b0
dce75c32d021e7f3fd3f9274947d9eb9
Normalize the arrayList, meaning divide each column by its standard deviation if that standard deviation is nonzero, and leave the column unmodified if it's standard deviation is zero.
namespace Accord.Statistics static partial class Tools public static double[] Standardize(this double[] values, bool inPlace = false) { return Standardize(values, Measures.StandardDeviation(values), inPlace); }
1
51d9bd4c3e9f8af2d48d9a6e543b4284
6f8826baecb36c52f29e2540d976e60c
선택된 캐릭터를 전/중/후방에 따라 배치
public class selectCamera : MonoBehaviour void SelectCamera() { if (selectedCharacter == 0) { camera1.SetActive(true); camera1AudioLis.enabled = true; camera2AudioLis.enabled = false; camera2.SetActive(false); camera3AudioLis.enabled = fals...
0
8333fd5af24e30bae9dd156df52a8fee
7180c8bfb49aa64ae2e9d3e6a403a097
更新运营商非空字段
public class CsOperService implements ICsOperService public void updateCsOper$NotNull(CsOper csOper) { csOperDao.updateCsOper$NotNull(csOper); }
1
2a21417cd1532fb70b8e9ed391857a16
4679caee7319dfba9ad9b3a4a276fc6d
Returns 1 if x is a power of 2 and 0 otherwise
while (((x & 1) == 0) && x > 1) { x >>= 1; } return (x == 1); }
1
d784064956f45ed8cab8f649cfff7319
a08ed103372a12e3319a494c70d809a9
Получить список правил для провайдера
namespace FlashFileProcessor.Service.Interfaces List<Rule> GetRules();
1
9864f321618d718b2f23d36d059286e7
a19c984c74ad6200065c05411ccb82e5
profileId를 받아 스케쥴러를 해제 시킴 (DB X)
profiles = self.getSchedulerProfiles()["data"] for profile in profiles: data = {"operation": "remove", "key": profile["key"], "index": 0} res = self.s.post("http://%s/data/scheduler.profile.json" %(utils.ip), data, headers=utils.header_eap220) profiles = self.getScheduler...
0
7c529c9a72b2c61c58caa398cebfd594
62e189e441898e15ec733fc5106412cb
Append an item to the outline.
class Table(AbstractTable): def append(self, key: Key | str | None, _item: Any) -> Table: if not isinstance(_item, Item): _item = item(_item, _parent=self) self._value.append(key, _item) if isinstance(key, Key): key = next(iter(key)).key _item = self._value[ke...
1
7e2f346ae483951bb9cf7a7985ecf85c
a1897164ecf486622e288545fb6584b0
Task to handle updating tinygl.
async def update() -> None: while True: print("working") await asyncio.sleep(1)
0
b67b30805832e091977ec099550a490b
0ce23a3cdd852d52c09d3dc9f3852557
Retrieve supplied content image from within content image directory. @name: an image
class BaseContent(AbstractBaseContent): def get_image(self): images = self.images.all() try: return images[0] except IndexError: return None
0
ac888121d65f27f3d9138cb52b316418
b203664d8e311d5a5acfbb258c0a37d2
Converts binary data into a hexadecimal representation.
{ string st = ""; for (int i = 0; i < bData.Length; i++) { st += string.Format("{0:x2}", bData[i]).ToUpper() + " "; } return st; }
1
21cef32feef545428644740b843b41a4
b0ed51c8ea09e5c654ee4083a45fe29b
自动点击弹出确认或弹出提示
function autoReview(setting) { if (setting == 'checked') { if ($(".commstar-group").length > 0) { $('.commstar .star5').trigger("tap") $('.commstar .star5').trigger("click") } if ($(".f-goods").length > 0) { $('.fop-main .star5').trigger("tap") $('.fop-main .star5').trigger("click"...
0
e976da884a646405d01a5954703fc56e
6b286c4e435f0cf17cc6a0afbf1c427c
============================ METODO PARA COMPLEMENTO DO PERFIL ==================================
{ $id_p= $formacionacademica->personal; $formacionacademica->delete(); $id_i=complementoPersonal::where('id', '=', $id_p)->value('ingreso'); $id_c=complementoPersonal::where('id', '=', $id_p)->value('contacto'); $complementoPersonal=complementoPersonal::where('id', '=', $id_p...
1
5a0ccb2e8f6a32f893b343cd828a3836
4a70341c5862ba992f5f5c02640b5690
LDAPディレクトリへのバインドを解除する
class Ldap extends AbstractLdap public function unbind() { return $this->getBinding()->unbind(); }
1
bd95a049e8940c5236949e50814564b2
50e95fcab98703c1a10fcf3685355798
设置Z坐标(local)
public class TrackingItem extends com.earthview.world.core.AllocatedObject public void setZValue(double zVar) { double zVarParamValue = zVar; setZValue_ev_real64(this.nativeObject.pointer, zVarParamValue); }
1
464f17532554ce3e000e2c282583b2a8
b70a451eaab75a97367535a1ba3cf524
Initializes the Bandfilling correction
class Analytical_bands(object): def __init__(self, coeff_file): self.coeff_file = coeff_file
0
2bebdf594392a7a2414464d298a661bf
ee49dd0d627eeab859f0aea38d8e53bb
쪽지조회 biz 요청 및 html생성
if ($_POST['kkoBizCode']){ $this->load->model('kakaotalkmodel'); $scParams['kkoBizCode'] = $_POST['kkoBizCode']; $template_info = $this->kakaotalkmodel->get_template($scParams, false); if ($template_info[0]){ foreach($template_info[0]['comments_arr'] as $k => $v){ $template_info[0]['comments_arr'...
1
2aa90e7aac2bd1af9da6188367c40082
ff723fb619004129d2e6f8c01f2f4200
Test the HTTP response for the new review page
user = User.objects.create_user(username='username', email='myemail@test.com', password='password') self.client.login(username='username', password='password') item = Product(name="Product",...
0
cc0d98289c31529c56fc0a03b6e84c6e
241ad6e925a1461ec2e33c487897fcc0
使用BufferedImage获取图片尺寸 源图片路径
public class ImageUtils public static PicSize getPicSize(String path) { BitmapFactory.Options options = new BitmapFactory.Options(); options.inJustDecodeBounds = true; BitmapFactory.decodeFile(path, options); return new PicSize(options.outWidth, options.outHeight); }
0
4e1cff74ec1d3c69391d1307ca3727f1
5e82031bab1082270324a368ed39eb0e
检测:平仓量<=持仓量
void Strategy::Close_SedimentaryOut_SignalCheck() { char logbuf[1024]; DateUtil dateutil; std::string trading_date = this->GetTradingDay().c_str(); std::string tradingday_sqltime = dateutil.ConvertDatetoSqlTime(this->GetTradingDay().c_str()); MysqlDayLine mysqldayline; MysqlHold mysqlhold(this->GetUserID().c_s...
0
360b88ee87e259b852e4fa9b28709ea0
ec777143183aab412214a847c4b8fde9
removes last NChord in the voiceNumth voice
function MIDIClip:deleteTopNote_Near(_nearLength_) local targetNotes_A = self:_detectTargetNotes(); table.sort (targetNotes_A,function (a,b) return (a.startpos < b.startpos) end ); local offsetCount = 1; local nearLength_ = _nearLength_ or 1/4 ; local deleteNoteQue = {} ...
0
c32b56efd497e0e68dadb59a571da90b
3df57e75a855ca47ad31a5b0a4220f8e
Returns the maximum record for each of the specified segments.
namespace Microsoft.Research.Naiad.Frameworks.DifferentialDataflow Collection<TRecord, TTime> Max<TKey, TComparable>(Expression<Func<TRecord, TKey>> keySelector, Expression<Func<TRecord, TComparable>> comparableSelector) where TKey : IEquatable<TKey> where TComparable : IComparable<TComparable>;
1
03ba5368aaf6afee7c1ba7fa1c71e6ae
54c2dd9583d4dca2a380009f88f48768
计算涨停价格
{ if(type == SecurityType.Sotck) { return GetLimitPrice(preClose, true, 2); } else if(type == SecurityType.Fund) { return GetLimitPrice(preClose, true, 3); } else { thr...
1
729de7032f6239264859cb4259ebdcdd
c6dcc6e2d8e25c71af8b4a78acccdfea
Get array of MX records for host. Sort by weight information.
class DiscoverRequest implements SearchRequestInterface public function getMx() { return $this->mx; }
0
88bc3aae4d8003a9585331bf96006b44
6971045e574d13593b5c1868f3f02323
Convierte el valor entregado por las salidas digitales de arduino a volts
double Sensor_Iluminacion::calcular_Voltaje (int lectura_digital) { double valor_voltaje = (lectura_digital/((32768-1)/4.096)); return valor_voltaje; }
1
1d634fc2ddfc0240e1d4e741472325c7
2d6f57fb2903d341bf8d8c53a68ac4c4
ES - Edita el tamaño del pane1.
{ Dimension tabbedPaneSize = frame.getControlPanel().getTabbedPane() .getSize(); Dimension newSize = new Dimension(tabbedPaneSize.width, frame .getScrollPane().getHeight()); frame.getControlPanel().getTabbedPane().setPreferredSize(newSize); frame.getControlPan...
0
8eb321a7345e451b3e88735eb7466ff3
bba7e8521ee74f1f782ded567b2ef2f8
@brief Initialize and blink the LEDs momentarily. To be used at the start of the program.
Scheduler_Init(); int blink_count[] = {1,3}; void* count_ptr = &blink_count; Scheduler_AddSporadicTask(100, 50, blink_for_count,count_ptr); Scheduler_Start(); }
1
efd430ed63c4d0c2e89fd36419f69c33
a09d1eed1e33988e8b19f8fd922bc3ad
a bounding sphere centered at the origin.
static void ComputeAABBSphere(const real& radius, const real3& position, real3& minp, real3& maxp) { minp = position - R3(radius); maxp = position + R3(radius); }
0
ed51a99f8825ec325cf297b685df684a
d45c2beaa80f510e3fd0464c994e4bc0
Generate HeeksPython objects from dxf entities.
common = dict() if base.get('entity_mode') == 0: common['handle_owner_ref'] = self.decode_handle_reference(base.get('handle'), DWGHandleCode.SOFT_POINTER) common['handle_reactors'] = [] for idx in range(bas...
0
fc479f599902dbea2394504093130d2e
2eaca723def860988151a0e77ced93c8
Return number of elements in queue. Return 0 if q is NULL or empty
int len_rqueue(t_ret_q *q) { if(NULL == q ) { return -1; } return q->len; }
0
fefaf21883ae8e2e3e45c84c4921293d
fbffea67fca1592e6c7b944ba4ac93c8
长文本的语音合成,包含简单分句模块。
def synthesis(text, text1): APP_ID = key_APP_ID API_KEY = key_API_KEY SECRET_KEY = key_SECRET_KEY client = AipSpeech(APP_ID, API_KEY, SECRET_KEY) result = client.synthesis(text, 'zh', 1, { 'vol': 5, 'spd': 5, 'pit': 8, 'per': 0 }) if os.path.exists('temptype.mp3'): os.remove(...
0
e5ad3dbb85d24b1df0414b9f7009add9
b77b69ef541d695dc2b4919dffd01684
@brief Checks, if the specified parameter has been defined with an initial value.
{ if (isset($this->parameterValues[$parameterName])) { return true; } if ($this->typeDescriptor && $includeDefault) { return $this->typeDescriptor->hasParameterValue($parameterName); } return false; }
1
1764b1e6ceba89f7cf3d5dbc621fcb0b
3a3476d6494734b5ded580b4cca82d44
Registra a seleção feita na página no controle de sessão.
class ISessionStateController: def save_selection(self, name): pass
1
487f9a5455acbf02ff394c8f92acf0b2
53d4736469bcb8173033022eaf0d4f39
! @brief Gets the MIDI jack identifier. None Returns the identifier of the MIDI jack.
internal static partial class Interop internal static partial class Winmm [MethodImpl(MethodImplOptions.AggressiveInlining)] [DllImport(Libraries.Winmm, EntryPoint = "midiOutGetID", ExactSpelling = true)] private static extern MmResult MidiOutGetID(IntPtr hMidiOut, out int lpuDeviceID);
1
bbf55d6564c588d6ad8f53a6eb5eeca5
6778940001b0065ccab1215160494720
一个恒为真的测试用例,用来测试 SpringBoot 能否正常启动.
@RunWith(SpringRunner.class) @SpringBootTest public class BootApplicationTest @Test public void contextLoads() { }
1
c20f86445d0935975b4cdeb2fd7d2b05
77f6bdb8f62e2594fbcdf7e237eef0b3
用递归方法遍历文件夹
function recursive($dir){ $handle = opendir($dir); echo "<ul>"; while($line=readdir($handle)){ if($line=='.'||$line=='..')continue; echo "<li>".iconv('gbk','utf-8',$line)."</li>"; if(is_dir("$dir/$line")){ recursive("$dir/$line"); ...
1
8296eb8688a7d4db8343fa14186b5f9c
db3e3c26c8f999511d05e7874c3b6787
Get the next credential from the cache file.
class ECSCredentials def get_credentials begin retry_errors(NETWORK_ERRORS, max_retries: @retries) do open_connection do |conn| http_get(conn, @credential_path) end end rescue '{}' end end
0
8e678ecd8e1e4505ac1ec072ae2b13de
72d6fc290abbe8093faf59abf08ec83a
turns a dotted field path into a valid field name
if '.' in field['Field Name']: parent = '.'.join(field['Field Name'].split('.')[:-1]) child = field['Field Name'].split('.')[-1] if '.' in parent: field['Field Name'] = parent.replace('.', '_') + '.' + child field['Field Alias'] = field['Field Name'].r...
1
9d3f824fe2989662e48e05a5f3e7487a
b7cb430c4bff4d3695eac48f92a82f8e
匹配以指定名称开头的方法名, 配置了slaveMethodStartWith属性, 或使用默认
{ $realModelName = trimNamespace(get_called_class()); $Model = str_replace('Model','',$realModelName); array_unshift($args, $Model); return call_user_func_array(array(DBSlave(),$name),$args); }
0
aa209096c35b9893710abecfab98be68
96cfb2c03435b80f1b70c5dfdbce5fbd
Apply a security profile to a socket.
{ SlNetSock_SecAttribNode_t *tempSecAttrib = *secAttrib; int32_t retVal = SLNETERR_RET_CODE_OK; if ( 0 != (flags & SLNETSOCK_SEC_BIND_CONTEXT_ONLY) ) { while (NULL != tempSecAttrib) { if ( tempSecAttrib->attribName <= SLNETSOCK_SEC_ATTRIB_DISABLE_CE...
1
4866181c2d6ca0be676131cb5bb422f2
914f94a8e55867ef5fac2147063797b3
EUC-KRをISO-2022-KRに変換、もしくはその逆(ISO-2022-KRをEUC-KRに)を行う。
long fromJIS(long kcode) { if (is_internalUPTEX()) return UCStoUPTEX(JIStoUCS2(kcode)); if (is_internalSJIS()) return JIStoSJIS(kcode); return JIStoEUC(kcode); }
0
853e6df88baf16e510cd102b02485d55
1d414a9576f0fdb143cab371f8319854
Creates and returns a shader module.
const RESTRICT VulkanInterface::CreateShaderModule(const void* const shaderData, const uint64 shaderDataSize, const VkShaderStageFlagBits stage) NOEXCEPT { VulkanShaderModule *const RESTRICT new_shader_module{ new (MemorySystem::Instance->TypeAllocate<VulkanShaderModule>()) VulkanShaderModule() }; new_shader_module->...
1
b057193964f59b974a6b0137a524e225
7a116a02a91c034d6c208fc8c71b128b
Extracts all pending data from the videoEncoder. If endOfStream is not set, this returns when there is no more data to drain. If it is set, we send EOS to the videoEncoder, and then iterate until we see EOS on the inputSurface. Calling this with endOfStream set should be done once, right before stopping the muxer.
namespace android int C2SoftXaacDec::drainDecoder() { return 0; }
0
6ee02fd384a0fa9e87026ed0afed13f9
d6921558a7304dddfcbd7dcca5967f49
Increment positions of all others sortables.
if self.position_scope all.group_by(&self.position_scope).each do |scope, entries| entries.each_with_index {|e, i| e.update_attribute(:position, i + 1)} end else all.each_with_index {|e, i| e.update_attribute(:position, i + 1)} end end
1
f1649cf475480231c6a589eed5742377
b087bad1d847c110c122cb0bdfc23af4
The simplest possible Shape – one triangle. It has 3 vertices, each containing two values: a 3D position and a color.
vec3 colors[6]; vec3 points[8]; Vertex vertices[8]; float min = 0.25; num_tris_ = 12; tris_ = new Triangle[num_tris_]; colors[0] = vec3(1, 0, 0); colors[1] = vec3(0, 1, 0); colors[2] = vec3(0, 0, 1); colors[3] = vec3(1, 1, 0); colors[4] = vec3(0, 1, 1); colors[5] = v...
0
ce901836fc828a91ff033f3e26599b3e
4f310910b8c71178d1950f9bc711e17a
下面程序创建了4个线程安全的集合对象
Thread t1 = new Thread(new ThreadSafeDemo()); Thread t2 = new Thread(new ThreadSafeDemo()); Thread t3 = new Thread(new ThreadSafeDemo()); t1.start(); t2.start(); t3.start(); }
0
2887496b145172a1fbc19ffa9a5f9978
c81206d74456cddc7937089813d6de89
找出指定路徑底下所有的分享資料
{ try { return gbe.DT_Share.Where(a => a.ShareId == sid).ToList(); } catch (Exception) { throw; } }
0