Posts

Showing posts from June, 2010

java - How do I distribute a JOGL application? -

I wrote an application that makes fine on my machine but when I take it to another machine, then dependent The jogic library can not be found. Is it possible to create a build that can set all required JOGL files so that you can distribute your Java application with the necessary JOGL libraries? If someone can explain this James I wrote a tutorial about how to make redistributable JGL applications for multiple platforms. Tutorial uses Eclipse instead of Netbense, but the principle should be the same. You can use this system to create a JOGL application which is completely self-sufficient, so that the user does not need to install Java. The tutorial is on my blog.

vb.net - How to avoid if... else and switch cases -

I'm programming for a long time, usually in some languages, PHP, ASP.NET, Java, Javascript and others Programs in the programs. In all languages, I have to use more and more numbers. If value = 10 ... then if I review my code then I get a lot of position, if I want to reduce them, but it is not certain that is a point Classes were reduced to a lesser extent but still they are more ... Like functions, cats, seconds and types: If function = 'Junk' then if cat = "animal" then if sec = "man" then type = "male" then 'the following If you do stuff, then the end of the following stuff is if elseif sec = "horse" then if type = "play", do the following things: end the following material if elseif .... end if elseif cat = "plant "So if sec =" land ", then if type =" tree "then do the following material otherwise =" grass "then .. 'otherwise do the following material ... end if...

html - how to hide a <div> part from tabs -

I have some & lt; Div id = "hideclass" & gt; In the jquery tab I want to hide or not. I want to be able to click on some buttons after this. How do i do this Use this CSS: # Hideclass {Display: No one; } and jQuery: $ ('# button'). Click (function () {$ ('# hideclass').;}); Or you want to toggle it: $ ('# button'). Click (function () {$ ('# hideclass') .slideToggle ();}); Where #button is the ID of the button, which is clicked, will show the div: & lt ; Button id = "button" & gt;

java - How to Check available space on android device ? on SD card? -

इस सवाल का पहले से ही एक उत्तर है: 8 जवाब मैं कैसे देखने के लिए कैसे जांच करूं एंड्रॉइड डिवाइस पर कितना एमबी या जीबी बचा है? मैं जावा और एंड्रॉइड एसडीके 2.0.1 का उपयोग कर रहा हूं। क्या कोई ऐसी प्रणाली सेवा है, जो इस तरह से कुछ का पर्दाफाश करती है? उस कोड को आज़माएं statfs stat = नया statfs (पर्यावरण .getexcessarystorage डायरेक्टरी ()। GetPath ()); लंबे बाइट्स उपलब्ध = (लंबी) stat.getBlockSize () * (लंबे) stat.getBlockCount (); लंबे मेगा उपलब्ध = बाइट्स उपलब्ध / 1048576; System.out.println ("मेग्स:" + मेगा उपलब्ध); UPD: getBlockCount () - एसडी कार्ड का वापसी आकार; getAvailableBlocks () - सामान्य प्रोग्रामों (धन्यवाद जो) के लिए अभी भी पहुंच योग्य ब्लॉकों की संख्या लौटा

tfs2010 - Tibco Designer integrate with TFS 2010 -

Has anyone attempted to integrate the Dune Designer specifically for Business Works with Team Foundation Server 2010? For the moment, our Tibbon Designer is using VSS as a safe control of its source. We are planning to migrate from VSS to TFS 2010 but I could not find the solution to integrate Tibco Designer with TFS 2010. Yes Try this link: Is an open source project and it There is a working version if someone likes to be my guest then

Using the jQuery plugin ColorBox in noConflict() mode -

I'm using a jQuery plugin in ColorBox in Joomla! The subject is, and it's been a tough time to work in a noisy () mode. I have the following code that calls my jQuery and noConflict (); Call, after my actual jQuery markup: & lt; Script type = "text / javascript" language = "javascript" src = "http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> & Lt; Script type = "text / javascript" language = "javascript" & gt; JQuery.noConflict (); & Lt; / Script & gt; & Lt; Script type = "text / javascript" language = "javascript" src = "path to colorbush" & gt; & Lt; / Script & gt; & Lt; Script type = "text / javascript" language = "javascript" & gt; JQuery (document) .ready (function () {jQuery ('a.colorbox'). Colorbox ();}) & lt; / Script & gt; However, I can not get it to work under uninte...

php - Why I'm getting "cannot modify header information headers already sent by registration_model" error in codeigniter? -

