Posts

Showing posts from February, 2013

Delay by 1 microsecond in C MIPS Environment -

i'm trying port u8glib (graphics library) mips processor, openwrt router. here's example in arm environment. as such, 1 of routines must implement is: delay_micro_seconds(uint32_t us) since high resolution unit of time, how can reliably in environment? i've tried following, i'm not sure how validate it: nanosleep((struct timespec[]){{0, 1000}}, null); how can validate approach? if bad approach, how reliably delay 1 microsecond in c? edit: i've tried this, i'm getting strange output, expect difference between 2 print s 1000*10 iterations = 10,000 , closer 670,000 nanoseconds: int main(int argc, char **argv) { long res, resb; struct timespec ts, tsb; int i; res = clock_gettime(clock_realtime, &ts); for(i=0;i<10;i++){ nanosleep((struct timespec[]){{0,1000}}, null); } resb = clock_gettime(clock_realtime, &tsb); if (0 == res) printf("%ld %ld\n", ts.tv_sec, ts.tv_nsec);

xslt 1.0 - Grouping elements based on criteria and eliminating duplicates -

i have problem on grouping elements based on criteria , eliminating duplicates. i have 2 records in xml. document 1 , document 2 the objective create table 3 sections. same, add, delete. elements both in record should come in same subsection quantities. element not there in doc 1 , present in doc 2 should come add subsection , elements there in doc 1 , not present in doc 2 should come delete subsection. here able create 3 subsections total. problem identify similar elements based on rec_no in same document , sum quantities. here output table comments. --------------------------------------------------------- section recno desc doc-1 qty doc-2 qty total --------------------------------------------------------- same 111 desc1 1 2 300 same 444 desc4 6 4 1000 --------------------------------------------------------- same total 1300 -----------------------------------------

Convert Vector to Tuple scala -

is possible convert vector of heterogeneous vectors list of tuple3 in scala i.e. vector(vector(1,"a","b"),vector(2,"b","c")) list(tuple3(1,"a","b"),tuple3(2,"b","c")) explicitly convert every inner vector tuple3 : vector.map { case vector(f, s, t) => tuple3(f, s, t) }.tolist if have vectors of variadic size can use more general approach: def totuple(seq: seq[_]): product = { val clz = class.forname("scala.tuple" + seq.size) clz.getconstructors()(0).newinstance(seq.map(_.asinstanceof[anyref]): _*).asinstanceof[product] } vector.map(totuple).tolist but has restriction: max length of vectors 22.

java - Can not access Administrative Console -

good day, previously administrative console can access successfully. start today, not sure why can not access. i working on rad 8.5, right click on server, point administration , click on run administrative console . hit error follow: srve0255e: webgroup/virtual host handle /ibm/console has not been defined. srve0255e: webgroup/virtual host handle localhost:9060 has not been defined. ibm websphere application server my server working fine, because can start it, , browse app correctly, can log in , on. can not access administrative console. previously working fine, can not access. didnt change on also. kindly advise. i know post pretty old seems found better answer when stuck. the deployconsole.py script located in profile_root/bin directory. should used redeploy adminconsole . wsadmin.bat deployconsole.py install

oracle11g - How can I solve error 403 (Forbidden) after deploying ADF Application without any security configuration? -

friends, need help! i have server oracle linux 6.3. i read article install & configure weblogic server run adf 11g applications: http://www.oracle.com/webfolder/technetwork/jdeveloper/howto/11114/managedserver/wlsadfms.html everything ok. after that, on desktop created simple adf application on jdeveloper 11.1.1.7.0 article: http://infotechinspiration.blogspot.ru/2011/08/in-this-post-i-will-show-you-how-to.html this adf application deployed , run when using integrated weblogic server in jdeveloper. after deployed adf on standalone weblogic server: [11:04:06 am] ---- deployment started. ---- [11:04:06 am] target platform (weblogic 10.3). [11:04:11 am] retrieving existing application information [11:04:12 am] running dependency analysis... [11:04:12 am] building... [11:04:14 am] deploying 2 profiles... [11:04:14 am] wrote web application module c:\jdeveloper\mywork\myfirsadfpp\viewcontroller\deploy\myfirsadfpp_viewcontroller_webapp1.war [11:04:14 am] wrote enter

android - Mobile app. load testing using jmeter -

Image
i have configure , doing android app testing using jmeter. http request getting web services , jmeter puts load on those. correct mobile app load testing?? i recording scenario , putting load. if signup , login or action , creating web service request little bit confuse doing right app testing or not? is read testing of mobile app testing put load on web services only? please see attached screenshot of recent recorded plan.

java - spring and vaadin integration -

i'm trying implement application several ui s - vaadin, jsp , etc. it working simple jsp decided use vaadin ui. i've created vaadin servlet(and spring servlet left too). web.xml looks this <?xml version="1.0"?> <web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xsi:schemalocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" version="2.5"> <context-param> <param-name>contextconfiglocation</param-name> <param-value> classpath:/pmc-web-context.xml </param-value> </context-param> <listener> <listener-class>org.springframework.web.context.contextloaderlistener</listener-class> </listener> <servlet> <servlet-name>another-pmc-servlet</servlet-name>

java - Configuring priority in rabbitmq -

i have following configuration attempting change support priority queues. based on done research says should have 2 queues 1 each priority. adjusted configuration following: @configuration public class fixedreplyqueueconfig { @bean public connectionfactory rabbitconnectionfactory() { cachingconnectionfactory connectionfactory = new cachingconnectionfactory(); connectionfactory.sethost("localhost"); connectionfactory.setusername("urbanbuz"); connectionfactory.setpassword("ub"); connectionfactory.setvirtualhost("urbanbuzvhost"); return connectionfactory; } /** * @return rabbit template fixed reply queue. */ @bean public rabbittemplate fixedreplyqrabbittemplate() { rabbittemplate template = new rabbittemplate(rabbitconnectionfactory()); template.setexchange(ex().getname()); template.setroutingkey("test"); template.setreplyqueue(replyqueue()); return template; } /** * @return reply li

php - How to wrap html when running foreach loop -

i have loop below foreach( $b $entry) { $title2 = "<!doctype html> <meta content='text/html; charset=utf-8' http-equiv='content-type'> <head> <link rel='stylesheet' href='../../css/bootstrap.min.css'> </head> <body>"; $title2 .= "<div class='data'><div id=".$id."><span style='font-family: web'>".$entry->pubdate."&nbsp;&nbsp;</span><a href='../../fetch.php?url=".$id."' title='$entry->title' >" .$title. "</a><br/><div class='content'>".$description."</div></div></div>"; $title3 = "<!doctype html> <meta content='text/html; charset=utf-8' http-equiv='content-type'> <meta name='viewport' content='width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;

android - Duplicate value issue in MultiAutoCompleteTextView -

i new android development , using multiautocompletetextview in app , following code. public textview autoselected; string[] countries = {"india","usa","canada","indonesia","belgium", "france", "italy", "germany", "spain"}; @override protected void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); setcontentview(r.layout.activity_main); multiautocompletetextview autocompletetextview = (multiautocompletetextview)findviewbyid(r.id.autocompletetextview); arrayadapter<string> adapter = new arrayadapter<string>(this,android.r.layout.simple_dropdown_item_1line,countries); autocompletetextview.setadapter(adapter); autocompletetextview.settokenizer(new multiautocompletetextview.commatokenizer()); } first problem , main problem textview getting duplicate values means same country showing in textview again ,

Convert MD5 messageDigest from Java to Digest::MD5 Ruby -

i want use digest::md5 on ruby java code. java code: public static string md5encode(string input, string salt) { try { messagedigest messagedigest = messagedigest.getinstance("md5"); byte[] hash = null; try { messagedigest.update(salt.getbytes("utf-8")); messagedigest.update(input.getbytes("utf-8")); hash = messagedigest.digest(); } catch (unsupportedencodingexception exception) { logger.error("md5encoder:encode:" + exception.tostring()); } if (hash != null) { stringbuilder output = new stringbuilder(2 * hash.length); (byte b : hash) { output.append(string.format("%02x", b & 0xff)); } return output.tostring(); } } catch (nosuchalgorithmexception exception) { logger.er

How to solve php REDIRECTION ISSUE -

<?php /* subject , email varialbles*/ $emailsbuject = 'subscribe'; $webmaster = 'help@intaxfin.com'; $emailsbuject2 = 'thank you'; $client = ' $emailfeild\r\n'; /*gathering data variables*/ $emailfeild = $_post['email']; // admin message body $body= <<<eod our new subscriber $emailfeild email: $emailfeild eod; $textmessage = <<<eod thank subscribing us. possible. eod; $headers = "from: $emailfeild\r\n"; $header = "from: $noreply@example.com"; $success = mail($webmaster,$emailsbuject,$body,$headers); $success1 = @mail($emailfeild,$emailsbuject2,$textmessage,$header); /*result*/ $theresults = <<<eod eod; echo "$theresults"; header("location: http://www.example.com/"); exit; ?> i have lots of html pages under every page. have text box , button php script associated it. my problem whenever put email id , clicks button redirect

php - How to create a Symfony2 drop down form element from mongodb? -

i'm new mongodb , asking self how implement following: i have set of values, example names of persons, in drop down form element. these names loaded collection. if 1 ore more names selected drop down these names should saved in collection in array. don't want have relations between collection persons , other collection. in opinion similar star schema in sql world - without relations between tables. but until din't figure out how solve symfony2 , mongodb ... would happy if !

java - What is a global transaction? -

jsr 907 jta 1.2 defines "global transaction" term: the usertransaction.begin method starts global transaction , associates transaction calling thread. what mean? outermost transaction or what? basically difference between local transaction , global transaction resource bound. global transaction span multiple resources. local transaction limited 1 resource/datasource. e.g. in global transaction write db , send message on queue. this nicely explained here: http://integrationspot.blogspot.co.uk/2011/03/jta-transactions-local-and-global.html global transactions (xa) when managed data source configured global transactions, returns connections can participate in global transactions. global transaction (also called distributed transaction) enlists more 1 resource in transaction. global transactions provide ability work multiple transactional resources (typically relational databases , message queues).

vb.net - Fill a few Datatables with Tableadapter at one time fails -

i try fill few datatables same amount of tableadapter @ 1 time of datatables stay empty. codeexample: dim integer = 1 aaatableadapter.fillbycontractid(contractdataset.aaa, i) bbbtableadapter.fillbycontractid(contractdataset.bbb, i) ccctableadapter.fillbycontractid(contractdataset.ccc, i) dddtableadapter.fillbycontractid(contractdataset.ddd, i) eeetableadapter.fillbycontractid(contractdataset.eee, i) ffftableadapter.fillbycontractid(contractdataset.fff, i) gggtableadapter.fillbycontractid(contractdataset.ggg, i) example: datatables containing aaa, bbb, ccc , ddd filled rest of tables stay clear. if click on button performs code above, datatables filled after 2 attempts! i've allready used bindingsource.endedit method dosent worked out. problem occurs once. if datatables filled (after 2 attempts) , 'i' set @ runtime works fine. hope can me. i'm not able find solution 'small' problem.

logcat - Application loading slow and how to use strict mode in android -

i facing lots of message through strict mode in logcat . may reason if click next buttton on ui, takes long time 1 min. how occure this, data loading process fast. why got strict mode log? don't know. , finally, how use strict mode in 4.1.6 . meaning of developer_mode . , strictmode details , sample of logcat: 11-27 13:08:14.220: d/strictmode(11010): strictmode policy violation; ~duration=1492 ms: android.os.strictmode$strictmodediskreadviolation: policy=23 violation=2 11-27 13:08:14.220: d/strictmode(11010): @ android.os.strictmode$androidblockguardpolicy.onreadfromdisk(strictmode.java:1135) 11-27 13:08:14.220: d/strictmode(11010): @ android.database.sqlite.sqliteconnection.applyblockguardpolicy(sqliteconnection.java:1041) 11-27 13:08:14.220: d/strictmode(11010): @ android.database.sqlite.sqliteconnection.executeforlong(sqliteconnection.java:595) 11-27 13:08:14.220: d/strictmode(11010): @ android.database.sqlite.sqliteconnection.setforeignkeymodefromconfigur

event log - How can one query the Cluster .etl logs thru Powershell? -

server 2008 onward cluster log stored in 3 different .etl files @ "%windir%\system32\winevt\logs\" microsoft-windows-failoverclustering diagnostic.etl.001 microsoft-windows-failoverclustering diagnostic.etl.002 microsoft-windows-failoverclustering diagnostic.etl.003 however, can't query these files thru get-winevent get-winevent : c:\windows\system32\winevt\logs\microsoft-windows-failoverclustering%4diagnostic.etl.001 file not appear valid log file. specify .evtx, .etl, or .evt files values of path parameter. am missing something? there way of querying these .etl filesthru powershell? you can't read these files directly far know, have dump contents cluster.log file human readable output using get-clusterlog or cluster log /gen on 2008 systems: understanding cluster debug log in 2008

printing - Word 2010 prints document properties -

everytime print page or blank one, printer prints 3 pages. first page is: microsoft world - document1 nword.exe 6:291:87 27/2/4 the other 2 pages blank. has happened since few days. i checked in options->display->printdocumentsettings , it's unchecked! anyone have idea? it because of default template using. the default template named normal.dotm in word 2010 c:\users\<username>\appdata\roaming\microsoft\templates. the appdata folder hidden need show hidden files , folders in windows explorer in order see it. exit word. move normal.dotm other folder (save somewhere else). restart word - document should blank now.

visual studio 2012 - C problems with nested structs (looks like 1 instance is defined without explicit definitios) -

i've created struct: typedef struct { short s; int i; struct ss { short s; }; } s; and have error (vs2012): error c2020: 's' : 'struct' member redefinition i see name "s" used, in nested named struct, shouldn't problem. know in c11 intruduced anonymouds structs , unions in case not anonymous , have vs2012 not support c11. another interesting example is: typedef struct { short s; union u { int uu; }; struct s { short ss; }; union { int i; double d; }; } a; and interesting think that: in vs2008 sizeof(a) = 24, have 1 field defined. , when use code: a = {1, 2, 3, 4}; printf("a.s=%d a.uu=%d a.ss=%d a.i=%d \n", a.s, a.uu, a.ss, a.i); the output is: a.s=1 a.uu=2 a.ss=3 a.i=4 so question is: why that, correct behaviour? you first example not c because part struct ss{ short s }; doesn't declare name or no

xml - Selecting attributes of nodes using for-each in XSLT -

i have requirement need prepare xml list of questions , answer. 1 eform can have multiple documents. each document can have multiple questions. i have prepared 2 xml same. please suggest 1 approach. xml 1 <?xml version="1.0" encoding="utf-8"?> <eform> <documents> <document id="c7ba73bb-c096-4099-ad70-fd47d2320d00"> <questions> <question id="1a4eb1e0-f657-483e-a8fa-59e9002d7c3f" title="doc 1 - question 1 - paraghraph" answer="abc" /> <question id="d43fcf9d-91f6-43ce-b970-737aa0a51d36" title="doc 1 - question 2 - date" answer="2014-10-08t18:30:00z" /> </questions> </document> <document id="12d726d9-6e77-4657-ab8c-dddb7104a14a"> <questions> <question id="3a9d6172-90b6-420d-911a-43857e7c21a2" t

jquery on change at span id want to insert whole select box -

here example http://jsfiddle.net/4yp9k81w/9/ here html <span id="span_upper_level_name"> <select name="upper_level_id0" id="upper_level_id0" class="upper_level_id" > <option value="select1">select1</option> <option value="2">transport</option> </select> <select name="upper_level_id1" id="upper_level_id1" class="upper_level_id" > <option value="select2">select2</option> <option value="4">cars</option> </select> </span> <span id="span_position_after">position after</span> here jquery $('.upper_level_id').change(function(){ $('#span_position_after').html( $( '#upper_level_id0' ).html() ); }); if select box changes, want insert select box in span_position_after . but can insert words/options of select box (can not insert drop

Matlab making new cell array from another cell array fileds -

i have cell array thiscells : thiscells <1*40 cell> eacharray of thiscells 280*3 i have function ( thefunction ) gets input of cell array each array x*2 how can send cell array thefunction contain columns1,3 each array? i tried thefunction(thiscells{:}(:,1:2)) % tring send columns 1,2 but didn't work edit: working (but still looking faster way so): what did far thefunction(makingnewcells(thiscells,2)); when makingnewcells: [newcells]=makingnewcells(oldcells) ii=1:max(size(oldcells)) newcells=oldcells(:,[1 column]); end this question , answers may of - thiscells{:}(:,1:2) failing without call thefunction , if not mistaken. for cells, problem worse: add impossibility double-subref if did intended do, passes 40 arguments (which 280x2 vectors) thefunction . doubt there (m)any legitimate uses function takes 40 arguments of same type, instead of having wrapped in cell. try doc cellfun first. edit: clear, suggest changing thefunction a

sql - distinct on 4 billion records -

in teradata consider scenario have more 4 billion records in table , need execute distinct/group on column not part of primary or secondary index , not partitioned. now taking time. there other way of achieving this. this standalone environment , can not copy data , neither have access create new table in environment. select access have. if need number of unique values column help statistics {database}.{tablename} provide columns statistics , number of unique values. in teradata 14 or later, can perform show statistics values column {column} on {database}.{tablename}; command provide more details histograms including biased values column. biased values may encompass of unique values column or first few hundred. permissions on table may or may not permit this. if using statistics out of question because don't exist or don't have sufficient permissions going end scanning table. having statistics collected on column information result in full table scan. fin

android - Show multiple images in a imageView one after another with left to right flip effect repeatedly -

suppose have multiple images in drawable folder(ex-8 images). want show these images in imageview 1 after left right flip effect repeatedly( ex-img[0],img[1],……img[8],img[0],img[1],………… ). how can this? private void animateandslideshow() { image1 = (imageview)findviewbyid(r.id.imageview1); image1.setimageresource(img[currentimageindex1%img.length]); currentimageindex1++; animation rotateimage = animationutils.loadanimation(this, r.anim.custom_anim); image1.startanimation(rotateimage); } use custom function rotate image using handler interval change image,here change image vice verse direction : private imageview image1; private int[] imagearray; private int currentindex; private int startindex; private int endindex; @override public void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); setcontentview(r.layout.main); image1 = (imageview)findviewbyid(r.id.imageview1

Output of dist() with more than 3 dimensional matrix in R -

i'm new r. can't figure out meaning of dist() out. i understand following. because euclidean distance between (1,3) , (2,4) √2 > x = matrix(1:4, 2, 2) > x [,1] [,2] [1,] 1 3 [2,] 2 4 > dist(x) 1 2 1.414214 but how should see output more 3 dimensional matrix? > x=matrix(1:25, 5,5) > x [,1] [,2] [,3] [,4] [,5] [1,] 1 6 11 16 21 [2,] 2 7 12 17 22 [3,] 3 8 13 18 23 [4,] 4 9 14 19 24 [5,] 5 10 15 20 25 > dist(x) 1 2 3 4 2 2.236068 3 4.472136 2.236068 4 6.708204 4.472136 2.236068 5 8.944272 6.708204 4.472136 2.236068 the number in cell in column named "1" , row named "2" distance between first , second rows of data. so 2.236068 distance between vectors c(1,6,11,16,21) , c(2,7,12,17,22) (rows 1 , 2), 4.472136 distance between vectors c(1,6,11,16,21) , c(3,8,13,18,23) (rows 1 , 3) , on.

Asp.Net VNext Windows service -

i want try moving vnext asp.net mvc 3, used windows service project ( http://www.interworks.com/blogs/banderton/2009/10/30/long-running-tasks-aspnet ) doesn't seem work on vnext, because doesn't have proper system.servicemodel reference , cant add dll. there way around? recommend other ways run long tasks such big file import/calculations vnext? generally, no - not because of feature-set in asp.net vnext (it's been possible since .net 1.0) because of permissions: process needs run under high-privilege security context or able impersonate such user account in order control windows services. w3wp.exe (the application pool hosting process, , extension, application pool , applications within it) typically run under least-privilege user-account (often nt authority\network service or custom user account enough permissions write website's root directory, database server, , not else (in recent versions of windows further reduced concept of "service accoun

ember.js - Routine controller working but failing in test -

i'm building ember app ember-cli , reason mundane controller works @ runtime, fails when being run through tests following error: typeerror: cannot read property 'find' of null the controller nothing more than: export default ember.arraycontroller.extend({ exercisetemplates: null, setup: function() { this.set('exercisetemplates', this.get('store').find('exercise-template')); }.on('init'), }); any ideas? btw, here's stacktrace: typeerror: cannot read property 'find' of null @ eval [as setup] (trainer/controllers/workouts.js:11:54) @ sendevent (http://localhost:4200/assets/vendor.js:27786:27) @ new class (http://localhost:4200/assets/vendor.js:47448:9) @ function.mixin.create.create (http://localhost:4200/assets/vendor.js:47903:16) @ object.defaultsubject [as subject] (http://localhost:4200/assets/test-support.js:200:22) @ object.context.(anonymous function) [as subject

c# - Process.Start() significantly slower than executing in console -

i have performance problems executing .exe using process.start() . execution takes 5 times longer .net console. can cause this? here test program: public static void main(string[] argv) { (int = 0; < 10; i++) { processstartinfo psi = new processstartinfo(exepath, args); process ps = new process {startinfo = psi}; stopwatch sw = stopwatch.startnew(); ps.start(); ps.waitforexit(); sw.stop(); console.writeline(i+" elapsed time: " + sw.elapsedmilliseconds + "ms."); thread.sleep(1000); } } the result this: 0 elapsed time 4310ms. 1 elapsed time 4330ms. 2 elapsed time 4280ms. ... running in cmd window returns (sub 1 second execution). tried timing in console using > powershell measure-command { cmd /c start /wait %exe% %args% } which shows around 750ms execution, 5-6 times faster. not sure did right, 750ms feels execution time. at first reading std out ,

jquery - AJAX - Parsing JSON -

i attempting match id of table cell id specified within json file. if match found later description. everytime ran, skips straight error message. doing wrong? function getjson(showid){ $.ajax({ type: 'get', url:'json/tvshows.json', datatype: 'jsonp', success: function(data){ $.each(data, function(key,tvshow){ tvshow.description; var tvshowid = tvshow.id; if (tvshowid == showid) { var description = tvshow.description; console.log(description); } }) }, error:function(){ console.log('error occured in getdescription'); } }); //ends ajax request } you should using: datatype: 'json',

javascript - Getting HiddenField value upon clicking the button -

i want value of hiddenfield when clicking button but parentnode of button clicked. <div id="wrapper"> <div id="gameinfo"> <input type="text" id="gametitle" disabled="disabled" /> <input type="text" id="gametype" disabled="disabled" /> <input type="text" id="gameprice" disabled="disabled" /> <asp:hiddenfield runat="server" id="hiddenf"> <input type="button" id="button1" value="enable" onclick="myfunc(this)" /> </div> </div> so have javascript here when clicked button gets parent node of button , enables fields in parent div can see, way incorporate function? need able value in code behind once have retrieved value hidden field. function myfunc(elm){ for( var inputs = elm.parentnode.queryselectorall('input[type="text"

java - Parse date in String format to Gregorian Calendar, with hour and minute -

i'm trying parse input string date gregoriancalendar: scanner scan = new scanner(system.in); string next = scan.next("[0-9]{2}.[0-9]{2}.[0-9]{4} [0-9]{2}:[0-9]{2}"); scan.nextline(); dateformat df = new simpledateformat("dd.mm.yyyy hh:mm"); date date = null; try { date = df.parse(next); } catch (parseexception e1) { e1.printstacktrace(); } gregoriancalendar cal = new gregoriancalendar(); cal.settime(date); system.out.println(cal.gettime()); but keeps giving error: java.util.inputmismatchexception @ java.util.scanner.throwfor(unknown source) @ java.util.scanner.next(unknown source) @ java.util.scanner.next(unknown source) can me? works if don't specify hours , minutes not this... looking @ source code of scanner.next(pattern) , called scanner.next(string) , method roughly follows these steps: use delimiter pattern skips delimiters current position in stream. search next delimiter in stream. blocks if more input n

ios - Scroll content size not working in viewDidLayoutSubviews -

am using xib design view using auto layout.run time want change content size of scrollview in viewdidlayoutsubviews method not working.on orientation change code written inside viewdidlayoutsubviews works on load not working.please advice issue? - (void)viewdidlayoutsubviews { scroll.contentsize = cgsizemake(scroll.frame.size.width, attbtn.frame.origin.y+attbtn.frame.size.height+40);//atnbtn added programatically } usually when want have view redraw should call: [self setneedsdisplay: yes]; granted have never build on ios, on osx code works every time. also, example, if want delegate call redraw view named someview: [someview setneedsdisplay: yes];

javascript - D3 padding dates and values -

i building simple bar chart d3.time.scale: var data = [ {"date": new date("1992-05-01 00:00:00"), "value": 10}, {"date": new date("1997-05-01 00:00:00"), "value": 110}, {"date": new date("2007-05-11 00:00:00"), "value": 34} ]; var width = 300; var height = 200; var barwidth = width / data.length; var x_domain = d3.extent(data, function(d) { return d.date; }); var x = d3.time.scale() .domain(x_domain) .rangeround([0, width]); var y = d3.scale.linear() .domain([0, d3.max(data, function(d) { return d.value; })]) .range([height, 0]); var chart = d3.select(".chart") .attr("width", width ) .attr("height", height ) .append("g") .attr("transform", function(d, i) { return "translate("

Java applet not loading on Java8/HTTPS -

i hava java applet not run when using https. works fine when testing on localhost. working using test server using http. in production mode server using https issue raises. the 1 thing caught attention this: " http://www.example.com:443/ proxy=direct" why connection attempted establish http instead of https? http + port 443 seems not quite right there... has idea how can perhaps modify that? would pleased if point me right direction problem. console output: java plug-in 11.25.2.18 using jre version 1.8.0_25-b18 java hotspot(tm) client vm user home directory = d:\users\example ---------------------------------------------------- c: clear console window f: finalize objects on finalization queue g: garbage collect h: display message l: dump classloader list m: print memory usage o: trigger logging q: hide console r: reload policy configuration s: dump system , deployment properties t: dump thread list v: dump thread stack x: clear classload