Posts

Showing posts from January, 2011

templates - How to make C++ find templated function header when dependent-scoped inner classes are involved? -

I am trying to create a templated C ++ function which accepts it as its logic, An indicator for an inner square object Here is a small version of class structure similar to a specific link-list or tree class: template & lt; Typename T & gt; Structure Inner {T-Wall; Inner (TV): Well (V) {}}; Inner * PTR; Exterior (t-wall) {pt = new inner (val); }}; I have created a structure to exclude them from any access control problems and removed some extraordinary example variables. In the brain with the structure of that class, there are three functions, The first of which I do not want much: template & lt; Typename T & gt; Zero TestOper (Cust Outr & Lt; T & G & OBJ) {cout & lt; & Lt; Obj.ptr- & gt; Val & lt; & Lt; Endl; } Zero Test InnerIt (infected external ; inner p) {cout & lt; & Lt; P-> Val & lt; & Lt; Endl; } Template & lt; Typename T & gt; Zero test infra-implied (Constant Tyman's external ; inner *...

It is posible to store the information of a php include into Memcached? -

Is this correct to include a PHP information in a variable? I use sensible and loading 75% of my page, 15 ms, one of them: need_once 'smarty / smarty.class.php'; Can it save this information before it's already included in a memcatch? As stated in the comments, what you are searching here is an "opcode cache" - An extension of a PHP engine that stores the result of compiling a PHP file in memory, so that the compilation happens only once The default option is this day, with PHP 5.5+ Bundled, and for PHP 5.2+ However there are other options; Another word often used (though maybe these days maybe less often) is "PHP Accelerator".

sql server - Using group by for a SQL to filter with datetime -

I am trying to create a SQL but it is not working. I have a table that: Amount of Acess | Was the computer ace? | Whats date and time 11 Computers 1 2013-12-30 09:00:00 2 Computer 2 2013-12-30 10:00:00 30 Computer 2 2013-12-30 10: 11:00 17 Computer 3 2013-12-30 17:30:00 200 Computer 4 2013-12-30 07:00:00 150 Computer 1 2013-12-30 14:00:00 19 Computer 1 2013-12-30 06:00:00 What I have to do is the result, where it has been shown to me only this way: In each computer, maximum excise and how much time was there? Result of the OS above the OS will be like this: Amount of Acess | Was the computer ace? | Whats date and time 30 computer 2 2013-12-30 10:11:00 17 computer 3 2013-12-30 17:30:00 200 computer 4 2013-12-30 07: 00:00 150 Computer 1 2013-12-30 14:00:00 Computer 2 in the exact time had maximum 30 Aces 2013-12-30 10:00:00 ... ..... The problem is how can I show a great date in each result? Can anyone help? Thanks I think you want the date whose maximum nu...

Create a Generic List of Generic objects in C# -

I have a generic class for which I would like to create a general list, where the underlying classes apply the same interface However, all of the given interface is not implemented. Describing the problem would be an easy example. Intermediate Interface Isoming {} Internal Segment Type: ISOMTI {} Internal Square Theatings: Isoming {} Internal Class SomethingElse {} Internal Square Generic Tings & lt; T & gt; {} Internal range DoThings {void Main ()} {var thing1 = New GenericTeat; This lesson & gt; (); Var thing2 = new generic typing & lieutenant; That Typing & gt; (); Var Talk 3 = New Generic Ting & lt; SomethingElse & gt; (); ** var thingList = new list & lt; Generic typing & lt; ISomething & gt; & Gt; () {Thing1, thing2}; **} } I'm unable to create a list of things which is a way of putting two things that apply the same interface in the general collection, while The interface is not currently interrupted to protect the gen...

php - Append DOMDocument root element to another DOMDocument -

I have 2 "DOMDocument" objects - $ Original and $ Excess I want to get all the children from an additional docdocument $ And add $ end to the end of the original document. I had to take the original element of the $ extra document I tried to use: $ root = $ Extra-> Document element; $ Original- & gt; Append Child ($ root) But I get an error, which is expected of Ependon Child as a logon object. I tried to access every child in the document via: $ extra-> childNodes-> Item (0); But it gives the purpose of domelimity Can you advise how to obtain an object of a domonode class? What is the most convenient way to provide this import operation? The $ basic XML looks like this: & lt ;? Xml version = "1.0" encoding = "UTF-8" & gt; & Lt; Products & gt; & Lt; RecordReference & gt; 345,345 & lt; / RecordReference> & Lt; NotificationType & gt; 03 & lt; / NotificationType & gt; & Lt;...

java - How to call public static String method from jar from command-line? -

हमारे पास एक परियोजना है (जैसे, फ़ू ) जिसमें कुछ सार्वजनिक स्थिर है विधियां, उनमें से कुछ रिटर्न स्ट्रिंग अब, मुझे उस प्रोजेक्ट के जार से कमांड लाइन तक पहुँचने की जरूरत है और उस स्ट्रिंग के लिए उन सार्वजनिक स्थिर स्ट्रिंग तरीकों में से एक को कॉल करें। 1 संपादन करें: मुझे एक शेल स्क्रिप्ट के लिए एक तर्क के रूप में लौटा हुआ स्ट्रिंग देना होगा। ऐसा कुछ: ./ my_bash_script.sh & lt; मूल्य जार से लौटा & gt; & Lt; अधिक तर्क & gt; हम इसे कैसे करते हैं? कमांड लाइन से जार कॉल करने की कोशिश की, लेकिन उसने मदद नहीं की। java-cp Foo.jar full.package.name.ClassName त्रुटि: मुख्य वर्ग की जार को ढूंढ या लोड नहीं किया जा सका यह अपेक्षित था, क्योंकि वर्ग में कोई मुख्य फ़ंक्शन नहीं है। इसके अलावा Foo.jar के आस-पास एक आवरण जोड़ने का प्रयास किया। जैसे, इस जार को मेरे अन्य प्रोजेक्ट में निर्भरता के रूप में जोड़ा गया, और सार्वजनिक स्थिर स्ट्रिंग विधि से Foo.jar कहा जाता है। खैर, यह काम करता है, लेकिन मुझे जावा एप्लिकेशन के बाहर एक स्ट्रिंग वापस करना होगा ...

python - Get number of characters matched in regex -

