Posts

Showing posts from May, 2014

Is it always safe to define sonar.forceAnalysis=true for SonarQube analysis? -

when parallel sonarqube analyses started, 1 rejected / fail error: the project being analysed. i learned on mailing list entry possible override check adding --define sonar.forceanalysis=true apache maven command. thus (to repeat title): always safe define sonar.forceanalysis=true sonarqube analysis? why care / ask? i know interesting corner cases or concerns using flag. examples: there downsides or risks? corrupt sonarqube database? i have teamcity cloud multiple build agents. if more 1 agent triggers build (after multiple, successive version control commits), sonarqube analyses may overlap. this property deprecated since sonarqube 3.5 , no longer necessary. see http://docs.sonarqube.org/display/sonar/frequently+asked+questions#frequentlyaskedquestions-failedtoanalyseaprojectasanotheranalysisonthesameprojectseemstoberunningatthesametime(sonarqube3.4only)

android - Going back and forth between intents without losing user entered data -

i have form. here, user fills in details event name, description, location etc. select location, have set button. button code: btnmap.setonclicklistener(new view.onclicklistener() { @override public void onclick(view v) { // todo auto-generated method stub intent map = new intent(getapplicationcontext(), map2.class); startactivity(map); } }); i select location there, , data passed main intent correctly. thing is, data in other fields event, description etc. users filled in lost. i tried startactivityforresult(map,1); too. doesn't work. there way keep data, without sending them in bundle other intent , getting them back? select image button does? goes gallery , comes without resetting other fields contactimageimgview.setonclicklistener(new view.onclicklistener() { @override public void onclick(view v) { // todo auto-generated method stub intent intent = new intent()

java - Is this a good way of clearing a StringBuilder? -

this question has answer here: how can clear or empty stringbuilder? [duplicate] 9 answers i ask if way of clearing/emptying stringbuilder? wrapped in method , called several times, thread safe? not consume lot of memory? better if created stringbuilder outside of method , in class instead? private void callme(){ stringbuilder builder = new stringbuilder(); builder.delete(0, builder.length()); } builder.append("some id"); if (builder.tostring().contains("some other id")) show("information") else show("invalid id") before post answer assuming using stringbuilder in loop , every few iterations may want empty , start empty stringbuilder. in case can think of 2 approaches: invoke setlength(0) on string builder using. prefer on delete feel more neat. or allocate new 1 instead rather clearing buffer

indexeddb - Uncaught ydn.error.ArgumentException: require index "Account__c,PrimaryContact__c" not found in store "contactRole" store.js line 1284 -

Image
i have following: ydbstorage = new ydn.db.storage(dbname, schema); /** @param values - array of keys . e.g. ['account1', 'city1'] @param index - string of index value . e.g. 'account, city' @description - records based on compound index. remember indexes not created boolean values */ var getrecordsoncompoundindex = function(store_name, index, values, success_callback, failure_callback) { console.log('inside getrecordsoncompoundindex'); if(!store_name || ! index || !values) { failure_callback(); } else { var keyrange = ydn.db.keyrange.only(values); ydbstorage.values(new ydn.db.indexvalueiterator(store_name, index, keyrange)).done(function(response) { if(!response){ failure_callback(); }else{ success_callback(response); } }); } } $scope.getaccountkeycontact = function() { var indexes = 'account__c,primarycontact__c'; var values = [accountid, "true"];

Python 2.7 multiprocessing get process result whithout using pool -

how can result process without using pool ? (i'm willing conserve eye on progression: (print "\r",float(done)/total,"%",) which can't done using pool far know) def multiprocess(function, argslist, ncpu): total = len(argslist) done = 0 jobs = [] while argslist != []: if len(mp.active_children()) < ncpu: p = mp.process(target=function,args=(argslist.pop(),)) jobs.append(p) p.start() done+=1 print "\r",float(done)/total,"%", #get results here job in jobs: job.get_my_result()??? the processes short (<0.5 seconds) have around 1 million of them. i saw thread can return value multiprocessing.process? tried reproduce couldn't make work properly. at entire disposal further information. this question may considered duplicate anyway here solution problem: def multiprocess(function, argslist, ncpu): total = l

c++ - cURLcpp error while compiling source -

i kinda new c++ , use of github. want use curl functionality in c++. therefore first forked curlcpp (by josephp91) github, , followed instructions readme.txt. now error when executing make # -j2 (with or without -j2 makes no difference). the error: [ 12%] building cxx object src/cmakefiles/curlcpp.dir/curl_easy.cpp.o in file included /home/user/.git/curlcpp/src/curl_easy.cpp:6:0: /home/user/.git/curlcpp/include/curl_easy.h:276:31: error: ‘curlopt_obsolete72’ not declared in scope curlcpp_define_option(curlopt_obsolete72, long); /* obsolete, not use! */ ^ /home/user/.git/curlcpp/include/curl_easy.h:47:33: note: in definition of macro ‘curlcpp_define_option’ template <> struct option_t<opt> {\ ^ /home/user/.git/curlcpp/include/curl_easy.h:47:36: error: template argument 1 invalid template <> struct option_t<opt> {\ ^ /home/user/.git/

statistics - plot regular graph when x axis data is inconsistent -

as example, have api access sensor measures how many lumens of light there outside. ideally want access every hour on hour can plot graph data like: datetime | lumens 2015-05-12 0900 | 9001 2015-05-12 1000 | 11400 2015-05-12 1100 | 11300 2015-05-12 1200 | 18000 unfortunately api call, various reasons such internet connectivity , device tragically running solar power, intermittent. ideally device store data until has been collected, alas returns data @ moment has been asked: datetime | lumens 2015-05-12 0905 | 9006 2015-05-12 1123 | 11900 2015-05-12 1201 | 18026 which holey, , late. assuming have work data , create graphs it, there several options. use scattergraph, type of graph account irregularity of data collected interpolate data estimate have been, on hour because want line graph doing equivalent of plotting results many sensors, inclined towards interpolated regularity. my questions is: if (does problem have name) it, can else if (are ther

java - How to capture website hits using Android App Plugin -

i new android app development there plugin capture different webpages user interactions webpage ui,user device name,user session,user time spend on particular screen , display records on mobile application. thanks. your best bet google analytics. pretty straightforward , documented. see here : google analytics

xmppframework - How to manage XMPP connection -

i designing chat application using ejabberd xmpp server , smack 4.1 api. below code snippet managing connection. // create connection server.com server on 5222 port. xmpptcpconnectionconfiguration config = xmpptcpconnectionconfiguration.builder() .setusernameandpassword("user", "password") .setservicename("server.com") .sethost("server.com_ip") .setport(5222) .setsecuritymode(securitymode.disabled) .build(); xmpptcpconnection conn = new xmpptcpconnection(config); try { conn.connect(); system.out.println("connection established."); conn.login(); system.out.println("logged in."); } catch (smackexception | ioexception | xmppexception e) { system.out.println("connection not established: " + e.getmessage()); } some processing chat , muc. // disconnect conn.disconnect(); system.out.println("conne

javascript - Mouse events not fired after applying CSS -

i'm working on app uses svg draw nodes (i.e. rectangles) have ports (i.e. circles) , edges (i.e. path) between 2 ports. i'm attaching mouseup , mouseenter , mouseleave callback ports in order draw edges. these events triggered when add following style mouseup never called , mouseenter not called @ when entering delayed cannot draw edge! .graph path { fill: none; } .graph .edge-bg { stroke: #000; stroke-width: 5px; } .graph .edge-fg { stroke: #fff; stroke-width: 3px; transition-property: stroke-width; transition-duration: 0.5s; } here port react component: // react element representing node port var port = react.createclass({displayname: "port", componentdidmount: function () { if(this.props.inport) { // if inport listen mouse event this.getdomnode().addeventlistener("mouseenter", this.onmouseenter); this.getdomnode().addeventlistener("mouseleave", this.onmouseleave); this.getdomn

How to retrieve Session key from Skyscanner API post request - Ruby -

in app want fetch live price flight details have used skyscanner api . have read documentation before obtained data have create live pricing service session. can created post request api , provide sessionkey using sessionkey , apikey can retrived data. how can sessionkey understood must provided api server. here try: require 'json' require 'net/http' require 'uri' post_params = { :apikey => "[api_key]", :country => "gb", :currency => "gbp", :locale => "en-gb", :adults =>1, :children => 0, :infants => 0, :originplace => '11235', :destinationplace => '13554', :outbounddate => '2015-05-19', :inbounddate => '2015-05-26', :locationschema => 'default', :cabinclass => 'economy', :grouppricing => true } sessionkey_request = net::http.post_form(uri.parse('http://pa

linux - PHP user cannot send email via Mutt but normal user can -

i experimenting php , have run problem. trying have php script send email when process has completed. <!doctype html> <html> <body> <?php echo shell_exec('echo "testing" | mutt -x -f /usr/web/mail.mut -s test -- my_email_here@gmail.com'); ?> <br> thanks. pdf copys of energy plots have been emailed. </body> </html> the result echo displaying "could not send message" on page. however, when logged host, can issues exact same command , messages goes through. some supplementary info. host linux mint vm. mta postfix. when logged host user (not php user), mutt works terminal. i've checked file permissions on mutt config file specified , should fine. mutt config file (/usr/web/mail.mut) has account info gmail. again, when execute same command messages comes through. tried looking in /var/log/syslog there not entries. grateful advice. edit: as per michal's comment. i've tried following same re

Android multiple activity status -

i have 15 activities in project.i want show current status of user @ bottom of each of 15 pages page.so user can clue how many forms remaining fill. don't know technical term it.but seek bar. in advance. go seekbar . set max value total number of activities , update according current activity number.

How to split Pandoc template files into sub files -

i able split pandoc template files sub files using \input{path-to-file} in template file. when use \input command, following error message when running pandoc -o output.pdf --template=default.latex --latex-engine=lualatex : ! latex error: missing \begin{document}. how split pandoc template files? i think not possible achieve pandoc. choose switch panzer , project combines pandoc styles.

PHP: handle undefined exception -

i have device sends data url, depending on situations 3 4 parameters received, when try data 4th parameter using $a = $_get["xyz"]; in case when " xyz " not exist function _get['xyz']; returns undefined. tried using try catch , initialized $a empty string in catch part did not work either. how can undefined exception handled? isset if(isset($_get["xyz"])) { $a = $_get["xyz"]; }

android - Attachments can not be sent out through email -

i trying send email attachment android app. email somehow goes out without attachment, though file exists. in email sending view, shows attachment (with file size even), after sending, on receiver side, there no attachment. idea why? private void copyfiletoexternal() throws ioexception { try { file sd = environment.getexternalstoragedirectory(); file data = environment.getdatadirectory(); if (sd.canwrite()) { string currentdbpath = "data/com.dw.inspectionhelpernstc/databases/inspection.db"; string backupdbpath = "inspection_backup.db"; file currentdb = new file(data, currentdbpath); file backupdb = new file(sd, backupdbpath); if (currentdb.exists()) { filechannel src = new fileinputstream(currentdb) .getchannel(); filechannel dst = new fileoutputstream(backupdb) .getchannel();

html - Java Swing Application in a web -

i'm doing portfolio projects i've made , have java swing projects. i'm not sure best way of showing them in web. i've tried export them jar , embed in html doesn't work. there other posibilities? you can use applet show swing project. or can use webstart launch applicatoin via website. webstart option display application complete in own frame. there nothing embedded in html.

jenkins workflow - SCM environment variables missing -

usually, when using scm git plugin , there bunch of environment variables can use (e.g. see these ) but neither git step nor generic scm seem that. is there way these variables groovy env.* can used? something useful: def commitmessage = sh 'git log --max-count=1 --oneline --no-merges | cut -b9-' i can think of writing results file , read them via readfile() mehtod -- there easier way achieve this? see jenkins-24141 ; these variables not yet available workflow. in meantime, on right track: run git command record information need, , use readfile load (see jenkins-26133 ).

javascript - Display number of colour swatch based on device -

Image
on product list template page, i’ve got colour swatches show available colours product. on mobile want display first 2 , , provide “more available” button takes through specific product page. on desktop want display first 4 , , provide “more available” button takes through product page. i can show , hide colours available on either viewport (with css), how variable logic work out when provide “more available” button on desktop , mobile? html: <!— product —> <div class=“product”> <div class=“colour-swatches”> <ul> <li class=“swatch">red</li> <l class=“swatch"i>blue</li> <li class=“swatch">green</li> <li class=“swatch">orange</li> <li class=“swatch">yellow</li> <li class=“swatch">black</li> <li class=“swatch">lime</li> </ul> </div> </div> css: li.swatch { &:nth-child(-n+2

java - multiple post ajax to different methods in the same controller -

i newbie jquery, js, java, etc world. using spring mvc maven. i have jsp file 2 post functions different url matching 2 different methods in same controller. so expected => caseasend (in mytest.jsp) posts data caseahandler (in mycontroller.java) casebend (in mytest.jsp) posts data casebhandler (in mycontroller.java) but both caseasend and casebsend ends same handler in mycontroller.java [note] caseasend , casebsend called different behaviors in jsp file , need process differently in controller. should handled seperately [q] how can make 1:1 mapping between post ajax , handling method in mycontroller.java. why both posts goes same method different url? [my code this] : 1) mytest.jsp function caseasend(title, id){ $.ajax({ url:'/test/{casea}.html', data: 'title='+title+'&id='+id+'&something'+something, type:"post", success: function(response){

Android XML parsing listview -

i using tutorial http://www.androidbegin.com/tutorial/android-xml-parse-images-and-texts-tutorial/ reaching xml parsing,if want change url 1 http://gis.taiwan.net.tw/xmlreleaseall_public/activity_c_f.xml ,how that? because xml format different.if there similar question of please inform me.thanks. there tag in each listitem url 'infos' @ begin includes tags. mainactivity.java package eason.xml; import android.app.activity; import android.app.progressdialog; import android.os.asynctask; import android.os.bundle; import android.util.log; import android.widget.listview; import org.xmlpull.v1.xmlpullparser; import org.xmlpull.v1.xmlpullparserexception; import org.xmlpull.v1.xmlpullparserfactory; import java.io.ioexception; import java.io.inputstream; import java.util.arraylist; import java.util.hashmap; import java.util.map; public class mainactivity extends activity { // declare variables listview listview; listviewadapter adapter; progressdialo

php - How to Access the private member of class? -

this question has answer here: how object value:item:private php array 1 answer xpostmodel object ( [script:model:private] => abc ) i wanna change abc efg how can ? there way ? if can't make changes class definition , there no public setter method class property, , need able directly edit property outside class, option using reflection methods, see example here: https://stackoverflow.com/a/6448613/1362634 here example should work in case set private property $script in $obj of type xpostmodel (where property inherited parent class model ): $obj = new xpostmodel(); $refproperty = new reflectionproperty('model', 'script'); $refproperty->setaccessible(true); $refproperty->setvalue($obj, 'def'); and here working code example mockup class definitions simulate situation of question. <?php error_reporting(-1); i

java - ds.getConnection hangs indefinitely with tomcat 6 to MSSQL DB -

i trying connect mssql database war file deployed on tomcat 6.0.41, java version 1.5.0_22. tomcat hangs indefinite time @ following line of code. datasource ds; this.conn = ds.getconnection(); and works fine oracle database. i have tried making changes @ tomcat in context.xml file of no use. thanks,

html - Resize of table-cell to zero -

can please this. there's solution without javascript , @media. image better understanding problem all details in it, there's no of it. main problem right , left columns resize 0 window/resolution changes, i'm getting hard time it .table { min-width: 399px; width: 100%; max-width: 100%; margin: 0 auto; display: table; } .table-cell-left { min-width: 0px; max-width: 9999px; width: 49%; display: table-cell; background-color:#933333; color: #ffffff; text-align: center; vertical-align: middle; padding: 0 0 0 0; } .table-cell-right { min-width: 0px; max-width: 9999px; width: 49%; display: table-cell; background-color:#339933; color: #ffffff; text-align: center; vertical-align: middle; } .table-cell-middle { min-width: 399px; max-width: 999px; width: 2%; display: table-cell; text-align: center; vertical-align: middle; background-color:#333393; color: #f

javascript - Investigation of specific lines of code on github -

Image
hey guys debugging jquery carasoul plugin , came across following lines of code :: $next.addclass(type) $next[0].offsetwidth // force reflow ofcourse , mean little , can have @ source on git here. (check line 147). now , question s not lines of code doing , question : sometimes when going through github repository , come across few lines of code make little sense , if these lines of code debugged , still persists make little sense , lines of code above example of trying say. now in such scenario, person left 1 option , check comments on git repo specific line of code , question "how go doing that" ?? . tried "blame" button , litterally gives me no info why lines of code added . place on git go , find out "why these lines of code added ??" . thank you. tenali. using blame button info you're going - shows comment left revision on left along author. unless code commented, other way asking author themselves.

C++ - Could not deduce template argument -

i have sample code makes use of template programming, runs fine on linux. when try bring windows visual studio 12, got compile error template argument deduction. here fraction of code cause error: template <int i> class assign_array { public: template <typename u, unsigned n> static inline void run(improved_builtin<u, n>& a, const u b[n]) { // sth } }; template <template <int> class a, int i, int e> struct loop_iter { template <typename u, typename v> static inline void iter(u& a, v& b) { a<i>::run(a, b); // error here } }; template <typename t, unsigned n> improved_builtin<t, n>::improved_builtin(const t v[n]) { loop_iter<assign_array, 0, n - 1>::iter(*this, v); return; } the error occurs @ a::run(a, b) => assign_array<0>::run(improved_builtin &,const u [n])' : not deduce template argument 'const u [n]' 'const int *'

php - cannot open any file in MacGDBp -

i’ve downloaded macgdbp on mac cannot use because cannot open or read file it. in « file » menu, « open recent » (pointing empty list) , « close » enabled. tried using « open as » on file of project open macgdbp, refused system. any appreciated. edit: window -> breakpoints -> "+" -> open file on local machine. view file in breakpoints window , set breakpoint want. macgdbp -> preferences -> paths -> "+". set local project root on local machine, , set remote project root on machine running code debugging. now when set breakpoint in local file , have matching path entry, macgdbp set breakpoint in corresponding remote file. the macgdbp doc helped me find answer. original answer: i new program don't believe how intended used (pretty sure osx apps have usual file menu options greyed out if app doesn't use them). once start macgdbp starts listening connections on port 9000 using dbgp protocol (the php xdebug extensio

javascript - Why does the following JS function wreck the browser process? -

var wait = function (milliseconds) { var returncondition = false; window.settimeout(function () { returncondition = true; }, milliseconds); while (!returncondition) {}; }; i know there have been many posts why not try implement wait() or sleep() function in javascript. not making usable implementation purposes, rather making work proof of concept's sake. trying console.log("starting...");wait(3000);console.log("...done!"); freezes browser. why wait() seemingly never end? edit: answers far, wasn't aware of while loop never allowing other code execute. so work, then? var wait = function (milliseconds) { var returncondition = false; var setmytimeout = true; while (!returncondition) { if (setmytimeout) { window.settimeout(function() { returncondition = true; }, milliseconds); setmytimeout = false; } }; return; }; javascript executed in single thread. when execut

wxpython How to change the values of widgets in other panel -

my frame split in 3 panels, in paneltwo, there textctrl, in panelthree , there textctrl too, when input in textctrl of paneltwo, need change value of textctrl in panelthree, how it? # -*- coding: utf-8 -*- import wx import sys class panelone(wx.panel): """""" #---------------------------------------------------------------------- def __init__(self, parent): """constructor""" wx.panel.__init__(self, parent) self.setbackgroundcolour("blue") font = wx.font(12, wx.decorative, wx.normal, wx.bold) button1 = wx.button(self, -1, label='button1') button2 = wx.button(self, -1, label='button2') button1.setfont(font) button2.setfont(font) vbox = wx.boxsizer(wx.vertical) vbox.add(button1, 1, wx.expand) vbox.add(button2, 1, wx.expand) self.setsizer(vbox)

plot - Syntax Error in Octave plotting -

i got following syntax error while want plot values: syntax error >>> plot(freq1, abs(fft1/max(fft1)),xlabel('f(hz)'), ylabel('amplitude i(f)'); ^ my definitions follows: a=x+y+z; % sinus mixture of different curves/functions n1 = fa/0.05; % n 50 ms fft1=fft(a,n1); freq1 = [0:deltaf1:fa-fft1]; plot(freq1, abs(fft1/max(fft1)),xlabel('f(hz)'), ylabel('amplitude i(f)'); edit: nice stop voting me down, know question not interesting (please see below in comment answer), thank you! you have more opening brackets ( closing ones ) , that's syntax error. it should be: plot(freq1, abs(fft1/max(fft1)),xlabel('f(hz)'), ylabel('amplitude i(f)'));

java - Override toString() method of final BluetoothDevice class -

in android app have listactivity displays bluetooth devices. have arraylist<bluetoothdevice> , arrayadapter<bluetoothdevice> . works there 1 problem. each bluetoothdevice displayed mac address in list need display name. as know adapter calls tostring method on each object. bluetoothdevice returns mac address if call tostring on it. solution override tostring , return name instead of address. bluetoothdevice final class not able override it! any ideas how force bluetooth device return name instead address? tostring ? as mentioned in comment extend arrayadapter , use method instead of tostring method. for example so: public class youradapter extends arrayadapter<bluetoothdevice> { arraylist<bluetoothdevice> devices; //other stuff @override public view getview(int position, view convertview, viewgroup parent) { //get view , textview show name of device textview.settext(devices.get(position).getname()); return view; }

mosquitto - how to test MQTT server in ubuntu? -

i have installed mqtt server 'mosquitto' in ubuntu machine following instructions in link https://lukeisadog.wordpress.com/2014/02/27/setting-up-mqtt-on-ubuntu-round-1/ . not able test server. when type mosquitto in command prompt getting below error. 1431416111: mosquitto version 1.4.2 (build date 2015-05-09 21:39:32+0000) starting 1431416111: using default config. 1431416111: opening ipv4 listen socket on port 1883. 1431416111: error: address in use when type mosquitto –daemon –verbose getting error "unknown option '–daemon'". please me on this. if have install mosquitto repository, have started automatically you. try connecting e.g. mosquitto_sub -t '$sys/#' -v you may need install mosquitto-clients package first. if works, have instance of mosquitto running. if want run broker manually yourself, can stop automatically started instance sudo stop mosquitto . with regards unknown option, should note need 2 dashes, --da

r - how to assign a missing value in dataframe by another value of dataframe? -

my dataframe col1 col2 col3 col4 abc 25 35 cde asd 25 45 def 15 36 erf 23 69 erf asd 25 36 erf dfg 85 78 convert col1 col2 col3 col4 col5 abc 25 35 abc abc asd 25 45 asd def 15 36 def erf 23 69 erf erf asd 25 36 asd erf dfg 85 78 dfg i need col5 value amnot getting it. have tried using ifelse code data$col5 <- ifelse(data$col2 =="",levels(data$col1),levels(data$col2)) but getting wrong value. as per @rolands comment data$col5 <- ifelse(data$col2 =="",as.character(data$col1),,as.character(data$col2))

sql - How to JOIN a table with itself and display it as a single row -

there table named product_price: create table [test].[product_price] ( [price_id] [bigint] not null, [product_id] [bigint] not null, [price_date] [date] not null, [is_sale_price] [bit] not null, [unit_price] [decimal](18, 2) not null ) it has following records: price_id product_id price_date is_sale_price unit_price -------- ---------- ---------- ------------- ---------- 1 15 2015-05-12 false 0,05 2 15 2015-05-12 true 0,04 3 25 2015-05-12 false 1,45 4 35 2015-05-12 true 2,65 edit: there can 2 prices - purchase price , sale price. there can't 3 or more rows same product_id , price_date . i want write select statement results in following: price_id product_id price_date is_sale_price unit_price price_id_2 is_sale_price_2 unit_price_2 -------- ---------- ---------- ------------- ---------- ---------- --------------- ------------ 1 15

c# - quartz.net automatic delete trigger -

i using quartz.net(2.2.x) in winform application(visual studio 2013),but when invoke function, program deletes trigger automatically. the task execute once. this log snip: 2015-05-12 15:19:01,056 [taskscheduler_quartzschedulerthread] debug quartz.core.quartzschedulerthread [(null)] - batch acquisition of 0 triggers 2015-05-12 15:19:01,141 [taskscheduler_worker-4] info probevideoupdate [(null)] - 开始调度检测视频更新作业..... 2015-05-12 15:19:01,275 [taskscheduler_worker-3] info netstatushelper [(null)] - ping www.baidu.com success 2015-05-12 15:19:01,529 [taskscheduler_worker-3] info netstatushelper [(null)] - 网络正常 2015-05-12 15:19:01,554 [taskscheduler_worker-4] info printapp [(null)] - original json address:http://api.zouwo.net/weixin/macdata?id=1001 2015-05-12 15:19:01,625 [taskscheduler_worker-3] debug quartz.core.jobrunshell [(null)] - trigger instruction : deletetrigger 2015-05-12 15:19:01,816 [taskscheduler_worker-3] debug quartz.simpl.ramjobstore [(null)] - deleting t

c++ - Reading contents from a stringstream -

i testing how read data out of std::streamstring i'm getting wrong, point out what's problem? , give correct way read it? my testing code is: #include <iostream> #include <string> #include <sstream> #define buffer_size 16 int main(int argc, char ** argv) { std::stringstream ss; ss << "un texto con datos de ejemplo para probar la extacción de un stream"; std::cout << "stream contents: '" << ss.str() << "'" << std::endl; char buffer[buffer_size] = {0}; std::streamsize read = 0; { read = ss.readsome(buffer, buffer_size - 1); std::cout << "read: " << ss.gcount() << std::endl; std::cout << buffer << std::endl; std::cout << "---" << std::endl; std::fill(buffer, buffer + buffer_size, 0); } while ( read > 0 ); return 0; } and i'm getting output

linux - Is there a way to map 3 ip addresses on diffrent server to a virtual ip address? -

there 3 servers, ip addresses 192.168.1.1 , 192.168.1.2 , 192.168.1.3 . i want use ip 192.168.1.100 connect 1 of servers , if 1 not reachable, connection should go server. ps:i knew way using name access server ,and detect , modify hosts file of client . but there other way ,such config switcher or router. thank ,and please forgive bad english .

perl - Creating a table in pdf file using PDF::Report and PDF::Report::Table -

in 1 of application having requirement download pdf file report details in form of table. for creating pdf file , writing table in it, using cpan module available in perl. pdf::report , pdf::report::table. please find below code sample: #!/usr/bin/perl use strict; use warnings; use pdf::report; use pdf::report::table; $pdf = pdf::report->new( pagesize => 'a4', pageorientation => 'portrait' ); $table = pdf::report::table->new( $pdf ); $data = [ ['a1' , 'b1' , 'c1'], ['a2' , 'b2' , 'c2'], ['a3' , 'b3' , 'c3'], ['a4' , 'b4' , 'c4'], ['a5' , 'b5' , 'c5'], ['a6' , 'b6' , 'c6'], ['a7' , 'b7' , 'c7'], ['a8' , 'b8' , 'c8'], ['a9' , 'b9' , 'c9'], ['a10' , 'b10' , 'c10'], ['a11' , 'b11' , 'c11'

java - REST webservice url to get only json data in google cloud -

i new google cloud webservices. have created 1 application in android json web services fetching complete html page output. need know , how path can json data output. i using httpget() add url of our webservice. need this.

ios - CVPixelBufferUnlockBaseAddress - Block UI -

i'm struggling debug weird problem. in captureoutput:didoutputsamplebuffer:fromconnection: right after cvpixelbufferunlockbaseaddress(imagebuffer,0); entire ui stops responding touches. camera preview works buttons stop responding , added uitapgesture , not work. tried putting dispatch still no success. - (void)captureoutput:(avcaptureoutput *)captureoutput didoutputsamplebuffer:(cmsamplebufferref)samplebuffer fromconnection:(avcaptureconnection *)connection { if (state != camera) { return; } if (self.state != camera_decoding) { self.state = camera_decoding; } cvimagebufferref imagebuffer = cmsamplebuffergetimagebuffer(samplebuffer); //lock image buffer cvpixelbufferlockbaseaddress(imagebuffer,0); //get information image baseaddress = (uint8_t *)cvpixelbuffergetbaseaddressofplane(imagebuffer,0); int pixelformat = cvpixelbuffergetpixelformattype(imagebuffer); switch (pixelformat) { case kcvpix