Search Results

Search found 2 results on 1 pages for 'lewicki'.

Page 1/1 | 1 

  • Java - What methods to put in an interface and what to keep out

    - by lewicki
    I'm designing a file handler interface: public interface FileHandler { public void openFileHandler(String fileName); public void closeFileHandler(); public String readLine(); public String [] parseLine(String line); public String [] checkLine(String line[]); public void incrementLineCount(); public void incrementLineSuccessCount(); public void incrementLineErrorCount(); public int getLineCount(); public int getLineSuccessCount(); public int getLineErrorCount(); } It is soon apparent to me that these methods can't be made private. I don't want incrementLineCount to be public. What is proper way to design an interface like this?

    Read the article

  • Get a JQuery function to execute after and independently of onLoad

    - by lewicki
    Is is possible to execute a JQuery function by injecting it into the page? IT CAN'T be attached to the .ready function. The reason is that the user will be uploading an image via iframe. I need JCrop to execute after I display the uploaded image. echo "<script>$('#pictures_step1_right_bottom1', window.parent.document).html('<img id=\"cropbox\" src=\"../../box/" . 'THM' . $filenameAlt . '.jpg' . "\">');</script>"; echo "<script>jQuery(function(){jQuery('#cropbox').Jcrop();});</script>"; This is executed in the iframe that is processing the image. it then sends it to the main page. This does not work however. EDIT: Ended up running a timer: function checkPic() { if($('#cropbox1').length != 0) { jQuery(function() { jQuery('#cropbox1').Jcrop(); }); } timer(); // Check size again after 1 second } function timer(){ var myTimer = setTimeout('checkPic()', 3000); // Check size every 1 second}

    Read the article

1