I have a file indented with a place indentation: some text Level 1 level 2 Level1 Level3 and its text I want to indent it with 4 spaces. I thought of a regex to match the starting position ^ (\ s) * . However, I do not know how to change it with "Apply a tab for each place". My estimated output will be: Level 1 level 2 with \ t * len (\ 1) exists? Edit: I appreciate a Regex based solution because I want to use it from within the SibalTimetext Editor, where the replacement performance is done by regex. I do not think the Python regex engine supports this, but since you have used the subtitle text, you It can be used, which matches the situation immediately after the end of the last match. What to Search: (^ | \) \ s Replace with: \ t This pattern will match a single whitespace character, which or line back after immediately starting

r - Errors when using RStudio's Git tools -

Image
When trying to push GitHub from RStudio, I get the following errors I 'Rpostback-askpass' Fatal to askpass response Unable to read: Username for 'https://github.com' can not be read: no such device or address / pre> RStudio as mine The original is https://github.com/rmscriven/other.git when it should actually be https://github.com/rmscriven/saber.git RStudio me from version control system It will not be allowed to change here: Is it possible to change my sitename URL from RTDO? In the comments thanks to the Pro Tip provided by @ krlmlr, Use an empty target directory on your GitHub project page, look for "Clone URL", maybe choose SSH variant. I clicked "Clone URL" at a time, nothing. Again, nothing. And once again for the good measure, nothing. So I went to the terminal, read the man git help file, and decided to change and reconfigure my password. These are the lines I have run, and it's been successful. ...

java - New Activity from SherlockFragment -

