query_id
string
corpus_id
string
query
string
code
string
label
int64
e3035e15d943658e6631dd39169b8258
458e7d6b6d84b96788b7107567321f11
Strips white space from left and right ends
def trim_sides(s) s = s.lstrip s = s.rstrip return s end
1
2b48be0ef566925a843e2d764c39ced7
eece26fb2f0547aa0a33867113973f3a
Calculate the minimal translation along the camera's z-axis required to bring all display objects into view.
const scale = this.computeScale(); if (isNaN(scale) || scale <= 0) { return { position: {x: NaN, y: NaN}, frustum: {bottom: NaN, left: NaN, right: NaN, top: NaN} }; } const gridWidth = this.grid.right - this.grid.left; const gridHeight = this.grid.top - this.grid.bottom; ...
0
c0f67bc92b8fb0dd24bb350254479630
ddb5f97cf02384c6bd83b8dffcc30d65
Get the ON DELETE mode
class ForeignKey extends AbstractAsset implements ConstraintInterface public function getOnDelete() { return $this->onDelete; }
1
10dcf7ba4ef0ca3947526e206ca08483
9b367f645b76702d13e953f8cd1a3810
The default constructor. Declared as private to disable instances of the class.
final class Path private function __construct() { }
1
761886ba0f93236a80e769670ba2dcff
e504a70001e70a286ffd96d5d8867fee
按鈕敲擊時發出選關音(不使用人聲)
public class UI_PatientFeedback : MonoBehaviour public void SoundClick() { if (SoundManager._SoundManager) { SoundManager._SoundManager.PlaySound("Click"); } }
1
13a057f1c8b7707cda5ae1246f93d148
5c47e82439c5a2ca722198034afa3423
Sets the XStream facade to use when marshalling objects.
xstream.alias("com.luntsys.luntbuild.remoting.BaseClearcaseAdaptorFacade", com.luntsys.luntbuild.facades.lb111.BaseClearcaseAdaptorFacade.class); xstream.alias("com.luntsys.luntbuild.remoting.BuildFacade", com.luntsys.luntbuild.facades.lb111.BuildFacade.class); xstream.alias("com.luntsys.luntbuild.remoting.Bui...
1
4a9b1fa1d25fd9ae50610c67795fad04
56a21ac60a12e636ac4cc4225e24511c
funktio, jolla voi säätään toistettavan kappaleen äänenvoimakkuutta.
@PUT @Path("/sijoittelu/{hakuOid}") @Produces(MediaType.APPLICATION_JSON) SijoitteluDto merkkaaSijoittelunAjetuksi(@PathParam("hakuOid") String hakuOid);
0
feec7d6012958dcaa8b3a2d784f3c58d
d2148039e9c87c3759e7ba8834076b33
给消防资源添加orgId
void orgAdd(Organization organization);
0
f81199735a35a4082d8a05bd085c3bfe
dee41206aa5e6df074d281c58fc04841
! @brief set oscillator ring-modulation for given voice
void _mixer_set_vibrato(int voice, int rate, int depth) { }
0
d84df010921680e87afc7dc2b4745c10
21517605d8053275aed863bcdc761772
批量读取数据与缓存对比并存入数据库
cacheMap.clear(); theLogger.debug(sql); DataBaseStorageService dataBaseStorageService = PlatformServiceHelper.findService(DataBaseStorageService.class); List<Object[]> cacheDataList = dataBaseStorageService.selectRecords(theLogger.getMessageFormat(sql)); List<JSONObject> cacheJSO...
0
854e4d41194a1f59de93c3d9bb1943aa
cee2288ecc448b3931f2bbfeb6ca4034
Cuenta el numero de cursos en la bbdd
sql = ''' SELECT COUNT(*) FROM course ''' number = select(sql) return number
1
af945f54fb8bfe498e76cad672ee7043
846f755a49264952d445b1de4169125a
Function to check if the course is active
if (course_name in self.taken): return False if (course_name in self.excluded): return False if (course_name in self.selected): return False return True
0
51e773750f5beba143f0717f49d5911e
2f293dbbbc99f48a05ba128435433533
分页获取数据列表-未发送
PageUtils queryUnReceivedPage(Map<String, Object> params);
1
3b66fb5682c6cc56074951699110839e
590d5fb2b9da4c8d6d0f718efb4b78d6
Instantiates the movement marker and hides all battle-related objects
{ curCommand = _comm; BattleSlot[] slots; switch (_comm.GetTargetType()) { case Command.Target.ENEMY: slots = bcm.GetEnemySlots(); for (int i = 0; i < slots.Length; i++) { slots[i].EnableMarker(); ...
0
00f7a392d3e3651ab5853123d24388b8
ebe595aec41bd5a8ffc8d02f1ab8cd9c
Metodo que setea el arreglo a ordenar.
class class_module_rating_sort_absolute implements interface_module_rating_sortalgo public function setElementsArray($arrElements) { $this->arrElements = $arrElements; }
1
16399bc9996b31af5da4314deba8d7f1
1a04f7870fa26fad7b91c10b54049b62
\brief Returns the string for the first format (used for the NAWS format)
function BMLT_FuncNAWSReturnFormat1( $in_meeting_id, &$server ) { return BMLT_FuncNAWSReturnFormat(1, $in_meeting_id, $server); }
1
5886fc1d3269f73e212e659daa230bd1
8b871a320044fb31bc01a46bde649825
using classmethod as alternative constructor
class Word: def __new__(cls, *args, **kwargs): print('Call __new__ method') return object.__new__(cls)
0
50d7514c89ab752ec0890f29d41cc4ec
d491676d3cf2d04c0694dc46ba731866
Validate time input
class dueDate private function checkTime() { if (!isset($this->submitTime['hour'])) { return false; } if (!is_numeric($this->submitTime['min']) || $this->submitTime['min'] < 0 || $this->submitTime['min'] > 59) { return false; } if (!is_numeric($this->submitTime['hour']) || $this->submitTime['hour...
1
ed061757aab22b5523f4f052ebb3c85e
dcc94947ec480567798c64a80f3825f9
Median einer Pareto-Verteilung berechnen.
{ double retval = 0; GenericDistribution * dist = DistributionManager::getInstance()->retrieve(iHandle - 1); if (dist != 0) { retval = dist->getMedian(); } return retval; }
0
7ee7fc294ed9cf50bf00289da18e2f0d
81135eb498dca6c50379ca498d30337e
终止老用户优惠活动任务
namespace Tuhu.C.Job.PromotionTask.Dal public static class PromotionDalHelper public static int ClosePromotionTaskJob() { using (var conn = new SqlConnection(DBConntionStr)) using (var cmd = new SqlCommand(@" UPDATE dbo.tbl_promotiontask SET TaskStatus = 2,...
1
0baabb2ad782c59a7417cf0dc3d947f2
42b399e235c15b4a86243ef8b16cc371
根据数据生成excel保存到服务器 返回保存地址
let today = moment().format('YYYYMMDD_HHmmss'); fileName = fileName + today + '.xlsx'; let relativePath = path.join(excelFolder, fileName); let fullPath = path.join(downloadDir, relativePath); relativePath = downloadHost + path.join('/', relativePath); let styleHeader = { fill: { p...
1
cf08a4401a7c5a2820b49c8e26b594e2
9c3b25c533aeff24661273aa1b6e44d0
Lists all Karaoke models.
class KaraokeController extends BaseController public function show($id) { }
0
af5f5e3b31c81e7849e65d0f9f65febc
c77213055a97e45d0f397fa69cabd433
Retourne la liste des dossiers de reservation
namespace BoVoyages.Controller class GestionDossier : Gestion public void ListerDossiers() { ListerColonnes(accesBDD, table); DataSet dataset = accesBDD.AfficherTout(table); if (dataset != null) { Menu.ImpressionTable(dataset); } ...
1
5f567695ff87a9afa5802ba90fe8e8e6
a027d1421f047a952ab9b1e556c2e415
获取所以第三方应用开发信息,只从数据库中取出一次,放入到分布式缓存(保证缓存的调用失败不影响业务流程)
String string = aCache.getAsString(Config.key_buyer_app); if (string==null) { return null; } else { ApplicationListData applicationList = new Gson().fromJson(string, ApplicationListData.class); return applicationList.getApplications(); } }
0
756b63c5f0558af3d48d031e625b78c1
03577116b1dce234fc9709b10bdcf72b
Hiển trị màn hình thông báo khi thắng
{ String chucNang = "Tăng may mắn"; lbLoiNoi.Text = chucNang; }
0
4e382542fdc7bf1ef1e97ff82420d5f9
7d0ff4cff406954cd43416fd0a8ed7c4
Devuelve el mensaje del correo.
public abstract class Mail public String getAsuntoMail() { return asuntoMail; }
0
872313a035bcd521b0e9368dee58a965
679baff9fca9c423892ce6b9ef61ae6e
Checks if the two string are equals even without accents
souple = False if word1 != '' and word2 != '': word1 = accent_remove(word1.lower()) word2 = accent_remove(word2.lower()) if word2[0] != word1[0]: souple = False elif ((word1 == word2) or (word2 == word1 + 's') or (word1 == word2 + 's') or (word2 == word1 + 'e') or (wo...
1
d266cf1b9bed29c509dc39ce2c009991
c2664bbf71fac67da686e11c68895ba4
Parse a IMDB directors list.
class ImdbRdfParser: def parse_movies(self): self._parse_list(self._MOVIES, self._parse_movie)
0
0f4eba39ef84ffd6d75b8ede4f54ce0e
a2df0ba01f95f20652dad570763e97db
Gets the credits from the server async.
WebTarget resource = creditTarget; resource = resource.queryParam("username", username); resource = resource.queryParam("password", password); resource = resource.queryParam("cmd", "credits"); return resource.request(MediaType.TEXT_PLAIN).get(String.class); }
0
95ef0f2911f3ab66275e8a5a51626047
1daa6c394d2b1679c06af611b8b73f21
These tests ensure that the implementation maps and reduces all of the instances in the passed-in collection.
int value = executor.mapReduce(shortItems, new RoundMapper(), new SumReducer()); assertEquals(10, value); value = executor.mapReduce(longItems, new RoundMapper(), new SumReducer()); assertEquals(45, value); }
1
84338c95b30da5adb7ee2a0ccfb3d82e
b254ce5efc5f242d1c35d169bb83572f
Reads the view's package property
public abstract class GuiViewLogic extends MetafacadeBase implements GuiView public ModelElementFacade getPackage() { return this.getSuperFrontEndView().getPackage(); }
1
00e7451b9a1a28e5a5d51831faea194e
4b5f4389bad8916b2fcb7ea8b160a8b6
Iterates over the tree in order. Generates a sequence of (key, value) pairs
namespace Library.Net.Collections [Serializable] public class BstDictionary<TBst, TTreeNode, TKey, TValue> : IDictionary<TKey, TValue> where TBst : BinarySortTree<TTreeNode, TKey>, new() where TTreeNode : BinaryTreeNode<TKey, TValue>, new() where TKey : IComparable<TKey> public IEnumerator<KeyValuePair<TKey, TV...
1
da79f21a0ddc0cff6ba6b823fdb6f91c
c50ea1e4acab841b1283b5c9040fc092
Gets the shelf id.
class ShelfI(plugin.Interface): def GetId(self): raise NotImplementedError
1
31ed80e5292a3448c27d2dfb45c60f64
34068b881526a6d240590ce7dc7b4ab1
ВОЗВРАЩАЕТ ИСПРАВЛЕННЫЕ КООРДИНАТЫ, ЕСЛИ ОНИ НЕКОРРЕКТНЫ.
namespace GeoFilials.Forms public partial class EditFilial : Form private string WorkWithDots(string dataIn) { string data = dataIn.Replace(',', '.'); data = Regex.Replace(data, @"\s+", ""); if (Convert.ToChar(data.Substring(0, 1)) != '.') { in...
1
0d2e201d095b3766206d8c5a8220ee2d
cbf747ccca71feb6a212b8f3168e672e
This method initialises the default gameBoard for tic tac toe.
class TTTBoard: def __init__(self): self.M = ["*","*","*","*","*","*","*","*","*"]
1
e9a06c4c5b480f95b84b306c6e1744a2
9819efda49b8753f142b8736dc4f6d95
returns n-tuples from l. e.g. tuples(range(4), n=2) -> [(0, 1), (1, 2), (2, 3)]
N = len(l) size = float(N) / n return [l[int(i * size):int((i + 1) * size)] for i in xrange(n)]
0
8f4b853e42dfae92e4ca36cb273c9d3f
5a140059a85de713919ef1ffd12818fb
This method performs actions in response to the Activate Customer Panel Button being pressed.
{ lblCustStatusValue.Text = "ACTIVE"; lblCustStatusValue.ForeColor = Color.Lime; cmdCloseOpenCustomer.Text = "Close customer"; lblBDayValue.Visible = true; lblIDCardNumValue.Visible = true; lblAddressValue.Visible = true; lblPos...
1
cd5bcb38eabfdf9033d1bd54ac142d1f
7da5065b986070bb13ac94a84bd51591
Подписка на сокет
namespace App3.Controllers [ApiController] [Route("n")] public class NamingController : ControllerBase [HttpGet("sub")] public async Task<string> Subscribe() { await _client.Subscribe("mysvc2", listener).ConfigureAwait(false); return "Subscribe"; }
1
4130c7b8670aff5cdcf88c43d73fedf2
05e77de5e51a5de0d6f2962fc89d1934
rolls four 6-sided dice and returns sum of largest three
class PcsController def d46 [d6,d6,d6,d6].sort[1..3].inject(:+) end
1
e266e22c4e92a996a6e551c914388845
3ce3ab2adad4d3d062da9fcaac9e133c
Write indicator section with arbitrary length.
cls = '' if vertical: rep = '<span class="u ns" data-glyph="&#x2500"> </span>' else: rep = '<span class="u ns" data-glyph="&#x2502"> </span>\n' self.chunks.append('<div class="{} sep"><pre>'.format(cls)) self.open(None, None) self.chunks.append(rep...
1
40a64504433fc754fda7dce7d49cd84e
7b7b1b3bcdbbb6ad7f9930267a356588
add heros to the map
export class HeroesMapComponent implements OnInit getHeroes(): void { this.heroService.getHeroes() .subscribe(heroes => { heroes .filter(hero => hero.location) .forEach(hero => { this.map.addMarker(hero.id, hero.location, hero.name); }); }); }
1
620cfa33d68bd0ef4b5bab6573e7eec2
25ef31c240aa8337d820fa75c954876b
计算生产n个产品需要多少燃料、拥有的燃料数量
public double calculateFor(int numberOfDelivers,int numberOfProducts);
0
c3ff442abb05b627a6ff85a68fc9ab6e
8b262008d405a916e8552fda5db14e9a
lookfor(board,piece) - This functions takes the 2D array that represents a board and finds the indices of all the locations that is occupied by the specified piece. The list of indices is returned.
void Pawn::findLoc(std::vector<Chess_Piece*>* board, int w){ }
0
4981781fe0b0d5d6011917d156cb8c43
70e1a70e525627f746396baf5a2502f4
Get the next batch from the queue, blocking as necessary. Returns: list: A list of dequeued items, in order. This list is always non-empty.
class Generator: def get_batch(self): batch = self._queue.get() return batch
1
b3d6888046a13af239d74fa2ffbbdfc7
001b84181248476fb1989f9c905a556e
returns the topmost element of the stack returns -1 if the stack is empty
int Stack::stackTop() { if (!stackEmpty()) return firstNode->data; return -1; }
1
01a02a31a79681a0145c705cc54dd60b
5e4df7f9fa79208b334de955e9be8f6e
Method for counting the score that is going to be added. Points are given according to the amount of rows that where removed.
{ indexOfCube.Clear(); int[] rows = new int[20]; foreach(Cubes i in savedCubes) { rows[((i.point.Y - startPos.Y) / gridSize)]++; } for(int i = 0;i<rows.Length;i++) { if (rows[i] == 10) ...
1
57ee00e5859eec67c8553c5fa788b58c
435efcbe745e35a95e9db3b5ecf6063e
Obtem o contador de reinicio de operacao.
public class NotifyThread public int getReset() { return reset; }
1
91a21ade6b227b955dea65e721d8ebaa
98241df69e3ae1d05b7964c72a9025b0
Add theme custom CSS from theme options
function theme_options_custom_css() { echo '<style type="text/css">'. theme_custom_styles() .'</style>'; }
1
ee05b0f77232422b4aeaef9f54ff4206
abfb7d1d172213cabb19dcaae18c1489
替换url中的参数或添加参数
var reg = new RegExp("(^|)" + param + "=([^&]*)(|$)"); var tmp = param + "=" + paramValue; if (url.match(reg) != null) { return url.replace(eval(reg), tmp); } else if (url.match("[\?]")) { return url + "&" + tmp; } else { return url + "?" + tmp; } }
1
e74621460534a51425ce1d7539bc340d
87d72a917248766392ac7f28a2934367
Sets the end portion of the OAI baseURL that is being used, for example 'provider'. The new providerBaseUrlEnding value
public class RepositoryManager public void setProviderBaseUrlEnding(String baseUrlEnding) { if (baseUrlEnding.startsWith("/")) dataProviderBaseUrlPathEnding = baseUrlEnding; else dataProviderBaseUrlPathEnding = "/" + baseUrlEnding; }
1
200f8ac1605c204b720f02bb988049aa
aad986146108c55a398660479eb2ae73
Play the vibration clip with the chosen force.
public class FFB : MonoBehaviour public void Vibration(int power,float time) { if (mGameSceneManager.SceneState != SceneState.GAME) return; if(power == 0 && time == 0f) { StopFFB(); return; } HitFFB(power, time); }
1
8663c0019f197cfc70d7202ffdd1bf26
97560752b93c9bcebbc92c754ae19ec6
Méthode permettant de récupérer le mode du thermostat
namespace MultithreadElevator.Avm.elevator.Concrete public class Elevator : IElevator public bool getMode() { return this.mode; }
0
788114c2195fd988e68e09c04e7f10c0
168f745c706c245c34bd1104a3f03a2e
Verifies the Activity properly handles a missing breadcrumb
final PlaceRequest brokenPerspectivePlace = DefaultPlaceRequest.parse( BreakablePerspective.class.getName() + "?broken=" + OPEN ); pollWhile( DEFAULT_SCREEN_NOT_VISIBLE ) .thenDo( new Runnable() { @Override public void run() { placeManager.goTo( brokenPers...
0
d52a296906fab8d8f8e43ac2c9b98c09
6f1fe30ec3311ad339b242c980e9363c
Outputs ordinal for number.
def ordinal(value): return str(value)
0
ca4d1471da58bfddff26660388ab478d
905e0ad563ef4d010e49d6295f3340ea
Sets the value for <b>gvfVersion</b> (Version of the GVF file) <p> <b>Definition:</b> Valid version of the GVF file </p>
void setVersion(String value);
1
21ff65158cc72a41d6d67d68e3a2c8a3
a8d3c8acc9eaac4ac51d34f1888e3381
获取比较值字符串
public class DetectInfoText extends AbstractModel{ public String getComparemsg() { return this.Comparemsg; }
1
672fbf542914ec97a2dd4316dcda59c1
773b907ac77d0aaf987bf181900ef41e
Envoie un message de login
class Chat extends Component{ componentWillMount(){ socket.emit('login', { id : this.props.user.id, username : this.props.user.login, mail : '@cpe.fr', usercolor:'' }); }
1
3458eac109aa1e91f252f32fece6ac05
12022f40b513ab65aa8109b1b21d9a67
Determine the final atomtypes from the white- and blacklists.
weights = [] count = 0 atom_atom = [] atom_rev = [] uni_inter = [] final_weigths = [] if decay_function == 'expo': for inter in atom_interactions: type_weight = (np.exp(-abs(inter[-2])/3), "{}-{}".format(inter[2], inter[1] + '_' + inter[-1]), inter[-2]) weight...
0
2e914cf84ef98e05c0cf2ca0570d6d92
1df20c3dcf1e3ff75e4e6f4cdfccb2e3
Creates multiple applications for use in test database.
class ApplicationsFixture extends TestFixture public function __construct() { $this->records = [ [ 'id' => 1, 'name' => 'Profiles', 'alias' => 'user', 'template' => 'default', 'app_group' => 'communi...
1
c4becceb6ce25432f18ceffb1f0c86ab
72822aa851273367723c66f4ff9dfa2e
Disable output on AMUX-pin.
{ u16 temp; mxc_request_iomux(MX31_PIN_LD0, OUTPUTCONFIG_FUNC, INPUTCONFIG_FUNC); mxc_request_iomux(MX31_PIN_LD1, OUTPUTCONFIG_FUNC, INPUTCONFIG_FUNC); mxc_request_iomux(MX31_PIN_LD2, OUTPUTCONFIG_FUNC, INPUTCONFIG_FUNC); mxc_request_iomux(MX31_PIN_LD3, OUTPUTCONFIG_FUNC, INPUTCONFIG_FUNC); mxc_request_iomux(MX31...
0
11a48c42c3c523bf66a0633694c934b0
c6546e88eac828e2d6cfc12f29bfdb8b
laço principal do jogo em modo texto
print('F O R C A') receberPalavras() palavraSecreta = sortearPalavra() palpite = '' desenhaJogo(palavraSecreta,palpite) while True: palpite = receberPalpite() desenhaJogo(palavraSecreta,palpite) if perdeuJogo(): print('Voce Perdeu!!!') break ...
1
aa2a50c0e315611fd52d284e0d02b5ce
d1adc868ac1a031fe84886bce0d91d67
Check that we refuse to transform a Schedule to use OpenCL if any of the kernels use module data.
_, invoke = get_invoke("single_invoke_three_kernels.f90", API, idx=0, dist_mem=False) schedule = invoke.schedule schedule.children[0]._loop_type = "wrong" ompl = GOceanOMPLoopTrans() with pytest.raises(TransformationError) as err: ompl.validate(schedule.children[0]...
0
e95383f234765a1839f33d4dab717e3e
2b413eeedefa86679f169179943f93fb
This function converts a number _n_ into an array of boolean values, where the maximum bit length is _N_.
max_dec_with_n_bits = sum(2 ** np.arange(0, n)) if dec <= max_dec_with_n_bits: new_dec = deepcopy(dec) decreasing_pow_array = np.arange(n-1, -1, -1) bit_array = np.zeros((1, n)) bit_index = 0 for pow_val in decreasing_pow_array: if (new_dec / (2 ** pow_val)) >= 1: bit_array[0][bit_index] = 1 new_...
1
f0fd6f599cc989186a2885dc0826c789
406476ef117d47927292289c377c9914
Add human-readable string representations to the field.
if fmt is None: if field == "temperature": fmt = ".0f" elif field == "energy": fmt = ".3g" return super().get_field_string(field, fmt)
1
48569346a5664adb598c0cfa3f171897
291658863452566c5ae5e833222e08f9
used for text fields with numeric input, only allows integer numeric characters
namespace RemoteClient [Serializable()] public partial class ProcStatic public static void TextBoxIntegersOnly(KeyPressEventArgs e) { if (!char.IsDigit(e.KeyChar) && !char.IsControl(e.KeyChar)) { e.Handled = true; } }
1
3431a6448bc6facacba14935e201d9e4
fcc78ff84ca45b983e40edf4597a805e
Remove the ladder that out of screen and add ladder at the same time.
{ GameObject block = null; int range = 0; if (MainManager.StepComplications * 2 < MainManager.Interface.NumStep) block = Instantiate(StairwayPrefabs[0], StairwayCreater.transform); else if (MainManager.StepComplications * 3 < MainManager.Interface.NumStep) { range = Random.Range(0, 4); block = Insta...
0
8043d8ae7ecc29a09d20a97da303879c
cc1a671de667e492d458d499e8f472b1
Returns Teller id
if (!$this->GetIsClassLoaded()) { throw new SWIFT_Exception(SWIFT_CLASSNOTLOADED); return false; } return $this->_dataStore['ticketwatcherid']; }
0
b977b552e232c3e57a399b22016a1d87
18228292340d3d27fad28ad34f96e7cc
add a new uploaded file to the field
$f = $this->get_files_array($fieldname, $rowindex); if ($f['name'] == '') return ''; move_uploaded_file($f['tmp_name'], $f['suggest_path']); $rowid = $this->insert_row(array('filename'=>$f['name'], 'size'=>$f['size'], 'type'=>$f['type'], 'path'=>$f['suggest_path'], 'create_da...
1
e50e19f4e4032500451f15d164c61371
bb9b0360284db1087c865e7dd48a1aef
#this function loop through any dataframe and create a frequency table for every factor
freq_tb <- function(in_df) { output <- cbind(Level=unlist(attr(table(univ$lrnval),"dimnames")), Freq=table(in_df), CumFreq=cumsum(table(in_df)), Pct=prop.table(table(in_df)), CumPct=cumsum(prop.table(table(in_df))) ) output <...
0
a51e38f7706dd3dd015e6c8aa30822dd
350b60e1131383b62b6219892591f027
连续梁参数的处理函数
changdujiancha_q=float(self.l_Input.get()) waijiafenbuli=self.q_Input.get() zuoyongweizhi1=self.x1_Input.get() zuoyongweizhi2=self.x2_Input.get() if (waijiafenbuli=="" or zuoyongweizhi1=="" or zuoyongweizhi2==""): self.q_Input.delete(0,END) self.x1_Input.d...
1
e496a56931053d6fe2b05f184ae84208
584cb7f0098e077bc914b33a0d9dc372
Analyze the TX1 elements. true if the analyze must continue.
TResult Analyze(While exp);
0
4847845e10561223636cf8d62c03966e
4986cd7a29655ba24e7a8c93ef477a49
<p>Initializes the attributes of a composition event.</p> <div id="section_5"><span id="Parameters"></span><h6 class="editable">Parameters</h6> <dl> <dt><code>typeArg</code></dt> <dd>The type of composition event; this will be one of <code>compositionstart</code>, <code>compositionupdate</code>, or <code>compositionend...
@Generated( value = { "http://www.jooq.org", "jOOQ version:3.7.3" }, comments = "This class is generated by jOOQ" ) @SuppressWarnings({ "all", "unchecked", "rawtypes" }) public class CompositionHistoryRecord extends TableRecordImpl<CompositionHistoryRecord> implements Record10<UUID, UUID, UUID, Boolean, Boolean,...
0
1b54209b793a3d5c0a891a59386ebae4
267bef056c089a481d0a41823da8b44c
Metoda implementujaca algorytm Edmondsa-Karpa wyszukiwania maksymalnego przeplywu w sieci przeplywowej.
namespace Przeszukiwanie_grafu class Algorytm1 public List<int> Uruchom(wierzcholek[] W) { W[0].Odwiedzony = true; W[0].Dr_do_pkt = 0; int aktualny = 0; int i; List<int> Sciezka = new List<int>(); List<int> Otwarte = new List<int>(); ...
0
6275ee94d19d0333a9fd76d9a0b08502
8e3acb0899afce3cae3382568fe183e4
Verifica se o jogador que possui este número pertence ao time
for(int i = 0; i<total; i++){ if(team[i].getId() == p.getId()){ return true; } } return false; }
1
176f9adb4760483a29cd4b3e1f4f3bcb
4bd8dbdbf58f8d8ff1fd4bd68fdd27a7
Gets estimated z-y cross-coupling error.
public class KnownHardIronAndFrameMagnetometerLinearLeastSquaresCalibrator implements KnownHardIronAndFrameMagnetometerCalibrator<FrameBodyMagneticFluxDensity, KnownHardIronAndFrameMagnetometerLinearLeastSquaresCalibratorListener>, UnorderedFrameBodyMagneticFluxDensityMagnetometerCalibra...
0
31a63c4e36fc53e5293aeecc9a56f8ab
1ea0fa5eb9e78c25e11fe257cded1a0a
Check to see if SecretsManagerKey property is set
namespace Amazon.CodePipeline.Model public partial class AWSSessionCredentials internal bool IsSetSecretAccessKey() { return this._secretAccessKey != null; }
0
b97abeab887ca23d92c3fea32c90e14e
45152bf0f0ad35c09c3ab4657fc09535
사료 떨어지는 타이머함수
public class EatController : MonoBehaviour private IEnumerator Eating(RoastController meatController) { yield return new WaitForSeconds(eatingTime/2); meatController.ChangeEatingEmage(); yield return new WaitForSeconds(eatingTime / 2); meatController.EatObject(); isEating = f...
0
4603faccd6fc4156bc79eb9151426696
72e65acbc5d3fe27887c2d35fc9a80cd
单个字符的高度
public class Font extends Texture implements IDisposable public float getCharHeight() { return mCharHeight; }
1
4365e4469c73730a6ec010994d45ecc7
1d5867af9fe057f50a49953a72e470c6
Handler to move the clicked-marker to the end of the longest track.
if ((marker.options.latEnd == marker.options.lat) && (marker.options.lonEnd == marker.options.lon)){ return; } var latlngStart = L.latLng(marker.getLatLng()), latlngEnd = L.latLng(Number(marker.options.lat), Number(marker.options.lon)); marker.options.latEnd = marker.options.lat; mar...
1
42ba47801199e335879dda18efdde969
8d281bd4ccdb5cf7b7a2b20d0d35d5a8
@brief load texture atlas from file and convert it to an OpenGl texture array
bool LoadTGATexture(const char *szFileName, GLenum minFilter, GLenum magFilter, GLenum wrapMode) { GLbyte *pBits; int nWidth, nHeight, nComponents; GLenum eFormat; pBits = gltReadTGABits(szFileName, &nWidth, &nHeight, &nComponents, &eFormat); if(pBits == NULL) return false; glTexParameteri(GL_TEXTURE_2D, GL_TEX...
0
3396dead7f0a3abac6c94f4b06b03a8b
8e9d030a8ec1d6b085a00c2e790c7b90
Unsets the value of the '{@link org.bimserver.models.ifc2x3.IfcHygroscopicMaterialProperties#getLowerVaporResistanceFactor <em>Lower Vapor Resistance Factor</em>}' attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
void unsetVaporPermeability();
0
a470004640ee3934416554a0261106a3
6b607c8aef0ff28bca05bf0495aadd39
Create a Trust Relationship.
@Singleton public class RelationManagerImpl implements RelationManager @Override public Relation buildTrustRelation( RelationObject source, RelationObject target, RelationObject trustObject, Set<Permission> permissions ) { try { if ( source != ...
1
cc56047ec6e8ef1b4e727430ddd19918
f732691a63ba734973461808250e13be
Gets the List of root notes that the currentPerson is authorized to view for this EntityId and NoteTypes
{ if (this._notesForDisplay == null) { RequestContext requestContext = new RequestContext(); requestContext.Filter.Add(new FilterItem(ProjectNoteFields.Fields.ProjectId, AutotaskCorporation.Core.Configuration.ComparisonType.Equals, this.ID)); requestContext.Filter.Add(new FilterItem(ProjectNoteField...
1
e3311bacbc6166ced95049ce6d254b18
a155c7066fc586fbfacfcc4c9dabef0a
puts a message at the front of the queue to be heard immediately (or as soon as current speech finishes)
public class Director : MonoBehaviour public void Say(string w, string c, float s = 0.1f, bool k = true) { if (behaviour_queue.Count == 0) { GameObject.Find("GameController").GetComponent<GameController>().EnterWork(); } behaviour_queue.Enqueue(new Behaviour(BehaviourType.Say, new SayBehav...
0
faaa348e159421b6c4522a9ec49631ef
5be0c2fa7fbd748242bce1a4b5367c70
设置战斗中获得的英雄列表
function heroVoApi:setServerWarHeroList(index,heroList) if index then self["serverWarTroop"..index]={0,0,0,0,0,0} if heroList then for k,v in pairs(heroList) do if v then self["serverWarTroop"..index][k]=v end end end end end
1
86594e8c691928c8d3a7e3f28981eefd
edbcbea065802602031904f357463e4b
Returns the requested block as specified by block number. Returns None if it is not present in the db.
class BlockAllocationTable: def GetDBEntryForBlock(self, block_number): return self.data_blocks[block_number]
0
662cd2e33f37da15f38b2ec362788ec5
377f94366b99ec5571fa890df5e14d6d
Método que obtiene todos los grupos musculares registrados en la BD
public class GrupomuscularBCLImpl implements IGrupomuscularBCL @Override public InternalResultsResponse<Grupomuscular> fetchGrupomuscularsById( InquiryGrupomuscularRequest inquiryGrupomuscularRequest) { return getGrupomuscularDAC().fetchGrupomuscularById(inquiryGrupomuscularRequest); }
0
1eb1462d0ba54bdf6d8bb0d1cea6f12a
2a6e7a8b1642c601220eccccacdcac3b
获取用户所有联系人信息(后台使用)
List<Map<String , Object>> getAllContactsMap(int id);
1
34015ad1e10dce3d19610dc3b85e42e2
12cb10ac37adcc23fc6738146e5ced2a
Supprime un fichier d'une publication
{ if (file_exists(public_path('./uploads/') . $post->image)) { unlink(public_path('uploads') . '/' . $post->image); } $post->delete(); return redirect()->route('home')->with([ 'success' => 'Article supprimé' ]); }
1
e1dde197c8f4b2a52514d1271a923013
7c8d3bc95b76fe464aa905e06e2d48f2
This routine performs the difference of two matrices
int size = (result->rows)*(result->cols); double *rd = result->data; double *md = mat->data; __m256d a; __m256d zero = _mm256_setzero_pd(); #pragma omp parallel for private(a) for(int i = 0; i < size/16 * 16; i+=16){ a = _mm256_loadu_pd(md+i); _mm256_storeu_pd(rd + i, _mm256_sub_pd(z...
0
95fa9aea3664cbdbf072ba82d7628981
9bfec897e8c7196424c3b5632283b996
POST /cat_ppr_par_partida_genericas
@part_configuration = PartConfiguration.new(part_configuration_params) if @part_configuration.save render json: @part_configuration, status: :created, location: @part_configuration else render json: @part_configuration.errors, status: :unprocessable_entity end end
1
33611a1d3a85ce67a7610aafd61aaa31
6cd0fad47f7910bbbc61e24e2e038021
二维码生成图
{ $text = $this->request->get('text', 'hello world'); $size = $this->request->get('size', 250); $padding = $this->request->get('padding', 15); $errorcorrection = $this->request->get('errorcorrection', 'medium'); $foreground = $this->request->get('foreground', "#ffffff"); ...
1
1bac7b8d8fe28e5aced210f73afc304b
fa44c813032738931385139a9fa840cc
Needs dynamic renderer.
class DMSimScene(SimScene): def _create_renderer(self, sim: Any) -> DMRenderer: return DMRenderer(sim)
1
106f68963893bb8237081c43cc402351
04cc9d3d2d7b5d1ea38ae4874b219843
Binary Split
struct Splits *trees = new Splits(); ThreadedBST *left = NULL, *right = NULL; if(k == key){ if(rightThread != true) trees->right = rightChild; trees->left = this; if(rightThread == false){ ThreadedBST *leftMostOfRight = leftMost(rightChild); leftMostOfRight->leftChild = NULL; } rightThread = tru...
1
017bf8e57bd540c887470e343f86c086
1ccc976bd3dba438b725746ada51a330
Use reflection to instantiate the right Fetcher at runtime.
{ foreach(Type type in _fetcherAssembly.ExportedTypes) { if(type.GetInterface(typeof(ITaskFetcher).FullName) != null) { return _fetcherAssembly.CreateInstance(type.FullName) as ITaskFetcher; } } t...
1
350235c234e011f7123f9ed192ff1011
8e1d9784798d0170c74d009b2e7b6b19
Initializes the MCC body/brain coevolution experiment by reading in all of the configuration parameters and setting up the bootstrap/initialization algorithm.
namespace SharpNeat.EvolutionAlgorithms public class MCCAlgorithmContainer<TGenome1, TGenome2> : IMCCAlgorithmContainer<TGenome1, TGenome2> where TGenome1 : class, IGenome<TGenome1> where TGenome2 : class, IGenome<TGenome2> public void Initialize(IGenomeEvaluator<TGenome1> agentFitnessEvaluator, ...
1
f4ee65a6d1ac9c3e837ed24969a93437
8bcd2ede68b1e90eedd4ebe7631ebb52
jitter the laser width randomly between two points
public class Behaviors : MonoBehaviour Vector3 Jitter(Vector3 wanderpoint) { Vector3 jitter = Random.onUnitSphere; jitter.x *= XForce; jitter.y = 0; jitter.z *= ZForce; return (wanderpoint + jitter); }
0
2b73af1777cfd90d98cbe37e1f4f4837
dd2dc7a5c53aab91a4ed68470d5fed81
Calculate the initial capacity of a map, based on Guava's [com.google.common.collect.Maps.capacity](https://github.com/google/guava/blob/v28.2/guava/src/com/google/common/collect/Maps.java#L325) approach.
fun mapCapacity(expectedSize: Int): Int = when { expectedSize < 0 -> expectedSize expectedSize < 3 -> expectedSize + 1 expectedSize < INT_MAX_POWER_OF_TWO -> ((expectedSize / 0.75f) + 1f).toInt() else -> Int.MAX_VALUE }
1
e165d6168f66702c808c3af1637bfde8
aeafe3154e3a1a7c9dbe80759a8d7a12
Get 证书可配置域名数量。 注意:此字段可能返回 null,表示取不到有效值。 注意:此字段可能返回 null,表示取不到有效值。
req?: DescribeDomainCountInfoRequest, cb?: (error: string, rep: DescribeDomainCountInfoResponse) => void ): Promise<DescribeDomainCountInfoResponse> { return this.request("DescribeDomainCountInfo", req, cb) }
1
1517d59323e27d57093af3439a696726
5135529df2e75c8f9d29e114b3b6597c
This function takes a pointer to a struct containing the window layouts and then initilizes them with the terminals current screen size
PUBLIC bool WINDOW_Init() { WINDOW_LoadBackground(); dword height = SVGA_GetHeight(); dword half_height = height/2; dword width = SVGA_GetWidth(); dword half_width = width/2; screen_size.height = height; screen_size.width = width; WINDOW_Init(0, 0, half_width, 0, half_height); WINDOW_Init(1, 0, half_width, hal...
0