text
stringlengths
0
30.5k
title
stringclasses
1 value
embeddings
listlengths
768
768
Java of course. ``` In all these cases you need short-circuiting, so that the RHS is only evaluated if the LHS dictates that it should be. In such cases there's no point comparing performance with alternative code that's wrong!
[ 0.07553024590015411, 0.3427755832672119, -0.38490891456604004, -0.14167965948581696, 0.020611008629202843, -0.443715363740921, 0.37863895297050476, -0.09963542968034744, -0.12772247195243835, -0.45817041397094727, -0.15568599104881287, 0.5191099643707275, -0.3223508894443512, -0.2577069997...
What is the difference in C# between `Convert.ToDecimal(string)` and `Decimal.Parse(string)`? In what scenarios would you use one over the other? What impact does it have on performance? What other factors should I be taking into consideration when choosing between the two? From [bytes.com](http://bytes.com/forum/th...
[ 0.174172505736351, -0.03974610194563866, 0.11431673914194107, -0.025974266231060028, -0.20897848904132843, -0.050333037972450256, 0.028005355969071388, -0.10667108744382858, 0.118468277156353, -0.47065648436546326, -0.15336759388446808, 0.5862894654273987, -0.2420123815536499, -0.180588766...
For Convert.ToDecimal(string), > Decimal.Parse is called internally. > > > Morten Wennevik [C# MVP] Since Decimal.Parse is called internally by Convert.ToDecimal, if you have ***extreme*** performance requirements you might want to stick to Decimal.Parse, it will save a stack frame.
[ -0.07940161228179932, 0.08170193433761597, -0.003819640027359128, -0.054527267813682556, -0.14532631635665894, 0.19572271406650543, 0.46189936995506287, -0.14427126944065094, -0.23374591767787933, -0.479042649269104, 0.03976193442940712, 0.16177979111671448, -0.06244863569736481, -0.034987...
How do I call an external command within Python as if I'd typed it in a shell or command prompt? Use the [`subprocess`](https://docs.python.org/library/subprocess.html) module in the standard library: ```py import subprocess subprocess.run(["ls", "-l"]) ``` The advantage of [`subprocess.run`](https://docs.python.org...
[ -0.13240866363048553, 0.08174286782741547, 0.37378913164138794, -0.07160703837871552, 0.2289074957370758, 0.11395888775587082, 0.018649322912096977, -0.2916055917739868, -0.5122280120849609, -0.5853633880615234, -0.4303922653198242, 0.5833051800727844, -0.08237028121948242, 0.0235217325389...
for some helpful recipes. On Python 3.4 and earlier, use `subprocess.call` instead of `.run`: ```py subprocess.call(["ls", "-l"]) ```
[ 0.009658010676503181, 0.06174423173069954, 0.09322226047515869, -0.08009830117225647, 0.3049665093421936, 0.2600586414337158, 0.17267577350139618, 0.1261025071144104, -0.16002975404262543, -0.378081738948822, -0.6781619787216187, 0.2816694676876068, -0.5229255557060242, -0.2445287257432937...
Using Windows Server 2003 in a multi-user environment (via Remote Desktop, using it as an application server), how to mount a (preferably encrypted) volume in a way, that won't show up on any other user's desktop? Tried, and failed approaches: * tweaking user rights -display of mounted volume can not be changed. * Be...
[ -0.2669602930545807, 0.09536156058311462, 0.4606660306453705, 0.4311314821243286, -0.1696842759847641, -0.3768279552459717, 0.28813549876213074, -0.07992883026599884, -0.3788411319255829, -0.4140072464942932, -0.1481170803308487, 1.083938717842102, -0.3406454920768738, 0.07470158487558365,...
secure: 1. hide access to certain drive letters based on group policy. Not very secure, easy to workaround. 2. Don't mount a seperate volume: use NTFS encryption and simply set security permissions on certain folders. Is there any particualr reason it has to be an entire drive? If you're trying to avoid allowing the ...
[ 0.12953749299049377, -0.047867994755506516, 0.2936474680900574, 0.1949976235628128, 0.03247695416212082, -0.5808512568473816, 0.3187177777290344, -0.14288710057735443, -0.11903048306703568, -0.4550471305847168, -0.36957237124443054, 0.7610993981361389, -0.15657618641853333, -0.079824425280...
volumes) that other users cannot access, store the files on a remote server. That way local administrators on the application server cannot arbitrarily access other peoples folders. (Unless they have Domain Admin or Enterprise Admin rights) You can set up a single big network drive and have different user folders on it...
[ 0.19437122344970703, 0.1861654371023178, 0.6399372816085815, 0.5227027535438538, 0.08520235866308212, -0.2992120683193207, -0.04426365718245506, -0.04260444641113281, -0.6966059803962708, -0.6749864816665649, -0.21706148982048035, 0.4243152141571045, -0.19996923208236694, 0.654518306255340...
I've run into what appears to be a variable scope issue I haven't encountered before. I'm using Perl's CGI module and a call to DBI's do() method. Here's the code structure, simplified a bit: ``` use DBI; use CGI qw(:cgi-lib); &ReadParse; my $dbh = DBI->connect(...............); my $test = $in{test}; $dbh->do(qq{INSER...
[ 0.2818244397640228, 0.21589624881744385, 0.1666206419467926, -0.3073781728744507, 0.027451414614915848, -0.0897810086607933, 0.4443962275981903, -0.34795787930488586, 0.17096969485282898, -0.5182021856307983, -0.1727517694234848, 0.4584050178527832, -0.3474600911140442, 0.15033672749996185...
how the CGI module's ReadParse() function assigns scope to the %in hash, but I don't know Perl scoping well enough to understand why %in is available at the top level but not from within my do() statement. If someone does understand the scoping issue, is there a better way to handle it? Wrapping all the %in references...
[ 0.3199528157711029, 0.08545311540365219, 0.30410435795783997, -0.07308032363653183, 0.022694040089845657, -0.156376451253891, 0.16577395796775818, -0.2677692472934723, -0.06417610496282578, -0.3411526679992676, 0.09213162213563919, 0.46093201637268066, -0.36046135425567627, -0.068793021142...
CGI 3.20, and DBI 1.52. Thank you in advance to anyone reading this. @Pi & @Bob, thanks for the suggestions. Pre-declaring the scope for %in has no effect (and I always use strict). The result is the same as before: in the db, col1 is null while cols 2 & 3 are set to the expected value. For reference, here's the Read...
[ 0.2985230088233948, 0.08271101862192154, 0.2614755630493164, -0.3255772888660431, -0.1620396226644516, -0.15991322696208954, 0.16036531329154968, -0.15374541282653809, -0.14728717505931854, -0.3063170909881592, -0.11438480019569397, 0.628302812576294, -0.3762201964855194, 0.053092811256647...
handle that: ``` sub ReadParse { local(*in); if (@_) { *in = $_[0]; } else { my $pkg = caller(); *in=*{"${pkg}::in"}; } tie(%in,CGI); return scalar(keys %in); } ``` I guess my question is what is the best way to get the %in hash within the context of do()? Thanks again! I hope...
[ 0.34610071778297424, 0.14548350870609283, 0.30936580896377563, -0.12126193940639496, 0.22797797620296478, -0.14220517873764038, 0.4184410572052002, 0.03609639033675194, 0.014297944493591785, -0.5587419867515564, -0.10231339931488037, 0.6950833797454834, -0.2817419469356537, 0.2727891802787...
use CGI::ReadParse() but in this case I thought it was best to stick to how [the CGI.pm documentation has it](http://search.cpan.org/src/LDS/CGI.pm-3.42/cgi-lib_porting.html) exactly. Per the DBI documentation: Binding a tied variable doesn't work, currently. DBI is pretty complicated under the hood, and unfortunately...
[ 0.4347071051597595, 0.2119169384241104, 0.49292513728141785, 0.13267354667186737, -0.2413615733385086, -0.6348126530647278, 0.38237008452415466, -0.2910546064376831, 0.025306714698672295, -0.35269585251808167, -0.14612218737602234, 0.4463357627391815, -0.5218887329101562, 0.393914997577667...
What is the best C++ IDE or editor for using on Windows? I use Notepad++, but am missing IntelliSense from Visual Studio. I've found the latest release of NetBeans, which includes C/C++ support, to be excellent. <http://www.netbeans.org/features/cpp/index.html>
[ 0.011924246326088905, 0.021278511732816696, 0.22923971712589264, 0.060936544090509415, -0.021753689274191856, -0.08051104843616486, -0.3215526342391968, 0.20780359208583832, -0.2464989572763443, -0.7283686995506287, -0.0699048861861229, 0.6137127876281738, 0.050144609063863754, -0.15548357...
The scenario is this We have two applications A and B, both which are running in separate database (Oracle 9i ) transactions Application A - inserts some data into the database, then calls Application B Application B - inserts some data into the database, related (via foreign keys) to A's data. Returns an "ID" to App...
[ 0.04991864785552025, 0.16041117906570435, 0.15797114372253418, 0.17234688997268677, 0.26451465487480164, 0.1090935543179512, -0.14559276401996613, -0.43364691734313965, -0.06601009517908096, -0.16322994232177734, -0.16007351875305176, 0.3971782326698303, -0.35017991065979004, 0.16150240600...
if anything goes wrong. How would you approach this problem, with minimal refactoring of the code. Surely this kind of this is a common problem in the SOA world? ------ Update -------- I have not been able to find anything in Oracle 9i, however Oracle 11g provides [DBMS\_XA](http://www.morganslibrary.org/reference/d...
[ 0.175744891166687, -0.015212523750960827, 0.29218167066574097, 0.03596939519047737, 0.015272959135472775, -0.04046254977583885, 0.2804524004459381, -0.234237939119339, -0.231118306517601, -0.5519568920135498, -0.25978630781173706, 0.6662710309028625, -0.39926469326019287, -0.17780992388725...
Application C acts as the coordinator. C signals A and B to ask if they're ready to commit. A and B do their processing, and respond to C with either a "ready" or a "fail" reply (note that there should be a timeout on C to avoid an infinite wait if one process hangs or dies). If both reply ready then C tells them to co...
[ 0.06405817717313766, 0.007698654662817717, 0.746845543384552, 0.23391412198543549, 0.290804386138916, 0.17375068366527557, 0.04105006903409958, -0.39917027950286865, -0.5104142427444458, -0.3145120143890381, -0.7043313980102539, 0.4535956084728241, -0.31308671832084656, -0.0584282204508781...
be an issue). Oracle's read consistency would probably prevent this from being allowed, since app A's transaction will begin before app B. Just a warning.
[ 0.1095292866230011, 0.06887087225914001, 0.4815570116043091, 0.058967627584934235, 0.1684616208076477, -0.09807391464710236, 0.4125343859195709, -0.047955356538295746, -0.09788288921117783, -0.22914749383926392, -0.36335939168930054, 0.49575603008270264, -0.36287444829940796, -0.0116647593...
I frequently use `git stash` and `git stash pop` to save and restore changes in my working tree. Yesterday, I had some changes in my working tree that I had stashed and popped, and then I made more changes to my working tree. I'd like to go back and review yesterday's stashed changes, but `git stash pop` appears to rem...
[ 0.509380042552948, 0.2580417990684509, 0.08104821294546127, -0.05546621233224869, 0.295669823884964, 0.20314571261405945, 0.3748784363269806, -0.19645391404628754, -0.32300519943237305, -0.8105338215827942, -0.10885629057884216, 0.6275655031204224, -0.1720544397830963, 0.26630720496177673,...
pop`. I know that the commit is still in my repository somewhere, but I don't know what it was. Is there an easy way to recover yesterday's stash commit reference? Once you know the hash of the stash commit you dropped, you can apply it as a stash: ```bash git stash apply $stash_hash ``` Or, you can create a separa...
[ 0.3291686177253723, 0.28869399428367615, 0.44123318791389465, 0.08086438477039337, 0.18759700655937195, -0.26908811926841736, 0.09946030378341675, 0.26181861758232117, -0.49783411622047424, -0.4178870618343353, -0.17004723846912384, 0.8790809512138367, -0.3027353286743164, 0.32997965812683...
hash value printed by `git stash pop` on screen](https://stackoverflow.com/questions/89332/recover-dropped-stash-in-git/7844566#7844566) (thanks, Dolda). Otherwise, you can find it using this for Linux, Unix or Git Bash for Windows: ```bash git fsck --no-reflog | awk '/dangling commit/ {print $3}' ``` ...or using P...
[ -0.010730454698204994, 0.2775522470474243, 0.4433644413948059, -0.018567444756627083, 0.03280472010374069, -0.11747248470783234, 0.14196151494979858, 0.12600316107273102, -0.4011804461479187, -0.542099118232727, -0.0013402714394032955, 0.6081622242927551, -0.0882137343287468, 0.10323003679...
to pass that list to `gitk`: ```bash gitk --all $( git fsck --no-reflog | awk '/dangling commit/ {print $3}' ) ``` ...or see [the answer from emragins](https://stackoverflow.com/questions/89332#34666995) if using PowerShell for Windows. This will launch a repository browser showing you *every single commit in the r...
[ 0.009696521796286106, -0.07552036643028259, 0.2873050272464752, 0.21421058475971222, 0.05360257998108864, -0.3550887405872345, 0.32142072916030884, 0.004853439051657915, -0.47667837142944336, -0.820245623588562, -0.3572066128253937, 0.6475258469581604, -0.24250750243663788, 0.1470931917428...
will only be in this form (starting with "WIP on") if you did not supply a message when you did `git stash`.
[ 0.4840065836906433, -0.10496939718723297, 0.4019871652126312, 0.00976486410945654, 0.1603207290172577, -0.22013364732265472, 0.5779387950897217, 0.20419122278690338, 0.03371994569897652, -0.46997979283332825, -0.48854684829711914, 0.1762881577014923, -0.18746092915534973, -0.19253395497798...
Has anyone been able to get a variable record length text file (CSV) into SQL Server via SSIS? I have tried time and again to get a CSV file into a SQL Server table, using SSIS, where the input file has varying record lengths. For this question, the two different record lengths are 63 and 326 bytes. All record lengths...
[ 0.37713703513145447, 0.25851714611053467, 0.2317451685667038, 0.2063545137643814, -0.06046690046787262, -0.1721813678741455, 0.2007584422826767, -0.006007468327879906, -0.7947238683700562, -0.6545882821083069, 0.020023444667458534, 0.4014820158481598, -0.22202938795089722, 0.17541888356208...
this has been reported as a bug. I have tried several workarounds. Most have been where I try to write custom code to intercept the record and I cant seem to get that to work as I want. I had a similar problem, and used custom code (Script Task), and a Script Component under the Data Flow tab. I have a Flat File Sourc...
[ 0.40598350763320923, 0.15624620020389557, 0.2621685564517975, 0.10542706400156021, 0.29671284556388855, -0.04831355810165405, 0.14942146837711334, 0.10823969542980194, -0.3828638195991516, -0.5302410125732422, 0.20742167532444, 0.260854035615921, -0.3244282007217407, 0.18256866931915283, ...
issue.
[ -0.3436424732208252, -0.22370529174804688, -0.04770179092884064, -0.1390600949525833, -0.4051094055175781, 0.5182002782821655, -0.3109857141971588, -0.2359110713005066, -0.15687930583953857, -0.05343484506011009, -0.46139830350875854, 0.17534267902374268, 0.027516987174749374, -0.157469555...
Since Rails is not multithreaded (yet), it seems like a threaded web framework would be a better choice for a Facebook application. (reason being is cuz each Rails process can only handle one request at a time, and facebook actions tend to be slow, because there is a lot of network communication between your app and fa...
[ 0.4006968140602112, -0.04063994437456131, -0.06567148119211197, 0.13907811045646667, -0.16025832295417786, -0.034656304866075516, 0.3267701268196106, -0.23578192293643951, -0.09542348235845566, -0.4266417324542999, 0.3750922977924347, 0.43684160709381104, -0.19711443781852722, -0.193369597...
as you don't have control of the middleware, so watch out for your expectations of the FB API and make sure you validate as much of them as possible early in the development stages (not trying out all the things we needed to do with fbML early on brought a few headaches).
[ 0.4088222086429596, 0.155372753739357, -0.029500873759388924, -0.11474964767694473, 0.05740834400057793, -0.4133308529853821, 0.07609205693006516, 0.19694848358631134, 0.2105417251586914, -0.3748546838760376, 0.01905069127678871, 0.6727578043937683, -0.005403699818998575, -0.23247674107551...
I suppose it allows for moving changes from one branch to the next but that's what cherry picking is for and if you're not making a commit of your changes, perhaps you shouldn't be moving them around? I have on occasion applied the wrong stash at the wrong branch, which left me wondering about this question. As mentio...
[ 0.7137302756309509, -0.5529659390449524, -0.11061318963766098, 0.19232431054115295, 0.17278462648391724, 0.21797287464141846, -0.05049385130405426, -0.0024736179038882256, -0.6952003836631775, -0.06923005729913712, 0.4495770335197449, 0.07004915177822113, -0.037569016218185425, 0.142743721...
before you have committed everything. This is useful not for cherry-picking in the usual sense so much as for cherry-picking *your working copy*. F.ex., while working on a feature branch, I will often notice minor bugs or cosmetic impurities in the code that aren’t relevant to that branch. Well, I just fix those right...
[ 0.7467877864837646, -0.08781503140926361, 0.07436574250459671, 0.08959125727415085, 0.3082337975502014, 0.31328967213630676, 0.25400510430336, -0.07554168999195099, -0.6931538581848145, -0.4939822554588318, -0.1278754323720932, 0.9710262417793274, -0.12629558145999908, 0.22106871008872986,...
changes in question, I will also stash some of them yet again, to switch to a different feature branch, where I apply *those*.) This allows me to go deep into programming mode when I am working, and not worry about proper librarianship of my code. Then when I take a mental break, I can go back and carefully sort my ch...
[ 0.15813708305358887, -0.1675560027360916, 0.3581876754760742, 0.21062152087688446, 0.20773746073246002, 0.19151507318019867, 0.23443134129047394, -0.12231029570102692, -0.5418789386749268, -0.892881453037262, -0.08359017968177795, 0.5923461318016052, 0.1504051238298416, 0.00541152106598019...
I was following along with the railscast regarding the restful\_authentication plugin. He recommended running the command: script/generate authenticated user session Which I did, and everything generated "fine", but then sessions wouldn't work. Checking the site again, he mentions a naming standard and listed update...
[ 0.2034723162651062, 0.14957401156425476, -0.008791133761405945, 0.03530682623386383, -0.07629560679197311, -0.28911465406417847, 0.5475893616676331, -0.05195954069495201, -0.10713647305965424, -0.43890053033828735, 0.08328147977590561, 0.8352352976799011, -0.35745665431022644, 0.3050033152...
this without regenerating the content? Is there a way to reverse the generation process to clear out all changes made by the generation? I tried just renaming the files to sessions\_controller with e SessionsController class, but that failed. While writing this, I solved my own problem. I had to rename session to ses...
[ 0.28729209303855896, -0.15444709360599518, 0.20558731257915497, 0.12451194226741791, -0.14601482450962067, -0.19904646277427673, 0.6195959448814392, -0.26000329852104187, -0.25527992844581604, -0.8229451775550842, 0.09155406802892685, 0.4231773018836975, -0.4459669589996338, 0.473614931106...
- generators work by reading a script of sorts on what files to create; `script/destroy` just reads that script in reverse and removes all the files created, as long as you give it the same arguments you passed to `script/generate`. To sum up: `script/destroy authenticated user session` would have removed all the gene...
[ 0.30585870146751404, -0.1935952603816986, 0.021000469103455544, 0.37517401576042175, -0.49901750683784485, -0.06926874071359634, 0.16806772351264954, -0.691307008266449, 0.11289283633232117, -0.16740714013576508, 0.13376019895076752, 0.7898176312446594, -0.5885036587715149, 0.1365277171134...
I have done a bit of testing on this myself (During the server side processing of a DWR Framework Ajax request handler to be exact) and it seems you CAN successfully manipulate cookies, but this goes against much that I have read on Ajax best practices and how browsers interpret the response from an XmlHttpRequest. Not...
[ 0.12011735886335373, -0.06975476443767548, 0.09170763194561005, -0.0076219611801207066, -0.4574238955974579, -0.34106582403182983, 0.43027475476264954, -0.20152530074119568, -0.11208488047122955, -0.6983723044395447, 0.03352067992091179, 0.7593322396278381, -0.012253468856215477, -0.275322...
push the cookie manipulation to the client side, or if this (much cleaner) server side cookie handling can be trusted. I would welcome answers both specific to the DWR Framework and Ajax in general. XMLHttpRequest always uses the Web Browser's connection framework. This is a requirement for AJAX programs to work corre...
[ 0.23995180428028107, 0.0952233076095581, 0.3718361556529999, 0.14470912516117096, -0.4396754205226898, -0.5781421065330505, 0.16452865302562714, 0.032104648649692535, -0.03400648012757301, -0.7385642528533936, -0.18229222297668457, 0.6811622977256775, -0.11963199824094772, 0.01695724576711...
uses the Web Browser's connections. Thus the end result is that it IS safe to manipulate cookies via AJAX. Just **keep in mind** that the AJAX call might never happen. They are not guaranteed events, so don't count on them.
[ 0.028029317036271095, -0.03852793201804161, 0.15636113286018372, 0.38152629137039185, 0.07045912742614746, -0.5418306589126587, 0.5625550150871277, 0.292896568775177, -0.20127254724502563, -0.6830894947052002, -0.06186332181096077, 0.5553140640258789, -0.11956136673688889, -0.3515103459358...
When you create a new content type in Drupal using the Content Creation Kit, you automatically get Title and Body fields in the generated form. Is there a way to remove them? If you're not a developer (or you want to shortcut the development process), another possible solution is to utilize the auto\_nodetitle module. ...
[ 0.531590461730957, -0.2808007001876831, 0.06361878663301468, 0.3483036160469055, 0.22217608988285065, -0.24036557972431183, 0.19735223054885864, 0.01770404912531376, -0.18225841224193573, -0.5679376125335693, -0.29864898324012756, 0.45709675550460815, -0.21024809777736664, -0.1215658560395...
I'm going through the problems on projecteuler.net to learn how to program in Erlang, and I am having the hardest time creating a prime generator that can create all of the primes below 2 million, in less than a minute. Using the sequential style, I have already written three types of generators, including the Sieve of...
[ 0.5205267071723938, 0.2671750783920288, -0.04623892903327942, 0.08602587878704071, -0.17502708733081818, 0.5093695521354675, 0.054827332496643066, -0.10151667147874832, -0.3483022451400757, -0.8202606439590454, 0.27329155802726746, 0.33350151777267456, -0.34117233753204346, 0.2302204221487...
out sections are where I tried to make things concurrent: ``` -module(primeserver). -compile(export_all). start() -> register(primes, spawn(fun() -> loop() end)). is_prime(N) -> rpc({is_prime,N}). rpc(Request) -> primes ! {self(), Request}, receive {primes, Response} -> Response ...
[ -0.040872860699892044, -0.031175922602415085, 0.2565224766731262, -0.12206871807575226, -0.11762119829654694, 0.12360844016075134, -0.05777820944786072, -0.4966783821582794, -0.2520766258239746, -0.0597989596426487, -0.015112421475350857, 0.30030566453933716, -0.5592626333236694, 0.2375361...
N From ! {primes, false}; N =:= 2 -> From ! {primes, true}; N rem 2 =:= 0 -> From ! {primes, false}; true -> Values = is_not_prime(N),
[ -0.04210912808775902, 0.001981371082365513, 0.17244812846183777, -0.41016092896461487, 0.33527058362960815, 0.07245001196861267, 0.32975226640701294, -0.6501239538192749, -0.042438704520463943, -0.17941097915172577, -0.32452282309532166, 0.5408813953399658, -0.33117496967315674, 0.20463636...
Val = not(lists:member(true, Values)), From ! {primes, Val} end, loop() end. for(N,N,_,F) -> [F(N)]; for(I,N,S,F) when I + S [F(I)|for(I+S, N, S, F)]; for(I,N,S,F) when I + S =:= N -> [F(I)|for(I+S, N, S, F)]; for(I,N,S,F) when I + S > N -> [F(I)]. get_list(I, Limit)
[ -0.044243223965168, -0.5034804940223694, 0.6838424801826477, -0.1672455370426178, 0.19135737419128418, 0.17683999240398407, 0.491044282913208, -0.5894399285316467, -0.1967618763446808, -0.5233489871025085, -0.7627257704734802, 0.8607810735702515, -0.24002647399902344, -0.06783373653888702,...
-> if I [I*A || A [] end. is_not_prime(N) -> for(3, N, 2, fun(I) -> List = get_list(I,trunc(N/I)), lists:member(N,lists:flatten(List)) end
[ -0.225272536277771, -0.2670515775680542, 0.3034380078315735, -0.353748619556427, -0.1278892159461975, 0.0626879334449768, 0.15434125065803528, -0.48227304220199585, -0.39353376626968384, -0.44512706995010376, -0.4579354524612427, 0.36003953218460083, -0.4432333707809448, 0.0547965243458747...
). %%L = for(1,N, fun() -> spawn(fun(I) -> wait(I,N) end) end), %%SeedList = [A || A %% lists:foreach(fun(X) -> %% Pid ! {in_list, X} %% end, SeedList) %% end, L). %%wait(I,N) -> %% List = [I*A
[ -0.17663654685020447, -0.3012017607688904, 0.33174020051956177, -0.26135581731796265, 0.15394212305545807, 0.43508026003837585, 0.20737487077713013, -0.34429946541786194, -0.3824370801448822, -0.06683652102947235, -0.2603950798511505, 0.5068833827972412, -0.5634181499481201, 0.124226070940...
|| A lists:member(X,List) %% end. ``` The 'badarity' error means that you're trying to call a 'fun' with the wrong number of arguments. In this case... %%L = for(1,N, fun() -> spawn(fun(I) -> wait(I,N) end) end), The for/3 function expects a fun of arity 1, and the spawn/1 function expects a fun of arity 0. Try th...
[ 0.16644108295440674, 0.03536030650138855, -0.012535144574940205, -0.20063672959804535, -0.2999957799911499, 0.23642125725746155, 0.15986846387386322, -0.37336626648902893, -0.07424089312553406, -0.41591107845306396, -0.3445424735546112, 0.685965359210968, -0.6449952125549316, -0.1837502419...
the kind of problem Erlang was designed to solve. Erlang was designed for massive actor-style concurrency. It will most likely perform rather badly on all examples of data-parallel computation. In many cases, [a sequential solution in, say, ML](http://home.mindspring.com/~eric_rollins/erlangAnt.html) will be so fast th...
[ -0.3395490348339081, -0.1458921879529953, 0.4751747250556946, 0.2511593997478485, 0.03130354732275009, -0.08820540457963943, 0.14319635927677155, -0.019309811294078827, -0.6528379321098328, -0.3749876022338867, 0.05292317271232605, 0.43429824709892273, -0.6316654086112976, 0.15312632918357...
I am trying to extract a gif image embedded as a resource within my ISAPI dll using WebBroker technology. The resource has been added to the DLL using the following RC code: ``` LOGO_GIF RCDATA logo.gif ``` Using resource explorer I verified it is in the DLL properly. using the following code always throws an excep...
[ 0.36716777086257935, -0.07753058522939682, 0.5908041596412659, 0.03408082574605942, 0.12827086448669434, -0.12443812936544418, 0.44934940338134766, -0.3817159831523895, -0.08389779180288315, -0.6997771859169006, -0.10180923342704773, 0.5556877851486206, -0.035573095083236694, 0.12232739478...
How can I get **hierarchy recordset** in ms access through **select** statement? You actually want `/proc/self/status`, which will give you information about the currently executed process. Here is an example: ``` $ cat /proc/self/status Name: cat State: R (running) Tgid: 17618 Pid: 17618 PPid: 3083 TracerP...
[ 0.05898095667362213, -0.2557438910007477, 0.6518083810806274, 0.29479044675827026, 0.36002129316329956, 0.1802486777305603, 0.2871864438056946, -0.36894482374191284, -0.42831385135650635, -0.6819986701011658, -0.19973014295101166, 0.31782564520835876, -0.005235888995230198, 0.1824900805950...
kB VmRSS: 432 kB VmData: 156 kB VmStk: 84 kB VmExe: 32 kB VmLib: 1532 kB VmPTE: 24 kB Threads: 1 SigQ: 0/32268 SigPnd: 0000000000000000 ShdPnd: 0000000000000000 SigBlk: 0000000000000000 SigIgn: 0000000000000000 SigCgt: 0000000000000000 CapInh: 0000000000000000 CapPrm: 000000000...
[ -0.2827736735343933, 0.019041746854782104, 0.6735946536064148, 0.30650684237480164, -0.0442882664501667, 0.21036705374717712, -0.028679581359028816, -0.2121165245771408, -0.5898443460464478, -0.5769811272621155, -0.09871997684240341, 0.19915719330310822, 0.050154153257608414, 0.36628347635...
username by looking at `/etc/passwd`, or calling the relevant functions for mapping uid to username in whatever language you're using. Ideally, you would just call the system call `getuid()` to look up this information, doing it by looking at `/proc/` is counterproductive.
[ -0.18378283083438873, -0.08450324088335037, 0.2715696394443512, -0.03522884473204613, -0.06600139290094376, -0.1718755066394806, 0.2411499172449112, 0.16450387239456177, 0.09198280423879623, -1.073148250579834, -0.37468552589416504, 0.5156044960021973, -0.18608807027339935, -0.018273442983...
I've been using the YUI Components and want to begin using the Loader Utility to specify my dependencies on my page. From your experience, is the YUI Loader Utility a reliable way to load Javascript dependencies in web pages? Yes, YUI Loader is reliable on all A-grade browsers. For a list of which browsers Yahoo! consi...
[ 0.36656680703163147, -0.011769338510930538, 0.20251044631004333, 0.06262103468179703, -0.4455942213535309, -0.4733871519565582, 0.15288080275058746, 0.178805872797966, -0.03927226737141609, -0.4800949692726135, -0.05297447368502617, 0.7610591053962708, -0.04730970412492752, -0.146415308117...
I just learned about how the Java Collections Framework implements data structures in linked lists. From what I understand, `Iterators` are a way of traversing through the items in a data structure such as a list. Why is this interface used? Why are the methods `hasNext()`, `next()` and `remove()` not directly coded to...
[ -0.007009114604443312, -0.06387297064065933, 0.3984726071357727, 0.19672752916812897, -0.13983173668384552, -0.03345176950097084, 0.06756047159433365, -0.6937223672866821, -0.6989535689353943, -0.4836556017398834, -0.21222305297851562, 0.5042146444320679, -0.2832300066947937, -0.1658929586...
to remove > elements from the underlying > collection during the iteration with > well-defined semantics. * Method names > have been improved. > > This interface is > a member of the Java Collections > Framework. I tried googling around and can't seem to find a definite answer. Can someone shed some light on w...
[ 0.17800530791282654, -0.05177057534456253, 0.08049421012401581, 0.036768291145563126, -0.336822509765625, -0.05437977612018585, 0.17647124826908112, -0.19565659761428833, -0.36529740691185, -0.668748140335083, 0.152226984500885, 0.2980778217315674, -0.34827855229377747, 0.03915220871567726...
(note: not necessarily a `Collection` in the `Object` sense). > Why are the methods... not directly > coded to the data structure > implementation itself? They are, they're just marked Private so you can't reach into them and muck with them. More specifically: * You can implement or subclass an `Iterator` such tha...
[ 0.11931488662958145, -0.06649637222290039, -0.05577157810330391, 0.3903769254684448, 0.008925055153667927, -0.10588061064481735, 0.25141066312789917, -0.024330031126737595, -0.5436562895774841, -0.7606238722801208, -0.239089697599411, 0.6120952367782593, -0.24960333108901978, 0.01999788917...
you wish, and each client may traverse in their own time, at their own speed. * Java `Iterators` from the java.util package in particular will throw an exception if the storage that backs them is modified while you still have an `Iterator` out. This exception lets you know that the `Iterator` may now be returning inval...
[ -0.09299014508724213, 0.10166363418102264, 0.10074707120656967, -0.08787250518798828, 0.00911711435765028, -0.1471240222454071, 0.5453078746795654, -0.03231627121567726, -0.6714307069778442, -0.9321093559265137, -0.20214982330799103, 0.4466685950756073, -0.2110718935728073, 0.0131938615813...
My users use the site pretty equally 24/7. Is there a meme for build timing? International audience, single cluster of servers on eastern time, but gets hit well into the morning, by international clients. 1 db, several web servers, so if no db, simple, whenever. But when the site has to come down, when would you, a...
[ 0.6329733729362488, 0.2164812684059143, 0.40751028060913086, -0.07294817268848419, -0.2148182988166809, -0.09857065230607986, 0.48627689480781555, 0.42587485909461975, -0.07757751643657684, -0.5445455312728882, -0.09812991321086884, 0.6000312566757202, 0.13432061672210693, -0.1661409735679...
I am just starting out with DI & unit testing and have hit a snag which I am sure is a no brainer for those more experienced devs : I have a class called MessageManager which receives data and saves it to a db. Within the same assembly (project in Visual Studio) I have created a repository interface with all the metho...
[ 0.30870741605758667, -0.05840256065130234, 0.029253721237182617, 0.01867181807756424, -0.48049628734588623, -0.15777556598186493, 0.1100764200091362, -0.021463491022586823, -0.15285055339336395, -0.870738685131073, 0.08658094704151154, 0.44658830761909485, -0.07976952940225601, 0.024686953...
the client of MessageManager can inject a concrete implementation of the repository interface. This is of courser not allowed I could move the interface into the data access assembly but I believe the repository interface is meant to reside in the same assembly as the client that uses it So what have I done wrong? Ar...
[ -0.020964818075299263, 0.08074357360601425, 0.36067014932632446, -0.06076151132583618, -0.27238160371780396, 0.10409500449895859, 0.21579758822917938, -0.40312984585762024, -0.138047993183136, -0.5373247265815735, 0.04229462891817093, 0.48471781611442566, -0.5703774094581604, 0.06828375905...
how to resolve MessageManager *and* the IRepository.
[ -0.34914785623550415, 0.12189925462007523, -0.052676472812891006, 0.15509650111198425, -0.17865373194217682, 0.12226410955190659, 0.31492117047309875, -0.28865063190460205, -0.009094905108213425, -0.7839943766593933, 0.0024651442654430866, 0.3247174620628357, 0.034599777311086655, -0.46518...
If you were to mandate a minimum percentage code-coverage for unit tests, perhaps even as a requirement for committing to a repository, what would it be? Please explain how you arrived at your answer (since if all you did was pick a number, then I could have done that all by myself ;) This prose by Alberto Savoia answ...
[ 0.7435194253921509, 0.11940721422433853, -0.05307887867093086, 0.28778979182243347, -0.19338557124137878, 0.04829687252640724, 0.23389025032520294, -0.3469406068325043, -0.10274279117584229, -0.6770015358924866, -0.038058407604694366, 0.4618757963180542, -0.1002882644534111, 0.016034562140...
for?” > > > The great master replied: > > > “Don’t worry about coverage, just write some good tests.” > > > The programmer smiled, bowed, and > left. > > > ... > > > Later that day, a second programmer > asked the same question. > > > The great master pointed at a pot of > boiling water and said: > > >...
[ 0.4261482059955597, 0.49517086148262024, -0.12987355887889862, -0.013313359580934048, -0.25709760189056396, 0.150940403342247, 0.18549510836601257, -0.43592143058776855, -0.34532663226127625, -0.5925663709640503, 0.12228261679410934, 0.4683900773525238, -0.21367603540420532, 0.357987433671...
they are, what other > food you are serving, how much rice > you have available, and so on.” > > > “Exactly,” said the great master. > > > The second programmer smiled, bowed, > and left. > > > ... > > > Toward the end of the day, a third > programmer came and asked the same > question about code coverage....
[ 0.44315841794013977, 0.5196042656898499, 0.0612819530069828, 0.034653760492801666, -0.2732457220554352, 0.09952337294816971, -0.13606016337871552, -0.3552383482456207, -0.5648691058158875, -0.7836384177207947, 0.03814706206321716, 0.8572921752929688, -0.1190025731921196, 0.2659242451190948...
reply, a young > apprentice approached the great > master: > > > “Great master, today I overheard you answer the same question about > code coverage with three different > answers. Why?” > > > The great master stood up from his > chair: > > > “Come get some fresh tea with me and let’s talk about it.” > > >...
[ 0.3974583148956299, 0.44852250814437866, -0.01381885726004839, 0.3239078223705292, -0.22448725998401642, -0.1465338170528412, 0.0748891606926918, -0.455443799495697, -0.4665921628475189, -0.8513653874397278, -0.09988117218017578, 0.28023114800453186, -0.10267613083124161, 0.450272589921951...
no > tests. He has a long way to go; > focusing on code coverage at this time > would be depressing and quite useless. > He’s better off just getting used to > writing and running some tests. He can > worry about coverage later.” > > > “The second programmer, on the other hand, is quite experience both > at pr...
[ 0.24891801178455353, 0.3129867911338806, -0.2928001880645752, -0.04164843633770943, -0.29844769835472107, 0.16812743246555328, 0.2530772387981415, -0.4829600751399994, -0.18509499728679657, -0.6699405908584595, 0.4101628065109253, 0.6497904658317566, 0.196986585855484, -0.1728460192680359,...
of factors, and she knows those > factors better than I do – it’s her > code after all. There is no single, > simple, answer, and she’s smart enough > to handle the truth and work with > that.” > > > “I see,” said the young apprentice, > “but if there is no single simple > answer, then why did you answer the >...
[ -0.06575623154640198, 0.3194264769554138, -0.24522584676742554, 0.28362923860549927, -0.29520460963249207, 0.11047138273715973, 0.10784084349870682, -0.611137866973877, -0.5990126132965088, -0.26114821434020996, -0.010001085698604584, 0.7455094456672668, -0.19124829769134521, 0.11126978695...
and down. > > > “The third programmer wants only simple answers – even when there are > no simple answers … and then does not > follow them anyway.” > > > The young apprentice and the grizzled > great master finished drinking their > tea in contemplative silence.
[ -0.24905283749103546, 0.6060053706169128, 0.28740131855010986, 0.09258656948804855, -0.41654932498931885, -0.17406898736953735, 0.036514703184366226, 0.022906653583049774, -0.24877271056175232, -0.5469654202461243, -0.21668730676174164, 0.5747948288917542, 0.4078083038330078, 0.09898224472...
I'm using the following html to load dojo from Google's hosting. ``` <script src="http://www.google.com/jsapi"></script> <script type="text/javascript">google.load("dojo", "1.1.1");</script> <script type="text/javascript"> dojo.require("dojox.gfx"); ... ``` This errors out on the requre line with an error like dojox...
[ 0.19767728447914124, 0.1873595267534256, 0.5732382535934448, -0.11872035264968872, -0.44786569476127625, -0.5021289587020874, 0.20447294414043427, -0.17312388122081757, -0.05484872683882713, -0.464640349149704, -0.13407011330127716, 0.6207053661346436, -0.6505789756774902, -0.0543061494827...
to keep parsing; it will go straight to your dojo.require line, and it will fail there because the **dojo** object will be undefined. The solution (if you don't want to use use the direct <script> tag), is to enclose all your code that references dojo in a **start** function, and set it will as a callback, by doing: ...
[ -0.03290664404630661, 0.1971985548734665, 0.5105540752410889, -0.16125403344631195, -0.11274820566177368, -0.21850785613059998, 0.393489271402359, -0.4146839380264282, 0.06894652545452118, -0.38782113790512085, -0.46186578273773193, 0.6195735335350037, -0.7369828820228577, -0.2023972570896...
Businesses Analyst from my team keeps sending us the updated Requirements documents often and I end up hunting the recent changes by comparing the old version. Is their a good way of comparing the Word documents? Note: We have the track changes option ON, but now the documents looks like a blood bath, complicating it...
[ 0.34354275465011597, 0.3754657804965973, 0.3062434196472168, 0.04583312198519707, 0.34851816296577454, -0.12251346558332443, 0.36892521381378174, -0.14244115352630615, -0.18027444183826447, -0.645386815071106, 0.2952820956707001, 0.8659361600875854, 0.10431058704853058, 0.02292221412062645...
marketplace, but to do this within Word, the simplest answer is to upgrade to Word 2007 or later versions From Word version 2007 the ribbon command "Review" and "Compare" are easy to find, and operate reasonably obviously. And they have a nice clear layout of merged changes, and the before and after docs The small co...
[ 0.19495144486427307, 0.13080058991909027, 0.5342985987663269, -0.06957294791936874, -0.22256618738174438, 0.19155165553092957, 0.2045874148607254, 0.05106126889586449, -0.02314515970647335, -0.6993893384933472, 0.27193689346313477, 0.9675898551940918, 0.16896194219589233, -0.04143138602375...
given the long term consequences of parts of your documents being silently deleted
[ 0.3858667016029358, 0.2116491049528122, -0.1500556617975235, 0.19282685220241547, 0.49104276299476624, -0.2793075144290924, 0.14551402628421783, 0.26883938908576965, -0.5090659856796265, -0.3855031430721283, -0.12873578071594238, 0.06465107947587967, 0.06514373421669006, 0.131642147898674,...
I have a table in `MySQL` that has 3 fields and I want to enforce uniqueness among two of the fields. Here is the table `DDL`: ``` CREATE TABLE `CLIENT_NAMES` ( `ID` int(11) NOT NULL auto_increment, `CLIENT_NAME` varchar(500) NOT NULL, `OWNER_ID` int(11) NOT NULL, PRIMARY KEY (`ID`), ) ENGINE=InnoDB DEFAULT CHARSET=u...
[ -0.12033616006374359, 0.26902320981025696, 0.3827507495880127, 0.07723435014486313, -0.128927081823349, 0.03798926621675491, 0.06524243205785751, -0.34550175070762634, -0.20135824382305145, -0.5886498093605042, 0.03315073251724243, 0.7116925120353699, -0.2386375367641449, 0.374608695507049...
error: > Error executing SQL commands to update table. > Specified key was too long; max key length is 765 bytes (error 1071) Anyone else have any ideas? MySQL cannot enforce uniqueness on keys that are longer than 765 bytes (and apparently 500 UTF8 characters can surpass this limit). 1. Does CLIENT\_NAME really n...
[ -0.14215855300426483, 0.04012829810380936, 0.14374564588069916, 0.009858074598014355, -0.16493351757526398, 0.0936485156416893, 0.3279434144496918, -0.05803387984633446, -0.4540797770023346, -0.41296616196632385, 0.21471881866455078, 0.3935110867023468, -0.24127312004566193, 0.232633695006...
As an example in pseudocode: ``` if ((a mod 2) == 0) { isEven = true; } else { isEven = false; } ``` Instead of the modulo operator, which has slightly different semantics, for non-negative integers, you can use the *remainder* operator `%`. For your exact example: ``` if ((a % 2) == 0) { isEven = true; ...
[ 0.03748416155576706, -0.08172572404146194, 0.04939483478665352, -0.3781419098377228, 0.25916367769241333, -0.08272721618413925, 0.3989804983139038, -0.6288660764694214, -0.1425580233335495, -0.07506369054317474, -0.15152660012245178, 0.42323336005210876, -0.31422799825668335, 0.04930889233...
I'm trying to read a .doc file into a database so that I can index it's contents. Is there an easy way for PHP on Linux to read .doc files? Failing that is it possible to convert .doc files to rtf, pdf or some other 'open' format that is easy to read? Note, I am not interested in .docx files. There seems to be a [libr...
[ 0.5682504773139954, 0.29198744893074036, 0.007411353290081024, -0.19193431735038757, -0.4069642126560211, -0.23956602811813354, 0.24817103147506714, 0.04426998645067215, -0.1267109364271164, -0.8159111142158508, 0.016994336619973183, 0.5528193116188049, -0.19284161925315857, 0.295555055141...
Why doesn't this Google Chart API URL render both data sets on this XY scatter plot? ``` http://chart.apis.google.com/chart?cht=lxy&chd=t:10,20,30,40,50,60,70,80,90,100,110,120,130,140,150,160,170,180,190,200|0.10,0.23,0.33,0.44,0.56,0.66,0.79,0.90,0.99,1.12,1.22,1.33,1.44,1.56,1.68,1.79,1.90,2.02,2.12,2.22|0.28,0.56...
[ 0.06575159728527069, 0.21582938730716705, 0.6667743921279907, 0.1821351945400238, -0.10636574774980545, 0.5149732828140259, 0.008189232088625431, -0.07436809688806534, -0.1771891564130783, -0.6018275022506714, 0.1518065184354782, 0.03591355308890343, -0.18642935156822205, 0.370407879352569...
How to create new PCL file similar to existing MS doc. I have MS doc template and replacing it with actual data. I need to achieve same for PCL format (Create PCL file as template and replacing it with actual value from database and send it to fax). 1. install a new printer 2. when asked for a port, create a new port o...
[ 0.39430683851242065, 0.20837046205997467, 0.7697282433509827, 0.027184683829545975, 0.05035975202918053, -0.13702966272830963, -0.11878553777933121, -0.11337941139936447, -0.11512408405542374, -0.8310483694076538, -0.08010146766901016, 0.8318093419075012, -0.41431838274002075, 0.0827168971...
output to that file. Many programs allow you to redirect printing to a file; in this case, you'd be able to select a different file name for each print job.
[ 0.4365447163581848, -0.1357683688402176, 0.24337729811668396, 0.15514858067035675, -0.08828628063201904, 0.11167986690998077, -0.20172719657421112, 0.06089023873209953, -0.42310482263565063, -0.7590177059173584, -0.0756932720541954, 0.38126468658447266, -0.2667970657348633, 0.2417268007993...
I want to encrypt few files using python what is the best way I can use gpg/pgp using any standard/famous python libraries? [PyCrypto](http://www.pycrypto.org) seems to be the best one around.
[ 0.3542182743549347, -0.015415643341839314, 0.015571772120893002, 0.19344472885131836, -0.17635956406593323, -0.11411453038454056, 0.1602066457271576, 0.48018431663513184, -0.4279654026031494, -0.3833485245704651, -0.09532450884580612, 0.3195943236351013, -0.1664111167192459, -0.16143311560...
Basically, I would like a brief explanation of how I can access a SQL database in C# code. I gather that a connection and a command is required, but what's going on? I guess what I'm asking is for someone to de-mystify the process a bit. Thanks. For clarity, in my case I'm doing web apps, e-commerce stuff. It's all AS...
[ 0.5539466142654419, 0.33575087785720825, 0.08985496312379837, 0.3705354332923889, 0.0597744882106781, -0.2588566839694977, 0.19475416839122772, 0.4637412428855896, -0.043234262615442276, -0.40702715516090393, 0.1637362837791443, 0.5623283386230469, 0.09867260605096817, 0.19259534776210785,...
for beginner video demos. <http://www.asp.net/learn/data-videos/> They are ASP.NET focused, but pay attention to the database aspects.
[ 0.40061289072036743, -0.4142994284629822, 0.18252618610858917, 0.4633718430995941, -0.14577020704746246, -0.5354317426681519, 0.029141731560230255, 0.05674256011843681, -0.26941919326782227, -0.6239691972732544, -0.24737000465393066, 0.4798867106437683, 0.662926971912384, -0.19622528553009...
When a user goes to my site, my script checks for 2 cookies which store the user id + part of the password, to automatically log them in. It's possible to edit the contents of cookies via a cookie editor, so I guess it's possible to add some malicious content to a written cookie? Should I add `mysql_real_escape_stri...
[ 0.45184704661369324, 0.21866318583488464, 0.3509533107280731, 0.0781380757689476, 0.25111863017082214, -0.24398687481880188, 0.8776744604110718, -0.027294501662254333, -0.2936236262321472, -0.5928645133972168, 0.001981590176001191, 0.5740431547164917, -0.31600770354270935, 0.13108308613300...
why not hash the username and password and a (secret) salt and set that as the cookie value? i.e.: ``` define('COOKIE_SALT', 'secretblahblahlkdsfklj'); $cookie_value = sha1($username.$password.COOKIE_SALT); ``` Then you know the cookie value is always going to be a 40-character hexidecimal string, and can compare th...
[ 0.02352827787399292, 0.19656437635421753, 0.19153068959712982, -0.05035414174199104, 0.03762819245457649, -0.08020507544279099, 0.42267245054244995, -0.3252471685409546, -0.03119851090013981, -0.6787858009338379, -0.018564900383353233, 0.5474212169647217, -0.1319735050201416, 0.14102941751...
can't change your app and insist on using hackable cookie values is to use [prepared statements with bound parameters](http://devzone.zend.com/node/view/id/686).
[ 0.5182549357414246, -0.1562523990869522, 0.10710150748491287, 0.2115689218044281, 0.29191291332244873, -0.4075867533683777, 0.6356260776519775, -0.15883830189704895, -0.24188703298568726, -0.5942168831825256, -0.4350487291812897, 0.4638139605522156, -0.4003663957118988, -0.0953797996044159...
NHibernate is not really a good fit for our environment due to all the dependencies. (Castle, log4net etc.) Is there a good lightweight alternative? Support for simple file based databases such as Access/SQLite/VistaDB is essential. Ideally, something contained in a single assembly that only references .NET assembli...
[ -0.2132207751274109, 0.08886938542127609, 0.42084306478500366, 0.09861179441213608, -0.39000701904296875, 0.021338224411010742, -0.07168696820735931, -0.11123069375753403, -0.17674054205417633, -0.6011925935745239, 0.2049257904291153, 0.5953904390335083, -0.5180206298828125, 0.311598241329...
over ADO.Net: * MS [Data Access Application Block](http://msdn.microsoft.com/en-us/library/cc309504.aspx), a part of [ms enterprise library](http://msdn.microsoft.com/en-us/library/cc467894.aspx). * [iBatis.Net](http://ibatis.apache.org/) (Was [retired](http://attic.apache.org/projects/ibatis.html) by the Apache Found...
[ 0.21296146512031555, 0.2850269377231598, 0.35071396827697754, -0.031797245144844055, -0.16340473294258118, 0.09257529675960541, 0.26742297410964966, -0.2690421938896179, -0.24086253345012665, -0.5532840490341187, -0.07699061185121536, 0.18082208931446075, -0.3605717420578003, 0.38013985753...
I'm looking for an open source search indexing library. It will be used for embedded web application so it should have a small code size. Preferably, written in C, C++ or PHP and does not require any database to be installed for storing indexes. Indexes should be stored on a file instead (e.g., xml, txt). I tried to lo...
[ 0.2706742584705353, 0.07607094943523407, 0.19765447080135345, 0.42394524812698364, -0.12164020538330078, -0.2818378508090973, -0.09382659941911697, 0.25698602199554443, -0.2439694106578827, -0.9404873847961426, 0.07544906437397003, 0.2863302528858185, -0.2172321081161499, 0.067997954785823...
what would be a good search library/API to use? Thanks. [Hyper Estraier](http://hyperestraier.sourceforge.net/).
[ -0.1611081063747406, -0.17451472580432892, 0.1960776299238205, 0.542811393737793, -0.01720534637570381, -0.1357995718717575, 0.32990407943725586, 0.3668628931045532, -0.29698917269706726, -0.8197300434112549, -0.3500898778438568, 0.4579898715019226, -0.01375927310436964, 0.1840126961469650...
How to implement a web page that scales when the browser window is resized? I can lay out the elements of the page using either a table or CSS float sections, but i want the display to rescale when the browser window is resized i have a working solution using AJAX PRO and DIVs with overflow:auto and an onwindowresize...
[ 0.29945579171180725, -0.04353823512792587, 0.39014455676078796, 0.09726749360561371, -0.19955141842365265, 0.31227555871009827, 0.37001845240592957, -0.3050430417060852, -0.0620088092982769, -1.0721523761749268, 0.24796806275844574, 0.48790714144706726, -0.1424083709716797, -0.205590486526...
and percentages seems to work best, which is what I did in the original solution; using a visibility:hidden div set to 100% by 100% gives a way to measure the client area of the window [difficult in IE otherwise], and an onwindowresize javascript function lets the AJAXPRO methods kick in when the window is resized to r...
[ -0.06446868181228638, -0.04341455176472664, 0.5648714900016785, -0.03736676648259163, -0.07373915612697601, 0.22791844606399536, 0.27724748849868774, -0.5320194363594055, -0.12161857634782791, -0.7539975643157959, -0.025177698582410812, 0.4696667790412903, 0.007277891505509615, -0.00782225...
re-display the 'pane' contents after resizing, and keep overflow:auto turned on to avoid scrolling instead of using in css say "width: 200px", use stuff like "width: 50%" This makes it use 50% of whatever it's in, so in the case of: ``` <body> <div style="width:50%"> <!--some stuff--> </div> </body> ``` The div...
[ -0.006836991291493177, -0.14804452657699585, 0.687282919883728, -0.11205021291971207, -0.11100444197654724, 0.17191661894321442, 0.13198064267635345, -0.07251778244972229, -0.2489033341407776, -0.917175829410553, -0.3346259593963623, 0.19063018262386322, 0.15621566772460938, -0.07189314812...
How do I create a resource that I can reference and use in various parts of my program easily? My specific problem is that I have a NotifyIcon that I want to change the icon of depending on the state of the program. A common problem, but one I've been struggling with for a long time. Well, after searching around and c...
[ 0.23519286513328552, 0.09857236593961716, 0.4267393946647644, 0.2477455586194992, 0.028289761394262314, 0.1367797553539276, 0.3584083020687103, 0.16996827721595764, -0.33540093898773193, -0.9437686204910278, 0.2603197991847992, 0.3067678213119507, -0.14195099472999573, -0.03355499729514122...
want to create an icon. It's a similar process, no matter what type of data you want to add as a resource though. * Right click the project you want to add a resource to. Do this in the Solution Explorer. Select the "Properties" option from the list. * Click the "Resources" tab. * The first button along the top of the...
[ 0.27459967136383057, -0.08948156982660294, 0.4545515775680542, 0.17088784277439117, 0.38628068566322327, 0.10741011798381805, 0.12358033657073975, -0.04419681429862976, -0.24462337791919708, -1.1401300430297852, 0.010321544483304024, 0.5213043093681335, -0.02196328341960907, 0.108719334006...
button, "Add Resource". You can either add a new resource, or if you already have an icon already made, you can add that too. Follow the prompts for whichever option you choose. * At this point, you can double click the newly added resource to edit it. Note, resources also show up in the Solution Explorer, and double c...
[ 0.18899981677532196, -0.22904066741466522, 0.5362237095832825, 0.2190307080745697, 0.25498244166374207, 0.3771146833896637, 0.10886736214160919, 0.3794291615486145, -0.43939071893692017, -1.0342885255813599, -0.10359837114810944, 0.7550972700119019, -0.006484154611825943, 0.228103205561637...
`Properties.Resources` that gives you access to all your resources, so my code ended up being as simple as: ``` paused = !paused; if (paused) notifyIcon.Icon = Properties.Resources.RedIcon; else notifyIcon.Icon = Properties.Resources.GreenIcon; ``` Done! Finished! Everything is simple when you know how, isn'...
[ 0.16605313122272491, -0.22228483855724335, 0.13186240196228027, 0.04485098272562027, 0.0866863802075386, -0.10180030018091202, 0.48718705773353577, -0.32162073254585266, -0.527027428150177, -0.4299977421760559, -0.04709605127573013, 0.8311581611633301, -0.20145997405052185, -0.023560255765...
I am working on a small application in VB.NET. The program needs administrator privilege for doing some tasks. Is there a way to ask for administrator privileges during the execution if the program? What is the general way of changing the user account under which the application is running? There are a number of metho...
[ 0.515882134437561, 0.10873828828334808, 0.04932497814297676, 0.16366691887378693, 0.23677270114421844, -0.05253930017352104, 0.1601855605840683, -0.22517481446266174, -0.1707163006067276, -0.7311823964118958, 0.15346749126911163, 0.4683469533920288, -0.12660841643810272, 0.2201320081949234...
nicest is to use [the COM elevation moniker](http://msdn.microsoft.com/en-us/library/ms679687(VS.85).aspx) and `CoCreateInstanceAsAdmin` to call methods on a COM object running as an administrator. This is possibly tricky to get working in VB.Net. I got it working ok in C++ though 3. Another ok method is to isolate the...
[ 0.1254958063364029, 0.046445708721876144, 0.32047757506370544, 0.14873960614204407, 0.050860919058322906, -0.15103517472743988, 0.14531618356704712, 0.12941992282867432, -0.1442762017250061, -0.7076777815818787, -0.05320700630545616, 0.5728206038475037, -0.2339065819978714, 0.1483456939458...
Do C#/.NET floating point operations differ in precision between debug mode and release mode? They can indeed be different. According to the CLR ECMA specification: > Storage locations for floating-point > numbers (statics, array elements, and > fields of classes) are of fixed size. > The supported storage sizes ar...
[ 0.06235312297940254, 0.14056208729743958, 0.24758170545101166, 0.15964563190937042, 0.19977571070194244, -0.01640511304140091, -0.21639327704906464, -0.42808234691619873, -0.24884290993213654, -0.03132614120841026, -0.1839568316936493, 0.38279154896736145, -0.22232891619205475, -0.17003685...
R8, but its value can be represented > internally with additional range > and/or precision. The size of the > internal floating-point representation > is implementation-dependent, can vary, > and shall have precision at least as > great as that of the variable or > expression being represented. An > implicit wi...
[ -0.17925003170967102, -0.11932168155908585, 0.703968346118927, -0.2793905735015869, 0.10948582738637924, 0.35455015301704407, 0.06119469180703163, -0.52197265625, -0.3078768849372864, -0.2657506465911865, -0.09062488377094269, 0.33437255024909973, -0.19071908295154572, 0.001479821396060288...
is that the following comparison may or may not be equal: ``` class Foo { double _v = ...; void Bar() { double v = _v; if( v == _v ) { // Code may or may not execute here. // _v is 64-bit. // v could be either 64-bit (debug) or 80-bit (release) or something else (future?). } ...
[ 0.36988383531570435, 0.25211310386657715, 0.22172468900680542, -0.40012747049331665, 0.08382511138916016, 0.032631147652864456, 0.29435649514198303, -0.33891060948371887, -0.12488174438476562, -0.36783796548843384, 0.036076243966817856, 0.702894389629364, -0.6135512590408325, 0.21799221634...