Posts

Showing posts from April, 2014

mysql - How to Create database through java using google app engine? -

Since I'm new to Google App Engine, I need to create a database and table through java code. Can help to create a database, I'm trying to understand this for creating connections, but I'm getting an exception Here's my original connection code Public static zero main (string [] args) {string URL = "JDBC: mice: //127.0.0.1: 3306 / Irrescue = user = root "; Try {class.forName ("com.mysql.jdbc.GoogleDriver"); Connection conn = DriverManager.getConnection (url); + + "Primary ID (ID))" + "(id is not a table, ID + + VARCHAR first (255)," + "VARCHAR (255)," + "age INTEGER," + "primary key ; Statement stmt = conn.createStatement (); stmt.executeUpdate (SQL);} Catch (Clasnotfooundation Expression | Accluse E) {// Todo Auto-Generated Catch Block E.PintstacksCress ();}} But I'm getting an exception like this org.eclipse.debug.core.DebugException: com.sun.jdi.ClassNotLoadedException: retrieve the ty

Replace With Regex Notepad++ -

Image
नोटपैड ++ इस के लिए regex का उपयोग कर बदल सकता है: आप ऐसा कुछ इस्तेमाल कर सकते हैं : क्या खोजें: \ ((\ d +), \ d +, ('। +?'), (\ D +), ('[^'] + ')। + \) इनपुट के रूप में ले जाता है: (35, 25, 'xxxx.com'), \ ($ 1, $ 2, $ 3, $ 4 \) 82, '2014-07-18', 3, '2013-07-18', 1, 1, ...) पैदावार: (35, 'xxxx.com', 82 ', 2014 -07-18 ') । एक एफवाईआई के रूप में, कोड पोस्ट करते समय, कृपया छवियों का उपयोग न करें।

c++ - Redefined variable in the other module -

Why do we redefine the variable in other modules, so it is OK to add this module together? I have written two modules main.cpp and module.cpp as the following: // - main.cpp-- // # include & lt; Stdio.h & gt; Int main () {int i = 5; Printf ("I value is% d", i); } and // - module.cpp - // int i = 7; I am now compiling and adding g ++ as the following: g ++ -c main .cpp g ++ - c module. cao g ++ - o bin main.o module.o and it's okay. But I hope the compilation will be successful, while the linker will throw an exception like redefining varaible when I'm running .bin output then the value of i is 5 . UPD: I understand that if we use I as global variable module main.cpp that linker will throw an error. The main variable in the function is a local variable of i function. It is not visible and is present outside the function is. Consider the following example #include & lt; Iostream & gt; Int i = 3; Int main (

How does Neo4j physically store data? -

I want to present Neo4j as a proposal for one of my clients. I have some doubts I should know how Neo4j stores data in a database, physical representation. My understanding of this is as follows: Nodes are stored in an earlier connection with an indicator, and relationships are treated as double-linked lists. Is stored (for a start node and for an end node) when the disk is loaded. Each relationship has two indications in the next connection (one in the next connection for the initial node and the other for the second node) so that any unit only points to the next digit of its own, when it is a Together, the whole list is made. But I'm not sure what I got is correct. Please guide me on this issue. Regards, Apurva Well International "), which some people wrote in Neo Techology

How to include a php file in subdomain from main domain -

मेरे पास मेरे सर्वर में दो फ़ोल्डर्स हैं: - मेन डमैन-। Header.php - Index.php -footer.php - सबडोमेन-इंडैक्स.एफ़पी अब मैं header.php को मुख्य डोमेन से index.php में शामिल करना चाहता हूं जो उप डोमेन में है। शामिल करें फ़ंक्शन का उपयोग करके मुझे त्रुटि मिलती है स्ट्रीम को खोलने में विफल: ऐसा कोई नहीं फ़ाइल या निर्देशिका में / home / content / xx / xxx / xxxx / xxx / मुझे पता है कि यह त्रुटि तब होती है जब कोई निर्दिष्ट पथ पर फ़ाइल मौजूद नहीं है, लेकिन मैं मुख्य डोमेन से उप डोमेन में एक फ़ाइल शामिल है? पहले से आपको धन्यवाद मुझे पता है कि यह सवाल आठ महीने पहले पूछा गया था, लेकिन मैंने अभी तक यह किया है एक ही सटीक समस्या है और इसे हल किया उम्मीद है कि इससे भविष्य में लोगों की मदद मिलेगी जो एक ही चीज़ में ठोकर खाते हैं। उदाहरण के लिए, मान लें कि आपके पास दो उपडोमेन हैं: गाजर। कोक और डॉट कॉक। कॉम। गाजर उपडोमेन में आपके पास एक फ़ाइल है: गाजर.कोक / स्क्रिप्ट / लॉजिइन। Php और आपके पास चॉकलेट सबडोमेन में एक फ़ाइल है: chocolate.cake.com/index.php < / li> आप &q

reporting services - Databar in SSRS throws exception While integrating With ASP.net -

I am creating reports using SSRs that show statistics This works fine with the RDL file when I am integrating it into ASP.NET, then shows the following error. The maximum expression for the chart is 'DataBar 1' in which there is a consolidated task (or running valve or relative function), which is another integrated task (or running value). Overall functions can not be nested inside other total tasks. Any ideas to solve this error. I had this problem I know that this question was asked some time ago, but I have to solve Before the help was discovered, so I hope it can help someone else. In my case this is due to the database SUMs are set to determine the values ​​of the bar, and the horizontal axis is being set to the maximum auto. I think whatever was happening in that situation The maximum renewable maximum is effectively maximized (SM), which is not allowed, which is not allowed. I used to change my query around and change the value of one percent (still Use

Add Named Range to Excel using C# -

I am creating excel sheet which is named after the class created using code. ExcelRange namedRange = Sheet1 Seals [2, Startcollum + i, Region Andrra, Start column + I]; Package. Workbook Name. Add ("Named Range", Named Range); namedRange.Dispose (); After saving the axle file, I am trying to open the file. At that time it gives me an error like Is there a clue to this problem I To find the reason I am using this designated category by adding this code more dynamically to a loop. There are some names with spaces in some time & amp; Character for the category name. The same problem is when it is opening the sheet, all named categories will be abandoned which are invalid

java - Exporting Runnable JAR in eclipse with User Libraries included -

I am trying to create a runnable JAR file from a project in which I am importing org.apache.commons.io I tried to export and check the box to include all dependent libraries, but I am getting this output: "exception" in the thread "main" java.lang. NoClassDefFoundError: org / apache / commons / io / filefilter / TrueFile Filter by tvSort.Main.main (Main.java 36) Reason: java.lang.ClassNotFoundException: org.apache.commons.io.filefilter.Tr ueFi java.net.URLClassLoader $ 1.run (Unknown Source) on leFilter at java.net.URLClassLoader $ 1.run (unknown source) at java.security.AccessController.do (unknown method) at java.net.URLClassLoader.findClass ( Unknown source) java.lang.ClassLoader.loadClass (Unknown Source) on the Sun.misc.Launcher $ appClassLoader.loadClass (unknown source) on java.lang.ClassLoader.loadClass (unknown source) ... 1 more Any help would be appreciated, thanks. / P> Did you try to install a classpath in the manifest? For example cl

mysql - Variable in trigger doesn't work for me -

Image
I am trying to create a new trigger like this. But it gives me an error. DELIMITER Email at SENT @ cnt = (SELECT count (*) by email ID where position = 'left'); If @cnt = 0 then - my question is Eid IF; END $$ DELIMITER; This trigger returns this kind of error You for every line Enter email for each line before email / post.

Polymorphism in Go - does it exist? -

I'm trying to make something real simple: goter and setter methods and it seems that the setter methods Not allowed Looking at this code: Package main import "fmt" type MyInterfacer interface {Get () int set (i int)} type MyStruct struct { Data int} func (this mystate) () set up IT (iit) (iit) {this.data = i} func main () {s: = MyStruct {123} fmt.println (s.Get) ) Asset (456) FMT. Printline (S.Gate ()) var milesintheater = s m .Set (789) FMT. The print line (get.)}} The set method does not work, because func (this MyStruct) set (i int) , This MyStruct is not an indicator, and changes occur as soon as the function exits, but it will not be compiled by compiling it as this * MyStruct Is there any way? Here is the correct version of your code (). This is not really polymorphism, but the use of an interface is good go style. Package main import "fmt" type MyInterfacer interface {Get () int set (i int)} Type MyStruct Struct {data int} func

java - In around avice, how to get the 'type parameter' of a parameter of the advised method -

With Spring AOP, I'm writing an around that the @MyAnnotation . Suppose that the blocking method was declared as follows: @My annotation public string Some method (ArrayList & lt; Integer & gt; arrList) {...} < / pre> Method in the advice, I have to get the information that the first parameter, i.e. arrList , type ArrayList type parameter with Integer . I have tried the following by doing this @ around ("@notation") Public Objective Advice (Proceedings JointPoint PJP) {Method method = (( MethodSignature) pjp.getSignature ()) getMethod () .; Classroom & lt ;? & Gt; [] Parameters class = method.getParameterTypes (); Logger.info (((ParamyTermetime) Parameters Class [0] .getGenericSuperclass (). GetActualTypeArguments () [0]) ...} But the one who logged out was just a < The code is> e . How do I insist that it is java.lang.Integer < P prints> Try it: @Around ("@notation (mynotation)" throws public obj

design patterns - 'Intended to be' way to initialize a goog.ui.Control model? -

I find it amazing that the Google Closure Library not only provides functionality, but to build a solid architecture of a method and components A guide for getModel and defines setModel goog.ui.Control goog.ui.Component . . I think its purpose is MVC : is the controller goog.ui.Control Goog.ui.ControlRenderer Model is goog.ui.Control.model_ property This model in the entire library Could not find an example of the usage. I believe it keeps for complex modules which Google uses for itself, however, this idea prevents it from being interesting. Now, this question is oriented: you goog.ui.Control : inside the constructor? Should it be given as a parameter for control? Should it be set out from an initial form? Goog.ui.Control exits goog. Ui.Component , which has a method. This is not a specific use in the library - the details in the docs "The arbitrary data associated with the component is given as an object." Such as meta-data "

arraylist - Update Tree node using pass by value in Java -

Before I show my problem which I understand: uses java from near pricing. Under the example, I refer to the "my_root" reference, node (), and "NodeModify (my_root)" in the row; The compiler is expected to pass the copy of the "my_root" memory address and "root = new_node;" inside the function I.E = & gt; Hopefully the memory location / address of the root will be updated at the location / location where "new_node" is located. Surprisingly, it does not reflect back from the main () function, from where it was called ??? package com.trees; Public class nodeemption {public static zero node modid (node ​​root) {System.out.println ("[nodmodivate] is the latest root:" + root); Node new_node = new node (0); System.out.println ("[node] is the new node:" + new_node); Root = new_node; System.out.println ("[NodeModify] is root:" + root); } Public static zero main (string [] arg) {node my_root = new no

javascript - Send decimal number with ExternalInterface between JS and AS3 -

मुझे बाह्य संख्या में दशमलव संख्याओं में समस्या है AS3 कोड: var पूर्वावलोकन: बिटमैप (लोडर कंटेंट); var w: संख्या = पूर्वावलोकन.वेदथ; var h: संख्या = पूर्वावलोकन.हाइट; ट्रेस (डब्ल्यू, एच) // इसमें मुझे मूल्य मिलते हैं: 887.9 और 665.95 ExternalInterface.call ('परीक्षण', डब्ल्यू, एच); जेएस कोड: फ़ंक्शन परीक्षण (w, h) {console.log (w, h); // और मेरे पास मूल्य 0.95 और 0.7} क्यों? सभी उत्तरों के लिए धन्यवाद। मैंने एडोब उदाहरण के साथ परीक्षण किया है ()। मैं एएस में एक आकार (887.9, 665.95) बनाएँ, और एक फ़ंक्शन को अपनी तरह जोड़ता हूं। यह अच्छी तरह से काम करता है। इसलिए, यह कुछ और से प्रभावित हो सकता है। उदाहरण के लिए, आप आकार या अन्य DisplayObject बिटमैप को बदलें।

How do I make an sbt plugin for compiler plugin with cross build support -

I have an SBT-plugin that updates the Skelek option to add the compiler-plugin with the release of Scala 2.11 I need to change the version of the compiler-plugin based on the version of skeleton used in users' projects. I understand that SBT itself uses 2.10, so I think my SBT-plugin should be compiled with only 2.10. However, I change the version of the compile-plugin to build on runtime. At the moment I do this: Val device settings: Seek [setting [_]] = {sec (library dispersion + = "group" %% "artifact"% "version%" range)} Is this the right thing to do? I only have one SBT-plugin release (2.10) and tries to find the correct compiler-plugin version (2.10 or 2.11) on runtime. In addition, the SBT-plugin is the compiler-plugin, so I declare that as a general dependency in build.sbt. In this case SBT-plugin will only use version 2.10? I am not quite clear what are the actual questions, but here are some ideas that came to my mind. :

mysql - How to update one table from another table? -

I want to update the rows from one table to another, both of which are the same structure and I use this query as SAT ST.tag_uid = apprv.tag_uid, st.stk_id = apprv.stk_id as UPDATE bh_master_ritesh_stock; bh_stock_approval ashr approv WHERE st.stock_id = apprv.stock_id but it gives me this error, is an error in your SQL syntax; Where is my fault, check the manual that uses line 3 on 'Asperv WHERE st.stock_id = apprv.stock_id' near 'FRRO BH_stock_provals near the correct syntax for your MySQL server version. Or am I using the wrong query? Try this code: Because UPDATE cant Use section to

Am I allowed to share YouTube dataset ? -

I have used the YouTube API to crawl the publicly available content of the website to develop a dataset for research. (Comment on video) purposes. Datasets are completely anonymous and all use IDs and other information that can lead to the identification of users. I was thinking that I have permission to share the dataset or not with other researchers? Or what are the conditions for doing this? Thank you, Maral Reading as well as you needed. I am not an advocate and can not interpret these words for you, but it seems that you will be in close vigilance section 4 of the prohibition: Your API will not subscribe, and you Encourage or create functionality for your users or other third parties: Sell, lease, lend all or any part of the YouTube API or API data to any third party To give, express, redistribute or sub-license (besides contact the legal counsel of your organization for the final Code;

c# - WCF dynamic json to Dictionary -

I am using ASPX 4.5. The client sends a JSON object with a dynamic field (can be different each time) Function Collection DataAnSession (formData) {var data = {}; Data ["formData"] = formdata; $ .ajax ({url: "MY_URL / StoreFormData", type: "post", data: JSON.stringify (data), contentType: 'application / json', datatype: 'json', success: function (data, textStatus , Xhr) {console.log (data); console.log ("success");}, error: work (xhr, textStatus, errorThrown) {console.log ("failure");}}); } On the server side, I'm trying to convert that Jason to a dictionary, but I'm getting error 500. Public String StoreFormData (Dynamic FormData) {JavaScriptSerializer} [WebSite] Jss = new JavaScriptSerializer (); Dictionary & lt; String, string & gt; FormValues ​​= jss.Deserialize & lt; Dictionary & lt; String, string & gt; & Gt; (Formadata); Return "Aaaa"; } What am I doing?

Android: Can we read file from /data/data/ folder using su command in non rooted device -

Hi all I'm confused about "su" command, it's working in a non-rooted device. As I want to read a file from the / data / data folder on the stackover I can do different solutions to read the file from this folder using "su", but it is not working on my non rooting device. Please some body advises me. string comando = "cp -r / data / data" /local/data.txt / sdcard / 123 / "; Process process = runtime.gettime () .exec (" su "); DataOutputStream OS = new dataoptputstream (process.jetoutputstream ()); oslitimes (comando +" \ n "); os.flush ( ); Os.writeBytes ("Exit \ N)"; os.flush (); Su Binaries are only available in the contained phones. What happens after the phone is retired? system / read-write application Su binaries are mounted with copies, copies are copied to Copy / System / Bin or / System / Xbine folder. The Root Manager app is installed. [As SuperSu or SuperUsers] This is because app

Python OOP Exercise -

I am trying to use classes in Python, and have written this exam program. This is somewhat of what I found in another question which I found here on stack overflow. The code looks as follows: class student (object): name = "" age = 0 major = "" # class "constructor" - this is actually an initial Def __init __ (self, name, age, major) is: self.name = name self.age = age self.major = major def list_values ​​(): print "name:", self.name print "age:", self . Print "Major:", self. Major def (name, age, major): student = student (name, age, major) return student print "a list of students." Steve = Melchistant ("Steven Schultz", 23, "English") Johnny = Macstastent ("Jonathan Rosenberg", 24, "Biology") Panny = Macstastant ("Penelope Marmolytakis", 21, "Physics") Steve.List_Value () Johnny.list_values ​​() Penny.list_values ​​() When I run it, get error &

vba - How to nest IF, AND, OR in excel -

The lack of a legible format in Excel formulas is making it very difficult for me. I need to write a formula which: Check if J2 is "No" If not then set the value " If so, check the date in E2 against the given date after the given date, set the value for "pass" If the date given earlier, check that G2 is "cancel" and K2 if the correct set value is "unsuccessful" then if false set To "pass" the value "no", or the G2 is "zero" And K2 is "Yes" If I was using Javascript then something like this might appear: Function Formulas MacHead Heart (J2, E2, G2, K2, The Date) {if (J2 == "No") {if (E2> givenDate) {if ((G2 == "Cancel" and "amp; K2! =" No ") {G2 == "Zero"! = "Yes"}) {Return "Failure" I "," At least one syntax error "does not mention the possibility to mention the logic issues I write During the f

javascript - How to position text over an image with html? -

Image
How do I focus a text on the image with html without a CSS file? I want to do something similar below but I 'm having trouble and I am also using this function There is also CSS in your question. I have this solution for you: HTML: & Lt; P style = "condition: complete;" & Gt; I did the text & lt; / P & gt; & Lt; / Div & gt; Hope it helps.

wcf - HTTP could not register URL (remote debugging) -

C #, Windows 7 - I write an AutoCAD plugin and use Remote Debugging (MS Visual Studio). My plugin should work as a WCF service. AutoCAD is an unmanaged application and should be in the form of a host for my service. I am reading a book about WCF, and I try to use it, I can not use acad.exe.config for my service settings: I do not have permission. So I do it myself (I'll teach them with my XML file, but later, after refactoring). Code of my "server" (this code begins with AutoCAD): Private static zero runs service () {AP Document Doc = cad.DocumentManager.MdiActiveDocument; Try {Uri Address = New Uri ("http: // LocalHost: 8000 / Cread Service"); BasicHttpBinding Binding = New BasicHttpBinding (); Binding .name = "HTBbinding"; Binding. Hostname ComparisonMode = Hostname ComparisonMode. Strongwoldcard; Binding. Security.mode = Basic HTPSAquiry Mod.No.No; Host = new service host (typef (CADSWire)); Host.AddServiceEndpoint (typeof (ICadService), bind

php - Why laravel 4.1 is giving class does not exist error for a namespaced class? -

I'm having a problem with Laravel 4.1. I am following a tutorial series in my "app" directory "Acme / Transformers" folder, which has two classes "Transformer.fp" and "Les Transstrofer.fp". When I use "LessonTransformer.php", I'm having the following problem in the LessonController class of the controller directory. ReflectionException category Acme \ Transformers \ LessonTransformer does not exist < ">" autoload ": {" classmap ": [" App / Order "," app / controller " "app /" AP / database / BG "," app / Test / Test Sisiapeepi "," app / Acme "]," SSR 0 ": {" Acme ":" app / database / migration "Acme"} < / Code> and "composer dump-autoload-o" went but there was no change in output I have no idea what's going on, please help me. Here's my lesson clip Olr.afpi class Ac

jquery - Text parsing and formatting with JavaScript -

I am working in an application where I face problems while formatting text (bold, italic, and underlined) Have to do I'm creating an array by dividing the entire text with # b #, # i # and # u # but for some scenarios this is difficult to divide. I have another situation where I have to separate the words like '%%' as well. Some examples are: 1% # # # # # # # # # # # # # # # # # # # # # # # # # # In all cases, I need an array like the following - [" A "," "," Sample , "", with "%% text b & gt; with & lt; / b & gt; With; %% "," ", & lt; B & gt; Text format & lt; / b & gt; "] [" %% & lt; B & gt; A & lt; / B & gt; %% "," | "," %% & lt; B & gt; B & lt; / B & gt; %% "," "," will be good. "] // space is excluded var s =" a # i # sample # / i # %% text # b #% text format # b # ", s1 =&

unix - recoding of a huge file -

मेरे पास एक बड़ी फ़ाइल है जिसमें निम्न प्रारूप है: #pair: 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 # पेयर : 1 2 0 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 # 1: 1 2 1 2 0 0 1 इत्यादि आदि मुझे आशा है कि मैं लिनक्स में कमांड का उपयोग कर सकता हूं, प्रत्येक लाइन को "# पेअर" से शुरू होता है और इसे पिछले 3 कॉलम सीधे इस लाइन को सहारा देते हैं। उदाहरण के लिए: # पेअर: 1 2 1 2 0 0 1 में परिवर्तन: < पूर्व> # पेअर: 1 2 1 2 0 0 1 बहुत पहले धन्यवाद! Awk के साथ आसान है: awk '/ ^ # pair: / {$ 6 = "\ n" $ 6} 1 'फ़ाइल & gt; नयाफ़ाइल यह मानता है कि फ़ील्ड गिनती स्थिर है, और # पेयर के अंत में यह सफेद स्थान है: लाइन सहनीय

c# - copy a file to shared folder on another computer -

I am moving the copy file to the mapped network location. If I try to do it manually then everything is working fine. I get no exception by running the following code, but I do not get the code at the required location. string _ share location = @ "c: \ user \ pddd \ appdata \ roaming \ microsoft \ windows \ network shortcut \ system-test"; If (directory .xis (_shared location) & amp; amp; file.exis (@ "c: \\ automation \\ test \\ test1 \\ events.json") {file copy (@ "c : \\ Automation \ test \\ Test 1 \ Events .Jason ", Path.Combine (_space location," Event 11.Jusus "), True);} That Any suggestions with issue. _SharedLocation variable, it is in place : "... \ Windows \ network shortcut \ ..." I'm just guessing here, but do you have a network fol Tringing to refer to a shortcut in the Network folder instead of the address? This will never work: Copy (myOriginalFile, "C: \ ... \ MyShortcutToANet

android - Removing XML node Using Xpath -

I am trying to delete some nodes from the XML document but XML is not working here & lt ;? XML version = "1.0" encoding = "UTF-8"? & Gt; & Lt; reg> & Lt; Users & gt; & Lt; Name & gt; Adik & lt; / Name & gt; & Lt; Email & gt; adil@mail.com< / Email & gt; & Lt; Picture & gt; /storage/sdcard0/XLEZData/EZImage/20130425163759.PNG< / Pictures & gt; & Lt; Last Adrated & gt; 7 April 2014 09:28 28: 27 & lt; / Last Edit & gt; & Lt; / User & gt; & Lt; Users & gt; & Lt; Name & gt; Adil & lt; / Name & gt; & Lt; Email & gt; adil123@mail.com< / Email & gt; & Lt; Picture & gt; / Storage / sdcard0 / DCIM / camera / 20140318_165923 (0) .jpg & lt; / Pictures & gt; & Lt; Last Adrated & gt; 7 April 2014 09: 29: 06 & lt; / Last Edit & gt; & Lt; / User & gt; & Lt; / Reg> And here is the code Private

configuration - How to get key in hash value in puppet -

I do not know whether it is possible to appear to me like this: $ some_external_value = 'pew_pew' $ dict = {confirm = & gt; $ Make sure, configuration = & gt; {"Random_name - $ {some_external_value}" => {Command = & gt; 'Python script.py config / random_name - $ {some_external_value} Cfg ',}, "some_other_name - $ {some_external_value}" => {Command = & gt; 'Python script.py config / some_other_name - $ {some_external_value}. Cfg ',}, "Without-External" = & gt; {Command = & gt; "Python script.py configuration / non-external code", user = & gt; 'Cluster',}}} notice ($ dict ["configuration"] ["some_other_name - $ {some_external_value}"] ["command"]) I get notice: scope (class [main]): Python script.py config / some_other_name-pew_pew.cfg Is it just a bar and later to write the key name Just mentions it? "some_other_name - $ {some_ex

elisp - How to customize Emacs key bindings for going to specific line / end of buffer -

I want to customize the Macs have to press ESC: < n and n Kbd> ESC: $ REET takes me to the last line (similarly how the Vi editor works). < / P> How can I get it into my AMACS configuration file? Currently I have .emacs : (global-set-key (kbd "M-9") 'back-window' (global-set-key ( Kbd "M-0") 'other window) I do not want to use any off-shelf solution (eg evil) because they are bloated and messed up with their existing shortcuts can do. Put it in a file and load (execute the meaning of load): < pre> (defun vi-goto-line (arg) (interactive "Seline:") (message args) (if (string = "$" args) (end-of-buffer) (Goto-the-line (string to Entry Arg)))) (Global-set-key (KBD "M-:") 'V-goto-line) You can do this to load Use the MX load-file and then enter the file interactively. Note key combo M -: < (which ESC : the same ) already Imaks There is a meaning in it

php - jQuery-File-Upload without file -

I am using jQuery plugin "jQuery-File-Upload" to manage a form. I Tried to search my problem but nothing. The problem is that in this form an optional field is allowed for file upload. When I insert a file, it all goes well, but when I decide not to include a file then the plugin script will not work. Now I know that this is a plugin to upload files exclusively, even then it happens What is the way to solve this problem? Thanks Peter P:> Update to add code: form.fileupload ( {Url: 'php / file.php', data type: 'json', autoUpload: wrong, replace fileInput: incorrect, sequential upload: wrong, maxfileSize: 10000000, minFileSize: 0, accept file type: /(\.:\/ ) (Gif.jpe? G | png) $ / i, add: function (e, data) {data.context = button.click (function (e) {e.preventDefault (); // validity for side data / / Data to recover. Submit ();})}}, failed: function (e, data) {console.log ('unsuccessful') to send; console ;log (data);} T: Function

html - Converting a Java program with main method into a servlet -

I am new to servlets. I have a query processor Java program and now, I want to use it in web application . I have an interface (HTML) that generates the query and I want to run the program on a button click in the interface. For this, I want to convert the Java program into a Java servlet. I am working in Net Beans. The structure of my java program is as follows: public class ABC {// code public ABC () // constructor {// code} public static zero main (string [] Args) {// code}} I want to convert it into a servlet The following is the default servlet structure in Net Beans. Public class demo expands Httpservlet {/ * -------- ---- ---- * / Public Zero Processor Request (HTTPSRCLATOR request, HTTPSteam response ) Servlet upption, IOE expansion {/ * code * /} / * HTPSRLL methods - DOGet (), DOST () etc. * /} Option for main function in servlet? Which method is executed before Sewlett starts? Can I run Java program on a HTML page by clicking on a button so that I can termi

r - How to convert list file to matrix -

I have a list file as the following: & gt; Results [[1]] [[1]] [[1]] [[1]] [[1]] [[1]] [[1]] [[1]] [[1]] [[1] [1] "1" "swelling" "37.5" "a" "b" [6] "f" [[1]] [[1]] [2]] [[1]] [[1]] [ [2] [1] [1] "1" "opopassis" "37.5" "c" "g" "h" [1]] [[1]] [[3]] [[1]] [[3] ] [1] "1" "Repair" "25" "A" "H" [2]] [2]] [[1]] [2]] [[1]] [[1] ]] [[2]] [[1]] [1]] [[1]] [1] "2" "swelling" "20" "f" [[2]] [[1]] [[2] ]] [[2]] [[1]] [[2]] [[1]] [1] "2" "apoposis" "40" "g" "h" [[2]] [[1]] [[3]] [[2]] [[1]] [[3]] [[1]] [1] "2" "repair" "20" "H" In addition, it is the Outlook for dput function: dput (list) list (list (list (list (list (c ("1" (c ("1", "apoptosis" , "37.5&

three.js - ParticleSystem as ShadowCaster -

Is there any three Can the JS particle system shade somehow? I put together a scene and was able to put only cube shade. I have correct castShadow on the particle system, in this case there is also a pointcloud. There was a similar problem in trying to shade me from a simple geometry. At least in my case, it seems that the face should be oriented towards the element where the shadow should be visible (and Dubbedded has not decided it). So, you need some particles in wrong direction. Can they be presented twice?

javascript - How to select an element that was created in a for loop? -

I have loaded lots of elements on my page dynamically in each list, one descriptor and one in each list A highlighter is overlaid on the image. What do I want when a user enters the list item, the other element is highlighted. My current code only highlights the last element in .viewer , no matter what list item I run. What is the best way to handle it? for (i = 0; i & lt; Ajax lang; ++ i) {var listid = 'listitem -' + i; Var mapad = 'mapitim -'; $ ('.list'). App ('& lt; div id = "' + listid + '" & gt; lots of text & lt; / div & gt;'); $ ('. Viewer') Attachment ('& lt; div id = "' + + + + '+'"> here it is ;); $ ('#' + Listid). Hover (function () {$ ('#' + mapid) .toggleClass ('Highlight');}); } the last value assigned by it in Hover Time removed for event handlers, so you have to make sure that you have relevant values. Try putting

mysql - slow MongoDB with an easy query -

I am a MongoDB starter and I have a small problem like a simple query: Code> Db.table.find ({"text": / a /, "nb_ret": {"$ gt": 2}}) 5min like before giving the result < / P Intel Xeon E3 1225v2, 4C / 4T, 3.2GHz +, RAM: 32 Go, Disc: 2x2 to SATA This is normal? Your query is not easy in any way, because it involves executing a match against a regular expression is. Some fixes are new to . E.g., db.table.ensureIndex ({"text": "text"})

jquery - typeahead.js default select the first suggestion -

I am using the angularJS library by type siftion for typeahead, which in fact typed head. JS and bleeding Uses JS and Jazzery. I have typeheadhead.js v 0.10.2 and jquery 1.10.2. My goal is to create a facility for search where users can only select from the suggestions, so I have implemented it in such a way that if the result of the suggestion is not selected Then a query has been submitted with the tap parameter and the suggestion has been submitted. I have set my options as minLength: 1, hightlight: true, editable: false I have three datasets: var lahounders = new bloodhound ({Datum tokoniser: bluehound.tokenizers.obj.whitespace ('name'), querytokenizer: bloodhound.tokenizers.whitespace, prefetch: {url: '/ url / param' , Filter: function (store) {return $ .map (store, function (store) {return {name: store.name}}}}}}); I call clear cash for all of them and then initialize them, just to let you know. I am not very expert in this, but doing so solves my

How to calculate the time taken to load module in gwt? -

I am using a custom gridview widget and large amounts of data (say 1000 rows). I know that it takes more time. And I want to know how much time it takes to load this grid. & lt ;; Doctype html & gt; & Lt; Html & gt; & Lt; Top & gt; & Lt; Link rel = "stylesheet" href = "custom.css" & gt; & Lt; Meta http-equiv = "content-type" content = "text / html; charset = UTF-8" & gt; & Lt; Title & gt; CustomWidget & lt; / Title & gt; & Lt; Script type = "text / javascript" language = "javascript" src = "mywidget / mywidget.nocache.js" & gt; Function startTime () {var today = new date (); Var h = today.getHours (); Var m = today.getMinutes (); Var s = today.getSeconds (); // Add a zeros to the numbers & lt; 10 m = checktime (m); S = checkTime (s); . Document.getElementById ('text') innerHTML = h + ":" + m + ":" + s; T = setTimeou

python - Dictionnary item with `.` in index -

मेरे पास यह शब्दावली है # Views.py परिणाम = {} # सामग्री प्रकार सेट करें परिणाम ["teams.team"] = [] परिणाम ["users.userprofile"] = [] sqs में परिणाम के लिए: content_type = result.content_type () # teams.team, users.userprofile, ... परिणाम [content_type] .append (result.get_additional_fields ()) # get_additional_fields = & gt; {title: "", ...} मैं कैसे एक django टेम्पलेट में teams.team आकार प्रदर्शित कर सकते हैं? मैंने कोशिश की {{results.user.userprofile } लेकिन ऐसा लगता है कि । गलत कर रहे हैं। धन्यवाद आपका शब्दकोश : नहीं = का उपयोग निम्नानुसार होगा: परिणाम = {" उपयोगकर्ता .userprofile ": {" title ":" the name "} ...} तब आप ऐसा कर सकते हैं: {{परिणाम ['उपयोगकर्ता .userprofile '] [' शीर्षक ']}} आपके अपडेट किए गए प्रश्न का उत्तर: {{लेन (परिणाम [' teams.team '] )}}

java - How can a thread acquire lock on two objects simultaneously as in this case? -

सार्वजनिक शून्य विधि (प्रकार 1 inst1, type2 inst2) {सिंक्रनाइज़ (inst1) {सिंक्रनाइज़ (inst2) {// मैं इस कोड के इस टुकड़े से समझ सकता हूं कि एक बार धागा विधि में प्रवेश कर लेता है, यह inst1 पर लॉक प्राप्त करता है, और फिर इसे बिना किसी रिलीज के ताला प्राप्त करता है Inst1 लॉक मुझे लगता है कि इन दोनों वस्तुओं को अन्य थ्रेड से लॉक नहीं किया जाता है। अगर एक धागा एक ही ऑब्जेक्ट पर एक बार लॉक हासिल कर सकता है और लॉक के बाद केवल एक लॉक का ही इस्तेमाल कर सकता है वर्तमान ऑब्जेक्ट पर जारी किया गया है, कोड का यह भाग मान्य कैसे हो सकता है, या बल्कि यह एक मान्य कोड है जिसे मुझे लगता है कि मैंने कहीं देखा है? और क्या होगा अगर Type1 और Type2 समान हैं? यदि हम पद्धति को सिंक्रनाइज़ करते हैं, तो यह विधि के पैरामीटर प्रकारों के अलावा किसी अन्य वर्ग में रहता है, इसके कारण क्या होता है? 1 यदि कोई थ्रेड एक बार में केवल एक ऑब्जेक्ट पर लॉक हासिल कर सकता है और केवल मौजूदा ऑब्जेक्ट पर लॉक जारी किए जाने पर केवल एक लॉक का ही इस्तेमाल कर सकता है, तो यह कैसे कोड का टुकड़ा वैध हो सकता है, या बल्कि

javascript - Kendo UI - Tooltip in a grid -

I am trying to create a tooltip for my grid like this: KendoTooltip ({autoHide: true, showOn: "mouseenter", width: 125, height: 125, position: "true", filter: $ ("grid-content a.hasTooltip", content: cando ("# grid"). ".k-grid-content a.hasTooltip" .template ($ ("# storeTerritory") .HTML ())}); Template definition: & lt; script type = "text / x-kendo-template" id = "storeTerritory"> #for (var i = 0; i & lt; Territories.length; i ++) {# #if (state! = 'Null' and territories! = '') {# & Lt; p & gt; # regions = [i] .TerritoryDescription # & lt; / p & gt; #} and {# & lt; p & gt; Notification is unavailable & lt; / p & gt; #} # #} # & lt; / div & gt; & lt; / Script> I have set a sample here: I get a reference error: area in the console error is not defined I'm putting a mouse on 'Wilton' Let's assume tha

php - Error: mysqli_fetch_array() expects parameter 1 to be mysqli_result, boolean given in -

इस सवाल का पहले से ही एक उत्तर है: < 33 उत्तरों $ result2 = Mysqli_query ($ con, "चयन करें * से a_option WHERE $ राशि 1 & gt; मूल्य"); जबकि ($ row2 = mysqli_fetch_array ($ result2)) {गूंज $ पंक्ति 2 ['कंपनी का नाम']। "" $ पंक्ति 2 ['उत्पाद का नाम']। ""। $ पंक्ति 2 ['मूल्य']; गूंज & lt; br / & gt; '; } मूलभूत MySQL कमांड ठीक काम कर रहा है, लेकिन जब मैं परिशोधन खोज करने की कोशिश करता हूं तो यह पैरामीटर त्रुटि फेंकता है: mysqli_fetch_array () पैरामीटर 1 में दिए गए mysqli_result, बुलियन को दिया जाता है, इसलिए केवल मुख्य कोड को पोस्ट करने के लिए डीबी के संबंध में किया जाता है। कठिन है, उसी प्रश्न के इतने सारे उत्तर दिए गए हैं, कुछ कैसे इनके माध्यम से जाने के बाद मैं त्रुटि को हल नहीं कर पा रहा हूं। क्या कोई एक बिंदु / त्रुटि यहाँ हल कर सकता है .... धन्यवाद !! इस तरह से आपकी क्वेरी परिवर्तन में समस्या SELECT * से a_option WHERE मूल्य & gt; $ Amount1; यदि क्वेरी ठीक काम करती है, त

postgresql - Setting up postgres on VPS for production -

Therefore, I have a pyramid app with a postgrez database on my local machine, to get the data dump in my database Did a pg_dump, which is called pg_dump_2014-04-22 I then pushed this file to git, and pulled a vibration into the VPS to get the file. Now, I've already installed postgres on my VPS. When I do sudo -u postgres psql on my VPS, I can connect it but there is no relation (naturally). Both my user names and database names are postgres . So, I tried psql postgres & lt; Pg_dump_2014-04-22 , but this error returns psql: FATAL: role "root" does not exist . I also tried to pg_restore -h localhost -U postgres -d postgres pg_dump_2014-04-22 , and this indicates my password, but then the error < code> pg_restore: [Archiver (db)] Connection happened for database "postgres": FATAL: password authentication failed for user postgrades " What am I missing here ? < You must first create a user and database where you can import

php - Uploading a PDF with CodeIgniter not working -

I am trying to upload a PDF to my website using the CodeIgniter framework. It's ok to upload a JPG or PNG, but it's not a PDF. On my page I have two forms, but if I print the 'userfile' post from my controller, then I get the file name pdf. This is my viewpoint code: This is the code in my controller: $ config [upload_path '] =' Applications / User Docs / '$ this- & gt; Input-> Post ('type document'). '/'; // is a part of the directory in 'type document' where $ config ['allowed_types'] = 'pdf' is uploaded; $ Config ['max_size'] = '0'; $ This- & gt; Load-> Library ('upload', $ config); If ($ this-> upload-> do_upload ('userfile')) {$ data ["succesmelding"] = "Upload document value document."; // upload has been done} and {$ data ["fatmelding"] = "er an e-fouut octetraden bj hat uploading van document". ;; // upl

Simple way to send php post data with no form -

I have a file called "receive_data.php" on my server, which receives postal data from excel VBS throughout the day is. This file incorporates data into the database in the database, for which the equipment and reports for the business I work for are being used throughout the day. I have now created a report, which is generated by a parsecript when the php file "show_data .php" can be viewed. When Show_data.php is viewed, ideally I would like to 'ping' "received_data.fp" with the same values ​​below: $ _POST ['code '] = 1; $ _POST ['r_id'] = 24; The company I work for uses a very old browser, so using something like Angiezer is not an option because it can be incredible in IE is. The php file contains "receive_data.php", but it is still a matter of enabling the variable sent as a 'variable' Finally I do not want to modify "receive_data.php" in any way. I can modify the "receive_da

redirect - django return to index when there is no next= in URL -

I created a login, which would have to redirect to the previous page (with /? Next = /) that started working , But when there is no next = it remains on the login page without redirecting to the index. Where should I make my mistake? DR login_user (request): login_form = loginForm (request.POST or none) if request.POST and login_form.is_valid (): user = login_form.login (request) if user: login (Request, user) HTTP response redirect (request.POST.get ('next', reverse ('index')) #Rarton HTTP response redirect (reverse ('index')) submit the submission (request, login '.html Django ('next', '')}) .conf.urls Import Pat From the URL import url pattern = pattern ('', '', #ifification url url (r '^ login / $', views.login_user, import name) = 'Login_user'), Url (r '^ logout / $', views.logout, name = 'logout'), url (r '^ register / $', views.register_user, name = 'register_user&#

c# - Get Dates based on Current Date and List of Week Days -

I have something weird. I have a list of current date and weekdays. And I want all possible dates by the next date. i.e. For today, its 22-04-2014 and Tuesday. The target date is 15-05-2014 I have 2 week days, Monday and Thursday. The code should be found near the weekday, which will be on Thursday. Therefore, it should return the date of Thursday, 24-04-2014 . Now, the next turn is from Monday which comes from the list. So now, it should be returned to Monday date which is 28-04-2014 . It should be repeated until the target date. So, the end result is 24-04-2014, 28-04-2014, 1-05-2014, 5-05-2014, 8-05-2014 Please, help me get this type of results here, Monday and Thursday are not fixed. It can happen any day and any day. Update: For example the link working - You can try this code, I have tested it and working properly Private list & lt; DateTime & gt; Process Date (Date Time DTStartDate, DateTime Target) {DateTime DTLop = DTStartDate; // dtReq

c# - Difference between this two uses of MethodInvoker -

विधि इनकॉकर के दो प्रयोगों में क्या अंतर है: 1: < प्री> textbox1.Invoke (नया तरीकाविज्ञापन (बी)); 2: textbox1.Invoke ((MethodInvoker) प्रतिनिधि {b ();}); मैं केवल समझता हूं, कि अगर मुझे चाहिए तो वैरिएंट 2 मुझे मापदंडों के साथ b () कॉल करने की अनुमति देता है लेकिन इस 2 संस्करणों में अंतर क्या है? संस्करण 1 मेरे लिए स्पष्ट है: मैं एक नया प्रतिनिधि तैयार करता हूं और इसे मेरे बी () पद्धति को पास करता हूं, जिसमे समान वापसी-प्रकार और पैरामीटर हैं, जैसे कि विधिविवेशकर्ता प्रतिनिधि। एक प्रतिनिधि का मानक कैरेक्टर। लेकिन संस्करण 2 बिल्कुल क्या करता है? इसका मतलब क्या है / क्या "प्रतिनिधि" शब्द यहाँ है? वी 1 एक नया methodInvoker < कोड> ऑब्जेक्ट और यह आपके b विधि को पैरामीटर के रूप में पास करता है MethodInvoker फिर "बी के साथ करता है" क्लास में ही होता है। V2 में आप एक अनाम पद्धति बनाते हैं और इसे MethodInvoker पर डालते हैं और किसी भी "अतिरिक्त ऑब्जेक्ट" को instasciate नहीं है और आपके प्रतिनिधि को "सीधे" निष्पाद

java - hadoop in windows with cygwin noclassdefinition found error -

I am trying to install Haup in my windows 7 environment and run with Sigwin. I've been Saigvin download and install and I have configured SSH, I have set the Java class path inside Saigvin Kbasrak and set all Haup configuration files. My .bashrc file listed export JAVA_HOME = "C: \ \ Program Files \\ Java \\ jdk1.6.0_24" export HADOOP_HOME = / home / user / Thaup export HADOOP_MAPRED_HOME = / home HADOOP_COMMON_HOME / HADOOP_COMMON_HOME = / HOME / USER / HADOP EXPORT HADOOP_HDFS_HOME = / HOME / USER / THOVE EXPORT YARN_HOME = / HOME / USER / HADOP EXPORT HADOOP_CONF_DIR = / home / user / hasoop / etc / hasoop but I could not find the error when I run the Falling command error on the Sigwin terminal: $ ./hadoop version java.lang.NoClassDefFoundError: org / apache / hasoop / util / versionInfo by reason: java.lang.ClassNotFoundException: org.apache.hadoop.util.VersionInfo on Java.lang.la java. Java.security.AccessController.doPrivileged on net.URLClassLoader.fi

android - How to create Sliding tabs inside Fragment? -

I have created five tabs using fragment activity. Now I want to create three sliding tab layouts inside one of those pieces I am How can I achieve this? Please make a suggestion and the tutorial will be a great idea. thank you in advanced. & lt ;? Xml version = "1.0" encoding = "utf-8" & gt; & Lt; ScrollView xmlns: Android = "http://schemas.android.com/apk/res/android" Android: layout_width = "fill_parent" Android: layout_height = "fill_parent" & gt; & Lt; RelativeLayout Android: layout_width = "fill_parent" android: layout_height = "wrap_content" Android: background = "@ Android: color / white" Android: scrollbar = "vertical" & gt; Android: Android: Android: Android: Android: Android: Android: Android: Android "Android: Text Classes =" @Android: Color / Black "/> Android: layout_height = "wrap_content" android: layout_alignParentTop =

c++ - JNA Pointer to Pointer -

I am trying to use JNA at one point and execute with an indicator but I have trouble. I am able to use other functions in the classroom, although the arguments of this function are causing me trouble. My interface and Java work fine, and I can use other methods, though "execute_file" & amp; "Alenacexicute" is giving me trouble Is my law declaration closed? I am thinking that I want a string array instead of pointerfire? Below I included C ++ with execute_file. Thank you! The public interface extends the libcvm library {void alenkaInit (PointerByReference av); Int execute_file (int ac, pointerfreeference avi); Zero alenaclos (); Int Alenka Execute (Byte Buffer S); } Public static zero main (string [] args) {libcvm libcvm = (libcvm) Native.loadLibrary ("libcvm.so", libcvm.class); Pointerbearer reference pref = new pointer breather (); Libcvm.execute_file (2, prefix); Pointer P = pref.getValue (); } Int execute_file (int ac, char ** av) {bool jus

ios - sending sms and email simultaneously What about FB and Twitter? -

Is it possible to send text messages / images to multiple e-mails and SMS accounts by pressing a single button? I understand that emails and SMS messages are sent continuously in the background but I am trying to avoid the user from several view controllers. I have seen "iOS does not allow you to send e-mails or texts without user contact" but the user will be pressing a button saying that this email was sending messages in the list of addresses and SMS numbers. I have social framework and message UI I am reviewing content on framework and search forums, but I can not find the information I am receiving. Should any other framework use me? As an extension, can you send the same message to multiple messages such as Facebook and Twitter account for the same message? You can use FacebookSDK for Facebook and (for example ) FSHTwitterEngine for Twitter and create your own custom composer and sender. Both of these libraries have the source of GitHub, so that you can

Powershell script to see currently logged in users (domain and machine) + status (active, idle, away) -

I am looking for a simple command to see logged on users on the server I know this: But it will not provide me with the necessary information: Domain Maker Model Name (Machine Name) Primary Owner Name Total physical memory I run Powershell 3.0 on Windows Server 2012 Get-WMIObject Win32_LoggedOnUser -ComputerName $ Computer | Select pre-selection - Exclusive I do not want the exact answer that I need. I would also like to see inactive time, or if they are active or away. In this same solution in search, what was the need for me in a separate question in Stackhouse Flow: . Below will return a list of logins to one line users. query user / server: $ server

javascript - Passing configuration to a CommonJS module -

स्रोत कोड समस्या मेरे पास जावास्क्रिप्ट के साथ एक वास्तुकला है I मैंने एक कॉमनजेएस मॉड्यूल लिखा है, लेकिन यह एक आंतरिक कॉन्फ़िगरेशन ऑब्जेक्ट ( var config देखें) के लिए कसकर युग्मित है। मैं इस कॉन्फ़िगरेशन का सार करना चाहता हूं, ताकि मॉड्यूल अन्य वातावरण / परियोजनाओं में पुन: उपयोग किए जा सकें। पृष्ठभूमि मॉड्यूल एपीआई संचार के लिए प्रयोग किया जाता है, अर्थात् सिर्फ उपयोगकर्ता प्रमाणीकरण वर्तमान में। यह टोकन आधारित है, जिसके लिए मैं टोकन की समाप्ति का ट्रैक रखूंगा, जिससे कि सभी राज्य क्लाइंट-साइड हो सके। EventEmitter और AppDispatcher का कारण यह है क्योंकि यह फेसबुक द्वारा "फ्लक्स" आर्किटेक्चर पर आधारित है। - इस पर कोई भी निर्देश भयानक होगा मैंने निर्भरता इंजेक्शन पर विचार किया है, लेकिन मैं समझ नहीं पाया कि यह कैसे लागू होगा? एक बहुत सारे पुस्तकालयों ने विन्यास का प्रबंधन किया है लेकिन मैं इसे सरल रखना पसंद करता हूं: config / index.js var config = {facebook : {key: 'foo', secret: 'bar'}} {} ('./' + (process.env.NODE