Posts

Showing posts from July, 2010

symfony - Twig batch filter with if condition for creating 3 columns gallery table -

I want to create a gallery with three columns and I have used the twig batch filter, is it possible to add such a condition Which does not list all disabled images? My example is not working: & lt; Table & gt; {% 3 for items in content.galleries. Batch (3) if item Capable}}} & lt; Tr & gt; {% In cells for%} and gt; & Lt; Img src = "{{property (cell.image)}}" & gt; & Lt; / Td> {% Endfor%} & lt; / Tr & gt; {% Endfor%} & lt; / Table & gt;

java - Encode text from Tex file to UTF-8 format -

मेरे पास .tex फ़ाइल है जो लैटिन, सीपी से सार्वभौमिक एन्कोडिंग प्रकार हो सकते हैं। ..., आईएसओ-, या यूटीएफ - .. या कुछ भी। सामग्री को पार्स करने के लिए मुझे इस पाठ फ़ाइल को सांकेतिकृत करने की आवश्यकता है और फिर उसे किसी तरह के डेटाबेस प्रकार की तरह SQLite पर संग्रहीत करना होगा। जब मैं जावा का उपयोग करता हूँ तब समस्या तब होती है जब मैं tex में जापान के प्रतीक या किसी अन्य के लिए उदाहरण देता हूं, यह गलत चर चर को पार्स करता है I क्या आपको सलाह है कि पाठ को सार्वभौमिक को कैसे एन्कोड करना है कि मैं उस पार्स के बाद ठीक हो सकता हूं (मेरे पार्सर ने सिर्फ कमानों से सामग्री निकाली और इतने पर।) \ begin {Japanese} Textbf {難 し い}! \ End {जापानी} लेकिन न केवल जापानसे एन्कोडिंग के लिए, लेकिन सामान्य। मुझे पता है, वहाँ मौजूद है MathJax लेकिन मुझे सामग्री को पार्स करने और इसे डेटाबेस में पहले संग्रहीत करने की आवश्यकता है। धन्यवाद

c# - Parse.com Windows Phone 8.1 not working -

I want to ask a question related to Parse.com on Windows Phone 8.1. I have successfully installed the SDK from there, but this app crashes with the following error: Type 'System.TypeInitializationException' type a first instance exception type in Parse.DLL 'System.TypeInitializationException' was done in Parse.DLL but was not handled in user code Additional Information: Type Initializer for 'Parse.ParseClient' threw an exception I also accept Have done that for Windows Phone 8 only in Parse.com Tutorials, but we do not have the tools to test 8.0. So back to the finder, what purse should work on 8.1 or should I look for alternatives? Parscomm is no longer supported, and now it is contained

How to deal with JavaScript Error: "e is null" when try to click on browser pop-up in Firefox -

When using warning methods Seleniam- webdriver, I suffered a JavaScript error: "E Blank" code: browser = Watir :: Browser.new: Firefox browser.alert.ok; Sleep 5 Error: selenium WebDriver :: :: Error :: Unknown: [JavaScript error: "E null" {file: "File : ///var/folders/f4/rz3xgqkj22zdyldyzrnyx4v40000gn/T/webdriver-profile20l4073l-47367-tyngix/extensions/fxdriver@googlecodekcom/components/command_processorkjs "line: 7716}] [JavaScript error:" e is empty "{file:" file: ///var/folders/f4/rz3xgqkj22zdyldyzrnyx4v40000gn/T/webdriver-profile20l4073l-47367-tyngix/extensions/fxdriver@googlecodekcom/components/command_processorkjs "line: 7716}] 'when calling method: [nsICommandProcessor :: execute] environment: 'Seleniam- webdriver', '2.42.0' Firefox 31.0 Mac 10.9 Ruby 2.0 Any advice would be greatly appreciated. Thanks! After the text "itemprop =" text "> alerts me because of...

sql - When / how are default value expression functions bound with regard to search_path? -

For testing purposes, I have my now () function which is public.now () . Works mostly with my own version, but I have a table in which default pg_catalog using search_path with the default expression of (now now). To override now () () . Showing table which makes something similar to the following: start_date | Date | However, after saving a schema and restoring (in test db), generates the same show table start_date | Date | Tap default pg_catalog.now () I suppose it, in the beginning, a function in the default expression is not bound to any schema and search_path will be used to find the right one However, the dump or restoration operation seems to "tie the current" to the function. Is my understanding of the "bind state" of work right? Is there any way to keep the unbound-snap of function in dump / restored bounds? The default value is parsed on the creation time (initial binding!) Whether you have psql, pgAdmin or others There is a te...

c# - How do I change the datagridview defaults for a program -

Image
In my current project I am trying to find a way to reset the default style for all the datagrid views in my project I am I was trying to install it in the designer but these changes remain only for the first generation and then overwritten. The ultimate goal is that I will have a normal place where I can change the font size, alignment, color, etc ... and then those changes will be seen throughout the program. It will keep every Data Grid view in its project, without repeating the 20 times the values ​​of each separate datagrid view. Update: The method of loading the DataGrade view was changed so that instead of setting all the data, instead of setting up a dataset, then we went to the dataset on Gridview and now we have done it in the Datagridware method (Designer With all the column settings) and only rows in the method. (Too many 'cleaner' solutions moved from line 1 line to 30 lines of code to load line) You can do the sub code in the DataGridView class and s...

SVG animation does not set attributes as expected -

