text
stringlengths
0
30.5k
title
stringclasses
1 value
embeddings
listlengths
768
768
public void DisplayNode() { Console.Write(n); } } public class BinarySearchTree { public TreeNode root; public BinarySearchTree()
[ -0.2935508191585541, -0.19336460530757904, 0.06529355049133301, -0.1688273400068283, 0.14126017689704895, 0.22598858177661896, 0.3016800284385681, 0.29380762577056885, -0.39099663496017456, -0.7044259905815125, -0.356770396232605, 0.39299777150154114, -0.24016985297203064, 0.17440034449100...
{ root = null; } public void insert(ref TreeNode root, int x) { if (root == null)
[ -0.16092370450496674, -0.08845458179712296, -0.05058949440717697, -0.15062761306762695, 0.11551590263843536, 0.08674803376197815, 0.4812547564506531, 0.19411098957061768, -0.09812488406896591, -0.24270451068878174, -0.2307429313659668, 0.4336240887641907, -0.24653375148773193, 0.0338765867...
{ root = new TreeNode(x, null, null); } else if (x < root.n)
[ -0.40009021759033203, -0.30384185910224915, 0.020157037302851677, -0.19298946857452393, 0.0122830206528306, -0.05002298206090927, 0.5524671673774719, -0.03944670781493187, -0.39229506254196167, -0.2428816705942154, -0.3216075003147125, 0.20359738171100616, -0.15198129415512085, 0.227323994...
insert(ref root._left, x); else insert(ref root._right, x); } public int FindMin() {
[ -0.30508658289909363, 0.000018726419511949643, 0.013840977102518082, -0.2991528809070587, 0.49971216917037964, -0.08005836606025696, 0.10813350230455399, -0.10437784343957901, 0.5435062646865845, -0.3334464132785797, -0.12879958748817444, 0.9048804640769958, -0.3257855176925659, 0.04231303...
TreeNode current = root; while (current._left != null) current = current._left; return current.n; } public int FindMax()
[ -0.347379595041275, -0.6304493546485901, 0.48515743017196655, -0.07196000218391418, 0.5293585062026978, -0.2969910800457001, 0.3540131151676178, 0.047848813235759735, -0.3636884391307831, -0.1482464224100113, -0.4430365264415741, 0.41595274209976196, -0.45642873644828796, 0.050632543861866...
{ TreeNode current = root; while (current._right != null) current = current._right; return current.n; }
[ -0.4886626601219177, -0.3485977053642273, 0.2650511860847473, -0.14714142680168152, 0.2840029001235962, 0.08287615329027176, 0.41147786378860474, 0.1666363924741745, -0.5803087949752808, -0.08822835236787796, -0.29186776280403137, 0.1648666262626648, -0.26593253016471863, 0.389392018318176...
public TreeNode Find(int key) { TreeNode current = root; while (current.n != key) { if
[ -0.42974844574928284, -0.3555634617805481, 0.19036726653575897, -0.08114119619131088, 0.39471179246902466, -0.16695304214954376, 0.22354958951473236, 0.02852090634405613, -0.2885708510875702, -0.22358569502830505, -0.30316272377967834, 0.3077213764190674, -0.15022623538970947, 0.2353964298...
(key < current.n) current = current._left; else current = current._right; if (current == null)
[ -0.3633846044540405, -0.4300330877304077, 0.4608152508735657, -0.2718025743961334, 0.5714534521102905, -0.11029763519763947, 0.12448611855506897, -0.16455532610416412, -0.45199882984161377, 0.16776223480701447, -0.2365260124206543, 0.41842541098594666, -0.14161908626556396, 0.5934395790100...
return null; } return current; } public void InOrder(ref TreeNode root) {
[ -0.12337367236614227, -0.1524420976638794, -0.05273963883519173, -0.27966830134391785, 0.05247744545340538, -0.09359026700258255, 0.6641919612884521, 0.00614942004904151, -0.2217520773410797, -0.12441690266132355, -0.215200275182724, 0.4515754282474518, -0.26871350407600403, 0.460276752710...
if (root != null) { InOrder(ref root._left); root.DisplayNode(); InOrder(ref root._right);
[ -0.5131829380989075, -0.016236763447523117, 0.1900845468044281, -0.4875571131706238, 0.3168589472770691, 0.09161387383937836, 0.45786526799201965, -0.04362407326698303, 0.04225962981581688, -0.49129629135131836, -0.5037778615951538, 0.5057761073112488, -0.14861781895160675, 0.2707687914371...
} } public int CountNodes(TreeNode root) { int count=1; if (root._left != null)
[ -0.2739846110343933, -0.2564197778701782, 0.08633678406476974, -0.23622289299964905, 0.33794543147087097, -0.1817963719367981, 0.4583788812160492, -0.02870192937552929, -0.2906939685344696, -0.2063107192516327, -0.3302971124649048, 0.34083428978919983, -0.4639209806919098, 0.00549299782142...
count += CountNodes(root._left); if (root._right != null) count += CountNodes(root._right); return count; } public int CountLeaves(TreeNode root)
[ -0.22297999262809753, -0.26213136315345764, 0.40907472372055054, -0.2930130064487457, 0.08710645139217377, -0.1565285176038742, 0.484845370054245, -0.3104952275753021, -0.3560352325439453, -0.1655436009168625, -0.3531787097454071, 0.3704710900783539, -0.42219915986061096, 0.152074009180068...
{ int count = (root._left == null && root._right == null) ? 1 : 0; if (root._left != null) count += CountLeaves(root._left); if (root._right != null)
[ -0.3166349530220032, -0.2046435922384262, 0.28521865606307983, -0.42122361063957214, 0.26903554797172546, 0.028685148805379868, 0.5128084421157837, -0.45109251141548157, -0.06670919060707092, -0.08617422729730606, -0.4320220649242401, 0.5376405119895935, -0.5010693669319153, -0.13243944942...
count += CountLeaves(root._right); return count; } public static void print(TreeNode root) { if (root != null)
[ -0.01910792849957943, -0.2583926022052765, 0.29660797119140625, -0.32090139389038086, 0.13076362013816833, -0.1455909013748169, 0.6932582855224609, -0.25696757435798645, -0.3669116795063019, 0.03117167204618454, -0.2934083342552185, 0.4159146547317505, -0.4840414822101593, 0.17948941886425...
{ print(root._left); Console.WriteLine(root.n.ToString()); print(root._right); } }
[ -0.4042745530605316, -0.0857873186469078, 0.39437323808670044, -0.3369167149066925, 0.6219683885574341, 0.15476058423519135, 0.3384670913219452, -0.0875140056014061, 0.07699666917324066, -0.5329439043998718, -0.3867252767086029, 0.7101271748542786, -0.32310760021209717, 0.11818350106477737...
} } } ``` Thanx in advance and special thanx to Marc Gravell . If what you mean in `CountNodes` is to count all non-leaf nodes you must change this line: ``` int count=1; ``` to read this: ``` int count = (root._left == null && root._right == null) ? 0 : 1; ``` (the opposite of what is in `CountLeaves`). ...
[ -0.1489151269197464, -0.12297514081001282, 0.5309624075889587, -0.2432512491941452, 0.06986519694328308, -0.1665232926607132, 0.23352745175361633, -0.1003590002655983, -0.3630220592021942, -0.4276486039161682, -0.164359912276268, 0.37256529927253723, -0.19978611171245575, 0.032595232129096...
height = Math.Max(height, Height(root._right)); return height; } ```
[ 0.12169665843248367, 0.29724669456481934, 0.4279829263687134, -0.2842327058315277, 0.27613165974617004, 0.03773220628499985, 0.4777311086654663, -0.18786592781543732, -0.1391311138868332, -0.3295220136642456, -0.3150571882724762, 0.7870707511901855, 0.166232630610466, 0.3515748083591461, ...
Can someone tell me what the code equivelant in VB.Net to this C# code is? ``` new {name="value"} ``` This is called Anonymous Types and the VB equivalent is : ``` New With {.Name = "value"} ```
[ 0.577839732170105, 0.06938803941011429, 0.26555460691452026, -0.07427568733692169, -0.05171866714954376, -0.47428810596466064, -0.012835926376283169, -0.12887108325958252, -0.22254496812820435, -0.4585427939891815, 0.09692750126123428, 0.6682382225990295, -0.5162900686264038, 0.22140857577...
Let's say I have the following jQuery AJAX call: ``` $.ajax({ type: "POST", url: "MyUrl", data: "val1=test", success: function(result){ // Do stuff } }); ``` Now, when this AJAX call is made I want the server-side code to run through a few error handling checks (e.g. is the user still logged ...
[ 0.17185385525226593, 0.17647963762283325, 0.15398478507995605, -0.0444234199821949, -0.2597672939300537, -0.2292584925889969, 0.16890765726566315, 0.10458012670278549, 0.06737521290779114, -0.6676957607269287, 0.04680958390235901, 0.6155313849449158, -0.13243368268013, 0.02083844318985939,...
to return a JSON object with two fields: error and errorMessage. These fields would then be checked in the jQuery AJAX call: ``` $.ajax({ type: "POST", url: "MyUrl", data: "val1=test", success: function(result){ if (result.error == "true") { alert("An error occurred: " & result.er...
[ -0.3170085549354553, -0.2069236934185028, 0.08818893134593964, -0.14227649569511414, -0.17386074364185333, 0.006467137951403856, 0.34203505516052246, 0.015398669056594372, 0.13368016481399536, -0.4853222668170929, -0.3060324192047119, 0.6473801136016846, -0.15403030812740326, -0.2026335448...
// Do stuff } } }); ``` This feels a bit clunky to me, but it works. Is there a better alternative? Personally, I have similar code to the following code in my library. ``` $.ajaxSetup({ error: function(xhr){ alert('Request Status: ' + xhr.status + ' Status Text: ' + xhr.statusText + ' ' + xhr...
[ 0.22376082837581635, -0.051467206329107285, 0.06630003452301025, 0.041944924741983414, -0.3098984658718109, -0.2963968515396118, 0.37724289298057556, 0.07040012627840042, -0.07132075726985931, -0.5655495524406433, -0.027100367471575737, 0.5815244913101196, -0.23101259768009186, -0.26173001...
the Ajax request somewhere in the 400's (which is always associated with errors). Once the Ajax request receives this it will trigger your error function. This also means that you do not have to define an error: call in every $.ajax call. ``` header('HTTP/1.0 419 Custom Error'); ``` Quote from [w3.org header informa...
[ 0.10482770204544067, 0.06203484535217285, 0.481134295463562, 0.1547527015209198, -0.16831721365451813, -0.021016808226704597, 0.5066365003585815, -0.034996919333934784, 0.016387222334742546, -0.69951331615448, -0.07268428802490234, 0.6007551550865173, -0.1550624519586563, 0.031871456652879...
may contain a document describing the error in human readable form. The document is in MIME format, and may only be in text/plain, text/html or one for the formats specified as acceptable in the request.*
[ 0.5886962413787842, 0.23250482976436615, 0.001277824630960822, 0.3064311444759369, 0.33900681138038635, 0.23592029511928558, 0.5880855321884155, 0.20769533514976501, 0.15912917256355286, -0.2401137799024582, -0.4607740640640259, 0.2379007339477539, -0.26503056287765503, -0.1433568000793457...
Situation: I entered several functions while working with REPL in Emacs. Problem: There is junk like "; Evaluation aborted" when I'm simply saving buffer. What I want: clear descriptions of all the functions I entered in their latest revision. Can I do that? Thanks. I agree that the best work flow method is to write y...
[ -0.12912170588970184, 0.061868954449892044, 0.10416802018880844, 0.010381289757788181, 0.011717953719198704, 0.16314372420310974, 0.3803350627422333, -0.06834279745817184, -0.37344881892204285, -0.7077551484107971, 0.015822283923625946, 0.8236724734306335, -0.08833076804876328, -0.11636665...
into a separate package, you could go through the symbols in the package to help you decide what you want to keep. E.g. to see all symbols created in the cl-user package: ``` (let ((p (find-package :cl-user))) (loop for s being the symbols in p when (eq p (symbol-package s)) do (format t "~a~%" s))) ...
[ 0.17816494405269623, -0.05502338707447052, 0.258124977350235, 0.11986884474754333, 0.2435114085674286, 0.004096111282706261, 0.2132272571325302, -0.4995144009590149, 0.057378463447093964, -0.2299169898033142, -0.3136231601238251, 0.5836080312728882, -0.2935083210468292, -0.359270840883255,...
I need to use a priority queue in my Python code, and: * am looking for any **fast** implementations for priority queues * optimally, I'd like the queue to be **generic** (i.e. work well for any object with a specified comparison operator). Looking around for something efficient, I came upon [heapq](http://docs.pytho...
[ -0.15144528448581696, -0.04364662617444992, 0.05626991018652916, -0.04665127769112587, -0.3896624743938446, 0.09490799158811569, 0.044713009148836136, -0.006397502962499857, -0.32464927434921265, -0.5193463563919067, 0.15809202194213867, 0.24484756588935852, -0.453886479139328, -0.10693352...
in `heapq`, I can either use a `(priority, object)` as Charlie Martin suggests, or just implement `__cmp__` for my object. You can use [Queue.PriorityQueue](http://docs.python.org/library/queue.html#Queue.PriorityQueue). Recall that Python isn't strongly typed, so you can save anything you like: just make a tuple of `...
[ -0.0934264287352562, -0.3292336165904999, -0.1418212205171585, -0.028810542076826096, -0.08235855400562286, 0.06716153770685196, -0.28116533160209656, 0.2260284125804901, -0.3105781078338623, -0.44066816568374634, 0.03231094032526016, 0.33708035945892334, -0.40698006749153137, 0.1230705827...
I'm trying to build a query with hibernate criteria for the following scenario: * Two entities: Indicator and report (each with their own tables, classes etc.) * an indicator can be used in zero to many reports * a report uses zero to many indicators * therefore, I have an intersection table to store the relationship ...
[ 0.15765273571014404, 0.14875976741313934, 0.24692302942276, 0.1032802164554596, -0.43281784653663635, 0.1377454400062561, 0.06445665657520294, -0.32012468576431274, 0.06741705536842346, -0.7834508419036865, 0.23499296605587006, 0.2674262225627899, -0.19293035566806793, 0.037643350660800934...
a strange SQL Statement with ``` where this_.Indicator_ID in (?) ``` and then a JDBC exception (missing parameter) Any ideas? Thanks. Note: I've looked into [Querying ManyToManyrelationship with Hibernate Criteria](https://stackoverflow.com/questions/264339/querying-manytomany-relationship-with-hibernate-criteria)...
[ 0.19208326935768127, 0.08044872432947159, 0.539982795715332, 0.0232420414686203, -0.11429416388273239, -0.1721048355102539, 0.24560290575027466, -0.33832040429115295, -0.2578332722187042, -0.5079669952392578, 0.030208664014935493, 0.3219805359840393, -0.41167551279067993, 0.448452889919281...
light on what you can do w/ criteria: <http://www.hibernate.org/hib_docs/v3/api/org/hibernate/criterion/Restrictions.html>
[ 0.805041491985321, -0.26960304379463196, 0.462811678647995, -0.14555726945400238, -0.06451177597045898, -0.39697226881980896, 0.2479611039161682, -0.7252570390701294, -0.17078444361686707, -0.5105452537536621, -0.1827237606048584, 0.392402321100235, -0.013608638197183609, -0.21993905305862...
With more and more projects under my belt I find that I am often repeating many common tasks from project to project, client to client. So I have started to assemble a "utility" library, a collection of these common elements that are often repeated from project to project. So far I have utilities to resize images, exp...
[ 0.5738807916641235, -0.07179562747478485, -0.08411967009305954, 0.23240357637405396, -0.08765367418527603, 0.2547239661216736, 0.0881553590297699, -0.00047022930812090635, -0.4314073622226715, -0.8552780747413635, 0.1420912891626358, 0.3170367479324341, -0.1658746898174286, 0.0081046763807...
group common elements. 1. I wouldn't write a library called 'Common' or 'Utilities' or 'Misc' or... You get the idea. Instead, I'd have a directory called 'Lib', and have each area of functionality in a separate library under that. For example, I might have Lib/Trace, Lib/UI, Lib/Net, Lib/Web for a C++ project. For C#,...
[ 0.450711727142334, 0.07637711614370346, -0.23988856375217438, -0.06247054412961006, -0.3453039824962616, -0.38620561361312866, 0.11891377717256546, -0.3400379717350006, -0.0036824161652475595, -0.5014594197273254, 0.0409749411046505, 0.2683970332145691, -0.4234457314014435, -0.013289039954...
Anyone know of a way to guarantee plugin startup order? I have a plugin that I want to develop that will provide runtime configuration information to a 3rd-party plugin that I can't modify. So, I want to make sure my plugin always ***runs to completion*** before the 3rd-party. Eclipse 3.3, BTW. The OSGi way to do it ...
[ 0.6294689774513245, -0.06380119919776917, 0.2229611575603485, 0.11638570576906204, 0.10237100720405579, -0.503190815448761, 0.005854552611708641, 0.043528735637664795, -0.2747339606285095, -0.718362033367157, -0.13312788307666779, 0.6957326531410217, -0.023389311507344246, -0.2947254478931...
any order, in general. Use the service registry to get handles to whatever you need as soon as they become available. Another way to look at it: what's causing the 3rd-party plugin to load (since Eclipse favors lazy loading of plugins)? Perhaps you can hook into the same mechanism. If you get desperate you can force ...
[ 0.2704387307167053, -0.08617334067821503, 0.4931996166706085, 0.004612994380295277, -0.11475574970245361, -0.056157488375902176, -0.012576221488416195, -0.18792171776294708, -0.39138492941856384, -0.549784243106842, -0.47559869289398193, 0.6732277274131775, -0.261675626039505, 0.0626670122...
startup extension point, so if your 3rd-party plugin uses it too, you are SOL.
[ -0.06701668351888657, -0.21628589928150177, 0.5827999711036682, -0.18172131478786469, 0.36678391695022583, 0.0009600528865121305, -0.41845983266830444, 0.3243253529071808, -0.35414695739746094, -0.6077364087104797, -0.5077453255653381, 0.439773827791214, -0.05659235268831253, 0.02412595786...
Backdrop: There are two forms, the main application form and a form to edit various settings for the operations of main application. What would be the proper way to show the frmSettings form and how to dispose it once clicked OK or Cancel in the actual frmSettings form? Perhaps a Dialog would be better suited to your ...
[ 0.4665146768093109, -0.15645821392536163, 0.5858539342880249, 0.21205183863639832, 0.07152359932661057, 0.1976308673620224, -0.1038435846567154, -0.08226414024829865, -0.27215859293937683, -0.43320128321647644, -0.03470905125141144, 0.7075956463813782, -0.272545725107193, -0.36551767587661...
the top of my head): ``` using (DialogSettings dlgSettings = new DialogSettings) { if (dlgSettings.ShowDialog() == DialogResult.OK) { ``` } } If you insist on using a form then you would have to * Instance the form * show the form * record whether ok or cancel was clicked to a form level variable (from within...
[ 0.19108977913856506, 0.13803546130657196, 0.9478586316108704, -0.03426739573478699, 0.18162642419338226, -0.27570202946662903, 0.13523873686790466, -0.2648637890815735, -0.3085026443004608, -0.43010038137435913, -0.06491195410490036, 0.4211977422237396, -0.18341732025146484, 0.022313090041...
How can one allow code snippets to be entered into an editor (as stackoverflow does) like FCKeditor or any other editor while preventing XSS, SQL injection, and related attacks. Part of the problem here is that you want to allow certain kinds of HTML, right? Links for example. But you need to sanitize out just those HT...
[ 0.3216601610183716, -0.0746426209807396, -0.062114667147397995, 0.40004339814186096, 0.06796367466449738, -0.3503701090812683, 0.10978059470653534, -0.17072294652462006, -0.21114081144332886, -0.5993577837944031, -0.05065619945526123, 0.19134600460529327, -0.3607964515686035, -0.1165049076...
because that won't allow links. Preventing SQL injection may be somewhat dependent upon your platform choice. My preferred web platform has a built-in syntax for parameterizing queries that will mostly prevent SQL-Injection (called cfqueryparam). If you're using PHP and MySQL there is a similar native mysql\_escape()...
[ 0.038527678698301315, 0.11582353711128235, 0.21761798858642578, 0.19901823997497559, -0.18384972214698792, -0.035546500235795975, 0.5142567157745361, 0.047368671745061874, -0.20473751425743103, -0.5930057168006897, 0.07190773636102676, 0.6509955525398254, -0.5332229137420654, 0.04194153472...
but have since moved away from that method because of the difficulty involved in both allowing things like links while also removing the dangerous code. What I've moved to as an alternative is XSLT. Again, how you execute an XSL transformation may vary dependent upon your platform. I wrote [an article for the ColdFusio...
[ 0.21804296970367432, 0.07453978061676025, 0.3892505466938019, -0.2010057270526886, -0.10559386759996414, -0.30755019187927246, 0.382854163646698, 0.004451662302017212, -0.188797727227211, -0.6009183526039124, 0.02129734680056572, 0.652958333492279, -0.4466567635536194, 0.17329664528369904,...
two fold. First validating that the input is well-formed XML eliminates the possibility of an XSS attack using certain string-concatenation tricks. Second it's then easier to manipulate the XHTML packet using XSL and XPath selectors than it is with regular expressions because they're designed specifically to work w...
[ 0.11104562133550644, -0.04634058475494385, 0.15459483861923218, 0.15912482142448425, -0.5039542317390442, -0.29664042592048645, 0.12489926815032959, -0.2464333474636078, -0.049503445625305176, -0.47837576270103455, -0.19690223038196564, 0.579073429107666, -0.3177214562892914, -0.2243678420...
CKEditor (he removed the F) preserve well-formed XML, so you shouldn't have to worry about that as a potential issue.
[ 0.26381760835647583, 0.21791289746761322, 0.4244583547115326, 0.3744819760322571, 0.22461049258708954, -0.20823442935943604, -0.23875916004180908, 0.5767303705215454, 0.02940976433455944, -0.45260393619537354, -0.19101667404174805, 0.17097947001457214, -0.09769819676876068, 0.0639936327934...
What is it best to handle pagination? Server side or doing it dynamically using javascript? I'm working on a project which is heavy on the ajax and pulling in data dynamically, so I've been working on a javascript pagination system that uses the dom - but I'm starting to think it would be better to handle it all serve...
[ -0.11107464879751205, -0.28170067071914673, 0.057751838117837906, 0.2690841555595398, -0.3725089132785797, 0.2238619178533554, -0.09835857152938843, 0.18343006074428558, -0.3929329216480255, -0.7766797542572021, 0.16525474190711975, 0.626950740814209, -0.11753510683774948, -0.3460512161254...
for:** * Small data set * Faster subsequent page loads So if you're paginating for primarily cosmetic reasons, it makes more sense to handle it client side. And if you're paginating to reduce initial load time, server side is the obvious choice. Of course, client side's advantage on subsequent page load times dimini...
[ -0.19465354084968567, -0.1571812927722931, 0.015717150643467903, 0.393390417098999, -0.34855735301971436, 0.19493895769119263, 0.07720805704593658, 0.381925493478775, -0.45232152938842773, -0.8853995203971863, -0.18199338018894196, 0.5080029368400574, -0.1597101390361786, -0.19077941775321...
I have a debian webserver and it is running shopsite and some php programs. Which use sendmail to send out email to customers. So this server only needs to send email out. So how do I setup sendmail to use Google Apps smtp? Because I am getting the following error: sm-mta stat=Deferred: Connection reset by mx4.hotmail....
[ 0.5528306365013123, 0.04756787791848183, 0.4220263957977295, -0.02652815915644169, -0.19789066910743713, -0.3441973626613617, 0.547508955001831, -0.07106547802686691, -0.26173555850982666, -0.7283607125282288, 0.10123074054718018, 0.43871769309043884, -0.5026416778564453, 0.085950464010238...
to read through it, uncomment the smart host line, put in the Google SMTP server, and you're done. Otherwise, you still need to set up Google Apps as your smarthost. There's a ton of Google-able info on how to do this; see [here](http://www.cyberciti.biz/faq/configure-sendmail-as-a-smart-host/) for instance.
[ 0.3020645081996918, -0.12382693588733673, 0.3100909888744354, 0.18611547350883484, 0.060775429010391235, -0.47147852182388306, 0.16680319607257843, 0.3892596662044525, -0.03256472200155258, -0.5200815796852112, -0.21332749724388123, 0.3750755786895752, -0.1347167193889618, -0.0774526670575...
By default [Eclipse](http://en.wikipedia.org/wiki/Eclipse_%28software%29) indents with a hard tab character. How do I change it to spaces? ### Java Editor 1. Click **Window** » **Preferences** 2. Expand **Java** » **Code Style** 3. Click **Formatter** 4. Click the **Edit** button 5. Click the **Indentation** tab 6. Un...
[ 0.045781210064888, 0.09306930750608444, 0.6559360027313232, -0.15038582682609558, -0.2578120231628418, 0.11557640880346298, -0.04285936802625656, -0.09394140541553497, -0.33914050459861755, -0.6772342324256897, -0.1775728464126587, 0.4843433201313019, -0.28029879927635193, -0.1652176380157...
nauseam to apply the changes. Note that the default text editor is used as the basis for many non-Java editors in Eclipse. It's astonishing that this setting wasn't available until 3.3. ### C / C++ 1. Click **Window** » **Preferences** 2. Expand **C/C++** » **Code Style** 3. Click **Formatter** 4. Click the **New** ...
[ -0.12047461420297623, 0.06556694954633713, 0.7586610913276672, -0.16034279763698578, -0.3923799693584442, 0.17489686608314514, 0.05951416492462158, -0.5055797100067139, -0.1250225305557251, -0.88143390417099, 0.21444520354270935, 0.5496413707733154, -0.22666355967521667, 0.1176561638712883...
**OK** to apply the changes. ### CSS Follow the same instructions for HTML, but select **CSS Files** instead of **HTML Files**. ### JSP By default, JSP files follow the formatting preferences for HTML Files. ### XML XML files spacing is configured in Preferences. 1. Click **Window** » **Preferences** 2. Expand *...
[ -0.20377299189567566, 0.12560920417308807, 0.7203955054283142, 0.04382973536849022, -0.10752198100090027, -0.025152668356895447, -0.052440300583839417, -0.3740358352661133, -0.503368616104126, -1.0305765867233276, -0.38128820061683655, 0.36848166584968567, -0.14398564398288727, -0.28630805...
Years ago I learned the hard way about precision problems with floats so I quit using them. However, I still run into code using floats and it make me cringe because I know some of the calculations will be inaccurate. So, when is it appropriate to use a float? **EDIT:** As info, I don't think that I've come across a ...
[ 0.7249062061309814, 0.17217053472995758, 0.16572825610637665, 0.3459867238998413, -0.39822348952293396, -0.28041478991508484, 0.11283551901578903, -0.2394588142633438, -0.3382972776889801, -0.3263756334781647, 0.41560202836990356, 0.37384355068206787, 0.006748783867806196, -0.2709984779357...
anymore outside 3D APIs as far as I know. Floats and doubles have the same performance characteristics on modern CPUs, doubles are somewhat bigger and that's all. If in doubt, just use double. Oh yes, and use **decimal** for financial calculations, of course.
[ 0.9867912530899048, 0.15772101283073425, 0.24065807461738586, 0.47163650393486023, -0.0628485381603241, -0.048875294625759125, -0.16923591494560242, 0.38506606221199036, -0.29469671845436096, -0.36664432287216187, 0.1682395040988922, 0.6780337691307068, -0.01477863173931837, -0.13788561522...
If you have an elliptic curve in the form of: ``` y^2 = x^3 + a*x + b (mod p) ``` Is there a good program to calculate the number of points on this curve? I have read about Schoof's and Schoof-Elkies-Atkin (SEA) algorithm, but I'm looking for open source implementations. Does anyone know a good program that can do...
[ -0.19085226953029633, -0.13163363933563232, 0.11483298242092133, 0.004734332673251629, -0.14301607012748718, -0.05536327138543129, -0.09383159130811691, -0.2320033311843872, -0.4421136975288391, -0.3514891266822815, -0.019960539415478706, 0.314250648021698, -0.01387274730950594, 0.11267840...
What does Pro have that's not in Standard (or vice-versa)? I need Visual Studio for personal use but I can't use the Express editions because I need T4. Here's a [nice list](http://deepdark.net/PermaLink,guid,9100f681-876b-4221-8ea9-eb7dc972be8d.aspx): > Debugging Tools: > > > * Attach to Remote Process > * SQL-CLR...
[ -0.32930245995521545, -0.10031238198280334, 0.32573872804641724, -0.1411885917186737, -0.47556614875793457, 0.1050766333937645, 0.15997140109539032, -0.45134761929512024, -0.10816632211208344, -0.29969432950019836, 0.1987672597169876, 0.7419390082359314, -0.44469285011291504, -0.1481045037...
> > Smart Device Development: > > > * Device Emulator > * Project Templates > * Debugging Tools Moocha and Filip Ekberg provided a really good reference to the [feature matrix](http://msdn.microsoft.com/en-us/vstudio/products/cc149003.aspx). --- From the comments: * ctacke: Smart device development is better sup...
[ 0.041951555758714676, 0.10849333554506302, 0.11339405924081802, 0.057804569602012634, 0.4549791216850281, 0.14627714455127716, -0.00761118158698082, -0.3402472138404846, -0.0994553342461586, -0.5200903415679932, -0.5102300643920898, 0.6022738814353943, -0.05378199368715286, -0.008882628753...
I have a custom feature, and I'd like to link to that functionality from a link on the "Create" page -- the create.aspx page that you get to from the Site Actions menu. I'd be happy to do this either declaratively within my feature's element manifest or programmatically in some feature activation code, but I have no id...
[ 0.7715827822685242, 0.04011410102248192, 0.2688601016998291, -0.16437603533267975, 0.04133649170398712, -0.10151167213916779, 0.143218532204628, 0.20352301001548767, -0.2895928621292114, -0.7024198770523071, -0.05015213042497635, 0.41539084911346436, 0.009608986787497997, -0.05190219357609...
link at the bottom of the "Custom Lists" column on the Create page that says "Chris's Custom List", and that link would point to my custom application page to initiate this custom list creation process. Here's a [nice list](http://deepdark.net/PermaLink,guid,9100f681-876b-4221-8ea9-eb7dc972be8d.aspx): > Debugging Tool...
[ 0.22734133899211884, 0.25607171654701233, 0.6299030780792236, 0.1035003513097763, -0.42176395654678345, -0.0362749919295311, -0.058864399790763855, -0.2004735916852951, -0.6694124341011047, -0.4919368326663971, 0.19111314415931702, 0.40512898564338684, 0.12681986391544342, 0.10170818120241...
2007 > * Sharepoint 2007 State Machine workflow template > > > Smart Device Development: > > > * Device Emulator > * Project Templates > * Debugging Tools Moocha and Filip Ekberg provided a really good reference to the [feature matrix](http://msdn.microsoft.com/en-us/vstudio/products/cc149003.aspx). --- From the...
[ -0.12321397662162781, 0.2239186018705368, 0.09365682303905487, -0.04056262969970703, 0.11029812693595886, 0.0565069355070591, 0.2469748854637146, -0.29691845178604126, -0.07278142869472504, -0.26473701000213623, -0.23503459990024567, 0.5562157034873962, -0.019786737859249115, 0.04812075942...
We use iText to generate PDFs from Java (based partly on recommendations on this site). However, embedding a copy of our logo in an image format like GIF results in it looking a bit strange as people zoom in and out. Ideally we'd like to embed the image in a vector format, such as EPS, SVG or just a PDF template. The ...
[ 0.6409070491790771, -0.04962931573390961, 0.626974880695343, 0.17469507455825806, -0.012529307045042515, -0.26608046889305115, -0.3306411802768707, 0.026749471202492714, -0.0026158930268138647, -0.940690279006958, -0.0066345809027552605, 0.42507994174957275, -0.22654253244400024, -0.334754...
willing to break out of AWT mode and use iText itself if it achieved the result. How can this be done? According to the [documentation](http://itextdocs.lowagie.com/tutorial/objects/images/index.php) iText supports the following image formats: JPEG, GIF, PNG, TIFF, BMP, WMF and EPS. I don't know if this might be of any...
[ 0.4274080693721771, -0.5932496190071106, 0.5678552985191345, 0.0678538903594017, -0.2940322458744049, 0.01374951284378767, 0.03319964557886124, -0.09045842289924622, 0.05609874799847603, -0.8624929785728455, -0.24852775037288666, 0.878467321395874, -0.41298606991767883, -0.1101032495498657...
using (Stream outputPdfStream = new FileStream("output.pdf", FileMode.Create, FileAccess.Write, FileShare.None)) using (Stream imageStream = new FileStream("test.wmf", FileMode.Open, FileAccess.Read, FileShare.Read)) { PdfWriter.GetInstance(document, outputPdfStream); Image wmf =...
[ 0.21263089776039124, -0.23024502396583557, 0.9005996584892273, -0.07983832061290741, -0.07522744685411453, 0.14792558550834656, 0.15880051255226135, -0.8149500489234924, -0.04797893390059471, -0.7858473062515259, -0.3109857439994812, 0.7026491165161133, -0.3800406754016876, -0.008619701489...
} } } ```
[ 0.033695679157972336, 0.4034728407859802, 0.1949702352285385, -0.15257494151592255, 0.4299153685569763, -0.20141436159610748, 0.07711705565452576, 0.4467844069004059, 0.3091506361961365, -0.5090379118919373, -0.3048633635044098, 0.5600791573524475, -0.33611243963241577, 0.3141762912273407,...
We are currently using Mysql version 5.0 in our application and are thinking of moving to version 5.1 How stable is version 5.1.30 ? EDIT When version 5.0 was released it took a long time to become stable MySQL 5.1 recently went to [GA](http://dev.mysql.com/downloads/mysql/5.1.html), so apparently the dev team thoug...
[ -0.13960745930671692, -0.23075877130031586, 0.6066181063652039, -0.24085761606693268, -0.2731149196624756, -0.3805098235607147, 0.18403765559196472, -0.381474107503891, -0.28025633096694946, -0.5675029754638672, 0.02623928338289261, 0.874576985836029, 0.2576669454574585, -0.443012148141860...
I thought I'd use Boost.Interprocess's [Message Queue](http://www.boost.org/doc/libs/1_37_0/doc/html/interprocess/synchronization_mechanisms.html#interprocess.synchronization_mechanisms.message_queue) in place of sockets for communication within one host. But after digging into it, it seems that this library for some r...
[ -0.12158940732479095, 0.06317691504955292, 0.33449843525886536, -0.14910158514976501, -0.10826914757490158, 0.21809609234333038, -0.03533937782049179, 0.07927145063877106, -0.3060123026371002, -0.5341619253158569, 0.01906137354671955, 0.564822793006897, -0.30101707577705383, 0.014419378712...
library loses in this case. Does anyone understand know why this should be? Even if it POSIX message queues are only available on some systems, I'd expect Boost to use that facility where it is available, and reimplement it only where necessary. Is there some pitfall of the POSIX system which I do not yet recognize? I ...
[ 0.15949483215808868, -0.25085875391960144, 0.08849865198135376, 0.47886261343955994, 0.011823401786386967, -0.23287242650985718, 0.20285461843013763, 0.14290644228458405, -0.2721579074859619, -0.4644746482372284, -0.0362357459962368, 0.5196763873100281, -0.3428781032562256, 0.1048474535346...
least). For all intents and purposes it made the sync classes useless. In my experience the Interprocess library is pretty immature. I use it for shared memory, and it does work pretty well but there are some rough edges and I've had to hack around some "missing features" such as dynamically resizing shared memory etc...
[ 0.11145902425050735, 0.10495536774396896, 0.04154712334275246, 0.4946819245815277, 0.0800454169511795, 0.08346214890480042, 0.37176573276519775, 0.301876425743103, 0.2363639771938324, -0.6001921892166138, 0.4399787485599518, 0.6044242978096008, 0.16715195775032043, 0.15390609204769135, -...
Is there a foreach structure in MATLAB? If so, what happens if the underlying data changes (i.e. if objects are added to the set)? MATLAB's **FOR** loop is static in nature; you cannot modify the loop variable between iterations, unlike the **for(initialization;condition;increment)** loop structure in other languages. ...
[ -0.02535216324031353, -0.09191391617059708, 0.2969675660133362, -0.28113511204719543, -0.12843279540538788, 0.3049287796020508, 0.28211742639541626, -0.2778424918651581, -0.13601894676685333, -0.33544743061065674, -0.3213440477848053, 0.2561682462692261, -0.3757455050945282, 0.066845223307...
more appropriate --- you'll be able to test the loop condition at every iteration, and set the value of the loop variable(s) as you wish: ``` n = 10; f = n; while n > 1 n = n-1; f = f*n; end disp(['n! = ' num2str(f)]) ``` Btw, the **for-each** loop [in Java](http://java.sun.com/j2se/1.5.0/docs/guide/language...
[ 0.2981584370136261, -0.0898568257689476, 0.15962843596935272, -0.010633518919348717, 0.11167942732572556, -0.1183556541800499, 0.280005544424057, -0.4178234338760376, -0.32030266523361206, -0.48520490527153015, -0.1388111412525177, 0.43152034282684326, -0.28334489464759827, 0.0163720734417...
that MATLAB supports Java objects, so you can do something like this: ``` A = java.util.ArrayList(); A.add(1); A.add(2); A.add(3); A.add(4); A.add(5); itr = A.listIterator(); while itr.hasNext() k = itr.next(); disp(k); % modify data structure while iterating itr.remove(); itr.add(k); end ```
[ -0.15669825673103333, -0.14965632557868958, 0.434991717338562, -0.3492732644081116, -0.1325228065252304, -0.061183132231235504, 0.22494563460350037, -0.555233895778656, -0.4594746232032776, -0.324091374874115, -0.42225292325019836, 0.3823900520801544, -0.5623393058776855, 0.065113991498947...
I'm looking for an easy way to track time I work on a project using the command line. I do ``` echo "$(date) : Start" >>worktime.txt ``` When I start working and ``` echo "$(date) : End" >>worktime.txt ``` When I stop working. The result is a file of the form: ``` kent@rat:~/work$ cat worktime.txt Fri Jan 2 19...
[ -0.0057177236303687096, 0.25911471247673035, 0.5769863128662109, -0.36350488662719727, 0.22138549387454987, 0.2969526946544647, 0.4209941327571869, -0.09713578969240189, -0.30287790298461914, -0.7055608630180359, -0.1512819230556488, 0.47106483578681946, 0.047851767390966415, -0.1969986706...
start date and time before : and every *even* line contains an end date and time. What I would like to do is sum up my worked time by parsing the text file using bash, tr, sed, awk and the other common Unix/Linux tools. I prefer using this approach instead of using Python, Perl, Haskell, Java etc. All ideas welcome!...
[ 0.2842920124530792, 0.23118555545806885, 0.37746772170066833, -0.01943156123161316, 0.06446054577827454, -0.12479738891124725, 0.2204878032207489, 0.02298421412706375, -0.07594960182905197, -0.8142157793045044, 0.020407618954777718, 0.17968615889549255, 0.20656666159629822, 0.1596246510744...
using `+%s` ``` #!/bin/bash total=0 while read LINE; do d1=$(echo $LINE |cut -c1-28); t1=$(date -d "$d1" +%s); read LINE d2=$(echo $LINE |cut -c1-28); t2=$(date -d "$d2" +%s); total=$(($total+$t2-$t1)); done echo $(($total/(60*60))) hours ```
[ 0.30454978346824646, 0.028413226827979088, 0.13611985743045807, -0.32259026169776917, 0.15086226165294647, 0.19931341707706451, 0.7433575987815857, -0.8650267720222473, -0.13851945102214813, -0.044952284544706345, -0.3056125342845917, 0.3956138789653778, -0.21045488119125366, 0.08705987036...
I am wondering if someone can help me figure out the best approach to the following problem. I'm building a web application which uses Django templating to construct its web UI component. There are a number of common HTML elements such as the header / footer, HTML head, masthead etc. I'd like to code these once and "in...
[ 0.7687956094741821, 0.24764728546142578, 0.13906756043434143, 0.22966007888317108, -0.05389375239610672, -0.24910365045070648, -0.13746890425682068, -0.1857481747865677, -0.33952435851097107, -0.6282663941383362, 0.24878548085689545, 0.4692228436470032, -0.21178267896175385, -0.06370452791...
foo.django: ``` <h1>My HTML Header</h1> <!-- an so on --> {% block content %} {% endblock %} <!-- html footer --> ``` Then, you can make another template, say, bar.django: ``` {% extends "foo.django" %} {% block content %} This overrides the content block in foo.django. {% endblock %} ``` ...which will then re...
[ 0.20910035073757172, 0.6804544925689697, 0.48628875613212585, -0.4291888475418091, -0.2818344831466675, -0.3193686902523041, 0.12937290966510773, -0.21545881032943726, -0.08084089308977127, -0.4725678861141205, -0.06641817837953568, 0.5830228924751282, -0.4077829420566559, -0.2191238850355...
Documentation simply states that setting `setAutosavingDelay` to anything > 0 on the shared doc controller should do it, but after calling ``` [[NSDocumentController sharedDocumentController] setAutosavingDelay:2.0]; ``` in my controller, autosave doesn't seem to work: I neither see anything in `~/Library/Autosave ...
[ 0.05229150876402855, -0.03754688799381256, 0.6759672164916992, -0.03350260108709335, 0.2582002878189087, -0.2880900502204895, 0.39987704157829285, -0.08728623390197754, -0.13543856143951416, -0.6911620497703552, -0.21500132977962494, 0.8772162199020386, -0.22559478878974915, -0.02682692557...
I have table with 50 entries (users with such details like Name Surname Location etc) I want to create a query that give me users from row 1 to row 10. Then another query that give me users from 11 to 20 and so on. Is there any way how to do that? Thanks <http://www.singingeels.com/Articles/Pagination_In_SQL_Server_...
[ -0.17113640904426575, 0.003393367398530245, 0.26539352536201477, -0.17206202447414398, -0.1728067696094513, 0.4202851355075836, 0.37029197812080383, 0.03487302362918854, -0.2640736699104309, -0.12313352525234222, 0.23519060015678406, 0.2370140105485916, 0.0842069461941719, -0.2251855283975...
When trying to compile my class I get an error: > The constant `'NamespaceName.ClassName.CONST_NAME'` cannot be marked static. at the line: ``` public static const string CONST_NAME = "blah"; ``` I could do this all of the time in Java. What am I doing wrong? And why doesn't it let me do this? A `const` object is...
[ 0.03562317416071892, 0.19155699014663696, 0.12404732406139374, -0.26687806844711304, -0.23475492000579834, -0.2516261637210846, 0.5461978316307068, 0.1864650845527649, -0.17495942115783691, -0.31477317214012146, -0.027641931548714638, 0.454250693321228, -0.3755952715873718, 0.4383392035961...
The problem I'm running into is that as far as I know the delete operator should be a static function but sometimes the compiler (VC++) seems to be treating it as dynamic. Given: ``` class Base { public: void* operator new(size_t size) { /* allocate from custom heap */ } void operator delete(void *p) { customFre...
[ 0.03465165197849274, -0.4914396107196808, 0.4180072247982025, -0.27684247493743896, 0.04818800836801529, 0.1511370837688446, -0.02038068324327469, -0.4038008749485016, -0.4156935513019562, -0.5028523206710815, -0.16397309303283691, 0.6929381489753723, -0.32242313027381897, 0.28041797876358...
deleting the base pointer will result in call to `Derived::opeator` delete. ``` Base *p = new Derived(); delete p; //calls Derived::operator delete ``` If I don't define ANY **destructors** then I get what I expected to happen: Base::operator delete is called. This seems to be happening because the compiler is inser...
[ 0.2180667221546173, -0.3562070429325104, 0.4068599045276642, -0.1909407526254654, -0.04955402761697769, -0.18477435410022736, 0.3284195363521576, -0.299988716840744, -0.32992151379585266, -0.4894208014011383, -0.235256627202034, 0.7644389867782593, -0.48304983973503113, 0.48839524388313293...
the derived class's operator new was used, *its* operator delete will also be used (also note even though you do not explicitly tell the compiler those functions are static, they *are* implicitly declared so). There might be the naughty case where you have an operator new in the derived class, but the corresponding ope...
[ 0.2470635026693344, -0.17487871646881104, -0.009161224588751793, 0.11641643941402435, -0.06861287355422974, -0.24700060486793518, 0.5420370101928711, -0.24793539941310883, -0.12891152501106262, -0.3970853388309479, -0.2708527743816376, 0.8911230564117432, -0.3002234101295471, 0.01967429928...
I expected to happen: You will get undefined behavior :) Everything can happen, including something you would expect (wrongly). Deleting through a base pointer that points to an object of another type requires a virtual destructor. The implicitly declared destructor is not virtual. > When should I be using void oper...
[ 0.21846336126327515, -0.2301086187362671, 0.3128194808959961, -0.25665849447250366, 0.1476159691810608, -0.1573089063167572, 0.4598214626312256, -0.3124549984931946, -0.4167303144931793, -0.4324248433113098, -0.1620069146156311, 0.6219140291213989, -0.45808643102645874, 0.2498256266117096,...
delete/new) the global operator new & delete to get your memory and release it, or even malloc / free, you don't need that size information. But it could be useful for logging purposes.
[ 0.06278334558010101, -0.3472250998020172, 0.585586428642273, 0.18917317688465118, 0.06832902878522873, -0.09786362200975418, 0.20417265594005585, 0.08124138414859772, -0.5215024948120117, -0.6006749868392944, -0.32235223054885864, 0.5543131828308105, -0.2350192666053772, 0.2134914100170135...
I've got a highly multithreaded app written in Ruby that shares a few instance variables. Writes to these variables are rare (1%) while reads are very common (99%). **What is the best way (either in your opinion or in the idiomatic Ruby fashion) to ensure that these threads always see the most up-to-date values involve...
[ 0.32428908348083496, 0.3060213625431061, -0.01954326592385769, 0.01884620264172554, 0.03448021411895752, 0.042311083525419235, 0.62485671043396, 0.06913720071315765, -0.37543725967407227, -0.7329433560371399, 0.20431500673294067, 0.5146923661231995, -0.20393966138362885, -0.115474238991737...
a lot of `synchronize` blocks in my code and I don't see an easy way to avoid it. * Use Ruby's `freeze` method (see [here](http://rubylearning.com/satishtalim/mutable_and_immutable_objects.html)), although it looks equally cumbersome and doesn't give me any of the synchronization benefits that the first option gives. ...
[ 0.20495468378067017, 0.12429191917181015, 0.048449885100126266, 0.15730030834674835, -0.1764792501926422, -0.1552029401063919, 0.9463407397270203, 0.10403415560722351, -0.14729973673820496, -0.4295578896999359, -0.12118753045797348, 0.30616098642349243, -0.35848918557167053, 0.407834380865...
my own and [this question](https://stackoverflow.com/questions/213312/can-ruby-really-be-used-as-a-functional-language) seems to argue that objects are highly mutable. Using the lock is the most appropiate way to do this. You can see this presentation by Jim Weirich on the subject: [What All Rubyist Should Know About T...
[ 0.3201731741428375, 0.11073209345340729, -0.1719111204147339, 0.03683120012283325, -0.16943760216236115, -0.16863366961479187, 0.6381140351295471, -0.22240811586380005, -0.33916470408439636, -0.2538450062274933, -0.08821495622396469, 0.4104427397251129, -0.24368077516555786, 0.196473643183...
Has anything useful come out of Intentional or "Language Oriented" Programming? This isn't a rhetorical question. I'm looking for people who've tried these tools (ie. representing programs in some "higher level" format than mere text and using different editors for different domain specific subsets) and have some comm...
[ 0.5740197896957397, 0.0688014030456543, -0.05664391070604324, 0.4850204288959503, 0.091883584856987, -0.39434871077537537, -0.11782743036746979, 0.12610752880573273, -0.44669103622436523, -0.21033024787902832, -0.06800990551710129, 0.5006706118583679, 0.016098029911518097, -0.5565907359123...
very helpful. You can have the spec at hand, and even document the rules in source code comments, but those artifacts don't get executed. Code is! You can also make the program very clear, but more clearer than a "language oriented" description would be almost impossible. Consider this fictional fragment. **NOTE** ...
[ 0.6041293144226074, 0.056769344955682755, -0.2527914345264435, 0.2504395544528961, -0.004173934925347567, -0.3912380337715149, 0.4235447645187378, -0.08559580892324448, -0.025378458201885223, -0.6835629343986511, -0.2868707776069641, 0.5633573532104492, -0.2102416604757309, -0.170820727944...
value = ""; Object obtained = ""; assert that( expected( value , isEqualTo( obtained ) ) ); } } ``` This is a very simple example. The value in this code is the line that gets executed says what the test is all about: ``` assert that( expected( value , isEqualTo( obtained ) ) ); ``` ...
[ 0.1402897834777832, -0.103983573615551, 0.23198319971561432, 0.016727754846215248, -0.09815657138824463, -0.09078878164291382, 0.23107711970806122, -0.4836167097091675, 0.19497203826904297, -0.31618544459342957, 0.017023764550685883, 0.7591990232467651, -0.14304819703102112, -0.10310532152...
any kind of business rule an just read it literally. > assert client mortgage is processed when it reach... etc. etc Martin Fowler explains about this and mention [Hamcrest](http://code.google.com/p/hamcrest/) a framework to do this. Here's the [link](http://www.infoq.com/presentations/domain-specific-languages) *(...
[ 0.16459183394908905, 0.3095095455646515, -0.026563942432403564, -0.30106502771377563, 0.046196796000003815, -0.5410438776016235, 0.2521492838859558, -0.39176109433174133, -0.2771497964859009, -0.1802828311920166, -0.283768892288208, 0.49859389662742615, -0.1472964733839035, -0.119338348507...
More particularly - I have a window handle of another running application. This application contains a `TListControl.UnicodeClass` control somewhere (I know this from Winspector). How can I, using the Windows API and that window handle, go through all the items in that list control and get the text from all of the item...
[ 0.010575255379080772, 0.1518440544605255, 0.26985299587249756, 0.1073802039027214, -0.18675415217876434, 0.04731166362762451, 0.4224233329296112, -0.24946460127830505, -0.2541986405849457, -0.680418848991394, -0.07785630226135254, 0.3897881805896759, -0.20121723413467407, 0.133062973618507...
use IPC of course (RPM) ask on news://comp.os.ms-windows.programmer.win32 for code.
[ 0.5457282662391663, 0.02257332019507885, 0.1310577094554901, 0.5198307633399963, 0.20132935047149658, -0.546537458896637, -0.12757712602615356, 0.06729477643966675, -0.12773703038692474, -0.3768703043460846, -0.22088104486465454, 0.6513257622718811, -0.040282875299453735, 0.023036172613501...
I'm creating a website for my church and I'm having problems making it display right in IE. It seems that my div "sidebox" is having its background position overridden by the "margin: 0 auto;" as the background displays centered rather than on the right, which is shifting the site to the right. Here's the code: ``` ....
[ 0.21471501886844635, 0.2441382259130478, 0.6713815927505493, -0.2993144989013672, 0.03497237339615822, 0.110660620033741, 0.5309248566627502, -0.15501435101032257, 0.19795726239681244, -0.646487832069397, -0.32816213369369507, 0.6486695408821106, -0.03611845523118973, -0.0085673863068223, ...
background-position: bottom left !important; width: 25px !important; } .boxtopcorner { background-image: url(images/bg-container-top-right.jpg); background-repeat: no-repeat; background-position: top left; width: 25px; height: 37px; } <div class='sidebox' style='border: 1px solid;'> I'm in the...
[ 0.20786722004413605, -0.11588937044143677, 0.49100327491760254, -0.041011981666088104, 0.08723892271518707, 0.04787148907780647, 0.19394956529140472, -0.03301360085606575, -0.2071990817785263, -0.4979735016822815, -0.505721390247345, 0.3417646288871765, -0.012783956713974476, -0.0685626417...
FF and Safari, but not in IE. My code above is without the content and removing it doesn't fix the problem. [Running page](http://victoryregina.com/newSite/church.html) Looking at it through IE developer toolbar, it gives .sidebox an alignment of center. Changing that to left seems to fix it. ``` .sidebox { ... te...
[ 0.054105207324028015, 0.18089459836483002, 0.2594950497150421, -0.06624282151460648, -0.20496219396591187, 0.14472170174121857, 0.17573533952236176, -0.14294366538524628, -0.2808268368244171, -0.7304396629333496, 0.009709355421364307, 0.4605492055416107, 0.0011471856851130724, -0.049254145...
Has anybody tried doing GSP design with Adobe Dreamweaver CS4? It has support for JSPs, but it doesn't recognize the gsp extension, and even if it did I think there would be problems regarding the gsp tags that it would not recognize. I found a little cookbook here (<http://www.bitwalker.nl/blog/using-groovyserver-page...
[ 0.520407497882843, 0.10355866700410843, 0.1924794465303421, 0.0008464159327559173, -0.15337839722633362, -0.13552072644233704, 0.10900994390249252, -0.014519747346639633, -0.33883869647979736, -0.5100159645080566, 0.046084560453891754, 0.40258756279945374, -0.07908397912979126, -0.19292728...
slight changes for Dreamweaver CS5. So five steps to go through and please make a test after each step to make sure you are on the right path. 1. **Add \*.gsp file extension to Open Dialog.** Edit %APPDATA%\Adobe\Dreamweaver CS5\en\_US\Configuration\Extensions.txt to add "GSP:Groovy Server Pages" (no quotes) to the bo...
[ -0.070936419069767, -0.17267456650733948, 0.9897794127464294, 0.22412879765033722, -0.002056779805570841, 0.06283203512430191, 0.3932685852050781, -0.07296540588140488, -0.3978649079799652, -0.7514543533325195, -0.38214510679244995, 0.5775312781333923, -0.10879728943109512, -0.125160306692...
document type as the last node. `<documenttype id="GSP" servermodel="JSP" internaltype="Dynamic" winfileextension="gsp" macfileextension="gsp" file="Default.gsp" writebyteordermark="false" mimetype="text/html"> <TITLE>GSP</TITLE> <description>Groovy Server Pages (GSP) document</description> <dtdcontext>html</dtdcon...
[ -0.18819399178028107, -0.18581384420394897, 0.9769903421401978, 0.11903273314237595, 0.23872020840644836, -0.2453705221414566, 0.2038344442844391, -0.07848405092954636, -0.30000436305999756, -0.766730785369873, -0.6349762082099915, 0.2719310224056244, 0.049692749977111816, 0.27644470334053...
for Dreamweaver](http://www.bitwalker.nl/wp-content/uploads/2007/09/gsptaglibrary.zip). Copy GSP folder with lots of \*.vtm files into %DreamweaverInstallationDirectory%\configuration\TagLibraries. Edit %APPDATA%\Adobe\Dreamweaver CS5\en\_US\Configuration\TagLibraries\TagLibraries.vtm to add content of gspTagLibrary.vt...
[ -0.08915777504444122, -0.2661932110786438, 0.8051864504814148, 0.11991780996322632, 0.09186764061450958, -0.11372793465852737, 0.1472814679145813, -0.22272980213165283, -0.33613598346710205, -0.7698219418525696, -0.42476707696914673, 0.7135101556777954, -0.35479119420051575, 0.114505797624...
have to enable code coloring. Edit %APPDATA%\Adobe\Dreamweaver CS5\en\_US\Configuration\CodeColoring\CodeColoring.xml to search & replace ',JSP,' with ',JSP,GSP,' (no quotes and pay attention to commas). Also find the line <sampleText doctypes="JSP"> and add GSP doctype there, like <sampleText doctypes="JSP,GSP"> (if y...
[ 0.0026988168247044086, -0.05722502991557121, 0.35241982340812683, 0.2787264585494995, -0.03693154826760292, -0.1142113208770752, 0.2404988408088684, -0.24743695557117462, -0.018152780830860138, -0.9678614735603333, -0.28997352719306946, 0.37354594469070435, -0.2761864960193634, -0.20271578...
in 'Styles for' list. And finally open up any of GSP files and check if it has code coloring for HTML, CSS, JavaScript and GSP tags. That's it! Hope this helps to someone! And thanks to Harald Walker for the [article](http://www.bitwalker.nl/blog/using-groovyserver-pages-in-dreamweaver) I based my research on.
[ 0.5600746273994446, -0.1999872922897339, 0.29547318816185, 0.3713444173336029, -0.044474683701992035, -0.3203396499156952, 0.19941629469394684, 0.08499313145875931, -0.43485191464424133, -0.7575143575668335, -0.41590362787246704, 0.2571038007736206, 0.13977967202663422, -0.1908701062202453...
In our site, users can have many private files. We are thinking what could be the best distribution so as to avoid destroying the server's performance, These files are served through Apache and should be listed each time the user needs to manage them. Our first approach right now is: ``` var first_level = (int) $user...
[ 0.28359857201576233, 0.2362435758113861, 0.44866764545440674, 0.030341947451233864, -0.11051724851131439, -0.1847957968711853, 0.3603638708591461, -0.05861179903149605, -0.21502140164375305, -0.952314019203186, 0.01851293444633484, 0.28982192277908325, -0.11083485186100006, 0.1111851632595...