Search Results

Search found 5671 results on 227 pages for 'final'.

Page 8/227 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • Is it easy to update ubuntu beta to ubuntu final release?

    - by Peter Smit
    At this moment I am preparing a virtual server to host a web application which needs php5.3 The virtual server base image is always Hardy (8.04 LTS). There is no php5.3 until the upcoming release in a few days: Lucid (9.04 LTS). I am seeing to options: - waiting until the final version is released and then start preparing this server - Now upgrading to the beta (do-release-upgrade --devel-release) and when the final release has come upgrading to that For time constraints I would prefer the second option. I only can't find whether it will be easy to upgrade from a beta to the 'clean' final release. Is this possible in an easy way. Will it have any drawback for security or will there be any traces left of it being ever a beta release? Note: the server will not go into production before the LTS is really installed.

    Read the article

  • GPL question : web application using Imagick and GhostScript => Which would be the final licence?

    - by sdespont
    I am a bit confusing and I need your help to undertand my problem. I have developed a web application (PHP, JQuery) for one of my customer. Recently, my customer ask me to add a new feature permitting PDF to JPG conversion. After web browsing, I have discovered that iMagick (Apache licence) PHP extension with GhostScript (GPL licence) is the only solution. But, as my customer want to sell the web application to others companies, I have to use non-GPL licences. By the way, this feature is OPTIONAL and the final user must download and install manually iMagick and GhostScript if he his interesting by using the PDF conversion. Is there someone to tell me if the fact to use Imagick to convert PDF to JPG (and therefore use GhostScript) turns my current proprietary licence to GPL? And what about if I don't use Imagick but call GhostScript using PHP exec() function? Is there others non-GPL projects to convert PDF to JPG that I could use with PHP? Any help would be greatly appreciated.

    Read the article

  • How can one find software development work that involves directly the final end user?

    - by RJa
    I've worked in software development for 15 years and, while there have been signficant personal achievements and a lot of experience, I've always felt detached from the man/woman-on-the-street, the every day person, how it affects their lives, in a number of ways: the technologies: embedded software, hidden away, stuff not seen by the everyday person. Or process technology supporting manufactured products the size of the systems, meaning many jobs, divided up, work is abstract, not one person can see the whole picture the organisations: large, with departments dealing with different areas, the software, the hardware, the marketing, the sales, the customer support the locations and hours: out-of-town business parks away from the rest of society, fixed locations, inflexible: 9-5 everyday This to me seems typical of the companies I worked for and see elsewhere. Granted, there are positives such as the technology itself and usually being among high calibre co-workers, but the above points frustrate me about the industry because they detach the work from its meaning. How can one: change these things in an existing job, or compensate for them? find other work that avoids these and connects with the final end user? Job designs tend to focus on the job content and technical requirements rather than how the job aims to fulfil end user needs, is meaningful.

    Read the article

  • IOException during blocking network NIO in JDK 1.7

    - by Bass
    I'm just learning NIO, and here's the short example I've written to test how a blocking NIO can be interrupted: class TestBlockingNio { private static final boolean INTERRUPT_VIA_THREAD_INTERRUPT = true; /** * Prevent the socket from being GC'ed */ static Socket socket; private static SocketChannel connect(final int port) { while (true) { try { final SocketChannel channel = SocketChannel.open(new InetSocketAddress(port)); channel.configureBlocking(true); return channel; } catch (final IOException ioe) { try { Thread.sleep(1000); } catch (final InterruptedException ie) { } continue; } } } private static byte[] newBuffer(final int length) { final byte buffer[] = new byte[length]; for (int i = 0; i < length; i++) { buffer[i] = (byte) 'A'; } return buffer; } public static void main(final String args[]) throws IOException, InterruptedException { final int portNumber = 10000; new Thread("Reader") { public void run() { try { final ServerSocket serverSocket = new ServerSocket(portNumber); socket = serverSocket.accept(); /* * Fully ignore any input from the socket */ } catch (final IOException ioe) { ioe.printStackTrace(); } } }.start(); final SocketChannel channel = connect(portNumber); final Thread main = Thread.currentThread(); final Thread interruptor = new Thread("Inerruptor") { public void run() { System.out.println("Press Enter to interrupt I/O "); while (true) { try { System.in.read(); } catch (final IOException ioe) { ioe.printStackTrace(); } System.out.println("Interrupting..."); if (INTERRUPT_VIA_THREAD_INTERRUPT) { main.interrupt(); } else { try { channel.close(); } catch (final IOException ioe) { System.out.println(ioe.getMessage()); } } } } }; interruptor.setDaemon(true); interruptor.start(); final ByteBuffer buffer = ByteBuffer.allocate(32768); int i = 0; try { while (true) { buffer.clear(); buffer.put(newBuffer(buffer.capacity())); buffer.flip(); channel.write(buffer); System.out.print('X'); if (++i % 80 == 0) { System.out.println(); Thread.sleep(100); } } } catch (final ClosedByInterruptException cbie) { System.out.println("Closed via Thread.interrupt()"); } catch (final AsynchronousCloseException ace) { System.out.println("Closed via Channel.close()"); } } } In the above example, I'm writing to a SocketChannel, but noone is reading from the other side, so eventually the write operation hangs. This example works great when run by JDK-1.6, with the following output: Press Enter to interrupt I/O XXXX Interrupting... Closed via Thread.interrupt() — meaning that only 128k of data was written to the TCP socket's buffer. When run by JDK-1.7 (1.7.0_25-b15 and 1.7.0-u40-b37), however, the very same code bails out with an IOException: Press Enter to interrupt I/O XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXX Exception in thread "main" java.io.IOException: Broken pipe at sun.nio.ch.FileDispatcherImpl.write0(Native Method) at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:47) at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:93) at sun.nio.ch.IOUtil.write(IOUtil.java:65) at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:487) at com.example.TestBlockingNio.main(TestBlockingNio.java:109) Can anyone explain this different behaviour?

    Read the article

  • In ArrayBlockingQueue, why copy into ReentrantLock field into local final variable?

    - by mjlee
    In ArrayBlockingQueue, any method that requires lock will get set 'final' local variable before calling 'lock()'. public boolean offer(E e) { if (e == null) throw new NullPointerException(); final ReentrantLock lock = this.lock; lock.lock(); try { if (count == items.length) return false; else { insert(e); return true; } } finally { lock.unlock(); } } Is there any reason to set a local variable 'lock' from 'this.lock' when field 'this.lock' is final also. Additionally, it also set local variable of E[] before acting on. private E extract() { final E[] items = this.items; E x = items[takeIndex]; items[takeIndex] = null; takeIndex = inc(takeIndex); --count; notFull.signal(); return x; } Is there any reason for copying to local final variable?

    Read the article

  • Use CSS Selectors with HtmlUnit

    - by kerry
    HtmlUnit is a great library for performing web integration tests in Java.  But sometimes node traversal can be somewhat cumbersome. Fear not fellow automated tester (good for you!).  I found a great little project on Github that will allow you to query your document for elements via css selectors similar to jQuery. The project is located at https://github.com/chrsan/css-selectors.  You can use Maven to build it, or download 1.0.2 here.  Beware.  I will not be updating this link so I suggest you download the latest code. In any case, you can use it like so: // from HtmlUnit getting started final WebClient webClient = new WebClient(); final HtmlPage page = webClient.getPage("http://htmlunit.sourceforge.net"); final DOMNodeSelector cssSelector = new DOMNodeSelector(page.getDocumentElement()); final Set elements = cssSelector.querySelectorAll("div.section h2"); final Node first = elements.iterator().next(); assertThat(first.getTextContent(), equalTo("HtmlUnit")); The only problem here is that the querySelectAll returns a Set<Node>.  Not HtmlElement like we may want in some cases.   However, if you were to reflect on the Set, you would find that it is indeed a Set of HtmlElement objects. Typically, I like to create a base class for my web tests.  Just for fun, I am using the $ method similar to jQuery. public class WebTestBase { protected WebClient webClient; protected HtmlPage htmlPage; protected void goTo(final String url){ return (HtmlPage)webClient.getPage(url); } protected List $(final String cssSelector) { final DOMNodeSelector cssSelector = new DOMNodeSelector(htmlPage.getDocumentElement()); final Set nodes = cssSelector.querySelectorAll("div.section h2"); // for some reason Set cannot be cast to Set? final List elements = new ArrayList(nodes.size()); for (final Node node : nodes) { elements.add((HtmlElement)node); } return elements; } } Now we can write tests like this: public class LoginWebTest extends WebTestBase { @Test public void login_page_has_instructions() throws Exception { goTo(baseUrl + "/login") assertThat( $("p.instructions").size(), equalTo(1) ); } }

    Read the article

  • Do fields need to be explicitly final to have a "proper" immutable object?

    - by Yishai
    You often read about immutable objects requiring final fields to be immutable in Java. Is this in fact the case, or is it simply enough to have no public mutability and not actually mutate the state? For example, if you have an immutable object built by the builder pattern, you could do it by having the builder assign the individual fields as it builds, or having the builder hold the fields itself and ultimately return the immutable object by passing the values to its (private) constructor. Having the fields final has the obvious advantage of preventing implementation errors (such as allowing code to retain a reference to the builder and "building" the object multiple times while in fact mutating an existing object), but having the Builder store its data inside the object as it is built would seem to be DRYer. So the question is: Assuming the Builder does not leak the Object early and stops itself from modifying the object once built (say by setting its reference to the object as null) is there actually anything gained (such as improved thread safety) in the "immutability" of the object if the object's fields were made final instead?

    Read the article

  • Detect multitouch (two fingers touch) on a sprite to apply pinch zoom behaviour

    - by Tahreem
    I am using andengine, want to move, zoom and rotate multiple sprites individually on a scene. I have achieved "move" but for pinch zoom i am unable to get the event to two fingers' touch. Below is the code: public class Main extends SimpleBaseGameActivity { private Camera camera; private BitmapTextureAtlas mBitmapTextureAtlas; private ITextureRegion mFaceTextureRegion; private ITextureRegion mFaceTextureRegion2; Sprite face2; private static final int CAMERA_WIDTH = 800; private static final int CAMERA_HEIGHT = 480; @Override public EngineOptions onCreateEngineOptions() { camera = new Camera(0, 0, CAMERA_WIDTH, CAMERA_HEIGHT); EngineOptions engineOptions = new EngineOptions(true, ScreenOrientation.LANDSCAPE_FIXED, new RatioResolutionPolicy( CAMERA_WIDTH, CAMERA_HEIGHT), camera); return engineOptions; } @Override protected void onCreateResources() { BitmapTextureAtlasTextureRegionFactory.setAssetBasePath("gfx/"); this.mBitmapTextureAtlas = new BitmapTextureAtlas( this.getTextureManager(), 1024, 1600, TextureOptions.NEAREST); BitmapTextureAtlasTextureRegionFactory.createTiledFromAsset(this.mBitmapTextureAtlas, // this, "ui_ball_1.png", 0, 0, 1, 1), // this.getVertexBufferObjectManager()); this.mFaceTextureRegion = BitmapTextureAtlasTextureRegionFactory .createFromAsset(this.mBitmapTextureAtlas, this, "ui_ball_1.png", 0, 0); this.mFaceTextureRegion2 = BitmapTextureAtlasTextureRegionFactory .createFromAsset(this.mBitmapTextureAtlas, this, "ui_ball_1.png", 0, 0); this.mBitmapTextureAtlas.load(); this.mEngine.getTextureManager().loadTexture(this.mBitmapTextureAtlas); } @Override protected Scene onCreateScene() { this.mEngine.registerUpdateHandler(new FPSLogger()); final Scene scene = new Scene(); scene.setBackground(new Background(0.09804f, 0.6274f, 0.8784f)); final float centerX = (CAMERA_WIDTH - this.mFaceTextureRegion .getWidth()) / 2; final float centerY = (CAMERA_HEIGHT - this.mFaceTextureRegion .getHeight()) / 2; final Sprite face = new Sprite(centerX, centerY, this.mFaceTextureRegion, this.getVertexBufferObjectManager()) { @Override public boolean onAreaTouched(final TouchEvent pSceneTouchEvent, final float pTouchAreaLocalX, final float pTouchAreaLocalY) { this.setPosition(pSceneTouchEvent.getX() - this.getWidth() / 2, pSceneTouchEvent.getY() - this.getHeight() / 2); return true; } }; face.setScale(2); scene.attachChild(face); scene.registerTouchArea(face); face2 = new Sprite(200, 200, this.mFaceTextureRegion2, this.getVertexBufferObjectManager()) { @Override public boolean onAreaTouched(final TouchEvent pSceneTouchEvent, final float pTouchAreaLocalX, final float pTouchAreaLocalY) { switch(pSceneTouchEvent.getAction()){ case TouchEvent.ACTION_DOWN: int count = pSceneTouchEvent.getMotionEvent().getPointerCount() ; for(int i= 0; i <count; i++) { int id = pSceneTouchEvent.getMotionEvent().getPointerId(i); } break; case TouchEvent.ACTION_MOVE: this.setPosition(pSceneTouchEvent.getX() -this.getWidth() / 2, pSceneTouchEvent.getY()-this.getHeight() / 2); break; case TouchEvent.ACTION_UP: break; } return true; } }; face2.setScale(2); scene.attachChild(face2); scene.registerTouchArea(face2); scene.setTouchAreaBindingOnActionDownEnabled(true); return scene; } } This line int count = pSceneTouchEvent.getMotionEvent().getPointerCount() ; should set 2 to the count variable if i touch the sprite with to fingers, then i can apply zooming functionality (setScale method) on the sprite by getting the distance between the coordinates of two fingers. Can anyone help me? why it does not detect two fingers? and without this how can i zoom the sprite on pinch of two fingers? I am very new to game development, any help would be appreciated. Thanks in advance.

    Read the article

  • Extra Life 2012 - The Final Plea ... Until the Next One

    - by Chris Gardner
    I thought I'd share the email stream that my friends and family get about the event.So, here we are again. We scream closer to the event, and the goal is not met.I was approached by the ghost of feral platypii past last night. Well, approached is putting it lightly. I was mugged by the ghost of platypii past last night. He reminded me, in no uncertain terms that I have only reached the midway point of my fundraising goal. He then reminded me, in even less uncertain terms, that we are one week away from the event. There were other reminders past that, but this is a family broadcast. *shudder*Now, let us be serious for a moment. The event organizers claim a personal story helps to tug heart strings, whatever those are...I've been to Children's Hospital of Birmingham. I had to take Spawn, the Latter, there to verify she was not going to die. Instead, she's just a ticking time bomb for the next generation, but I digress.While I was there, I saw things. I saw child after child after child waiting for their appointment. I saw the most sublime displays of children's art juxtaposed with hospital sterilization that I could ever possibly imagine. I saw and heard things that only occur in the nightmares of parents, and I was only in the waiting rooms.But I will never forget the 10-ish year old girl that came in for her regularly scheduled dialysis appointment ... as if it was just another Friday afternoon. She had her school books, a little snack, a book to read for pleasure, and a DVD, in case she finished her homework a little early. You know, everything you'd need for an afternoon hooked up to a huge medical machine that going to clean out all the toxins in your blood. As she entered the secured area, she warmly greeted all the doctors and nurses with the same familiarity that I would greet the staff of my favorite coffee shop as I stopped in for my morning cup of coffee.I don't know the status of that little girl. I don't know if she's healthy or, quite frankly, alive. I don't even know her name, as I only heard it in passing for the 37 seconds our paths crossed. However, I do remember being incredibly moved and touched by her upbeat attitude about the situations, and I hope that my efforts last two Octobers got her, in some way, a little comfort.And, if she is still with us, I hope we can get her a little more.=== PREVIOUS MESSAGE FOLLOWS ===Greetings (Again),If you are receiving this updated message, then you didn't feel generous the first time. Now, I tried to be nice the first time. I tried to send a simple, unobtrusive email message to get you into the spirit. Well, much like the bell ringers that I ignore in front of the Wal-Mart, you ignored me.I probably should have seen that coming...However, unlike those poor souls, I know how to contact you. And I can find out where you live. So, so, so, you better feel lucky that I'm too lazy to terrorize you people, but cause I could do it.Remember, it's not for me, it's for those poor kids... and the feral platypii.  Because, we can make more children, but platypii are hard to come by.=== ORIGINAL MESSAGE FOLLOWS ===It's that time of year again. The time when I beg you for money for charity. See, unlike those bell ringers outside Wal-Mart, I don't do it when you have ten bazillion holiday obligations...Once again, I will be enduring a 24-hour marathon of gaming to raise money for Children Hospital in Birmingham. All the money goes straight to them, and you get to tell Uncie Samuel that you're good for that money. I'd REALLY like to break $1000 this year, as I have come REALLY close for the past 2 year to doing so.This year, the event will take place on October 20th, beginning at 8 A.M. Once again, I will try to provide some web streams, etc, if you want to point and laugh (especially if I have to result to playing Dance Central at 4 AM to stay awake for the last part.)Look at it this way, I'm going to badger you about this for the next month. You might as well donate some money so you can righteously tell me to shut the Smurf up.You can place your bid at the link below. Feel free to spread the word to anyone and everyone.I thank you. The children thank you. Several breeds of feral platypus thank you. Maybe, just maybe, doing so will help you feel the love felt by re-fried beans when lovingly hugged in a warm tortilla.Enjoy your burrito.http://www.extra-life.org/participant/cgardner

    Read the article

  • Does the method of adjustment matter, or just the final calibration?

    - by Steve
    A company produces software (and hardware) that is used to both perform automatic adjustments on electronic test equipment as well as perform calibrations of the same equipment. The results of the calibrations are put onto a certificate of calibration that is sent to the customer along with the equipment. This calibration certificate states various conditions of the calibration, such as what hardware (models/serial numbers) and software (version) was used to perform the calibration, as well as things like environmental conditions, etc. Making the assumption that the software used to produce the data (and listed on the calibration certificate) used on the certificate of calibration must have gone through a "test/release" process and must be considered "released" software - does this also mean that the software used for adjustment must also be released? I believe that the method (software/environmental conditions/etc) used or present during adjustment doesn't matter, all that really matters is the end result of the calibration, the conditions present during the calibration, and whether or not the equipment was within the specifications. The real question I'm hoping to get answered: Is there a reputable source (e.g. NIST or somewhere similar) that addresses this question? (I have searched...) The thinking is that during high volume production runs, the "unreleased" system can be used to perform adjustments, as long as a released system is used to perform the calibrations, since the time required to perform the adjustments is much longer than the calibration. This unreleased system will eventually become released for use, but currently is not. Also, please not that there is a distinction between "adjustment" and "calibration". The definition from BIPM International vocabulary of metrology, 2.39: Operation that, under specified conditions, in a first step, establishes a relation between the quantity values with measurement uncertainties provided by measurement standards and corresponding indications with associated measurement uncertainties (of the calibrated instrument or secondary standard) and, in a second step, uses this information to establish a relation for obtaining a measurement result from an indication. Followed by NOTE 2 (emphasis in original text): Calibration should not be confused with adjustment of a measuring system, often mistakenly called "self-calibration", nor with verification of calibration As a side note, I'm not sure why this got down voted. It's regarding software and it's use before and after release for use. I believe there is a best practice that can be applied and this is (hopefully) not primarily opinion based.

    Read the article

  • java.lang.NoSuchMethodError: javax.persistence.OneToMany.orphanRemoval()Z

    - by Panayiotis Karabassis
    I am getting this error: java.lang.NoSuchMethodError: javax.persistence.OneToMany.orphanRemoval()Z These are the jars in my classpath: com.sun.faces/jsf-api/jars/jsf-api-2.0.0.jar com.sun.faces/jsf-impl/jars/jsf-impl-2.0.0.jar org.apache.myfaces.orchestra/myfaces-orchestra-core20/jars/myfaces-orchestra-core20-1.5-SNAPSHOT.jar commons-lang/commons-lang/jars/commons-lang-2.1.jar commons-logging/commons-logging/jars/commons-logging-1.1.1.jar org.springframework/spring/jars/spring-2.5.6.jar commons-el/commons-el/jars/commons-el-1.0.jar org.richfaces.ui/richfaces-ui/jars/richfaces-ui-3.3.3.Final.jar org.richfaces.framework/richfaces-api/jars/richfaces-api-3.3.3.Final.jar commons-collections/commons-collections/jars/commons-collections-3.2.jar commons-beanutils/commons-beanutils/jars/commons-beanutils-1.8.0.jar org.richfaces.framework/richfaces-impl-jsf2/jars/richfaces-impl-jsf2-3.3.3.Final.jar com.sun.facelets/jsf-facelets/jars/jsf-facelets-1.1.14.jar org.hibernate/hibernate-core/jars/hibernate-core-3.6.0.Final.jar antlr/antlr/jars/antlr-2.7.6.jar dom4j/dom4j/jars/dom4j-1.6.1.jar org.hibernate/hibernate-commons-annotations/jars/hibernate-commons-annotations-3.2.0.Final.jar org.slf4j/slf4j-api/jars/slf4j-api-1.6.1.jar org.hibernate.javax.persistence/hibernate-jpa-2.0-api/jars/hibernate-jpa-2.0-api-1.0.0.Final.jar javax.transaction/jta/jars/jta-1.1.jar org.hibernate/hibernate-c3p0/jars/hibernate-c3p0-3.6.0.Final.jar c3p0/c3p0/jars/c3p0-0.9.1.jar org.hibernate/hibernate-entitymanager/jars/hibernate-entitymanager-3.6.0.Final.jar cglib/cglib/jars/cglib-2.2.jar asm/asm/jars/asm-3.1.jar javassist/javassist/jars/javassist-3.12.0.GA.jar org.hibernate/hibernate-search/jars/hibernate-search-3.3.0.Final.jar org.hibernate/hibernate-search-analyzers/jars/hibernate-search-analyzers-3.3.0.Final.jar org.apache.lucene/lucene-core/jars/lucene-core-3.0.3.jar org.apache.lucene/lucene-analyzers/jars/lucene-analyzers-3.0.3.jar mysql/mysql-connector-java/jars/mysql-connector-java-5.1.13.jar com.ocpsoft/prettyfaces-jsf2/jars/prettyfaces-jsf2-3.0.1.jar commons-digester/commons-digester/jars/commons-digester-2.0.jar org.slf4j/slf4j-log4j12/jars/slf4j-log4j12-1.6.1.jar log4j/log4j/bundles/log4j-1.2.16.jar xom/xom/jars/xom-1.2.5.jar xml-apis/xml-apis/jars/xml-apis-1.3.03.jar xerces/xercesImpl/jars/xercesImpl-2.8.0.jar xalan/xalan/jars/xalan-2.7.0.jar org.jboss.jsfunit/jboss-jsfunit-core/jars/jboss-jsfunit-core-1.3.0.Final.jar net.sourceforge.htmlunit/htmlunit/jars/htmlunit-2.8.jar xalan/xalan/jars/xalan-2.7.1.jar xalan/serializer/jars/serializer-2.7.1.jar xml-apis/xml-apis/jars/xml-apis-1.3.04.jar commons-collections/commons-collections/jars/commons-collections-3.2.1.jar commons-lang/commons-lang/jars/commons-lang-2.4.jar org.apache.httpcomponents/httpclient/jars/httpclient-4.0.1.jar org.apache.httpcomponents/httpcore/jars/httpcore-4.0.1.jar commons-codec/commons-codec/jars/commons-codec-1.4.jar org.apache.httpcomponents/httpmime/jars/httpmime-4.0.1.jar org.apache.james/apache-mime4j/jars/apache-mime4j-0.6.jar net.sourceforge.htmlunit/htmlunit-core-js/jars/htmlunit-core-js-2.8.jar xerces/xercesImpl/jars/xercesImpl-2.9.1.jar net.sourceforge.nekohtml/nekohtml/jars/nekohtml-1.9.14.jar net.sourceforge.cssparser/cssparser/jars/cssparser-0.9.5.jar org.w3c.css/sac/jars/sac-1.3.jar commons-io/commons-io/jars/commons-io-1.4.jar cactus/cactus/jars/cactus-13-1.7.1.jar cactus/cactus-ant/jars/cactus-ant-13-1.7.1.jar commons-httpclient/commons-httpclient/jars/commons-httpclient-2.0.2.jar junit/junit/jars/junit-3.8.1.jar aspectj/aspectjrt/jars/aspectjrt-1.2.1.jar cargo/cargo/jars/cargo-0.5.jar ant/ant/jars/ant-1.5.4.jar and this is my ivy.xml: <dependencies> <!-- JSF 2.0 RI --> <dependency org="com.sun.faces" name="jsf-api" rev="2.0.0"/> <dependency org="com.sun.faces" name="jsf-impl" rev="2.0.0"/> <!-- MyFaces Orchestra --> <dependency org="org.apache.myfaces.orchestra" name="myfaces-orchestra-core20" rev="1.5-SNAPSHOT"/> <dependency org="org.springframework" name="spring" rev="2.5.6"/> <dependency org="commons-el" name="commons-el" rev="1.0"/> <!-- RichFaces --> <dependency org="org.richfaces.ui" name="richfaces-ui" rev="3.3.3.Final"/> <dependency org="org.richfaces.framework" name="richfaces-impl-jsf2" rev="3.3.3.Final"/> <dependency org="com.sun.facelets" name="jsf-facelets" rev="1.1.14"/> <!-- Hibernate --> <dependency org="org.hibernate" name="hibernate-core" rev="3.6.0.Final"/> <dependency org="org.hibernate" name="hibernate-c3p0" rev="3.6.0.Final"/> <dependency org="org.hibernate" name="hibernate-entitymanager" rev="3.6.0.Final"/> <dependency org="org.hibernate" name="hibernate-search" rev="3.3.0.Final"/> <dependency org="mysql" name="mysql-connector-java" rev="5.1.13"/> <!-- PrettyFaces --> <dependency org="com.ocpsoft" name="prettyfaces-jsf2" rev="3.0.1"/> <!-- SLF4J --> <dependency org="org.slf4j" name="slf4j-api" rev="1.6.1"/> <dependency org="org.slf4j" name="slf4j-log4j12" rev="1.6.1"/> <!-- XOM --> <dependency org="xom" name="xom" rev="1.2.5"/> <!-- JSF Unit --> <dependency org="org.jboss.jsfunit" name="jboss-jsfunit-core" rev="1.3.0.Final" conf="development"/> </dependencies> I am deploying to tomcat 6.0 Update After the answer below, I solved this by adding the following dependency to my ivy.xml: <dependency org="org.hibernate.javax.persistence" name="hibernate-jpa-2.0-api" rev="1.0.0.Final"/> then putting this jar above everything else under Eclipse's build order tab. I was using JRE/JDK 6.

    Read the article

  • java.lang.NoSuchMethodError: javax.persistence.OneToMany.orphanRemoval()Z

    - by Panayiotis Karabassis
    I am getting this error: java.lang.NoSuchMethodError: javax.persistence.OneToMany.orphanRemoval()Z These are the jars in my classpath: com.sun.faces/jsf-api/jars/jsf-api-2.0.0.jar com.sun.faces/jsf-impl/jars/jsf-impl-2.0.0.jar org.apache.myfaces.orchestra/myfaces-orchestra-core20/jars/myfaces-orchestra-core20-1.5-SNAPSHOT.jar commons-lang/commons-lang/jars/commons-lang-2.1.jar commons-logging/commons-logging/jars/commons-logging-1.1.1.jar org.springframework/spring/jars/spring-2.5.6.jar commons-el/commons-el/jars/commons-el-1.0.jar org.richfaces.ui/richfaces-ui/jars/richfaces-ui-3.3.3.Final.jar org.richfaces.framework/richfaces-api/jars/richfaces-api-3.3.3.Final.jar commons-collections/commons-collections/jars/commons-collections-3.2.jar commons-beanutils/commons-beanutils/jars/commons-beanutils-1.8.0.jar org.richfaces.framework/richfaces-impl-jsf2/jars/richfaces-impl-jsf2-3.3.3.Final.jar com.sun.facelets/jsf-facelets/jars/jsf-facelets-1.1.14.jar org.hibernate/hibernate-core/jars/hibernate-core-3.6.0.Final.jar antlr/antlr/jars/antlr-2.7.6.jar dom4j/dom4j/jars/dom4j-1.6.1.jar org.hibernate/hibernate-commons-annotations/jars/hibernate-commons-annotations-3.2.0.Final.jar org.slf4j/slf4j-api/jars/slf4j-api-1.6.1.jar org.hibernate.javax.persistence/hibernate-jpa-2.0-api/jars/hibernate-jpa-2.0-api-1.0.0.Final.jar javax.transaction/jta/jars/jta-1.1.jar org.hibernate/hibernate-c3p0/jars/hibernate-c3p0-3.6.0.Final.jar c3p0/c3p0/jars/c3p0-0.9.1.jar org.hibernate/hibernate-entitymanager/jars/hibernate-entitymanager-3.6.0.Final.jar cglib/cglib/jars/cglib-2.2.jar asm/asm/jars/asm-3.1.jar javassist/javassist/jars/javassist-3.12.0.GA.jar org.hibernate/hibernate-search/jars/hibernate-search-3.3.0.Final.jar org.hibernate/hibernate-search-analyzers/jars/hibernate-search-analyzers-3.3.0.Final.jar org.apache.lucene/lucene-core/jars/lucene-core-3.0.3.jar org.apache.lucene/lucene-analyzers/jars/lucene-analyzers-3.0.3.jar mysql/mysql-connector-java/jars/mysql-connector-java-5.1.13.jar com.ocpsoft/prettyfaces-jsf2/jars/prettyfaces-jsf2-3.0.1.jar commons-digester/commons-digester/jars/commons-digester-2.0.jar org.slf4j/slf4j-log4j12/jars/slf4j-log4j12-1.6.1.jar log4j/log4j/bundles/log4j-1.2.16.jar xom/xom/jars/xom-1.2.5.jar xml-apis/xml-apis/jars/xml-apis-1.3.03.jar xerces/xercesImpl/jars/xercesImpl-2.8.0.jar xalan/xalan/jars/xalan-2.7.0.jar org.jboss.jsfunit/jboss-jsfunit-core/jars/jboss-jsfunit-core-1.3.0.Final.jar net.sourceforge.htmlunit/htmlunit/jars/htmlunit-2.8.jar xalan/xalan/jars/xalan-2.7.1.jar xalan/serializer/jars/serializer-2.7.1.jar xml-apis/xml-apis/jars/xml-apis-1.3.04.jar commons-collections/commons-collections/jars/commons-collections-3.2.1.jar commons-lang/commons-lang/jars/commons-lang-2.4.jar org.apache.httpcomponents/httpclient/jars/httpclient-4.0.1.jar org.apache.httpcomponents/httpcore/jars/httpcore-4.0.1.jar commons-codec/commons-codec/jars/commons-codec-1.4.jar org.apache.httpcomponents/httpmime/jars/httpmime-4.0.1.jar org.apache.james/apache-mime4j/jars/apache-mime4j-0.6.jar net.sourceforge.htmlunit/htmlunit-core-js/jars/htmlunit-core-js-2.8.jar xerces/xercesImpl/jars/xercesImpl-2.9.1.jar net.sourceforge.nekohtml/nekohtml/jars/nekohtml-1.9.14.jar net.sourceforge.cssparser/cssparser/jars/cssparser-0.9.5.jar org.w3c.css/sac/jars/sac-1.3.jar commons-io/commons-io/jars/commons-io-1.4.jar cactus/cactus/jars/cactus-13-1.7.1.jar cactus/cactus-ant/jars/cactus-ant-13-1.7.1.jar commons-httpclient/commons-httpclient/jars/commons-httpclient-2.0.2.jar junit/junit/jars/junit-3.8.1.jar aspectj/aspectjrt/jars/aspectjrt-1.2.1.jar cargo/cargo/jars/cargo-0.5.jar ant/ant/jars/ant-1.5.4.jar and this is my ivy.xml: <dependencies> <!-- JSF 2.0 RI --> <dependency org="com.sun.faces" name="jsf-api" rev="2.0.0"/> <dependency org="com.sun.faces" name="jsf-impl" rev="2.0.0"/> <!-- MyFaces Orchestra --> <dependency org="org.apache.myfaces.orchestra" name="myfaces-orchestra-core20" rev="1.5-SNAPSHOT"/> <dependency org="org.springframework" name="spring" rev="2.5.6"/> <dependency org="commons-el" name="commons-el" rev="1.0"/> <!-- RichFaces --> <dependency org="org.richfaces.ui" name="richfaces-ui" rev="3.3.3.Final"/> <dependency org="org.richfaces.framework" name="richfaces-impl-jsf2" rev="3.3.3.Final"/> <dependency org="com.sun.facelets" name="jsf-facelets" rev="1.1.14"/> <!-- Hibernate --> <dependency org="org.hibernate" name="hibernate-core" rev="3.6.0.Final"/> <dependency org="org.hibernate" name="hibernate-c3p0" rev="3.6.0.Final"/> <dependency org="org.hibernate" name="hibernate-entitymanager" rev="3.6.0.Final"/> <dependency org="org.hibernate" name="hibernate-search" rev="3.3.0.Final"/> <dependency org="mysql" name="mysql-connector-java" rev="5.1.13"/> <!-- PrettyFaces --> <dependency org="com.ocpsoft" name="prettyfaces-jsf2" rev="3.0.1"/> <!-- SLF4J --> <dependency org="org.slf4j" name="slf4j-api" rev="1.6.1"/> <dependency org="org.slf4j" name="slf4j-log4j12" rev="1.6.1"/> <!-- XOM --> <dependency org="xom" name="xom" rev="1.2.5"/> <!-- JSF Unit --> <dependency org="org.jboss.jsfunit" name="jboss-jsfunit-core" rev="1.3.0.Final" conf="development"/> </dependencies> I am deploying to tomcat 6.0 Update After the answer below, I solved this by adding the following dependency to my ivy.xml: <dependency org="org.hibernate.javax.persistence" name="hibernate-jpa-2.0-api" rev="1.0.0.Final"/> then putting this jar above everything else under Eclipse's build order tab. I was using JRE/JDK 6.

    Read the article

  • How do I fix cfdisk error: "Partition ends in final partial cylinder"?

    - by Laurens
    The problem I want to install Arch Linux on my desktop, it is going to be a dual boot with Windows. I booted into the installation CD, but when I started cfdisk to partition my hard drive it gave me the following error: FATAL ERROR: Primairy parititon 1, partition ends in the final partial cylinder. The Question How can I troubleshoot and fix this? Additional details These will be added if asked for.

    Read the article

  • Using nested public classes to organize constants

    - by FrustratedWithFormsDesigner
    I'm working on an application with many constants. At the last code review it came up that the constants are too scattered and should all be organized into a single "master" constants file. The disagreement is about how to organize them. The majority feel that using the constant name should be good enough, but this will lead to code that looks like this: public static final String CREDITCARD_ACTION_SUBMITDATA = "6767"; public static final String CREDITCARD_UIFIELDID_CARDHOLDER_NAME = "3959854"; public static final String CREDITCARD_UIFIELDID_EXPIRY_MONTH = "3524"; public static final String CREDITCARD_UIFIELDID_ACCOUNT_ID = "3524"; ... public static final String BANKPAYMENT_UIFIELDID_ACCOUNT_ID = "9987"; I find this type of naming convention to be cumbersome. I thought it might be easier to use public nested class, and have something like this: public class IntegrationSystemConstants { public class CreditCard { public static final String UI_EXPIRY_MONTH = "3524"; public static final String UI_ACCOUNT_ID = "3524"; ... } public class BankAccount { public static final String UI_ACCOUNT_ID = "9987"; ... } } This idea wasn't well received because it was "too complicated" (I didn't get much detail as to why this might be too complicated). I think this creates a better division between groups of related constants and the auto-complete makes it easier to find these as well. I've never seen this done though, so I'm wondering if this is an accepted practice or if there's better reasons that it shouldn't be done.

    Read the article

  • Using reflection to change static final File.separatorChar for unit testing?

    - by Stefan Kendall
    Specifically, I'm trying to create a unit test for a method which requires uses File.separatorChar to build paths on windows and unix. The code must run on both platforms, and yet I get errors with JUnit when I attempt to change this static final field. Anyone have any idea what's going on? Field field = java.io.File.class.getDeclaredField( "separatorChar" ); field.setAccessible(true); field.setChar(java.io.File.class,'/'); When I do this, I get IllegalAccessException: Can not set static final char field java.io.File.separatorChar to java.lang.Character Thoughts?

    Read the article

  • Returning an anonymous class that uses a final primitive. How does it work?

    - by Tim P
    Hi, I was wondering if someone could explain how the following code works: public interface Result { public int getCount(); public List<Thing> getThings(); } class SomeClass { ... public Result getThingResult() { final List<Thing> things = .. populated from something. final int count = 5; return new Result { @Override public int getCount() { return count; } @Override public List<Thing> getThings(); return things; } } } ... } Where do the primitive int , List reference and List instance get stored in memory? It can't be on the stack.. so where? Is there a difference between how references and primitives are handled in this situation? Thanks a bunch, Tim P.

    Read the article

  • Android: database reading problem throws exception

    - by Vamsi
    Hi, i am having this problem with the android database. I adopted the DBAdapter file the NotepadAdv3 example from the google android page. DBAdapter.java public class DBAdapter { private static final String TAG = "DBAdapter"; private static final String DATABASE_NAME = "PasswordDb"; private static final String DATABASE_TABLE = "myuserdata"; private static final String DATABASE_USERKEY = "myuserkey"; private static final int DATABASE_VERSION = 2; public static final String KEY_USERKEY = "userkey"; public static final String KEY_TITLE = "title"; public static final String KEY_DATA = "data"; public static final String KEY_ROWID = "_id"; private final Context mContext; private DatabaseHelper mDbHelper; private SQLiteDatabase mDb; private static final String DB_CREATE_KEY = "create table " + DATABASE_USERKEY + " (" + "userkey text not null" +");"; private static final String DB_CREATE_DATA = "create table " + DATABASE_TABLE + " (" + "_id integer primary key autoincrement, " + "title text not null" + "data text" +");"; private static class DatabaseHelper extends SQLiteOpenHelper { DatabaseHelper(Context context) { super(context, DATABASE_NAME, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { db.execSQL(DB_CREATE_KEY); db.execSQL(DB_CREATE_DATA); } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { Log.w(TAG, "Upgrading database from version " + oldVersion + " to " + newVersion + ", which will destroy all old data"); db.execSQL("DROP TABLE IF EXISTS myuserkey"); db.execSQL("DROP TABLE IF EXISTS myuserdata"); onCreate(db); } } public DBAdapter(Context ctx) { this.mContext = ctx; } public DBAdapter Open() throws SQLException{ try { mDbHelper = new DatabaseHelper(mContext); } catch(Exception e){ Log.e(TAG, e.toString()); } mDb = mDbHelper.getWritableDatabase(); return this; } public void close(){ mDbHelper.close(); } public Long storeKey(String userKey){ ContentValues initialValues = new ContentValues(); initialValues.put(KEY_USERKEY, userKey); try { mDb.delete(DATABASE_USERKEY, "1=1", null); } catch(Exception e) { Log.e(TAG, e.toString()); } return mDb.insert(DATABASE_USERKEY, null, initialValues); } public String retrieveKey() { final Cursor c; try { c = mDb.query(DATABASE_USERKEY, new String[] { KEY_USERKEY}, null, null, null, null, null); }catch(Exception e){ Log.e(TAG, e.toString()); return ""; } if(c.moveToFirst()){ return c.getString(0); } else{ Log.d(TAG, "UserKey Empty"); } return ""; } //not including any function related to "myuserdata" table } Class1.java { mUserKey = mDbHelper.retrieveKey(); mDbHelper.storeKey(Key); } the error that i am receiving is from Log.e(TAG, e.toString()) in the methods retrieveKey() and storeKey() "no such table: myuserkey: , while compiling: SELECT userkey FROM myuserkey"

    Read the article

  • How to Get All the Windows 8 Editions on One Install Disk

    - by Taylor Gibb
    There are a lot of different versions of Windows, but you probably didn’t know that short of the Enterprise edition, the disc or image that you own contains all versions for that architecture. Read on to see how we can use them to make a universal Windows 8 install disc. Things You Will Need A x86 Version of Windows 8 A x64 Version of Windows 8 A x86 Version of Windows 8 Enterprise A x64 Version of Windows 8 Enterprise A Windows 8 PC Note: While we will use all the images above you don’t really need the Enterprise Edition. You could always leave out parts of the tutorial if you know what you are doing, if you are not comfortable with that and still want to follow through you could always grab the Enterprise evaluation images that are available for free to the public, on MSDN. Getting Started To get started you will need to Download the Windows 8 ADK from Microsoft. Once downloaded go ahead and install it, you will only need the Deployment tools so be sure to uncheck the rest of the options. Lastly you will also need to create the following folder structure on the root of your C:\ drive to make things a bit easier. C:\Windows8Root C:\Windows8Root\x86 C:\Windows8Root\x64 C:\Windows8Root\Enterprisex86 C:\Windows8Root\Enterprisex64 C:\Windows8Root\Temp C:\Windows8Root\Final OK lets get started. Making The Image The first thing we need to do is create a base image, so mount the x86 version of Windows 8 and copy its files to: C:\Windows8Root\Final Now move the install.wim file from: C:\Windows8Root\Final\sources To: C:\Windows8Root\x86 Next go ahead and copy the install.wim file from the other 3 images, Windows 8 x64, Windows 8 Enterprise x86 and Windows 8 Enterprise x64 to the respective folders in Windows8Root, the install.wim file can be located at: D:\sources\install.wim Note: The above assumes that the images are always mounted at drive D. Remember that each install.wim is different so don’t copy them to the wrong directories or the rest of the tutorial wont work. Next switch to the Metro Start Screen and open the Deployment and Imaging Tools Environment. Note: If you are not a local administrator on your PC, you will need to right-click on it and choose to run it as an administrator. Now run the following commands: Dism /Export-Image /SourceImageFile:c:\Windows8Root\x86\install.wim /SourceIndex:2 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8″ /compress:maximum Dism /Export-Image /SourceImageFile:c:\Windows8Root\x86\install.wim /SourceIndex:1 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8 Pro” /compress:maximum Dism /Export-Image /SourceImageFile:c:\Windows8Root\x86\install.wim /SourceIndex:1 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8 Pro with Media Center” /compress:maximum Dism /Export-Image /SourceImageFile:c:\Windows8Root\Enterprisex86\install.wim /SourceIndex:1 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8 Enterprise” /compress:maximum Dism /Export-Image /SourceImageFile:c:\Windows8Root\x64\install.wim /SourceIndex:2 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8″ /compress:maximum Dism /Export-Image /SourceImageFile:c:\Windows8Root\x64\install.wim /SourceIndex:1 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8 Pro” /compress:maximum Dism /Export-Image /SourceImageFile:c:\Windows8Root\x64\install.wim /SourceIndex:1 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8 Pro with Media Center” /compress:maximum Dism /Export-Image /SourceImageFile:c:\Windows8Root\Enterprisex64\install.wim /SourceIndex:1 /DestinationImageFile:c:\Windows8Root\Final\sources\install.wim /DestinationName:”Windows 8 Enterprise” /compress:maximum Next navigate to: C:\Windows8Root\sources\ And create a new text file. You will need to call it: EI.cfg Then edit it to look like the following: The last thing we need to do is work some magic to get Windows Media Center added to the WMC editions of Windows 8. For that I have written a little script to make it easier for everybody, you can grab it here. Once you have downloaded it extract it. In order to use it right-click in the bottom left hand corner of the screen, and open an elevated command prompt. Then go ahead and paste the following into the command prompt window. powershell.exe -ExecutionPolicy Unrestricted -File C:\Users\Taylor\Documents\HTGWindows8Converter.ps1 Note: You will need to replace the path to the script, another thing to note is that if the path you replace it with has spaces you will need to enclose the path in quotes. The script should kick off straight away and has some progress bars you can watch while it does its thing. Half way through another Window will pop open, which will start creating your final ISO image. When its complete, close the command prompt and you should have an ISO image on the root of your C drive called: HTGWindows8.iso That’s all there is to it. 7 Ways To Free Up Hard Disk Space On Windows HTG Explains: How System Restore Works in Windows HTG Explains: How Antivirus Software Works

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >