Posts

Showing posts from September, 2010

java - Update textview of MainActivity from class that extends Service -

I am trying to create an Android app that communicates with Bluetooth low energy module. I am able to connect to the module, read data and so on. But the problem is that I do not know how to improve the text visit with how the service is extended (which is the full connection to the blade). I know that there are more bills or more posts like these, but I believe that I tried Here's the main activity: And here's a class that enhances the service: If someone can give me some suggestions to solve my issue which is great! Create broadcast recipients and serve in the broadcast. If your activity is open, register the receiver and update the () UI on the receipt. The receiver should be in the activity ... Below is a job code

mysql - Submitting scores from AS3 to PHP/SQL - #Error 2101 -

Flash सीसी एएस 3 गेम से स्कोर पोस्ट करने में मुझे समस्या हो रही थी पृष्ठ SQL डेटाबेस के साथ। मुझे अपने आउटपुट विंडो में त्रुटि # 2101 संदेश प्राप्त हो रहा था। इस समस्या की खोज करने में बहुत समय बाद मुझे यह देखने की सलाह दी गई थी कि क्या PHP समस्या थी। मैंने एक बहुत सरल फ्लैश फाइल बनाई है, कोड (मैं नीचे मेरी वास्तविक साइट का पता बदल दिया है) है: आयात करें flash.events.MouseEvent; आयात करें flash.net.URLRequest; आयात करें flash.net.URLVariables; आयात करें flash.net.URLLoader; आयात करें flash.events.Event; Var उपयोगकर्ता नाम = "जेमी"; Var newScore = 1300123; Btn_submit.addEventListener (MouseEvent.CLICK, प्रस्तुत); फ़ंक्शन सबमिट किया गया (ई: माउसइवेंट) {var myrequest: URLRequest = नया URLRequest ("http://mysiteaddresshere.com/test_scores.php"); Myrequest.method = URLRequestMethod.POST; Var चर: URLVariables = नया URLVariables (); Variables.player = userName; Variables.score = newScore; Var लोडर: यूआरएल लोडर = नया यूआरएल लोडर (); Loader.dataFormat = U...

oracle adf - Progress Message -

