query_id
string
corpus_id
string
query
string
code
string
label
int64
3cb347a048ac462a974369af6ae756d2
21dc10f615ab93f980af79b0b81abc54
<p>mcnSid を取得します。
public class Sml010Form extends AbstractSmlForm public int getSml010usrSid() { return sml010usrSid__; }
0
5b606589b77a03d03965715b2e5905f3
c6794f791419c68aff95b0a0e5dac112
return true is the object is in saving state
bool ContainerObject::getSaveUndo() { return mSaveUndoStack; }
0
4305e3911ebb99f5031fb0305a433756
74f56a77d6149b949dc643fa48e9ed96
根据关键字查找资源名称或描述包含该关键字的资源。
public class ResourceDao public ArrayList<ResourceEntity> getResource_byNameLike(String keyword) throws SQLException { ArrayList<ResourceEntity> resources = new ArrayList<ResourceEntity>(); String sql = "select * from tb_resource where lower(title) like ? or lower(re_detail) like ?"; keyword = "...
1
02b6de59d4e6739a3049e12ddcca533a
f31726f30952e4f64bc5fb459e28bf3a
以select开头的任务是sql语句
class dbClass{ private function is_select($query){ $t_sql = strtolower(ltrim($query)); if(strpos($t_sql,'select')===0){ return true; }else{ return false; } }
1
b7406c6abc283e22aba0051c43a0d6a1
c6962047664de1e52682b77428a570c0
Decide which buttons are being pressed based on a simple collision, then change the state of the button
if (event.x < 80 && event.y < 80){ buttonPressed = 0; backButtonState = PRESSED; } else if (event.y > 400){ buttonPressed = 1; newMessageButtonState = PRESSED; } else if (event.y < 80 && event.x > 720){ buttonPressed = 2; upScrollButtonState = PRESSED; } else if (event.y > 320 && event.x > 720){ ...
1
50e202aceac732d6615fea9134fb4eba
75224019dc0bcb0881b0f82abd7e28a3
General frame to generate a graphene sheet
gframe = [[] for row in range(l*h)] for i in range(0,l): for j in range(0,h): seq = i*h+j if stype == 1: if i%2 == 0: gframe[seq] = np.array([1.5*i+(j%2)/2.0, j*3**0.5/2, 0])*bondlen else: gframe[seq] = np.ar...
1
bd68c6bc2efccc2cd12a40b253fef767
404f62e57a2471e834c46a94b7a528cc
Returns a list containing the player's currently active upgrades
@IdValue @ListValue List<Integer> getUpgrades();
1
00f069098d0029284a01865ccf940420
dcb32ef7e466f18045789a2ad3322379
Send data to encrypt/decrypt to device.
int32_t nss_core_send_crypto(struct nss_ctx_instance *nss_ctx, void *buf, uint32_t buf_paddr, uint16_t len) { int16_t count, hlos_index, nss_index, size; struct h2n_descriptor *desc; struct hlos_h2n_desc_rings *h2n_desc_ring = &nss_ctx->h2n_desc_rings[NSS_IF_DATA_QUEUE]; struct h2n_desc_if_instance *desc_if = &h2n_...
1
05e87838295e0ab0a82640311d761bd9
9ae53d8d34b0f48514a7f1fac60c8de9
=========================================================================== DESCRIPTION This function initializes the header and sends the message to the message router. DEPENDENCIES None. RETURN VALUE None. SIDE EFFECTS None. ===========================================================================
static void NetMLDP_TxMsgDone(NET_IF_NBR if_nbr, NET_IPv6_ADDR *p_addr_mcast_dest, RTOS_ERR *p_err) { NET_IPv6_ADDR addr_unspecified; NET_IPv6_ADDR addr_mcast_all_routers; NET_IPv6_ADDR *p_addr_src; NET_IPv6_EXT_HDR hop_hdr; NET_IPv6...
1
7a0009b85aa1ee98c39a3e7bb262137d
f8d5820c4e533620200acde8344f32a0
Configurationが初期化されている状態でInitializeメソッドを実行したとき、例外が発生する
public void testInitializedInvalidParam() throws Exception { setRequiredFields(); FacesContextMock.EXPECTED_MESSAGE = new FacesMessage(FacesMessage.SEVERITY_ERROR, FacesMessage.SEVERITY_ERROR .toString(), createExpectedMessageString(Messages .g...
1
96cf111a3f9b1e2392c7454459a66f29
099970fb4c07a37c6158cd5756df2a3b
Create mail data provider before every test case.
{ return array( array( 'tom.'.Text::random().'@codelights.com', array(), ), array( $this->get_person_email(), array( 'first_name' => 'John', 'last_name' => 'Smith', 'company' => 'JOHN INC', 'phone' => '1234567890', 'site' => 'http://johnsmith.com', 'meta' => arr...
1
5ec2e823d1473deccceae0580db78fc0
e570742628d4d3eda69417e264e93106
Updates the other people's scoreboard so that everyone sees the new player's rank.
public class CreateServer extends Thread private void updateOtherUsers(int thisIndex, String name, int score) { for(int idu = 0; idu < userList.size(); ++idu) { if(idu != thisIndex) { sendUserInfoToClients("USER_DATA_INCOMING|" + name + "|" + score, idu); ...
1
ac204c8902ae905b6b963e5ba73f09bc
353bd6a9327bde4296d7eb198689f8f4
通过用户id查询商户欠账金额
throws Throwable { BigDecimal amount = new BigDecimal(0); try (PreparedStatement pstmt = connection.prepareStatement("SELECT F06 FROM S61.T6101 WHERE T6101.F02 = ? AND T6101.F03 = ? LIMIT 1")) { pstmt.setInt(1, userId); pstmt.setString(2, T6101_F03...
1
30604182322707e1e66a3f010e9e404d
4647608fed0551a3b68c1e9063f7dc7f
Return a json string from a File
function getJsonStringFromFile($filename){ $json_string = file_get_contents($filename); return $json_string; }
1
2008a7076bbc9dec1c09282fffc3364c
584c6a275aa312a29cc4b89eda2e60c7
첫 화면에 띄울 기본 추천 리스트 검색 메소드
String tag_string_req = "req_RecommendUserList"; pDialog.setMessage("Getting List ..."); showDialog(); StringRequest strReq = new StringRequest(Request.Method.POST, AppConfig.URL_GETHIGH, new Response.Listener<String>() { @Override public void onResponse(String re...
1
fbf44ce7581ba155ca7f98f0ec8d60f8
31434c04345050ddcd660336f727afc8
Method to get the current unit test number.
public class TestPendingInputRequests implements TestCollection, EventHandler public int getTestNumber() { return 14; }
1
387a477701310f1cde30592e39567274
1274e0945575d414572fd0f0fe1fd7dc
Obtiene el cuit solicitante
class Empresacuenta extends \Empresacuenta implements \Doctrine\ORM\Proxy\Proxy public function getCuit() { $this->__initializer__ && $this->__initializer__->__invoke($this, 'getCuit', []); return parent::getCuit(); }
1
e544d78817879e8d72124961217567e2
27559c77b5b6c0c06e091ba5eb25cacb
Specifies the assumptions to use when calculating time in traffic. ## Arguments * `traffic_model` ‧ Which traffic model the directions service should use when calculating the route and duration in traffic - _best guess_, _optimistic_, or _pessimistic_? ## Description Specifies the assumptions to use when calculatin...
class AlipayEbppBillAddModel implements ModelInterface, ArrayAccess, \JsonSerializable public function setTrafficLocation($trafficLocation) { $this->container['trafficLocation'] = $trafficLocation; return $this; }
0
cc3142d1bf9b625f2030024172faf894
eaef78f927fb176819298d25ba0bffa5
初始化象棋配置
mStrokePaint.setColor(0x88000000); mStrokePaint.setAntiAlias(true); mStrokePaint.setDither(true); mStrokePaint.setStyle(Paint.Style.STROKE); mFillPaint.setColor(Color.BLACK); mFillPaint.setAntiAlias(true); mFillPaint.setDither(true); mFillPaint.setStyle(Pa...
0
ba6a75c0b68c538978e7d3cc03962112
8074714945bef251dde4c8575e0e4949
|-----------------------------------------------------------------------| | DESCRIPCIÓN: Regresa al menú de listado de diagnósticos. | |-----------------------------------------------------------------------| | AUTOR: Ricardo Luna. | |-----------------------...
{ $objResponse = new xajaxResponse(); $sql = AutoCarga::factory("OdontogramaTratamientoIIISQL","classes","hc1","OdontogramaTratamientoIII"); $paciente = SessionGetVar("DatosRsponsable"); $odontograma_tr = $sql->ObtenerUltimoOdontogramaTR($paciente); $diagnosticos = $sql->ObtenerDiagnosticosIngresa...
0
24b9243ae67ed3cb2dcda86dbc04ade0
44cb84b0e999b8c841cac3e547296439
Deletes all jobs in DOcloud for the subscription.
class API(object): def clear_job_list(self, uid, token): payload = {'uid': uid, 'token': token, 'call': 'clear_job_list'} self._call_rpc(uid, payload)
1
fc3cff436f50ff299475e3f07a91486f
ffb8936eb539efb4b5e0dd683f69384a
Returns the effective numerical matrix rank. <p>The effective numerical rank is the number of non-negligible singular values. The threshold used to identify non-negligible terms is {@latex.inline $\\max(m, n) \\times \\mathrm{ulp}(S_1)$}, where {@latex.inline $\\mathrm{ulp}(S_1)$} is the least significant bit of the la...
class Linalg fun <T : Number> matrixRank(m: KtNDArray<T>): Int = callFunc(arrayOf("linalg", "matrix_rank"), args = arrayOf(m), kClass = Int::class)
1
f29412add92cb57cbbbf47ef357b2fd5
71c03f836c9a23ae5761664a4b8533c1
Called when the player wants to teleport to the western golem area
public class Halloween public void teleportToGhasts() { client.getPlayerTeleportHandler().teleport(3526, 3506, 0); }
0
d33ce9253afacb0219d301c4e0c695ab
7470b9716576a5d144023a77c6c11620
Just shoot a bullet towards the player
{ GameObject bulletclone = Instantiate(bullet, muzzle.position + player.transform.forward/2 + Vector3.up/2, muzzle.rotation); Rigidbody rigidbody = bulletclone.GetComponent<Rigidbody>(); rigidbody.AddForce(player.transform.forward * 5,ForceMode.VelocityChange); GetComponent<AudioSour...
0
50ff4fa2d2b54f39ce992d18ac00b4dd
f84fd07b589c49a356d09d1269f7ddc2
Method to calculate the current objective function value
public double getObjectiveValue();
1
a0e438a32468b8913954d6c2fca1ddd2
03f52210037ecf0119d356eed5e1cbfe
在主页显示本日影讯
class HomeController extends Controller public function index() { $url = config('medias.image-host'); $film_url = config('medias.film-host'); $filmCondition = ['publish' => 1, 'isHot' => 1]; $films = $this->film->where($filmCondition) ->orderBy('created_at', 'desc') ->get(); $cond = ['publish' =>...
1
ed95677bfe7d3ee6ac76d27a36a4b12c
9733d2923aa68af7f377aaba09594a63
Validates that drush is available on the shell
class EkinoDrupalBundle extends Bundle public function boot() { if (php_sapi_name() === 'cli' && !defined('EKINO_DRUSH_FROM')) { global $container; $container = $this->container; if (!defined('DRUSH_BASE_PATH')) { define('EKINO_DRUSH_FROM', 'symfony'); ...
0
00317050e27ad7f58e4474498ff1883a
5d79bf638cd26eea1ac3517e139ebbbc
Computes the natural logarithm of the given value. .. versionadded:: 3.4.0
value = args[-1] if len(args) > 1: base = args[0] else: base = 10. return math.log(value, base)
0
645c1d44881b45bcd317d28c7d336faa
b6f3d4004e5340f3562ae03fdf430b3a
执行leader任务
public class ZKOperator public void election() { LeaderLatch latch = new LeaderLatch(client, leadPath()); try { latch.start(); latch.await(); boolean hasInstance = hasInstance(); if(!hasInstance) { createInstanceEphemeral(); } ...
1
9597062aa68241c4f8b143b29ad1e650
fc55e45c1d15c54b430be456700ee766
Set's up the players panel. This is for all the players currently in the game.
JPanel panel = new JPanel(); panel.setLayout(new GridLayout(1, 1)); personComboBox = new JComboBox<String>(); for(Player p: Board.getInstance().getPlayers()) { personComboBox.addItem(p.getPlayerName()); } panel.add(personComboBox); return panel; }
1
26af2cf40c2d2a54050a35545783e687
d6806cf84a6d0a9984e5020e3767d9e3
Gets a facet by its short name
public class FacetSelection public TLFacet getFacet(String facetName) { return facetsByName.get( facetName ); }
1
a7553b19a068da428dd134168a519878
987fea595e3cc1d541d4f58387304382
Método que añade un jugador a la lista m_Players y aumenta el contador de jugadores
public class GameManagerc : MonoBehaviour public void AddPlayer(PlayerStatus aPlayer) { InGamePlayers.Add(aPlayer); PlayerWins.Add(aPlayer, 0); }
0
59452fc436a86675f8089293b42bcf52
d4401ad02a83f1f096c5b00f04a682d3
True, якщо стек повний
namespace _04_Stack class Program static bool IsEmpty() { return (marker == 0); }
0
d84096132b3ba3168b83bcb57760027f
a672b67ede5658bcbef632e4078a3c2c
Geeft het aantal hospitals terug
int Recreation::getNumOfStores() { return numOfStores; }
0
a78832f22b89245fc18f457f479fa2ff
91a714c77cc47fcba6494ae694b13337
This function forwards a command.
public class RequestDispatcher public void forward(CommandRequest request) throws Exception { command.execute(request); }
1
ca9d18c9807e0b380b83eed54b975fe0
a15dc074941d6e67b5c5f62b5e5634c0
LoggerToES 日志记录到 ES
client, err := elastic.NewClient( elastic.SetURL(esURL), elastic.SetBasicAuth(esUser, esPassword), elastic.SetHealthcheck(false), elastic.SetSniff(false), ) if err != nil { return nil, fmt.Errorf("connect to ES %q: %v", esURL, err) } hostName, err := os.Hostname() if err != nil { return nil, err } i...
1
2cffc0a3099226d7d35432ec1b8c8513
1340f8212aafc26ed782343093f20d5c
Internal method which turns off (hides) all of the line segments for the specified cell.
try: cells_to_hide = list(self.fitnesses[source_cell].keys()) for fitness_key in cells_to_hide: dest_cell = self.get_cell_by_real_index(fitness_key) dest_cell.hide_fitness_value() except KeyError: pass
0
8cb6adc1a2e04fbee8f67c48ac133b60
79daeb1952ed6432140e56f611611047
public 解雇工人
public class EmployeeActionImp implements EmployeeActionInf{ public String dimissionEmployeeInfo(String id,Employee[] es){ String msg = ""; return msg; }
1
94c2dcc37a4bc88370f667fabc260f34
b98346f7df50e53cdf9d945319d68a45
Tests removing a nonexistant edge from the Graph (tests for not crashing)
func TestIssue123UndirectedGraph(t *testing.T) { defer func() { if r := recover(); r != nil { t.Errorf("unexpected panic: %v", r) } }() g := NewUndirectedGraph(0, math.Inf(1)) n0 := Node(g.NewNodeID()) g.AddNode(n0) n1 := Node(g.NewNodeID()) g.AddNode(n1) g.RemoveNode(n0) n2 := Node(g.NewNodeID()) g.Ad...
0
b4ce084c1260a65680c2fee124b0ea15
bebcf36d0fdf28f5afb4c507c40c33c3
Sets your status as 'back' /slack back
class Callbacks public function setAway($data) { $this->core->utilities->aim_set_away($data['message_text']); }
0
7e146f691dfe15fea6fbc2fe7f5c533a
2902aefa2253d4ca419fd8f106ce0b62
Gibt den Titel des Artikels oder den Titel des Parent-Artikels zurueck, wenn es sich um eine Variante handelt.
class bds_imex_prodexport_tradebyte extends bds_imex_prodexport protected function _getShortDescriptionLine(oxArticle $oArticle) { if ($oArticle->isVariant()) { return trim($oArticle->getParentArticle()->oxarticles__oxshortdesc->value); } else { return trim($oArticle->oxarticles__oxshortdesc->value); ...
1
70621250497088c0d397670c57b3c1b5
3e0c28e178f1bf406a8f0e5e5a25b7e9
Lists all ObjectType entities.
class ObjectsCategoryController extends Controller public function index() { return view('admin.octell.objectcategory.list'); }
0
d1c70c67634937f6b7b2dbfb9e63a6e6
c4589eb5cef0fe3ea5001b7339982e44
Populate Classification admin frontend table via AJAX
check_ajax_referer( 'soliloquy-fc-term-refresh', 'nonce' ); if ( empty( $_POST['post_type'] ) ) { echo json_encode( array( 'error' => true ) ); die; } $taxonomies = array(); $instance = Soliloquy_Metaboxes::get_instance(); if ( count( $_POST['post_type'] ) > 1 ) { forea...
1
bfa4bc801c4ce86236c1c969effd8447
7026805125a1ab5cdde6f0d0a08f3f46
设置汇率(将input中的值循环放入本地存储)
const self = this; const moneyArr = this.data.money; const index = ~~e.detail.value const form = self.data.form; form.symbol = moneyArr[index].symbol self.setData({ form }) }
0
e89cd2d0083e0a8eac6dd154d2d21b17
52fda0c6510578a5097fdbc910467a1b
Stores state within non-volatile memory
namespace ArchitectedMobile public class ArchitectedAppPage : PhoneApplicationPage protected virtual void StoreState() { }
0
ced46e03a074198f2b5e82f66767e6bd
6694cc3eb5a48c6d574f13e96c47de4d
Uploads the file specified - meaning that it enters the target file information, then clicks the import button. The file path is an optional parameter.
{ var fullFilePath = string.Concat(projectDir, fileTitle); var uploadDialog = BAT.Macros().DialogOperations().StartFileUploadDialogMonitoring(fullFilePath, DialogButton.OPEN); ActiveBrowser.WaitUntilReady(); ActiveBrowser.WaitForAsyncRequests(); ...
0
986044f8b2c61d8683f7693dd1c7542a
8136d1a77e4d5c25a5ba19e050037787
Show the application Disclaimer screen to the user.
public class CustomAppsManager extends AppsManager private void createDisclaimer() { DisclaimerService service = new DisclaimerService(); service.doGetRequest(new ActivityImpl() { public void execute(String response) { new DisclaimerDialog(response); } }); }
1
0e8f97311a0ca794c6ad2c1a0325b07a
b978e5061f44d7c170b470dd7d86bf53
Update the status of a media
class MediaController(BaseController): def update_status(self, blocking=False): self.send_message({MESSAGE_TYPE: TYPE_GET_STATUS}, wait_for_response=blocking)
0
9d2aa178b57df05d82fc7f0965b3536e
6173f311463487d220390ad7cd3fcf55
The Ninject httpmodules inject the Ninject dependency resolver.
{ var kernel = new StandardKernel(); kernel.Load<PersistenceNinjectModule>(); kernel.Load<ServicesNinjectModule>(); kernel.Load<PresentationNinjectModule>(); }
0
7e7449f09718720006d6f8d52890e2d9
34306bc6c6dd198524b9abacc10bc53e
Test that graph features have correct type.
class TestGraphORM(unittest.TestCase): def test_graph_orm_mapped_edges(self): self.assertEqual(set(self.graph.orm.mapped_edge_types.keys()), {'label'}) self.assertEqual(sorted(self.graph.orm.mapped_edge_types.values())[0], ['mo', 'bi'])
1
1fa3be38bb0fef38bcb24090f635ae80
790ba89ef1f0bf3cc716f52c24716e9d
Returns the scaled y-coordinate direction of a data point.
public class GridPointData implements GridData public final double getDy() { return dy; }
0
0caf136d35ff606d5fe320fcbf335032
fa11966e357345ce3c1c4adaabb33799
Function to calculate the interest rate of an item
def interest_rate_simple(FV, PV, Per): return (FV/PV-1)/Per
1
0506046c0d97139413f37e3db515602a
5692d93bd8fed416aa826965cee80a94
Confirma se o endereço do destinatario é valido
class Instituto extends CI_Controller public function valida_IdEndereco() { if ($this->session->has_userdata('logged_in')) { $this->load->model('model_endereco'); $id_endereco = (int) $this->input->post('endereco'); $endereco = $this->model_endereco->exibirEndereco(null,...
1
208a6d1132705d04c46fd1208825019d
620016f3e6ebda471fc5117e78ab7b38
Sets all day labels unmarked.
for (int i = 0; i < 7; i++) { daysLabel[i].setVisible(true); } }
0
3f350cf7319c4bd7f4cbe843de872502
b640e276b05e6a8c453bda0428bf6aa0
Update all balls every frame.
public class BouncingBalls extends JPanel implements MouseListener public void updateEachBallPosition() { for (Ball temp : balls) { temp.refreshAllBalls(myContainer); } }
1
ca549109c6d518c5c3c9e0397cd35b9f
c3c0ddd835190d572e90ae171354d3ea
Returns the absolute coordinates corresponding to the given point To be implemented by the child classes
export class AbstractProjection implements IProjection rawUnproject(point: any[]): any[] { console.error("Abstract method not implemented by subclass.") return null }
1
af75edee5b0fadfa14f7ac51d466d3f4
9b0f900f1adc497d0cfe3ad295597730
rebuild the list of users: scan all users and add them to the list of users
{ for (int i=0; i<users.count(); ++i) { add(users[i]); } }
1
e244775eb122f6d35d95f0f9a1182e04
15669f2a36de6e20dd4b916cf1922757
将表单和按钮组添加进来
class MyForm extends BaseFormGroup public function submit_form() { $label_content = '<label class="col-sm-2 control-label">&nbsp;</label>'; $field_content = '<div class="col-sm-8">'; $field_content .= '<div class="pull-left reset-btn"><input type="reset" class="btn btn-default" value="重 置" /></d...
1
fd4812dd72bf007055426ac0d18c38ce
d061791358650173c89e19d7e426d54a
Assert that two tabular files are essentially equal.
def assert_csv_equal( a_uri, b_uri, rel_tol=REL_TOL_DEFAULT, abs_tol=ABS_TOL_DEFAULT): a_file = open(a_uri, 'r') b_file = open(b_uri, 'r') reader_a = csv.reader(a_file) reader_b = csv.reader(b_file) for index, (a_row, b_row) in enumerate(zip(reader_a, reader_b)): try: if ...
1
0b3ccba5515d54353be5fb5e5c776ca1
9402d1540076aa57602b90551753176b
\brief Flush all mboxes and clear possible used memories
void sys_mbox_free(sys_mbox_t *mbox) { u8_t ucErr; sys_mbox_t m_box = *mbox; LWIP_ASSERT("sys_mbox_free ", m_box != SYS_MBOX_NULL); OSQFlush(m_box->pQ); (void)OSQDel(m_box->pQ, OS_DEL_NO_PEND, &ucErr); LWIP_ASSERT("OSQDel ", ucErr == OS_NO_ERR); ucErr = OSMemPut(pQueueMem, m_box); LWIP_ASSERT("OSMemPut ...
1
d30589b8ef9abc01097a4b6f4fc10b41
61a62bf3336d3d2b16cfce009f360aa2
Allows callers to add a service via HTTP requests by providing a specially formatted service description.
namespace Microsoft.ServiceFabric.Client.Http internal partial class ServiceClient : IServiceClient public Task CreateServiceAsync( string applicationId, ServiceDescription serviceDescription, long? serverTimeout = 60, CancellationToken cancellationToken = default(Can...
1
8f5118517fa1b9c8ba7e8f54bb7d2423
96c041ae4db9811ecf6a40c028fbb4fe
保存到未完成表
public int toUnfinished(String appId) throws CoreException { return getSqlMap().update(NAMESPACES + "toUnfinished", appId); }
1
621e1e7b6c6266006dfa03fb88bc4452
9f830e54f9e3be34e7b879a2e73042d0
constructor of pyNufft
self.nx = nx self.nu = nu self.ng = ng self.ngN = ngN self.N = N self.M = M
0
6de524944904a2f3f572b918c1a4cfa6
fe3a4300465acff764d078ac0be54b0b
上传视频认证配置
@Service public class UploadExamProcessInfoServiceImpl implements IUploadExamProcessInfoService{ @ExamProcessLogSaveAnnotation public WebServiceResult writeVideo(WirteVideo wirteVideo) throws Exception { String writeXml = HXCallWebServiceUtil.beanToXml(wirteVideo); String jkid = "17E14"; HXLogUtil.info(logger,...
1
f3eff3ada71103ebe073e195c6f17a4c
56dffd9143771b5eb0077f3040c12b04
从hole位置向下调整
{ int i, j = size-1; for(i = size-1; i >= 0 ; i--) if(arr[i] != HOLE) { swap(&arr[i], &arr[j]); j--; } }
0
0120f519df0927c1ea75b77aa6de54d8
8e334b4373b8866c503adea6b89db4c3
结束投放操作
$running_id = (int) $running_id; $v = M('Running')->find($running_id); if($v['OrderStatus'] != 1){ $this->tuError('订单状态不正确'); }else{ $Running = M('Running')->where(array('running_id'=>$v['running_id']))->save(array('OrderStatus'=>256)); $RunningProduct = M('RunningProduct')->where(array('running_id'=>$...
1
3b15650357b9550ba496cbefc53ef6ae
dd014eb4550deb8667e61456098a749a
窗口新增导游
$account=I('post.account'); if(M('guider')->where("account='$account'")->find()){ echo 3;return; } $_POST['userid']=$this->guid(); foreach($_POST as $k=>$v){ if($v==''){ echo 2; return; } } ...
1
5f9558c1d34435448ef6aa1e30331daf
80b02b8edbf85a311796e19fb30a2e84
============================================================================= Gauging complete interrupt handler.
static DECLARE_ISR(adc_conversion_end_irq) { sig_post(adc_process, SIG_ADC_COMPLETE); AIC_EOICR = 0; }
1
b7206d734d8504a1bec094b8e92f0e49
09bad31198d30c21d701bbef45309181
Check if there were any errors in given period of DateTimes
namespace rt.srz.services.Statement public class StatementService : IStatementService public List<string> GetErrorsByPeriod(DateTime startDate, DateTime endDate) { return ObjectFactory.GetInstance<IStatementManager>().GetErrorsByPeriod(startDate, endDate).ToList(); }
1
98c7cf5f86aa05753f936b1b5fba7eb7
fad534ab0996e868761a1a5022361de4
The built-in ui64 function returns the operand 1 casted from type f32 to type ui64.
func opUI8ToF64(expr *CXExpression, fp int) { outV0 := float64(ReadUI8(fp, expr.Inputs[0])) WriteF64(GetOffset_ui8(fp, expr.Outputs[0]), outV0) }
0
db73f08a624f978c239430f30ef25fa7
81346d8b5f56fc3bb0bb71a233dd3c2a
Prevents redirects to unsafe locations. Allows only the ones listed explicitly.
class SecuredRedirectStub extends SecuredRedirectResponse protected function isSafe($url) { return TRUE; }
0
97ad0d9b793efa54bfa7ca8a3302c66a
ad32bb823ae63d1f27f6b91ed3c3632c
将流长度写入到流的起始位置并关闭数据包内存流。
namespace Engine.IO public sealed class CompressedPacketStream : IPacketStream public void Flush() { _stream.Flush(); }
0
5f4160a2a3e07a09d987850b2ffd3f82
860fa4ef2e43eb0f4f0a476a4408544b
Generates a reference using the time, and a 6 char hex string.
class FileStorage_Original implements ThrowableStorageInterface protected function generateUniqueReferenceCode() { return date('YmdHis', $_SERVER['REQUEST_TIME']) . substr(md5(rand()), 0, 6); }
1
7df75a54a7e9c80716f3b36c56f4fd03
7652684932aca556ce5e6bbe5395bb43
Return raw data string encoded from a ``value``.
def make_str(value, encoding='utf-8', errors='strict'): if isinstance(value, six.text_type): return value.encode(encoding, errors=errors) elif isinstance(value, six.binary_type): return value else: return six.u(str(value)).encode(encoding, errors=errors)
1
c85001137c9b20269dfebe18dc7e0a1d
f726ca37457101a8f81482f82a521503
reads the temperatures into a list
class TestArkaneJob(unittest.TestCase): def test_temperatures_list(self): self.assertTrue(np.array_equal(self.TlistValue, np.array([450, 500, 678, 700])))
0
1e39115c6c93242015f99ccf4dc3297e
2417840f54e6ccd34cd4e32a4c5717e1
Sets the homologation flag. true for a homologation match, false otherwise
class ResourceObject public void setIsMatched(Boolean isMatched) { this.isMatched = isMatched; }
1
5cc63ab2be7bb9c3e32813426fafa1bd
4631b3cb18d292671130afca8b8e8c64
Prompt the user to make a guess.
def user_guess(): while True: try: return int(input('Enter a guess: ')) except ValueError: print('Input must be an integer. Try again.')
1
9694bad21243b67265643f32b181999f
8205636f59476736487d8944c871828e
метод защиты приложения
{ bool createdNew; string mutName = "Приложение"; mutex = new Mutex(true, mutName, out createdNew); if (!createdNew) { System.Windows.MessageBox.Show("Программа уже запущена."); this.Shutdown(); return; ...
1
9785932a487feb4d2d374a93cd6f0e17
f09f41805bfbb8dd17a65f9cded3e106
Use the session store to persist a token as a session.
class FrontendFormProtection extends AbstractFormProtection public function persistSessionToken() { $this->frontendUser->setAndSaveSessionData('formSessionToken', $this->sessionToken); }
1
ede55ff496a78666c7f347380a9b4ef5
09137fe1e868b70458240b45dedc0ed5
automatically detects language via browser
function detectDefaultLanguage() { global $supported_languages; if (isset($_GET['lang'])) { $key = array_search($_GET['lang'],$supported_languages); if ($key) { $_SESSION['lang'] = $supported_languages[$key]; } else { $_SESSION['lang'] = 'en'; } ...
1
3a133c884d54dae23ef857b742bbffa8
b704c92fbd2a4e989c96b29c8989741c
Метод загружающий и устанавливающий при налачии объект Zend_Acl из кэша (Cache) Возвращает true вслучае успешной загрузки и false вслучае неудачи
if (null === self::$_cache) { throw new ZtChart_Model_Acl_Loader_Exception('The cache for acl is not exist.'); } if (false === ($acl = self::$_cache->load('acl'))) { if (!self::$_cache->save($acl = $this->_getAclsInDb(), 'acl')) { throw new ZtChart_Model_A...
0
239b2c9a4d352c65ae6295ab3d1dfa02
28983513010e4c50beb13954979a004a
shows login page.
public String showMyLoginPage() { logger.info("Login page showed"); return "login"; }
1
3f7727e417af9003b99e361eb88493b4
0be717fcb1b097a6d77e9dbb2d1f5955
获取成交额
public class InvestorTrans public BigDecimal getTransAmount() { return transAmount; }
1
553e30dad01332ae3fa09305e1299538
5483514a630e284f007621fc6ea2cef4
set position to center of the table
self:InvalidateLayout( true ) self:SetPos( ScrW()/2 - self:GetWide()/2, ScrH()/2 - self:GetTall()/2 ) end
1
93e52563b18a3901f061052d092b3195
8cda4f8a86ffcb0642d722322cfb9966
Returns a new object of class '<em>Llave Valor</em>'. <!-- begin-user-doc --> <!-- end-user-doc -->
ClavePrimaria createClavePrimaria();
0
4c98ef7ce5c451e691ea7019b8cdf18a
75fc78a2ea6a774a6ec6dccbc7f942ed
Get the ha remise achat1.
class Articles public function setRemiseAchat1(?float $remiseAchat1): Articles { $this->remiseAchat1 = $remiseAchat1; return $this; }
0
de179883c083654634c7d783f3b32062
51e3404e3f203cc1c2e621ba95dfb4e2
Adds one to the value held at a specified memory location setting the zero and negative flags as appropriate.
export class Operations INC() { var result = (this.modRead() + 1) & 0xff; this.write(result); this.updateFlags(result, CPU.STATUS_REGISTER_BIT_Z, CPU.STATUS_REGISTER_BIT_N); }
1
871ba07a19cfb6cf3a5d97abd398354d
b09a2d4b2dbebcd18c21de7bb2e991fa
查看我的下线
$model_activity = new ActivityModel(); if ('POST' == $_SERVER['REQUEST_METHOD']) { if(!$model_activity->where("id = {$_POST['id']}")->update(array('status' => '0'))){ Msg::ajax('下线失败,请联系开发人员'); } Msg::ajax('下线成功',1); } }
0
9abd5d0cae8da524c55b0ec9e5c47c2d
6ca88f2b89edb97af559c5fa1d18e161
Busca en la base de datos la información de varias películas. Desde una lista con los PK de las películas realiza la busqueda generando una nueva lista con la info de dichas películas.
throws IOException{ List<Movie> result = new ArrayList<>(); JsonNode moviesNode = rootNode.path(Movie.KEY_RESULTS); if(moviesNode.isMissingNode()){ return null; } List<String> ids = Arrays.asList(context .getResources().getStringArray(R.array.f...
0
302ab8c6b9959c646ae85dca5e74c0a7
35118548678aeacda59cb23455b67eff
返回 Tax Invoice(支払用) の発行日
public class Ctr0003s01Dto extends BaseDto public Date getTaxInvoiceIssueDate() { return taxInvoiceIssueDate; }
1
28b2d96bcabf560c6e029106e0a2a435
92207df1043f0e9566785a7efbb8191e
Creates a new speaker.
namespace DataManager.Controllers [Authorize] public class SpeakersController : Controller public ActionResult Create() { return View(); }
0
8a139c560815d7cdda44431d51597e20
1e0b55a42f1c4fdc6539158b54137c33
设置HOME点经度
void MapFrame::on_aSetHome_triggered() { if(mapView->clkLL.isNull()) return; var->home_pos[0]=mapView->clkLL.x(); var->home_pos[1]=mapView->clkLL.y(); var->send(idx_home_pos); }
1
63c121a0e91ecc16f8a0dad9ae1a0bd0
02cd535c7b2fe05943416881d20933ff
============================================================================ OpcUa_HttpsStream_SendChunk ===========================================================================
{ if (message_header == nullptr) { return false; } auto export_data = _export_chunk->ExportStreamData(message_header, data); if (export_data == nullptr || export_data->data() == nullptr) { return false; } return SendData(export_data->size(), export_data->data()); }
1
7eda96f8ff95245c716960ed6d792f4c
3bf31f102525239ab33176e4367d3da6
Unload all assets in given folder
for(String s : assets) { if (manager.isLoaded(s)) { manager.unload(s); } } }
0
83c9c86994de3a62510ced2e418b4347
b97dd482b0a0c471b028e1441b088339
Specify that the case definition belongs to no tenant. Can only be used when the definition is referenced by <code>key</code> and not by <code>id</code>.
namespace Sys.Workflow.Engine.Repository IProcessDefinitionQuery SetProcessDefinitionWithoutTenantId();
1
c9c4481955bf5f0e2367aa0f89b206bb
026c42c36affa4144d992a457e21ca41
인자: 정규식 엔진 리스트, 패킷 리스트 정규식 엔진들과 패킷들을 받아 정규식을 doc ID로, 그 정규식에 걸러진 payload들을 단어로 삼아 학습시킨 Doc2Vec 객체를 반환한다.
mal_records = InspectInParallel(patterns, packets) sentences = [d2v.TaggedDocument(payloads, [rule]) for payloads, rule in mal_records] return Train(sentences)
1
20d5521cf0212383a6acdb1cc2621d22
a484614cc2742fb6dd0f5f88b93571b5
GET: stocklocationmodels
{ IEnumerable<StoreLocation> locations = Repo.GetLocations(); IEnumerable<StoreViewModel> locationModels = locations.Select(c => new StoreViewModel { Id = c.Id, LocationName = c.LocationName, Orders = c.Orders.Select(x => new Or...
0
d2b241b06208a019b95b532dfe550e94
bcad4c46a74f8dcf41c3035c4f7b8fb5
# single step of random scan Gibbs sampler: update para[j]
m <- exp(d*(stats::runif(1)-0.5)) prop <- pars[[move]]*m lnHastingsRatio <- log(m) pars.new <- pars pars.new[[move]] <- prop return(list("pars"=pars.new, "hr"=lnHastingsRatio)) }
1
2675f38a9afb09509320400898c141c0
2e1b0959f6f679220fd24524e6da33c0
Restart button pressed. Navigate to Start Menu.
namespace Bettery.Kiosk public partial class Start : Page private void GetStartedButton_Click(object sender, RoutedEventArgs e) { BaseController.PreviousPage = this; Welcome page = new Welcome(); this.NavigationService.Navigate(page); }
0
357728a12a28e09cc582171d1cbfd9ec
e98f9a42599336dd3a86c2785bd85990
Asynchronously get the sub object keys in this folder
Observable<Page<KeyItem>> getKeysAsync(final String vaultBaseUrl);
1