When I click on to open a new activity and try to set up a program designed button to putExtra But the activity will not be so, even after the inauguration, it stays for 1 second and then accidents button code:. Blog .setOnClickListener (New View. OnClickListener) {Public Zero onClick (see v) {Log.e ("button", "clicked blog"); I = New meaning (getSherlockActivity (), Soundcloud.class); startActivity (i);}}); New class: Public class Soundcloud activity extends {@Override protected Zero onCreate (bundled savedInstanceState) {//this.requestWindowFeature(Window.FEATURE_NO_TITLE) ; Super.onCreate (savedInstanceState); //setRequestedOrientation (ActivityInfo.SCREEN_ORIENTATION_PORTRAIT); Logs. E ("activity", "in action"); SetContentView (R.layout.soundcloud); }} Layout: & lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; LinearLayout xmlns: android = "Http://schemaskandroidkcom/apk/res/androi...

opengl - Screen position unprojection without W -

मैं कैसे unproject की बुनियादी अवधारणा को समझता हूं: चलो mut z = 0.0; Gl :: ReadPixels (x के रूप में i32, i32 के रूप में y, 1, 1, gl :: DEPTH_COMPONENT, gl :: FLOAT, & amp; z); स्क्रीन स्थिति के लिए // खिड़की की स्थिति स्क्रीन_पोजीशन = स्फ़ी। टॉ_स्क्रीन_पोजीशन (एक्स, वाई) दें; // दुनिया की स्थिति के लिए स्क्रीन की स्थिति world_position = self.projection_matrix ()। Invert () * Vector4 :: new (screen_position.x, screen_position.y, z, 1.0); लेकिन यह डब्ल्यू समन्वय ठीक से नहीं लेता है - जब मैं विश्व अंतरिक्ष से स्क्रीन स्थान तक चीजों को प्रस्तुत करता हूं, तो वे W! = 1 के साथ समाप्त होते हैं, परिप्रेक्ष्य परिवर्तन की वजह से () जब मैं स्क्रीन स्थान से वापस विश्व अंतरिक्ष ( W = 1 की धारणा के साथ) में परिवर्तित करता हूं, तो वस्तु गलत स्थिति में होती है। जैसा कि मैंने इसे समझ लिया, डब्ल्यू अन्य सभी निर्देशांक के लिए एक स्केलिंग कारक है। यदि यह मामला है, तो इसका मतलब यह नहीं है कि स्क्रीन वैक्टर (0, 0, -1, 1) और (0, 0, -2, 2) का नक्शा होगा एक ही खिड़की के निर्देशांक के ...

nlp - How to extract information from these sentences -

I found a list of sentences given below: They are a few sentences drawn from job descriptions I want to remove such information: Degree type, major, required or preferred The following are the results: {Degree: Bachelor, Key: Computer Science, Required: Truth} Theres are not clear rules in these sentences. How can I achieve this goal? bachelor one ???? Pursuing computer science or equivalent BS Or advanced degree in computer science or related technical / engineering degree. Bachelor's degree in computer science or equivalent experience will give you the same technical degree with educated (BS / MS in computer science or other technical degree) computer science, BS in digital media or 3+ years of experience; Bachelor's degree computer science, design or Undergraduate degree in the relevant field, the ability to absorb emerging technologies, master and lever the BA / BS Education or Bachelor Degree in a related field, or four (4) years of experience in a directly r...

css - How to change the color of the caret in a dropdown? -

Image
इस सवाल का पहले से ही एक उत्तर है: 6 उत्तर क्या कोई बदलाव करने का कोई मौका है एक लटकती मेनू में कैरेट का रंग या & lt; select & gt; & lt; div & gt; & Lt; img src = "..." alt = "" शैली = "स्थिति: रिश्तेदार; शीर्ष: ... px; left: ... px;" / & Gt; & Lt; / div & gt; तीर पर सीधे डिवीज़ रखें।

famo.us - How to implement google paper button effects -

Google's paper / content design is a very clean look that I think is going to see a lot of uses . A group of polymers is - ???? Paper-elements ???? Ready to go and the web community is already playing different ways to implement it. I'm particularly looking at the button click effect for this question. There is a wave of activation color that is broadcast by your click. Here is a polymer example: Here is a CSS jquery example: My question is how to go about implementing it? Take a look at the polymer example You can masuad it in a second color instead of the color opacity waveform as a background color poly radiation. It holds when it reaches the IAC limit and then it fade quickly on the mouseup. Because I could easily see the code behind the second example because I applied it in the same way as it was, but with the exception of using touch instead of clicking on the click, because I wanted to That's what I did to get the effect, but not touching it. I tried s...

ios - Outlet collections, i want to access the properties(hidden) for my UIimageview -

I can only access the ID of my outlet store and the ID does not have hidden assets This is my outlet collection @property (strong, non-creative) IBOutletCollection (UIImageView) NSArray * heart; And this happens when I try to call it, and change it to hide it. [self.hearts objectAtIndex: 0] .hidden = YES; I can not because objectAtIndex only returns an ID Thanks for any help You can try to enumerate objects in the archive, the way you expect (e.g., heartView in self.hearts ) ) or the first cast ObjectAtIndex: 0 and then set the hidden property.

java - UUID not working with JOOQ and PostgreSQL -

Whenever I try to set or retrieve the area of ​​UUID type, I get the following error from JOOQ: "Not supported by the bid: type class java.util.UUID is not supported in the bid null" Everything else works great and as far as I can tell the bids that properly set on postgres What is happening on any idea? You are using jOOQ 2.6.4. java.util.UUID types are only supported by jOOQ 3.0: But when If you are on it, you would want to upgrade to the very latest version (which is 3.4.1, when I answered it)

Is it possible to recursively flush directories in the CQ5/AEM apache dispatcher? -

Due to a special project in a multi-rented situation, I have a large number of dispatches set with deep data file levels. I am hoping that more disturbing figures for other tenants is a way to be able to flush the directories to duplicate the file level. Is there a sender flush command that allows me to explicitly delete a directory of contents? You can get it by sending a simple GET request to yourself. The dispatch you need to hit is the path /dispatcher/invalidate.cache . The following headers make sure that it is processed correctly: CQ-Action: Delete "can be set on. I think "EXPIRE" also works to flag content as out-of-date, but it is not physically removed from the cache. CQ-Handle: It specifies what should be deleted, starting with the root of your cache folder such as "/ content / geometry", under geometry and everything Will be removed. "/" Will remove everything in the cache. Content-Length & amp; Content-Type...

php - Sending empty arrays to the server using jQuery post or similar Asynchronous JavaScript request -

इस सवाल का पहले से ही एक उत्तर है: 2 जवाब दिये गये $ पोस्ट ( 'dealWithStuff.php', { 'fullArray' [ 'हैलो', 'goodby'], 'emptyArray': []})। dealWithStuff.php प्राप्त ['fullArray' = & gt; ['हैलो', 'गुडबाय']] लेकिन ['fullArray' = & gt; ['हैलो', 'गुडबाय'], 'खालीअरेरे' = & gt; []] मैं सर्वर पर खाली ऐरे को कैसे भेजूं? मैं इसे एक दरार दे दूँगा। / P> हम शुरू करने से पहले, आप खाली सरणी नहीं भेज सकते क्योंकि यह कुछ ऐसा दिखता है: file.php? Arra [] । आपको भेजने पर यह करने की आवश्यकता होगी: $। Post ('dealWithStuff.php', {'fullArray': ['हैलो', 'गुडबाय' ], 'emptyArray' [ '']}); [] के बजाय emptyArray [''] कैसे ध्यान दें ? यह आपको एक प्रतिक्रिया देगी जो इस तरह दिखता है: Array ([fullArray] = & gt; Array ([0] = & gt; हैलो [1] = & gt; गुडबाय) [खालीअरे] = & Gt; ऐरे ([0...

sql - update column with condition from another column -

I am trying to update a column based on condition from the second column. Something like this, & gt; Apparel App | SPV ID | SPV App | Test | | Test | | | | | Expected: Apparel App | SPV ID | SPV App Approved. | Test | Approved. | Test | Approved. | | Approved Approved. | | Therefore, column 2 is not zero, update column 1, if column 2 is zero, then update column 1 and column 3. Here is my code: [APV AD] = When the [SPV ID] is tap, then 'Approved' (Aether app) = 'Approved', [Attar Date] = @Adit, [SPV App] Finally, where [Wear app] is zero " On the scene I did not add another column called [Dress Date], assuming that in the scene That column is but it does not work, it's just Column Update 1 ... Do you have any suggestions about this problem? Thanks in advance. I can not follow your code because it uses separate column names from the description. However, the argument you want It is: Update your table set col1 = @ COL1...

sql - Using two mdbs to Select Into a third -

I have issues creating this SQL string in VB6 select AID .aSTTp, In [AL:] [AL:]: [OFF] of [ALB] in [ALC] at [ALC] in [at: c: \ temporary \ ALPA.mdb] ACT = "Sealed"] LnReg is for MDB with my ADO connection Error thrown '[c: \ Temp \ ALPA.mdb]' is not a valid name. [edit] From the syntax error segment [ALPA] in FROM "AID, ASTP, A Aostate, AAG, BLNO, BACNT, B in [ALPA] in C Select .comcontent: \ Temp \ ALPA.mdb "As A left OUTER JOIN [ALX] IN" c: \ Temp \ ALX.mdb "A, AID = BID where AAST =" sealed " / Code> I prefer to add the table to the main MDB file from other MDB files. I use this function to add tables. With the connected table you can do something similar with the local table. AccessLinkToTable (as the sLinkFromDB string, as the sLinkToDB string, as the sLinkToTable string, as the optional sNewLinkTableName string, as an alternative sPassword string) as the Boolean ' Input: path of the original database of sL...

Can one change/influence JAXB's code generation? -

I was wondering if a JAXB XML schema (.xsd) could affect the "style" of code generated from fles is. Like I would like to: Emits a comment within the newly generated sections, especially if the class is empty because it creates warnings in my environment. Change all the setter-methods to return the object instead of "zero" so that one can do the call-chaining: X some method () {Return new X (). SetFoo (5) .setBar ("Some"); } Instead of tireless: X some method () {xx = new (x); X.setFoo (5); X.setBar ("something"); Return x; } Is there a few "templates" anywhere that uses JAXB and who can make more changes to achieve such things? Or is it all that hard-coded? M. There is no template to modify generated code easily. However, for example many plugins: that you want according to your 2 bullets. There are other plugins, e.g. For comments suppressing warnings - which can help against bullets first. As an add...

java - This application does not exist - GAE -

This application is live I had used this project for PHP first, now I am experimenting with Java and I can not get the project to upload The following is an error message: com.google.appengine.tools.admin.HttpIoException: Error posting URL: 404 Not found This application does not exist (app_id = u'laraveltest2014 '). I tried to add the parameter below and it had no effect. - no_cookies If you already log in to a different Google account , Then try removing these two files from the Home directory: .appcfg_oauth2_tokens_java .appcfg_cookies

To where does the library functions in c return the value? -

Eventually the library function will return a value. Who takes this return value? For example, consider the code below. # include & lt; Stdio.h & gt; The main () {printf ("Waiting for the character being pressed with the keyboard to exit. \ N"); Getch (); Return 0; } getch () gives a value Who casts this value? Answer me in general knowledge, not specific to the above program. The return value of a function can be removed. In the example you provided, you would not know that there is actually a return value of printf the function call Expression description , only the side effect is being followed, the return value is abandoned. Another example of the expression statement is: 21 + 21; Expression 21 + 21 has been evaluated and omitted. C allows this syntax, even though a compiler has optimized it.

Grails Spring Security UI Plugin - Does It Support Groups? -

I'm ready to implement the Spring Protection UI plugin (we have already implemented the Spring Protection Core plugin) . I know that the main plugin is support for users, roles and groups, however, I do not see any mention of groups in documents in Spring Protection UI plugin. Does the Spring Protection UI do not support the build, version, etc. groups? Anyone tries to add this functionality? Late response, but I had only one question, so I thought that I look at the tax. I have just tried this myself and I believe that this answer is not (out of the box) The spring security UI does not take into account the plugin group. If you try to edit a user, myapp / user / edit / 1 you will get some type of error such as: class groovy.lang.MissingPropertyException Message is not such a property: Authorization for Class: com.myapp.security.SecGroup Possible Solution: Authorization Have you found a way so I'm curious around this? Or we have to customize the plugin....

Blocking and Non-Blocking Assignments Verilog -

I always have code in block block (code 1) and non-blocking (code 2) assignments. But why is the output different in both cases? I know the queue for the event, but I probably can not understand that the "Always @ (CLK)" description will be placed in the queue. Code 1 module OSS 2 (CLK, D); Output Clock; Reg clk; Input D; Initial start # 10 clerk = 0; $ Monitor ("% d% b", $ time, clk); Initial $ 100 end; Always @ (CLK) # 10 CLK = ~ CLK; Endmodule // Code generation 1 10 0 20 1 // Code 2 module OSS 2 (CLK, D); Output Clock; Reg clk; Input D; Initial start # 10 clerk = 0; $ Monitor ("% d% b", $ time, clk); Initial $ 100 end; Always @ (CLK) # 10 CLK & LT; = ~ Clk; Production of Endmodule / Code 2 2 10 0 20 1 30 0 (becomes 90) 90 0 For clarification purposes, I first resolved the contents of the two loops and opened the extended components for the break down. The code below will simulate. always @ (clk) # 10 clk = ~ clk; Initially...

windows - What is the meaning of thread count in process (wmic) -

When I'm running wmic query through the command line, I have a line with THREADCOUNT I'm not aware of the value I do not know about the meaning of threadcount . I'm running this wmic query: get wmic process (where captions like '% Explorer%') * / get the format : List Output of the above queries: caption = explorer.exe exists in the partition = C: \ Windows \ Explorer. Exe CreationClassName = Win32_Process CreationDate = 20140725092933.908032 + 330 CSCreationClassName = Win32_ComputerSystem CSName = DIGITALFOX Description = explorer.exe ExecutablePath = C: \ Windows \ Explorer.EXE ExecutionState = Handle = 1820 Handlankt = 856 InstallDate = KernelModeTime = 50388323 MaxverWorkSetSize = 1380ConstructuringSetset = 200Name = explorer.exe OSCreationClassName = Win32_OperatingSystem OSName = Microsoft Windows 7 Ultimate | C: \ Windows \ Device \ Harddisk0 \ Partition2OtherOperationCount = 90378 Anytronsfrkount = 20893 00 PageFaults = 63,847 PageF...

c# - Implement smart search / Fuzzy string comparison -

I have a web page on the ASP.NET MVC application, where customers search for suppliers. Suppliers take their own details on the website. The client wants the "smart search" feature, where they can search for suppliers and search them, even if the supplier spelling is "slightly different" of things written in the search box. I do not know the perception of a customer is "slightly different" I have been looking at implementing a custom soundx algorithm. It changes a word into a number, which it comes to sound. That number is used for comparison. For example: Zach jack will encode for the same value Can I possibly see other options? You can use a 'tag' field combined with 'smart search' style functionality For your database at the supplier. This is very basic, but works well for cases like 'Jake / Zach'. Adding Tags to Your Database You can search for the situation where people are familiar with them or other c...

python - django formsets can_delete header -

Image
I'm new to the deegago, please stand with me .. generated a template It all works well, except I am unable to provide the header in the can_delete column. My Django looks.py looks like this: def add_exchange (request): reference = requestContacts (request) ExpFormSet = Modelformset_factory (expense, excess = 1, max_num = 10, fields = ('exp_date', 'description', 'amount'), can_delete = true) if request.method == 'POST': formset = exp.conf (request.POST ) If formset.sis_valid (): Formset.save (commit = true) formset = expformet () Other: print "Errors are formset", formset.errors else: formset = expformet (queryset = expenditure.objects.none ()) The form of the temple code is given below: id = "expense_form" method = "post" action, return render_to_response ('moni') = "/ Moni / ad_expect / "& gt; {% Csrf_token%} & lt; Table range = 10> & lt; tr & gt; & lt; th ...

jquery file upload with blueimp fails when file selected in multiple iterations -

I am using the blueimp file upload file upload feature is working for me when I have more than one file I mean, when I select multiple files from a single folder and upload them, it works fine, all my files are uploaded. But the problem is when I select multiple files in many iterations, i.e. single file in the first trip, again single file in double iterations and so on. So in this case only the previous file that I have selected has been uploaded. File uploads, forgets the first selected file. I tried with sequential uploads = true . But it does not help. Do you have any idea how to upload multiple files selected in different iterations? S Nesario's Maintainer El Campo Named Modo array wai ocean "multiple" & lt; Input type = "file" name = "foto []" id = "fileFoto" multiple & gt;

java - Apache Thrift: Server with sync and async methods, it is possible? -

I am trying to implement a Twitter like service with the customer using Java. I am using Apache Savings for RPC calls. I service uses a key-value store. I am trying to make service defective with stability and data-replication in key-value stores. For example: To assume at one time, there are 10 servers running with ID S1, S2, S3 etc and a client call (key, value) on S1 Now S1 saves this value and puts RPC for data-replication on all remaining servers (key, value). I want to start a thread with the async calls to save the server method and return customer success and on the remaining 9 servers so that the customer is not blocked during the replication. The auto-generated code is escaped as an encrypted and I currently have a server in the driver class I My target is to expose a backend server in the client and the client and server and Make normal (blocked) calls between the server async calls. I understand the data replication model is raw, but I am trying to learn distribu...

plone - non required SelectFieldWidget -

I have an expertise content type and I have to put a selected field that is not necessary and which value is a term This is the glossary. Pre- @ grok.provider (IContextSourceBinder) Def voc_test (reference): value = range (10, 21) conditions = map (Lambda X: simple trim (value = str (x), title = str (X)), values ​​back to simple terminology (word) and the definition of this area: import dexterity from plone.directives, zope Import schema class from plony.namefile.field from IMyType (form.Schema) form from NamedImage: ... form.widget ('test', selectFieldWidget) test = schema list (title = _ (U "test"), value_type = Schema The option (source = glossary. Voc_test), description = _ (u "desc_test"), required = false,) What I find is a select field with my values ​​and terminology The value is 'no value' before it is okay. But when I save an error message selected and the 'no value' hit amount is shown: Traceback (Last Last): m...

bigdata - Hadoop two node cluster environment, NameNode’s web UI displays the number of live nodes as one and Dead nodes as zero -

I have correctly configured two node cluster environments for the head, and also the master is also configured for data. So, I currently have two data nodes, without any issues, I am able to start all the services in the master. Slave detonodes may stop starting from the master node. But when I type the URL http: // live node counting, I'm not seeing only one two. Master Process: ~ / hadoop-1.2.0 $ jps 9112 Task Tracker 8805 Secondary Nomen 929 GPS 8579 Detanode 8887 JobTracker 8358 NameNode Slave process: ~ / hadoop-1.2.0 $ jps 18130 data node 18380 jps18319 tasktracker Please let me know this Help me in what I am doing. The second datanode is running but is not connected to NameNode is likely that you can reformat NameNode again And now there are different version numbers in NameNode and DataNode. Manually delete a directory, where Datanet keeps its data (dfs.datanode.data.dir) and then reformats NameNode. Editing a version is very low manually, but fo...

javascript - How to hide error message in angularjs http request? -

I have received a request from API, in some time I will get EXIF ​​information, but sometimes I get an error Message will be found {"error": "no exif data"} How can I hide this error message in Chrome, error 400 is (bad request) $ Http.get (res.getQNUrl (domain, key, "exif"). Feature (function (data) {$ scope error (function (data, position, header, config) {}) The error message you specified is browser-specific. This is a browser logging functionality. Well, a workaround for this (there is no problem because it does not resolve I do not recommend it because it has the functionality of a built-in browser that you are trying to suppress by working to do this, but if you want it to be the same, Here are some ways to make a conclusion. Using a regular expression filter like ^ (?! * 404 \ (not found \)) (?!. * [File name]) I have not understood this much because already there is a question that tells it in detail. Detailed expl...

ruby - Unexpected keyword_end error, yet syntax seems fine -

This function is used to retrieve the name of a value file comma-separated and treated them in an array. def xprt_csv_to_ary (csv_file) namecatcher_regex = "/^[\.{1}]([AZ]+)\.{3}/" # next name current_word = 0 names_array first = Match up to four [] while current_word & lt; 5000 If current_word == 0 Name = csv_file.readline.match (namecatched_regex) and name = csv_file.past_match.match (namecatcher_regex) names_array end [current_word] = name current_word ++ finally return names_array I am getting the following error: syntax error, unexpected keyword_end I would like to be sent to solve a current question As my happiness will be answered to someone directly to answer me Your error line Comes from. current_word ++ Ruby should be no such syntax: current_word + = 1 what's more, you should be your regexp make incorrectly: namecatcher_regex = /^[\.{1}]([AZ ] +) \. {3} / There may be some other errors that I did not pay attention to ...

php - how to determine if selected date and time is within the range of the duration -

How to check the date and time of my chosen date (this is the minute)? This is my code: function check-time () {$ time = $ this- & gt; Input-> Post ("time" is true); $ This- & gt; Db- & gt; Select ("time, duration"); $ This- & gt; Db- & gt; ("Timetable"); $ Query = $ this- & gt; Db- & gt; get receive (); $ Message = array (); $ Time converted = stratetime ($ time); Foreach ($ query- & gt; result () as the $ line) {if ($ timeConverted == $ row- & gt; time) {$ message = array ("message" => Please enter another date Select more time "); } Other {$ message = array ("message" => "available"); }} $ This-> Output-> Set_output (json_encode ($ message)); } In that argument, I'm just checking whether the selected time and date is equal to the values ​​in my database. I want to add a period thank you in advance. I believe you are looking for something like thi...

c# - Togglebutton content change in image in WPF -

Image
मेरे पास wpf में कोड है जो ToggleButton का उपयोग करता है। & LT; ग्रिड & gt; & LT; ToggleButton एक्स: नाम = "pinButton" VerticalAlignment = "केन्द्र" चौड़ाई = "ऑटो" MaxWidth = "26" ऊंचाई = "26" पृष्ठभूमि = "{DynamicResource MyBorderBlueGradientBrush}" फ़ोकस करने योग्य = "false" DockPanel.Dock = "सही" BorderThickness = "0" OverridesDefaultStyle = "false" BorderBrush = "{DynamicResource MyBorderBlueGradientBrush}" FontFamily = "Webdings" & gt; & LT; लेबल एक्स: नाम = "Pinback" पृष्ठभूमि = "{DynamicResource MyBorderBlueGradientBrush}" चौड़ाई = "26" ऊंचाई = "26" BorderBrush = "{DynamicResource MyBorderBlueGradientBrush}" & gt; & LT; लेबल एक्स: नाम = "पिन" FONTSIZE = "18" अग्रभूमि = "व्हाइट" सामग्री = "मैं ??« "चौड़ाई =" 25 "ऊंचाई =" 2...

ibm mobilefirst - Running Worklight Deployment Server with fixed IP to Generate War/Wlapp/.adapter files? -

I have to host things with my project and host my wklight application based on Woklight 6.1 to employ things on Websphere server I am spending time for it. 0. Despite reading the following question, I have a question now. The webserver server on which I deploy my .war, .wlapp and .adapter files is a remote server and is not coming under my company's domain. I do not have access to clients by IP address and port, so to deploy my backup plan, to copy a laptop to access the file network, copy and use the window server IP's RDP is deployed My problems are: As Vernal behaves, while I run - & gt; Running on the warklelight development server overwrites this file properties like worklight.properties, .plist and index.html with its local IP address details. When I do, run - -> Create and target settings I create the application to work with different virtual server and fill out the details of the server: http: //182.19.xx.x0:9xx0 and the reference path: / con...

cq5 - Export XML component from CRXDE Lite -

In our source code, we have something to represent the structure of our communication components We design the project through Maven for our local CQ server for development and testing. Many times we need to modify the communication component through CLXDI Lite (in CQ server) because it is very fast to edit that dialog. The problem is this: How do I export the edited dialog component back to its respective dialog xml file? CRXDI LITE does not only provide export-to-XML functionality, but you do not have your dialog Xml can get in some different way. Let's say you want to get the dialog for the / libs / foundation / components / text component: 1 sling great servlet - Quick & amp; 2. VLT - Recommended method Use the VLT tool, which is a standard way of synchronizing between JCR and local file systems: vlt export http: // localhost: 4502 / crx / libs / foundation / components / text my-export # cat my-export / jcr_root / libs / foundation / componen...

python - How to force every line to have the same # of tabs as the maximum length line -

I have a tab-delimited text, and I want to make tabs like the same number in each row have tab of the big number. For example, a \ tB \ tC \ tD \ tF \ tG \ t Input file: Will be a \ tB \ tC \ tD e \ t \ t \ tF \ tG \ t \ t I'm trying this is. to import the Ayatr izip_longest import codecs inputf = sys.argv [1] outputf = sys.argv [2] as the F-open (inputf): data = izip_longest (* (* X.split ('\ t') for the line (* data) f), fillvalue = '\ t'): print line, offline = codecs.open (outputf, "w") But there is nothing in the output, although it prints things in the command window. I hope this program does not print in these command windows (it seems that takes a lot of time) and I hope the output file has the right output . Try using the CSV module, like this #! / Usr / bin / env pyt import CSV Hein import System import Ijit_long def Reed_aro (Inputfail) with open (Inputfail, 'RB') H: reader = CSV. Reader (H, quote = ...

c# - How to avoid entering values in tables that are just information tables asp.net mvc -

I have a model client: public class client {public int client id {get; Set; } [Required] public string compte {get; Set; } Public int Restr_typeID {get; Set; } Public Virtual Restr_type1 Restr_type {get; Set; } and Restr_type is also a model: public int Restr_type1ID {get; Set; } Public string restr1_name {get; Set; } Receive public integral {attief}; Set; } Received Public Virtual Actifs Actifs; Set; } My problem occurs when I add an instance of the client in the Customer table, it also adds a line in the Restr_types table and the Actifs table, but it has only two tablets in the information tables. And so I want them to be stable. What do I need to do is stock up only one customer Can you help me? Thank you for your help! If you have EF works as an attachment object as a virtual property. Actually if you create a new event of Client and populate the Restr_type property with a reference that you get from EF If it does, it will treat it as a new value of ...

php - get date form DateTime object -

How can I get the date to date in a variable? The date does not even need to be formatted - Ymd because it will be sufficient datetime object ([date] => 2014-07-24 10:14 : 31 [timezone_type] => 3 [timezone] => Europe / Berlin) A similar question was seen, but there was no effect in the answer, so a new question Decided to make. thank you in advanced. Let's see: per $ echo $ your_date - & Gt; Format ('YMD H: I: S');

asp.net mvc - Creating a custom RouteBase in MVC 5 -

मैंने एक कस्टम रूट MyCustomRoute को RouteBase से प्राप्त किया है मैंने ओरेरराइड किया है GetRoutData और विधि तब तक लागू की जाती है जब तक मैं / XY जैसे URL का उपयोग करता हूं हालांकि जब मैं /XY.htm या /XY.pdf जैसा कोई URL कॉल करता हूं, तब विधि लागू नहीं की जाती है मुझे कहीं भी अनुमान है कि मुझे अपने ऐप को निर्देश देना होगा जो "फाइलें" की आवश्यकता है सार्वजनिक स्थैतिक शून्य रजिस्टर रौटेंस (रूट कलेक्शन मार्ग) {routes.Add (नया) MyCustomRoute ()); Routes.MapRoute (नाम: "डिफ़ॉल्ट", url: "{नियंत्रक} / {action} / {id}", डिफ़ॉल्ट: नया {नियंत्रक = "होम", एक्शन = "इंडेक्स", आईडी = UrlParameter.Optional}); } मुझे ऐसा करने की क्या ज़रूरत है कि "फ़ाइलें" मेरे रूट से भी संसाधित हो सकती हैं? ठीक है, सामान्य रूप से, डिफ़ॉल्ट रूप से रूटिंग सिस्टम एक फ़ाइल एक्सटेंशन के अनुरोध को अनदेखा कर देगा जिसे मैप नहीं किया गया है और फिर IIS स्थिर फ़ाइल हैंडलर पर ले जाएगा। क्या होता है कि / XY को मैप किया जाता है और आपके द्...

How to initiate a Listener which can accept two events in Jquery? -

यह मेरा HTML है & lt; div id = "69" class = "activateUiHTML "डेटा-रोल =" खुलने योग्य "& gt; & Lt; div class = "prd-items-detials" & gt; & LT; ul & gt; & Lt; li वर्ग = "सिर" & gt; & LT; प्रपत्र & gt; & Lt; इनपुट प्रकार = "चेकबॉक्स" वर्ग = "चेक बॉक्स" नाम = "चेकबॉक्स-मिनी-0" आईडी = "69" डेटा-मिनी = "सही" id_attr = "69" & gt; लेबल आइटम _id_itr_some = "69" वर्ग = "चेकबॉक्स-मिनी-0" & gt; कोल्ड टी, ताज़ा चाय सोने की बर्फ & lt; / लेबल & gt; & lt; i वर्ग = "हटाएं-आइटम-बीटीएन" & gt; & lt; / i & gt; के लिए = "testtt" & Lt; / प्रपत्र & gt; & Lt; / li & gt; & Lt; / ul & gt; & Lt; / div & gt; & Lt; div शैली = "प्रदर्शन: कोई नहीं;" वर्ग = "टॉपिंग-विवरण" आईडी = "69" & gt; & Lt; / div & gt; &...

List type conversion python -

I have a dataset that PDB debugger tells me that it looks like this; set1: [(4.4,), (4.8,), (4.2,), (4.0,), (4.2,), (4.8,), (2.0,), (2.4 ,), (3.0,)] I need to be in the format given below; set2: [4.4, 4.8, 4.2, 4.0, 4.2, 4.8, 2.0, 2.4, 3.0] what type or type of type, 1 And 2 are set and how you are inserted, or else set 1 in Set 2. I am new to python and it needs to do this in a crowd, so I should not have any time now to know in detail - now any help will be greatly appreciated. Thank you! Set1 = [(4.4,), (4.8,), (4.2,), try: set1 is an element of the tuepals, map the result of applying the function passed as a first In this reply, for the collection passed to the Ramter as the second parameter, that function is the one that gives the first element of the tuple. To do this, use the understanding of a more Python way list: set2 = [X [1] set in X1]

SQL-query order by multiple columns having null values -

I found a table like this (note: there are more columns in the real table): alley | Zip ----------- 'b' | 0 'A' 0 'c' | Null 'f' | 1 null | 0 null | Null I would like to do a query like this: SELECT * from place ORDER by road, zip The result of this query is: road | ZIP ----------- 'a' | 0 'b' | 0 'c' | Null 'f' | 1 null | 0 Now the question is how should this output be produced (this is possible?): alley | ZIP - ---------- 'a' | 0 'b' | 0 'c' | Null null | 0 'f' | 1 null | Null If the value is zero of one column, it should be ignored / interpreted as a wildcard. I am using PostgreSQL 9.2. Thank you for your help. No, it does not seem possible that you can not create a copyable rule for that. Your first example will also be valid if you behave as a wild card in futile behavior. Road | ZIP --- -------- 'A' | 0 'b' | 0 'C' | Empty ta...

android - Google Play Game Services Multiplayed and Cheating -

I'm thinking of using Play Game Services with turn-based multiplayer to power Android games . I have concerns about fraud. Neither real-time nor turn-based game requires backend server with game logic (except Google server) I do not trust the client and I It is feared that if they do not go back to the backend server then the data may be bad. How can fraud be prevented through the Google Play Games service? You can use your backend server for multiplayer.

excel - Getting runtime error 1004 when having copy/paste function -

I'm trying to compile this. What is the correct way to copy the cell and paste another sheet? sub copy () integer dim as integer dim row like integer dim copy string as negative nirov as integer dim wrksht as integer wrksht = 3 newrow = 1 col = 23 for 1 phase-1 worksheets (3) .cel (33, cola) .copy worksheets (17). Game (line, 1). Paste Specific Changes: = For Stacks = 31 to 1 Step-1 If Worksheets (3) .mail (line, color). Value = "x" then worksheets (17) .seel (new, 2). Value = worksheet (12). Row, 25). Value new = = new + 1 end if next line next call closing sub In your line: worksheet (17). Game (line, 1). Paste Specific Transjections: True Truth You are trying to refer to a cell using the variable line before giving it a value. It's possible that your error is happening.

regex - Dart says Regexp has invalid quantifier, but it works in JavaScript - a bug? -

itemprop = "text"> I have a regular expression: color: \ s * + ((?! ?: Transparent | inherits) (:;?? $)) [^ @;] [^;] *;? is apparently working on regex1010.com But if you take the dart to the expression, for example, if you paste this code: void main () {newRegExp (r) "Color: \s * + (?! (?: Transparent | inheritor) (?:; | $)) [^ @] [^;] *;? " ); } We are in: InternalError: neither came exception: FormatException: invalid regular expression pattern: color: \ s * + ((?:? ! inherit transparent |) (:;? | $)) [^ @;] [^;] * ;, syntax error: invalid quantifier $.wrapException@blob: 98,037,409-a6ed-4af3-b17a-97b022530853: 218: 5 $ ?. ThrowExpression @ blob: 98037409-a6ed-4af3-b17a-97b022530853: 223: 3 $ JSSCXTXMMnetWeb: 98037409-A6D-4AF3-B17A-97B022530853: 411: 3 $. Jesssianaksaksakspi $ 9 BLOB: 9803740 9-A6 D-4 F-3-B-17A -97b022530853: 399: 3 $.main@blob: 98,037,409-a6ed-4af3-b17a-97b022530853: 148: 3 @blob: 98,037,409-a6ed- 4af3-b17a-97b022530853:...

cocos2d iphone - SpriteBuilder blurs imported images -

Image
I am learning some animation using spritebuilder, but it is blurred (or antialysing, i do not know) images i ' I'm importing and using On the left you can see the phantom producer image, png in the image viewer on the right. to prevent this Any thoughts about? I've changed _sprite.texture. Not antialiased but the result is the same left texture. Random = No, the correct texture. Random = Yes (default) I used the code: @implementation MainScene {CCSprite * _sprite1; CCSprite * _sprite2; } - (zero) didLoadFromCCB {_karel1.texture.antialiased = No; // NSLog (@ "hi"); Self.userInteractionEnabled = Yes; } You must set filtering mode to filter the nearest (point) filter. This cctacture properties in Cocos2d are named incorrectly (or at least unusually). This is the default for Yes, so set it to enable close / point filtering for texture. For example: the PlayerSprite.texture.antialiased = NO; It can not be done in SpriteBuilder, you have to prog...

Titanium JS: Error using Alloy data binding: 'undefined' is not an object (evaluating '__alloyId60.on') -

I have created a new controller ( search.js ) in titanium alloy, within which I I have referenced one of my collections: search.js var searchResults = Alloy Collections.searchResults; and then in my view ( search.xml ) I have created a tableview, and added the data collection feature: search.xml & gt; Table View ID = "ResultsTable" Datacallication = "Search Results" & gt; & Lt; Tableview title = "{name}" /> & Lt; / Tableview & gt; In my controller, this archive is populated with data through an online API, when a user performs a search in this code, results all A JSON object with the data is: search.js _ Each (results, functions) {var bier = alloy.createModel ('searchResults', item); searchResults.push (beer);}); When I run my app, I get the following error message: "'undefined' is not an object (evaluation '__alloyId60.on ') " I do not know where I...

jsf - Why do I need to use getter for a public attribute? -

In my table, I just want to get one attribute, why do I have to write a gator in my data object? I am declaring a variable 'O' (this is my data object) and I want to get public value 'commission'. It does not work without a clogging method. view.xhtml: & lt; H: DataTable value = "# {ABList.unreadedABs}" var = "o" style class = "ABList-table" headerClass = "ABList-table-header" rowClasses = "ABList-table-weird-line, ABList-table- Even-row "& gt; & Lt; H: column & gt; & Lt; F: aspect names = "header" & gt; Commission & lt; / F: Aspect & gt; # {O.commission} & lt; / H: column & gt; DataObact: public class AB {public string commissions; } refers to the recipient from that code The property is due to the default EL resolver, which is implemented in such a way. You can write your own EL RESOLTOR which directly resolves public properties. See the quest...

Mysql update query with IF statement -

I'm learning to use mysql so I actually created a simple project manager program. I wanted to know if a user saw it in a project. So I want to update the user_seen_task registered by the user when a project asks the user, but obviously I just want to update this field if it is not already set. This is what I have my views have already: function SET user_seen_task = 1, user_seen_task_date = now () WHERE project_id = 14 and User = 4 and user_seen_job! Update = 1 Unfortunately this query updates user_seen_task_date every time it runs. Any help is greatly appreciated. update tasks set user_seen_task = 1, user_seen_task_date = case when user_seen_task_date is zero now ( ) And end user_seen_task_date where PROJECT_ID = 14 and user = 4 and user_seen_job! = 1 or if it does not need to update user_seen_task in this case, just enter your in your and add user_seen_task_date work Stiu user_seen_task = 1 update, user_seen_task_date = NOW () WHERE project Ect_id =...

java - Why am i getting NoSuchElementException error in my class -

I have this class, which in the north should open the file with a question in response to NR. The problem occurs when I get to write in ArrayList, I've tried all types of Arrayists, Linkedists, Even Vectors. Answers to the first part of the file, such as questions and answers, it takes no problem. But when I want to store those answers in a list, I can save that list in an object. It will not work. If someone can help with this or knows a better way then an unknown NR string in an object list will be epic. The file format is: A question, 3, yes, no, maybe another question, 4, yes, maybe, no, why not my class: public square GetSurvey {intrebare public static string; Static en raspasauri; Public static int i = 1; Fixed string holder; // static string [] rasp = new string [250]; Fixed list & lt; String & gt; Rasp = new linked list & lt; String & gt; (); Public stable SurveyClass [] obj = new SurveyClass [250]; Public static zero loadserve () {file file...

clojure - lein repl fails: "No such var user/help" -

मुझे निम्न त्रुटि का अनुभव है: CompilerException java.lang.RuntimeException: ऐसा कोई var नहीं है : उपयोगकर्ता / सहायता, संकलन: (/ निजी / var / फ़ोल्डर्स / xy / 8l2mmnsj0gv3myj72y0s2kmr0000gn / T / form-init6632573911186472967.clj: 1: 10884) # & lt; नेमस्पेस उपयोगकर्ता & gt; नामस्थान लोड करने में त्रुटि; उपयोगकर्ता में वापस गिरना यह केवल एक ही परियोजना में होता है परियोजना खुशी से uberjar के लिए तैयार है, और लीन रन काम करता है ठीक है, यह केवल repl कि काम नहीं करता है। किसी के पास यह पता है कि यह क्या हो सकता है? मैं इस सवाल पर ठोकर खाई क्योंकि मुझे वही मुसीबत। मैंने उस समस्या के लिए एक समस्या खो दी है, कम से कम पुन: प्रोडक्शन प्रोजेक्ट और वर्कअराउंड के साथ। चूंकि ओपी ने पहले से ही समस्या का समाधान कर लिया है, यहां टीएल है; यह है कि आपको : उपयोगकर्ता के रूप में मुख्य नामस्थान में की आवश्यकता होती है। उपनाम बदलने से समस्या का हल होता है, जैसा कि ओपी ने किया है।

php - Symfony2 - New environnement but how to rewrite it url correctly? -

I am creating an application on Symfony2. Everything works fine, I can access it through the web address www.test.ch For some reasons, I want to create a demo space. So I work with demo.test.ch to create a new vhost. In Symfony2, I created a new app_demo.php which called a new environnement (espacially loaded the database) for the database. Everything works fine when I call demo.test.ch/app_demo.php but when I want to leave the app_demo.php in the URL (and based on .htaccess in the web directory of Symfony2), url remain demo.test. But is loaded in the environment. My demo looks virtual: & lt; VirtualHost *: 80 & gt; ServerAdmin support@test.ch Server Name demo.test.ch DocumentRoot / home / www / test / current / web directoryIndex app_demo.php header set access-control-allow-generation "*" errorlog / home / www / test / share / Log /apache.demo.error.log # Possible values ​​include: Debug, Notification, Notices, Warnings, Errors, Alerts, # Warnings, Rise ...

Android setTypeface not working correctly -

I write simple new application in Android and I want to do the activity widget using setTypeface. The code below in this code looks right that I get this error in the console: 1803-1803 / com.example.AndroidMultiPage E / AndroidRuntime ?? Fatal exception: main java.lang.RuntimeException: Unable to start activity ComponentInfo {com.example.AndroidMultiPage / com.example.AndroidMultiPage.MyActivity}: java.lang.RuntimeException: Can not make native typeface font path: property / font / bZar.ttf my simple code: package com.example.AndroidMultiPage; Import android App Import android.content.DialogInterface; Import android.content.Intent; Import Android.graphics. Typefaces; Importroid.os.Bundle; Import android.text.TextUtils; Import android.view.Menu; Import android.view.MenuItem; Import android.view.View; Import android.widget.Button; Import android.widget.EditText; Import android.widget.TextView; Import android.widget.Toast; Import org.w3c.dom.Text; Public Class MyActivi...

jquery - How to grey out a particular section of a div when dragging another div over it using javascript/css -

The functionality shown in the above link is being obtained by dragging an element. In addition, without using thewtriangle.js plugin Can it be achieved ?? Is there a way to solve this ?? You can do that using the jQuery UI Droppable. You can check the demo here: From your question, it seems that when the item reaches the droppole, you want to highlight the div. But as soon as you start dragging the item, this demo color droppole divas yellow. But still, this may be a good start for what you want to achieve.