Posts

jsf - JSF2.2 Annotated Validation not working -

i developing application using tomcat 7, jsf 2.2.6 (mojarra), hibernate validator 4.3.1 , have come across documented bug shown here: https://java.net/jira/browse/javaserverfaces-3183 . i have patched temporarily using fix given in answer on question: https://stackoverflow.com/a/21700488/1089995 , until such time 2.2.7 released publicly. however when attempt use annotations on fields, such @notnull, @size, etc, these ignored - there no relevant stack trace this, no error occurs , annotations ignored during validation phase. page.xhtml <input type="text" placeholder="e.g. joe bloggs" jsf:id="txtadminname" jsf:validator="#{bean.validateadminname}" jsf:value="#{bean.model.adminname}"/> model.java //model bean bean validation, not applied field. @size(min = 3, max = 50, message = "please enter between 3 , 50 characters.") private string adminname; bean.java //the model bean bean validation, shown below. ...

Neo4j embedded online backup using Java in Ubuntu -

i using neo4j(embedded) enterprise edition 1.8.3. tried online backup using code below def backup_data() { val backuppath: file = new file("d:/neo4j/data/backup/") val backup = onlinebackup.from( "127.0.0.1" ) if(backuppath.list().length > 0) { backup.incremental( backuppath.getpath(), false ) } else { backup.full( backuppath.getpath() ); } } the above code working fine in windows got error client not connect localhost/127.0.0.1:6362 same code in ubuntu. should change make work in ubuntu?

javascript - Leaflet.markercluster cluster added to DOM event -

i'm trying customize marker clusters appear pie charts, using chart.js library. i've overridden iconcreatefucntion additional calculations necessary , set data, transform icons actual charts, need call additional js when cluster icon added dom. how can hook leaflet.markercluster's "cluster icon added" event? ok, figured out. it's simple adding like: cluster.on 'add', (event) -> # stuff event.target, l.markerclustergroup instance to iconcreatefunction hope helps else out 1 day...

jquery - Issue in iterating the array in javascript -

i have array named a[] contains city_id , city name then doing edit , details such cityid , countryid ,etc and save in var b= cityid now cityname , appending field textbox i iterating array thru each function function f1() { jquery(a). each(function(m) { if(this.city_id(from array a) == cityid) if(c== "") { c += this.cityname; } else { c += ","+ this.cityname; } }); } c global var problem on click of edit c bombay , delhi , puna but again next time if click on radio button fetch details gets appended bombay , delhi , puna , chennai instead of clearing first one. try this.. here each obj in array. $.each( a, function( i, val ) { if(i.city_id== cityid) if(c== "") { c += this.cityname; } else { c += ","+ this.cityname; } });

c# - EventWaitHandle.Close() - what type of call this is sync or Async? -

i have eventwaithandle wait receive events. once, receive event. supposed release resources used eventwaithandle. releasing events using eventwaithandle.close(). my question after calling eventwaithandle.close(). should wait or sleep times release resources?

excel - Report generation based on multi lookup and dynamic columns -

i little stuck report trying generate in excel , hoping help. here summary of trying do: table 1 has 1 column called people (it’s list of employees) table 2 has 1 column called countries (it’s list of relevant countries) table 3 has 3 columns called person, country , date. there 1 entry every person each time review country. so data like: person | country | date john | uk | 10/01/2013 paul | uk | 15/01/2013 john | france | 15/01/2013 bob | spain | 16/01/2013 the report need produce 1 shows has/hasn't checked each country. columns ‘person’, uk, france, spain (and other unique value country table). there 1 single row each person yes/no value in relevant column if person has reviewed country i.e. table 3 contains value matches value person , country. so clear report should similar to: person | uk | france | spain john | yes ...

javascript - jQuery: How to toggle H1 tags at different time intervals? -

i need toggle 2 h1 tags. first 1 needs displayed 3 seconds on screen, , second needs displayed 8 seconds on screen. i need jquery solution. try code. html <h1> first h1 </h1> <h1> second h1 </h1> jquery <script type="text/javascript"> $(document).ready(function(){ //initially hide second h1 $("h1:nth-child(2)").hide(); function show_second_h1(){ $("h1:nth-child(1)").hide(); $("h1:nth-child(2)").show(); settimeout(show_first_h1,8000); } function show_first_h1(){ $("h1:nth-child(1)").show(); $("h1:nth-child(2)").hide(); settimeout(show_second_h1,3000); } settimeout(show_second_h1,3000); }); </script> it call show_first_h1() , show_second_h1() @ given time-interval 1 one show respective h1 tag. demo jsfiddle edit: if have control on html , can set id h1 following simplified code...