数据库路径设置

C# & JAVA, 把数据库文件放到项目工作目录外会有更好性能

  1. iBoxDB.LocalServer.DB.Root("/data/");

ASP.NET Cross Platform

  1. iBoxDB.LocalServer.DB.Root(MapPath("~/App_Data/"));

Xamarin

  1. iBoxDB.LocalServer.DB.Root(System.Environment.GetFolderPath(
  2. System.Environment.SpecialFolder.Personal));

Unity3D

  1. iBoxDB.LocalServer.DB.Root(Application.persistentDataPath);

Android

  1. iBoxDB.LocalServer.DB.root(android.os.Environment.getDataDirectory()
  2. .getAbsolutePath() + "/data/" + packageName + "/");

JSP WebApplication

  1. @WebListener()
  2. public class StartListener implements ServletContextListener {
  3. @Override
  4. public void contextInitialized(ServletContextEvent sce) {
  5. String path = System.getProperty("user.home") + "/data/";
  6. new File(path).mkdirs();
  7. iBoxDB.LocalServer.DB.root(path);
  8. }
  9. }