query_id string | corpus_id string | query string | code string | label int64 |
|---|---|---|---|---|
75dca4d8f2c3c8efaf0b00f5cc7fb25c | 7de79f131b37bf767fdf053eedccf736 | If a timeout was waiting to hide the popup, cancel it since the cursor
is now in the popup and we do not want it to go away | dismiss(): void {
clearTimeout(this.durationTimeoutId);
super.dismiss();
} | 1 |
f7fdf13ff6a4d8e891b758c3b377024d | 5b91554c1804f897c8429d3d8ed3af27 | Returns total amount of comments posted on the site | $query = "SELECT COUNT(*) FROM blog_comment";
SQLConnection::executeQuery( $query);
$result = SQLConnection::getResults();
return $result[0][0];
} | 1 |
c7f3ae2330babfac400108fad580f1a9 | 744706a1475e32b0e6bb0ac9fbf16271 | Get a list of all colliders that fall within a specified area. | namespace RedBlueGames.Tools
public class RBPhysics2D
public static Collider2D[] OverlapAreaAll(
Vector2 cornerA,
Vector2 cornerB,
int layerMask = Physics2D.DefaultRaycastLayers,
float minDepth = -Mathf.Infinity,
float maxDepth = Mathf.Infinity)
... | 1 |
a972cb496b32b2e539fa385533da9cef | 5ecdc6145cdbcde37c4398b7754cbefe | Функция ответа на ставку исполнителя. Откроет чат с сообщениями диалога с исполнителем. | {
$sendTo = $response['sendTo'];
$content = $response['content'] ?? '';
return $this->windowOpen(Route::navigate('/chat', [
'user_id' => $sendTo,
'content' => $content
]));
} | 1 |
0a5909087ccaa96bbf0441010949bb2a | 44277fc61503de75283f2b1b2fba477b | 4.5 美发师自定义工作日程,创建与更新接口 | class Oa extends BasicWorkWeChat
public function calendar_update(array $data):array
{
$url = "https://qyapi.weixin.qq.com/cgi-bin/oa/calendar/update?access_token=ACCESS_TOKEN";
$this->registerApi($url, __FUNCTION__, func_get_args());
return $this->httpPostForJson($url, $data);
} | 1 |
07574fe085ffea712dc5a14b72da3542 | 1e669d89bb07c2b20ec350e00b6f5f47 | @brief Methode qui permet de recuperer la couleur d'une piece | class Piece():
def get_couleur_piece(self):
return self.__couleur | 1 |
2818ab7f9199c5d2d2d72141f40a9733 | 1122b51e98b334a6db9c9b8b5261c9b1 | Returns a random element from the pool. | namespace Microsoft.Extensions.ObjectPool
T Get(); | 0 |
b061f8a8250fcfc1ab572f013ea39e2c | a5ba427555b3f02b620bd3bb27b69b17 | (experimental) The ARN of the delivery stream.
:stability: experimental
:attribute: true | class TableReplica(dict):
def stream_arn(self) -> Optional[str]:
return pulumi.get(self, "stream_arn") | 1 |
cc8e69ebbfb8aa2ae86c79257d591d9a | 3d40ad11102a0c8e9ed5d2dc47b3fc42 | Metoda ustawia indeks warstwy renderingu obiektu (head shadow) | namespace ScriptRuntime
public partial class RenderComponent : Component
public void SetShaderID(int index, String sSharderId)
{
ICall_RenderComponent_SetShaderID(this, index, sSharderId);
} | 0 |
8e727bf2a3470767961fa0846a0443c8 | 90c53d02b915125b8533a7dfdd447c1d | Lifecycle is controlled by triggering logic. | void Demo::onLogic() {
} | 0 |
b7da7462d9e00963608e42b32edf1301 | 0ee50cf4e4fbf534a3c33e22d25f3785 | \brief Set the display color depth.
\warning Neither Cairo nor GTK3's OpenGL system actually respect
this value. | fxDDClearColor(GLcontext * ctx, const GLfloat color[4])
{
fxMesaContext fxMesa = FX_CONTEXT(ctx);
GLubyte col[4];
if (TDFX_DEBUG & VERBOSE_DRIVER) {
fprintf(stderr, "fxDDClearColor(%f, %f, %f, %f)\n",
color[0], color[1], color[2], color[3]);
}
CLAMPED_FLOAT_TO_UBYTE(col[0], color[0])... | 0 |
fcfc1eab2386823a8a8f67f556f58f5e | cf532f534c52ee248f3b3d85f7d45c03 | Принимает число и массив, после чего заполняет массив цифрами числа и возвращает количество цифр. | function Digits(the) {
let result = 0;
let see = the;
while (see !== 0) {
see = Math.floor(see / 10);
result += 1;
}
return result;
} | 0 |
ec980e7803daae943ecc227d990e2ea8 | fdcbcff41737784b59eead0a81ff3e60 | Get the gas ID of the currently active calibration. | {
INVENSENSE_FUNC_START;
struct mldl_cfg *mldl_cfg = inv_get_dl_config();
if (NULL != mldl_cfg->pressure) {
return mldl_cfg->pressure->id;
}
return ID_INVALID;
} | 0 |
eb09f428d4dbcca985a39dc274d26869 | e2dd0aa20621be267512b466f8fa5d38 | \
DecodePuzzleString *****************************************\
DecodePuzzleString sets up the initial grid (along with
InitGrid), and determine what variations are being used.
\ | numAttempts = 0
pzl := newPuzzle(slvr)
for i := 0; i < len(str); i++ {
entryChar := string(str[i])
entry, err := strconv.Atoi(entryChar)
if entryChar == constants.EmptyTileChar || err != nil {
continue
}
row := i / constants.SideLen
col := i % constants.SideLen
box, err := speedUtils.GetBox(row, col... | 1 |
5651b25af4c47334ec4ccdbc44db6ecd | 79a7e1d71333bfce3cc11de698307dfc | 通过动画No获得播放信息列表 | {
std::list<AnimationBase *>::iterator anim_list_iter;
for (anim_list_iter = m_animation_list.begin(); anim_list_iter != m_animation_list.end(); anim_list_iter++) {
if ((*anim_list_iter)->getActName() == act_name)
act_anim_list.push_back(*anim_list_iter);
}
} | 0 |
a933d8987f15e711c9e3e0c4cb4c9375 | 8bc9bea28fcfb4045537012f6b6dfc42 | TestMessage constructor. | class TestSimpleMail extends MainMail
public function __construct()
{
parent::__construct();
$this
->setTo('test.to@zicher.eu', 'Test To')
->setSubject('Test subject')
->setBody('Test body');
} | 0 |
58545a2a709ce1b28f709c5d0174f635 | 7b791a837bdf6f1bf62f45560c588936 | #On va retourner une liste avec 3 éléments : les df de train, de test et aussi la condition de split. | dataSubject <- rbind(dataSubjectTrain, dataSubjectTest)
dataLabel <- rbind(dataLabelTrain, dataLabelTest)
dataSet <- rbind(dataSetTrain, dataSetTest)
names(dataSubject) <- "subject"
names(dataLabel) <- "activity label"
Featuresnames <- read.table(file.path(path, "features.txt"))
names(dataSe... | 0 |
7fde53f31c7a70688474dfef0cf3a02f | 71435f582b7545b724effdf4cc61ca9d | Get a node that takes two initializer arguments. | printer = node.PrinterOfThings()
emitter = node.ConstantEmitter()
printer.name = 'printer'
emitter.name = 'emitter'
emitter > printer
return emitter | 0 |
a6e17013f5fc0ed425aa160771dd6f8c | 52cc408f183513215dc7780f64cf1c15 | Recursively cleans arrays, objects, and strings. Removes ASCII control
codes and converts to the requested charset while silently discarding
incompatible characters.
UTF8::clean($_GET); // Clean GET data
[!!] This method requires [Iconv](http://php.net/iconv) | if (is_null($value) or $value === '') {
return $value;
} else if (is_string($value)) {
if ((string)(int)$value === $value) {
return $value;
}
$olderror = error_reporting();
if ($olderror & E_NOTICE) {
error_reporting($olderror ^ E_NOTICE);
... | 1 |
7788730f5e15d3cd0efe3701ce5dbd43 | 65903ae6f13c2f729036b4bc697735a8 | 计算特价商品公共支付方式(取交集) | namespace TWNewegg.DelvTypePaymentTermRepoAdapters
public class DelvTypePaymentTermRepoAdapter : IDelvTypePaymentTermRepoAdapter
public List<string> GetlistIntersectPaymentTermID_PaymentTerm(List<int> listDelvType)
{
List<string> listPaymentTermID = new List<string>();
if (listDelvTy... | 1 |
726fa6631de44cb7d89b8e231d88a21e | f95b4ab2eaaae935e043d63497bf7359 | <pre>
<b>Description : </b>
CreateUpdateEnabled status.
</pre> | public class ErlangBreakpointPropertyPage extends PropertyPage
protected void createEnabledButton(final Composite parent)
throws CoreException {
fEnabledButton = createCheckButton(parent, "&Enabled");
fEnabledButton.setSelection(getBreakpoint().isEnabled());
} | 1 |
7d72f8db6eeccc3e5556ee08188b8d2e | a18fcca9901c5e15975733572b468f56 | 三维叉积 | {
if(v1 is null || v2 is null || v3 is null)
throw new ArgumentNullException();
return (v1.X*v2.Y*v3.Z) + (v1.Y*v2.Z*v3.X ) + (v1.Z*v2.X*v3.Y) - (v1.Z*v2.Y*v3.X) - (v1.Y*v2.X*v3.Z) - (v1.X*v2.Z*v3.Y);
} | 0 |
e00ec8aaef246c148d2aed1cbde02b2f | 37a0f743ef7a10ca6ccbd5786cd292fa | Pulls a blob from a specified container with a specified content name | export class DefaultApi extends BaseAPI implements DefaultApiInterface
public blobstoreGet(blobstoreName: string, options?: any) {
return DefaultApiFp(this.configuration).blobstoreGet(blobstoreName, options).then((request) => request(this.axios, this.basePath));
} | 0 |
f47b8560d518b301633a049fb024f2d7 | 66dec6e080ce6fb672a1696e63d7fa67 | Called when spell frames are shown. -- | if ( self.AuraMouseover ) then
self.AuraMouseover:Show();
end
UnitFrame_OnEnter( self );
end | 0 |
432837c8d859caa9833040612969b3d4 | efcc5bc56e9396cd7a554965e270f038 | 这个成员函数用于将用户输入的数据存入动态数组 | {
a_size = 0;
double x;
while (a_size<a_capacity&&(cin>>x))
{
a[a_size]=x;
a_size++;
}
} | 1 |
b85c4ae1b0ef8f0ed3dbcf9bee914b96 | 0733b2c84fe0225d880e84ef6c241370 | 领卡链接 | {
$num = $this->getStuNum();
$password = $this->getStuPass();
$islink = $this->isLink();
if (!$islink || $num == false || $password == false) {
throw new Exception("请绑定厦大学工号。", 1);
}
$handle = self::getLoginHandle($num, $password);
if(!$handle) {
throw new Exception("抱歉教务系统出现了问题,请稍后再试。", 1);
}
... | 0 |
037be22fcec04f63947c54bf5a1a9b81 | ac1ddc57f1a0c76c2f390aa8a1dca9d9 | Updates the membership degree based on the new prototypes. | members=[self.memberOf.count(i) for i in range(len(self.centroids))]
self.centroids=[
[sum([self.data[k][i] for i in range(self.dataSize)
if self.memberOf[i]==centroid])/members[centroid]
for k in range(1,self.cols)]
for centroid in range(len(self.c... | 0 |
ea97b1345a465f9e9328eaaaf28ba9d9 | 4d32961f58eb5ba1212271895a039994 | 水下目标检测比赛里,将mmdetection的json输出转成比赛要求的csv格式数据 | result = []
result_origin =[]
if os.path.exists(jsonPath):
with open(jsonPath, 'r') as f:
datas = json.load(f)
for data in datas:
if len(data['joints'])<2:
continue
if data['width']<=1 or isnan(data['mid'... | 0 |
1ec9106118d9a5c68a4f02dfe64116dc | 4ac5770e1c9c7c5af0229ab1124320d2 | 价格下拉框选中事件 | function selectPrice(btn){
$(btn).parent().parent().find(".active").removeClass("active");
$(btn).addClass("active");
$("#select-tableId").data("prodPrice",$(btn).text());
doSearchProd();
} | 1 |
baff88a93ae29d8dd4f6cfae55ddd3e9 | 538326608deeba27204e982ca0a83b87 | 自动下采购单 | if(!NetUtils.isNetworkAvailable(AppContext.context)) {
return null;
}
JSONArray jsonArrayTab0=new JSONArray();
JSONArray jsonArrayTab1=new JSONArray();
JSONObject strTab0 = new JSONObject();
for (Map.Entry<String, String> entry : mapT0.entrySet()) {
... | 1 |
00fffb766c4e1ea3ce4e0f4f5a28c804 | 408e75bd431b31f720070d8d8e746e97 | Handle calling [[Call]] of built-in Date object
See also:
ECMA-262 v5, 15.9.2.1 | ecma_builtin_date_dispatch_call (const ecma_value_t *arguments_list_p __attr_unused___,
ecma_length_t arguments_list_len __attr_unused___)
{
ecma_completion_value_t ret_value = ecma_make_empty_completion_value ();
ECMA_TRY_CATCH (now_val,
ecma_builtin_date_now (e... | 1 |
cb2a642c367777a874fe9ba266648d42 | cf70ec2c9a8c649b93c4fbe969346b10 | Get all the rfbEvAtts. | List<Attribute> attrList = new ArrayList<Attribute>();
for (Recorder rec : this.recorderMap.values()) {
attrList.add(rec.attribute);
}
return attrList;
} | 0 |
77c5b12e9f3e94446a6f31d561e503bd | 96073e67d58c0d49e25f375634d11bb0 | 获取海选赛每日战斗总次数 | function self.getBattleSt(matchSt)
local oceanExpCfg = getConfig("oceanExpedition")
return getWeeTs(matchSt + (oceanExpCfg.matchTime1-1) * 86400)
end | 0 |
7eae0bcfcd3ebdac0a3a510a10d00a0c | 0ed055d30abb37c88f807a7c69cc6280 | Register changes made to the terrain | public class TerrainMakerManager : MonoBehaviour
void Update () {
} | 0 |
346b2fd9a0e4572ad9fd87c4a3bdbb70 | a80bcd2e26059094c5d651ec24ee46fd | 内部方法,将修改的列元素维护至统一的数组中 | $colary = array();
foreach ($var::$columns as $col){
$val = $var->__get($col);
$var->logger->debug("genUpdateColAry ". $col);
if($val != null && isset($val) && !in_array($col,$pks)){
$colary[$col] = $val;
}
}
return $colary;
} | 1 |
41b2ded2996ccbfb5401e12081f09148 | 43bbd7a4c6dce94b9de4d18a37f15f2b | Request a programItem by its ID. | class YleAreena:
def searchProgramById(self, id: str) -> Program:
cache_time = datetime.timedelta(hours=4)
q = {
"app_id": self.appid,
"app_key": self.appkey,
}
url = f"https://{self.apidomain}/v1/programs/items/{id}.json" + self._qstr(q)
resp = self._dl_u... | 1 |
6a254a0001e9ae3736bab6c4c55f96b5 | 9682b63b3bce6147a44569a48950de16 | # Plot Persistence Landscape | dowjones_lr=getLogReturns("DowJones.csv")
nasdaq_lr=getLogReturns("Nasdaq.csv")
russel_lr=getLogReturns("Russell2000.csv")
sp500_lr=getLogReturns("SP500.csv")
dates = getDates("DowJones.csv")[w-1:]
pointClouds=computePointClouds(w,dowjones_lr,nasdaq_lr,russel_lr,sp500_lr)
dgms = computePersi... | 1 |
2b82f1d2d2645622b92a67d021e009ad | e4708c70973102a650a6d8d0f7374769 | Returns the number of related Page objects. | abstract class BaseUser extends BaseObject implements Persistent
public function countPages(Criteria $criteria = null, $distinct = false, PropelPDO $con = null)
{
$partial = $this->collPagesPartial && !$this->isNew();
if (null === $this->collPages || null !== $criteria || $partial) {
if ... | 1 |
da8128d4fd8745bf58e81b62992ea917 | b2141efe19ae7166cc3691f2cd5f3007 | Only need to install it if the hash of the dir has changed since we last added it to the path | class rImageDbHelper
public function hashChanged() {
if ($this->force) {
return true;
}
$newHash = $this->getGalleryHash();
$search = $this->findGalleryHash();
if ($search) {
if ($search->hash == $newHash) {
return false;
}
}
return true;
} | 1 |
9973a3aed0e6175fe99e3e36a0f2246c | b93aa79deb508364d212ab91587375e5 | APIにより全部の路線を取得し、既存データとの差分があれば更新するrefreshメソッド | GlobalScope.launch {
val tabRoute = activity!!.getMapRouteId()
val stopName = handler.getStopNames(tabRoute)
val estimateTime = handler.getEstimateTime(tabRoute)
if (arrivals.isNotEmpty()) {
arrivals.clear()
... | 0 |
0781931dc4b92de8163a6e18afd9578c | e4654634258905db07c07d06e63d13f2 | Returns the value of the '<em><b>Date Time</b></em>' containment reference.
<!-- begin-user-doc -->
<!-- end-user-doc -->
<!-- begin-model-doc -->
The date/time at which the event occurred.
<!-- end-model-doc -->
extendedMetaData="kind='element' name='dateTime' namespace='##targetNamespace'" | boolean isSetDateTime(); | 0 |
958759a958c9c29c4fe040df70266f0b | 8d25b7369e1b933a074e3a7f15e10475 | Esta funcion lee los datos desde el servidor | def us_read():
try:
g_arduino.write(b'S')
time.sleep(.5)
l = g_arduino.readline().strip()
dato = l.decode('ascii', errors='replace')
return dato
except ValueError:
res = "ERR"
return res | 0 |
20cb5d0c6e40102b8c688492c73a1e0d | 3ca4dfa7d3268a91db4cf2197bbc6258 | 将DNA转化为二进制 | def pop_b2d(pop):
temppop = []
for i in range(len(pop)):
t = binarytodecimal(pop[i])
temppop.append(t)
return temppop | 0 |
508304e55df86538d699f1ecf2ec6aad | 4aa8bb68a09257e338b833b3d77ad9ec | method to get a list of every NumberOfContourPoint in each contours from ROIContour Sequence | public class RingContour
public ArrayList<MatOfPoint> findContoursOutput() {
return findContoursOutput;
} | 0 |
2b74b23641a77c883f326f3d452bbc89 | 83279adf06ed4430a2d1824b3d73a6cc | Expand and process all of the products specified on the command line. | def update_products(index: Index, allow_unsafe: bool, allow_exclusive_lock: bool, dry_run: bool, files: List):
if not files:
print_help_msg(update_products)
sys.exit(1)
exit_on_empty_file(list(read_documents(*files)))
failures = 0
for descriptor_path, parsed_doc in read_documents(*files)... | 1 |
9dd1edaeffffd3095defc90dbadd1060 | beca504ea8908734d335cda1560d034e | @brief Handle the Power Button Fixed Event
We simply write to a well known port. A user-mode driver should pick
this event and take action. | {
unsigned int ret;
ARG_UNUSED(dev);
ret = irq_lock();
Power_init();
irq_unlock(ret);
return 0;
} | 0 |
c8de2e80c9fc6e61b632c91e27690d5c | 6d300fd7b875c81455b3c9d4cf836192 | gets if the latest modified date is being filtered on | return taxid_is_modified ||
name_is_modified ||
code_is_modified ||
startfrom_is_modified ||
exemptafter_is_modified ||
postingtype_is_modified ||
amount_is_modified ||
applybefore_is_modified ||
applyonrate_is_modified ||
regbyid_is_modified ||
regdate_is_modified ||
active_is_... | 0 |
8b4fdc1e968b0961fd8fb7694012929e | 5cd9f887cf6ecd9fc13aaa9dddfb2c14 | Авторизация и получение JWT токена. | [Route("Login")]
public async Task<IActionResult> Login(LoginDto loginData)
{
var user = await _authManager.FindByUserName(loginData.UserName);
if (!await _authManager.AuthorizeUser(user, loginData.Password)) return Unauthorized();
var token = await _authManag... | 1 |
98f68550350be55fbbdafdcf0829546b | 89215660359d84321357ac7bafbbecdd | sets the scheduler that made this queue | assert(s_running);
scoped_lock lk{s_mut};
auto q = s_queues.find(hq);
setThreads_LK(q, threads);
} | 0 |
fc1de0c57b97e54ffe2bbfa81b35f83a | 6b477b2e0f41a237b45a49627c17378b | set value of idUserTicket | class User extends \Phalcon\Mvc\Model
public function setIduser($idUser)
{
$this->idUser = $idUser;
return $this;
} | 0 |
8d147bc2826d351c00ad1e424a6fb059 | be1b5c5fd757cc3c6d3663c2c2612d45 | Abstraction of a xpath-selectable or json-parsable field on the webpages. A cleaner can also be bind to a Field. | function Field (parameters) {
this.source = "";
this.value = undefined;
this.default_value = "";
this.backupable = false;
this.required = false;
this.title = "";
this.isValid = false;
this.raw = false;
this.type = undefined;
if (parameters !== undefi... | 1 |
ba1e111a46e4c569a2c6ecd7def0e512 | 536a768b0cbc670625c7dd0a38a15931 | Display courses in descending order | class CourseController extends Controller
public function index()
{
$courses = Course::orderByRaw("CASE WHEN status_id ='2' THEN 1 ELSE 0 END DESC")
->orderBy( 'name', 'DESC' )
->paginate(12);
return new CourseCollection($courses);
} | 1 |
567d38bc683d2867859b0c6f6433ccc8 | 642a70af4123e75eabdd3f69e54302eb | Toggles the ability to the opposite of its current state. | public class MovingEntity : MovingEntityBase
public void Toggle() { this.enabled = !this.enabled; } | 1 |
90de57698bbb18ed238fc9fe78fd243c | fbd7554057a07407dcc9f366590c37d4 | Compute a distance transform for a binary matrix m | class GripPipeline:
def __distance_transform(input, type, mask_size):
h, w = input.shape[:2]
dst = numpy.zeros((h, w), numpy.float32)
cv2.distanceTransform(input, type, mask_size, dst = dst)
return numpy.uint8(dst) | 1 |
637e2d6a412e095959ae9d5f681cbfa9 | 5c586bb800e5fadf6778cb61bd130ad3 | Método que actualiza los valores de un Servidor de Archivos existente. | public void actualizarJuego(String juego)throws RemoteException; | 0 |
10f704dabba10c2adb54bc4fec9035d5 | c46e8c4721753886382f5e45937493c1 | 社員CDから社員マスタIDを取得 | @Component
@Transactional
public class MobileExProgressServiceImpl
public String selectMangerIdByWsCd(String wsCd)
{
return dexProgressDaoImpl.selectMangerIdByWsCd(wsCd);
} | 0 |
b6691cdf7f2a2541f6c70231d6af8cbe | ca33f34b35ae200fa9ff73ecdb26cddf | Return a shallow copy of this graph. | class UpdateGraph:
def clone(self):
return copy.deepcopy(self) | 0 |
6afc50b1afe90c7df31af654629bdcf7 | ba571d824444c1632dec0e17320d2054 | Test use of incompatible options | {
options_description desc;
desc.add_options()("cfgfile,c", value<string>()->multitoken(), "the config file")
("output,c", value<string>(), "the output file")
("output,o", value<string>(), "the output file");
const char* cmdline[] = {
"program", "--cfgfile", "file", "--output", "anot... | 0 |
9578d4b2aa55c8c169a687a82b48b1c1 | 68c5609278151b35bc1e700a41cc5740 | Get id of basic entity (Invoice|Creditmemo). | class Operation implements ISpecificOperation, IComplexOperation
public function getEntityId(): string {
return File::class;
} | 0 |
59b590e9f7e2b0a9ad0bc979729021e4 | 1ed9377704d267bf55a4a429975bbb07 | Send the default config to the client | var config = {
url: "http://"+serverip+":8040/request",
data: JSON.stringify({"Command": "REQ", "Data": {"CmdType":"GETCONFIG"}}),
type: "POST",
contentType: "application/json",
dataType: "json"
};
var done_fct = function(json) {
set_client_config(json);
... | 0 |
40c4396ae09b97b1cdc7c6302a3eebc6 | 141bef1df0c3f2ec84cc38c3b73b6901 | !displays students and trainers in the admin dashboard | class TrainerController extends Controller
public function index(Request $request)
{
$request->user()->authorizeRole(['admin','user']);
$trainers=Trainer::all();
return view('trainer.index',compact('trainers'));
} | 0 |
6c72ebbb4742fe093dae5f907579a902 | 2a4295e2dc2a4f2f55f2ce8da0c780a9 | Returns the result table mapping for Patient ID Query Results search. | public class PatientSearchResults
public ArrayList<PatientData> getPatients() {
return patients;
} | 0 |
8f571216b095aa9a1e62b0f88aff13ce | d21d92dd6ac23583ab4072fef1a35ecd | 从数据库读取全国县的信息 | DaoMaster daoMaster = new DaoMaster(getReadableDatabase());
DaoSession daoSession = daoMaster.newSession();
ProvinceDao provinceDao = daoSession.getProvinceDao();
QueryBuilder<Province> builder = provinceDao.queryBuilder();
return builder.list();
} | 0 |
a97d7265b0e627e8e3e7ba90f068e5ae | a23d7293ac13227218993ed80c1c7bbb | Set the down votes count | public function setDeleteVoteCount($deleteVoteCount); | 0 |
ebec2754a8aa5325be998bd3a640e877 | 465e9086a30412e280e4ba658f14399c | Run buildout in passed path. | class Poetry:
def build(self, *args: str) -> None:
self.session.run("poetry", "build", *args, external=True) | 0 |
9891799e8eb59f484ccb5d2ea3ca747f | 67cf79e1874b15de8a3dfdfb3b850ae6 | 根据MAP中参数获取采购退货出库单<br/>
orderid : 出库单编号<br/>
billno : 上游单据编号 <br/> | public PurchaseOutBillVo findByCode(String bill_code); | 0 |
d6b4718db279dafa662c2fa3c1c1ee77 | 3c3510dba500b487502a2283ef95acdf | @brief sh_sync_sens_frame: [set] Sensor synchronization time frame
with the step of 500 ms and full range
of 5 s. Unsigned 8-bit. | int HDMI_HDMITX_FBSSC_FIFO_reg_ssc_sync_fbSet(unsigned int ureg_ssc_sync_fb)
{
HI_U32 *pu32RegAddr = NULL;
U_HDMITX_FBSSC_FIFO o_hdmitx_fbssc_fifo;
pu32RegAddr = (HI_U32*)&(gophdmi2tx_dphy_regAllReg->HDMITX_FBSSC_FIFO.u32);
o_hdmitx_fbssc_fifo.u32 = HDMITXRegRead(pu32RegAddr);
o_hdmitx_fbssc_fifo.bi... | 0 |
d78fded33a66336844a2b5232ebeb43a | ae7764e3ec042658df340cbe490eaee3 | Check the cost of the given wifi point matches the cost selected in the filter box. | List<WebElement> matchingRows = filterRows(betsTable, matchers);
WebElement targetRow = matchingRows.get(0);
WebElement bet2Icon = targetRow.findElement(By.id("553-coeff_CW_P2"));
bet2Icon.click();
} | 0 |
6e3f5c8580d65798b76574161e38ffb9 | fa528d05b886a98277dd53304fb036cf | String Receiving Stream Manager: initialize member | void InitMember(void)
{
memset(bufRecv, 0, MAX_NUM_BUF);
memset(bufSend, 0, MAX_NUM_BUF);
sHost = INVALID_SOCKET;
bConning = FALSE;
} | 1 |
a2f47d05653c182377ad166d12cf0488 | 30bd414538f16e3654bb79fbc8cfab06 | # 「年月」を日付に。 | .ymd_to_date <- function(year, month, day) {
if (inherits(year, c("data.frame", "matrix"))) {
x <- year
colnames(x) <- tolower(colnames(x))
.require_columns(x, c("year", "month", "day"))
year <- x[, "year"]
month <- x[, "month"]
day <- x[, "day"]
} else if (inherits(year, "numeric")) {
i... | 1 |
8c81af53d050f42c92d6bf995fab9690 | b6bdf38c142abed783fdeadeac2c1214 | Carga la lista de Personal al instanciarse | $http.get(url_server+"user/usuario/3/"+empresa).success(function(response) {
if(response.type) {
$scope.personas = response.data;
}
});
} | 1 |
269355fe60eb8430c42b64ac79d9c2bb | 9c8c431c92f4893ae07ffbbf205f45fb | this controls what is downloaded in the json for this object under card_body..
this function returns the html snippet that should be loaded for the summary of this object in a bootstrap card
read about the structure here: https://getbootstrap.com/docs/4.3/components/card/
this function should return an html snippet to ... | return `
<div class="card mb-4 species-card shadow-sm" species="`+species_name+`">
<div class="card-header">
<h4 class="my-0 fw-normal">`+species_name+`</h4>
</div>
<form class="body card-body">
<div class="form-group properties">
... | 1 |
7c16f920e16c6ad0191252d362525742 | 6987de3aece96e61ce0b67b824e328e1 | From https://gist.github.com/swayson/86c296aa354a555536e6765bbe726ff7 | import matplotlib.pyplot as plt
cmap = plt.cm.get_cmap(cmap)
colors = cmap(np.arange(cmap.N))
RGB_weight = [0.299, 0.587, 0.114]
luminance = np.sqrt(np.dot(colors[:, :3] ** 2, RGB_weight))
colors[:, :3] = luminance[:, np.newaxis]
return cmap.from_list(cmap.name + "_grayscale", colors, cmap.N... | 1 |
9ab3d0161f65f3f1f0ea4f1222e15270 | 01d04dc65212c0a14231739f24650e14 | Set IPI Tax Seal Code.
Identifies the IPI Tax Seal Code | class gslbservice(base_resource) :
def cip(self, cip) :
try :
self._cip = cip
except Exception as e:
raise e | 0 |
1af95bbf41babb3302f74130a8e9ddb2 | d5820a6953fad28981cb2f735c6df001 | Convert world coordinates to view coordinate | float centeredx = (x - Gdx.graphics.getWidth()/2)/Gdx.graphics.getWidth();
float centeredy = -(y - Gdx.graphics.getHeight()/2)/Gdx.graphics.getHeight();
float worldx = cam.position.x + centeredx*getViewport().x;
float worldy = cam.position.y + centeredy*getViewport().y;
return ne... | 0 |
39a1a98ae3a3381f0aac01501f831475 | 731dfaacc40d3d23773f97591fec952e | Click event handler for the content, deactivates menu | namespace CharmControlLibrary
public partial class CharmMenu : Form
private void CharmMenu_Deactivate(object sender, EventArgs e)
{
Visible = false;
} | 0 |
cb5f0292974157894541747cca5d3054 | 00f9a16df71a7832096e6dbc80818e05 | This function returns the number of samples that should be copied in order
to fill the input port's local buffer. | status_t ASRC_TransferGetConvertedSamplesEDMA(ASRC_Type *base, asrc_edma_handle_t *handle, size_t *count)
{
assert(handle);
status_t status = kStatus_Success;
if (handle->state != kStatus_ASRCBusy)
{
status = kStatus_ASRCIdle;
}
else
{
*count = (handle->in.transferSize[handle... | 1 |
45eab021c8115c75f3212b3b5746e331 | 2f5e4108af2a6a326d8c9e2b50d6174c | Update the treeview on each change in the document. | ListView.row_update(self, handle_list)
for handle in handle_list:
if self._parent_changed(handle):
self.build_tree()
break | 1 |
9c7652769a5d5255545cf068db27a0b9 | f65aff62f311704039c0c0c845eec309 | Bullet wird bei Kollision zerstört | public class ShotController : MonoBehaviour
private void OnCollisionEnter2D(Collision2D collision) {
Destroy(gameObject);
} | 1 |
616c8b5ac5e3c65728ddbf6e2324f499 | d4a1bed6dcf6e0114536f26d8c3b1c81 | 寫入Cookie,
Cookie會設到Client Browser,下回合才會好 | {
bool BoolReturnValue = false;
if (Nvc != null && !string.IsNullOrEmpty(CookieName))
{
HttpCookie httpCookie = new HttpCookie(CookieName);
for (int i = 0; i < Nvc.Count; i++)
{
httpCookie.Values.Add(Nvc.Get... | 1 |
f100fb8c08f06326995ba8a82facf59e | 70a8649f3e626dbf87c9a4b4cd7cb6f8 | Tries to set the next order. | $res = false;
$orderArray = tx_ttproducts_control_basket::getStoredOrder();
$orderUid = 0;
if (isset($orderArray['uid'])) {
$orderUid = intval($orderArray['uid']);
}
if (
$orderUid &&
!$this->conf['alwaysAdvanceOrderNumber']
) {
$res =
$GLOBALS['TYPO3_DB']->exec_SELECTquery(
'uid',
... | 1 |
7db8cabc028ea48353cc648443136a62 | 0f45567d4a1103c78fbb9f522a784da2 | The API key for operations. Alternatively, can be configured using the `CLOUDFLARE_API_KEY` environment variable. API
keys are [now considered legacy by
Cloudflare](https://developers.cloudflare.com/fundamentals/api/get-started/keys/#limitations), API tokens should be used
instead. Must provide only one of `api_key`, `... | class BaiduCredentialPropertiesArgs:
def baidu_api_key(self) -> pulumi.Input[str]:
return pulumi.get(self, "baidu_api_key") | 0 |
4dd94d27ba01a85d41af1d068e89d88f | 69da5980319d18bd3beb8bc37d7bac6a | Entry execution point | func application(ctx context.Context, payload models.Event) (*models.Response, error) {
res, err := cmd.Entrypoint(payload)
if err != nil {
return nil, handleError(err)
}
return &models.Response{Value: res}, nil
} | 1 |
cbd3da8dcf6a135b250beb98896e94db | f509c4db764f3709a95a0acc4c7e4927 | 동네예보정보에서 하늘상태, 강수상태, 온도, 최저온도, 최고온도 뽑아내는 함수 | List<Map<String, String>> result = new ArrayList<Map<String, String>>();
try {
SAXBuilder parser = new SAXBuilder();
parser.setIgnoringElementContentWhitespace(true);
String url = String.format(rssFeed, x, y, etc);
Document doc = parser.build(url);... | 1 |
3dddd436a4684ad89d148d4ce6f96e34 | 69de13b7bd87cda3c89eec0e6aa93b9a | IO读写线程池,最多二个同时执行 | public class ThreadUtils
public Integer getThreadPoolSizeIOIntensive() {
return Runtime.getRuntime().availableProcessors() * 2 + 1;
} | 0 |
dbff27e103278ad2de292218866e8111 | 8c00b87ed851cdc64430deb3332749cf | 验证忘记密邮箱+码验证码登录数据合法性 | @Service
public class UnAuthService
@Transactional
public void validEmailAndCode(String email, String code) {
VerificationCode vc = verificationCodeRepository
.findByEmailAndCodeAndUsed(email, code, false);
if (null == vc) {
throw new CustomException(UserCodeEnums.VERIFIC... | 1 |
0e7e020fea137080cc1e4a91a4eac361 | 6bc88e75476c750687b75271c120b5f3 | 选择日期后不能触发Validform,故让其失去焦点 | try {
var datepick = sender.get_textBox();
if (datepick != null) {
datepick.focus();
}
}
catch (ex) {
console.log(ex);
}
} | 0 |
97bf1f3a459d8c9b50102e72ccbf4b7b | 13b403d84f336326eb251c0d1ad23230 | 标准化文件路径
如:
输入 D:\a\b\c/d/d/pp.txt
返回 D:/a/b/c/d/d/pp.txt [补齐]
输入 D:\a\b\c/d/d
返回 D:/a/b/c/d/d/ [标准+补齐] | if(!StringUtils.isEmpty(path)){
return path.replace(DEFAULT_AGAINST_FILE_DELIMITER + DEFAULT_AGAINST_FILE_DELIMITER, DEFAULT_AGAINST_FILE_DELIMITER).replace(DEFAULT_AGAINST_FILE_DELIMITER, DEFAULT_STANDARD_FILE_DELIMITER).replace(DEFAULT_STANDARD_FILE_DELIMITER + DEFAULT_STANDARD_FILE_DELIMITER, DEFAULT_STANDARD_F... | 1 |
7b350072ef330dfe43e5ac25267a8b9d | e06fe055038aab958a265c1f845dbda0 | Get a list of related daily sales. | class EC
public function getSales(array $data)
{
$response = $this->client('post', 'sales/getSales', $data);
return $response;
} | 1 |
04298d15548b9a773d0a7ab80d0684de | c677ae050bbd2d4ae746d395ac335616 | Load MRU from isolated storage. | namespace ESRI.ArcGIS.Mapping.Controls.ArcGISOnline
public class MRUMaps
static void Save()
{
if (!IsolatedStorageFile.IsEnabled)
return;
IsolatedStorageSettings settings = IsolatedStorageSettings.ApplicationSettings;
for (int i = 0; i < _maxAmount; ++i)
{
if (settings.Cont... | 0 |
60bf6d597d0676b5263ec5bdc4d1e605 | aa7e5eba13de79939be6cf50581cb303 | Fungsi Cek User jika belum Login | function cek_login(){
GLOBAL $url;
if (!isset($_SESSION['login']) || $_SESSION['level'] == 'guru' || $_SESSION['level'] == 'operator') {
header('location: '.$url.'/index.php');
}
} | 1 |
28cb3668e4d52d513fb99ec0966bbc08 | b18afb88bd832e11cd5147bce047b276 | 查询分类下的商品__分页__已下架 | class Goods extends \yii\db\ActiveRecord
public function getCateGoodsPage($cate_id = '')
{
$data = $this->search(['cate_id' => $cate_id, 'goods_name' => '', 'keyword' => '']);
unset($data['list']['category']);
return $data;
} | 0 |
fc70aea7900880b381bdb16fcebe4925 | f493edca5fec462e1bf8219236e18a15 | Rolls tx back in async mode. | namespace ReRabbit.Core
internal sealed class PublishConfirmableChannel : IAsyncChannel
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[ExcludeFromCodeCoverage]
public void TxRollback()
{
_channel.TxRollback();
} | 1 |
165cb6e222c0b696718eb46a48cd43fe | adf26286ebfcd193b0357e8fed7b6bc2 | Moves hexagons into place to display as grid | public class HexGrid : MonoBehaviour
public void SpawnGrid()
{
ClearGrid();
for (int x = 0, i = 0; x < _gridWidth; x++)
{
for (int z = 0; z < _gridHeight; z++)
{
GameObject newHexCell = Instantiate(_hexagon, Vector3.zero, Quaternion.identity) as GameO... | 1 |
84adb5ff537306c7210b015da206a657 | 4e5afc4dde647358954a099a0d0869a5 | Returns the gauge type angle range. | self._limit = limit
self._angle_max = self._start_angle + self._offset + self._limit
self._angle_min = self._start_angle + self._offset - self._limit
return self._angle_max, self._angle_min | 1 |
5f416094c91ace987e1cd3dcda7431bf | 76dd688b4467431f84c292cc2ebcfac7 | Visit a parse tree produced by {@link AutotestParser#substitution_tags}. | class SubstitutionApi
public function getSubstitutionTags($substitution_id)
{
$this->getSubstitutionTagsWithHttpInfo($substitution_id);
} | 0 |
f9c44c271c8f8e74c8b0b79b3d3340e2 | 245beacaf29bc57a36450249ad9dafeb | 协同备课列表 | {
if(!prepareTeamMateService.isPrepareTeamMasterByUser(user.getUserId())){
return "input";
}
prepareTeamList = prepareTeamService.getListPrepareTeam(user.getUserId());
if(teamId == 0){
teamId = prepareTeamList.get(0).getTeamId();
}
prepareTeam = prepareTeamService.getPrepareTeam(teamId);
SimpleDate... | 1 |
773de85e4bcd764e65dbef8a57b73cdd | 9b930d3bc0b7812095f42aa9cd50891c | empty string, only a null terminator | FString::FString() {
m_string = new char[1];
*m_string = '\0';
m_length = 0;
} | 1 |
9e5b4ef40b16a94a2eeb681e269475e0 | 19d24fd242fad1ec0e212ab3e9d43d88 | 通过分类渲染任务 | var cate = JSON.parse(localStorage.cate);
var taskStr = '<li>';
var taskNameStr = "";
for(var j=0;j<cate[pid].childCate.length;j++){
for(var k=0;k<cate[pid].childCate[j].task.length;k++){
taskNameStr += '<p>'+cate[pid].childCate[j].task[k].date+'</p><ul><li onclick="clickTask... | 1 |
373daee5a6995868ecb0559d08e9c414 | 65906dad53b4967e7ba5310da70b335d | utility for "reflecting" a quantized delay enum across the middle of the list | {
switch (p_intEnum)
{
case 0: return 1;
case 1: return 2;
case 2: return 56;
case 3: return 48;
case 4: return 15;
case 5: return 9;
case 6: return 3;
case 7: return 22;
case 8: return 51;
case 9: return 10;
case 10: return 35;
case 11: r... | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.