इस सवाल का पहले से ही एक उत्तर है: 11 उत्तर मुझे मॉडल के साथ एक समस्या है मेरे codeigniter एप में मुझे शीर्ष लेख की जानकारी भेजने की यह त्रुटि मिल रही है असल में, codeigniter मेरे पंजीकरण मॉडल के बारे में कुछ भी पहले हेडर सूचना भेजने के बारे में शिकायत कर रहा है। यह कैसे संभव है? मैंने सोचा था कि मॉडल केवल डीबी प्रश्नों के तरीकों के लिए ही हैं और कुछ और नहीं। क्या कोई कृपया मुझे समझा सकता है? इस तरह से नियंत्रक की शुरुआत इस तरह दिखती है: फ़ंक्शन उपयोगकर्ता () {माता पिता :: नियंत्रक (); $ This- & gt; दृश्य_डेटा ['base_url'] = बेस_यूआरएल (); $ इस- & gt; load- & gt; मॉडल ( 'User_registration_model'); // पूंजी को भूल नहीं है, यह महत्वपूर्ण है कि यह $-> लोड- & gt; मॉडल ('user_map_model'); // पूंजी को भूल नहीं है, यह महत्वपूर्ण है कि यह $-> लोड- & gt; मॉडल ('ट्राइब_मॉडेल'); // पूंजी को भूल नहीं है, यह महत्वपूर्ण है कि यह $-> लोड- & gt; पुस्तकालय ('ईमेल'); // लोडिंग लाइब्रेरी $ इस- & gt; लोड- &...

java - Listing values of unknown enum -

कहें कि हमारे पास वर्ग वस्तु है इसे cls नाम दें अब cls.isEnum () रिटर्न true क्या एक खुशी है !!! क्या मैं कृपया मेरे लिए मूल्यों को सूचीबद्ध कर सकता हूं? (एक चीनी, नहीं दूध) getEnumConstants () क्लास ऑब्जेक्ट की एक विधि ऑब्जेक्ट की एक सरणी देता है सार्वजनिक स्थिर एंउम ई {ए, बी, सी, डी; } सार्वजनिक स्थिर शून्य मुख्य (स्ट्रिंग [] आर्ग्स) {class c = E.class; के लिए (वस्तु b: c.getEnumConstants ()) {System.out.println (b); }} प्रिंट्स: ए बी सी डी

.net - Convert pdf to html/xml using c# -

I want to use convert PDF to html c # Can anyone give any idea? . Edit (original link to html in PDF, not other way): , which is near (generates text) should give you a starting point in it, you explained how you can get HTML using that technique (leave code for example). And, however, there is a search for it, and you will see the link for it, which will give you the interface to PDF document.

python - How can I get the object count for a model in Django's templates? -

I am applying my own demo, I am bringing all things for a particular model like: secs = sections.objects.filter (order__gt = 5) I can use all properties of models such as this varbiles near my templates and i section . Name is a model named , section.id , etc books in which sections models when I I repeat the template in seconds varible, so how can I get count of books for each section? {{sec.books.count}} ?? Something like "Text"> Books in thanks Sections , then DJO will automatically create reverse relationships from books with sections, which is books_set . This is a manager, which means that you can use .filter () , .get () and .count () - And you can use it in your template. {{sec.books_set.count}} (By the way, you should use singular nouns for your model name, not plural - Books instead of code> book . An example of that model keeps information for a book, not many.)

PHP Plugins System -

संभव डुप्लिकेट: मैं यह जानना चाहता हूं कि php plugins सिस्टम कैसे काम करता है तो कोई भी इसके बारे में विस्तार से मेरे विचार को समझा सकता है, मैंने कई पदों और स्पष्टीकरण देखा, लेकिन मैंने इसे किसी भी रूप में नहीं समझा। मेरा मतलब था कि अगर मैं अपने लिए एक प्लगइन्स सिस्टम बनाना चाहता हूं PHP स्क्रिप्ट, कैसे? बचाव के लिए PHPplexus।

WPF lengthy Validation Scenario -

In my scenario I have a Linq2 SQL data backend. My data object applied to IDataErrorInfo like name == null (Fast Validationrules is required to execute only that value, nothing special yet) P> Dataobjects are organized to catch errors in a tree-structure, so each has a parent and child If a chosen name is unique under the parent of parents of a databizax, then how do I verify Can i do The problem is facing that, unique name recognition is a database round trip which if typing lags is required UpdateSourceTrigger = "PropertyChanged" to the name of the text box is. On the other side, I can set UpdateSourceTrigger = "LostFocus" , but the problem is that I am enabling / disabling the "save" button on valid / invalid data . Now in the invalid state you can not click on the Save button with the LostFocus, so there is no way to update the lost text box (Only remove the tab which is ugly, but there are more "unusabilities" t...

c# - Set selected value in a SharePoint Dropdown list -

We are using the SharePoint 2010 Foundation. We have a list that has a dropdown value from another list. When we access the list as a SharePoint list, then it works fine, we can select the value, save the list, next time we reach the list , Then the correct value is selected. We have created a program that will update the list. When we pull the form up, select the value and save it, we can directly access the list and see that the value has been saved. However, when we pull the form again, then it is the first item in the list that has been selected. The list has tried to store the selected value before compelling it but it is not able to work. We have found a solution. Before compelling the move list it was to get the number that is the first part of the SPListItem ToString. Parameter: / Pre> code: string selected value = current itam [fieldname]. Ostring (). Substring (0,1); // ... bind list ddlLookup.SelectedValue = selectedValue;

char encoding problem in android -

I'm getting some special character in parsing and I could not parse that character. If I try Java in four I can parse it. But in Android I can not parse that four pars. In Simlator / device I am receiving it as (box), I am getting in the log. Manually I tried to change the encoding format in Eclipse (right click on the project -> "UTF-8" as "Text File Encoding"), although it is not working .

How can I pass a Class as parameter and return a generic collection in Java? -

I am preparing a simple data access object for my Java application. I have a few squares (records) that represent a line in tables like user and fruit . Let me have a single method For this time I like this: GetAllUsers () {...} public list & lt; Fruit & gt; But I have to do a single polymorphous method like this: Public list & lt; T & gt; GetAllRecords (class type) {if (user type example) {// select JDBC and SQL * from user) Otherwise (example of forest type) {// Use JDBC and SQL * Frames} use the return archive; } Example for use: list & gt; Fruit & gt; Fruit = myDataAccessObject.getAllRecrods (fruit class); & Lt; Users & gt; User = myDataAccessObject.getAllRecords (User.class); How can I do this in Java? You say that you do not want you to have data access methods in different classes (Anish's answer In the comment), I thought why not try to do this. Public Class Records {Public Interface Recorder & lt; T ...

javascript - Should I use document.createDocumentFragment or document.createElement -

I was reflow and DOM and wondering how to document.createDocumentFragment from document .createElement is different from as it seems that none of them are present in the DOM unless I add them to a DOM element. I did a test (below) and all of them at the same time (about 95 mms) of the same estimation, this could be due to no style being applied to any element, so anybody Can not Refuge Anyway, based on the example given below, why should I use the createDocumentFragment instead of createDocumentFragment when inserting the dot and both What is the difference between var htmz = " "; For written "+ i + ' & lt; / li & gt; (var i = 0; i & lt; 2001; i ++) {htmz + =' The difference is that when you add it to the DOM, a document section effectively disappears. What happens is that all children in the document fragment are located in the node DOM , Where you insert the document section and the piece of the document is not included. Th...

java - How do I convert my BeanInvocation object in camel to a message body and headers? -

I am using a path to expose an interface as a starting point. This message uses a Bean Invocation object as the body. Based on the arguments given to the interface, how do I set up messaging bodies and headers? Public Interface Test {Public is to say zero (string first name, string last name); } I want to make body (first name + + + last name). I would also like to know how to set a logic as a header on the message and the other as a body. It uses the same bean parameter binding stuff that uses regular camel bean invocation. See the documentation about this The action in the camel Chapter 4 includes all about using beans with camels.

mysql - SQL where clause with multiple keys in same table -

I have a table with two keys and I can not break the table in two. The first key, the ID is a counter, the second key is parent_id. For example: id, parent_id, text 1, 0, Hello Steve - this bill is 2, 1, hi - how are you bills? 3, 0, Good morning Janice 4, 3, Hello - Good night to you The first record is the guardian record of the conversation and the second is the child's record. What I'm having difficulty is writing a query that gives both records for the same conversation when you pass any ID for example: Select from Select * From the table where id = 2 or parent_id = (select parent_id from the table where id = 2) * Select * from the table where id = 1 or Parent_id = (select parent_id where the id = 1) The first query will work, return the records with ID 1 and 2. The second will not be because it will return the line with the id as well 3 because if you pass 1, you will get a zero for the parent. I am sure that it is something that is missing me due to...

c# - Get a distinct list of ids from IEnumerable<T> -

I have an IEnumerable that I want to get all the specific MaterialIDs. I have a code that is working, but I was wondering if using LINQ is a better way. Here I have the code: Private IEnumerable & lt; Int & gt; GetDistinctMaterialIDs (IEnumerable & lt; TankReading & gt; Tank readings) {var specific content items = new list & lt; Int & gt; (); Foreign currency (Y tank readings in tank readings) {if different! Metiridides, canton (tank readings, metalid)) {Tank readings Metallurgy}; }} Specific Maliridides return; } Any help would be appreciated because I am learning how LINQ can help me. tank readings. Selection (o = & gt; o metired). Undoubtedly ();

asp.net - How do you get ELMAH to throw its own exceptions? -

There was an article in this article on the ELMAHs Docs site, but it seems that it has been removed. I think it is as easy as setting up a configuration setting in this section, but I do not know what it is Can anyone take a few seconds and leave the configuration setting here? ? There is a file from here Notice There are some configuration updates that will be put in place. If you need a quick tutorial, then Hanselman is with another link. I hope this will be helpful.

javascript - Cleaning up the HTML generated by JQueryUI? -

Can it be done? I am creating a template generator complete with resizable and draggable elements in a preview window. The problem is, when I generate HTML, all elements are added to all the JTUUUUUU classes and divisions, which are not desirable in the final product . I want to simplify the output HTML so that I can increase the posts and sizes so that it is my page, but I can not keep the preview window as optimized as possible and still get the clean HTML out of it. Has anyone ever done such a thing? idea? idea? Thanks in advance. Edit: In other words, I do this html process by any means: and end up with something else like this: & lt; Div id = "preview_title" value = "title" style = "visibility: visible; width: 400px; height: 16px; top: 32px; left: 12px;" & gt; Title & lt; / Div & gt; & Lt; Div id = "preview_logo" value = "logo" style = "visibility: visible: width: 50px; height: 50px; top: 123...

c# - What is the relationship between DDD and the “Onion Architecture”? -

जेफरी पालेर्मो (DDD) और "" के बीच संबंध क्या हैं? मेरे सामने - वे एक दूसरे को बधाई देते हैं - लेकिन बहुत अलग दृष्टिकोण से। प्याज वास्तुकला डोमेन / बिजनेस लैगिक बनाने के बारे में है डेटा-ऐक्सेस, यूआई, सेवाओं आदि जैसी 'अवर की' चीजों पर स्वतंत्र। प्याज वास्तुकला पर वास्तव में परवाह नहीं है कि आपने अपने डोमेन को कैसे बनाया है - यह बाहरी निर्भरताओं से रक्षा करने के लिए अविचल है। डोमेन चालित डिज़ाइन यह है कि आप अपने डोमेन को कैसे मॉडल बनाते हैं और आप अपनी ऑब्जेक्ट कहां कहते हैं। जिसका मतलब है कि प्रत्येक डोमेन कक्षा का व्यापारिक संबंध में यह दर्शाता है कि यह किस तरह का प्रतिनिधित्व करता है (भौतिक / वास्तविक दुनिया) का प्रत्यक्ष संबंध होना चाहिए। इसलिए ग्राहक ऑब्जेक्ट को कोड में एक ग्राहक का नाम देना चाहिए - इसका वास्तविक नियम होना चाहिए क्योंकि ग्राहक वास्तविक दुनिया में (या जितना करीब हो सकता है) संभव है।

jquery - $.isPlainObject($('...')) == true in IE -

It is not in FF / Chrome and I do not think it should be in IE. Does not return a plain object after all $ (), but an example of $ short Answer: No, To set up a quick test, see what the difference is: The list of assets is different in IE (at least 8) in its order, so this part (): var key; (Important in Obj) {} is grabbing the final asset in the list and checking it on a hasOwnProperty , so it's down to IE Boiling: Object.prototype.hasOwnProperty.call ($ (document.body), 'length') // true and this is another browser In (test FF / Chrome): Object.prototype.hasOwnProperty.call ($ (document.body), 'width') // incorrect Since that property list is ordered separately, this length can be trafficked in IE, and other browsers For some of us, we are getting a different result (for kick, click to include, jQuery UI on the left, change it to another custom property, tab ). : // Own properties are first mentioned, to be so fast, // i...

How do I find all elements with a specific 'name' attribute using jQuery -

I want to find all the elements on my page that have the 'name' or 'name' attribute with 'x' or 'y' P> If anything is named 'x' or 'y' in the name attribute, then .yepItHasXorY It seems like a simple thing to say that ID or How to search on the basis of the class but not the name attribute ... You can use it Do: $ ("[name * = x], [name * = y]"). AddClass ('yepItHasXorY'); However, I will add an element type, over there, or maybe : input you are only viewing the elements that you care about (otherwise it is more Expensive selector).

asp.net - Calendar Control: Have todays date selected on page load -

मेरे पास एक asp .net webform पर एक कैलेंडर नियंत्रण है I Pag_Load घटना में मेरे पास this.CalendarReportDay.SelectedDate = DateTime.Now; जो कि कैलेंडर की चुनी गई तारीख को सेट करता है, लेकिन आज की तारीख को कैलेंडर पर हाइलाइट नहीं किया जाता है। क्या किसी को आज का चयन करने के लिए आज का दिनांक कैसे पता है? चयनित दिनांक कैलेंडर की तारीख निर्धारित करेगा, लेकिन इसका अर्थ यह नहीं है कि इसे उजागर करेगा। / P> एक मुद्दा यह है कि DateTime.Now में समय शामिल है, जबकि कैलेंडर को केवल अपेक्षित काम करने की तारीख की आवश्यकता है, ताकि आप इसके बजाय DateTime.Today का उपयोग कर सकते हैं , जैसे myCalendar.SelectedDate = DateTime.Today तिथि दिखाने के लिए (अर्थात कैलेंडर को सही महीने और वर्ष को प्रदर्शित करने के लिए चयनित को दिखाने के लिए आवश्यक तिथि) उपयोग VisibleDate , जैसे myCalendar.VisibleDate = dateToUse; अधिक जानकारी के लिए, यहां पर एक नज़र डालें:

google app engine - Securing a deployed Roo/GWT application -

I've recently been able to upload the Roo / GWT project on Google App Engine. But, how do I protect it from the Google App Engine application dashboard? Many thanks, Regards. simply answered ~ same q here This process is being implemented for GWT 2.1 / Rs 1.1.0. For more information see this If you can not wait, check Spring Security in the Google App Engine article, that is not supported by RU on that approach (so when you change the generated codes, So it will be hard, but still possible, to continue using Roo)

java - Parsing an XSD to list elements -

I'm trying to type and documentation. I looked at XSOM, SACPERSER, JARSSE, JASPSPP - all of which are easy to read an XML and read nodes. It is difficult to read an XSD without the element names (to get a list of all element names). Parser. Pursue I work mostly fine with Libs (there is a well made xml as an XSD) but I'm not able to get more than that (to remove all element names) I am Am I missing anything? Anyone have any experience of similar problem? The following is a sample xsd: & lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; Xs: schema attribute default = "ineligible" elementfirm default = "qualified" xmlns: xs = "http://www.w3.org/2001/XMLSchema" xmlns = "http://abc.mycompany.com/dto/address" TargetNamespace = "http://abc.mycompany.com/sdo/address" & gt; & Lt; X: complex type name = "address" & gt; & Lt; XS: Sequence & ...

php - Find users residing between a specified distance (using user's zipcode) -

Is there a way to radial distance to use zipcode? My job is to find all users living in a specified distance. I know the user's zip Example, user between 25 miles from the current location. I have other search categories for which I am using mysql queries. I am unable to extract anything for the distance problem My backend is in phx with php and frontend. The best option for me would be something like www.zip-codes.com/zip-code-radius-finder.asp That is, if I should be able to get all zip-codes available in the specified radius distance. That's why I can compare this ZIP-code to user zip codes in my database. And select the one with the match. Please help me out. I have accomplished something like that - using your free Google Maps API - - - Google Maps API Home

is it possible to run some program in background for iphone -

Is it possible for the iPhone to run some programs in the background even if your app is closed by the user ?? I just want to know any idea that thanks The task is completed for a time when you want to run your app for up to 10 minutes of switching. After 10 minutes, the OS kills the app, after which the task is not completed. Background audio, location-based and VoIP applications are also allowed to run in the background, but if you abuse them, Apple can refuse your app to violate the spirit of the law.

Convert nested type in C# using delegates / LINQ -

मैं एक सूची & lt; सूची & lt; स्ट्रिंग & gt; & gt; को सूची & lt स्ट्रिंग [] & gt; सी # में प्रतिनिधि / LINQ का उपयोग करते हुए एक संक्षिप्त तरीके से? सूची से & lt; सूची से & lt; स्ट्रिंग & gt; & gt; ListOfLists = नई सूची & lt; सूची & lt; स्ट्रिंग & gt; & gt; (); ListOfLists.Add (नई सूची & lt; स्ट्रिंग & gt; () {"bla", "foo", "bar"}); ListOfLists.Add (नई सूची & lt; स्ट्रिंग & gt; () {"अल्फा", "बीटा", "गामा"}); ListOfLists.Add (नई सूची & lt; स्ट्रिंग & gt; () {"पृथ्वी", "चंद्रमा", "सूर्य"}); ListOfLists.Add (नई सूची & lt; स्ट्रिंग & gt; () {"cat", "dog", "उल्लू"}); सूची के & lt; स्ट्रिंग [] & gt; ListOfArrays = नई सूची & lt; स्ट्रिंग [] & gt; (); ListOfArrays = listOfLists.Select (l = & gt; एल। एओरे ())। ToList ();

How can I press a swing JButton using mouse events? -

I have a pocket (or component, literally) that I will try to think that it has been clicked and that's why Firing its action incident I do not want to call the action or doClick directly because I am trying to make a solution that normalizes beyond the buttons, and I am forced to post events. I would have thought that posting a MousePressed event would have done this in the queue of the system event, but not so. (With the appropriate location, count, etc.). Then I thought that a mouse was rotated over the mouse, the mouse was pressed, a mouse and mouse clicked mouse, but no. None of this causes the fire to fire Jebton's action as if I actually click on it. Has anyone demonstrated their actions by Pocketton driving with mouse events? Moved a JSlider with mouse events? Tree node extension? Thanks for any help. Have you tried the FireActionPerformed method? I can not stop from the top of my head, now I remember that all components are near, but if I remember cor...

data structures - Purely functional soft heap -

Is there any implementation of a purely functional data structure in any language? A quick search of the ACM Digital Library indicates that despite being very interesting, the structure of Chaseel's soft pile has received relatively less study, and continuous / functional soft heaps Thus, there is an open research topic. That's why I will not say, there are no known approaches for a continuous soft pile. Describing one would be a lucrative result (it may be boil to add duplicate where you change the original structure, and identify opportunities for sharing).

r - Combine two data frames by rows (rbind) when they have different sets of columns -

Is it possible to pair two data frames, whose columns have no set? I am looking forward to maintaining those columns which do not match after the bind.

java - Avoid unchecked warning in following -

I have done some fancy wrapping to avoid uncontrolled warnings in the past, but after over 90 minutes, Write down the findMatch method below and work it without @SuppressWarnings ("uncheck"). Parametized class is not known at compile time. Public interfaces matchable & lt; T & gt; {Public boolean matches (T-tomech); } Public square placemarching {public static object search match (object-to-match, object [] to search) (if (for example (! For matches)) blank return; Matchable match oz = (matchable) & Lt ;? & gt; matchclass = match obj.get class (); (object obj: toSearch) {/ ** * Check here that the search list is for us to test * about object, such as match object Is the same category. * This means that the mill Non-qualified class will work without exception. ** / (matchClass.isInstance (obj) & matchObj.matches (obj) back obj;} // It did not return the tap;}} The code works because in each case it is implemented by the matching t. Apple tools ...

math - countouring two xyz files -

I have two native xyz files with different resolutions - how can I structure both files I like Working with R. or open source geographic systems like GRT - If you know a different way to solve it then I would be happy to hear I have found !! I have used GMT (Generic Mapping Tools) surface roads --Groads.grd -I0.002 / 0.002 -N8 -R34 .66636708 / 34.87547842 / 31.64851241 / 31.82722429 -S0 .002 grdcontour roads.grd -Cconc.cpt -JM15c> roads.ps I did the same for both xyz files I got the Sam grid

How to Count number of lines of javascript in php files? -

I need to calculate the numbers Lines of inline javascript between script tags in php files How do I do this? Is the grep linux command sufficient or can I get some tools to do it? help please. You can use regular expressions such as to extract the contents of each SCRIPT tag in your files And compared to calculating \ n events within the content. This should match all the script tags, including regex opening and closing tags: / To count the actual rows of the JavaScript code, you must remove the tags and lines without any code.

vb.net - How to programatically create virtual IP Addresses in VB? -

What do I want to do, on 1/2/12 > I think SOAP requests are coming from many different PCs, just to make the exposure log file easy to read and I have been told that if virtual IP address is the only way to go, How to stop the range and then use them one by one in VB? (I'm gus that it is effectively buzzing the IP header?) Definitely not sure That's what you want to do but I suggest to look at the WMI class first to see what you want with it. If that class does not support it, then instead it may need to be used, where I think you can change any network setting too much, but using it is a bit more difficult. . There is a codeproject article to use INETCfg from C #, which at least can show you how to start.

Httpwebrequest / Httpwebresponse - Redirect Count -

How often did I find my web request before reaching the end of the content. I am creating my web request as follows: var httpRequest = (HttpWebRequest) WebRequest.Create ("some arc path"); HttpRequest.AllowAutoRedirect = Follow Followed; I have seen the following URL However, I do not want to apply the limit. I really want to follow all the redirects (not really in the context of all the URLs), but just for example "You have been redirected X times". I hope there is a quick way to do this: Currently, I'm assuming that I have to capture all the 3xx codes and make a new request for everyone (hopefully not!). There is no way you can achieve what you want. You must capture every 3xx request and there will be a new issue with the redirection's location header. However, if you want to use the original C / C ++ code and directly use WININET (which is the library used by IE) it will redirect you to each redirect (via the callback mechanism ) Wi...

c# - Best way to get the attribute value from HTML text -

मेरे पास निम्न है & lt; INPUT प्रकार = छुपा मूल्य = 2 नाम = hidItemCount & gt ; & Lt; INPUT प्रकार = छुपा मूल्य = "2; अपरिभाषित; 1; एसआर; नाम = 12-मई -10 बनाया; चयनित =; डीएस मौनिक = एल # %% 902; सूची आकार = 2; बनाया = 6 अगस्त 2009; संशोधित = 12 मई 2010; अनिर्धारित; 1; एसआर; नाम = 12-मई -10 बनाया; चयनित =; डीएस मौनिक = एल # एबीसीडी 12; सूची आकार = 2; बनाया गया = अप्रैल 15, 2010; संशोधित = 12 मई 2010; | " नाम = hidItemData & gt; इस से मुझे डीएस मेमनिक के मानों को जानने की आवश्यकता है जो एल # %% 902 और एल # ABCD12 । इस मामले में इस के साथ आगे बढ़ने का सबसे अच्छा तरीका क्या है? कोई भी नियमित अभिव्यक्ति? मेरा दृष्टिकोण अब तक है स्ट्रिंग स्रोत = "& lt; INPUT प्रकार = छुपा मूल्य = 2 नाम = hidItemCount & gt;"; स्रोत + = "& lt; INPUT प्रकार = छिपी हुई मूल्य = 2; अपरिभाषित; 1; एसआर; नाम = 12-मई -10 बनाया; चयनित = उपयोग करें;"; स्रोत + = "डीएस मेमनिक = एल # %% 902; लिस्ट साइज = 2; बनाया = 6 अगस्त 2009; संशोधित =...

c# - Can't understand SecurityManager.IsGranted() -

I have deliberately reduced the permissions for a method whether the IsGranted method works, but it is not. Here is my code: [FileIopermission (SecurityAction.Deny, Read = "d: \\ faz.txt")] Zero method () {Console.WriteLine (SecurityManager.IsGranted (New FileIopermission) (FileIOPermissionAccess.Read, "d: \\ faz.txt"))); } The method returns even if this method has never allowed. Anyone can tell about this problem. I do not think you are using it correctly to make you a new example of fileIIapmission Not required and use one for the method to apply. Which one goes to another problem If your safety is working properly, how can this method execute?

wordpress hybrid theme centralize footer -

In the hybrid simple subject, the footer is an alliance on the left and I want it in the sensor Have you entered the #footer {text-align: center; } in your css file? I tried to do this and it seems to work. .copyright element floats on the left, so you probably want to remove it too to get everything in the center.

How to use multiple listviews in a single activity on android? -

I have 9 list views that should come under the same activity. All lists can be displayed on screen at once (good at all times) here only The activity is a decent solution for more than one ListView, first of all the important layout file (copy from, good job!). Note that ListViews are embedded in their LinearLayouts, which are evenly weighted. "& gt; ListView Android: id =" @ + id / list1 "Android: layout_height =" fill_parent "Android: layout_width =" fill_parent "> // start Java code (you can understand import) public class enhances AnActivity activity {Private ListView lv1 = null; Private Sue Private string s2 [] = {"R", "S", "S", " Override public zeros on @reate (bundle saved instanestate) {super.naught (savedinstenstate); setContentView (s), "T", "U", "V", "W", "X"}; R.layout.main); // Get UI context // lv1 = (ListView) findViewById (...

sql - SSIS 2005 flat file source - partial row which isn't actually a partial row -

I am currently working in a database to load mainframe logs from multiple server / file sources on an SSIS package. As of this time I am using a foreach loop container to loop and data flow via records with a file a flat file source OLE DB destination via Code> and file a derived column. I have created the error code in the Data Code. To allow the work to be done for the fact that the log file will not always be in the specified location (i.e. because the server is on a particular period During maintenance) but problems are started after handling these errors. If the file has not been found immediately after attempting to load the file immediately, then it starts loading, but then throws the following warning message: [message load file source ( NORDXSL) [57] WARNING: There is a partial line at the end of the file. , and does not load all records in that file. However, when I know that files are removed, they will not be present from the record set (so that only...

javascript - Internet Explorer or any Browser F1 keypress displays your own help -

I would like to display the selected help file to the user when I press F1. It should work on every browser where I test my application I do How can the default help file be displayed? The default action of the F1 key can be changed in any browser other than AFAIK, IA. The Microsoft team generally sticks to maintain a consistent user experience in their applications, and this is why F1 has said that the help is opened without regard to return false That is, an alternative solution as the window.onhelp event. // Internet Explorer (in the "onhelp" window) window.onhelp = task () {showMyHelpInsteadOfTheUsualDefaultHelpWindow (true); return false; } // Any other {document.onkeydown = function (evt) {cancelKeypress = (evt.keyCode == 112); If (cancel sepers) {// F1 was pressed Show MyHelpInsteadOfTheUsualDefaultHelpWindow (true); return false; }} // Additional documentation is required for Opera Documents. Compact = Function (EVT) {If (Cancel kpress) returned false;...

ruby on rails - ActiveRecord siblings in many-to-many relationship -

I'm working on this one degree, but I'm looking for some inputs for inquiring in siblings Consider the following sections class Post & lt; ActiveRecord :: Base has_many: post_categories has_many: categories, via = & gt; : Postcabins end class category & lt; ActiveRecord :: Base has_many: post_categories has_many: Posts, via = & gt; : Post_categories end By definition, there may be several categories in a post, what do I need for this to show the "related posts" area on the site? As I mentioned earlier, I have a working version, which is just to do the following: Post.find (id ,: include = & gt; {categories: = & Gt ;: posts}) Any thoughts are appreciated The only problem is that I see what you already have, it is possible that you have all the posts Do not want to return a category with a post. @ post = post.fund param [[id] @related_posts = post.find (: all ,: joins = & gt ;: post_categories, select = & gt;...

axis - What the difference between JAXB and CXF? -

I have tried to create java classes from xsd and run XJC with a schema with JAXB2.1 and it works . I have included schema in a wsdl file and I use jquax with wsdl2java command using cxf. There is a Java class about the problem, where the difference is: The difference is the content attribute and its recipient and the Setter are missing with the Wsdl2java command. // // This file was generated by the JavaTM architecture for XML binding (JASB) reference implementation, see v2.1-b02-fcs // & lt; A href = "http://java.sun.com/xml/jaxb" & gt; Http: //java.sun.com/xml/jaxb< / A & gt; // Any modification in this file will be lost if the source schema is reconfigured // import javax.xml.bind.annotation.xmlAccessType; Import javax.xml.bind.annotation.XmlAccessorType; Import javax.xml.bind.annotation.xmlAttribute; Import javax.xml.bind.annotation.xmlSeeAlso; Import javax.xml.bind.annotation.XmlType; Import javax.xml.bind.annotation.xmlValue; @XmlAccessorType (Xm...

objective c - How are objects made draggable in iphone app? -

I would like to object in my view that could be dragged and dropped. When they should be dropped into a certain area, they should disappear and execute some code. How are the objects dragable in an iPhone app? Is this just a button that can be drag enabled? How will the status of a dragable object be detected? Will it be as simple as Psuedo if (draggableButton1.xPosition> like & amp; amp; draggableButton1.xPosition & lt; e, g & amp; draggableButton1 YPosition & gt; Like & amp;; & amp; amp;;; DraggableButton1.yPosition & lt; e, g) {Something} ? When the user touches the object in the method when the following method is called. - (zero) touches: touches the (NSASE *) event: (UIEvent *) Event went with the touch, the following method Will be called. - Increased touch (zero) touch: (NSSET *) touches the event: (UIEvent *) Event When the user ends with touch , The following method will be used - (zero) touch touch: (NSSET *) to...

c++ cli - Array of Array in C++/CLI or managed C++ -

How can we translate this C # code: Mesh M7 = New Aries (); M.Maxfase (New Iquirer [] ((ICKRE) Red Lip}, New Iquirer [] [] (New ICRW [] {Circle}}, Plain. XY, Toll, True); array & lt; ICurve ^ & gt; ^ ar1 = gcnew array & lt; ICurve ^ & gt; {RedLp}; Array & lt; array & lt; ICurve ^ & gt; ^ & Gt; ^ ar2 = gcnew array & lt; arrays & lt; icurve ^ & gt; ^ & gt; {gcnew array & lt; icurve ^ & gt; {circle}}; ilith IT & lt; icurve ^ & gt; ^ 1 List = GCNUE List & lt; ICurve ^ & gt; (AR1); ILITIT and LTIIITIT Lit ICWRV ^ ^ gt; ^ & gt; ^ 2 List = GCNUE List & lt; IList & lt; ICurve ^ & gt; ^ & Gt; (); List2- & gt; Add (GCNU List & lt; ICurve ^ & gt; (ar2 [0])); Mesh ^ M7 = GCNE Mesh (); M7> MacFace List 1, List 2, Plain :: XY, Toll, True); Note: It is possible that should be Plane :: XY Plane.XY , or Plane-> XY but I have assumed an AIM.

Android Storing AV files -

Are we able to store recorded files in the hidden form in addition to the SDCard in Android. Third party should not open recorded files (ie-songs, pictures, messages) AV There is no other way to apa files that your res-folder is only usable by the application.

c# - What is the maximum amount of characters or length for a Directory? -

C #? What can be a specific path for a directory of at most characters when using? > For example C: \ exam \ is 7 characters in length, what is the maximum length? CLR has maximum 260 characters for Maxpath In the Win32 API Library MAX_PATH is defined. This setting is 260 and the same settings are used, inside the CLR BCL, hard-coded, the path reaching that amount of characters probably lead to problems (see one side below). This is the maximum good old fat and maximum for FAT32 is. On the contrary, the NTFS filesystem, by default, is used on most Windows installations, has a maximum of 32767 characters and supports Unicode (in an implementation where each letter can take 2 bytes, i.e. , UCS-2, not UTF-32). But even in the NTFS, the single path segment should not exceed 255 characters. While NTFS supports very long filenames, most applications depend on System.IO . With the NET application, these filenames will not be able to see. Why not 260 and 256? Because the d...

flex - inf actionscript 3 (as3), how to pass parameter in anonymous function? -

In As3, I am adding the Event Listener and then adding the anonymous function: myBox AddEventListener (MouseEvent.ROLL_OVER, function (e: MouseEvent): zero {warning. Show (count, 'alert box');); Now this whole piece of code has gone missing n times Now, I have my box and whenever I roll my mouse on the box, it should alert the name. But, what I see is that the last value of the count is used by each box. How do I pass parameters or values ​​in an anonymous function? (As on the roll, I believe, only one variable is expected) Opportunity is created to execute the function: for (var i: int = 0; i & lt; 10; i ++) {(function (count: int): zero {myBox .addEventListener (MouseEvent.ROLL_OVER, function (E: MouseEvent): Zero {warning. Show (calculation, 'alert box');});}) (i); }

apache - Add Expire headers to ASP.NET? -

How do I programmatically add termination headers? I am not using IIS, I want to do it in ASP.net or I would like to do it with Apache, which is what I am doing. view response. Cash. Set Excerpts (Datetime. Now.AddSeconds (60)); Response.Cache.SetCacheability (HttpCacheability.Public); Response.Cache.SetValidUntilExpires (true); If you set the end of the program for a page, you will also have to set the cached-control header for the cached page. To do this, call the SetCacheability method and make it HttpCacheability calculation value public

email - HTML: cannot open client e-mail app -

For some reason, the following code does not work. I do not understand where the problem is just sending an e-mail I want to open the client e-mail app. & lt; A href = "mailto: enter-friend@address-here.com? Topic = My website & amp;; Amp; body = This e-mail has been sent to inform you about my website's website: www. Mywebsite.com "& gt; Send an email to a friend & lt; / A & gt; Safari visits the page "mail: ante-friend@address-here.com? Topic = yellow world and body = it Chrome Chrome /p> "post-text" itemprop = "Text"> You can not decide how a client works with a mailto link. Every user / browser wants to do with those links. For example, when I click on the mailbox link, I have a Chrome setup to open Gmail, obviously you do not have your setup to do anything. Here's a random link that's running on your system to do something like this -

jwplayer - JW Flv Player Error handling -

How can I trigger a trigger that runs if the JW player returns an error? For example, when JW Player says, "Video not found", I want to run an Ajax function. something Add an error event listener with the callback function Such code looks like this: & Lt; Script type = "text / javascript" & gt; Var player; Function Player Readie (OBJ) {player = document.getElementById (obj ['id']); Player.addModelListener ('Error', errorHandler); }; Function Error Handler (evt) {// Your Code Here} & lt; / Script & gt; You should check the documentation for more information. Best, Developer, Longtele Video

Tricking ASP.NET into Thinking Request is Ajax Request for jQuery File Upload -

मैं MvcContrib से प्राप्त बचाव का उपयोग कर रहा हूं: सार्वजनिक वर्ग RescueAttribute: MvcContrib.Filters । बचाव स्रोत {सार्वजनिक बचाव वस्तु (स्ट्रिंग दृश्य): आधार (देखें) {IgnoreAjax = false; } सार्वजनिक बचाव सामग्री (स्ट्रिंग दृश्य, पैरामीटर प्रकार [अपवाद प्रकार]): आधार (देखें, अपवाद प्रकार) {IgnoreAjax = false; } सुरक्षित ओवरराइड एक्शन रिंगटैट एक्शनआरसल्ट (अपवाद अपवाद, अपवाद कंसोर्ट प्रसंग) {var नियंत्रक = (स्ट्रिंग) संदर्भ। रूटडेटा। मूल्य ["नियंत्रक"]; Var एक्शन = (स्ट्रिंग) संदर्भ। रूटडेटा। मूल्य ["एक्शन"]; Var मॉडल = नया हैंडलएर्राइनइन्फो (अपवाद, नियंत्रक, कार्रवाई); अगर (context.Controller.ControllerContext.HttpContext.Request.IsAjaxRequest ()) {नई JsonResult वापस (मॉडल); } रिटर्न बेस। क्रेएट एक्शनआरिसल्ट (अपवाद, प्रसंग); }} अब जब jQuery.form में फ़ाइल अपलोड का उपयोग करते हैं, तो Request.IsAjaxRequest () गलत देता है। जाहिरा तौर पर यह इसलिए है क्योंकि आप वास्तव में एक फाइल json पर अपलोड नहीं कर सकते हैं; यह प्लगइन अपलोड करने के लिए एक छिपी हुई आइफ्रेम उ...

struts2 - Struts 2 Custom Validator issue -

I have an operation for CRYOUD operation and 3 custom validators. Two validators work correctly, but not the second. It handles verification correctly, and gives the correct errors, but if there are no errors, then the workflow is not complete, it never reach the action. It seems that it is stuck in the verifier. There is no error in the log file. If I remove the verifier, the operation ends. I am not sure what I am doing, and I appreciate any help. package com.timesheet.validator; Import java.util.Map; Import com.timesheet.action.TimeSheetAction; Import com.timesheet.util.TimeSheetClient; Import com.timesheet.util.TimeSheetHolder; Import com.opensymphony.xwork2.ActionContext; Import com.opensymphony.xwork2.validator.ValidationException; Import com.opensymphony.xwork2.validator.validators.ValidatorSupport; Public class timetable submission provides support {@ Override public throws non-valid (object arg0) validation extension {// Todo auto-generated method stub map sessio...

App Engine - Datastore vs Blobstore for user uploaded profile pics? -

Which should I use? What are the professional and cons to use each? Pictures will be below 100 kilobytes. The thumbnail of 3 kilobytes of each image will be retrieved much like the 2 to 5 on the view of each page on average Considering latency in retrieving images, retrieving images, costs in CPU time, and which other factor would be better? This question came recently and is a great and detailed one. Blobstore storage is cheap, and since the blogstor can serve images directly through your app, you will also gain efficiency and save CPU costs. In your case, caching is very important, and Bobstore will automatically cache your images. It takes more time to set up, but as the Swissquac said, the images were designed in exactly the same way. Then the answer is: BlobStore.

postgresql - how do i remove overlapping lines in postgis -

I have a typical database with polygons of one lakh, which is in the form of land parcel and I call these polygons on lines I want to split and then remove the lines that each other overlap these lines will be used to fully mappal / and or to the zoosverver, because at this time each parcel boundary is sung twice. I propose to split the parcel polygon in a new table ("border_line") and then search and delete overlapping lines. How would I go about posting these overlapping lines in postgil? Use ST_Equals: Your SQL statement might appear something Will give: SELECT y.id, mytable y from z.id, mytable z, where ST_Equals (y.the_geom, z.the_geom) query Will take forever to run, but hopefully you only have to do this once after running it, get results and carefully delete duplicate IDs. Note that it will not be able to get rid of the limitations that do not overlap properly.

.net - is it possible to access subversion from ironpython? -

There is a scripting binding in Python called 'pievon' which can be used to manipulate subdivision repositories . Is there something like this for IronPython? My test platform in Windows 7 64-bit Visual Studio 2010. Maybe. Based based solution will be better:

jsf 2 - How to dynamically add JSF components -

Can I add JSF components to the dynamic? I should have a form containing a button that contains a & lt; H: Input Text & gt; Is it possible to add to the form? I know that it should be possible in JavaScript somehow Does anyone know how to do this in JSF? I think the big problem is that I can get or set the value of new input through # {value} . A dynamic element such as & lt; H: dataTable & gt; or & lt; Ui: repeat & gt; Use & lt; H: Kickoff example with dataTable & gt; Been @ViewScoped to make sure that the list is missed on all postbacks on the same scene. ; : & lt; H: form & gt; & Lt; H: Dataable value = "# {bean.it}" var = "item" & gt; & Lt; H: column & gt; & Lt; H: input text = "# {item.value}" /> & Lt; / H: column & gt; & Lt; H: column & gt; & Lt; H: command button value = "delete" action = "# {bean .remove (item)}" /> ...

regex - How do I match a string that does not contain X with ColdFusion regular expressions? -

I asked before, but got a negative vote, so I'm rewording it. I have: & lt; Cfset myExpression = "X" & gt; #REFind (myExpression, myString) # I need to change my expression so that it returns a value other than zero if there is no x in my string, and 0 if any x mystring In. & lt; Cfset string = "abc" /> & Lt; Cfoutput & gt; #refind ("^ [^ X] + $", string) # & lt; / Cfoutput & gt; // 1 & lt; Cfset string = "abcX" /> & Lt; Cfoutput & gt; #refind ("^ [^ X] + $", string) # & lt; / Cfoutput & gt; // 0

javascript - What do the attributes do in <script for=foo event=onmouseover> -

मैंने कुछ HTML की तरह पढ़ा: & lt; script = foo event = onmouseover & gt; ... & lt; / स्क्रिप्ट & gt; बस वैसा ही सोच रहा है कि for = foo event = onmouseover मतलब? HTML 4.01 / 5 और XHTML के विनिर्देशों के अनुसार उन विशेषताओं हैं यह भी देखें। लेकिन यह पता चला है कि विशेषताएँ इंटरनेट एक्सप्लोरर के मालिक हैं, वे एमएसडीएन पर पाए जा सकते हैं, जैसे, में: EVENT - नाम निर्दिष्ट करता है ईवेंट हैंडलर का जो कि संलग्न स्क्रिप्ट के लिए बाध्य है FOR - ऑब्जेक्ट का नाम निर्दिष्ट करता है कि ईवेंट स्क्रिप्ट के लिए बाध्य है दो अन्य पेज इन के बारे में बात करते हैं अधिक गहराई के साथ विशेषताएँ: और ध्यान दें कि दोनों में एक नोट है: मानक जानकारी यह संपत्ति परिभाषित है। यह निश्चित रूप से सही नहीं है। यह भी देखें, जो विभिन्न तरीकों पर चर्चा करता है जिसके साथ एक ईवेंट हैंडलर तत्व के लिए बाध्य हो सकता है।

Table View - Increase Amount of Text to appear in Row - Objective C -

Just question, how can I display more text in a row in the table view? View table row examples of data 1) Twitter feed: See the example below, 1) How it looks at this time, and 2) How do I want to see data? This is a work ... 2) Twitter feed: This is a working feed and in this way I want to show the text in line. As you can see it is a lot of time. Thanks a million.

java - Liquibase Rollback Custom SQL -

I can not understand how to rollback custom SQL within a change. Any ideas? I want to do this: & lt; ChangeSet author = "Charlie White" id = "15" runAlways = "false" runOnChange = "False" failOnError = "true" & gt; & Lt; SQL & gt; Include in `XXXX` (` CONFIG_ID`, `NAME`,` VALUE`) YYYY; & Lt; / SQL & gt; & Lt; Rollback & gt; Remove from 'XXXX' WHERE 'YYYY'; & Lt; / Rollback & gt; "RunOnChange =" false "failOnError =" true "& gt; & lt; SQL & gt;` XXXX` (`CONFIG_ID`,` NAME `YYYY '; & lt; / SQL & gt; YYYY; & lt; / SQL & gt; & lt; rollback & gt; & lt; sql & gt;' XXXX ' Thanks for the help.

python - wxPython: how to determine source of an event -

I have a panel with many images on it, each of which is bound to the same event handler I Can I determine which image is being clicked from the event handler? I tried to use Event.GetEventObject (), but it returns to the parent panel instead of the image that was clicked. Here is some sample code: import math import wx class MyFrame (wx.Frame): def __init __ (auto, parent, id = -1, title) = "", Position = wx.DefaultPosition, size = wx.DefaultSize, style = wx.DEFAULT_FRAME_STYLE, name = "frame"): wx. Frame .__ init __ (self, parent, id, title, status, size, style, name) self.panel = wx.ScrolledWindow (self, wx.ID_ANY) self.panel.SetScrollbars (1,1,1,1 ) Num = 4 column = 3 rows = integer (math.ceil (number / 3.0)) size = ruler = wx.GridSizer (rows = rows, column = column) file name = [] I in range (number): filenames .append ("img" + str (i) + ".png") for file fn: img = wx.Image (Fn, wx.BITMAP_TYPE_ANY) img2 = wx.BitmapFromImage (img) img3...

C++ location of main -

If I main at the top of the main file and open some custom functions, it will tell me that these functions are not Found, but if I put the main under the main file, it will work. Why? Is it because the compiler parses down from the top and breaks when the main is fixed? There is nothing to do with the main C ++ compilers work from top to bottom . Whatever your reference should be declared in advance, goes to the same variable in your case, you can void foo (); // & lt; - Further announcement, aka prototype ant Main () {foo (); } Void foo () {// here is your FU implementation}

ruby - How to convert n arrays of length m into m arrays of length n? -

I am trying to change it: [[1, 2, 3] , 4], [5, 6, 7, 8], [9, 10, 11, 12]] In: [[1 , 5, 9], [2, 6, 10], [3, 7, 11], [4, 8, 12]] Is there a function to do this? If it is not, then what is the low and cleaner way? The underlying method you are looking for

string - queue.remove() in Java not working -

I'm having trouble removing any element from the queue. Through extensive debugging I found that all the elements are being added, But when I try to remove one, it gives me the same element. Here's the code: Private synchronized string access mike (four [] myInput) {String myOutput = ""; MyOutput = convertToString (myQueue.remove ()); System.out.println ("remove accesscake:" + myOutput); } // And so you can see what is happening in the converttoastring ... private string convertertoastring (four [] a) {string migration = new string (a); Return myString.trim (); } If myQueue is an example of a standard Java The chance to implement the class in the Q interface, on which you got a bug with it ... ok, enough to zero is enough that we can miss it as a possibility. If, on the other hand, you have applied your self queue, yes, maybe there may be a problem, but because mental debugging is not yet a well-established area of ​​effort, So you are g...

compiler construction - are big programming languages implemented using tools like antlr ,javacc etc -

I was getting acquainted with the ANLR, so this was the question. If I want to create a strong programming language like Java or C #, then will I use the compiler tool to create it or write handwritten code for the compiler. Are there any practical examples of widely used languages ​​while using compiler tools? Also there are performance problems with tool generated code vs. handwritten compiler. I believe Java compiler was / A unit written in the Sun, C, and Solaris had a hardware company with long investments, so they knew best. They may have used the Si-Lex / Parser, such as grammar for yacc and their java but it was certainly not ANLDR. Update: I was thinking that this was true for first javac.exe, but I was not sure. A comment below said that the current incarnation of the Java compiler is actually written in Java. You can use ANTLR as the basis for Java or C # or any other language. (I believe you can see Java grammar for ANTLR.) You start with a grammar, lex and...

java - Efficiently store easily parsable data in a file? -

I need to store passable data easily in a file as the option of database backed solution (not to debate) is. Since many of its data is going to be stored, it will be a light syntax, it is not necessarily necessary to be human readable, but it should be personal. Note that there are going to be many types of fields / columns, some of which can be used and none of these without my database, I see many options, all the problems CSV - I could technically do this, and it is very light though parsing would be an issue, and then it would suck if I wanted to add a column. Multilanguage support isfy, mainly people's own custom parser XML - this is the perfect solution from many fronts, except that parsing and overhead are a lot of tags and a huge file will be generated, and parsing Much resources will be consumed. However, in fact every language supports XML JSON - it's middle ground, but I really do not want to do this because it is a strange syntax and parsing is not trivial...

iphone - How to add action to one dynamic button in one UIView Control to move back to UIViewController -

In my application, I created UIViewController and Dynamically created UIView.In that view dynamically created subviews (UIButton and PickerViewController) I want to display the chosen picker view value in a label control in the UIViewController ... how to act on this button to return to UIViewController ... You can either pass UIViewCOntroller's reference to subview or you can click on the subview Can create fixed-end methods. Method 1: // The code below is written in your UIViewController / * You should write the implementation of initWithFrame: viewController: in UIVIEW CustomUIView * youSubView = [[CustomUIView alloc] initWithFrame: YourFrame view controller: Self]; // The code below is in custom uViv - (id) initWithFrame: (CGRect) Frame view controller: (id) vc {.... UIButton * btn = [UIButton buttonWithType: UIButtonTypeCustom]; [BTN Edit Target: VC Action: Laws for Controlling Events: UIControlEventTouchUpInside]; } Method 2: Create protocol and create a ...

firebug - Server-side with Chrome Extensions -

I was a little searched and could not find a 100% critical answer. Can you include a Google Chrome extension in a server-side language file (especially php)? I feel like the answer is 'no', can you include it in any other way? If the answer is not again, how does firebug search HTTP requests (I am specifically talking about the Net panel)? Thank you in advance. There is no "php" in the Chrome extension if not "server side" You can communicate with remote servers that have installed PHP though. You can read more about it. About detecting HTTP requests, the FF extension has more power than Chrome and has extensive access to the browser's internal API. Firebug Lite for Chrome is not yet capable of tracking HTTP requests. If you have to track HTTP requests, then there may be a solution. Take a look at this: Partial solution to this problem is now available in Chrome Now there is an event that can be passed to content scripts called...

c - regex tutorials or books -

GCC 4.4.4 c89 Does anyone know any good online tutorials which used regex goes. I have to do a lot of regogs, which I have not done before. If tutorials or books can be related to sscanf, then better than that. Many thanks, Best resource: It is not specific, but at various points, different flavors and differences are mentioned.

layout - Android view fills screen using linerlayout -

Trying to write a game, like most screens fill up with my gameview (custom view, view-generated) I want to create an area at the bottom of the screen for the message etc. In the following I am trying to put a button to clarify this issue. & lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; LinearLayout xmlns: android = "http://schemas.android.com/apk/res/android" Android: Orientation = "Vertical" Android: layout_width = "fill_parent" Android: layout_height = "fill_parent" & gt; & Lt; My.GameView Android: id = "@ + id / gameview" Android: layout_width = "fill_parent" android: layout_height = "wrap_content" /> & Lt; Button Android: layout_width = "fill_parent" Android: layout_height = "wrap_content" android: text = "action 1" /> & Lt; / LinearLayout & gt; The button never shows when it moves. If I move the button...

How to detect the print preview window of Excel 2003, with vb.net? -

I should be able to check that the preview of the current view is in Excel 2003. Is there something in the Excel object model just to use this property? (Such as the application in word object model. Printfruv ...). Any advice you are welcome, thanks Julian PS: Long story short, I have keyboard shortcuts in my custom functions I am developing a vsto addin with the cache, and I have to disable this shortcut when the print preview is on. You want to determine that it is in xlPageBreakPreview Windows (1) .View = xlPageBreakPreview then finish the '#' if your note that Windows (1) always means "active view". Edit: Read the question again and you see the meaning of the actual print preview window. This is a dialog for the application. Dialog (xlDialogPrintPreview) . This is the only method . Show . But it does not really matter because the code does not run when this code is open, it will return only two values ​​- True and False . Therefo...