How to add progress messages such as "Receiving data" practically. When the data is received, I need to display this message on an empty page. I'm new to ADF, so I'm sorry if this is something very basic I could not find it on the net. You can use JavaScript in your page or pageframement. My example uses a piece of a page, so the popup id should have an area. If you are having trouble finding the correct ID, you can view it from any browser, using View Source, and the name that you have given (in this case, poppop). & lt; Af: resource type = "javascript" & gt; Function enforcementPrevent user input (evt) {var popup = AdfPage.PAGE.findComponentByAbsoluteId ('pt1: r1: 0: splashPopup'); If (popup! = Null) {AdfPage.PAGE.addBusyStateListener (popup, handbasstate); Evt.preventUserInput (); }} Function handle buzest (evt) {var popup = AdfPage.PAGE.findComponentByAbsoluteId ('pt1: r1: 0: splashPopup'); If (popup! = Null) {if (evt....

html - div width and height alignment for all levels of zooming -

Image
एचटीएमएल कोड: & lt; div class = "CorpPerformance" & gt; & Lt; div वर्ग = "पंक्ति" & gt; & Lt; div वर्ग = "डैशबोर्ड शीर्षक" & gt; 3 महीने & lt; / div & gt; & Lt; div class = "डैशबोर्डसोर" शैली = "फ़ॉन्ट-वजनः बोल्ड" & gt; & Lt; एक वर्ग = "पुनर्निर्देशित लिंक" डेटा-मापदंड-कार्पोरेट्समेरीक्रेक = "कोई नहीं" डेटा-मापदंड-कॉरपोरेट्समेरीएक्सपैड = "0" डेटा-मापदंड-ग्राहकपैकेज = "" डेटा-मापदंड-एक्सप्रेस सेवा = "" डेटा-मापदंड-रखरखाव प्लान = "" डेटा-मानदंड-मॉडलनाम = "" डेटा-मापदंड-आरस्पेंडडेट = "" डेटा-मापदंड- rspstartdate = "" डेटा-मापदंड-वॉरंटीपाए = "" डेटा-मापदंड-वर्ष-मॉडल = "" डेटा-मापदंड-विभाग = "विक्रय" डेटा [कैलेंडर तिथि]। [कैलेंडर]। [कैलेंडर महीना]] [अक्टूबर 2014] "डेटा-मापदंड - सारांश अवधि =" 3 महीने "href =" / कॉर्पोरेट / ऑफसेट सर्वेक्षण "> 950 ...

How to allow Facebook logins from other people than myself? -

I am creating a website that people can log on using Facebook when I login from my Facebook account I do it, it works fine in the present. The strange thing is that when someone else wants to login, I get an error on Facebook (translated from Dutch): App is not configured: this app is available for developers Is not set up correctly for facebook login I do not understand why this works with my own account, but it is not with other people's accounts Do anyone know that the source is of this evil What is it, and how can I solve it? Any suggestion will be appreciated! You have to set your app public, just go to "Status and review" and the following text Use the switch next to: Do you want to make this app available to you and all its general features to the general public? Also Be sure to add "Website" in the "Settings" tab.

emacs - Run remote R process using script on local machine -

I use R in Debian with emacs and ess. I will run R process on a remote machine in my laptop from an R script. Therefore, to connect my local R script to the remote R process using MX XR-Remote via RAP script from within MMax, I started the SSH and a new R session on the remote machine Want to As long as I try to load some functions from my laptop (local machine) and send it to remote r, all do good work. Whenever I try to do this, I get the following error: (file name, "R", encoding = encoding) in source ('file) error: connection can not open : Warning message: (File name, "R", encoding = encoding) in the file: File 'myFunction can not open R': No such file or directory: If I run on the R console Switching and I getwd () console says that I have a home directory I have followed the instruction from the ADWB-site. Where am I wrong? What I do in this case opens the local file in MXS and then, Mx ess-eval-buffer This will take your c...

javascript - readyState does not get past 1 -

is trying to insert data into XML by Javascript open () function. but the website is not the last 1, below JavaScript code function addItem () {var name = document.getElementById ( 'Iname'). Values; Var price = document.getElementById ('Iprice') value; Var quantity = document. GetElementById ('Iquantity'). value; Var Description = document.getElementById ('ecommerce'). Values; XHRObject.open ("GET", "listing.php", true); XHRObject.onreadystatechange = function () {if (xHRObject.readyState == 4 and amp; xHRObject.status == 200} {document.getElementById ( 'Information'). InnerHTML = xHRObject.responseText; xHRObject.send (void);} }} I do not know that it is an error with PHP, but it is very big, so I will post it only when I need to. it was an error with the browser functionality, worked fine in Firefox.

ios - Check IF one String contains the same characters as another string -

I am trying to write a function which will allow me to determine whether a NSString * NSString * s1 = @ "going"; / code> characters of the second NSString * ; NSString * s2 = @ "ievngcogdl"; So basically, when there is a comparison between these 2 strings, then it should be correct because the first string of the first string s1 is the same letter S2 . Can I use a NSCountedSet ? I know that there is a method in this class Object in: (id) However I do not think it will solve my problem. I have other methods to complete this function and I need the necessary results See you? I think this method is rather slow, but I still have the [NSString RangeOfCharacterFromSet:] , which requires a NSCharacterSet item per comparison: - (BOOL) string: (NSString * ) AllCharactersInString in String: (NSString *) Four String {NSUInteger stringLen = [String Length]; NSUntengar four string line = [four string length]; For (NSUntiger I = 0; I & lt; Fou...

javascript - Why transformed the bytecode in the SpiderMonkey & JSC? -

The JavaScript engine is usually used to change the bytecode from the source code. Then, the byte code converts the native code. 1) Why turned the bytecode ?? Is the source code poorly converting the original code into bad performance? 2) If the source code is very simple (formerly A + b function), the source code that converts the original code is good? complexity and portability . Transforming source code and object code, whether it is bytecode for virtual machine or machine code for actual machine, a complex process Bytecode mimics the closest machines, and it is easy to work : To customize the code to run faster, it is also better to change the code or to convert it to other formats to make the machine larger, if the situation says for it. For this reason, it is usually easier to write an front end whose source is to convert the work into bytes (or some other intermediate language ), and then an back end that works on intermediate language: it optimizes, produ...

linux - keep hard link connection after erasing a file -

I try to achieve something which I imagined very simple, but which is more difficult than expected. I have a folder: source / I have another one: target / . I create a file test.jar in my first folder, then I have to show this file and should be executable in my other folder. I see 3 options: Manually copy / paste My files do this work but ... every time I update my file, so do Do not want to. The symbolic link works, but if I execute a jar file, the reference is not source / and the targets / as I would like. Hard link what I really want, but the problem is that test.jar is not modified, but generated it means that source / test.jar , target.test.jar still refers to the old file ... is it always compulsory to implement 2 files Edit: For now, I solved the problem by adding a line to my file from source / copy / copy inside a script To copy which I will execute after jar and execute it anyway. I guess what I wanted to do was really impossible, it would re...

How to automatically update your docker containers, if base-images are updated -

Say that I have a poor container based on Ubuntu: latest . Now a security update and Ubuntu: latest has been updated to Docker Repo. 1) How can I know my local image and its containers are running behind? 2) Is there some excellent practice to automatically update local images and containers in order to follow the Docker repo update, which will harm you like unread upgrades running on traditional Ubuntu machine? We use a script that checks whether the running container starts with the latest image has gone. We also use the upstart init script to start the Docker image. #! / Usr / bin / env bash set -e BASE_IMAGE = "registry" registry = "registry.hub.docker.com" IMAGE = "$ REGISTRY / $ BASE_IMAGE" cid = $ (docked PS | GRAP $ IMAGE | awk ' {Print $ 1} ') Drag the IAG for $ C $ D $ D $ in Dock = `Docker Inspection - Format' {{. Id}} "$ IMAGE` running =` docked by inspection - format '{{image}} "$ im` name =` dockke...

asp.net mvc - Getting 404 using ajax in nopCommerce plugin -

I'm using nopCommerce 3.40 I call Ajax calls in the nopcommerce plug-in Getting the error on See page code looks like: $ (function () {var submitButton = $ ("# buttonid"); // submit submit button Attach event handler button to. () {SubmitInfo ();});}); Function SubmitInfo () {$. AZ ({url: '@ Url.Action} ("ActionName", "ControllerName"), type:' post ', data type: "json", success: function (result) {}, error: function (jquxhr, textstats , Erratrown) {}}); } looks like the admin code public JsonResult ActionName () {// some code here} Look like my current URL: localhost: 15536 ​​/ admin / plugins / groupname / system name / configure look like AJAX URL in firebug : I have also tried with this URL but did not find the debug point in action: localhost: 15536 / Admin / ControllerName / ActionName Code> Localhost: 15536 ​​/ Admin / Plugins / GroupName / SystemName / ActionNem Please give me some ide...

Logic error with Python while loops using 'and' and 'or' conditions -

इस सवाल का पहले से ही एक उत्तर है: 16 उत्तर मुझे पता लगाना परेशान हो रहा है कोड का एक टुकड़ा ऐसा दिखता है कि उसे काम करना चाहिए लेकिन यह काम नहीं कर रहा है कि मैं इसे कैसे भी पसंद करूं। मैंने इस मुद्दे को प्रदर्शित करने के लिए एक उदाहरण लूप बनाया है: एक = इनपुट ("उत्तर:"), जबकि एक! = '1' या '2': प्रिंट ("यह फिर से प्रयास करने के लिए गलत है") = a = इनपुट ("उत्तर:") यह इरादा होगा कि मेरे पास उपयोगकर्ता इनपुट की शर्त है जब तक कि यह सही नहीं था, लेकिन जब मैंने सही उत्तर दिया, तो ऐसा होता है। उत्तर: 3 यह गलत है फिर कोशिश करें उत्तर: 1 फिर से गलत प्रयास करें उत्तर: 2 फिर से प्रयास करें यह अजगर खोल आउटपुट है और जैसा कि आप देख सकते हैं कि जब मैंने गलत नंबर दिया था, तो मुझे सही संदेश मिलता था क्योंकि यह गलत है, लेकिन जब मैंने 2 सही उत्तर डाल दिए तो न इसे लूप से बाहर निकल जाए। अग्रिम में धन्यवाद यह हमेशा true a! = '1' या '2': क्योंकि यह काम करता है: (a! = '1') या '2' और ...

mongodb - Play 2.3.5 and ReactiveMongo: MongoError['No primary node is available!'] -

I recently upgraded the playback to version 2.3.5 and try experimenting with ReactiveVango. However, every time I try to read data from Mangodybi, an exception is there. This is my build.sbt: name: = "" Reactive Mongoort Example "" "version: =" 1.0-snapshot "lazy val root = (file (". ") ). enablePlugins (PlayScala) scalaVersion: = "2.11.1" libraryDependencies ++ = Seq (JDBC, anorm, cash, ws, "org.reactivemongo" %% "play2-reactivemongo"% "0.10.5.0.akka23") This stacktrace is: play.api.application $$ anon $ 1: execution exception [[PrimaryUnavailableException $: MongoError ['! No primary node is available '~ [play_2.11-2.3.5.jar: 2.3.5] play.api.DefaultApplication.handleError (on application.scala:]]] play.api.application $ class.handleError (296 Application .scala) at 402) [Play_2.11-2.3.5 .Jere: 2.3.5] play.core.server.netty.PlayDefaultUpstreamHandler $$$$$$$$$$$$$$$$$$$$$$ (PlayDe...

c++ - smart pointer the element of a std::pair -

मेरे पास एक फ़ंक्शन है जो std :: pair & lt; objectA *, objectB * & gt; । फ़ंक्शन के प्रलेखन कहते हैं कि यह मेरी जिम्मेदारी है कि वह दो तत्वों को निरुपित करे। अब मैं बस कर रहा हूं: {std :: pair}; ऑब्जेक्ट ए *, ऑब्जेक्ट बी * & gt; जोड़ा; ... अगर (शर्त) {the_pair.first हटाएं; हटाएँ_पएयर.सेकंड; वापसी; } ... the_pair.first हटाएं; हटाएँ_पएयर.सेकंड; } जब the_pair दायरे से बाहर हो जाता है तो मैं दो तत्वों को हटाने के लिए स्मार्ट पॉइंटर का उपयोग कैसे कर सकता हूं? अगर मैं सही ढंग से समझता हूं, तो कॉलर हटाने के लिए कॉलर की जिम्मेदारी है। उस स्थिति में, आप जोड़ी के प्रत्येक तत्व का प्रबंधन कर सकते हैं: {// कुछ स्कोप std :: pair & lt; objectA *, objectB * & gt; The_pair = the_function (); std :: unique_ptr & LT; objectA & gt; pfirst (the_pair.first); std :: unique_ptr & LT; objectB & gt; psecond (the_pair.second); } // पॉइंटर्स हटाए गए हैं वैकल्पिक रूप से, आप अपना स्वयं का दायरा गार्ड लिख सकते हैं: struct pointer_pair_guard {pointer_pa...

php - Insert Last Primary Key from One Table into Another as Foreign Key -

Finding a way to insert the last primary key from Table1 as a foreign key I'm trying to Table2 . . So far, I have tried as a Blobblabblabblas from the table 1 with foreign code as SELECT max ('id') Works if a user registers at that time; However, if 5 users are registered at the same time, then the foreign key is wrong. You can do this. Creating a Trigger You can create a trigger after inserting table1 in table2 . for example; Create the trigger 'Table 1` in the second table on INSERT for table' 2 'for each row table 2 ST user_id = NEW.id, name = NEW.username; Using PHP You can do this, for example; (You will bind and sanitize the input, but for illustration, I will not be) $ mysql-> Query ("INSERT INTO` table1` SET 'Username =' Poccans'"); $ IntforeignKey = $ mysql- & gt; Insert_id; $ Mysql- & gt; Query ("INSERT INTO` table2` SET` id` = ". $ IntForeignKey);

html - responsive site don't load correctly on mobile device but on desktop with small width yes -

I have a problem, that wordpress does not load correctly on mobile devices - but with small width on the desktop The load is OK. I've got a meta tag with width = device-width and inicial-scale = 1 . 320px width is about 800 pixels on my phone with site load, but when I see it with 320px on desktop browser, it looks like how it should be. Where can the problem be? There may be many reasons! 1) You have multiple CSS (- WebKit -, - Motion -, - O -, - MS-) Animation, whose properties are only supported by your browser I 2) Latest Check Android / Mobile Device (which is designed to support all types of CSS behaviors) 3) Check your media queries, if you are using chrome, you probably only used WebKit to make better use of all the properties to support all types of browsers. , (- Webkit -, - - - - - MS -, - o -). 4) Use more Java scripts than CSS. 5) Try to debug if you have not tried.

javascript - How can i Set Pre-load image on image loding from Server -

Before uploading the image to the server, I must set the spinner to load the image server, so how do I get a short spinner image Like HTML & lt; Img src = "/ imge / abc1.jpg" /> & Lt; / Br & gt; & Lt; P & gt; This test text & lt; / P & gt; & Lt; Img src = "/ imge / anyname.jpg" /> & Lt; / Br & gt; & Lt; P & gt; This test text & lt; / P & gt; & Lt; Img src = "/ imge / any.jpg" /> & Lt; / Br & gt; & Lt; P & gt; This test text & lt; / P & gt; & Lt; Img src = "/ imge / allname.jpg" /> & Lt; / Br & gt; & Lt; P & gt; This test text & lt; / P & gt; Like the Facebook show spinner before the image load, just give me the & lt; Img & gt; Need to replace , image here is loading. So how can I set a small spinner in this way that the user can feel that the image is loading here If you want this css by your ...

axapta - Multiple values in query range value in Dynamics AX 2012 -

How to Prepare a Query with Multiple Values ​​I need to create a filter which displays only active BOMs in the grid and I I'm looking for This is my code that is not working: public invalid executeQuery () {QueryBuildRange qbr; QueryRun queryRun; Query q = new query (); Qbr = SysQuery :: findOrCreateRange (BOMTable_q.dataSourceTable) (Filename (BOMTable)), FieldName (BOMTable, BOMId)); If (activeButton == incorrect) {qbr.value (SysQuery :: valueUnlimited ()); } Other {When selecting BOMVersion where BOMVersion.Active == true & amp; Amp; BOMVersion.Approved == true {qbr.value (queryView (BOMVersion.BOMId)); } Super(); You have two options: Multiple Option 1: queryBuildData source qbds = q.dataSourceTable ( BOMTable); QueryBuildRange qbr; While (...) {qbr = qbds.addRange (FieldName (BOMTable, BOMId)); Qbr.value (queryValue (BOMVersion.BOMId)); } option 2: querybuildrenz qbr = q.dataSourceTable (BOMTable) .addRange (FieldName (BOMTable , Bomid)); Cont...

ios - Google Analytics not receiving data -

Image
In my app I'm having problems with Google Analytics. The website does not get any data, Sends the way. I am following this Ray Wenderlich tutorial, and at the point where you run the app, there should be 1 visitor in real-time observation. It keeps saying 0. My AppDelegate.m [GAI Shared Instance] Track unencaughtExceptions = Yes; [GAI Shared Instance] .dispatchInterval = 20; [[[GAI Shared Instrument] Logger] Catalog Level: KGELLOLververbos]; [[GAI Shared Instance] Tracker Withdrawing ID: @ "UA - ******** - 2"]; My view controller. - (zero) viewDidoadload {[Super ViewDidoadload]; - self.screenName = @ "Screensaver"; // more} My console 2014-10-17 15: 07: 52.479 wheels [25548: 2342406] IDFA class is missing, will not IDFA 2014-10-17 15: 07: 52.513 Gather wheels [25548: 2342437] Cordata: WARNING: The class 'Gaiproperty' was unable to load the class named 'GAIProperty' for the class, instead using the default NSManagedObject Whil...

regex - R string match between tags -

How to obtain all file names in a directory in R, for which is the start and end name known? list.files (dir_path, pattern = "^ my_") All files that are "my_" Returns from list.files (DIR_path, Pattern = "R. $") All files that are "R." But how do I implement both patterns? list.files (dir_path, pattern = "^ my _ *. R") gives character (0) You can use the following regular expression: ^ _ _ * \\. R BTW, . matches any character, then . $ mail AIR , not only the files that end with . . If you want to match to You really have to save it. list.files (dir_path, pattern = "^ my _. * \\. R $")

jquery - Joomla ajax call onclick event to call helper method in component -

My case is low: I need to call a php helper method in the view / edit.php of my component in order To validate the value of a textbox against the database, I have read a lot of threads about Ajax calls within Joomla, but it has not yet managed to work. In helper.php the method is MyClass :: View / Edit I have it:

oop - Building a python counter with rollover -

I need to create a message counter object - not to be confused with the counter class of Python. The specification calls for a counter that starts from 0, then increments to 1 until it becomes 4294967295, at which point it should move backwards to 1. I have applied a class to do this, but this is just a naïve attitude, is there a better way of achieving this goal? class messagecountor (): def __init __ (self): self.value = 0 def increment (self): if self.value & lt; 4294967295: self.value + = 1 other: self.reset () Def reset (): self.value = 1 As an option for OO, you can create a creative task that creates numbers in sequence, forever. There are a number of ways to do this. In the descending order of size and simplicity: def count_loop (upper_limit): while true: I (upper_limit) for the range: produce i gen = count_loop (42 94967295) i itertools GEN = (itertools.count for _ in I) category (42 9 497272) for gene = (For the I category of I (int, 1) for i cate...

objective c - iOS Swipe Gesture Recogniser for a quick-paced game -

I'm new to iOS development world, so I'm starting with a game that neither Clans of Clans nor The infamous 'I am rich' I know Python and HTML / CSS, so I will be able to face computer words, but if you are able to explain any answer, then it would be good. Shape a pattern on the screen from half to second, suppose it is 'Arrow Left, Arrow Right, Arrow Left' (in the form of an image). Then the user will have to repeat the pattern (in the right order) to proceed. Actually, I'm asking what would be the simplest / most effective way of programming? It would be great if I could easily add more patterns. In a way I thought that it can be done that there should be an ID for each pattern, in which the pre-defined 'nodes' are swiped in a particular order, this is an advantage for this idea. That I can add patterns, although they may take some time to program. I have another idea that the user has to assign the eraser to the brush and it will find that...

javascript - Form's children not available in $scope -

मेरे पास एक ऐसा फ़ॉर्म है: & lt; form name = "myform" & gt; & Lt; इनपुट प्रकार = "टेक्स्ट" नाम = "इनपुट" / & gt; & Lt; / प्रपत्र & gt; लेकिन मेरा इनपुट $ scope.myform.input में उपलब्ध नहीं है और न ही {{myform.input}} । मैंने एनजी-मिनलाम्थ : & lt; फ़ॉर्म नाम = "मायफॉर्म" नोवलडेट & gt; जोड़ने का प्रयास किया। & Lt; इनपुट प्रकार = "टेक्स्ट" नाम = "इनपुट" एनजी-मिनलाैन्थ = "10" / & gt; & Lt; / प्रपत्र & gt; और यहां तक ​​कि 10 से कम कुछ लिखकर, myform अभी भी वैध है। यह इनपुट की तरह बिल्कुल भी नहीं है। यहां जेएसफ़िल्ड पर होस्ट किया गया एक उदाहरण है: इनपुट टेक्स्ट पर AngularJS प्रलेख: आपको एक एनजी-मॉडल विशेषता की आवश्यकता है उदाहरण के लिए: & lt; फ़ॉर्म का नाम = "मायफॉर्म" & gt; & Lt; इनपुट प्रकार = "टेक्स्ट" नाम = "इनपुट" एनजी-मॉडल = "इनपुट" / & gt; & Lt; / प्रपत्र & gt; फिर आप ...

c# - MySQL update once WPF DataGrid cell has been edited -

I have a datagroup which is generated from a MySQL query. I want to be able to modify the datagrid and edit the database directly. Basically I need that the user has finished editing the cell after generating such a string: Pseudocode: "UPDATE current_table SET current_column_name = New_cell_value WHERE id = The number of edited row "" is in the first cell hidden, what would be the easiest way to get it? Have tried to see and events but so far I have no "celled edited" Events have not been found and neither can I get the new value or ID in the first cell of that line. EDIT: OK, I have made some progress, I now get the ID and column name I am able to do this, but the problem is that I am unable to get the new cell value. I think the problem is that this code sets fire on the Edit Editing Event, so the change has not yet been done. I can how to fix it? Detarav view Detaro = (Detarvdrishy) Gemdetagrid. Selected items; Int index = gameDatagrid.Cu...

mysql - Optimized SQL for timetable -

I want to create a SQL table in my database which can catch the timetable of the school but by all means I Trying to move forward was not optimal and during the 1-2 changes to the timetable, the database table became a little bigger. It is a little bit like this: mo to mercury guru austerity 07:00 08:00 9:00 10:00 11:00 12:00 13: 00 14:00 15:00 16:00 The basic layout of this is the timetable and the first 2 columns in the table are timetable and classics. My first approach was to call columns for each day with classes in one column, but it was a small buggy, my next approach was to get columns like mo_7, mo_8, mo_9 etc. So my question is, what is the most optimal way to save timetables in the database in which table layout. Thanks in advance. / div> Your problem is not your database, that's because you use it as a spreadsheet Are trying. You have to leave behind a small shop in the classroom, along with many features. If there is only one session in each c...

spring boot - Configuring Jackson to enable self-referencing objects using jackson-datatype-hibernate -

How do I configure Jackson ObjectMapper in Spring Data when using Spring Boot? When I try to return a self referenced unit I'm getting a "com.fasterxml.jackson.databind.JsonMappingException: no serializer class org.hibernate.proxy.pojo.javassist.javassistLazyInitializer And to find a property BeanSerializer discovered (To avoid exceptions, when I try to retrieve the children of an object in a self-referenced table, disable the serialization function. FAIL_ON_EMPTY_BEANS " error. I thought that The issue was a serialization problem that can be solved using the Jackson-Datatype-Hibernate package to help sort the self-referenced objects. I have no definitive guidance till now I can see how to configure an existing ostapper instance that uses Spring Data Rest. / P> I like the ObjectMaster sub-works according to the Geitheb page of the project C is required public class HibernateAwareObjectMapper extends ObjectMapper {public HibernateAwareObjectMapper () {r...

javascript - Uncaught TypeError: undefined is not a function -

I am trying to find the difference between 2 dates in whole months, I have a small script on the stack exchange Found, but this is giving me an error of "Uncheck Type error: there is no undefined function". I get in Chrome, this is a fairly simple HTML page. It does not look like the first line of the function (var monthsLeft = to.getMonth () etc ...) (slightly simplified version for clarity :) & lt; Script & gt; Function monthDiff (from, from) {var monthsLeft = to.getMonth () - to getMonth () + (12 * (to.getFullYear () - to.getfulair ())); If (to.getDate () & lt; from.getDate ()) {monthsLeft--; } Months of return; } Function lumpChange () {var today = new date (); Var april5th = new date (); Var months length = 0; Today = '10 / 05/2015 '; April5th = '04 / 05/2015 '; Month length = monthdays (today, April 5th); } & Lt; / Script & gt; Your monthDiff () function looks like it Expected to pass the code as the date object...

windows - Java Runtime exec method throwing error when using with a custom URI -

I am running this command using this command prompt and it is running fine: without any problems: Start Demo: "-ping -ip 172.18.102.65" In the above order, demo: a custom Yury which I have created and I am crossing the criteria of the Custom Yuri that make it -ping , -ip and Lt; An_ip_address & gt; is Custom Yuri work. But when I run the same command using this code, then it does not work: Runtime.GetReight (). Exec (new string [] {"cmd.exe", "/ c", "start", "demo: \" -ping -ip 172.18.102.65 \ ""}}}); I'm receiving an error message: Windows '-ping' can not be found How to do this work. After my explanation of the question, I am writing again for my answer (thanks!). This syntax works for me: Runtime .getRuntime (). Exec (new string [] {"cmd.exe", "/ c", "start demo: \" -en -ip-172.18.102.65 \ ""}); It seems that the cloud defin...

android - Google Play store coming soon -

I have been asked to set up a Google Play store account / listing for an app that is in the early stages of development. is. The company only wants a link with some screenshots, so that they can point out for marketing purposes. I want to make a list that is coming soon and describes a description and screen shots. I was thinking that this is an option or I have to upload some type of APK on the listing.

Grails cannot cast JSON array to HashMap -

I have the following JSON (stored in strings in Groovy): { "Isfizz": "true", "buzzProperties": [{"foo": "bar"}, {"widget": 35}], "name": "dummy1"} Content register () {def JSONObject = request.JSON content stuff: In my Grails controller I have the following method that handles this JSON as HTTP request and to read JSON in Groove Attacks Vars = new content () stuff.isFizz = jsonObject.isFizz stuff.buzzProperties = jsonObject.buzzProperties // stuff.buzzProperties a HashMap stuff.name = JsonObject.name stuff} When the controller executes the method (when this request is received) I get the following exception: Can not remove ['foo': 'bar'}, {"widget": 35}] 'orbit' with org.codehaus .groovy.grails.web.json.JSONArray java.util.Map ' 'For class': groovy.lang.GroovyRuntimeException: manufacturer match for java.util.Map (org.codehaus.groovy.grails) co...

c++ - How to get memory information on Linux system? -

Using total memory, memory, and free memory from C ++ code on Linux system? Run your program through valgrind . For a program called foo , for example: valgrind foo This program will keep in the harness that keeps Track the usage of memory and print out that information after the program is over. If you do not have valgrind installed for any reason, then you should be able to find it in your distributions package repository

Laravel Artisan Migrate: "Error in cURL request: SSL certificate probl***: unable to get local issuer certificate" -

मैं विर 8.1 पर WAMP पर Laravel 4 चला रहा हूं। / P> [zend \ http \ client \ adapter \ अपवाद \ runtimeException] cURL अनुरोध में त्रुटि: SSL प्रमाणपत्र समस्या: स्थानीय जारीकर्ता प्रमाण पत्र प्राप्त करने में असमर्थ मैंने काफी कुछ किया है, लेकिन मैं अभी खो गया हूं। क्या कोई मुझे सही दिशा में इंगित करने में सहायता कर सकता है?

playframework - LESS generating empty folders in lieu of CSS files -

I am using SBT 0.13.5 at least and sometimes generate css files properly but others Bar without any obvious reason, it generates empty folders with the same name (such as 'social stylesheet.m.sssss'). Less build settings: includeFilter in (property, LessKeys.less): = "* .less", filter out (property, LessKeys.less): = "_ *." Insert into LessKeys properties: = true The empty folders clearly break the build. Why would this plugin ever generate empty folders instead of CSS files? It does not make sense to me.

sql - Counting distinct results and how to use sub queries in MySQL -

There is a problem finding the best way to do this. My query is as follows: Datatable from SELECT * where `type` = 'new' and 'permit' = 'valid' and year (` issuer ') = '2012' order 'Swamy' ASC This creates the personal results I find, but from that subset of data, let me know the list of individual (separate) "owner" , And how often they are ( I'm not sure how to query my query as a sub query Use and run another query on the result. I will usually only export the result, then work on it from there, but I have some time today and I feel that I have the right to do this I want some help in learning the way.

javascript - Remove elements from dom if not the only occurence using jQuery? -

इस सवाल का पहले से ही एक उत्तर है: 3 जवाब मेरे पास कई प्रकार के साथ एक फ़ॉर्म है गतिशील रूप से जोड़े गए इनपुट क्षेत्रों की पंक्तियों, मैं इन क्षेत्रों की अंतिम पंक्ति को हटा कर पा रहा हूं (बशर्ते कि यह केवल पंक्ति नहीं है) मैं इसे इस प्रकार से कोशिश कर रहा हूं जावास्क्रिप्ट $ ("# remove-item")। क्लिक करें (फ़ंक्शन () (यदि ($ ('। इनपुट-पंक्ति: पहले')! = = $ ('। इनपुट-पंक्ति: अंतिम')) {$ ('। इनपुट-पंक्ति: अंतिम')। निकालें ();}}); HTML (सरलीकरण के लिए संक्षिप्त) & lt; div class = "input-row" & gt; & Lt; इनपुट / & gt; & Lt; इनपुट / & gt; & Lt; इनपुट / & gt; & Lt; / div & gt; & Lt; div वर्ग = "इनपुट-पंक्ति" & gt; & Lt; इनपुट / & gt; & Lt; इनपुट / & gt; & Lt; इनपुट / & gt; & Lt; / div & gt; मैंने सोचा था कि यह उस स्थिति में काम करेगा जहां & lt; input & gt; फ़ील्ड की केवल एक पंक्ति होती है, मैं विभिन्न चयनकर्ताओं द्वारा...

java - Creating a CharAt() method in the main class -

I got stuck on this section of code. The idea is to return the character in the given index without using string, stringbirders, and wrapper classes . What do I have : " this.data " as a char [] data for me " MyOwnString " Object I understand how the main class code should look like: public char charAt (int index) {this Create a new letter from the data, then use the charAt () method}} to select the given index, the string will be in a tester class. Without any easy shortcuts, some guidance is required on this challenging homework work. About return data [index]; ?

