query_id string | corpus_id string | query string | code string | label int64 |
|---|---|---|---|---|
6a2512f17813857a88839e41fd8f33e4 | b0104dab7e38c64ed115ab16c0775fb6 | Tests parsing a single short option | class StringParserTest extends \PHPUnit\Framework\TestCase
public function testParsingArgumentShortOptionLongOption()
{
$request = $this->parser->parse('foo bar -r --name=dave');
$this->assertEquals('foo', $request->getCommandName());
$this->assertEquals(['bar'], $request->getArgumentValues(... | 0 |
9bb27db077474fd26cf0be39a2e3d685 | b6e21768f130520adc3d877e249be9c0 | Use None for no decoding | class Decoder:
def __init__(self):
pass | 0 |
8e3383e55061fdd8b9b62e11b121f328 | 241906b809a2e1b07dace78cbec0c10b | Gets LSA type. | if (LsType.WLAN_UNNAT_USER_ONOFF.value.equals(value)) {
return LsType.WLAN_UNNAT_USER_ONOFF;
} else if (LsType.WLAN_NAT_USER_ONOFF.value.equals(value)) {
return LsType.WLAN_NAT_USER_ONOFF;
} else if (LsType.WLAN_UNNAT_USER_ACCESS.value.equals(value)) {
return ... | 0 |
2505e8ed1da7af60a89bfb88478fd0a4 | 6a28e8fef0262c2a93b073b718e2cced | evaluate to | if (typeof exp === "number") {
return exp;
} else if (typeof exp === "string") {
if (exp in env) {
return env[exp];
} else {
throw new ReferenceError("'" + exp + "' is not defined");
}
} else if (exp instanceof Array) {
let [func_name,... | 1 |
527e931e29919f0d196a380d2c8c02ab | ec66d63a187e21c65b94dc8eb540eb6a | @brief Set Main Audio Clock Select.
( 0 : Internal Clock, 1: External Clock ) | void AuxIntOsc2Sel(void)
{
EALLOW;
ClkCfgRegs.CLKSRCCTL2.bit.AUXOSCCLKSRCSEL = 0;
EDIS;
} | 0 |
ff1f84c84fac7a5c0961bc4c0dcb90c1 | d58843b5bc68788e46e9acd0dafc048f | Lists the pareto-optimal trials for multi-objective study or the optimal trials for
single-objective study. The definition of pareto-optimal can be checked in wiki page.
https://en.wikipedia.org/wiki/Pareto_efficiency | points = np.linspace(0, 8, 9)
return dict(
n_trials=9,
resources=1,
results={
hashlib.md5(str([point]).encode("utf-8")).hexdigest(): (point, (1, point))
for point in points
},
) | 0 |
f8ff50bded57c6d8b04fdbce42c6e769 | be19f0d79039a093a3a4049731e3dc89 | 使标签卡处于静止状态 | namespace MCC
public class HZC_Head08Card
[DllImport("JotCard.dll", EntryPoint = "HZC6C0008_Stop",CallingConvention=CallingConvention.Cdecl)]
extern public static int HZC6C0008_Stop(int canno, int cardno, int axis); | 1 |
fd76127755798136495faa5da581f81e | a044484d6647d67886186ea411477a11 | 显示结束界面(失败) | export class GameScene extends eui.Component
private closeEndFail() {
} | 0 |
d81c65d4107526617509d4e34c03221a | ea7b0c4fbdaef396107b519c3d41d6a4 | Gets the inner com.azure.resourcemanager.monitor.generated.fluent.models.AlertRuleResourceInner object. | {
if (array_key_exists("alert", $this->_propDict)) {
if (is_a($this->_propDict["alert"], "\Beta\Microsoft\Graph\ManagedTenants\Model\ManagedTenantAlert") || is_null($this->_propDict["alert"])) {
return $this->_propDict["alert"];
} else {
$this->_propDi... | 0 |
2a5c4d4f05bc1c71b01ea330f4c9cba9 | 62a8812f04d48570e9ae00fc7343f2a8 | Get user location by IP range, if no location matches, returns default location. | class LocationHelper
public static function getLocationByUserIp($userIp = '')
{
$geoData = IPGeoLocationDetector::getInstance()->getCoordinatesByIP($userIp);
return $geoData['city'];
} | 0 |
f9e1d422bd3c02a6aa1d5523fa8c0a4f | e7e2bf33cc716671bf36e72187aaeeb2 | Analyze the reason for the failure | {
$value = $this->getData('failure_reason');
if (empty($value)) {
return null;
}
if (! is_array($value) && ! is_object($value)) {
$this->setData('failure_reason', unserialize($value));
}
return Mage::helper('postfinancecheckout_payment')->trans... | 1 |
daef8f9e3ccdbfec9f40bf716940bd36 | 245c3026799b7d142ee8c71eee093aee | Commits all previous changes to the filter.
Must be called before first executing the filter. | imf_commit(struct in_mfilter *imf)
{
struct ip_msource *ims;
struct in_msource *lims;
RB_FOREACH(ims, ip_msource_tree, &imf->imf_sources) {
lims = (struct in_msource *)ims;
lims->imsl_st[0] = lims->imsl_st[1];
}
imf->imf_st[0] = imf->imf_st[1];
} | 1 |
7bbc350f6be16af717622fa0e96f053f | db61e4977bd3a9cb99309a859c729972 | Compare performance of two models. | results = {}
for i in range(len(df_early)):
for j in range(len(df_late)):
accuracy, recall, precision, cm, predictions, predictions_prob, _ = train_model(model, df_late[j],
df_early[i],
... | 0 |
8ab350114123ba5c8af1f24ad15707b1 | 3980d11c6dadb45b2fa7a3519a9bef2b | String to Carbon from secure sources (database, after update...) | {
return $value ? Carbon::createFromFormat('Y-m-d H:i:s', $value) : null;
} | 1 |
00fbd1df803562042b1fde4ef8c7a00c | ac0d00de9388dd52c26eeca61083bf55 | Reboot device | Reboot ( device, "download" );
RunAdbCommand ( device, AdbCommand.Reboot, "download" );
} | 1 |
050d931141c59ffa6131426ba41bc98f | d2ab75007099b9e2cf835f8e49984120 | \brief Modificar datos de Entrega | {
using (Contexto contexto = new Contexto())
{
using (var tran = contexto.Database.BeginTransaction())
{
try
{
EFEntrega eFEntrega = contexto.Entregas.Include("Pedido.DetallesXPedido").Include... | 1 |
64c7a582ad5180403e39f5da89aa3928 | a6afcac6a745bd865303a5fe927d0635 | Decrypts the specified access token. | namespace Titan.WebAPPTest
public partial class Form1 : Form
private static void Decrypt(string token, string secret)
{
try
{
IJsonSerializer serializer = new JsonNetSerializer();
IDateTimeProvider provider = new UtcDateTimeProvider();
... | 1 |
d250259e773a899967631ddce3dd4e2d | 0ada6bfc6319a77c6f247edf9188ee41 | Generates gene - random String of 1s and 0s | def gene():
return random.randint(0,1) | 0 |
0da423627f66b2794b8e2874f21deb89 | ec6ff5566e40033b426f391a6a466785 | Gets the OpCo shipment line. | namespace Discovery.BusinessObjects.Controllers
public static class OpCoShipmentLineController
public static bool DeleteLine(int shipmentLineId)
{
throw new NotImplementedException();
} | 0 |
d3f30b1c8a79c0944f22a5cf8974a6d3 | 755f0ad8b4ea61cad012944caba7532b | hàm tải về danh sách khóa học | {
new Thread(() =>
{
try
{
HttpRequest http = new HttpRequest();
http.Cookies = MainWindow.cookies;
string httpResponse = http.Get(MainWindow.domainURL + "/subjects").ToString();
... | 1 |
67336d85f27fc356e4f0638dff0b6f12 | 2d6e437ae71e87751bb8fd4766770485 | t.foo = "bar" -- with lua_setfield | namespace KopiLua
public partial class Lua
public static void setsvalue2n(lua_State L, TValue obj, TString x) { setsvalue(L, obj, x); } | 0 |
cb57a263ffdc5bf8696af97840365c02 | 7f29fbb750d4e6bd29119ba2abc8b0bb | returns if the Add Ingredient Picker Cell is Shown | {
if (grid.BoundGridHelper.SearchRow != null)
{
return grid.BoundGridHelper.SearchRow.Visible;
}
else
{
return false;
}
} | 0 |
aa3b4c7c5b776e5f6bb634dc0636f56d | 42cf30192861494c52616d7991350739 | Calculates desired behaviour and updates desiredAccleration accordingly. | public class VrController : MonoBehaviour
private void CalculateAcceleration()
{
if(_surfingValue > 0)
{
_accelerationFactor = Mathf.Abs(_angularVelocity.y) * .25f;
if (_accelerationFactor > MaxAcceleration)
{
_accelerationFactor = MaxAcceleration;... | 1 |
641cfb8c732dca9edbc64c709a6fde25 | 0d36a9a9b1a6c4b618f60eff18bd44a9 | Fetches digital credential information. | namespace Streetcred.Sdk.Contracts
Task<CredentialRecord> GetAsync(Wallet wallet, string credentialId); | 1 |
2f9c2cdcc6f5d84bba6f92c2d623ec5a | d2a278b05c246f01521972dab1807c44 | Load subwaystops from disk. | stop_id_name = stops[["stop_id", "stop_name"]].sort_values(by="stop_id")
row, col = stop_id_name.shape
for i in range(0, row):
sid, name = stop_id_name.iloc[i]
graph.add_stop(Stop(sid, name)) | 0 |
f78b9e4d6e1a2c7ee7aafd3b86c37e0d | 39e76be4c36cc8420c082f5b8f9a20a1 | Add Upload tab to the popup windows | function open_file_upload(){
$(".add-file-popup-container").show();
} | 0 |
f7748453fb09ccc0d8d35ab06075f6aa | b549ff140e55198676fc5e95a44ab0af | Envoyer un e-mail sans passer par PHPMailer (Expediteur ovh visible, sans html). (Eviter d'utiliser dans la mesure du possible) | {
if (!is_array($mailto)) {
$mailto = [ $mailto ];
}
if (getenv('ENV_MOD') === 'dev') {
$transport = (new \Swift_SmtpTransport(getenv('CONTAINER_MAIL'), 25));
}else{
$transport = (new \Swift_SmtpTransport('smtp.gmail.com', 587, 'tls'))
... | 1 |
2965a834cf4c5906f15188ca1408ad01 | 2a60a12318e4bcf93cd8f98bbd3a7e9a | End enumeration of the Open Directory Service password list | MSdpElementBuilder* CObexSdpUtils::EndListL()
{
return this;
} | 0 |
2f15e1435c7830efb9d570995a530a9c | 98f42b97ba353ec40e411b15313dbc6a | EurobateGateway constructor. | class BankPaymentGateway extends BasePaymentGateway implements PaymentGatewayContract
public function __construct($currency = 'usd', $discount = 0)
{
parent::__construct($currency, $discount);
} | 0 |
4d0c79d2b0e78ebc1afe603a7e3be774 | 46cc2a17b92035017fc12e752e7e038e | 仅终止合同 | fileName = 'apartmentContract_1016'
contractSql = "SELECT contract_num,rent_end_date from apartment_contract where deleted = 0 and city_code = 330100 and audit_status = 'APPROVED' and contract_status = 'EFFECTIVE' " \
"and contract_type = 'NEWSIGN' and entrust_type = 'SHARE' and payment_type... | 1 |
a905ef0c213efc946a3d96d0e94b995c | 4c91ed057539f80c76873a54fc35b25e | 获取该课程的所有学生成绩 | public List<Map> getScoresByCourseId(String courseId); | 1 |
e7e80a1c36009772910269e1d14ca720 | 640ebed4325386e1085813a2afb23c1c | метод который возвращает все прочитаные книги что есть в базе | public class Repo extends SQLiteOpenHelper
public List<Book> getReadBooks() {
List<Book> mList = new ArrayList<>();
String cols[] = {ID_B, NAME_B, PICTURE_B, AUTHOR_B, READ_B, FAVORITE_B};
Cursor c = getReadableDatabase().query(TABLE_NAME_B, cols, READ_B + "=" + 1, null,
null, nu... | 1 |
99a5e4bce0a54091c83957b471cbd8d0 | f1a95dc946fede0eb5ce50f03f324281 | Enables application cache domain notifications. | public sealed class DomainSavedDistributedCacheNotificationHandler : SavedDistributedCacheNotificationHandlerBase<IDomain, DomainSavedNotification>
protected override void Handle(IEnumerable<IDomain> entities)
=> _distributedCache.RefreshDomainCache(entities); | 1 |
c4cd4c6e80140fd4502a625c1a74bb76 | d9b793460e1104eb23657bea488f8dc6 | 父协程的职责 | class Team_kun_25_captain(Team_kun_25):
def father(self, argument, handle):
return Team_kun_25.do_work(self, argument, handle) | 0 |
4ddc63392bff456adabdc01132aff57b | 6cb88c6db78aca6d1ed46b9e769cb43b | 发送post请求,带参数,带请求头 | public class HttpRequest
public static String sendPost(String url, String param) {
String result = "";
try {
URL realUrl = new URL(url);
URLConnection conn = realUrl.openConnection();
conn.setRequestProperty("accept", "*/*");
conn.setRequestProperty("conne... | 1 |
22a435d580a0ca524588c15731205f25 | 662d27ad2a2affb01a2c52117ba35afa | 保存已有选区 | function saveArea(count,i,type){
if(type==='new') {
var sheng=$("#sheng_"+count+"_"+i).find("option:selected").text();
if(sheng=="全部"){
sheng="";
}
if(sheng==null||sheng==""){
$('#sheng_'+count+'_'+i).attr('data-prev','')
$('#shi_'+count+'_'+i).attr('data-city','')
$('#xian_'+count+'_'+i).attr('dat... | 1 |
f70988d0ed71700e52911aa727be17e8 | dfe33e003150f2f27f4ae21ce1f49a78 | 判断start 是否为关键字,并返回token | static TokenType idOrkeyword(const char* start, uint32_t length) {
uint32_t idx = 0;
while (keywordsToken[idx].keyword != NULL) {
if (keywordsToken[idx].length == length && \
memcmp(keywordsToken[idx].keyword, start, length) == 0) {
return keywordsToken[idx].token;
}
... | 1 |
c4e5788d724ca65703512d6671823031 | 67ce9569bffe8a4e067e5a500f835013 | Gomega's default string diff behavior makes it impossible to figure
out what fake command is failing, so turn it off | func init() {
git.SetOS(gittest.FakeOS)
} | 0 |
93b9eec54bf907f53605cab7561a5cf7 | e1600173cd6c307d6312a5a01ea2c2b4 | Sets number of milliseconds per simulation tick. | void wamControl_setMsPerTick(uint16_t msPerTick){
milliPer = msPerTick;
} | 1 |
bc9d016989a4425bb78a16a214ba5be6 | 4751a15e44a6be9ef3007579d64a5e12 | Math to calculate the intersection between two circles | out Vector2 intersection1, out Vector2 intersection2)
{
float cxA = circleA.Center.x;
float cyA = circleA.Center.y;
float radiusA = circleA.Radius;
float cxB = circleB.Center.x;
float cyB = circleB.Center.y;
float radiusB = circleB.Radius;
float dx = cxA - cxB;
float dy = cyA - cyB;
float dist = Ma... | 1 |
6dd3c90bce9fbed33bac66c40164fca0 | bada51f289cceccbc43e0b3d21e93734 | Triggers the OkPressed event | namespace Ariadne public class EventProcessor : MonoBehaviour, IShowingMsg
public void OnPressedOkButton(){
isWaitingMsg = false;
} | 0 |
bbd38a166c1fcb56f6504d64b23bf394 | f1f3e3c362b622da5a92d5a75af19a1c | 遍历方式删除节点 | class SingleLinkedList
public void del(HeroNode node){
HeroNode helper = head;
boolean flag = false;
while (true){
if (helper.next == null){
break;
}
if (helper.next.no == node.no){
flag = true;
break;
... | 1 |
e522c79cb965f3f600f0a5f38285458e | 4b2656eae75430467cb9435fa571bb3c | Clears the focus from all boxes. | class ListBox(QtWidgets.QListWidget, QtWidgets.QWidget):
def lstboxCleaner(*listboxes):
for lst in listboxes:
lst.clearFocus()
lst.clearSelection() | 1 |
07d8efb876c83dcae8fc9af0159225a9 | 026d53b0ba523fd7e55e8a79a562c092 | 获取所有的笔记本 | var userId = getCookie("uid");
if(userId == null){
window.location.href="log_in.html";
}else{
$.ajax({
url:base_path+"/book/loadbooks.do",
type:"post",
data:{"userId":userId},
dataType:"json",
success:function(result){
if(result.status == 0){
var books = result.data;
for (var i = 0; ... | 1 |
1e4fd2809c3175fe48f560bcbbe0efd4 | 0123b8cd24c2bb542583c6aa5fd1942a | 获取默认的Z轴数据列. | namespace MB.WinChart.Share
public class ChartViewHelper
public DataColumn GetDefaultDataColumnZ(
List<ColumnPropertyInfo> columnPropertyInfos, DataColumnCollection dataColumnCollection, DataColumn dataColumnX)
{
try
{
DataColumn dataColumnZ = new DataColumn();
ColumnPropertyInfo columnPropertyInfo ... | 1 |
4e5e4aef4783f870c70fa652802f8c36 | e8bf5cbe19dc5ab9f345487225616004 | 短信找回密码页面 | @Controller
public class PasswordController
@RequestMapping({ "/", "/findbackBySmsCode" })
public String findbackBySmsCode(HttpServletRequest request,
HttpServletResponse responsel, ModelMap model) {
return "/safe/password/findbackBySmsCode";
} | 1 |
3b8ce05085931d070a4f421970fa82f2 | 3bdc3dfe51c16b9155e759a021f8c46c | Gets the forceChangePasswordNextSignInWithMfa property value. If true, at next sign-in, the user must perform a multi-factor authentication (MFA) before being forced to change their password. The behavior is identical to forceChangePasswordNextSignIn except that the user is required to first perform a multi-factor auth... | class PasswordProfile
def force_change_password_next_sign_in
return @force_change_password_next_sign_in
end | 0 |
ff04f27b7c0d0e617a517b4bcb2b02e6 | 6a76c30464ef257aacb89eaeaf9321e0 | Switch the last two items on the stack. | class Machine:
def revstack(self):
self._pshstack(*self._popstack(n=2)) | 1 |
45d69cf392a56083abda91aec5d57422 | d985b90cfe4fe17ab0edfd8b74c4ffee | evaluate
Evaluates a learner or set of learners on samples from a stream. | {
$this->backend->flush();
foreach ($this->members as $estimator) {
$this->backend->enqueue(new Predict($estimator, $dataset));
}
return array_transpose($this->backend->process());
} | 1 |
cbed534d11d26f3d20928360e771758b | 6dfe7cbcfc814dea8f4264dd2ed2a4c2 | 기반시설 보호대책 중점과제 파일을 삭제한다.
현재는 소프트 삭제로 진행한다. 업로드된 파일은 삭제하지 않고 DB상에서 논리적으로 삭제한다. | @Service
public class ProjectInfoReqSvc
public void deleteReqProjectFile(String req_idx){
ReqmntProjectFileDto fileInfo = new ReqmntProjectFileDto();
fileInfo.setReq_idx(req_idx);
projectInfoReqDao.deleteReqProjectFile(fileInfo );
} | 1 |
dc97e89b2d587214fcfc0c794c9b8ea2 | 608c11bff6b361a170cde6ddaa07e167 | Prove that cluster templates get updated with proper values
after a referenced node group template is updated | all_nodes = cloud_provider.create_multiple_nodes(2, test_name)
before_update_nodes = all_nodes[0:-1]
rke_template = 'cluster_update_roles_5_1.yml.j2'
network, dns_discovery = create_and_validate(
cloud_provider, rke_client, kubectl, rke_template, before_update_nodes,
base_namespace='be... | 1 |
a6f06ba7271b7a76f1dbb502b80503ef | 43b09a53adb9b2b26cef8da34df495d7 | Whole Loan
Executes the CheckIn process, routes to Services to update the DB, and then back to Index //RedirectToRouteResult | namespace SingularityFAAST.WebUI.Controllers
[Authorize]
public class LoanController : Controller
[HttpPost]
public ActionResult CheckInLoan(LoansClientsInventoryDTO loan)
{
var dto = new CheckInWholeLoanDTO()
{
ClientOutcome = loan.ClientOutcome,
... | 1 |
6833496cc44bb3b12d9258e903af8022 | 3012a25a91ad45662be5c6463ce48ddf | функция для приема или отклонения запроса на дружбу | if accepted == "true" then
self:BuddyAnim(BuddyFinderAnim.AcceptIn, false, function() self:DelayedAnswer(true) end)
else
self:BuddyAnim(BuddyFinderAnim.DenyIn, false, function() self:DelayedAnswer(false) end)
end
end | 1 |
f1fac7e75dbeca1779e04cd133630ae8 | 8cadac1799121fb89d240ade360d8ec6 | Returns the initial view to display. | namespace Coddee.Xamarin.Forms
public class ViewModelBase<TView> : ViewModelBase, IPresentable<TView>
where TView : VisualElement, new()
public TView GetDefaultView()
{
return (TView)GetView(0);
} | 1 |
896352aa0d94a7a7fdeaebb570b99bfe | 3d3bb6dc575ae2fa01b93bf979cc8dd9 | 根据插件名获取可配置的权限节点名称清单 | def _get_plugin_auth_node(plugin_name: str) -> list[str]:
plugin = get_plugin(name=plugin_name)
if plugin is None:
result = []
else:
result = [s.auth_node for s in (
parse_processor_state(m._default_state) for m in plugin.matcher
) if s.auth_node is not None]
resu... | 1 |
25145d286da70ee66fa9bfa8e37532bb | 50fbca290f110ce3a29de640c66e3ada | 设置腾讯微博SSO handler | String appId = "100424468";
String appKey = "c7394704798a158208a74ab60104f0ba";
UMQQSsoHandler qqSsoHandler = new UMQQSsoHandler(
ActivitySellerDetail.this, appId, appKey);
qqSsoHandler.setTargetUrl("http://www.baidu.com");
qqSsoHandler.addToSocialSDK();
QZoneSsoHandler qZoneSsoHandler = new QZoneSsoHan... | 0 |
959249edee511c0154244f65bec39c21 | d5181c0fac7f7bd0535cfdab23321349 | Checks whether the given interface or class has documentation for
all declared type parameters (no less, no more). | boolean result = true;
TypeVariable[] params = doc.typeParameters();
Set<String> paramsSet = new HashSet<String>();
for (TypeVariable param : params) {
paramsSet.add(param.typeName());
}
ParamTag[] paramTags = doc.typeParamTags();
Map<String, String... | 1 |
bd3f2f3bacf382dbd4d462eef2ef4b45 | b0ead7f12382d375ea929adf84cfc77d | Inserts the string representation of a single-precision floating point number into this instance at the specified character position.
The inserted string is NOT considered user controlled for the purpose of attack detection. | [__DynamicallyInvokable]
public StringBuilder Insert(int index, ulong value)
{
return this.Insert(index, value.ToString((IFormatProvider) CultureInfo.CurrentCulture), 1);
} | 0 |
d81df8175d96bf961942af9a4510b040 | 0099fe727931af0f033dd0fcd02c8b9e | Test that making a second affiliation request
does nothing for normal members bc
a signal intercepts the request (issue 930) | class TestAcceptInvite(APITestCase):
def test_user_already_member(self):
m = MembershipFactory.create(role=0, user=self.u)
i = InviteFactory.create(user=self.u, organization=m.organization,
role=1)
response = self.client.post(reverse('resturo_organization_join'),... | 1 |
a2ccd7411b85f62eb92dc2f65b8232c1 | c9d1257c6d34251d54d1d8d8b7849ac2 | !
@brief Checks whether the node had previously established a key through CBKE
with the Trust Center. | {
flag_node *n;
check_init(t);
n = &t->node[key & (t->size - 1)];
do
{
if ((n->flags & FLAG_FLAG_USED) && (n->key == key))
{
return (n->flags & FLAG_FLAG_KNOWN) ? TRUE : FALSE;
}
n = n->next;
} while (n);
return FALSE;
} | 1 |
90c38fc698d314f0fb8e6451a4ecf9c5 | dd1131e196ba0a62585e273e8116117d | Get the left trigger (LT) axis value of the controller. Note that this axis is bound to the
range of [0, 1] as opposed to the usual [-1, 1]. | @SuppressWarnings("MethodName")
public class CommandXboxController extends CommandGenericHID
public double getLeftX() {
return m_hid.getLeftX();
} | 0 |
b8c608368e5c7479189336b174f3334b | 2ed82906b3fcf65e51b1d6847bfdaafb | Get the trend in the number of active OneDrive users. | namespace Microsoft.Graph
IReportRootGetOneDriveActivityFileCountsRequestBuilder GetOneDriveActivityFileCounts(
string period); | 0 |
787cff8c3029ef50570b0b7fc461cbbb | 8e2cf64dc0c1a418bb5a5ccb285f276b | Given a compressed path, return a new path that has all the segments
in it interpolated. | class PathLexicalizer(Lexicalizer):
def convert(self, path: Iterable[str]) -> str:
pass | 0 |
ad89022267a03b78af3fc2481a9e671d | 9d64ee30f3c996405359155f1e028596 | получаем конфиг либо из аргумента либо дефолтный и отдаем содержимое | function init_config($configs)
{
if (is_array($configs)) return _config($configs);
if (is_file($configs)) return _config(include $configs);
} | 0 |
b0fe1e9464d36848eb82082d2dedb952 | 4aadd3c1eec28d4686018a55f42174de | Sets the fill style of a given sub-block of cells, XSSF version.
The other properties of cell styles are preserved. | {
if (_cellXf.applyFill)
{
int fillId = (int)_cellXf.fillId;
XSSFCellFill fillAt = _stylesSource.GetFillAt(fillId);
return fillAt.GetCTFill().Copy();
}
return new CT_Fill();
} | 0 |
e0545693906575b04aa1650abd60faba | e8a8153811da926cfe811ae443e86c57 | Français | void MainWindow::on_actionFran_ais_triggered()
{
m_settings->setValue("Language",1);
updateLanguage(m_settings, &translator);
} | 1 |
9f14ca2a6b45aac540905be07bdf4b30 | b1a71ec0e71ffc16eae4cd57d300187d | Método que retorna la tabla de tipos global | public class TablaView extends JPanel
public Tabla getT() {
return t;
} | 0 |
4904aad264120d32cce862ae2f08c655 | b561a6a14577a07848aba74a501c2435 | items를 SharedPreferences에 저장 | class SharedPreferencesUtil
fun saveItem(context: Context?, keyPrefs: String, prefs: String, value: String?) {
val sharePreferences = context?.getSharedPreferences(prefs, MODE_PRIVATE)
val editor = sharePreferences?.edit()
editor?.putString(keyPrefs, value)
editor?.apply(... | 1 |
c570c2935a7018887eb5457a64026a6a | 98b32f17a3ce778670626a9e413208b2 | List of media files that can be uploaded. | {
return [
self::CS_MEDIA_TYPE_OTHER,
self::CS_MEDIA_TYPE_MP3,
self::CS_MEDIA_TYPE_MP4,
self::CS_MEDIA_TYPE_WAV,
self::CS_MEDIA_TYPE_FLAC,
];
} | 1 |
8aa5c82d6a81afd1e309a57efca16450 | 2804a6ffd5e208660000a5a4bb4dc662 | Retrieves the current game, or creates one if none exists. | GameState gameState = Loader.loadGame(true);
if (gameState == null) {
gameState = Loader.newGame();
if (!Loader.checkForSave()) {
suggestTutorial();
}
}
return gameState;
} | 1 |
3fc1541e598d9d2072d3fa6dd3b93306 | 5d7fa63e12c0e33abd399a095c4b623a | 录入毕业答辩成绩列表 | @Controller
@RequestMapping(value="/admin/graduateinfo")
public class GraduateinfoController
@RequestMapping(value="/export.do")
public void export(HttpServletRequest request, HttpServletResponse response) throws VerifyException
{
Department department = (Department) request.getSession().getAttribute("department");... | 0 |
c58b2e0ffc4cf2383d2ae301d6307216 | f301a49904c0e46685b15b956d0855b5 | 返回用于在日志条目和日志文件名后缀中用于格式化时间戳的区域设置. | function datefmt_get_locale ($which = null) {} | 1 |
7b67dda6c663f85d6776549f68d4b398 | f69cb5a26d9a826e012f55c032e4df44 | Prints the gradients of the network. | class Network(torch.nn.Module):
def grad_flow(self, path):
grad = [
b.synapse.grad_norm for b in self.blocks if hasattr(b, 'synapse')
]
plt.figure()
plt.semilogy(grad)
plt.savefig(path + 'gradFlow.png')
plt.close()
return grad | 0 |
05caf280a2c15f1fa3edfc2f914a21e3 | 9f57b733866ef1f6d0944ce6695e0716 | list的每个元素应用函数fn,生成新的list。 | res = []
for i in itea:
res.append(func(i))
return res | 1 |
588c8674b1f584cc4ee34365b1de13b6 | 594054d4d13b4ed6fe739fb7eeea19ff | Returns the number of females in the database. | {
int numFemale=0;
for(int i=1;i<=studentData.size();i++)
{
if(studentData.getStudentAt(i).gender.equalsIgnoreCase("F"))
{
numFemale++;
}
}
return numFemale;
} | 1 |
0f409125c9714558225f0b0e4d7ef6ba | d0de1df92a832a318479f79674a1b87d | Invoked when bar is expanding. | namespace Int.iOS.Factories.Adapter.V2
public abstract class UIExpandableTableViewHeaderCell<T> : ComponentTableViewCell<T>
public virtual void OnExpand() { } | 1 |
34b0823327c8f99b7087b80d6f6f2b89 | 354089f76f78c6a9a01f33499c4d9d8d | Devuelve una lista con los nombres de todas las carpetas en la app | @Component
@ManagedBean
@ViewScoped
public class FolderController extends AbstractUIController
public List<String> getFolderNames() {
return new ArrayList<>(folderNames);
} | 1 |
d479e138ca43e1a3e4ecc06c71868f19 | 20ccc09c077703203434ae5c487cf22f | Devolve uma lista do tipo de aulas existentes | String sql = "SELECT * FROM aula_table WHERE COD_PROF = ?";
try {
PreparedStatement stmt = this.conn.prepareStatement(sql);
stmt.setString(1, "-1");
ResultSet rs = stmt.executeQuery();
List<Aula> listaAulas = new ArrayList<>();
while(rs.next())... | 1 |
27005503a4b8c63243c5dd8220b656ef | c7768f9c22705226f985f3f0851e185b | 子コンテンツをモーダルのボディ用htmlとする | namespace TagHelperWebApp.TagHelpers public class ModalPartialTagHelper : TagHelper
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output) {
_model.Body = await output.GetChildContentAsync();
await _inner.ProcessAsync(context, output);
} | 1 |
f54667ec78732f59229afcef892d520e | e531e91a0ec17010d49762a4936af583 | Convert this color's hue to radians (360° == 2π radians) | if (@max == @r) then
h = ((@g - @b).fdiv(@max - @min)) * 60
elsif (@max == @g) then
h = (((@b - @r).fdiv(@max - @min)) * 60) + 120
elsif (@max == @b) then
h = (((@r - @g).fdiv(@max - @min)) * 60) + 240
elsif (@r == @g && @g == @b && @r == @b) then
h = 0
end
if h < 0 then
... | 0 |
32205c6e5a09cd7b338bd6ca1fe94979 | a49296b475941b914dd8fe901a010eec | Funkcja sprawdzająca poprawność wciśniętych przycisków w poziomie różowym
względem wyświetlonego napisu
i zgodnie zjego wartością wykonywane są kolejne czynności takie jak
wyświetlenie odpowiedniego okna z informacja o dobrym lub złym ruchu,
zmiana wartości odpowiedniego parametru, w celu umożliwienia wyświetlenia
kole... | {
if (color == text_color[answer_index].Item2)
{
general_points += difficulty;
current_mistakes = 0;
if (++current_positives > 2) raiseDifficulty();
}
else
{
current_positives = 0;
... | 1 |
8e5b79a972c5f985a33e47867b14b8da | 0101a5d5fdec330f22fb1450832ebce4 | Remove everything that was added by Core Protege and
build menu again. This seems safer than removing select items
and then inserting items in particular places. | for (JMenuItem item : _menus) {
this.remove(item);
}
_menus.clear();
_offset = 0;
} | 1 |
7a807c59e1765f55f8b71bab9c41c1a6 | 121980f632cc5a4e40b85d6c92c4a5ce | Get the number of changesets in the analysis window. | throws InterruptedException, TimeoutException {
return Integer.parseInt(
JavaScriptUtils.executeJavaScriptAndWaitForResult(
mContentView,
new TestCallbackHelperContainer(mContentView),
"changes"));
} | 1 |
7066a86de32d5b9708804144712397c9 | 5abcd6d62e7e49c94cf98df83e82cc81 | Common Helper for Line Operations on D-cache | LOCAL void CleanInvalidateDCacheL( VP addr, INT blk )
{
Asm("0: \n"
" subs %1, %1, #1 \n"
" mcr p15, 0, %0, cr7, c14, 1 \n"
" add %0, %0, %2 \n"
" bne 0b \n"
" mcr p15, 0, %3, c7, c10, 4 \n"
:
: "r"(addr), "r"(blk), "r"(CACHE_LINESZ), "r"(0)
: "cc");
} | 1 |
18454ba04ff0d66d45293d6951f296fa | 960024de9d31aa7a73860dd3468db966 | Get Reason Value Options | {
return [
[
'label' => __('Default'),
'title' => __('Default'),
'value' => false,
],
[
'label' => __('Primarily individuals'),
'title' => __('Primarily individuals'),
'value' ... | 1 |
e196223184b0baa27c58e5653c742822 | b5d06400ab79caaacc6417eead0ffd5a | 函数说明:绘制前向逐步线性回归系数矩阵 | def plotwMat():
abX, abY = loadDataSet("abalone.txt")
ridgeWeights = ridgeTest(abX, abY)
fig = plt.figure()
ax = fig.add_subplot(111)
ax.plot(ridgeWeights)
ax_title_text = ax.set_title('gaun xi')
ax_xlabel_text = ax.set_xlabel('log(lambada)')
ax_ylabel_text = ax.set_ylabel('ws')
... | 0 |
9c5caa670711085f3ada078fff0eafbc | f3971b7ae995081e783c0ef1ea81dcd7 | Bir json stringini xml Stringine çevirir. | StringReader input = new StringReader(xml);
StringWriter output = new StringWriter();
JsonXMLConfig config = new JsonXMLConfigBuilder().autoArray(true).autoPrimitive(true).prettyPrint(true).build();
try {
XMLEventReader reader = XMLInputFactory.newInstance().createXMLEventRea... | 0 |
3b2aa4d254b5696ab7cc6159e443532b | 0b98125548d1b486591f1193d6286fae | Moves the time in the engine to newTime and updates all projectiles accordingly. | public void update(long newTime); | 1 |
41909c1cbba5e29ac2da72aa1aaf7132 | df93869391fa459f17d5b3dbc3fd0384 | Test Method for Empty string values addition | class Unit_Admin_AttributeMainAjaxTest extends OxidTestCase
public function testAddFilter()
{
$oView = oxNew( 'attribute_main_ajax' );
$this->assertEquals( "", trim( $oView->UNITaddFilter( '' ) ) );
} | 1 |
cb9fbe5db91f164da9b9ac4f72551726 | 2e25f0db5ffbcbe07d734bfcf8b09aec | Returns the count of sections of a given type. | {
Native xResult = 0;
byte xType = 0;
bool xCounting = false;
for (byte* p = mRAT; p < mRAT + mPageCount; p++)
{
if (*p == aType)
{
xType = *p;
xResult++;
xCou... | 1 |
ed80c9c95dbe29387d772a0fff9b4a6e | 4ec824ba279628ea04a9d9b78eb55f5a | Retrieves a file listing of backends. | def cmd_backends(**opts: tp.Any) -> None: | 0 |
91dedb295907e4a869811397cc2f1210 | 93ad860a3d0a48c44a3e3708b62d731b | 为类生成该类的注解 | public class PGEntityBuilder implements EntityBuilder, Serializable
private String buildClassAnnotation(TableBean tableBean) {
return String.format("/**\n * 该实体对应的table: %s\n *\n * @author kris.zhang\n */\n", tableBean.getTableName());
} | 1 |
133b2abaa621436ea39bdf018fe6e85b | 3e15bb6000b1aeee882f1caba13715f1 | Valida a existencia do dados da tabela de desconto/acréscimo. | {
if (grupoDesconto == null)
{
throw new Prion.Tools.PrionException("Objeto não definido.");
}
if (grupoDesconto.IdSituacao == 0)
{
throw new Prion.Tools.PrionException("A Situação tem que se informada.");
}
... | 1 |
1dca77befc70da9835e267d98cf69b67 | 6714359738905e3d724197eeb771098d | Opens a dialog allowing the user to edit the PeptideShaker settings. | public class PeptideShakerGUI extends javax.swing.JFrame implements ClipboardOwner
private void projectPropertiesMenuItemActionPerformed(java.awt.event.ActionEvent evt) {
new ProjectDetailsDialog(this);
} | 1 |
c961dbf66e8234df6f7654baf1d86f24 | 248b25c44c67f8ed47ee25ebd8483ab2 | 保存到指定路径,如果不存在则创建文件夹,文件名不变 | function save(_path,data){
if(exists(_path)) {
remove(_path);
}
_path = escapePath(_path);
createDirectory(path.dirname(_path));
fs.writeFileSync(_path,data,"utf-8");
} | 1 |
d56e3b3e9d29dd7b97fbe0b1383c7c14 | edc42647ff2f0d9136887f7f7f741ef2 | lấy ra 9 bài viết được duyệt mới nhất | class HomeController extends Controller
public function index()
{
$newpost = TinTuc::orderBy('id','desc')->take(3)->get();
return view('client.trangchu',compact('newpost'));
} | 0 |
282bb2c0ccf590f28d82cf529f6b5e8d | c361139434a3cdb78acf774e83b42958 | Move to Visuospatial Sketchpad Result Scene | namespace UI
public class SceneSwitcher : MonoBehaviour
public void MoveToVSResultScene()
{
SceneManager.LoadScene(SceneName.VISUOSPATIAL_SKETCHPAD_RESULT_SCENE);
} | 1 |
be955a4031a94e61e4b9fb37993531cb | 9c83ffee2e9c0502cb7d67b81561ff89 | Converts the name of the state into an index number | namespace Exolutio.Model.PSM.XMLValidation
class AutomatState
public int getIndexOfState()
{
String numberPart = name.Substring(1);
return int.Parse(numberPart);
} | 1 |
42afb1d87d5d4047f6bf4ef9dd740c08 | 3f13988204d64b2a7d2db4c0a845ca71 | Filters whether the current request is a WordPress Ajax request. | function wp_doing_ajax() {
return apply_filters( 'wp_doing_ajax', defined( 'DOING_AJAX' ) && DOING_AJAX );
} | 1 |
e739dcf7f3fd99e4c8584f4583a2b549 | 9ffd9c353ee66a862db9f6cd2efe1116 | Returns the processing time that the image's vendor needed to detect faces.
The processing time that the image's vendor needed to detect faces. | public class VisionValues
public double getPROCESS_TIME() {
return NetworkTable.getTable("VisionVars").getNumber("PROCESS_TIME",0);
} | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.