I am trying to animate the change of the viewport of the SVG element. When a special ellipse is clicked in SVG the viewport changes, so that it is zoomed in on the oval. From my interpretation of the W3C Chetan specification, when Fill = "freeze" is used, the value will be left in the to attribute. However, when I use console.log ("After the animation:" + canvas.getAttribute ("viewbox"); the view box is similar to the first (the animation does zoom in). For additional information, & lt; Chetan & gt; is added when the oval is clicked on the code that the animation is & lt; Svg & gt; ; var canvasassap = snap (canvas); Var animation = '& lt; Anamat ID = "Suspension" attribute name = "View box" start = "0s" Fear = "'+ + + duration + ms" = "0 1280 720" = "' + + + + + + + + + + + + Miniwai + '' + (max-minex) + '' + (max-minway) + '"fil...

java - Hibernate - Extract parameter values from SQL query -

I have a class that populates the Hibernate SQL query parameter with different values ​​depending on some input criteria. is. I would like to write the test for the resulting query. As of now, I have not found a way to get a parameter value that was set to the query. I saw the resulting query implementation (in this case, SQLQueryImpl) and there is a method called GetParameterMetadata (), as if something can give me, but I can not find anything. I want to be able to do something like this: assertEquals ("some value", query.getParameterValue (parameterName)); Is there any way to do this? Edit: I just saw a little more, and give me a query.getQueryParameters (map) .getNamedParameters () Which gives a map I believe that the map contains parameters and their value. I correct me if I am wrong. In fact, I did not consider this fact because I tested, I could just duplicate the query I can expect specific criteria.

ssl - Java WebSocket get distinguished name of client -

I have a Java website server running on the glassfish, and users want to connect using client TLS certificates that we Give them The certificate has a specific name that we used to identify the user once a connection has been made to server endpoint , my @OnOpen method is called And it is called the session object. I can tell that if is session.isSecure () , but nothing more than that, the session object does not give me any visibility in the properties of the TLS connection. How do I obtain the client's specific name when I'm connected via WebSocket? I believe that can be done in webbook handshake () only. Websocket is "upgraded" from an HTTP request and the request details are only available during that upgrade request. You can try to remove the user principal from HandshakeRequest , which is normally sent to you by X500Principal .

bash - zsh doesn't use my $PATH correct -

मैं ~ / .dotfiles / bin से एक स्क्रिप्ट चलाने की कोशिश करता हूं, लेकिन zsh इसे बजाय बैश नहीं मिला: ➜ ~ बिल्ली ~ / .dotfiles / bin / dotfiles-test #! / Bin / bash इको 'नमस्ते विश्व' ➜ ~ गूंज $ पैट / यूआरएस / लॉक / शेयर / एनएमएम / बीन /: / / डीटफ़ाइल / बीन: / यूएसआर / एलओसी / बीबीआई / यूएसआर / एलओसीएल / एसबीएन: / यूएसआर / एलओसीएल / बीन: / यूज़र / बीन: / बीबी: / Usr / sbin: / sbin ➜ ~ dotfiles-test zsh: कमांड नहीं मिला: dotfiles-test ➜ ~ bash bash-3.2 $ source .exports bash-3.2 $ इको $ PATH / usr / local / share / npm / bin /: ~ / .dotfiles / बिन: / usr / स्थानीय / बिन: / usr / स्थानीय / sbin: / usr / स्थानीय / शेयर / NPM / bin /: ~ / .dotfiles / बिन: / usr / स्थानीय / बिन: / usr / स्थानीय / एसबीआई: / usr / local / bin: / usr / bin: / bin: / usr / sbin: / sbin bash-3.2 $ dotfiles-test नमस्ते विश्व bash-3.2 $ बस ~ / .dotfiles / bin से $ HOME / .dotfiles / bin ।

asp.net - Advice on setting up multiple projects for an application with multiple customer sites -

I have some advice on how to establish an ASP.NET MVC application, on which a client portal and multiple client sites. The client portal allows any customer to log in and manage their sites. Each person's site is accessed by customers and they need their own customer database, which has the ability to login via social login provider. A client application can be a user of many sites and will have a separate login for each How can I create the best structure of projects within the solution, and separate login on all sites Am I My current thinking is: DLL / Customer Presentation Project (View and Controller for All Customer Projects) This is my first multi-project solution, so any advice would be greatly appreciated! which manage all client logins and management

apache - Symfony2 not redirecting to app_dev.php - httpd.conf is setup to redirect but not working -

So I think that if I do not use the .... / app_dev.php path then I One issue is to start the app: The app does not display the latest CSS file updated by me. If I manually navigate to app_dev.php and start exploring the app from there, all of this works very well otherwise if I do not manually navigate to app_dev.php, then I would like to get older CSS And if I try to do anything in style and nothing gets changed, as if the CSS has been cached. The problem is that if I am using "localhost" which does not redirect it to app_dev.fpp even though I have the following in the httpd.conf file: RewriteRule ^ (. *) $ /app_dev.php [QSA, L] Do I have to do something else to create a redirection? I tried to clear the browser and symphony cache, I restarted the PC, restarted the server (which included Apache) and nothing about this issue is changing.

sed - regex idiom for excluding word while matching other conditions -

The problem is as follows: I need to match every line: starts with tags ; & Gt; & lt; Div & gt; BubbleBall & lt; / Div & gt; BubbleBall & lt; / S & gt; & Lt; Div & gt; BubbleBall & lt; / Div & gt; & Lt; S & gt; BubbleBall & lt; / S & gt; I pre negative Lukahed and wildcard ^ & lt; Trying to insert (?!?! & Lt; s & gt;).) * & Lt; / S & gt; $ And thought about it, but there is no success so far. I am also aware of grep -v but I have a pure regex phrase that I can use in other references (e.g. You can use the following regex: ^ (?. * gt; & gt;) * * & Lt; / S & gt; $ Explanation : ^ # is not the beginning of the string (?! # Is not it, to see if the :. * # \ n excluding any character (0 or more times) & lt; s & gt; # '& lt; s & gt;') # finally look forward & LT; # '& Lt;' . * # Excluding any character \ n ...

c# - CLR / High memory consumption after switching from 32-bit process to 64-bit process -

I have the backend app (Windows Service) built on the top of the .NET Framework 4.5 (C #). This application runs on Windows Server 2008 R2 server with 64GB of storage. Due to dependence on me, I let it use 32-bit process (compiled as x86) / LARGEADDRESSAWARE flag more than 2GB of storage in the user space. Using this configuration, the average memory consumption (according to the "Memory (Personal Work Set)" column in the Task Manager) was approximately 300-400MB For this reason I needed a bigger flag, and the reason I changed it to 64-bit, that is, though 300-400 MB is average , once it is applying the stuff in which there is a lot of data loading in memory (and when you have a lot Memory-Not So Interested Not the development and management is very easy). Recently (after removing those x86 native dependencies), I changed the application compilation to "a CPU", so now, on the production server, it runs as a 64-bit process When I made this change, the aver...

Android - Update ListView not Working -

I'm trying to update a ListView on Android. I insert new items in the list and then notifyDataSetChanged () Calling and nothing happens! And I'm using runOnUIThread, which should work right? This is my code: @Override // This is where I am creating ListView with my custom adapter. Creature Protected Zero (Intrastance saved from bundle) {super.onCreate (SavedInstanceState); . Globals.getInstance () readWarehouse (this); Toast. Make text (this, "E:" + Globals.Just Instance (). GetWarehouse (). GetJointNames (). Length, toast .LENGTH_LONG). Show (); SetContentView (R.layout.activity_main); Adapters = new customist (Main activity. These, Globals.tastinstance). GetWarehouse ()); List = (ListView) findViewById (R.id.list); List.setAdapter (adapter); } Then I edit the content of this appeller on other activity .. I am adding more stuff .. And I am back to this activity and then I refresh the list I call this method to do .. but nothing is happy .. Here is the cod...

javascript - How to send to a web-server request for performing js-function under c#? -

First of all, English is my foreign language under C # I receive an audio file (stream) with the accent of some words. Trying to send a post http request to forvo.com (bank with the pronunciation of words) For example, I want to click on button 1 and want to hear the word "stack" From the .com site. I have a code for this: use (var wb = new webclient ()) {var data = new nameValueCollection (); Data ["LANGUAGE_ID"] = "3 9"; Data ["WORD"] = "Monday"; // This tag is not effective for requesting // var response = wb.UploadValues ​​("http://www.forvo.com/search/", "POST", data); Byte [] response = wb.UploadValues ​​("http://www.forvo.com/search/data", "POST", data); File. WritAllBytes (Path.GetDirectoryName (application.ExecutablePath) + "\\ fi2le.html", feedback); } With that action, I am trying to get the link for an audio file. After viewing a file.html I see these strings & ...

javascript - HTML Json parsing strings -

I am using html and JSON. What I'm doing is leveling a game in JSON and parsing information in JavaScript. I have no problem in doing this when the information is an integer, for example I will just correct the following: For (var i = 0; i & Lt; curNode.options.length; i ++) {var x = parseInt (curNode.options [i] .x); Var y = parseInt (curNode.options [i] .y); // set choice = new option (view); Choice.setPosition (X, Y); } even further. I can do it with width, height etc., but I'm not sure how to do it when working with the string. You can easily type in: Var avariable = 3; Var astring = avariable + ''; Var anotherstring = new string (avariable);

javascript - mongodb unexpected behavior when saving subdocs -

मैं एक मोंगोज़ .find क्वेरी के बाद यह करता हूं: data2 [0] .videos [अस्थायी] .markModified ( 'fakeName'); Data2 [0] .ave (फ़ंक्शन (त्रुटि, उत्पाद, संख्या प्रभावी) {if (err) {console.log ("मेनिफेस्ट सहेजने में त्रुटि") console.log (err); var back = {success: false, reason: err} ; कॉलबैक (वापस); वापसी;} अगर (numberAffected & gt; = 1) {console.log ( "बचाया प्रकट", product.videos [अस्थायी]); वर वापस = {सफलता: सच}; कॉलबैक (वापस); वापसी; } और {console.log ("कुछ भी नहीं बचाया"); कॉलबैक ({सफलता: झूठी}); वापसी;}}); कौन इस प्रिंट: प्रकट बचाया {fakeName: 'devrenameTest', नाम: 'bkdyZVb--', संस्करण: 1, DateCreated: 1406846165732, dateUpdated: 1406846165732, vidLoc: '[हटाया यूआरएल]', thumbLoc: '[यूआरएल हटाया]', लेखक: '53a47a469c52c9d83a2d71d9', _ id: 53dac4d533c061dd0b000007, sharedWithGroups: [], sharedWith: [], टैग: []} ऐसा लगता है कि सही काम किया है? लेकिन फिर अगर मैं अपने डेटाबेस पर गौर करता हूँ,...

Not repeating selectors in a conditional statement with JavaScript/jQuery -

I have a small app with a form and an input field. When a user submits this form, then I first want to see that there are only letters in the price if everything is fine, then I want to give value to the function. What do I have here: $ ('form'). On ('submit', function (e) {if ($ ('input'). Val (). Match (/ ^ [a-zA-Z] + $ /)) {someFunction ($ ('' input '') Val ());} Else {// error message or something else} e.preventDefault ();}); I do not like to write $ ('input'). Val () Twice (conditional statement once, and if it is true) using will not work, because it is within conditional statement and there is no function of any kind Is there any way to repeat the code in this scenario? Maybe setting $ ('input'). Val () will be the best in a variable? Thank you! Just do this: var inputValue = $ ('input '). Val ();

javascript - Trying to modify a show/hide script so first div opens on page load (Django project) -

I'm working on a blog feed and there is a script which currently opens a Divel and it Divijh () Displays content on click; However, I have the first device in the feed when the page loads and I am still struggling to understand it. I am a serious Django and Javascript / jQuery Noobi, so any help offered with this is greatly appreciated. The rest of the work currently loads the page feed, all the divisions are closed and when they are selected they are open. base.html & lt; article id = "entry - {{object .pk}}" {% if continue_reading%} onclick = "toggleArticleActive ( 'entry - {{object.pk}}', true);" {% Endif%} & gt; ... blog post content & lt; / Article & gt; tools.js function Toglartiklaktiv (Lek_am_aidi, Aiaiaktiv) {if (Aktiv_aktiv) {// disable that activate all $ ( 'active' ). Each (function (index, value) {toggleArticleActive ($ (this) .attr ('id'), incorrect);}); } Var a = $ ('#' + article_dom...

java - Jetty redirect and context path -

I have an application running on an embedded jettie server I have defined the reference path: circacton handheld reference = ... context.setContextPath ("/ dev"); I can present my app correctly When I use the transmission reduct function of the HTTestreseter: Resp.sendRedirect ("/ log in"); The formation URL is not using contextual reference http://application.com:8080/login for the return of http: //application.com:8080/dev/login How do I get this path? When you call sendRedirect () one place "/ ", It is always related to server root, not in the application context. To achieve whatever you want, you must add a reference path by yourself, ex: response.sendRedirect (request.getContextPath () + "/ login"); To make it work in all contexts, it is better to do better: response.sendRedirect (response.encodeRedirectURL (request.getContextPath) + " /log in"));

mysql - PHP check database for user ID -

I am sending data with jquery ajax to a php doctor first check on user information ( $ check_user_exists ) is to see if there is an account under $ email ? If I tried to write the function before the statement, but that too is not working. I am getting the following error: Parse error: Syntax error, C: \ xampp \ htdocs \ workflow \ ajax \ register.php on line 8 Unexpected 'Return' (Thanks before time)! Here's the code: if (isset ($ _ POST ['email']) and isset ($ _ POST ['firstname']) and amp; and isset ($ _Post [last name ']) and release ($ _ POST [' role ']) and dispatch ($ _ POST [' pw '])) {$ email = strtolower ($ _ POST [' email ' ]); $ First name = $ _POST ['first name']; $ Lastname = $ _POST ['last name']; $ Pw = crypt ($ _ POST ['pw'], MD5 ($ email)); $ Role = $ _POST ['role']; $ Check_user_exists = Return (mysql_result (mysql_query ("Select 'user_id` from user' wh...

javascript - why doesn't this backtracking recursion go to other branches? -

Looking at an array, and a goal (number), I have to determine whether to attain goals by adding elements The array is my code here (in javascript), and some results: function check (target, array) {function add (sum, array) {if (sum == goal) return True; And if ((Yoga> Goal) || (! Array [0])) false return; Else console.log (sum); // Check where we add back (sum + array.shift (), array) || (Yoga, array); } Add return (0, array); } I expect the add () stack to be made after calling (6, [1,3,5]) Add (0, [1,3,5]) // log 0 (1, [3,5]) // Add log 1 (1 + 3, [5]) // Add log 4 (1 + 3 + 5, []) // return false addition (1 + 3, []) // return false addition (1, [5]) // add log 1 (1 + 5, []) // return true return (1 (0 + 3, []) plus (0 + 3, []), ([0, [5]) plus [0, [3,5]) plus (0 + 3, [5]) plus (0 + 3, []) ) Add (0 + 5, []) (0, []) Add actual result: check (6, [1,3] , 5]]) false 0 1 4 check (3, [1,3,5]) false 0 1 1 This is the first branch It also does not leave! Why ? Edit: ...

css - Display first occurrence after a class that is nested -

To show the class .tab-wrapper , the rest should not be displayed & lt; Ul class = "tabs" & gt; & Lt; Li & gt; 1 & lt; / Li & gt; & Lt; Li & gt; 2 & lt; / Li & gt; & Lt; / Ul & gt; & Lt; Div class = "tab-cover" & gt; & Lt; Div class = "tab" & gt; Won & lt; / Div & gt; & Lt; Div class = "tab" & gt; & Lt; / Div & gt; & Lt; Div class = "tab" & gt; & Lt; Ul class = "tabs" & gt; & Lt; Li & gt; 1 & lt; / Li & gt; & Lt; Li & gt; 2 & lt; / Li & gt; & Lt; Li & gt; 3 & lt; / Li & gt; & Lt; / Ul & gt; & Lt; Div class = "tab-cover" & gt; & Lt; Div class = "tab" & gt; Won & lt; / Div & gt; & Lt; Div class = "tab" & gt; & Lt; / Div & gt; & Lt; Div class = "tab" & gt; & Lt; / Div & ...

arduino uno interruption code 2 leds 1 switch -

I have tried to make a blockage in my arduino uno board, the wired is connected correctly, but I do not know What is wrong with the code .. What do I need is that Leadership 1 is running by default and when I press the switch button it stops the functioning of 1 and starts making a loop for the lead 2. I've checked the code several times and I still do not know the mistake in code int led1 = 13; Int led2 = 12; Int button = 0; Boolean x = false; Zero setup () {pinomoda (lead 1, output); Pinomoda (lead 2, output); Pinomato (button, input); AttachInterrupt (Button, ledchange, CHANGE); } Zero loop () {digital light (lead 1, high); // current LED (high voltage level) // delay (1000); // 1000 ml-sec} wait for zero lidchange () {x = true; DigitalWrite (LED1, less); For (int i = 0; i Any suggestions? @TOMATO The right delay is not going to lead to an ISR, because all interrupts are disabled, Will not be out Unless you re-enable the interrupt without the lead () {interru...

NSMatrix bindings mayhem -

I want to use the NSMatrix so that a 6- day work for employees (columns) week (6 rows) Fwaiai, since NSTableView does not cell-to-cell drag-and-drop support, oh I have to instead use NSMatrix . However, I want to use NSArray content for coke binding, NSMatrix . If I have an employee, then there will be 6 items in my array. However, if I add another employee, then the data of the employee 1 also needs to be captured on the array index (0-2-4-6-8-10), and the data in employee 2 is a weird index (1 -3-5-7- 9-11). If I want to remove Employee 1 now, then I have to remove 10,8,6,4,2,0 items in that order! Yowza Am I reading this right? Is anyone else related to this madness? Actually, my initial arguments were correct - that is, with the built-in array for the content, NSMatrix returns That the material is from top to bottom to top, an array of 10 elements in 5x2 matrix will be kept with these indices: 0 1 2 3 4 5 6 7 8 9 > so I pieces of a couple of cod...

Heatmap with text in each cell with matplotlib's pyplot -

Image
मैं matplotlib के साथ एक हीटमैप साजिश करने के लिए उपयोग करता हूं: plt डीईएफ़ हीटमैप (डेटा, शीर्षक, xlabel, ylabel के रूप में एन पी आयात matplotlib.pyplot के रूप में आयात numpy ): plt.figure () plt.title (शीर्षक) plt.xlabel (xlabel) plt.ylabel (ylabel) c = plt.pcolor (डेटा, edgecolors = 'k', linewidths = 4, CMAP = 'RdBu', vmin = 0.0, VMAX = 1.0) plt.colorbar (ग) डीईएफ़ मुख्य (): शीर्षक = "आरओसी के एयूसी" xlabel = "शिफ़्ट होने के समय" ylabel = "तराजू" डेटा = np.random.rand (8,12) हीटमैप (डेटा, शीर्षक, xlabel, ylabel) plt.show () यदि __name__ == "__main__": मुख्य () क्या प्रत्येक सेल में संगत मान जोड़ने का कोई तरीका है, जैसे: (Matlab से) (मेरे वर्तमान आवेदन के लिए मुझे अतिरिक्त % की आवश्यकता नहीं है, हालांकि मुझे उत्सुकता होगी भविष्य के लिए जानने के लिए) आपको axes.text () , यहाँ एक उदाहरण है: plt title = के रूप में एन पी आयात matplotlib.pyplot के रूप में आयात numpy "आरओसी के एयूसी" xlabel = ...

c# - Access a class instance inside a other class from xaml in wpf -

मेरा वर्ग इस तरह दिखता है: सार्वजनिक वर्ग परीक्षण वर्ग {सार्वजनिक सूची & lt; अन्य क्लास & gt; संदर्भ {मिल {वापसी _references; }}} मेरा अन्य क्लास इस तरह दिखता है सार्वजनिक वर्ग अन्य क्लास {सार्वजनिक स्ट्रिंग का नाम {get; सेट; }} और अब मैं "DataTemplate" के अंदर इस "अन्य क्लास" का उपयोग करने की कोशिश करता हूं & gt; DataTemplate x: key = "templateCore" DataType = "{ X: प्रकार vm: AdminInterfaceViewModel} "& gt; & Lt; ग्रुपबोक्स डेटाकॉन्टेक्स्ट = "{बाध्यकारी संदर्भ}" & gt; ... & lt; / DataTemplate & gt; यह ठीक काम करता है, या मुझे लगता है कि कम से कम, बेकिंग इंटेलिसेंस स्वत: पूर्ण है। लेकिन अब मैं "अन्य क्लास" के नाम की संपत्ति तक कैसे पहुंच सकता हूं? आपको बस जरूरत है आइटमों को सूचीबद्ध करने के लिए सूचीबॉक्स्, डेटाग्रिड आदि, और आइटमोंकंट्रोल सूची में "अन्य क्लास" का प्रयोग प्रत्येक आइटम के लिए डेटाकॉन्टेक्स्ट के रूप में होगा.तो आप वहां एक 'मैपिंग' पा सकत...

How to make Anaconda python work in Emacs on Windows -

So I installed anaconda on my Windows 7 computer. Now how to lift it and run it in Imax? I tried to call Mx run-python I get an amazing error message: apply: Spelling child process: invalid argument My Python is on the executable path I tried to change the variable Python-shell-interpreter "python" for "python.exe "Should be . What does it have to do if there is no effect? I kept these lines of code in my .emacs, but still found the same error. (setq dragon-shell-interpreter "c: / user / my user / anaconda / python.exe") (setq Python-shell- virtualwave-path "C: / user / my user I think you can make emacs a "virtual element" and "emacs" By behaving like can indicate a different Python. Then (setq Python-shell-virtualenv-path "/ path / to / anaconda /") should do this. If you want to use a condo environment, replace / path / to / anaconda with the path of the environment such as / path / to / ...

docker - Is it possible to upgrade image of an existing container? -

I want to upgrade an image where a current container moves. After performing Docker Bridge , I got the latest image but the container is still running on the old image. Is it possible to run the existing container on the latest image? Thank you. This is not possible at this time, but one open to support the case of this usage is open.

jquery - how to open a dialog box after clicking a table row and edit -

I want to apply a dialog box which will open as soon as I click on a table row. Basically the database is edited through table rows, the table contents are stored in the database and received from there. If I edit the line then the database should be automatically updated. When I click on the line, the dialog box will receive some special cells from the row and I'll modify it or delete the row and should be visible immediately in the results table. I want to jquery it through AJAX, after opening the dialog box, Ajax should call the servlet and modify the database. Please also give the code. & lt; Fieldet id = "alltweets" & gt; & Lt; Table cells = "20" square = "tweet table" & gt; & Lt; Title & gt; Tweets & lt; / Heading & gt; & Lt;% while (rsnext ()) {%> & Lt; Tr id = "ForChangingTweet" & gt; & Lt; TD & gt; & Lt;% = rs.getString (1)%> & Lt; / TD & gt; & Lt; TD ...

java - Converting Lists of Lists into String array -

I want to change the list's lists into two different string arrays. I type the tag array in the string array tagar [] and tokenist in the array named Tokeny . I have tried many ways to change but there are several ways to change converting an ArrayList to 2D array but I list of lists Strong> Any string to convert to string array can not be found. Anyone can help me do this. Tag list [[non, non], [non, non], [non, non, non], non, non ], [ENTI, ENTI]] tokenist [[John, ran], [john, jump] [The dog, jump], [Mary, SAT], [Finland, India]] I tried the following methods for (int I = 0; i & lt; tokenlist.size (); i ++) {string [] word = tokenlist.get (i); } When I use the above method I am getting the output but the problem is that I have to take the same tokenlist and tag list at the same time. I have to convert it to a 3D array with the following format [last] string [] [] [] WORDS_TAGS = new string [] [] [] {{" John ","...

windows runtime - Win RT how to place button in specific coordinates? -

I am trying to put a button in a special x and y values. Is it possible in Metro C # (Windows Store app) You have two main options and one Less is obvious. If your button is in a canvas panel - then you can Canvas.X and Canvas.Y can set the attribute properties on the button, the desired value. If your button is in default 1x1 cell grid - you can horizontal alignment = "left" vertical alignment = "set" heading "Margin =" 10,20,0,0 " where 10 and 20 x and y values ​​are. If you want to animate the coordinates (one With button is not normal, but who am I to judge) - It is best to use a RenderTransform to create this situation, you give it the original coordinates of 0,0 You can set using one of the earlier methods, set translateTransform to set RenderTransform and set the transform code X And y Properties for the desired values ​​This idea is that the properties of RenderTransform can be easily animated, while ...

javascript - Use Highcharts-ng with JSON -

To display the chart, Y uses strategic methods: var Myapp = angular module ('map', ["hicharart-ng"]); Myapp.controller ('myctrl', function ($ scope) {$ scope.highchartsNG = {option: {chart: {type: 'bar'}}, series: [[data: [10, 15, 12, 8, 7] ]}], Title: {Text: 'Hello'}, Loading: Incorrect}}); & Gt; But I want to load the data from a remote Jason. I tried to use the method described in the official document, but it does not work with the angle. I am using Highchurch-NG, but I do not know how to load remote JSON files. I am researching how to use $ http.get, but still how do I use it? Thank you! Replace the data in your chart within a variable: var chart data [=]; [...] Series: [{Data: chartdata}], [...] Then you can use the $ http-service as follows: $ http.get ('/ PATH / TO / MY / JSON') .success (function (jsonData) {// if you need some remodeling of jsonData, otherwise give it on the chart: chartData =...

Perfect Splash Screen Size for Smart Phone, Tablets in Android -

I want the correct splash screen size for smart phones and Tables. I have a smart phone size but for the smart phone I: Doubles - HDPI, Dribble-MDPI, Drawable - XHDPI, Drawable- xxhdpi For tablets: Droplet-big, droble-small, droble-normal, drable -xlarge & lt; Br> & Lt; Br> Right now, I have the size according to size: excel (xhdpi): 640x960 Large (HDPI ): 480x800 Medium (MDPI): 320x480 Small (LDPE): 240x320 xlarge screen at least 960dp x 720dp Large screen at least 640dp x 480dp Normal screen at least 470dp x 320dp Small screen at least 426dp x 320dp Please help me with this And tell me the size for the tablet splash screen size too. First of all, the question is obscure words. What do you mean by splash screen size? Since you will load the splash for full screen, what does pixel for the screen mean ? I am going to perception that it was asked for image pixels for different screen sizes and provides answers. B...

linux - Crontab - sh: ip command not found -

I have a PHP script that can successfully get the results of this command. exec ("ip address list", $ result); If I use it on the command line by using / usr / bin / php /root/myscript.php Run But when the CronantB runs it, then the result will not be a sh: ip command. I also tried exec ("/ sbin / ip addr list", $ result); But there is still no luck Any help would be greatly appreciated. Add a log to your cronjob to see dome som dow command 14 9 8 * / usr / bin / php / home / user / Test.php & gt; & Gt; /home/user/test.log2 & gt; & Amp; 1 The code was successfully executed with a chronobose; & lt ;? Php $ ret = Exec ("/ sbin / ip addr list", $ out, $ err); $ File = '/home/user/output.log'; File_put_contents ($ file, $ out); ? & Gt;

java -version and javac -version showing different versions -

Image
मेरे पास मेरे कोड पर स्थापित दोनों java 7 और java 8 है सी: \ प्रोग्राम फ़ाइलें \ जावा के तहत सिस्टम के पथ में मैंने java 7 के मार्ग को इस तरह निर्दिष्ट किया है। % JAVA_HOME% / bin जहां JAVA_HOME = C: \ Program Files \ Java \ jdk1.7.0_17 लेकिन जब मैं javac टाइप करता हूँ यह दिखाता है javac 1.7.0_17 जो समझ में आता है लेकिन जब मैं java -version करता हूं जावा (टीएम) 64 बिट सर्वर वीएम (25.0-बी 70, मिश्रित मोड का निर्माण) कोई भी विचार क्या यहां समस्या हो सकती है? संपादित करें स्थापित फ़ोल्डर: और एक और चीज गूंज% PATH% में JDK का एकमात्र समय है जो कि java 7 के लिए है और जेआरई में पाया गया है। यह मुद्दा संभवतः सबसे अधिक हो रहा है क्योंकि आपके पास JRE आपके पथ में, आपके JDK से पहले है। यह आमतौर पर तब होता है जब हम जेडीके को पथ में जोड़ते हैं और पहले जोड़े गए JREs को हटाते नहीं हैं इस प्रकार जब आप java करते हैं तो यह जेआरई को इंगित करता है और जब आप javac करते हैं तो यह दूसरे संस्करण / जेडीके को इंगित करता है (चूंकि जेरे में ज...

recursion - Parsing XML in Ruby using a recursive function -

I am trying to change the data in the XML file below. I'm certain of one thing that the data & lt; String & gt; will be in the tag, but can be nested to any extent in order to do this so that I come up with a recursive solution that looks like the right code, but there is no change. Repeat in C or C ++ is easy because that change is easily reflected in the actual parameters but in Ruby, I am not able to understand how to reflect it. Source XML: & lt; Document & gt; & Lt; String id = "title" & gt; Continue without cable cord? & Lt; / String & gt; & Lt; String id = "bodytext" /> & Lt; String id = "f" & gt; This data is for 1 & lt; P & gt; & Lt; T & gt; This data is 2 & lt; / T> & Lt; / P & gt; This data is 3 & lt; / String & gt; & Lt; / Documents & gt; Ruby code: required 'nocagory' doc = nokia :: XML (file. Open ("d.xml") de...

Make Android App Compatible for all 6735 Android Devices -

Text after "itemprop =" text "> Google Play Support 6735 Android Devices From the Play developer account that I got from Google, I have an Android app which supports Android 4555 I do not know why this is infected, I have given all kinds of assist permissions in the Android Manifest, which is mentioned below: & Lt; Android: smallScreens = "True" Android: xlargeScreens = "true" Android: requiresSmallestWidthDp = "Android" 600 "Android: Compatible Wiki Limit DP =" 720 "/> & Lt; Compatible screen & gt; & Lt ;! - All small screens - & gt; & Lt; Screen Android: Screensense = "LDPI" Android: ScreenSize = "Small" /> & Lt; Screen Android: Screensense = "MDPI" Android: ScreenSize = "Small" /> & Lt; Screen Android: Screenwise = "HDPI" Android: Screen Size = "Small" /> & Lt; Screen Android: Screenscency = "xhdpi"...

stackexchange.redis - How to excecute flush commands on stackexchange redis client using c# -

How can we increase the FlushAll and FlushDB redis commands using the stack exchange redis client? There is one in which is a short answer: IServer through "Why" in the documentation is included. // target server var server = conn.getServer (someServer); // completely wipes all the keys from the database key server. Flash Database (); // database number is optional and default for 0

ios - Deleting Push Channel After Sending A Push with Parse -

I am trying to send a push notification across a channel that indicates that the channel is about to close, so Send me the notification out of the channel, then remove that channel from the PFInstallation attribute "Channel". However, when I do this I am called an exception: * Due to 'NSIININI Existency Exception' due to an incomplete exception, the reason: 'Operation is invalid after the previous operation.' The code where I call it: - (zero) table view: (UITableView *) View table Commitment style: (UITableViewCellEditingStyle) RowAtIndexPath for editing queue: (NSIndexPath *) indexPath {if (editingStyle == UITableViewCellEditingStyleDelete) {// Add code here for session when you want to delete; Session session = self Chat session [index.path] ;; [Remove .htaccess objects Object Index: indexpath.ro]; [Remove tableview RTI & XPPath: @ [IndexPath] with Row Animation: UITWebAvailabilityApplication]; NSString * pushchannel = [NSString stringWithFor...

Java code specialization through preprocessor -

Currently we are in the process of evaluating the method of a common code base per project basis. Think of it as a complete operating system, which is in line with the requirements of the project. Those requirements may be to add additional features or data or to completely or partially change parts of the system. There are many options we are considering, e.g. Heritage, patterns of strategies, plugins etc. But there are alternatives to change / enhance the methodology in the way of AOP. Since we are already considering various ways to deal with this problem, this question is aimed at Dikas in those ways, but also a single question: Does anyone have a preprocessor (Free or commercial) which will allow us to change the functionality (sections of sections or even sections of classes) during compiling time? It will be similar to AOP, in which time will be compiled to spend, this code will not be wrapped / expanded, but will actually replace the code in the question. Is there s...

Git uncommitted changes doesn't show after copying to a different computer -

OK, I have a rail application and I changed it to a computer and did not change the GIT repo and then I zipped the entire folder and later copied it to a new computer to continue working, but what was strange was that when I started my Rail app, as I did after the changes made on the previous computer Was but when i It opens the code, it still shows the code that was in the previous commit in other words, the changes shown in the local host server are nowhere, I can be found in files and tried to delete the whole code and its There was no effect on the page. After refreshing and even when I restarted the server, I came to the conclusion that it would have to get the code from some Temple Library, but showing me that this code was in the last but now the question is How can I use these files to return to other computers, change to another computer, and then copy / re-zip ?? I am using GIT in all 4 months, in fact I do not know whether this is a completely new problem or something st...

java - How to delete rows which have a field greater than 24 hours -

I have a table that has 2 user names and a date - I need a way of processing on the table so that the date is stored 24 Hours are more than one day - then it is removed. I think there may be a thread in my Java application that can make the choice and can do this, alternatively - there is a solution that can be prepared on the database side? For example, a stored procedure? Thanks You can periodically use MySQL database side Take an action on. You can program it in Java in a program in Java: Scheduled ExeterService ses = Expiration. NewSingleThreadScheduledExecutor (); // executed the query for every 15 seconds ses.scheduleAtFixedRate (new runnab ()) {@Override Public Zero Run (// to delete the appropriate data}}, 0, 15, TimeUnit.SECONDS;

html - Hide an entire row of table where a cell is empty -

How can I hide the entire row if one cell in the second column is blank? & lt; Table class = "maintenance" & gt; & Lt; TR & gt; & Lt; Td square = "tb_1c" & gt; Brand: & lt; / Td> & Lt; Td square = "tb_2c" & gt; {{ITEMBRAND}} & lt; / Td> & Lt; / TR & gt; & Lt; TR & gt; & Lt; Td square = "tb_1c" & gt; Part Number: & lt; / Td> & Lt; Td square = "tb_2c" & gt; {{ITEMSKU}} & lt; / Td> & Lt; / TR & gt; & Lt; TR & gt; & Lt; Td square = "tb_1c" & gt; Part Type: & lt; / Td> & Lt; Td square = "tb_2c" & gt; {{U_ITEMCAT}} & lt; / Td> & Lt; / TR & gt; & Lt; TR & gt; & Lt; Td square = "tb_1c" & gt; Size & lt; / Td> & Lt; Td square = "tb_2c" & gt; & Lt; / Td> & Lt; / TR & gt; & Lt; / Table & gt; I've wo...

c++ - JNI: How to pass an object as parameter to JNI from java -

I start Java, and also start a JNI = ( I have my object I want to pass the JNI function, my object is like this: class FEATUREINFO {string str_ID; char [] c_ID; public double [] featuredata; int group; iplImage * t_faceImg; public FEATUREINFO () {This.featureData = new double [1280];}} // class FEATUREINFO Then I create 100 feature films: FEATUREINFO [] p_featureNode = InitializeWithDefaultFEATUREINFOInstances (100); and the JNI function, which I call I repeat: // double * matrix = double, (Double *) Eniv-> GetDoubleArrayElements (d_Matrix, 0); env-> ReleaseDoubleArrayElements (d_Matrix, Matrix, 0); // I do not know how to use the value of p_featureNode // If I want to get the value of p_featureNode [3] Feature data [8], how to do? DoFaceGrouping (p_featureNode, t_size_fea, matrix); // reall C function I use I // Definition of DoFaceGrouping: // INTEFaceGrouping (FEATUREINFO * p_facefeature, int t_size_fea, double * d_Matrix)} I do not know how to field Get a...

sql - Strip HTML Tags Whilst Ignoring Greater than Less than Values <>? -

I am trying to strip HTML tags out of the string using a function. Everything is working fine until I get valid & lt; > Values ​​I have used this code in the loop through HTML input and found the character after 0-9 and returned the value to the output string. DECLARE @i INT = 0 DECLARE @ input string VARCHAR (50) = 'this lesson & lt; 50 'announcement @fix VARCHAR (2) while @i & lt; = 9 set start @fix = '& lt;' + Cast (@i VARCHAR), such as '%' @inputstring + @fix + '%' instead of @inputstring = (@inputstring, '& lt;' + cast (as @i VARCHAR) , '[[' + 'Cast (@i as VARCHAR)) set @fix =' & gt; ' + Cast (@i as VARCHAR) If @inputstring is not liked '%' + 'span' + @fix + '%' and @inputstring does not like '%' + 'LI' + @fix + '%' SET @ Instead of inputstring = (@inputstring, '& gt;' + cast (@i as VARCHAR), ']]' + cast (@i as VARCHAR) p...

performance - c# unit test akward runtime -

I am developing a C # tool in Visual Studio 2013 on Win8. I just started paying the depts for the unit testing (shame on me;)) on a very easy part: is a class for geometrical vectors Wanted to check whether the init works below given code. It was found that the sequence of test methods is very strange: when running from the time of test TestCreateNonZeroVertex & lt; 1ms TestCreateZeroVertex 4ms TestModifyVertex & lt; 1ms Many times executed in the sequence (to eliminate some of the system's buffering stuff) First consideration: Garbage collector -> Forced GC in tampering (with waiting for finishing) Result: Expansion of time (as expected) but proportional testcreateNonZeroVertex 2ms TestCreateZeroVertex TestModifyVertex 2ms There is a bit more fact about the 8ms (for 13ms with peaks) TestModifyVertex defacto TestCreateZeroVertex + X, I do not understand this discrepancy. Is it because TestCreateZeroVertex is the first method in TestSuite? If so, it ...

c - Code::Blocks command line argument issues -

का प्रयोग: कोड :: ब्लॉक सॉफ्टवेयर खुद को सिखाओ सी बुक कोई भी "कमांड लाइन तर्क" उदाहरण कार्यक्रम काम करते हैं वे या तो क्रैश या 0 मान के साथ सभी चर के साथ निष्पादित करें या नीचे दिए गए कार्यक्रम में समान परिणाम दिखाएं। #include & lt; stdio.h & gt; Int main (int argc, char * argv []) {वापसी 0; } उदाहरण प्रोग्राम का सबसे सरल नीचे है। #include & lt; stdio.h & gt; Int main (int argc, char * argv []) {int i; के लिए (i = 1; i & lt; argc; i ++) प्रिंटफ़ ("% s", अरव [i]); वापसी 0; } कुछ गुगलिंग के साथ मैंने पाया है कि मुझे प्रोजेक्ट को एक कंसोल अनुप्रयोग के रूप में रखना होगा और फिर परियोजना - & gt; सेट प्रोग्राम तर्क , लेकिन मुझे पता नहीं है कि विंडो में क्या करना है जो पॉप अप हो जाता है यदि आपने अपनी प्रोजेक्ट को कंसोल एप्लीकेशन के रूप में संकलित किया है, तो आप प्रोग्राम को कॉल करने से तर्क को पारित कर सकते हैं कंसोल (विंडोज में cmd.exe, लिनक्स में टर्मिनल) खिड़की प्रोजेक्ट -> सेट प्रोग्राम्स तर्क केवल आपको पूछत...

c++ - Unable to paint on Gtk drawing_area with Cairo -

I try to color a point at drawing_area on Gtk I'm Cairo . I have two functions, the do_drawing function, to draw a point on draw to paint the background, and the other one do_drawpoint . Zero Painting: do_drawing (cairo_t * cr) {cairo_set_source_rgb (cr, 1, 1, 1); Cairo_paint (cr); } Zero Painting: do_pointDraw (CARO_T * CR) {CARO_USSET_SASS_RGB (CR, 0, 0, 0); Cairo_Arch (CR, 150, 150, 10, 0, 2 * MOPI); Cairo_fill (cr); } Now whenever the user clicks on drawing_area , then the dropout function is called. zero drawing arrow :: dropout () {g_signal_connect (area, "button-press-event", gcalblack (clicked), tap); Std :: Court & lt; & Lt; "Drawpoint" & lt; & Lt; Std :: endl; } Gboolean clicked (GtkWidget * widget, GdkEventButton * event, cairo_t * cr, gpointer user_data) {if (event-> button == 1) {x = event-> X; Y = event- & gt; Y; } Std :: cout & lt; & Lt; X & lt; & Lt; "And" & lt; ...

c# - In my WPF application, my loaded PNG logo in image shows at design time but not at run time -

It is probably something simple that I remember I have a PNG file that I have in my WPF window * Image * I want to use as a source of control. I added this project property> resource> existing file and added it as a linked file (and then when it was not working as an embedded) by adding this PNG file. Then I will add * source * to the image to control it in XAML file. No code is included, simple click The annoying problem is that when I'm designing the WPF window, the image shows when I run it, it doesnt. Nothing appears. Update: Added XAMLL code below & Lt; GradientStop color = "white" offset = "1" /> & Lt; / LinearGradientBrush & gt; & Lt; /Grid.Background> & Lt; Button x: name = "btn connect" content = "connect" horizontal alignment = "left" height = "30" margin = "425,34,0,0" workspaceElement = "top" width = "134" click = "BTN Connect-l...

python - Calculate special correlation distance matrix faster -

I want to create a distance matrix using the Pearson correlation distance. I tried the first scipy.spatial.distance.pdist (df, 'correlation') which is a 20 dataset of 20 attributes for my 5000 rows. Since I want to make a recommendor, I wanted to change a little distance, considering only those two features which are different for the NANs for both users. Actually, scipy Spatial.distance.pdist (df, 'correlation') When output is matched with any feature whose value is float ('nan'). It is mine code, DF mine 5000 * 20 pendus dataframe dist_mat = [] en = df.shape [1] for EN, enumerate in line_i ( Df.itertuples ()): for j, in row_j calculation (df.itertuples ()): if i & lt; J: print (i, j) ind = [wrong (math.isnan (row_i [t + 1]) or math.isnan (row_j [t + 1])) correct for d in another category (d)] dist_mat .append (scipy.spatial.distance.correlation (for row [row_i [t], [india] [row_j [t])) This code works but it is ashtoningly slow compared ...

google maps - How can I turn a nested callback into a jQuery promise -

Now I have to remove the distance through every Google Map for every home. var campus = {Loc: [-122.4579294, 37.7632498]} House houses = [[Local: [-122.4629668, 37.75 9 62]}, {loc: [122.4629672, 37.75 9 60 ]} // ...] function distance (msg) {var type = Msg.type var distance = 0 house [type] = home [type] || || [] Home [type]. Push (msg) $ .each (home [type], function (index, value) {distance + = value.distance.value}) home [type] .allDistance = distance / 1000 * 0.62} function caculateRoute (transType, home) {Var campusLoc = campus.loc var homeLoc = home.loc // map by google map object map.travelRoute ({origin: [homeLoc [1], homeLoc [0]], destination: [campus lock [1], campus Lock [0], traffic mode: transcript, step: function (e) {distance readie ({type: transite, distance: {text: e distance text, value: e distance.value}, step_number: e.step_number, duration : E.duration, Path: e.path, Instructions: E.instructions, Directions: {left: e.instructions.indexOf ('left')> ...