angularjs - ui-router dots in name not working -

The UI-Router docs shows that you can use dots in the root name: Code> & lt ;! - Partial / State 1.html - & gt; & Lt; H1 & gt; State 1 & lt; / H1> & Lt; Hours / & gt; & Lt; A ui-sref = "state1.list" & gt; Show list & lt; / A & gt; & Lt; Div ui-view & gt; & Lt; / Div & gt; But though this does not work in my app, this is an example, as long as I customer to client.ts everywhere: Plunker here: As you can see the link can not be clicked: / What you need to do is add an intangible state for that clien . Here, state: Every time you define a state with dot. You still need to define the abstract state for at least the child. In your case for clien

json - json4s object extraction with extra data -

I am using spray with json4s, and to handle items placed to update items, Implementation is found ... My problem with it is that I first used an example of some objects from JSN, but being a cool API, I want to specify an ID in the URL. Then I have to make another example of some object which is indexed with ID ... To do this, I am using a constructor like some object (id: long, obg: some object). It works well, but the implementation is ugly and it seems unworthy. What can I do so why can I paste the ID in some way so that I can make an example of only some objects? class ApplicationRouter extends BaseRouter {val routes = pathPrefix ("some-path") {path ("destination resource" \ intNumber) {id = & gt; Entity (as [Jobic]) {rawData = & gt; Some ExtractedObject = rawData.camelizeKeys.extract [SomeObject] Val ExtractedObjectWithId = SomeObject (ID, extractedObject) handleRequest (extractedObjectWithId)}}}} Case class SomeObject (id: long, data: string, som...

osx - “Xcode” is damaged and can’t be opened. You should move it to the Trash -

Image
स्थापित XCode 6 पर Mavericks । यह रन नहीं है अपडेट किए गए ओएस से योसेमाइट 10.10 : अब Xcode.app (* .dmg के माध्यम से इंस्टॉल) लॉन्च में त्रुटि संदेश "Xcode" क्षतिग्रस्त है और खोला नहीं जा सकता। आपको इसे ट्रैश में ले जाना चाहिए। ऐप स्टोर के माध्यम से XCode 6.0.1 में अपडेट किया गया। फिर भी कोई भाग्य नहीं एक ही त्रुटि संदेश कोई भी ठीक समझे? मैक ओएस सिएरा के निर्माण के तहत किसी भी नए जोड़े गए आवेदन के साथ मुझे यह त्रुटि मिली। मुझे निष्पादित करना था: xattr -rc / applications / & lt; दोषपूर्ण अनुप्रयोग & gt; .app आप "मरम्मत" सभी एप्लिकेशन: xattr -rc /Applications/*.app

c++ - How to prevent a virtual method from always being compiled? -

एक Arduino पुस्तकालय पर काम करते समय मैंने एक दिलचस्प संकलन समस्या में भाग लिया है। सभी कक्षाओं में सभी आभासी विधियां एकत्रित हो जाती हैं ... हमेशा यहां तक ​​कि जब वर्ग कभी भी निर्माण या भी उल्लेख नहीं किया जाता है। उदाहरण Arduino कोड जो इस समस्या को पुन: उत्पन्न करता है: वर्ग BaseClass {आभासी शून्य विधि (); }; शून्य BaseClass :: method () {Serial.println ("यह बिल्कुल संकलित नहीं किया जाना चाहिए ..."); } शून्य सेटअप () {} void loop () {} बेसक्लास परिणाम 670 बाइट्स के अंतिम बाइनरी में छोड़कर। यह भी शामिल है, जबकि कभी नहीं वर्ग का उपयोग कर, 3.354 बाइट्स का एक कोड आकार में परिणाम है। कि अक्सर कभी नहीं सब पर इस्तेमाल किया जाएगा एक पुस्तकालय वर्गों का एक बहुत युक्त, सभी एक आभासी अद्यतन युक्त के लिए () रुटीन, इस तरह का व्यवहार अस्वीकार्य है मैंने अभी तक जो एकमात्र उपाय पाया है, वह उपयोगकर्ता को उन घटकों के लिए हेडर फाइलों को शामिल करने के लिए मजबूर करना है जो वे उपयोग करना चाहते हैं। अधिमानतः, हालांकि, मैं पुस्तकालय सरल रखने होगा और न ऐसा करने के लिए उपयोगकर्ता की आ...

backbone.js - Using same object instance from more than one different Backbone/Require views -

I try to write the login view of two scenes and try to render each data with the same data as The two are collected from a pool domain in both. The log template has a low data field, so the template template variables in comparison to the template template. So I thought of using a model for both of them to render the GUI, the data model formats, I am trying to isolate worries and to keep single responsibility for my module. Now, the form data model needs to make the dependence of a scene and make it in this view, and by looking at this dependence of this second example, mention this example from another example. Yet for the last time it should use the same example of seeing it, it is in the form of dependence it seems that there is only one scene and three different model data, login and registration and two separate templates are a solution You can. It looks amazing in the object-oriented paradigm that it feels cumbersome to add a small feature, which fights with object orient...

linked list - Using LinkedList to Compute the Addition of Large Size of Numbers (Java) -

I have written a program that calculates the time taken to calculate n integer (randomly generated) Calculates the amount of an ArrayList in the sum of all the values ​​and in a way, I can compare time to the linked list in nanosecond. The problem is that when I entered size 10 ^ 6 (1,000,000) for the calculation, Did not take the time for the linkedlist, only ArrayList for. I have been waiting for more than 20 minutes to show up, but there is no output yet, however, when I use small numbers for the size of 10 ^ 3 or 10 ^ 4, then it works fine. So, I was wondering if there is a limit on the size of the linked list or not. If so, can I get permission to calculate the values ​​of 10 ^ 6 using Linkedlists? I think how your code looks like. test for public squares {public static zero main (string [] args) {int LENGTH = 1000000; & Lt; Integer & gt; List = New Arrestist & lt; & Gt; (); For (int i = 0; i & lt; LENGTH; i ++) {list.add ((int) (100 * Math.rendum (...

Is it possible to shift column data downwards in a MySQL table? -

I want to use a table like this: + ---- - + ------------ + ----------- + | ID | Col1 | Col2 | + ------ + ------------ + ----------- + | 1 | ABC | Amano | + ------ + ------------ + ----------- + | 2 | Def | Pqr | + ------ + ------------ + ----------- + | 3 | Too. Stu | + ------ + ------------ + ----------- + What is a way to add A new line and a column downwards change? The table should look like this ... + ------ + ------------ + ----------- + | ID | Col1 | Col2 | + ------ + ------------ + ----------- + | 1 | ABC | | + ------ + ------------ + ----------- + | 2 | Def | Amano | + ------ + ------------ + ----------- + | 3 | Too. Pqr | + ------ + ------------ + ----------- + | 4 | JKL Stu | + ------ + ------------ + ----------- + New line with cell price Put [Row 4, call1] = 'JKL', but I want to increase call 2 data downwards, so [line1, cola 2] is now zero. Thanks in advance. EDIT: Thanks RAD & amp; 2unco; There was a play and you can find many columns in t...

ms access 2010 - Adding / Subtracting Two Fields in Query Criteria -

I have a table that contains suburbs and their geocodes. I have a query that selects a suburb from the form, together with +0.5 and -0.5 long and all other suburbs within latitude. Criteria in the query, respectively for Long and Wide Area; Between [forms]! [Long] -0.5 and [form]! [FMFIMMetting Locations]! [Long] +0.5 middle [form]! [FMFIMAttinging Leases]! [Late] -0.5 and [form]! [FrmFindMeetingLocations]! [Lot] +0.5 It works perfectly. What I am trying to do, statically changes the '0.5' in the context of the combo box on the form (by giving the option of 0.01, 0.05, 0.5 etc.) I have tried below and various other combinations, etc., but it does not seem to work. ] [frmFindMeetingLocations]! [Late] - [form]! [FrmFindMeetingLocations] [cmbSubDistance] and [form]! [FrmFindMeetingLocations]! [Late] + [form]! [FrmFindMeetingLocations]! [CmbSubDistance] to I put a text box and refers combo, and value have been added so that way I have two references that seem to r...

Show data on a specified template in wordpress -

I am using a plugin called Wp Store Locator No Custom Post Type . Therefore, the plugin gives a list of stores as output and has a template designed for it. I have modified the plugin in such a way that when I click more details , take me to the particular page of the particular clicked store. I did this localhost / wordpress /? Link like Wpsl-id = 3 has been created. My question is how can I show only on special stores? I have created a template in that plugin but I have no idea how I can use it. Any help from the user of the WP Store Locator will be highly appericiated.

ruby - Looping through nested modules -

I have created a module structure to capture the static data, something that I did not want to store in a database: module Wixon module ketterz module Amazon module THREE_D_PRINTED_PRODUCTS REFERAL_FEE_PERCENTAGE = .12 MINIMUM_REFERAL_FEE = 0 NAME = 'end of 3D printed product' module AMAZON_DEVICE_ACCESSORIES REFERAL_FEE_PERCENTAGE = .25 MINIMUM_REFERAL_FEE = 0 NAME = 'Amazon Device Accessories End module of AMAZON_KINDLE REFERAL_FEE_PERCENTAGE = .15 MINIMUM_REFERAL_FEE = 0 NAME = 'Amazon Rugged 'end module AUTOMOTIVE_AND_POWERSPORTS REFERAL_FEE_PERCENTAGE = .12 MINIMUM_REFERAL_FEE = 1.00 NAME =' Amazon Kindle 'End End End I am trying to select elements under the module. Is it possible to loop each module: Wixon :: Katarias :: Amazon. Ish | Category | Print Category :: NAME} I know that this code does not work like that. I think that's possible what you are trying to do: Vixen :: Cateories :: Amazon.constants.each do | Category | ...

multithreading - If I have 1 thread writing and 1 thread reading an int32, is it threadsafe? -

I am using C #, and I need to know that reading 1 thread and writing 1 thread is any Safe without vaporization or locks I only have to read / write 32 bit ints and booleans. This is pretty much the definition of a thread-insecure code if you lock If you analyze the need, you always find this pattern. If you do not lock, the thread that reads will show random variations in the variable, not just outside its synchronization with its execution and completely at random times. The guarantee that comes with the C # memory model is an int and bool update atom . An expensive word meaning that you will not be able to read any value by mistake, where some bytes of value have a new value and some have an old value. Which will produce completely random numbers. Each value update is atomic, long , double and the structure type (faucet & lt;> and decimal ) are not atoms. Problems are not necessary to lock the issues where they are needed to debug, they depend on time...

arrays - get element from arbitrary list in javascript -

I have a function in javascript where I need to retrieve the last element of the list. I list an array, string, Numbers can be list (not array). I tried to convert the list to string and then tried to retrieve an array and index it by index, but it is not working. Here I have tried the code: function Previous list) {var array = New string (list); Array = array.split (""); Return array [array.length-1]; } I do not understand what the problem is because the trial suite estimates: 5 instead of 5: 5 I am using code warfare and not writing a test I am Does it expect a number and is getting the string '5'? I do not understand very well in loose typed languages. From the comments, I think that means you want to return the last element in either array The last letter in a string, or if the last argument is passed, it will: function last () {if (arguments.length & gt; 1) {// most First we handle the case of multiple arguments: Array.prototype.pop.call (...

PHP variables variable not displaying if passed as an array or object -

It works with simple variables, but it shows empty results with complex variables. Or there is no other way thanks. # $ It works with simple variables $ object = "fruits"; $ Fruit = "banana"; Echo $$ object; // & lt; ------------ Works: Output "banana" echo "\ n"; Rebound $ {"fruit"}; // & lt; ------------ This output "banana" # 2 It does not have complex structure. Am I missing something here? Echo "\ n"; $ Result = array ("node" => (object) array ("id" => 10, "home" => "earth",), "count" => 10, "and_so_on "=> True;); #var_dump ($ result); $ Path = "results ['node'] -> ID"; Echo "\ n"; $$ route echo; // & lt; ---------- This output is empty Output "10" is not required to use variable variable at all, but if you want to use a variable as var, then $ path = "results ['node...

ubuntu 12.04 - Process Core dumps are not created after crash -

I have configured the system configuration to make process core dumps. Below are my configurations. /etc/sysctl.conf kernel.core_uses_pid = 1 kernel.core_pattern = /var/core/core.%e.%p.%h.%t fs.suid_dumpable = 2 / etc / Security / Limit.conf * Soft Core Unlimited Root Soft Core Unlimited Here are the steps I'm following to process the process. 1) I have restarted the Mysql service and executed command " kill -s SEGV " then I have a core dump file in the / var / core space Found Then I have started my service mysql "/ etc / init.d / mysql start" or "mysql service Start " . Now if I give " kill -s SEGV " then the core dump file is not being created. 3) To recover a crash file, I only have to restart the mysql service if I use " kill -s SEGV / Code> "I'm getting a core dump file. Can anyone please help me solve this? First of all, you can confirm that the core dumps are disabled for the M...

java - Class Cast Exception when casting double -

I tried to run the following code, it compiles, but class class throws the extension. I'm really glad if someone can help me. Why double costprice = 0; Object [] possibilities = null; CostPrice = (Double) Joppenpen. Shoinputdialog (Alpha POS, "Cost Price:", "Enter Value", Joppenpen. PLAIN_MESSAGE, Blank, Prospects, ""); answerpace.shoinputdomog () a The object is attributed to the (@SeleenVirtuose) which can not be inserted in double , using double.parseDouble () to parse the string as double To do it. costprice = double. PRSDB (Joppenpen. ShowInputDialog (alpha POS, "cost price:", "enter value", joppenpane.plin_msassage, empty, possibilities, "")); In addition, you can do all this on one line As you are declaring the double variable and then directly setting You are probably declaring it as well and assign a new value to a line double costprice = double. PRSD Double (JoptionPan.ShownputDial...

rest - Login/Register by using RESTFul api written on Java -

I created Java Web App using the Netbeans IDE. I have created organizations with relationships. Web pages are simple dashboards where I am using new entities I can add, change them and remove them. I've added cool web services for my organizations. Therefore the web page will be available only for the admin and I want to create client applications which only have access to my data. This means that the customer must log in or register on their server. When user login / registers on website, server will create session for this user. I know there is no session in lush service, my thoughts login and password every is the time when the customer wants to do some work with the server. Q: Is there any other way to create something like between sessions between client and server? I hope it is not associated with encryption There are several options for authorization with authentication . If you want to use simple authentication, look for the 'Basic Auth' description of ...

java - Updating existing Row on database jdbc -

No error is showing, when I click on the button, but the database is not updated on the table. string heh = jlabel 17.getText (); Try {stmt.executeUpdate ("update books SET availability = '" + "missing" + "' where book_title = '" + heh + "' ');} hold (SQLException error) {System.out.println (err) .getMessage ());} You completely messed up the query , stmt.executeUpdate ("update books SET availability = '" + "missing" + "' where book_ title = '" + + + "' '); may be, stmt.executeUpdate ("Set availability of books SET availability = 'unavailable' Where book_title = '" + heh + " ''); You are advised to print the query before executing, because it avoids common mistakes, try to use the prepared statement as well, because your SQL is weak for injection Read it

ios - Application crashed after two minutes -

I am creating an application that takes data from the web services and shows it in the table view When it launches it works like a magic, but when I see the table more than 5 times more than 7 times it was not working and it was so that it was stopped. If I do not do any scrolling on the table, then the app also crashes after 2 to 3 minutes. The code is as follows: - (zero) viewDidoadload {[self.interviewTableSetoshoshorazentalScroll Indicator: No]; [Set the retired view Current Circle Indicator: No]; PageNum = 0; [Super viewedload]; NSURL * url = [NSURL URLWithString: [NSString stringWithFormat: @ "http://www.truemanindiamagazine.com/webservice/interview.php?page=%d", page news]]; NSDTA * Data = [NSDTATA DATAVITY CONTENT URL OF: URL]; NSError * error; NSDictionary * json = [NSJSNSReelization JSONObjectWithData: Data Options: NSJSONReadingMutableContainers Error: & amp; Error]; NSLog (@ "% @", json); Self.dataArray = [Jason ObjectForcae: @ "Data...