query_id
string
corpus_id
string
query
string
code
string
label
int64
8b8842ce133fc2bcd4f6344f8466739f
5b821fa9272e42c044e014bf23010931
Limpia el campo responsables
@ManagedBean() @SessionScoped public class PromocionesController implements Serializable{ public void eliminarResponsable(ActionEvent event){ this.listaIngresarResponsablesPromocion.remove(this.responsablePromocion); }
0
5409d5ba85fb1d54915e596096ab506c
ee0e82692ad3da0534483e81ba4fd5da
Release lock using lua script.
{ am::util::data::Table *table = castUData<am::util::data::Table>(lua, 1); if (table) { table->release(); } return 0; }
0
6ca737e2ad5cf58c29080f5ae655db42
1237787ba24047fd88da6ec1de0019e4
Sincroniza con la base de datos de recursos humanos
if kwargs.get('using') == default_db: bases_de_datos = MICROSIP_DATABASES.keys() bases_de_datos.remove(kwargs.get('using')) cliente_a_syncronizar = kwargs.get('instance') indice, indice_final = get_indices(len(bases_de_datos), 40, 'CLIENTE') for base_de_datos in bases_de_dat...
0
cf3fb1ff52ea1eed3347ac5401ee7f0c
9e7971364247cbb5e55e338da265906e
Ascending
export default class Cpu private _asl() { let carry: number; let result: number; if (this._context.Mode === AddressingMode.Accumulator) { carry = (this.A >>> 7) & 1; this.A <<= 1; result = this.A; } else { const operand = this._memory.get(t...
0
48496f5e6d26cbd81a25672e9d04a9fd
32de2a708ad171c2151cfce9748947e6
根据openId查询角色信息
User selectByOpenId(@Param("openId") String openId);
0
c8217d756a3fb6c6e7862be1259abcab
f2e0aa3f02e172058628ff71e2ffb1aa
#客戶類別
class Basic_category extends CI_Controller function edit_cust_class($id='') { $id=$id*1; if(CkUrl() && $id>0) { SubmitKey('edit_cust_class'); $da=array(); $DB=$this->firebirddb; $da['row']=$DB->get_row("select * from cust_class where id='".$id."' "); $da['myclass']=strtolower(_...
1
bdf40d4f30d2190bb550d2c5ee2c3648
5bfc27b83c13ac196b3544e4bbd7b27c
Releases this Vulkan command pool.
VkCommandBuffer cmdBufferArray[1] = {cmdBuffer}; vk::vkFreeCommandBuffers( device, cmdPool, 1, cmdBufferArray ); vk::vkDestroyCommandPool(device, cmdPool, NULL); }
1
599645e2ca6c385793cd24e72e8960cb
8c003326f6346135f6f20a2e876f104b
分批次获取数据
const forkJoinArr = []; const requestTimes = options; if (requestTimes.length > 0) { for (let i = 0; i < requestTimes.length; i++) { const params = requestTimes[i].findParams; let paramsString = ``; for (const key in params) { if (params.hasOwnProperty(key) && params[...
0
358e1243aa72836073396787ebcfdbdb
996e88374350c2cf2382a26a9217cce1
Collect relations xi^2 = yi (mod kn) with yi smooth.
cross_x = tf.expand_dims(self.py, axis=-1)*tf.expand_dims(self.pz, axis=-2) cross_x_T=tf.einsum('aij -> aji', cross_x) yy = tf.gather(tf.reshape(cross_x-cross_x_T, [-1, self.n**2]), self.triu_indices, axis=1) return yy
0
d238241839ae6af7b0f72f6a8f29bd77
d58ae27ebac3b2c32b6594a7eb323c30
Inserta en la tabla 'administradores' el usuario actual
{ $sql = 'INSERT INTO datos (name, last_name, created_at) VALUES (:name, :last_name, now())'; $user = [ 'name' => $this->name, 'last_name' => $this->last_name, ]; try { return parent::sql([ "sql" => $sql, "params" => $use...
0
6c049d755b4bb6495e9800d16e69501b
b2d9daddd116f28a118318778cd67bd4
Вычисление LUP-Разложения данной матрицы
namespace pilal void Matrix::get_lupp(Matrix& l, Matrix& u, Matrix& p, PermutationFormat pf = PF_MATRIX) const { if (!is_square()) throw(MatrixNotSquareException()); long double determinant = 1; u = *this; l.resize(rows, columns); ...
1
c373d85ca709dd1ef8cd577308a0957f
e78d19ac331f9fd16fa4b8cd26d19e64
Sets the enclosing type
@Nullable BareTypeMirror getEnclosingType();
0
9f00f10b65aff9bb1692843718041346
134f5baa515abbca77cebeb0707ae126
Построение фазового портрета
fig = plt.figure(figsize=(60, 20)) print('L=', len(frame['lhfx'])) lensig = len(frame['lhfx']) if lensig < psfftl: sfftl = psfftl / 2 while lensig < sfftl: sfftl /= 2 sffto = psffto / 4 else: sfftl = psfftl sffto = psffto ax = fig.add_subplot(3...
0
b4f75f1f6660b796c77fd719fad59d24
7981f3864658b21e8d621c889caff66e
[Documentation](https://wowpedia.fandom.com/wiki/API_Animation_GetEndDelay)
function Animation:GetEndDelay() end
1
d1a60072b00208bec7ff9bf8356e68ec
64befa1ebe384edc8a6f71e8eea480bb
(可选) 每个测试用例执行后(test开头方法)执行该方法进行销毁
class TestCase1(unittest.TestCase): #测试环境搭建 def tearDown(self): pass
1
0b747bced2f837efbb1850dfd0a9935c
0d2702549f8c66ee8df6ae40d751ae40
Tests only if given rectangles intersect, returns True or False
def rectangle_overlap(r1, r2): return ( (r1[0] <= r2[2]) and (r2[0] <= r1[2]) and (r1[1] <= r2[3]) and (r2[1] <= r1[3]) )
1
16eba9747750c820ce3b532bb75429de
abf792d8bb8e3ff6a58c391a87aecd5f
Fill color in dot graphviz format.
def get_dot(G_orig): G = G_orig.copy() cluster_networks.relabel_graph(G) tr = {} for node in G.nodes_iter(): tr[node] = '"{}"'.format(node) nx.relabel_nodes(G, tr, copy=False) for node in G.nodes_iter(): label = str(node) if len(label) > MAX_LABEL: label = u'{...
1
8124732a716be13300ea208a77ec014d
3369d7241036d8d01f2ee2c37766f4ba
Tells if the option can accept more arguments. @return false if the maximum number of arguments is reached @since 1.3
public class Option implements Cloneable, Serializable public boolean requiresArg() { if (optionalArg) { return false; } if (numberOfArgs == UNLIMITED_VALUES) { return values.isEmpty(); } return acceptsArg(); }
0
ebb733a7f75574b3cb6720cf79177534
2745238db27c7c3b28bd44335635dfd6
从池子里面获取通道,如果没有就需要建立一个(目前都是在NavAgent里面处理的)
@Component("connectionManager") @Slf4j public class ConnectionManager public Channel getChannel(String nettyIp, int nettyPot) { Channel channel = null; if (StringUtils.isNotBlank(nettyIp)) { Connection connection = this.getConnection(nettyIp, nettyPot); if (null != co...
0
cadcd4f25aa1e48a88f44ae4d7062616
965852c8f842f56497dd743b5495ab3e
- don't allow dots for int values - remove all non-numeric characters - remove all dots after first one
function stripNonNumeric( str ){ str += ''; var rgx = /^\d|-$/; var out = ''; for( var i = 0; i < str.length; i++ ){ if( rgx.test( str.charAt(i) ) ){ if( !( ( str.charAt(i) == '.' && out.indexOf( '.' ) != -1 ) || ( str.charAt(i) == '-' && out.length != 0 ) ) ){ out += str.charAt(i); } } ...
1
0d3885a130cfa12fd09f2efe4cbeb9c9
c6c2ab8941af99d0e4bfd4ef76f34405
Spawn collectable points
{ std::for_each(&ai_spawn_points[0], std::end(ai_spawn_points), [this] (const QPointF &p) { spawn(p); }); }
1
0bf9cfcbb2fadb3555b568979a84ed28
060976b521dc520c9f6c8eb9ca46f508
Computes the number of nonzero array elements.
def w(v): return count_nonzero(v)
1
3da0c8393d666a8e21f1ef48911abf3d
e5ea2f25c03ed0ed9f40127301a8bffa
Attiva la pausa se inattiva, la disabilita se attiva
void BOF::isPause() { if (_isEnabled){ isDisable(); }else{ isEnabled(); } }
1
f90da65082a2de61c18dc1efc581f42e
d0afc6c9f7421a512fda18ff0f6cbbb1
O Método "OpcoesCheck()" serve para retornar um valor bollean informando o resto do programa, se o string que lhe foi passado pode ser de forma segura convertido para int, ou não.
{ try { Convert.ToInt32(valor); } catch (FormatException fe) { return false; } return true; }
1
b2205cf0d26adacd16ca4c7b2458f7ac
08addece6dabd96e84e456a96add54cf
查询商圈信息
headers = {'User-Agent':'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36'} html = requests.get(url[0], headers=headers).text if len(html) == 0: print('未找到该城市的商圈信息') return 0 else: html = BeautifulSoup(html, "html....
1
74a8f2f8328c7d650aac77352c45e1ac
3ce65b5434c363000a6b23771f97c95b
虚拟像素转真实像素
public class Transformer public void rectValueToPixel(android.graphics.RectF r) { mMatrixValueToPx.mapRect(r); mViewPortHandler.getMatrixTouch().mapRect(r); mMatrixOffset.mapRect(r); }
1
d1a55f1553173896e831f1dfc1c5f0d8
65df1f2711a25dd823f941011957e4a1
READ SCORES FROM scores.txt
ArrayList<String> strScoresList = new ArrayList<String>(); try { FileReader fr = new FileReader("WinTotals.txt"); BufferedReader br = new BufferedReader(fr); String strFileLine = br.readLine(); while(strFileLine != null){ strScoresList.add(st...
0
7a95d9853f8f35136dece32519d0dc83
7824b7befe7683ecab390e2ab9c4281c
Try to activate (double-click) the item according to the index, and then verify if the item has been really selected according to the parameter 'verify'. If the parameter key is provided, the selection will happen with that key pressed at the same time. <br> for example {@link Keys#SHIFT}, or {@link Keys#CONTROL}.<br> ...
public class NetNumeroSuggestBox extends Composite implements HasText, Focusable, HasAnimation, HasAllKeyHandlers, HasValue<String>, HasSelectionHandlers<Suggestion> private static class SuggestionMenu extends MenuBar public void selectItem(int index) { List<MenuItem> items = getItems(); ...
0
c70264259da3fd5fe3c1d68ea040011a
2f510576f63adc9f10a2e22e9c6d03ae
Returns length of the timer so far in milliseconds
function getTimer(): number { return Date.now() - _startTime; }
1
83be8d99d9a45e084af475bb39769c6b
54b05fcdd95abf69c0e157a2912475b2
Returns the meta object for class '{@link br.com.maisha.wind.terra.AttributeProperty <em>Attribute Property</em>}'. <!-- begin-user-doc --> <!-- end-user-doc -->
EClass getAttributeProperty();
1
98932214b2d3d383cab5be8f135279fe
6ca5efd2e56992a1d42fe51567700cb7
Формирует ключ для Множества с целевыми рубриками
function getOptionsKey(categoryOptions: any) { return _.sortBy(categoryOptions.map((co: any) => co.id)).join("-"); }
1
d0d058fdf3546cbb1e9efee5ec72ac03
abdc5908b4c0c91f26a55a71818ca8ee
1지역을 자주 방문한 사람들이 머무는 평균 시간 db 불러오기
def avg_stay(db: Session, time_range: int): date_subset = exit_date_subset(db=db, start_range= time_range) avg = db.query(func.avg(date_subset.c.length_of_stay)).one()[0] return round(avg)
1
879af138e810528551cd67ea26a2c173
14623d9cd759c7aed3ecd816822d3039
close our feed before our window goes away
namespace ThreadedPriceFeed public class Form1 : System.Windows.Forms.Form private void Form1_Closing(object sender, System.ComponentModel.CancelEventArgs e) { m_InstrNotify.Dispose(); m_InstrNotify=null; }
1
2de58a0da5662d3433921ae1144095fd
36cfd9383853f89ca5283436b69d9ba0
Ask user for two values and calc GCD
bool goAgain = true; do { int x; int y; char input; cout << "Enter first number: "; cin >> x; cout << endl << "Enter second number: "; cin >> y; cout << endl << "GCD is " << gcd(x, y) << "." << endl; cout << "Go again? (y/n)" << endl; cin >> input; if (input == 'n') { goAgain = ...
1
95a25dfaae2b20ed2f3e0905aebd12bb
4beab866193049af13d9031e07481ab7
Visit a parse tree produced by {@link MipsParser#stat}.
public class EvalVisitor extends MySQLParserBaseVisitor<String> @Override public String visitStat(MySQLParserParser.StatContext ctx) { return visitChildren(ctx); }
0
42eb08e1f16577cbc8b39cf60b64b1a1
af5b748803ede9b255e76c3316e1e993
Check that creating a user with a password works correctly
email = VALID_EMAIL password = VALID_PASSWORD create_user_successfully(client, email=email, password=password) user = get_user_by_email(email) assert bcrypt.checkpw(password.encode("utf-8"), user.password)
1
d36333d2429a4dadc3581d092aa5d35b
40e75c8b6b8f27168c8b9ad510afe391
NewWebsocketConfig creates a new WebsocketConfig with default values.
func NewConfig() *Config { return &Config{ MaxConns: defaultMaxConns, } }
0
879dd8dd8cf6550f71c8e783bcfa3a5e
32d9b96480fbb713c248779a4f15a3c9
Get info about the device and doors.
area = self.coordinator.data["locks"][self.serial_number]["device"]["area"] return DeviceInfo( name=area, suggested_area=area, manufacturer="Verisure", model="Lockguard Smartlock", identifiers={(DOMAIN, self.serial_number)}, via_dev...
1
0da45c651ce2602493da067ba50a6990
b526b5aadc711664a130a2a7d74b6a95
Get the SQL extension clauses for implementing privacy.
$clause = '1=1'; if ($this->filterVariant) { $clause .= ' AND is_variant = 0'; } if (TYPO3_MODE === 'BE' && $this->ignoreEnableFields) { $clause .= \TYPO3\CMS\Backend\Utility\BackendUtility::BEenableFields($this->tableName); } elseif (TYPO3_MODE === 'FE' && $this->ignoreEnableFields != TRUE) { $claus...
0
65125a9b21593f936a78c72963bcfc50
1fbe257831e91fce1ea7b32d82408a4b
レーティングモデルの一覧を取得<br />
Request.DescribeRateModelMastersRequest request, UnityAction<AsyncResult<Result.DescribeRateModelMastersResult>> callback ) { var task = new DescribeRateModelMastersTask(request, callback); return Gs2WebSocketSession.Execute(task); }
1
162f78ebde46d9164b890c7e09da28b5
07129dad865ab680742721498bbad4fd
(GameView) -> NoneType Initialtize a list of game options to be later chosen between, where the game options are a list of game classes.
self.frame = tk.Frame(self.root, bg='lemon chiffon') self.title_label = tk.Label(self.frame, width=25, height=2, bg='lemon chiffon', text='Please select players:', font=('Helvetica', 20)) ...
0
7237abc5dc0e7735bd3e8ccb2e0f2d9d
cb25b4776f522896ffdea9e8e6b90910
Ustawia aktualnego słuchacza sprawdzającego kolizje dla układanych elementów.
public void setCollisionEventListener(CollisionEventListener listener);
1
cfc35d47b5402c753b2477a14583ddcd
288b4c5624827765ff83617fbaa00dd2
Ermitteln des Sleeptimers.
{ int32u currentTime; currentTime = SLEEPTMR_CNTH<<16; currentTime |= SLEEPTMR_CNTL; if(forceSleepTmrCnt && (currentTime == wakeupSleepTmrCnt)) { return sleepTmrArtificalCnt; } forceSleepTmrCnt = FALSE; return currentTime; }
1
ac025a49407925fd61a079cc32000515
de2e9a047afeca1b967408543526c6dd
删除子文档
public class DataDoc public void deleteChild(String aName) { if (StringUtils.isNotEmpty(aName)) mChildDocs.remove(aName); }
1
d33727470eddb51d1cf5b5a571118e9c
b3edc6c86bf00ae2c054d9e0eb946117
map values from vt results data to key names defined in this script
if 'vtSymbol' not in d: return d symbol = d.get('symbol') exchange = d.get('exchange') vtSymbol = d.pop('vtSymbol', symbol) if '.' not in symbol: d.update({'vt_symbol': f'{symbol}.{exchange}'}) else: d.update({'vt_symbol': f'{symbol}.{E...
1
0b13b303775414c791d2ac14cd0e36be
294097978e265d52bea1fdcdddf4e058
Operation designProcessorValidateDesignImportSettingsAsync Validates the design import settings.
{ return $this->designProcessorValidateDesignImportSettingsAsyncWithHttpInfo($tenant_id, $marker_shortcuts_file) ->then( function ($response) { return $response[0]; } ); }
1
3f6487c764e52c8afa9244d9190d6a90
fedf7547852c8b05c513ab6f0908577e
Returns the meta object for the attribute '{@link org.cpntools.pragma.epnk.pnktypes.pragmacpndefinition.PragmaticsOntology#getManager <em>Manager</em>}'. <!-- begin-user-doc --> <!-- end-user-doc -->
EAttribute getPragmaticsOntology_Manager();
1
1dbe1668c9ac43ba14d9df4fc8b8b404
d133a6f31569ba81554430cc019cbc55
returns the starting y value of the specified edge
class VHEdge startY(){ this.start.getConnectionPoint(this.end).getY(); }
1
cda3e7f3c8a43a84e612315df809123a
982c793c79eef4d4901f0ff53c049fea
行番号の配列を作成します。
class Page extends ManageController private function __create_array_ymdhis($start, $end, $unit = '') { $_create_array = array(); for ($i = $start; $i <= $end; $i++) { $_create_array[sprintf('%02d', $i)] = $i.$unit; } return $_create_array; }
0
babb238f7af520a366b8cd1f9b997120
4df3d2e02ec038e3729dd5e8d700d3f4
Returns true if no ads purchased.
class AdManager private constructor(context: Context) fun removeAds(activity: AppCompatActivity): Boolean { if (!hasRemovedAds()) { mBillingManager.purchaseProduct(activity, BillingManager.Products.AD_REMOVE) } return hasRemovedAds() }
0
b4e1bce594448c1d851b9f076a0b4af5
80c9635468563ddc2c91c509bccb16e7
make api call to search the dynamic form data whether it is already exists or not
interface MainRepository suspend fun checkForDuplicate(data: String?): Boolean
1
21054c5b8106f4eb68e5feef2fefd329
44d512b35a89620a580c9d84e46dad58
评价商品页面
$goods_id = intval($_GET['goods_id']); $model_goods = Model('goods'); $goods_info = $model_goods->getGoodsInfoByID($goods_id, '*'); if (empty($goods_info)) { showMessage(L('goods_index_no_goods'), '', 'html', 'error'); } Tpl::output('goods', $goods_info); ...
1
3a069c57ba570a5facf01ad2153b2896
c2c0528ab6240389d5b1c7d03658e8be
<p>Funcion que configura el evento onClick para ser usado en cada item de la lista de cuentas.</p>
public void onItemClick(AdapterView<?> parent, View view, int position, long id) { Twitter selectedAccount; Intent intent; selectedAccount = TwitterAccounts.accounts.get(position); intent = new Intent(MainActivity.this, HomeTimelineActivity.cla...
1
3d9d769dfd6f111d8b2f59fe64a47a70
3f8f46576b6892e79d9cbf59b1f72e5d
Converts a sparse SciPy matrix to a sparse PyTorch tensor
def sparse_torch2scipy(tensor): coalesced = tensor.coalesce() values = coalesced.values() rows, cols = coalesced.indices() return scipy.sparse.coo_matrix(( values.numpy(), (rows.numpy(), cols.numpy()), ))
0
4b5c8217714f1963b05a1c7c71c98194
411a7f4621bdcff827ce0be0518159b7
Registers {@link Request}s (provided as a hashmap), also available as a static method.
if (Requests.get() != null) { throw new PrimeException("Request is already set into the HTTPObjectsHolder"); } Requests.set(request); }
0
6d024931da0bfb0253461ebc6bdcb334
61f32a4bdd03e708ffabb5f522b0b608
Metodo para consultar todos los datos de la tabla Menu
class MenuController extends Controller public function index() { $data = DB::table('menu') ->orderBy('id','desc') ->get(); return response()->json($data, 200); }
1
07e20d2dec2d32dd8e191d3c204df8f2
6eebc94da28b769acf4ce1cb3074d6e6
Resign a GNZ member Any club admin can do this, but the GNZ admin will be notified.
{ \IPS\Session::i()->csrfCheck(); if ( !$this->club->isLeader() or !\IPS\Application::appIsEnabled('nexus') or !\IPS\Settings::i()->clubs_paid_on ) { \IPS\Output::i()->error( 'no_module_permission', '2C350/W', 403, '' ); } $member = \IPS\nexus\Customer::load( \IPS\Request::i()->member ); switch ( $this-...
0
6ebf1755f5dd931506997c48c270b046
af4aefacb157849799934d08bb262d4c
累积/派发指标 Accumulation/Distribution
public Result getResult(Accumulator acc) { Result result = new Result(); result.timestamp = acc.timestamp; result.tip_percent = 100.0 * acc.tip_amount / (acc.total_amount - acc.tip_amount); return result; }
0
43632172e4fe0f18dfdb558159455447
2a8836ea6e5590657ee5b5d60782b3db
Builds the <see cref="DetachVolumeAsync"/> request.
namespace OpenStack.Compute.v2_1.Serialization public class ComputeApi public virtual Task<PreparedRequest> BuildDeleteVolumeSnapshotRequest(string snapshotId, CancellationToken cancellationToken = default(CancellationToken)) { if (snapshotId == null) throw new ArgumentNullExcept...
0
799b958ca1894437911318c0e43db8ad
d61ebd2a9b628f9040be43aae624d5ea
Walk all defs of the specified register.
regs = (reg,) + regs count = modifiers.get('count', 1) args = u', '.join(["{:x}".format(ea)] + ["{!r}".format(predicate)] + ["\"{:s}\"".format(utils.string.escape(str(reg), '"')) for reg in regs]) args = args + (u", {:s}".format(utils.string.kwargs(modifiers)) if modifiers else '') ...
1
c881b1b2062cc53ebe546d38c71bf61b
591f02a64b798a3665acb23978d1b8c7
读取灯泡名称
api = self.loadApi()['ssidIdList'] request = PublicControl(self.s) recvdata = request.apiRequest(api) ssid0_name = recvdata['data']['result'][0]['label'] print ssid0_name return ssid0_name
0
a074b2ee68bc264b439c617786243bba
1f0cef8283645b3ee96a3177c41cc5c1
NewInitializeAction returns a action that initializes the platform configuration when not provided by the user
internal expect fun platformInit()
0
03d69dc4273d1f7b7fb55f010b847c90
e22aa9fe40235ee3c45e3eaae810a43c
Delete last entry in a list Deletes the last object from the list Returns YES if OK, else NO
class Dataset(object): def deleteLastEntry(self): if self.data: self.data = self.data[:-1] return True return False
1
8124b4c1bef855dade117236a3d80a8e
a63f8278fd009d4fd66a0529d22e8f29
Dynamically get values from the Stripe PaymentIntent.
class Payment implements Arrayable, Jsonable, JsonSerializable public function __get($key) { return $this->paymentIntent->{$key}; }
1
0d14163025348ec6cb5be8a2458c55ea
3e1074ac15f96e27174225978fddfc0b
# vector to dataframe
xtodf=function(x,name="Data") { x=as.data.frame(x) x=data.frame(as.Date(rownames(x)),x) colnames(x)=c("Date",name) rownames(x)=NULL return(x) }
1
bd5ce84a8e40f7ae69c78aa2cc3b2977
be0adebf302fbc0b7255ea5ed4a2e84f
Verify that all the database tables are setup properly for managing IP addresses.
void dns_check_entries(void) { dns_check_entries_adpt(); }
0
a5b9dfeaaed2d1c31ec9130b2c984610
9833496233a35d85fdd0e3c0c9246b82
pretty-print state of audit
static void audit_sys_auditon(struct audit_record *ar, struct au_record *rec) { struct au_token *tok; switch (ar->ar_arg_cmd) { case A_OLDSETPOLICY: if (ar->ar_arg_len > sizeof(int)) { tok = au_to_arg32(3, "length", ar->ar_arg_len); kau_write(rec, tok); tok = au_to_arg64(2, "policy", ar->ar_arg_aud...
0
78087ae79aaba152e6ae0c01f195eca6
b4e0a7e226033c85b21c1c1e96949055
Empties the CC text area Change Log: 2012.12.19 ALP - Initial version
public class Cls extends AbstractCommand @Override protected void doExecute(String[] params) throws Exception { m_Owner.getOutputArea().setText(""); }
1
81bf1a453965e10e10b191f0208154db
564ebe7727a9ec97fbf736e4f1bd2829
Counts how often the sign of consecutive list elements
count = 0 for i in range(len(lst)-1): if lst[i] >= 0 and lst[i+1] < 0 or lst[i] < 0 and lst[i+1] >= 0: count+=1 return count
1
2e261e7d4641e87cb304bd0bbc23df77
2accfed6d1262baca636868970bfdfde
Carica uid cespiti da ammortare.
function consultaVariazioneCespite(uid, e) { e.preventDefault(); document.location = baseUrl + '_consulta.do?variazioneCespite.uid=' + uid; }
0
ef469d0e215408f7dda1feb478b9c84e
517d57033f25e1138790719b8e73f91b
Returns self._ship
class Ship: def getNameOfShip(self): return self.__nameOfShip
0
03ec159fe76efc39bbeceb412801c107
a72cca858867158c0982ba13d8b79064
Sets color to use when drawing strings. Will set alpha to 100%
public class CustomFont public void setColor(int r, int g, int b) { setColor(r, g, b, 0xFF); }
1
e59267ee19158c122b946e9f36679afc
85748cd835787c4a6a10bc1b6bce1b87
Metoda ktora nastavi vytrvalost predmetu (alebo tiez aktualny zivot predmetu)
void IceAge::ObleceneVybaveniVeverky::setPravaRuka(IceAge::Predmet* novaPravaRuka) { this->m_pravaRuka=novaPravaRuka; }
0
808e30f28047ff3bd0b9c091c481cb7e
43d2868ee5203e3be4d902efda2c73fb
Prüft den erforderlichen Parameter und gibt dessen Wert zurück
if !params.instance_of?(Hash) fail(UserError, "Die Parameter sind keine Hash-Struktur!") elsif params.empty? fail(UserError, "Die Parameter sind leer!") elsif !params.has_key?(:lang) fail(UserError, "Der Parameter \'lang\' hat keinen Wert!") end end
0
067066a84a27116bdc541de030b6ee3a
9a8cf4a9df9f4445d18d648157cac2a1
方法描述:获取冲抵结余实体
TOffsheetfinTol result = null; if(!id.isEmpty()){ String[] idList = id.split("_"); if(idList.length==2){ String sql = "select if_Need_Change,ifChecked,Acct_Id,Currency_Cd,Day_Bal_Fill,Report_Id,Declare_Dt,tol_record,Belong_Org_Id,modified_User,MODIFIED_TIME,CREATE_USER,CREATE_TIME,status from ZMQ_T_Offshe...
1
212bd0d1befa3b0018a487192ab725d5
4fdd3e361427df21645897c5fb784778
Determines the OpenGraph Title
class Meta public function getOgTitle() { return $this->ogTitle; }
1
66abf725009950bff497713b7fbea890
435ee2ec760c37c7469683ebb1ff4137
Remove address select fields
{ Schema::table('users', function(Blueprint $table) { $table->dropColumn('address1'); $table->dropColumn('address2'); $table->dropColumn('city'); $table->dropColumn('state'); $table->dropColumn('zip'); $table->dropColumn('parent'); }); }
1
241bb54b899c020ece85c44b1df85782
9d379bf94c11ca92b087d07352498a30
Removes all allocated data and rebuilds the free-list.
while True: try: block = self._pending_free_blocks.pop() except IndexError: break self._add_free_block(block) self._remove_allocated_block(block)
1
3a22eae93d9d314f76ad535cf213c6c8
53b8a51d238b9bc7671314becf8070ce
Request for the 'Menus' and then attach them with actual model.
class MenusController extends Controller public function index() { $menus = Menu::all(); $data = []; foreach ($menus as $menu_value) { $menu_items = $menu_value->menu_items('menu_id')->get(); $menu = $menu_value; array_push($data, compact( ...
1
d2e646ed1a7a1bd140ba3b784b22d3ac
0e3a92a6a2ac5560b957c9d77bf48e16
指定クラスのコンストラクタが実行可能か否かを返す
class Target(): def is_runnable(cls): return cls.RUNNABLE
0
c16c274650b4a437508b66bc12b52606
5627bd178a9a74c17ffdcc4818e07596
Изменить название файла шаблона
class TemplateConfiguration extends TemplateConfig public static function rename($sOldName, $sNewName) { self::model()->updateAll(array('template_name' => $sNewName), "template_name = :oldname", array(':oldname'=>$sOldName)); }
1
6fdc922cd5f37e175d038f480c4325e5
d53e62adc3f0c0fc6396e6cfbbb3337a
Tests closing an open file
_, filename = tempfile.mkstemp(suffix='.sdf', dir=self.temp_dir) self.reader.open(filename) self.reader.close() assert self.reader.f.closed with self.reader.open(filename): pass assert self.reader.f.closed
1
6438db7903766baa0c9807611ffed7b5
9589f5ab21ec399b7473f2b3077c3c37
returns digits of n in reverse order, faster than int(d)/str(n) approach Note: if performance is critical, it is better to inline this functionality than to call this generator.
def digits_rtl(num): val = int(num) while val: yield val % 10 val //= 10
1
d82b6f686ea4641a61625d2a9874d803
e2509df80534d46c87411b2ed1d810a7
personel işlemleri sekmesini temizleme metodu!
namespace B191210071_EzgiBAGCIK_odev3 public class Sepet public void SepetiTemizle() { Form1 frm = (Form1)Application.OpenForms["Form1"]; frm.lbAdet.Items.Clear(); frm.lbUrun.Items.Clear(); frm.lbKdvliFiyat.Items.Clear(); frm.lblToplam.Text = st...
0
ce356e5c4a92350d27aa2e30d482cb48
a96647909216aff6dcfb7ed3c1874dca
微信开放平台接口1:获取第三方平台access_token,即使用ticket获取组件的access_token。
{ var url = "https://api.weixin.qq.com/cgi-bin/component/api_component_token"; var ticket = await GetOpenTicketAsync(); if (string.IsNullOrEmpty(ticket)) throw new ArgumentNullException("component_verify_ticket", "开放平台ticket不能为空,该值每10分钟推送一次"); var content = new ...
1
8eeb544659777143985e2219e3bf32b5
b0aa07efc1fe8f184ce083545d3bd33b
Return a list of language directories. also see infocours.php and index.php which contain a similar function
function listLanguages($langdirectory) { if ($handle = opendir($langdirectory)) { while (FALSE !== ($entry = readdir($handle))) { if (substr($entry, 0, 1) == '.') { continue; } $lang = substr($entry, 0, -4); $languages[] = $lang; } closedir($handle); } if (empty($langua...
1
09fe8e585c40551d30d7995b92136fbb
f8cbd771df93ddf442ed5edddf12e672
Returns the description of <code>var</code>.
namespace System.Runtime.InteropServices.ComTypes void GetVarDesc(int index, out IntPtr ppVarDesc);
1
4281ab14ab1e3d0a6ba8b5f6cebf37d1
a1328c3a44c5fdc92bdf7b0a3744f05c
update wrist positions
elbowPosition = neckPosition + torsoRotation * elbowPosition; wristPosition = elbowPosition + elbowRotation * wristPosition; controllerPosition = wristPosition + wristRotation * controllerPosition; }
1
d7f058e8861d5d0432dde830dcc87122
3d0ebb92e012e6d21d563caf47b774a3
生成指定大小的TXT档
def gen_size_file(file_name, file_size): file_path = file_name file = open(file_path, 'w') file.seek(file_size) file.write('\x00') file.close() print("done!")
1
f01dd17a893ad1db5d4a660b88263f0d
227fb89ca125502add35cb86f067e3ab
e.g. Tchaikovsky, Pyotr Il´ich, 1840-1893
def artist_transform(artist): if artist == 'Miller, Jimmy (Ewan MacColl)': return u'Ewan MacColl' artist = artist.replace(',','').split(' ') return ' '.join((artist[1], artist[0]))
0
bc05e5c54a91238951b408c4b4f5779a
e843daeaa0f9e292c46ef7d9d5d1cd4d
Method that returns the welcome team adaptive card.
{ AdaptiveCard notTeamOwnerCard = new AdaptiveCard("1.0") { Body = new List<AdaptiveElement> { new AdaptiveTextBlock { Text = Strings.NotTeamOwnerText, }, }...
0
a8e87dc4b63cd65deed964a94a73a3a5
399c31795150a3f3808a927ff6203a1e
Call this function to play a cutscene
{ m_waveShader.setParameter("time", dt); m_cutscene.fit(sf::FloatRect(m_game->m_player->m_car.getPos().x - 639, m_game->m_player->m_car.getPos().y - 363, 1280, 720), true); m_shaderSprite.setPosition(m_game->m_player->m_car.getPos().x - 639, m_game->m_player->m_car.getPos().y - 363); m_play = true; if (m_play == t...
1
81b88ca4e300feb04bba3d04b7294152
adde34eba707abdfb935a0893b188103
初始化票号、销售日期
var userName=getCookie("userName"); var operDate=getCookie("operDate"); $("#soperator").val(userName); $("#lrr").html(userName); $("#rq").html(operDate); $("#lrrq").html(operDate); $("#dinputdate").val(operDate); $("#entryDate").val(operDate); $.ajax({ url: "faCards!doinit", type: 'post', async:false, ...
1
9d3584e22d034df1d6dc3321ae6f883d
2ad192cef21aae95c8cabae5db7a0dc2
移除多个请求参数
function remove(params, items, callback) { if (!Array.isArray(items)) { items = [items]; } params.Objects = []; items.forEach((item) => { params.Objects.push({Key: item.key}); }); cos.deleteMultipleObject(params, function (err, data) { if (err) { console.log(e...
0
3c5f58ccc3c13e87f7fdcbc7fdcc60cc
385abca9a341957ba33ab20c02e71efb
设置司机室气流增大/减小按钮可选状态
namespace Motor.HMI.CRH380D.Controller [Export] public class CarComfortController : ControllerBase<CarComfortModel> public void SetTemperatureButtonEnable() { bool IsEnable = false; foreach (var value in ViewModel.TrainModel.AllCarModels) { if (value.I...
1
cef6daea7ed159b6739f7d16f7b7bb9a
793825e5c639ab55363ddb0bb6132603
Returns boolean value to tell if product is gift card or not
class Administration::Web::ProductType def gift_certificate? handle == Administration::Web::ProductType.gift_certificate_handle end
1
65fcc3f4fddbbba0f1a5b3874f3eaae1
8bda960c8ccebb5ffe71aa0d02d15fd3
Get all Snapshots for a vps
snapshot_list = [] page, per_page = 1, 10 response = self.volumeapi.list_snapshots_for_volume( id, page=page, per_page=per_page ) content = json.loads(response.content.decode("utf-8")) print(content) snapshot_list.extend(content["snapshots"]) t...
1
fcf168fd6f14123fca60896c36c3eaff
7dfe9ba6a63084c227ddb121ebdb1e39
Przycisk odpowiadający za eksport bazy danych do pliku
namespace WindowsFormsApplication6 public partial class FormDatabase : Form private void button_exportToTxt_Click(object sender, EventArgs e) { backgroundWorker_saveDbToTxt.RunWorkerAsync(); }
1
8c423c6197ef8873a45226bd38822dad
895d543640a6cb836cfec68192859180
Gets all petTypes.
public Collection<PetType> findPetTypes();
1
789cfd95914fce262f80fc50df0e165b
350ceb859e380c458637af6bd2a93d48
This method is to update an already existing markov chain nodelist : list a markov chain generated using makeNew() dataset : str a string to train the markov chain with updateV : boolean optional argument to update vocabulary Returns list The updated markov chain
def update_stats(x,mu,alpha,kappa,beta,dist):
0