Posts

Showing posts from June, 2014

Downsides of subclassing specific exception in Python? -

I have a situation where a user can provide poor data to get data data that does not exist . At present, when these problems occur then error types are raised or not clear In my API, I intend to make an error to capture in the UI (or I want to give it to the UI Framework Users will be able to run it by reporting directly, which I have tested and works): DataError (ValueError): Increase this error with the message of 'wrong', General ValueErrors Or other exceptions ValueError subclass '' '/ code> and usage: if user_input is not in accept_values: Increase DataError (' bad user_input: {0} '. Format (user_input)) I have no opinion about my approach, and I need an unnecessary code. I know about fluctuation, because I can catch this specific exception without hiding others. But I can not think of any downsides. What happens to this as opposing to just raising my error message with ValueError ? Write a custom exception is almost always th...

html - How to have two input fields next to each other in a table cell, each being 50% wide? -

मेरे पास यह टेबल है : & lt; table & gt; & LT; टीआर & gt; & LT; टीडी & gt; & Lt; input type = "text" class = "half" / & gt; & Lt; input type = "text" class = "half" / & gt; & Lt; / टीडी & gt; & LT; टीडी & gt; & Lt; इनपुट प्रकार = "टेक्स्ट" / & gt; & Lt; / टीडी & gt; & LT; टीडी & gt; & Lt; इनपुट प्रकार = "टेक्स्ट" / & gt; & Lt; / टीडी & gt; & Lt; / टीआर & gt; & Lt; / तालिका & gt; सीएसएस: तालिका {चौड़ाई: 100%; सीमा-रिक्ति: 0; }। आफ़्फ़ {फ्लोट: बाएं; चौड़ाई: 50%; } तालिका सेल के (प्राकृतिक / सामान्य) चौड़ाई का 50% भरने के लिए मैं एक दूसरे के पास दो इनपुट फ़ील्ड कैसे कर सकता हूं? अभी, यह काम नहीं करता है कक्षा आधे के इनपुट फ़ील्ड वाले तालिका कक्षों में बहुत व्यापक हैं और मुझे नहीं पता कि यह क्यों होता है। आपको दो चीजों की आवश्यकता है: इनलाइन ब्लॉक तत्व के बीच में सफेद स्थान से बचें (तब आप...

opengl - Texture rotated by SDL2 is anti-aliased incorrectly -

Image
I'm trying to mix many textures with anti-aliasing enabled, it works fine if not textured Rotate, but when I rotate a texture, produces a "border" on the edge of anti-aliasing texture. Below are examples. Original textures, 100x100px image in the middle of 50x50px. Png "alt =" original texture "> I am rendering this text twice: as it rotates 45 degrees, it produces the following result: Note the range of gray rotation textures in my opinion, the texture at the bottom is lower Level should be mixed with texture because they contain pixels of the same color, if anti-aliasing is incomplete, the texture is up without any limit Miserically mix, but obviously I want to do anti-aliasing for the rotating texture. Is there a way to achieve both: anti-aliens texture and seamless mix? I am rendering with SDL2 and OpenGL below is a program to display this example below. #include & lt; Assert.h & gt; # Include & lt; SDL2 / SDL.h ...

c# - Error suggests I'm missing a using directive or assembly reference, but I'm not.... -

I'm new enough to work with multiple projects in the solution. Two of my projects are: AutoPoster. Droid and AutoPoster.Core . I have an adapter class in AutoPoster.Droid which gives LocationInfo context in AutoPoster.Core. I am getting this error now and it is not sure why: the type or namespace 'core' could not be found (are not you forgetting the reference to use or the reference to the coalition?) Here's my code: using the system; Using System.Collections.Generic; Using System.Linq; Using Android. App; Using Android. See; Using Android.Widget; Namespace Autopostor.Dyrid Adapter {public class postInfoAdapter: Base adapter & lt; Core.Model.Location & gt; {Private redone activity activity; Public listing & lt; Core.Model.LocationInfo & gt; Location information (get); Private set; } // Getting the error here: Public PostInfoAdapter (Activity reference, IEnumerable & lt; Core.Model.LocationInfo & gt; localInfo) // Get the error her...

python - Accented column names, introspection and mapping -

I want to use a legacy MSSQL database using SQLAlchemy. With the basic schema inspection I can already list the columns of tables in which I am interested. Unfortunately, the names of these columns are sometimes desired characters (such as "Magajhijhemai Livy", "Levelejhesisisiaiaiaraaaasisamajh"). / P> My only requirement is to be able to query this DB. I've listed some of the database name for you by using the following command def inspect_komplex_table (): Table = Table ( 'D_Allomanylista_Komplex_V', Meta, autoload = True, Autoload_with = engine) return table def get_columns (): keys = inspect_komplex_table (). Columns.keys () keys.sort () returns txt = '\ n' type (txt.encode ( 'utf8')) A (long it column_names) list ( ' Column_names.txt ',' w '). .txt file with lines: ... JUTE? RVKZad KZET KTTSAMAM PKLAB of Kamratigzam ?? K Lejhrlet Levelejhesi Siaimaiaraaiaa Tissaajiam Levelejhes C. Utka Levelejia Si...

google apps script - How do I resolve this "TypeError: Cannot read property "values" from undefined. (line 2, file "Code")" based on the context below? -

निम्न प्रकार से नीचे दी गई स्क्रिप्ट निम्न त्रुटि उत्पन्न करती है; प्रकार त्रुटि: अपरिभाषित से गुण "मूल्य" नहीं पढ़ सकता है फ़ॉर्न्मेंट पर फॉर्म्स सबमिट (ई) {var टाइमस्टैंप = ई। मूल [0]; Var ईमेल = e.values ​​[1]; Var नाम = e.values ​​[2]; Var टेम्पलेट = HtmlService.createTemplateFromFile ("ProfileEmail"); Template.name = name; Template.email = email; MailApp.sendEmail (ईमेल, "आपके समय के लिए धन्यवाद!", "", {Html बॉडी: टेम्पलेट। मूल्यांकन ()। GetContent ()}); } फॉर्म और शीट्स के नए संस्करण में, आप नामित मानों का भी उपयोग कर सकते हैं, उदाहरण। var टाइमस्टैम्प = ई। नामित वैल्यू। टेमस्टैम्प; Var ईमेल = e.named वेल्यू। ईमेल; Var नाम = e.namedValues.name; "nameValues" के बाद के मान को कॉलम हैडर के समान दिखना चाहिए। आप हमेशा "Logger.log (e)" को सिर्फ जोड़ सकते हैं टाइमस्टैम्प के ऊपर और स्क्रिप्ट पर कभी भी मूल्यों को पारित किया जाता है, यह देखने के लिए कि क्या आपके भी आपकी क्या तलाश है। बाकी कोड को HTML भाग को ...

python - Run a single test with multiple configs in parallel using pytest -

I have to run against the different hosts in a single test in parallel. Currently, I am calling a bunchof pytest.main (). But it has not run in parallel and the results are not collected. This is the content of runtest.py: pytest.main ('- conf = c1.txt') pytest.main ('- conf = c2.txt') pytest.main ('- -conf = c3.txt ') I have only one test_host.py that looks like this: test_pinghost (conf): # Ping Hosts in Configure Is there a way to run it in parallel and gross results? PS: Confidential files include host IP Please use it to run tests in many processes. Enables Pitext / Machine

java - Dynamic amount of loops through permutations -

I have found a program that will dynamically reach different approaches and in each method different quantities of parameters Will be I need to find a way to index these criteria through thousands of different arrangements, and I'm not sure how the loop dynamically through these permutations. For example, for a function with two parameters, I can repeat through the order in such a way: public static zero main (string [] args) {List & lt; Object [] & gt; Params = new arrelist (); Params.add (new integer [] (1,2,3}); Params.add (new Boolean [] (wrong, true)) runCalculation ("function1", parameter);} Public Zero run cloluation (string function name, List; Object for: parameters.get (0)) {for (object j: parameters.get (1)) {// Do reflection function call with (i, j) as parameter }}} But if I had the next function, I want to use 3 parameters, it is now again through all permutations O Will I be able to use a dynamic amount of loops to process the list corre...

java - Strange symbols are showing in Eclipse -

Image
My friend used my laptop for a while and I forgot to close the eclipse, I started working on it, its "strange symbol" like "> gt; & gt; and some kind of" q ", someone can tell me how to remove it? Any help will be greatly appreciated. / P> you p Click the button with a symbol (actually un-click). The characters you are seeing are symbols of rebuttal and line breaks (normally invisible).

python 2.7.6 and matplotlib.pyplot AttributeError: showMaximized -

हम एक अजगर स्क्रिप्ट (test.py) चलाते हैं: आयात करें matplotlib.pyplot के रूप में plt import pylab import win32com.client win32 import os mng = pylab.get_current_fig_manager () mng.window.showMaximized () के रूप में यह निम्न त्रुटि संदेश दिखाएगा: ट्रेसबैक (सबसे हाल का कॉल अंतिम): फ़ाइल "सी: \ test.py", पंक्ति 6, & lt; मॉड्यूल & gt; Mng.window.showMaximized () फ़ाइल "C: \ Python27 \ lib \ lib-tk \ Tkinter.py", पंक्ति 1826, में __getattr__ वापसी getattr (self.tk, attr) विशेषता एंटर: showMaximized हमारा ऑपरेशन सिस्टम विंडोज 7 है। हमने "मैप्लोटलिब" 1.3.1.win32â "py2.7.exe" स्थापित किया है, और इसी संकीर्ण, डेट्यूटिल, पाइट्ज़, पाइपरसिंग, छः और विनोवरकॉम। क्लाइंट। हम खोज के बाद कोई समाधान नहीं पा सके। क्या कोई गुरु कृपया कुछ टिप्पणियों / समाधानों की पेशकश कर सकता है? धन्यवाद। get_current_fig_manager द्वारा लौटा वस्तु छवि को रेंडर करने के लिए इस्तेमाल किए गए बैकएंड पर निर्भर करती है । आपकी त्रुटि के आधार पर, ऐसा लगता है कि...

javascript - How to set 'load' action after unsafeWindow.open -

It appears that I could just do this: var newWindow = unsafeWindow Open (someUrlOnTheSameDomain); NewWindow.addEventListener ('Load', toRunOnLoad); // or newWindow.onload = toRunOnLoad; But now Firefox returns error Refusing permission to use property 'addEventListener' when trying to perform similar or similar action This is done whether window.open or unsafe Windows.open is used. According to the new way to interact with an unsafe, clonoin () , exportfunction () , and createObjectIn () , but this announcement or limited documentation is not clear how any of these can be added in the event controller in the new window. What is the new solution for this pattern? Hmm .. interacting with a window that opens from the second window through the content script is actually a something's wrong. You can use window.open , but can not be interacted with the resulting window, in conjunction with the Sandbox Principal (the same basic policy) Due t...

function - Powershell script works in ISE but not in console -

I am writing a power shell script that will initiate a process, monitor a folder for file changes, and then Backup folder when file If I run my script from within PowerSheed ISE, then it works fine, I can monitor the folder and it will save the backup properly. The problem is that I will run a batch file that will run the PowerShell script. But whenever I run the script from the PowerShell console, or whenever I run my batch file that runs the script, it no longer works at all. The script runs and the events are registered when I copy the copy of a file into the viewed folder, then I only get the changed event and not the created event, and the DUSTFOOOM function is no longer called. I'm not sure how to go about debugging this: / The following is my script: I have removed the parts that are not currently related to actual wrong, so use some variables I am here, you will not see declared, but they are there. I get a host to write for the console, when a changed event happe...

html - How to make container div height of page at all times, with no content overflow? -

I'm trying to create a simple webpage where it has a focused div with content so far I have a lot easier It was time, but I've hit a roadblock: when the browser window is less than the main content, then the content "spreads" (example :) I saw a lot of tutorials / similar questions Is it, but I think that's going to fulfill my needs Can not find OS: Contains container (most solutions position: fixed , which usually aligns to the left side of the container divas page Keeps the container at the top of the window even when placed in the shape Allows scrolling when the window INS usually terminates the scroll bar, so only one of the content shows Share Here is my code: (CSS) # Container {width: 900px; height: 100%; margin: auto auto auto auto; padding: 1px; background-image: url ('img / light_tost page');} #mainHeader {margin: 30px 30px 10px; Padding: 0px;} #mainContent {margin: 0px 80px 0px 80px; Padding: 1px;} (html) & lt; Div...

checkbox - JSP - Passing String Array to a constructor -

I have jsp1 where the user checks two of the check boxes, able to successfully read the checkbox value using strings on jsp2 is. But I need to create a user object with the selected parameter on jsp1, so that I can write it in a text file. This is where I'm blocking a road block when I run the code independently, the Java console is working fine. But the actual code is not. I get an error below An error occurred on the line: 29 in the jsp file: /ProcessMyForm.jsp Constructor user (string, string, string, string, string, string [], string ) Is undefined 26: string path = sc.getRealPath ("/ WEB-INF / EmailList.txt"); 27: 28: // Use the normal Java object 29: User user = New user (username, email address, password, comment, email format, server script, business); 30: user.ed (user, path); 31:%> 32: The code below is where I am reading the JSP value and trying to create an object parameters Below is the code for the public class {Private string username; ...

python - Getting events of all levels using a non-root logger -

I have a non-root logger with some handlers, and I want the logger to have every event with them, - At the defined levels - I have a log .set level (notice) . This, however, those events that I do not want should be unconditional to my handler. I am thinking that if logs .Set level (1) would be the right choice, it does not seem elegant, so perhaps there is another way to accomplish that? Here's a minimal example - it does not print anything, which I do not want: Import from importers, streamhindlers, import system stdout from Log = Mill Logger ("MyLoger") handler = Streamhandler (standout) logs. Adhendler (handler) logs. Set level (notice) logs. Debug ("some") log.setLevel (logging. DEBUG) without any other consideration. In this case, you want to cover every potential user-defined level, which can be achieved using the level 1. I do not think this is unbearable, this is the only difference between this and log.setLevel (logging.ADUU). Is t...

c# - How to implement n-layer architecture in MVC? -

I know that this question has been asked before. I'm just asking that I can get better explanation in my webform applications, in this way I have implemented my projects. Two solution projects were the first project included data access and business logic. The first project is referred to in the second project aspx.cs called the business logic class and the business logic class says the data access class. I am trying to follow the same approach in my MVC programs. How do I apply it? Controller call model which in turn is called business logic? Will this approach add overhead accuracy? In the context of the direction the comment is taking this thread (it does not fit neatly in a comment ): The model folder created with a new MVC project is for the model - they have classes to support ideas. These are not your business model or data model. For example, in a view model that supports a view, you may have a potential property that renders in the dropdown: public em Custo...

Postmark Outbound Email Rails 3 -

I'm practicing a wedding site Unfortunately, I have not been able to send my emails to the guests who are interested in RSVP Have done I'm not sure what to do: = & gt; Rsvp_Mailer.rb square RsvpMailer & lt; ActionMailer :: Base Def RSVP_email (Primary, Guest, Message) @primary = Primary @ Grassatus = Guest @message = Message subject_motion = Primary. ? "Attending": "Not present" mail (: = & gt; "www.personaldomain.com" & lt; no -reply@personaldomain.com> ',: to = & gt;' ??? #: Subject = & gt; "new RSVP - # {subject_prefix}: # {primary.first_name} # {primary.last_name} + # {@ end = You need to have an email address of the recipient to do this: like this: mail (= = to; '' www..personaldomain.com '' & lt; no -reply @ Personaldomain.com & gt; ', to = & gt;' user@example.com ': topic = & gt; "new RSVP - # {subject_prefix}: # {primary .first_name} ...

java - Unable to populate ListView with ArrayList -

I'm trying to create an audio record for which I still want to display the list of recordings. I am able to get the file from my SD card recorded in an ArrayList list, but my app crashes while trying to fill this list view. ListRecordings.java is called using one. MainActivity.java means here for ListRecordings.java: spreads the public category ListRecordings activity {@Override protected Zero onCreate (bundled savedInstanceState) {setContentView (R. Layout.listrecordings); List view lv; String path = environment .getExternalStorageDirectory () .getAbsolutePath () + "/ MyAudioRecorder"; ArrayList & LT; String & gt; FilesInFolder = GetFiles (Path); Lv = (ListView) findViewById (R.id.filelist); ArrayAdapter & LT; String & gt; Adapter = new array adapter & lt; String & gt; (This, R.Lettextstyle, File Inf Folder); Lv.setAdapter (adapter); Lv.setOnItemClickListener (New AdapterView.OnItemClickListener () {Public Zero onItemClick (AdapterVie...

java - android 'package-list' not found in docs folder -

My previous OS was Windows XP 32 bit and I used this same Android SDK bundle. But recently I changed my OS to Windows 7, 64 bit.So I downloaded Eclipse ADT from Android SDK for Windows . But the new bundle is not documentation . I want to use the docs folder which was in the previous SDK folder instead of downloading it again. I searched in Google and found some answers as well. But when I tried that, by pressing the valid button to validate the documents, I saw this note: The location may be invalid, the files 'package-list' and 'index.html' Usually the documentation made by the Javadoc tool is available in the root. I see the Docs folder and there was index.html but I could not find the package list (it is not there ). Now what is there any way to solve this problem without downloading docs again? As I said, give me the reference folder to docs Browse in folder from my previous bundle

opencv - Smoothing motion by using Kalman Filter or Particle Filter in video stabilization -

I have a problem. I have read many papers about video stabilization, almost using paper fiction filter to smoothen the speed As mentioned, it is strong and is run in real-time applications. But another filter is also strongly, which is the particle filter. But why do not we use Patalus Filters in the chutney to create stabilized videos? Some papers use particle filters to estimate the global speed between frames (speed estimate part). They are difficult to understand. Can someone explain me to me, please? Thanks a lot. An imaginary filter is uni-modal This means that a normal There is a belief with the co-friendship matrix, an error to represent self confidence in this belief as distribution. If you are going to smooth some process, you want to get a singular, smooth result. It is analogous to a KF. It is like using the regression of at least sections to fit a line for the data, you are simplifying the input into a result. A particle filter is by its nature multidimensio...

ckeditor - Only menu shows on MODX Manager -

After I changed a setting in the ckeditor plugin, the content of the entire manager is not loaded. Only menu (top and left) is shown, I've already cleared the cache by removing the cache from the contents of the core / cache folder, and my browser. remove the components / ckeditor folder and clear the cache again . Log in to the manager, go to Package Manager and remove and reinstall ckeditor. This is also a way to manually delete packages in Mandix.

javascript - Rails 3: Jquery code breaks when making simple AJAX call, think is a simple mistake -

To update the user registration, in the Registry Registry Controller I have in my opinion & lt;% = form_for (@user ,: as = & gt; processing_name ,: url = & gt; registration_path (resource_name) ,: html = & gt; {: method = & gt; : Put: id = & gt; 'shared-form'} ,: remote => true) f | F | & Gt%; & Lt;% = f.check_box: facebook_share% & gt; & Lt;% = f.label: facebook_share ,: class = & gt; 'Submit-Share'% & gt; & Lt;% end% & gt; So ID = "share-form" in this form, I have a URL and the specified method. When my jacquery form is stored normally, but the database has not been updated with any data: $ (document) .ready (function () {$ ('Submit-share') (function () {$ ('# share-form'). Submit ();});}); The console reads: started for POST "/ user" on 127.0.0.1 2014-07-25 13:34:21 +0700 #update as the controller controller HTML parameters by registration: {"UTF...

java - Maven: error required library -

I am trying to reactivate a Maven project, but when I am performing a JUnit test I am getting this error: Description Resources Path Location Type Required Library Archive for: 'C: / ... m2 / repository / org / eclipse / ui / workbench / 3.3 .0-I20070608-1100 / Workbench-3.3.0 -E 20070608-1100.jar 'project-test' can not be read in project or valid pin file is not available Create path path path problem When I am checking the library I .jar file, just in case I have downloaded it again, but still I have the same error . I'm actually starting out in Maven and this is my first try. First of all, I made an example with maven-archetype-quickstar , but when I'm trying to make the exam Hello World , I get this error Here's my error described here, but I can not remove it: Anyway, I can run the test alone. The Java class and it is successfully executed. So, now I am trying to use an existing project (which I wrote in the beginning here) and before saying t...

c# - Using Timer to detect changes -

UPDATE: I added my code to show the whole process and somehow my continuity my 3 items are listed in the pass list and there is a if statement that indicates that if my subtitle is inactive code inside a file will generate a problem Once inactive item / s is active again, how do I redo my timer? Private Zero form1_load (object sender, event events e) {timer 2. Enchanted = true; } Private zero current_process () {process [] process = process. GetPrices ("ITWORKSPC152"); For (int i = 0; i You do not need a timer at all. In your case, the problem is this: when you want to do something, the price list of your item changes in view. The word "event" is here. Subscribe to an event in your list view, choose. I think the "AfterLabelEdit" event in that list is searching for you. Here are some clues, you should customize the code in your specific context: listView1.AfterLabelEdit + = (o, e) => {If (listView1.SelectedItems == faucet ...

android - What is callable in Java? -

The title tells too much I want to know the idea of ​​sensible and concept. I have read on the difference between colebal and runnabal but no code shows and explains in detail that what a callable person is. I do not want to know the difference between them. I want to know, What is a collage? When to use them and how to use them When they take action for Android You can check it out: In this example, callable function returns the name of the executed thread after one second. We are using the excercise framework to execute 100 operations parallel and use the future to get the results of the work presented. package com.journaldev.threads; Import java.util.ArrayList; Import java.util.Date; Import java.util.list; Import java.util.concurrent.Callable; Import java.util.concurrent.ExecutionException; Import java.util.concurrent.ExecutorService; Import java.util.concurrent.Executors; Import java.util.concurrent.Future; Public Class Microwaveable Tools Callable ...

apache - How To Use Htacess for www.example.com/type.php?user=name -

मैं www.example.com/type/name से www को रीडायरेक्ट करना चाहता हूं। Example.com/type.php?user=name {RewriteRule ^ ([a-zA-Z0-9 _-] +) / टाइप करें $ type.php? Key = $ 1 RewriteRule ^ ([a-zA-Z0-9 _-] +) / प्रकार / $ type.php? Key = $ 1} कृपया इस बारे में मेरी मदद करें। अपने वेब दस्तावेज़ रूट फ़ोल्डर में इसे .htaccess फ़ाइल में जोड़ने की कोशिश करें (अक्सर Public_html या htdocs ): विकल्प + अनुवर्ती लिपि -मल्टीइव्स रीव्रेटइन्गइन ऑन रिव्रैटआर्यूल ^ टाइप करें / ([^ /] +) /? Type.php? Key = $ 1 [एल] यह मानता है कि mod_rewrite दोनों स्थापित और के लिए सक्रिय है .htaccess फ़ाइलें यदि आप सुनिश्चित नहीं हैं, तो जांचने के लिए कि क्या mod_rewrite भी इंस्टॉल किया गया है, phpinfo (); के आउटपुट में स्थापित मॉड्यूल की सूची को देखें, डिफ़ॉल्ट रूप से, .htaccess फ़ाइलें यदि आप अपना स्वयं का सर्वर प्रबंधित कर रहे हैं, तो httpd.conf को खोलें और सुनिश्चित करें कि वेब्रोट निर्देशिका ब्लॉक में इनमें से एक पंक्ति है: अनुमति दें ओवरराइड फाइल इन्फोस या सभी को अनुमति दें क...

delphi - SetEnvironmentVariable not working -

I have to set two environment variables (when my application runs) for third-party libraries involved. The problem is that 'this way' is not working, however, when I run console applications, then set these two variables and then run the app, everything is fine ... How to configure these two wires correctly? I use this process: function SetEnvVarValue (Constant Varname, Verbewall: string): Integer; Start // Just call the SET function if Setanerative (Parsar), PCHart (Variant)) results: = 0 and results: = GetLastError; End; It gives 0 Probably this, I have the libraries being loaded on the application startup when the stars of my application set the variable I And I'm too late ...? More information I have included two units in the DPR: C: \ Program Files (x86) \ Borland \ Delphi 7 \ Lib \ Magick \ In C: \ Program Files (x86) \ Borland Delphi 7 \ Lib \ Magic \ Magic \ ImageMagic Wand \ magick_wand.pas'; And Unit: Unit DoItFirst; Interface Wind...

html - Post the only modify input field php -

I have 10 input fields here, then when I submit the click button to the user, then I need only the input field All input fields sent to the database send the database and updates instead. How can I get it? If you want to save the field that the user has touched, see the first version but a downside That if the user changed "ABC" to "xyz" and then changed it to "ABC" then the field will be marked by changing if it is not what you want, see the next version. (1) You can use the onchange () event in your area to modify a variable when the field is modified. Then send these variables to the server using the input hidden field. By the way: & Lt; Input type = 'hidden' name = 'input2changed' value = 0> Then in your PHP code: if ($ _POST ['input1changed']) $ _POST store ['input1'] if ($ _POST ['Input2changed']) Store $ _POST ['input2'] (2) & lt; Input type = 'hidden...

java - System.out, System.err : often temporary debugging statements warning -

While writing a very simple multi-platform console application in Netbeans, I have seen a consistent warning on the statement System.out. Println () and System.err.println (), which are often temporary debugging statements. And in the description of Netbeans wiki, it tells this is often a temporary debugging statement, and perhaps either removed from the output code, or by a more robust logging feature Should be replaced. Why it is this and what should I use to print the message after that in the user's powerful console application view I'm using to inform the user using many of these statements, the argument is not valid, or some access denied exception exists, etc. Any suggestions will help you If your application will update and / or become a part of the other, complex system, E System.out and System.err calls will be less convenient than the implemented logging subsystem in your application. And it would be necessary to re-write these parts of cod...

IntelliJ auto create new method that NOT exist and auto type conversion? -

These two Quickfix features are quite simple, but in Intellj I can not find them. For example: class A {a) A = new A (); A.newMethod (); // Eclipse can create a "new mode" function in class A, if we hold the mouse here. Is there a shortcut key? Any problem you have always tries to put your cursor on it and 'alt Enter '+' first hit. This standard IDEA problem is solver.

IntelliJ Ideea background color for External Libraries -

Image
How can I change the color in the background of external libraries in IntelliJ Idea? I set the settings-editor-color & amp; Fonts, but I did not know the background color of external libraries .... Thanks! Go to Preferences - & gt; File Color You will see various file scopes defined there. By default, there are only two - "non-project files" and "test". You have to change the scope of non-project files. Also be sure to check a custom-defined scope Note: Your screenshot thinks that this is a mixture between normal and darculla subjects provided by the IDEA. Are you switching between them? To fully implement the changes requires restart, and IDE until you feel weird. If this is the case, try restarting the IDE whether it fixes the problem or not.

google chrome - Python: What modules do I need to include in the directory of my program to run Selenium with Unittest? -

I am trying to run the following code using Pycharm IDE: selenium import selenium.webdriver.common.keys linked to import webdriver import key category PythonOrgSearch (unittest.TestCase): def setup (self): self.driver = webdriver.Firefox () def Test_search_in_python_org (self): driver = self.driver driver.get ( "http://www.python.org") self.assertIn ( "dragon", driver.title) ELEM = driver.find_element_by_name ( "q") elem.send_keys ( "selenium") elem.send_keys ( Keys.RETURN) def teardown (self): self.driver.close () if __name__ == "__main__": unittest.main () I Nimnliki Error comes when I do: Traceback (most recent call last): File "/ Users / BigRed / PycharmProjects / Dragon 3 / source.py", line 8, setup self.driver = webdriver.Firefox no specialty) AttributeError: 'module' object ( 'Firefox' the directory of the source file, I also have selenium folder in which t he Vebdraivr files , As well as...

graph - Neo4j/Cypher - find connected nodes that have more than 2 links -

Image
I have a graph (thus link instructions for any labels or simplicity has been removed) I would like to start on node (c) and only those nodes I will find those who have nodes with more than 2 adjacent edges, and the path from them (C) In the above example, there are 3 adjacent edges (ba, bc, bg) and node (e) 4 in the node (b) adjacent edges (ed, ef, eh, eh), so i just B) and (E) would like to return the path. I also want to no to return the path to (a), (f), (h), (g) or (j) - when i am satisfied counting the traversal I want to stop I have tried the following: start n = node (c) match (n) - [r *] - (m) - [rx] - ( O) with Mm, NNNRR, (rx) cnt ou cnt & gt; 2 returns n, r, m, cnt; ... but it gives the path to do one, which is in addition to G, H, F and B and E. Edit: For example, Pictures I, if my data is imposed, then the initial suggestion does not work (see) so that a new image Example given below. I want : Path to B - just as I do not want : To ret...

javascript - Returning false not working with MVC post -

मेरे asp.net MVC दृश्य में, @using (Html.BeginForm (" MyAction "," MyController ", FormMethod.Post)) {& lt; इनपुट प्रकार =" सबमिट करें "id =" सबमिट करें चयनित आइटम "value =" आइटम में जोड़ें "/ & gt; } इसके अलावा मेरे पास सबमिट बटन के लिए एक Jquery onclick ईवेंट है, $ a ("# submitSelectedItems")। पर ("क्लिक करें", फ़ंक्शन () {If (SelectedItem.length & lt; = 0) {चेतावनी ("कृपया आगे बढ़ने के लिए एक शैली का चयन करें!"); वापसी लौटें;} और {वापस लौटें;} वापसी वापसी;}); यहां कोई भी आइटम चयनित नहीं होने पर मुझे सफलतापूर्वक सतर्कता प्राप्त हो रही है, हालांकि चेतावनी के बाद भी मैं गलत लौट रहा हूं, यहां क्रिया पद्धति में पोस्ट को रोक नहीं है, यह निरंतर है उस? मैं पोस्टिंग कैसे रोक सकता हूं? मैंने e.preventDefault (); के साथ भी कोशिश की, लेकिन कोई भाग्य नहीं। आप फुले वापस आ रहे हैं; कृपया अपना कोड एक बार फिर से देखें इसे झूठे , $ a ("# submitSelectedItems") पर वापस करना...

php - Laravel basic routing returns 404 -

I have recently started learning Laravel but there is a problem which I do not know why this happens. My current Laravel project is located on wamp / www / codebright . When I reach localhost / codebright / public> , then see my welcome page. When I create a simple routing: Root :: find ('my / page', function () {return "harrow world";}); and attempt to use: localhost / codebrights / public / my / page it returns with error 404, even with Laravel error also no. I have also tried to use: localhost / codebright / my / page and still. However, if I type cmd php artisan serve and open a server on 8000 port and then log in: localhost: 8000 / my / page It works just fine. I want to know why my first method is not working without the commander command. Thanks in advance! Note It seems that if you have XMP installed, then there is no one in the above mentioned problems and the comment comment section. In fact, if you are using XAMPP, you will no...

Hiding an element in ClearCase -

I am trying to hide an element in my ClearCase view. I have defined the following line in my config spac: element / path / to / some / element -none further down in my config spec, this is included in another config spec (which in turn Other config glasses and so on - there is a complete mess, but I can not change it). I'm pretty sure there is another line in setting this element to a tagged version when I see that / Pre> what -none option element exaggerated by a tag? If so, how can I work around this? I confirm that a config spake will not operate well a symbolic link. View There is no VOB symbolic link area. A VOB symbolic link is listed in one or more versions of the directory element (listed) A vob symbolic link (for example, after moving the elements has been seen) Vob , even without talking about the symlink, it mentions that ClearCase config will not resolve the end point of the uncompressed wildcard or unrelated recursive rule symlink. ...

actionscript 3 - How to generate a sound file inside AS3 and upload it to server? -

I created a flash applet to record the sound and encoded it in mp3 bitrate. By uploading the file's readance object's upload method and URL rafing as a parameter, a file can be sent to a script that can process data (eg .php). However, FileReference.data is read-only, so I can not understand the way to pass a file reference object in the MP3 biterere, or create a file in AS3 and load it on the reference reference to the file. By the way, I would not want the user to download the file and upload it manually. Is there any way to solve this problem? file references is not used to analyze the loaded content, But to do this to load files between a server and a computer, you can use the URLLoader class. Listening events is done directly by the URLLoader object. var loader: URLLoader = new URLloader (); Loader.load (new URLRequest ("myFile")); Loader.addEventListener (event.complete, loading); To access the data, we use the property of the data of the UR...

java - getting Class Cast Exception while sending date to DAO Class -

// I'm trying to send a date to my Dao class, but I'm getting an exception string date Is = request.getParameter ("Date"); Date date = null; SimpleDataformat SDF = New SimpleDormat ("DD / MM / YEA"); Try / I am importing java.sql.Date // I am getting java.lang.ClassCastException: java.util.Date to java.sql.Date date = (date) sdf.parse (dateInString) Can not be put in; } Hold (ParseException e) {e.printStackTrace (); } Skip leave leave = new leave (associate id, date, buffer, applicator, buffer); AssoicatesDAO = new AssociatesAO (); Boolean success = AssociatesAo LevelBelance (Skip); If (success) {msg = "Associate's vacation has been successfully added."; } Other {msg = "****"; } Request.setAttribute ("Feedback Message", msg); Sender = request.getRequestDispatcher ("/ jsp / success.jsp"); Dispatcher. Forwarded (request, response); } in the form of you java.util.Date With SimpleDateFormat with java.ut...

javascript - Edit specific div's using AngularJS -

How can I edit the coal using a specific div? There is a problem with the Divs on my page, which includes tabulars with data. When I click on an edit button on a specific div, I want it to be editable. How can I tie the click event in that special device? I've done something like this now: & lt; Div ng-show = "summary.abbData.service_type == 'name'" class = "col-md-6" style = "background-colour: #ffffff; width: 325px; margin-left: 15px;" & gt; & Lt; H5 class = "bg-primary rmpad15" style = "margin-top: 1px; padding: 5px;" & Gt; {{Summary.abbData.service_type}} & lt; Button type = "button" ng-click = "editAbb (customer.id)" class = "btn btn-default btn-x" style = "float: right; margin-top: -3px;" & gt; Spine class = "glyphin glyphine-pencil" & gt; & Lt; / Time & gt; & Lt; / Button & gt; & Lt; / H5> & Lt; Table clas...

Centre Emacs buffer within window -

I wrap all my code in 80 columns, and there are times when the MX window is more than 80 columns wide And many unused whitepaces on the right side. I would like to create the status of amax buffer, so all the text is displayed in the center of the window. It is different from the center, align the text (like seeing a pdf, on both sides of the text, similar to aerospace). I think it can be achieved dynamically by adjusting the fringe mode width based on the current window size, I'm not sure where to start any ideas? It looks like this is actually possible: (set-fringe-mode (/ (- (frame-pixel-width) (* 80 (frame-four-width)) 2)) However, as I am testing it, I feel more fortunate to use margin, at least when my frame size changes: (defun myrise-margin () ((margin-size (/ (- (width width) 80) 2)) (set-window-margin zero (Marg-size-margin) (my-size-margin)

java - Printing objects in a 2-D array using deepToString -

I am trying to write a Java application that will simulate football fixtures (in the style of the World Cup) and The match will produce the report and the results randomly, since I want to hand over every team to the players, I should have teams to have an object instead of just stars. This is proving problematic because I am struggling to print a complete list of teams on the application run. So far I have for Team category: import java.util.Arrays; Public Sector Team {Public Stable Team Team 1 = New Team (); Public stable team team 2 = new team (); Public stable team team 3 = new team (); ... public stable team team 16 = new team (); Public stable team [] [] Full tilelist = {{Team 1, Team 2, Team 3, Team 4}, {Team 5, Team 6, Team 7, Team 8}, {Team 9, Team 10, Team 11, Team} 12}, {Team 13, Team 14, Team 15, Team 16}}; Public static zero print FULTemList () {System.out.println (Arrays.deepToString (fulltemlist)); }} (At some point I will change the team names manually, this i...

Android activity with tabs: how do i get the Fragment instance behind the active tab -

I have an activity that applies tabs, basically I delete it: There are tabs which contain one piece of activation, such as: mTabHost.addTab (mTabHost.newTabSpec ("tab1"). Set indicator ("Tab 1", GetResources (). GetDrawable (Android .r.drawable.star_on), Fragment.Tab. Class, Faucet; // How Can I Recover, Examples of French Tabs? I have added a TabChangeListener implementation and when a tab Active, I get a notification, But: How can I work the piece behind the tab example. TIA BG Well, you can not do this, No tab is activated and when it is disabled, the installation is stopped. Instead of the data being activated, segment / view Instead, instead I try to drag data into Crete - each time the piece is activated.

objective c - Pop up created by CFUserNotificationCreate is not coming to front -

This is a little tricky situation. I want to display a dialogue with the user from the daemon, on this dialog screen, all other open windows Should come out. In regular cases, CFUser notifications work just fine. But try to open a file using "open window" from that open encoder, if the window is hanging due to some reason, the conversation with CFUserNotificationCreate is not coming up on such windows. Is there a solution for this? Is there any way to display any other dialogue? After consulting Apple, it was known that this is a bug that exists with some applications is. We had extended the Apple bug ticket for the increase.

java - AnyLogic define speed for agents in Main -

Image
I want to define the speed velocity for all my agents in running a parameter. How can I get this from the "Initial Velocity" setting inside the agent? The recommended usage of "main (). Washing speed" is not working: ( Setup: main ------------ ---------- Patient (Walking Speed) | - Nurse | -Interist | -Correction Update 2014-08- 01: get_Main is also not working Say that you have examples of agent patients inside your head. To reach the set parameters speed for the main, you need to If you want to use other parameters of agents inside the main within Patin, then you should call: get_Main () .jet (i) . And the pamphlet If you want to use the parameters of agents inside the patient within the patient, then you can just call: other agent.gate (i). Other parameters, though to go to it Recommended here is also the main one.

plsql - Get the value of a record type from another package in Oracle PL/SQL -

पैकेज ए बॉडी सदस्य फ़ंक्शन getValue (PLS_INTEGER में इंडक्स) रिटर्न VARCHAR2 है colData packageB.vldtnR BEGIN colData: = packageB getColumnData (indx); - मैं निर्दिष्ट सूचकांक ईडीडी से आईडी और नाम आउटपुट करना चाहता हूं; पैकेज बी हैडर प्रकार VLDTNR है रिकार्ड (आईडी PLS_INTEGER; नाम VARCHAR2 (50)) पैकेज बी शारीरिक प्रकार vldtnArryT vlstnr इंडेक्स की तालिका है PLS_INTEGER द्वारा; VldtnArry vldnArryT; फ़ंक्शंस getColumnData (PLS_INTEGER में इंडक्स) है यदि vldtnArry.EXISTS (इंडक्स) = सही है तो वापस vldtnArry (इंडक्स); अगर अंत; समाप्त; कोड अवलोकन: vldtnArry vldArryT से संबंधित है (PackageB शरीर) vldtnArryT vldtnR से संबंधित है (PackageB शरीर) Vldtnr पैकेजबी हेडर में है प्रश्न: मैं पैकेज ए में किसी इंडेक्स के आईडी और नाम को कैसे आउटपुट करूँ? जैसा कि मैक्सिम ने कहा है, आपके पास एक colData वेरिएबल है जो एक रिकॉर्ड प्रकार है, ताकि आप फ़ील्ड को colData के रूप में देख सकते हैं आईडी और colData.name । आप varchar2 रिटर्न प्रकार और एम्बेडेड टिप्पणी के आधार पर एक स्ट्रिंग ...

java - Setting an array property from a single ${property} in Spring bean -

मैं PropertyPlaceholderConfigurer का उपयोग करके गुण-आधारित कॉन्फ़िगरेशन का उपयोग कर रहा हूं मेरे स्प्रिंग बीन्स को स्ट्रिंग की एक सरणी की आवश्यकता है चूंकि मैं सरणी के सटीक आकार को नहीं जान सकता, और मैं स्प्रिंग बीन्स फाइल को बदलने से बचना चाहूंगा (अन्यथा मैं गुणों का उपयोग नहीं करूँगा), ऐसा कुछ परिभाषित करने का एक तरीका है: property.value = {string1, string2} & lt; संपत्ति नाम = "theArray" value = "$ {property.value}" / & gt; मैंने अभी तक कुछ भी करने की कोशिश नहीं की है, मुझे नहीं पता कि कहां से शुरू हो रहा है। आप इस रूप में SPEL का उपयोग कर सकते हैं: property.value = string1, string2 & lt; गुण नाम = "theArray" value = "# {'$ {property। मान} '। विभाजन (', ')} "/> ध्यान दें कि मैंने काम के विभाजन के मूल्य के लिए { और } छोड़ा है यदि आपके पास उन ब्रेसिज़ हों तो एसईईएल को तदनुसार अद्यतन करने की आवश्यकता हो सकती है। अगर आप चाहें तो मैं उसे भी पोस्ट कर सकता हूं):

objective c - How can I move a UIView to an end location but make it slow down as it approaches it? -

I try to move a box from point A = (0, 0) to B = (0, 1000) But I want to be slow because it reaches point B. I tried UIViewAnimationOptionCurveEaseOut but it seems that continuous velocity moves. UIView * box = [[UIView alloc] in this]; Box.frame = CGRectMake (0, 0, 500, 500); Box.backgroundColor = [UIColor redColor]; [Self.view addSubview: box]; // Animation [UIView animateWithDuration: 0.3 Delay: 0.0 Option: UIViewAnimationOptionCurveEaseOut Animation: ^ {box.frame = CGRectMake (0, 1000, box.frame.size.width, box.frame.size.height); } Completion: zero]; Any ideas? The easiest way is to get animation in different stages, with different speeds, such as: // aviation step 1 [UIView animateWithDuration: 0.1 / / First half is faster delay: 0.0 Option: UIViewAnimationOptionCurveEaseIn Animation: ^ {box.frame = CGRectMake (0, 500, box .frame.size .width, box.frame.size.height); } Closing: ^ (BOOL Finish) {// Animation Phase 2 [UIView animateWithDuration: 0.2 / sec / secon...

Batch File Find Path of Exe and Run Program -

I am working on a batch file that searches the browser on the machine and runs a URL. I was able to find the code to find an XI and I know how the URL is run when the way of the browser is hard coded, but I want to put them together. // Comment Browser Shows Firefox @ Path of Path @ @OKO OFF BrowserPath = DIR / S / B FireFox XE // Comment - The URL "% BrowserPath%" "http://www.cnn.com" / Code> use the browser path, except for any command that Dyare / S / b firefox XX Anyone searching for exe Do not need Start will do the following for you: Start http://www.cnn.com will open Url with default browser (note: not quotation marks around url)

Math not working correctly in PHP? -

I am trying to complete the percentage of sales according to the amount originally purchased, here is the code that I I am doing it out with: $ sold = 212; Bought $ 213; Echo round ($ $ sold $ sold) * 100). "%"; Why is it happening 100% when it is not clearly? It should not be 99.5% OK, you're rounding Here are the results ... Try this with: resonance round (($ $ / $ sold $ $ 100,1). "%";

c# - Action Filters in WCF Services -

ActionFilterAttribute (something like ASP.NET MVC) that). What I basically want to do is log in, what is coming from my services, and I do not want to write the logging code in every one code. ServiceContract s Yes the question is very common, but you Understand this idea what I have to do. Yes, this is what you call message-inspector / parameter inspector This is what you want, the WCF custom version log logging The only confusing thing is that you may be the inspector on the WCF service and the WCF proxy In addition, in your case you only need for service side

angularjs - Is there a size limit in Videogular? -

I have a 86MB file that will not play, but the other small MP4 will be what the videodular is a streaming component or it MP3 loads and then runs it. I did not get any error, just loading screen / circle goes forever. Thx Ralph Your file to run on-demand for your file Should be correctly encoded. If you have problems with your MP3. If you need help to encode your files, such as the transcodeing software Or use an online service or.

Add Caldroid library in Android Studio -

I have a problem when adding a library to Android studios I try several different ways to add but this does not work Will I use Android Studio 0.8.2 First of all, I have created the original folder named libraries . I pasted a new folder Then, I pasted the downloaded files in the / libraries folder. After that, I changed the following files. Include: 'library: caldroid: library' settings.gradle Build.gradle dependency {compile 'com.android.support:appcompat- v7: 20. +' compilation 'com.google.android.gms: Play services: 4.0.30' compiled File Tree (DIR: 'Libs', includes: ['* .jar']) Compilation Project (': Library: Calderoid: Library')} But I get this error : Error: Configuration with name 'default' was not found. How to fix it I'm late To import an external library for Android Studio, I follow this conference: Create app directory in the Libs folder. Then copy the requi...

oracle11g - Oracle Privileges -

What type of privilege do I have to reduce the table on any Oracle database? Should I remove any table privilege or leave any table privilege? By removing the table, removes rows from the table. But the table structure is similar, so a deleted privilege is enough to shorten a table? Is that right? Any table privilege requires a drop indicating but some books have been mentioned that enough to be removed please clarify To actually delete a table, the drop command will be used. If you cut the table, if the structure is current and appears, you enter the DESC command. Although both give similar results, but TRUNCATE is fast and does not use much undo option as DELETE. So there is no possibility of rollback and after the triangle cmodes decrease. To reduce a table or cluster, you have to leave any table system privileges. Remove the option that does not have any privilege for the normal user, this is DBA CMD. It can be Cantt rollback and powerful choice. So you should join sys...

android - Xml: trying to put timeline on left with subject on right -

Image
I am trying to put some topics in a timeline on the left and at the right. When I get from the adapter and it should not be a problem in presenting it in XML. It's a format in XML which is a bit complicated for me. In Picture 2, you will see what I've done completely, it's a grid layout. (Picture 1) Like this picture, but I'll give time with the adapter. (pic 2) This is what I have. I'll call the code for myself. & lt;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; RelativeLayout xmlns: android = "http://schemas.android.com/apk/res/android" Android: layout_width = "match_parent" Android: layout_height = "match_parent" & gt; & Lt; LinearLayout Android: Android: Android: layout_width = "fill_parent" Android: layout_height = "2dp" Android: Layout_AlignerPerleLeft = "True" Android: Layout_bale = "@ + ID / Notification" Title: Background = ...