query_id
string
corpus_id
string
query
string
code
string
label
int64
c4711e6194f00bfd3ecdb3936a406b0c
5edbb25e8d0002b8fc82fdd38b662f23
Applies compilation options to a project.
WriteOption(writer, "fullpaths"); if (BaseAddress != null) { WriteOption(writer, "baseaddress", BaseAddress); } if (DocFile != null) { if (SupportsDocGeneration) { WriteOption(writer, "doc", DocFile.FullName); ...
1
97e5d4653ea1a123c5225e7e8f54e739
f09a2c3bd48793a9a1af2d3491c72cd4
Returns the coffees per day of this user data.
public class DayConsome implements Serializable public Double getConsume() { return consume; }
0
2b7cd7df0795f4e2816a3d10cbc30d14
697991bf847b1e271ba9c332e4f4ed16
1小时内全国阻断URLTOP10
[HttpGet] public JResult GetLocalByMonthTop10() { var result = _dataanalysisservice.GetLocalByMonthTop10(); return result; }
0
29d9516bc858a62a883e186ba4864330
1b852e72acf72c69f4d4e0918ae0d38e
Return a zero matrix
class VectorSpace( metaclass=ABCMeta ): def zeros( self ):
0
068be27c53c55ff25278cb92f9ebd57f
9b239c53ec6a5af68a96ad4430edb17c
returns index of array having the maximum value
size_t fltimax(const double *arr, size_t len) { double max = arr[0]; size_t imax; for(size_t i=0; i<len; i++){ if( arr[i] > max ){ max = arr[i]; imax = i; } } return imax; }
1
1625ef4fe09f68fa20d3ff6e02cd5c8e
7f61448ad6da3ef0f9cb03f40c5be655
GREATER_THAN
cases like (1)
0
e9778f4a419fe4c7c46aff2d3a8f9c09
7001f2cfb89abca944e54a9f6d0f0799
发送收件箱邮件列表消息
{ if (_emailNote.WasSent) throw new Exception("邮件已发送,不能重复发送!"); _emailNote.SendStamp = DateTime.Now; _emailNote.WasSent = true; foreach (var item in _emailNote.RecipientUids) { _emailInBox.Add(new EmailInBox() { ...
1
eba1950a6192fb2f05db9a2f2c049e1f
1703ed163aa5762654936e04959c5a8b
Get the list of vertices in the graph, except those removed. @return
public Set<Vertex> vertices() throws Exception { Set<Vertex> set = new HashSet<>(getVertex()); for (int i = 0; i < getVertex().size(); i++) { set.add((Vertex) getVertex().get(i).deepClone()); } checkRep(); return set; }
0
af49ae268c2c07ac502c86ea3b5809a8
d1aa70ea09de5aba0df2921edea80a3e
Creates an embedded database.
public DataSource dataSource() { return new EmbeddedDatabaseBuilder() .setType(EmbeddedDatabaseType.H2) .addScript("classpath:db/h2/schema.sql") .addScript("classpath:db/h2/security-data.sql") .build(); }
1
33295a88f3ce257d4ee10e52cdac2ea1
fd2543eedd5663aec28d4376e8b40102
多个评论同时获取点赞状态
class Comment extends MY_Controller public function get_stat_all() { $object_id = shtmlspecialchars($this->input->get_post('comment_ID')); $object_type = shtmlspecialchars($this->input->get_post('pageType')); $action_uid = shtmlspecialchars($this->input->get_post('action_uid')); $tid = shtmlspe...
1
66cf113552a24db12ddfa200c2f9f33c
c4b0a94720fb89cdccd91bae75437393
Works like get_roster but just returns a list of students; does not include admins.
class MainController def student_list Student::all.map do |s| s.attributes.except 'id', 'created_at', 'updated_at' end end
0
f7187442302a583429c71d0af5282831
f5fc3da1f3538eb44c17ce38599a5572
Authenticates a user with Ministry Platform.
{ if (string.IsNullOrWhiteSpace(email)) throw new ArgumentNullException(nameof(email)); if (string.IsNullOrWhiteSpace(password)) throw new ArgumentNullException(nameof(password)); JsonObject json = new JsonObject { [...
0
a14d45a79f4cce7b35cb37c3c2bd9913
bddbed00ca9e8684b1838fe0cc733911
Decode a binary label map to a list of structures.
assert isinstance(bytes_data, bytes) n_bytes = len(bytes_data) next_byte_index = 0 def extract_field(dtype): nonlocal next_byte_index width = dtype().nbytes field_buf = bytes_data[next_byte_index:next_byte_index+width] field = np.frombuffer( field_buf, dtype )[0] ...
1
2e5693cc7c86c0dea5095b3b36cefb6a
f68b2c3bc88f7ecb794e60771f1b2e4b
По переданному URL и аргументам определить ID контента, с которого все начнется и записать его в _contentID
abstract class cw_logic extends cw_base_module public function set_content_id( $id ) { $this->id = $id; }
0
9eb6fa97ef8581770aa6185740394369
06298cf21358701254684aef0a1bc930
Returns a random integer between the two values, with the defaults set at 1 and 10.
namespace Domain public class Factory private int GetRandomInt() { int range = 1010101; return random.Next(range); }
0
307ff332492d6e2737a55c9d1d198af2
effbe120ac70a51c6f0161975397f5ef
This method will get executed before each test method
public class TNG_0005 @BeforeMethod public void initialize_I(){ System.out.println("inside BeforeMethod"); }
1
d7d7288f4fefe6e6d431c58b66299664
c0197371f7edf00f5225f8c92727eff7
Set the sort direction for field: City (CMF_EXEMPT.city)
public class TaxExemptionObjectFilter extends BaseFilter implements Serializable public void setCountySortDirection (boolean ascending) { this.CountySortAscending = ascending; }
0
d2c44dbd446ba461822c6b5aef03b840
5a2175c3896478f4ab4ac041e5aa2a16
Determines how far the bow has been drawn
{ if (bHit) { return hit.distance; } else { return laserLength; } }
0
ad3c60d58b1b9e210628a74a6843c5e2
0e504a7245b1bbd66de9516588e9395d
@brief Ymodem协议接口初始化
void InitXMODEM(void) { }
0
5fa23adafbc85b6e33196aa5c255cdc2
7025b8cba8eb333437c87d63183850b8
создает default имя для новой категории
if(!$name) { return false; } $query = "INSERT INTO category VALUES (FNC_CATEGORY_NO(), '{$name}');"; return $this -> connection -> get_result($query); }
0
49cf6c2d2128acb151c11842e518356c
51cef68c70fd7a4a5c536336453e2a10
Откатить изменения команд
class User public function Undo($levels) { print("\n---- Отменить $levels операций <br>"); for ($i = 0; $i < $levels; $i++) if ($this->current > 0) $this->commands[--$this->current]->UnExecute(); }
1
2820dab7eb1756e4a4329525c3458467
5919bba5c037b4a842477b976ad69b11
<p> 将Portal的一套主题另存为。。。 </p>
Theme newTheme = service.saveThemeAs(themeId, name); return doAfterSave(true, newTheme, "ThemeManage"); }
1
59934a5568c5147efae6767d1c195ea6
13cd01997ddf2a9b68337f7715de8e5d
Altera uma maratona.
@Stateless @Path("miaa") public class miaaFantasy @PUT @Path("league/{id}") @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) public League putLeague(@PathParam("id") long id, League league) { League tempLeague = em.find(League.class, id); if (tempLeague != null...
0
28e39ade65b9ac5c97853465186a4c4f
0e4b751f196227256c51c480a82bc52f
Bivariate Statistics and Visualizations for Continuous/Categorical Features.
for cat_var in categorical_vars: explore_univariate_categorical(train, cat_var) print('_________________________________________________________________') for quant in quant_vars: p, descriptive_stats = explore_univariate_quant(train, quant) plt.show(p) print(descriptive_...
0
90eccd653938ae6b2545f474563dabe3
af50c6542aaec234dc33d41601c16d3e
飞船与外星人碰撞后的动作
collisions = pygame.sprite.groupcollide(bullets, aliens, True, True) if len(aliens) == 0: bullets.empty() creat_fleet(ai_settings, screen, ship, aliens)
0
8f83e8151e4de6a016f335d93532a45a
b63ad8d2f44e532115bd0dafbcfe80a6
Removes all `HVW Class` from the database.
public class ClassDataSource implements DataSourceInterface.ClassDataSourceInterface{ @Override public void deleteclasses() { resolver.delete(ForgettingCurveContract.ClassEntry.CONTENT_URI,null,null); resolver.delete(ForgettingCurveContract.TermsEntry.CONTENT_URI,null,null); }
1
cf32ea80b78abefc72bc13e9ad32fb7e
af327cee1632be38fc5c85d43cd5f03f
Retrieves the Intent data which to be uninstalled.
@Keep class IntentUtils private constructor() @JvmStatic fun getUninstallAppIntent(packageName: String): Intent { val intent = Intent(Intent.ACTION_DELETE) intent.data = Uri.parse("package:$packageName") return intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) }
1
4335539875770e668e7a4ef8663179bb
19730373323a2f781aee8db7040e6c61
You should not need to ever call this function as it is called as part of the Rig.add_component functionality for you. This will make a connection between the root guide object and the components meta node allowing the relationship to be traced between them.
class TBaseComponent(object): def mapToGuideLocs(self, rigNode, guideNode): if type(rigNode) == 'str' or type(rigNode) == 'unicode': rigNode, guideNode = pm.PyNode(rigNode), pm.PyNode(guideNode) self.guideToRigMapping[guideNode] = rigNode
1
9a3164019f8c89a25d74ecd9c66dea54
084b514c895f67e3cbacf5f32d48528c
Latticize the given graph by swapping edges.
G = copy.deepcopy(G0) n = 0 swapcount = 0 a = dict(G.degree()) keys, degrees = zip(*a.items()) cdf = nx.utils.cumulative_distribution(degrees) while swapcount < nswap: (ui, xi) = nx.utils.discrete_sequence(2, cdistribution=cdf) if ui == xi: continue ...
1
6f749ae8e3b82e3cea924372e988809e
e93c6a1d1d19e6b8ff923b9ba2909d56
1. Add light mode to the body.
if(mode === 'light') { document.body.classList.add(classLight); checkToggle.checked = true; } else if(mode === 'dark') { document.body.classList.remove(classLight); checkToggle.checked = false; } }
1
949e53f7823c128907c9c05e3913581b
29de0bbfcccbb05609aefb67d5ac45ff
Returns the alphabet size of the Markov process.
class FontClosModel: def N(self) -> int: return self.params.N
0
8b8ae9885edb841ff3c2f966e7302f48
a6537044083d6dbc898abd93bee393f6
物件放置器,將物件放置在滑鼠點擊處距離最近的gird座標點
{ foreach (Transform item in transf) { int x = Mathf.RoundToInt(item.position.x); int y = Mathf.RoundToInt(item.position.y); grid[x, y] = item; } }
0
b1ba57c172dc325fbaa7964d696fbc2f
b6137667d30b0d812fc1cd4c1de73382
Pretty print a datetime literal. Returns null if it is not a date time
let type = typeof (temp); let instance = temp instanceof Date; if (type == "string") { let objDate = this.#GetDtm(temp); return objDate == null ? null : objDate[1] + this.#lineSlash + objDate[2] + this.#lineSlash + objDate[3] + " " + objDate[4] + this.#Semicolon + objDate...
1
a32178b832b24dfe4bd862ddc0665f18
d8b0e673ac6fe838206b59bc63916350
returns true if the state of synchronization allows the acquire on behalf of the thread that is at the head of the queue.
public abstract class AbstractQueuedSynchronizer extends AbstractOwnableSynchronizer implements java.io.Serializable public final boolean hasContended() { return head != null; }
0
e50e3e6ce901f95376d31d6df87a4adf
721de7577ace7fa35e32e3889b2d88ab
Makes an API request and returns condition details object. See the docs: https://developer.infermedica.com/docs/v3/medical-concepts#conditions.
callback?: (categorizedConditionEnums: CategorizedConditionEnums) => void, ): Promise<CategorizedConditionEnums> { return ResourceLoader.fetchResources<CategorizedConditionEnums>(ResourcePaths.ENUMS_CONDITIONS, callback); }
1
dde212c50f4d125a5eeb63c771370220
005a119f3e144f9383956469208ff166
tableau destiné à stocker les produits du panier
export class ShoppingCart constructor() { this._products = []; }
1
f44d5f722de9dd0dca148882f0f37248
8ff103d9e48115d797a799f303291849
Register class as string injection token and singleton and load all import dependencies
if (Class["__inject__"]) { var result = Object.keys(Class["__inject__"]) .map((propertyName: string) => { var temp: InjectionPoint = { propertyName: "", constructor: null }; temp.propertyName = propertyName; temp.constructor = Class["__inject__"][p...
0
80c9b483d7e99ef161f0058efd4985fd
2cc40a5d8ccfefaaca6342bf087553d6
Returns an array with the information about the deployed datasources.
class XMLAConnection implements IOLAPConnection public function getDataSourceInfo() { return $this->dataSourceInfo; }
0
072405265fafec86cca2a40788a5efbe
a1171d94fba3637e9c4182515b7bddb5
在查找出某个列的同时,设置它的查询的别名。 如果没有找到,则会抛出异常。
DataBaseExcute.FieldInfo info = this.columnsMap.get(fieldName); if (info == null) { return false; } else { info.aliaName = aliasName; this.columnsMap.put(fieldName, info); return true; } }
0
1415f749a1628f4231df19094ba67ed4
3f3dc21c78e958e7fdbfc358c8383164
Click on Service Component.
public class GetServiceHistoryScreen extends AndroidBaseScreen public boolean tapOnServiceOrderNo() throws Exception { return driver.click(getServiceHistory.get("serviceOrderNo")); }
0
f272b1b6bd2b965981f2525bfa8d3b85
899656a030b3ab97d90f6a0cdaf74095
Garbage function, generates fake temperature data, for use in designing the GUI ONLY
{ Temperature = new int[4, 7]; Random Temp = new Random(); for (int i = 0; i < Temperature.GetLength(0); i++) { for (int j = 0; j <Temperature.GetLength(1); j++) { Temperature[i, j] = Temp.Next(-5, 10); } } ...
1
adc80d531a8f150e8cce31bcb48b428a
40f431493934deff9435432e5b901af8
Get all runfolders
info_dir = self._settings.info_dir if not os.path.isdir(info_dir): return [] paths = [os.path.join(info_dir, x) for x in os.listdir(info_dir)] return filter(lambda d: 'timestamp' in d, [RunInfo(os.path.join(p, 'info')).get_as_dict() for p in paths if os.path.isdir(p) and not os.path.is...
1
005e3d3d9b642546d759a688e243212c
109fb61662079a5a335a24e3ea635ab6
Increases total additions by one.
public class GridCachePartitionExchangeManager<K, V> extends GridCacheSharedManagerAdapter<K, V> private static class WarningsGroup private void incTotal() { warningsTotal++; }
1
dc9193a7bffc4441ea1f9537e6e2fa81
50f073d543a488a2eff50e238cad1610
Updated plot limits for the plasma current viewgraph
public class GraphActivity extends Fragment implements HeaterMeter.Listener, OnTouchListener private void redrawPlot() { mPlot.setDomainBoundaries(mPZT.domainWindow.min, mPZT.domainWindow.max, BoundaryMode.FIXED); mPlot.redraw(); }
1
033ac928731b67a8e89d91443afadc03
1f68af15a587e15ce1d15d24efcb960c
Adds an argument + description for a serve-time argument
$this ->setDescription('Fait quelque chose - mais on sait pas quoi encore.') ->setHelp('Cette command fera quelque chose...') ->addArgument('minDuration', InputArgument::REQUIRED, 'Durée min de la recette') ; }
1
8f877aec6ccab6080c03b9f0455e3227
c1a305531f594b6d3dd83c732d9f3c82
Gets the "chromakey" attribute
const std::string& CLImage::getKey() const { return this->mKey; }
0
c21963defcbdc9f8c5bd74377b3460da
aefd35bbbaaa8329a56e850579eb0b4d
Constructor. Loads schema into static arrays
ItemSchema::ItemSchema( void ) : is_loaded_( false ), item_definitions_(), attribute_definitions_(), quality_names_(), origin_names_(), kill_eater_types_(), kill_eater_ranks_(), fallback_( nullptr ) { }
0
29f1036f04e6269e83fef3d991c9700d
e3d2a2b59997f682ec2dd8fc806474be
Returns a sorted list of bone indices that should be exported for the given bone filter mode and bone groups. Note that the ancestors of bones within the bone groups will also be present in the returned list.
{ float wRoot; float[] wBones = new float[_bones.Length]; _ComputeBoneWeights(_bones, null, out wRoot, wBones); return wBones; }
0
cf9d73986650e6aa90b492eecfc98c77
6f7e2bc6fec0627c001e32366a20516d
Бараа материалын жагсаалт дуудах
def materials_list(request): materials = Material.objects.all() paginator = Paginator(materials, 2) page_number = request.GET.get("page", 1) page = paginator.get_page(page_number) is_paginated = page.has_other_pages() if page.has_previous(): prev_url = "?page={}".format(page.previous_pag...
1
6f3b43b3affd1c155bc469cb63faffe7
ca9dd67fdeaa8b715b1c86540cc0002b
设置回复的头部数据
if(bean.comment == null)return; myHolder.ll_one_img_headline.setVisibility(View.GONE); myHolder.ll_more_img_headline.setVisibility(View.GONE); myHolder.ll_headline_img_container.setVisibility(View.GONE); String comments = ""; if(!TextUtils.isEmpty(bean.comment.reply_count...
1
7615a9e85a6facaf877bf290055234d5
812def8673a8d1dcaf1e62face83de91
# Adjust doubling time for temperature
sofa_Taitt <- function(utc,tai,Par){ if(Par$TtType=='BIPM'){ dt <- time_BipmCorr((utc[,1]-DJM0)+utc[,2],BIPM=Par$BIPM)/DAYSEC }else{ dt <- 0 } dtat <- TTMTAI/DAYSEC cbind(tai[,1],tai[,2] + dtat+dt) }
0
2022e354aa6a0919f0fb1d9e947b9c92
8c49d6d66e43a310a00dbd38c1566d37
Invoke our handler with our current thread state; we use this state to try to roll back the tests and verify that the expected registers are restored.
memory::init(); interrupt::init(); drivers::init(dtb_pa); fs::init(); { let mut processor = PROCESSOR.lock(); processor.add_thread(create_user_process("never_return")); } extern "C" { fn __restore(context: usize); } let context = PROCESSOR.lock().prepare_next_...
0
58043a9216142450b81bc9979d6de6bf
4bd7048d176789492bdb9181da6687f6
Returns a set amount of letters at the start of a string
returnString = "" for char in 0..charAmount - 1 returnString << string[ char ] end returnString end
0
efa22c8b45c42a2aa908647023b5c541
b5edba2390b6fc75e560f50752ccc875
Registers a custom name for the world to be identified as on the client. Not required, if not set it will default to the unquie id of the world.
{ DimensionManager.registerDimension(dimId, dimId); FMLCommonHandler.instance().getMinecraftServerInstance().worldServerForDimension(dimId); Lumberjack.log("World registered for " + WorldProvider.getProviderForDimension(dimId).getDimensionName()); }
0
ee8e8e0465e0ed1230a93ecf19749197
df65c1c0d7787b5bf0327307481bad31
Получение типа данных из типа данных таблицы Access
{ switch (d) { case DataType.Real: return "Действ"; case DataType.Integer: return "Целое"; case DataType.Boolean: return "Логич"; case DataType.String: ...
0
37165e2d0cb8737a985061801914dd54
a4bb78438c0387423776f66e54e6ccdf
コマンドウィンドウが開いているときのイベントハンドラ
@party_command_window = Window_PartyCommand.new @party_command_window.viewport = @info_viewport @party_command_window.set_handler(:fight, method(:command_fight)) @party_command_window.set_handler(:escape, method(:command_escape)) @party_command_window.unselect end
1
171e343f47ea223d4686dd56ce515eea
d3d8879727d113daa38bd109eecdd1c7
Right half of x, R(x)
public class SDES private boolean[] rh (boolean[] inp) { return Arrays.copyOfRange(inp, ((inp.length)/2), inp.length-1); }
1
90fdc4410cb82da736f78f6ff732b5b8
c5e51e2a4c567f905ca7d8e46ef1c069
#returns the distance from the nearest Axiom SNP to the gene #we can then use this as a benchmark to determine how far significant selection signals (from pcadapt) are from the gene of interest # browser()
{ node.neighbors <- setdiff(neighborhood(ppi.network, 1, node, "out")[[1]], V(ppi.network)[node]) if (length(node.neighbors) < 2) return(0) return(sum(abs(gene.ws[node.neighbors[order(abs(gene.ws[node.neighbors]), decreasing=TRUE)[1:2]]]), abs(gene.ws[...
0
7ef117eded07f97e803467745bc751d7
d54b7f70c4d4182f06ed2d4be5c04be3
Returns the current location of the end effector, accounting for the gear ratios, and in 3D.
class CartPosQuatController(TrackingController): def getCurrentPos(self, robot): current_c_pos = robot.get_end_effector_pos() return np.hstack((current_c_pos, robot.current_c_quat))
0
1382c6e0df7bfbca74ea24a263e947d8
6e06fc1bdebd50ec6ca4c8d1b7fe430c
设置骆驼全名法转换标识
@Configuration public class MyBatisConfig @Bean public ConfigurationCustomizer configurationCustomizer(){ return new ConfigurationCustomizer() { @Override public void customize(org.apache.ibatis.session.Configuration configuration) { configuration.setMapUnderscore...
1
02d8c7dc9f27351e21e8c937ec7af54b
6b12f9d2fc9c1aa075ced7be6ec6998e
Overriding the default Xamarin view presenter to present fragments
this.isUserInputEnabled = false this.offscreenPageLimit = 3 adapter = object : FragmentStateAdapter(fragment) { override fun createFragment(position: Int): Fragment { return when (position) { 0 -> { HomeFragment() } 1 ->...
0
792c3365469cdaa42cbbe9dedd9fb856
dadf2a14a41726841ca6be41383e68b4
已读信息的列表分页情况(点对点)
$read_data = $this->_msg_read->list_by_conds($ep_id, $uid); if ($read_data) { $re_array = array_column( $read_data, 'logid' ); } else $re_array = array(); $real_count = $this->_get_real_count($ep_id, $re_array); $perpage = 12; if( $real_count > 0 ) { $pagerOptions = array( 'total_items' => $real_...
1
0e3b5ba04be4ba7b7d10e5cc2e5bdede
bfa2059a75ea029d60270b445daed436
Read command: Get service provider name from SIM
{ u16 i = 0; u8 index = 0; fSendCmd = true; uart2_putROMString((rom char*)"AT+GSN\r\n"); while(!fReceive) DelayMs(50); while((recvBuffer[index]<0x30)||(recvBuffer[index]>0x39)) index ++; memcpy(imei,(const void *)&recvBuffer[index],15); for(i = 0;i<simResCnt;i++) recvBuffer[i] = 0x00; simResCnt = 0; ...
0
9c886c37f733d7c5a09d1266976c7080
c6b2b33f1988dc900a83bc0d8694f49a
при подключение к пайп потоку смотрим если пишет в память, то все что записалось в память отправляем в переданный поток и заменяем поток памяти на переданный
try { await myStream.WriteAsync( Buffer , 0 , BytePeek ); await myStream.FlushAsync(); } catch( System.Exception ) { CmdSystem.AddLog("Socket error"); } }
0
91be90f8688dfb75b8476a9c398b3930
9214f0d72fb912d72dfd2a6c48b5b9c0
Get the current log version, supporting a test override.
namespace Org.Apache.Hadoop.Hdfs.Server.Namenode public abstract class EditLogInputStream : IDisposable public abstract int GetVersion(bool verifyVersion);
1
2ea4981e3855b08ad0ac37a1557655a6
3eabe08233fa12cf947bf6af686cea75
Рестарт всего при нажатии на Retry.
namespace URL public partial class MainGame : Form private void _lblRetry_Click(object sender, EventArgs e) { Application.Restart(); }
1
016304bb32bb013e6803e53b3b04c0b3
a633e1b49cd403528b12c1d9c47fef12
@brief 告诉所有在线操作端,这个共享端的状态发生了改变,此函数只在DBMgr模块中 更新会员状态时才调用,其他地方不应该调用
void LiveChatManManager::SetUserOnlineStatus(LCUserItem* userItem, USER_STATUS_TYPE statusType) { if (userItem->SetUserOnlineStatus(statusType)) { m_listener->OnChangeOnlineStatus(userItem); } }
1
0afd6cc460ea375e792d74a672bc2e62
0e64ac925a60a79e51b5816dfbbbdecc
会社CDを取得します。
public class SearchJoukenItem public String getControlCD(){return controlCD;}
0
491b590047b4e0619f92f37b9293c3eb
a1d0e417614c1706a1a763e5149b7713
method untuk validasi tanggal sesuai tiap bulannya dan pada tahun kabisat
if (! (1582<= *(in_date + 2) ) ) return false; if (! (1<= *(in_date + 1) && *(in_date + 1)<=12) ) return false; if (! (1<= *(in_date) && *(in_date)<=31) ) return false; if ( (*(in_date)==31) && (*(in_date + 1)==2 || *(in_date + 1)==4 || *(in_date + 1)==6 || *(in_date + 1)==9 || ...
1
7f16f5a84cb3818571f5fe7f01722a05
911e271cd820c8e08616b2a7c625a761
通过景区名称查看景区导游星级
String sql="select t_bookorder.bookOrderID,t_scenicspotinfo.scenicName,t_visitor.`name` as visitName,t_bookorder.contact," +"t_bookorder.guideSex,t_bookorder.visitNum,t_bookorder.orderState, t_bookorder.`language`,t_bookorder.visitTime,t_guideinfo.`name`,t_guideinfo.phone," +"t_bookorder.fullPrice,t_...
1
77a011218c11ebbf3d1150aca7e2e761
38d07fb411708e80f864e06414704980
Getter for ItemOptionValues. List of item option values associated with this item variation. Listed in the same order as the item options of the parent item.
class CatalogQueryItemVariationsForItemOptionValues implements \JsonSerializable public function setItemOptionValueIds(?array $itemOptionValueIds): void { $this->itemOptionValueIds = $itemOptionValueIds; }
0
07f597f99e8d8da5ded1247aa8cb1202
37a8da6dd2f9276d9434e706797c339f
Changes the cardinality of a relationship (DD08V-CARD).
public class OKCoCommiter public DtoResult commitMaxCardinalities(DtoCommitMaxCard dto) { DtoResult dtoResult = new DtoResult(); try { String separatorValues = "%&&%"; String[] arrayValues = dto.ListInstanceDifSameIds.split(separatorValues); for (String val : arrayValues) { if(val.contains("x...
0
869961b1306e6f91a20af66278897f73
df68d66d33c78ba26539f3b5dcd64cf1
=========================================================================== Sets message ack status for specified message type ===========================================================================
{ this.m_ids.Set(aType, aValue); if (this.Initialized) { this.m_pendingMessages.UpdateId(aType, aValue); } }
0
1e31545f606016ef282e17a27880660c
671e0069eedc91f32c0e88eb0d95ad16
Setea los colores de los botones de fecha.
public class Multijugador extends JDialog{ private void colorcitoBoton() { jugador2.setBackground(colorBoton); ia.setBackground(colorBoton); volver.setBackground(colorBoton); }
0
1d415ab03dcf6f0a197985c314b3abd5
689436ebba5a5b47c6f57dbbba1d99ab
Set the combo for players shooting signature.
let combo = new Combo(); combo.setCombo(comboNum); combo.horizontalCenter = 300; combo.verticalCenter = 280; this.addChild(combo); combo.show(); }
0
24444b4332953d20a7be42fc91d663f7
0781474beb4faf969205e7a72409bccb
Listener registration method.
class UserRegisteredListener implements ListenerInterface public function listen(): array { return [ UserRegistered::class, ]; }
1
942c9eafc32b96f76e16380f97f0ed53
bdbd87db5db8694b6d017805742b0218
Retrieves a note given a base and modifier.
const rootIndex = DATA.notesSharp.indexOf(rootName) !== -1 ? DATA.notesSharp.indexOf(rootName) : DATA.notesFlat.indexOf(rootName) if (rootIndex === -1) { throw new Error('Unknown note: ' + rootName) } const ecartIndex = DATA.ecarts.indexOf(relDiff) if (ecartIndex === -1) { throw new ...
1
e1c8b52f4126447b4791c54c143c72ad
52f018e87b4067f12aa0c47068e1c627
Length of time in seconds the subject can be confirmed See SAML core specification 2.4.1.2 NotOnOrAfter
namespace DotNetXri.Client.Saml public class Conditions public void setNotAfter(DateTime? oVal) { moNotAfter = oVal; }
0
b6ee8d049d8457458f53ab4a7dc90429
17d7f3bff482af03c218a15006c34d2e
向集合中添加元素,返回以代表成功添加,返回0表示这个元素已经存在集合中
export default class Set<T> add(element: any) { if (!this.has(element)) { this.items[element] = element; return true; } return false; }
0
1107f7ddd976bec217e9a275205b69bd
f48ef808463897f2c1330148b0a8eab2
Method to add a new member to group, adds document for new member and updates document for the group
Document newdoc = groupView.getDocumentByKey(key); if(newdoc == null){ newdoc = namesDb.createDocument(); CreateNamesGroupDoc(newdoc,key,key_show,groupType); newdoc.replaceItemValue("Members", Member); }else{ Item item = newdoc.getFirstItem("Members"); item.appendToTextList(Member); } newdoc.sa...
1
605a4e69972c380234400e3aa9c6719e
bc28b82b4b56143867fb619070553002
Uses the `post_processor` to decode the model output.
class BasicRegressor(Model): def decode(self, output_dict: Dict[str, torch.Tensor]) -> Dict[str, torch.Tensor]: predictions = output_dict["logits"] if predictions.dim() == 2: predictions_list = [predictions[i] for i in range(predictions.shape[0])] else: predictions_list =...
0
0662473590668e2b1a3f81d06055befb
d20c1820343648540309f56d6f1c245c
Gets the maximum number of alert instances to include in a report.
public class DescribeAlarmsRequest extends AmazonWebServiceRequest implements Serializable public Integer getMaxRecords() { return maxRecords; }
1
a3b614a5c442224e88b9435cf3f5fba2
bab4755e861da67c08dd67920a6da16a
Uninitialize power module
{ int ret; ret = __bma_reg_write_POWER(bma, 0); if (ret >= 0) ret = __bma_clear_int2(bma, 1, 0, 0, 0, 0); if (ret >= 0) ret = schedule_delayed_work(&bma->input_worker, msecs_to_jiffies(bma->evdev_delay_ms)); return ret < 0 ? ret : 0; }
0
74717920057a6004a4e1c07e75d4a7a6
21edbf7c190bfb665e5219a25670c2e8
Returns text for place column in results
class SearchInfo: def place_names(self): return self._get_text_for_category(self._categories.PLACE_NAME)
1
90751b932b16dff22c050b7ec52985c5
de33fff57ec3be167a6703d77b5b2383
Set the enables/Disables UPnP support.
class FoscamCamera(object): def set_upnp_config(self, isenable, callback=None): params = {'isEnable': isenable} return self.execute_command('setUPnPConfig', params, callback=callback)
1
c0a95a0905cb935bbf756f207e1d82c5
ad9fa0062fe944e7328f82e0751deb25
Mocks the redis storage object for unit tests.
class MockRedis: def __init__(self, *, loop=None, data=None): self.loop = loop or asyncio.get_event_loop() self.data = {} if data is None else data logger.info('initialising MockRedis, data id: %s', None if data is None else id(data))
1
094ccb7215ae494697068b65fa0f759a
2b802f41373242b1506f0efba9586334
Создаёт тапл с информацией, для последующей загрузки текстуры.
class Img_Block(QFrame): def Pack_Info(self): info = {} info['filename'] = self.WB.Img.FileName info['rotation'] = self.WB.Img.Angle info['Flip_h'] = self.WB.Img.Flip_H info['Flip_v'] = self.WB.Img.Flip_V info['crop'] = [] info['markers'] = [] crops = [i f...
0
618edce48c7970ae338978f84b801c19
a1c93c8dbe952383ccb0a8afe393a3e2
获取字典数据项表单数据
namespace Web.Areas.SystemManage.Controllers public class ItemsDataController : ControllerBase [HttpGet] [HandlerAjaxOnly] public ActionResult GetFormJson(string KeyValue) { var data = itemsDetailBLL.GetForm(KeyValue); return Content(data.ToJson()); }
1
d5b453896794daf8efb14ae1b405caad
a45df08139a07062d9b9a4a878f9513f
利用广度优先搜索,构建AC自动机的失配指针
root = self.root queue = deque() for char in root.childs: queue.append(root.childs[char]) def get_fail_end(node): if node.end is not None: return node while node and node.fail: if node.fail.end is not None: ...
1
4d14bded3073b7127f55a4e6a9b4acb5
f7f29d5b4e7c6b7cf087fc8ff56001ac
Создаем окно для добавления департамента
namespace FirmDZ11_PetrovGN_ public partial class MainWindow : Window private void BtnAddDepartment_Click(object sender, RoutedEventArgs e) { pageAddDepartment = new PageAddDepartment(); Frame1.Content = pageAddDepartment; }
1
4a914a90f764144fe828c1abe4479e9c
90d9639d22edf1584cc9b1fccb79e6f3
利用ITween实现UI移动效果
public static class MailboxTool public static IEnumerator MoveUIs(List<Transform> tages, List<Vector3> tagePoints, Action endAction, float speed) { while (Vector3.Distance(tages[0].localPosition, tagePoints[0]) > 3f) { for (int i = 0; i < tages.Count; i++) { t...
0
4e520d86fde7cfb96b593dbf2ff1354d
c5cac946ff7deb31facb8f5f3fab0cd5
根據給出的相對地址獲取網站絕對地址
namespace Cliver.BotWeb public partial class Spider public static string GetAbsoluteUrl(string link, string parent_url) { try { if (link == null) return null; link = HttpUtility.HtmlDecode(link); Uri u = new Uri(pare...
1
1cfd2e62e903af4b70fc3eb2c900c5c5
0a07981cc42527f9b5733c3bcd518ebc
Element layout type.
class surveypromform_textarea_plain extends \MoodleQuickForm_textarea public function getElementTemplateType() { return 'default'; }
1
5c1445d3edf368e3066c7440a85c6ea6
400328e90e364dc4ad967322d50c88c3
Toote lisamine koos attribuutidega
self.numero = numero self.nimi = nimi self.tyyppi =tyyppi self.sijainti = sijainti
1
2e091dfbaa486ab6af67ab03767cf9f9
5df86a4b1fccba6d3813620dd369c6c8
Free a bucket to the bucket layer.
static void RemoveBucket(Context_st *st, Bucket_t *b ) { LINK_REMOVE( &(b->l)); st->entries--; Heap$Free( st->h, b ); }
1
314ed5e14612add84d4d625bee9450d4
e5553d9aae8d214ce5ad29ad8124fda1
Ger poäng på positionen. En hög siffra är bra för CurrentPlayer.
namespace PaddleGame public class GameSet public int GetScore(PaddlePlayer pPlayer) { var game = Tournament.Instance.GetGame(GameID); if (game == null) throw new ArgumentException("Game wasn't found at this moment"); var pos = game.FindPlayer(pPlayer); return ...
1
2160c3157a7629461a85943dc96fbac0
15ad55d2bb228fd7b5c51e0d4094bea4
Registers an event listener for deleting an embedded asset's cached copy.
{ if (File.Exists(targetFile)) { FileSystemWatcher fileWatcher = new FileSystemWatcher(Path.GetDirectoryName(targetFile), Path.GetFileName(targetFile)); fileWatcher.IncludeSubdirectories = false; fileWatcher.EnableRaisingEvents = true; ...
1
e24e52d000b070b98c3e1bdd9639cbf1
394b7416afe9709e7129c58b30057670
根据类型随机查询num条音频
{ $mongo = $this->getMondongo(); $recommandFix_rep = $mongo->getRepository("RecommandFix"); $recommandFixs = $recommandFix_rep->find(array('query'=>array('type'=>$type),'limit'=>$count,'sort'=>array('_id'=>-1))); $arr_vod=array(); foreach($recommandFixs as $recommandFix){ ...
0
3ce6267b976c23600364fcd2235329bf
8e89d94ef3bd27a3e8628a09f2513557
余玄相似度,如果夹角为90则相似度为0
public class JavaUtils public static double sim(String str1, String str2) { int ld = ld(str1, str2); return 1 - (double) ld / Math.max(str1.length(), str2.length()); }
0
e097279ca38a93f63446510413db659a
6c57ea5147419821a1d5d18c226a73c7
# Compare Age terms from model with and without study
sim.study=function(n=100,N.sim=100,ratio=2,p.true=5,rho=0.25,cor.type=1,snr=10,method=1){ mydata=gen.data(n=n,ratio=ratio,p.true=p.true,rho=rho,snr=snr,cor.type=cor.type) model.compare(n=n,ratio=ratio,rho=rho,cor.type=cor.type,snr=snr,N.sim=N.sim, method=method) }
0