Forums

Get More Support

Here for you 24/7

learn more
VOD Free SDK

Start Building your Engine Now

Download Now
VOD Extranet

Access to patches, license management,
tech docs and more for existing VOD customers.

Learn More
Object manager 7.4
Last Post 03 Feb 2012 01:36 PM by mouyssi. 0 Replies.
AddThis - Bookmarking and Sharing Button Printer Friendly
  •  
  •  
  •  
  •  
  •  
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
mouyssi
New Member
New Member
Posts: 14


--
03 Feb 2012 01:36 PM

    Hi,

    I have a new problem about Object manager v.7.4.

    When i run this code:

    import java.io.*;


    import com.db4o.*;

    public class FirstStepsExample extends Util {
     final static String DB4OFILENAME = "db.yap";
     
     public static void main(String[] args) {
      ObjectContainer db = Db4oEmbedded.openFile(Db4oEmbedded
        .newConfiguration(), DB4OFILENAME);
      try {
       storeFirstPilot(db);
       //storeSecondPilot(db);
       //retrieveAllPilots(db);
       //retrievePilotByName(db);
       //retrievePilotByExactPoints(db);
       //updatePilot(db);
       //deleteFirstPilotByName(db);
       //deleteSecondPilotByName(db);
      } finally {
       db.close();
      }
     }

     public static void accessDb4o() {
      ObjectContainer db = Db4oEmbedded.openFile(Db4oEmbedded
        .newConfiguration(), DB4OFILENAME);
      try {
       // do something with db4o
      } finally {
       db.close();
      }
     }

     public static void storeFirstPilot(ObjectContainer db) {
      Pilot pilot1 = new Pilot("Michael Schumacher", 100);
      db.store(pilot1);
     
      System.out.println("Stored " + pilot1);
     }

    }

    I have my file db.yap.

    When i try to open it with O.M, there is nothing !?

    You are not authorized to post a reply.


    Active Forums 4.3