mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-22 21:58:08 +00:00
update compilation script to work with August 09 mingw environment.
git-svn-id: svn+ssh://svn.savannah.nongnu.org/linphone/trunk@572 3f6dc0c8-ddfe-455d-9043-3cd528dc4637
This commit is contained in:
parent
b406c401dc
commit
8b96905599
10 changed files with 513 additions and 363 deletions
110
linphone/INSTALL
110
linphone/INSTALL
|
|
@ -2,15 +2,15 @@ Installation Instructions
|
|||
*************************
|
||||
|
||||
Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
|
||||
2006 Free Software Foundation, Inc.
|
||||
2006, 2007, 2008, 2009 Free Software Foundation, Inc.
|
||||
|
||||
This file is free documentation; the Free Software Foundation gives
|
||||
This file is free documentation; the Free Software Foundation gives
|
||||
unlimited permission to copy, distribute and modify it.
|
||||
|
||||
Basic Installation
|
||||
==================
|
||||
|
||||
Briefly, the shell commands `./configure; make; make install' should
|
||||
Briefly, the shell commands `./configure; make; make install' should
|
||||
configure, build, and install this package. The following
|
||||
more-detailed instructions are generic; see the `README' file for
|
||||
instructions specific to this package.
|
||||
|
|
@ -67,12 +67,15 @@ The simplest way to compile this package is:
|
|||
all sorts of other programs in order to regenerate files that came
|
||||
with the distribution.
|
||||
|
||||
6. Often, you can also type `make uninstall' to remove the installed
|
||||
files again.
|
||||
|
||||
Compilers and Options
|
||||
=====================
|
||||
|
||||
Some systems require unusual options for compilation or linking that the
|
||||
`configure' script does not know about. Run `./configure --help' for
|
||||
details on some of the pertinent environment variables.
|
||||
Some systems require unusual options for compilation or linking that
|
||||
the `configure' script does not know about. Run `./configure --help'
|
||||
for details on some of the pertinent environment variables.
|
||||
|
||||
You can give `configure' initial values for configuration parameters
|
||||
by setting variables in the command line or in the environment. Here
|
||||
|
|
@ -85,7 +88,7 @@ is an example:
|
|||
Compiling For Multiple Architectures
|
||||
====================================
|
||||
|
||||
You can compile the package for more than one kind of computer at the
|
||||
You can compile the package for more than one kind of computer at the
|
||||
same time, by placing the object files for each architecture in their
|
||||
own directory. To do this, you can use GNU `make'. `cd' to the
|
||||
directory where you want the object files and executables to go and run
|
||||
|
|
@ -97,10 +100,24 @@ architecture at a time in the source code directory. After you have
|
|||
installed the package for one architecture, use `make distclean' before
|
||||
reconfiguring for another architecture.
|
||||
|
||||
On MacOS X 10.5 and later systems, you can create libraries and
|
||||
executables that work on multiple system types--known as "fat" or
|
||||
"universal" binaries--by specifying multiple `-arch' options to the
|
||||
compiler but only a single `-arch' option to the preprocessor. Like
|
||||
this:
|
||||
|
||||
./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
|
||||
CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
|
||||
CPP="gcc -E" CXXCPP="g++ -E"
|
||||
|
||||
This is not guaranteed to produce working output in all cases, you
|
||||
may have to build one architecture at a time and combine the results
|
||||
using the `lipo' tool if you have problems.
|
||||
|
||||
Installation Names
|
||||
==================
|
||||
|
||||
By default, `make install' installs the package's commands under
|
||||
By default, `make install' installs the package's commands under
|
||||
`/usr/local/bin', include files under `/usr/local/include', etc. You
|
||||
can specify an installation prefix other than `/usr/local' by giving
|
||||
`configure' the option `--prefix=PREFIX'.
|
||||
|
|
@ -123,7 +140,7 @@ option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
|
|||
Optional Features
|
||||
=================
|
||||
|
||||
Some packages pay attention to `--enable-FEATURE' options to
|
||||
Some packages pay attention to `--enable-FEATURE' options to
|
||||
`configure', where FEATURE indicates an optional part of the package.
|
||||
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
|
||||
is something like `gnu-as' or `x' (for the X Window System). The
|
||||
|
|
@ -135,14 +152,46 @@ find the X include and library files automatically, but if it doesn't,
|
|||
you can use the `configure' options `--x-includes=DIR' and
|
||||
`--x-libraries=DIR' to specify their locations.
|
||||
|
||||
Particular systems
|
||||
==================
|
||||
|
||||
On HP-UX, the default C compiler is not ANSI C compatible. If GNU
|
||||
CC is not installed, it is recommended to use the following options in
|
||||
order to use an ANSI C compiler:
|
||||
|
||||
./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
|
||||
|
||||
and if that doesn't work, install pre-built binaries of GCC for HP-UX.
|
||||
|
||||
On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
|
||||
parse its `<wchar.h>' header file. The option `-nodtk' can be used as
|
||||
a workaround. If GNU CC is not installed, it is therefore recommended
|
||||
to try
|
||||
|
||||
./configure CC="cc"
|
||||
|
||||
and if that doesn't work, try
|
||||
|
||||
./configure CC="cc -nodtk"
|
||||
|
||||
On Solaris, don't put `/usr/ucb' early in your `PATH'. This
|
||||
directory contains several dysfunctional programs; working variants of
|
||||
these programs are available in `/usr/bin'. So, if you need `/usr/ucb'
|
||||
in your `PATH', put it _after_ `/usr/bin'.
|
||||
|
||||
On Haiku, software installed for all users goes in `/boot/common',
|
||||
not `/usr/local'. It is recommended to use the following options:
|
||||
|
||||
./configure --prefix=/boot/common
|
||||
|
||||
Specifying the System Type
|
||||
==========================
|
||||
|
||||
There may be some features `configure' cannot figure out automatically,
|
||||
but needs to determine by the type of machine the package will run on.
|
||||
Usually, assuming the package is built to be run on the _same_
|
||||
architectures, `configure' can figure that out, but if it prints a
|
||||
message saying it cannot guess the machine type, give it the
|
||||
There may be some features `configure' cannot figure out
|
||||
automatically, but needs to determine by the type of machine the package
|
||||
will run on. Usually, assuming the package is built to be run on the
|
||||
_same_ architectures, `configure' can figure that out, but if it prints
|
||||
a message saying it cannot guess the machine type, give it the
|
||||
`--build=TYPE' option. TYPE can either be a short name for the system
|
||||
type, such as `sun4', or a canonical name which has the form:
|
||||
|
||||
|
|
@ -150,7 +199,8 @@ type, such as `sun4', or a canonical name which has the form:
|
|||
|
||||
where SYSTEM can have one of these forms:
|
||||
|
||||
OS KERNEL-OS
|
||||
OS
|
||||
KERNEL-OS
|
||||
|
||||
See the file `config.sub' for the possible values of each field. If
|
||||
`config.sub' isn't included in this package, then this package doesn't
|
||||
|
|
@ -168,9 +218,9 @@ eventually be run) with `--host=TYPE'.
|
|||
Sharing Defaults
|
||||
================
|
||||
|
||||
If you want to set default values for `configure' scripts to share, you
|
||||
can create a site shell script called `config.site' that gives default
|
||||
values for variables like `CC', `cache_file', and `prefix'.
|
||||
If you want to set default values for `configure' scripts to share,
|
||||
you can create a site shell script called `config.site' that gives
|
||||
default values for variables like `CC', `cache_file', and `prefix'.
|
||||
`configure' looks for `PREFIX/share/config.site' if it exists, then
|
||||
`PREFIX/etc/config.site' if it exists. Or, you can set the
|
||||
`CONFIG_SITE' environment variable to the location of the site script.
|
||||
|
|
@ -179,7 +229,7 @@ A warning: not all `configure' scripts look for a site script.
|
|||
Defining Variables
|
||||
==================
|
||||
|
||||
Variables not defined in a site shell script can be set in the
|
||||
Variables not defined in a site shell script can be set in the
|
||||
environment passed to `configure'. However, some packages may run
|
||||
configure again during the build, and the customized values of these
|
||||
variables may be lost. In order to avoid this problem, you should set
|
||||
|
|
@ -198,11 +248,19 @@ an Autoconf bug. Until the bug is fixed you can use this workaround:
|
|||
`configure' Invocation
|
||||
======================
|
||||
|
||||
`configure' recognizes the following options to control how it operates.
|
||||
`configure' recognizes the following options to control how it
|
||||
operates.
|
||||
|
||||
`--help'
|
||||
`-h'
|
||||
Print a summary of the options to `configure', and exit.
|
||||
Print a summary of all of the options to `configure', and exit.
|
||||
|
||||
`--help=short'
|
||||
`--help=recursive'
|
||||
Print a summary of the options unique to this package's
|
||||
`configure', and exit. The `short' variant lists options used
|
||||
only in the top level, while the `recursive' variant lists options
|
||||
also present in any nested packages.
|
||||
|
||||
`--version'
|
||||
`-V'
|
||||
|
|
@ -229,6 +287,16 @@ an Autoconf bug. Until the bug is fixed you can use this workaround:
|
|||
Look for the package's source code in directory DIR. Usually
|
||||
`configure' can determine that directory automatically.
|
||||
|
||||
`--prefix=DIR'
|
||||
Use DIR as the installation prefix. *Note Installation Names::
|
||||
for more details, including other options available for fine-tuning
|
||||
the installation locations.
|
||||
|
||||
`--no-create'
|
||||
`-n'
|
||||
Run the configure checks, but stop before creating any output
|
||||
files.
|
||||
|
||||
`configure' also accepts some other, not widely useful, options. Run
|
||||
`configure --help' for more details.
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ echo "Generating build scripts in linphone..."
|
|||
set -x
|
||||
libtoolize --copy --force
|
||||
|
||||
intltoolize -c --force --automake
|
||||
/usr/bin/intltoolize -c --force --automake
|
||||
autoheader
|
||||
$ACLOCAL -I m4
|
||||
$AUTOMAKE --force-missing --add-missing --copy
|
||||
|
|
|
|||
|
|
@ -56,12 +56,12 @@ AC_ENABLE_SHARED(yes)
|
|||
AC_ENABLE_STATIC(no)
|
||||
|
||||
|
||||
if test "$mingw_found" = "yes" ; then
|
||||
AC_MSG_NOTICE([Hacking libtool to work with mingw...])
|
||||
sed -e 's/\*\" \$a_deplib \"\*/\*/' < ./libtool > libtool.tmp
|
||||
cp -f ./libtool.tmp ./libtool
|
||||
rm -f ./libtool.tmp
|
||||
fi
|
||||
dnl if test "$mingw_found" = "yes" ; then
|
||||
dnl AC_MSG_NOTICE([Hacking libtool to work with mingw...])
|
||||
dnl sed -e 's/\*\" \$a_deplib \"\*/\*/' < ./libtool > libtool.tmp
|
||||
dnl cp -f ./libtool.tmp ./libtool
|
||||
dnl rm -f ./libtool.tmp
|
||||
dnl fi
|
||||
|
||||
dnl Add the languages which your application supports here.
|
||||
PKG_PROG_PKG_CONFIG
|
||||
|
|
|
|||
|
|
@ -19,15 +19,15 @@ LIBS_save=$LIBS
|
|||
AC_CHECK_LIB([eXosip2],[eXosip_subscribe_remove],
|
||||
[],
|
||||
[AC_MSG_ERROR([Could not find eXosip2 library with version >= 3.0.2 !])],
|
||||
[-losipparser2 -losip2 -lpthread])
|
||||
[-losipparser2 -losip2 ])
|
||||
AC_CHECK_LIB([eXosip2],[eXosip_get_version],
|
||||
[AC_DEFINE([HAVE_EXOSIP_GET_VERSION],[1],[Defined when eXosip_get_version is available])],
|
||||
[],
|
||||
[-losipparser2 -losip2 -lpthread])
|
||||
[-losipparser2 -losip2 ])
|
||||
dnl AC_CHECK_LIB([eXosip2],[eXosip_get_naptr],
|
||||
dnl [AC_DEFINE([HAVE_EXOSIP_NAPTR_SUPPORT],[1],[Defined when eXosip_get_naptr is available])],
|
||||
dnl [],
|
||||
dnl [-losipparser2 -losip2 -lpthread])
|
||||
dnl [-losipparser2 -losip2 ])
|
||||
LIBS=$LIBS_save
|
||||
LDFLAGS=$LDFLAGS_save
|
||||
|
||||
|
|
|
|||
|
|
@ -40,8 +40,17 @@ dnl check for osip2 libs
|
|||
LDFLAGS_save=$LDFLAGS
|
||||
LDFLAGS=$OSIP_LIBS
|
||||
LIBS_save=$LIBS
|
||||
AC_CHECK_LIB(osip2${osip_legacy_version},osip_init, , AC_MSG_ERROR([Could not find osip2 library !]),[-losipparser2${osip_legacy_version} -lpthread])
|
||||
AC_CHECK_LIB(osipparser2${osip_legacy_version},osip_message_init, , AC_MSG_ERROR([Could not find osipparser2 library !]),[-lpthread])
|
||||
case "$target_os" in
|
||||
*mingw*)
|
||||
osip_aux_libs=
|
||||
;;
|
||||
*)
|
||||
osip_aux_libs=-lpthread
|
||||
;;
|
||||
esac
|
||||
OSIP_LIBS="$OSIP_LIBS $osip_aux_libs"
|
||||
AC_CHECK_LIB(osip2${osip_legacy_version},osip_init, , AC_MSG_ERROR([Could not find osip2 library !]),[-losipparser2${osip_legacy_version} $osip_aux_libs ])
|
||||
AC_CHECK_LIB(osipparser2${osip_legacy_version},osip_message_init, , AC_MSG_ERROR([Could not find osipparser2 library !]),[$osip_aux_libs])
|
||||
LDFLAGS=$LDFLAGS_save
|
||||
LIBS=$LIBS_save
|
||||
fi
|
||||
|
|
|
|||
|
|
@ -2,15 +2,15 @@ Installation Instructions
|
|||
*************************
|
||||
|
||||
Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
|
||||
2006 Free Software Foundation, Inc.
|
||||
2006, 2007, 2008, 2009 Free Software Foundation, Inc.
|
||||
|
||||
This file is free documentation; the Free Software Foundation gives
|
||||
This file is free documentation; the Free Software Foundation gives
|
||||
unlimited permission to copy, distribute and modify it.
|
||||
|
||||
Basic Installation
|
||||
==================
|
||||
|
||||
Briefly, the shell commands `./configure; make; make install' should
|
||||
Briefly, the shell commands `./configure; make; make install' should
|
||||
configure, build, and install this package. The following
|
||||
more-detailed instructions are generic; see the `README' file for
|
||||
instructions specific to this package.
|
||||
|
|
@ -67,12 +67,15 @@ The simplest way to compile this package is:
|
|||
all sorts of other programs in order to regenerate files that came
|
||||
with the distribution.
|
||||
|
||||
6. Often, you can also type `make uninstall' to remove the installed
|
||||
files again.
|
||||
|
||||
Compilers and Options
|
||||
=====================
|
||||
|
||||
Some systems require unusual options for compilation or linking that the
|
||||
`configure' script does not know about. Run `./configure --help' for
|
||||
details on some of the pertinent environment variables.
|
||||
Some systems require unusual options for compilation or linking that
|
||||
the `configure' script does not know about. Run `./configure --help'
|
||||
for details on some of the pertinent environment variables.
|
||||
|
||||
You can give `configure' initial values for configuration parameters
|
||||
by setting variables in the command line or in the environment. Here
|
||||
|
|
@ -85,7 +88,7 @@ is an example:
|
|||
Compiling For Multiple Architectures
|
||||
====================================
|
||||
|
||||
You can compile the package for more than one kind of computer at the
|
||||
You can compile the package for more than one kind of computer at the
|
||||
same time, by placing the object files for each architecture in their
|
||||
own directory. To do this, you can use GNU `make'. `cd' to the
|
||||
directory where you want the object files and executables to go and run
|
||||
|
|
@ -97,10 +100,24 @@ architecture at a time in the source code directory. After you have
|
|||
installed the package for one architecture, use `make distclean' before
|
||||
reconfiguring for another architecture.
|
||||
|
||||
On MacOS X 10.5 and later systems, you can create libraries and
|
||||
executables that work on multiple system types--known as "fat" or
|
||||
"universal" binaries--by specifying multiple `-arch' options to the
|
||||
compiler but only a single `-arch' option to the preprocessor. Like
|
||||
this:
|
||||
|
||||
./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
|
||||
CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
|
||||
CPP="gcc -E" CXXCPP="g++ -E"
|
||||
|
||||
This is not guaranteed to produce working output in all cases, you
|
||||
may have to build one architecture at a time and combine the results
|
||||
using the `lipo' tool if you have problems.
|
||||
|
||||
Installation Names
|
||||
==================
|
||||
|
||||
By default, `make install' installs the package's commands under
|
||||
By default, `make install' installs the package's commands under
|
||||
`/usr/local/bin', include files under `/usr/local/include', etc. You
|
||||
can specify an installation prefix other than `/usr/local' by giving
|
||||
`configure' the option `--prefix=PREFIX'.
|
||||
|
|
@ -123,7 +140,7 @@ option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
|
|||
Optional Features
|
||||
=================
|
||||
|
||||
Some packages pay attention to `--enable-FEATURE' options to
|
||||
Some packages pay attention to `--enable-FEATURE' options to
|
||||
`configure', where FEATURE indicates an optional part of the package.
|
||||
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
|
||||
is something like `gnu-as' or `x' (for the X Window System). The
|
||||
|
|
@ -135,14 +152,46 @@ find the X include and library files automatically, but if it doesn't,
|
|||
you can use the `configure' options `--x-includes=DIR' and
|
||||
`--x-libraries=DIR' to specify their locations.
|
||||
|
||||
Particular systems
|
||||
==================
|
||||
|
||||
On HP-UX, the default C compiler is not ANSI C compatible. If GNU
|
||||
CC is not installed, it is recommended to use the following options in
|
||||
order to use an ANSI C compiler:
|
||||
|
||||
./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
|
||||
|
||||
and if that doesn't work, install pre-built binaries of GCC for HP-UX.
|
||||
|
||||
On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
|
||||
parse its `<wchar.h>' header file. The option `-nodtk' can be used as
|
||||
a workaround. If GNU CC is not installed, it is therefore recommended
|
||||
to try
|
||||
|
||||
./configure CC="cc"
|
||||
|
||||
and if that doesn't work, try
|
||||
|
||||
./configure CC="cc -nodtk"
|
||||
|
||||
On Solaris, don't put `/usr/ucb' early in your `PATH'. This
|
||||
directory contains several dysfunctional programs; working variants of
|
||||
these programs are available in `/usr/bin'. So, if you need `/usr/ucb'
|
||||
in your `PATH', put it _after_ `/usr/bin'.
|
||||
|
||||
On Haiku, software installed for all users goes in `/boot/common',
|
||||
not `/usr/local'. It is recommended to use the following options:
|
||||
|
||||
./configure --prefix=/boot/common
|
||||
|
||||
Specifying the System Type
|
||||
==========================
|
||||
|
||||
There may be some features `configure' cannot figure out automatically,
|
||||
but needs to determine by the type of machine the package will run on.
|
||||
Usually, assuming the package is built to be run on the _same_
|
||||
architectures, `configure' can figure that out, but if it prints a
|
||||
message saying it cannot guess the machine type, give it the
|
||||
There may be some features `configure' cannot figure out
|
||||
automatically, but needs to determine by the type of machine the package
|
||||
will run on. Usually, assuming the package is built to be run on the
|
||||
_same_ architectures, `configure' can figure that out, but if it prints
|
||||
a message saying it cannot guess the machine type, give it the
|
||||
`--build=TYPE' option. TYPE can either be a short name for the system
|
||||
type, such as `sun4', or a canonical name which has the form:
|
||||
|
||||
|
|
@ -150,7 +199,8 @@ type, such as `sun4', or a canonical name which has the form:
|
|||
|
||||
where SYSTEM can have one of these forms:
|
||||
|
||||
OS KERNEL-OS
|
||||
OS
|
||||
KERNEL-OS
|
||||
|
||||
See the file `config.sub' for the possible values of each field. If
|
||||
`config.sub' isn't included in this package, then this package doesn't
|
||||
|
|
@ -168,9 +218,9 @@ eventually be run) with `--host=TYPE'.
|
|||
Sharing Defaults
|
||||
================
|
||||
|
||||
If you want to set default values for `configure' scripts to share, you
|
||||
can create a site shell script called `config.site' that gives default
|
||||
values for variables like `CC', `cache_file', and `prefix'.
|
||||
If you want to set default values for `configure' scripts to share,
|
||||
you can create a site shell script called `config.site' that gives
|
||||
default values for variables like `CC', `cache_file', and `prefix'.
|
||||
`configure' looks for `PREFIX/share/config.site' if it exists, then
|
||||
`PREFIX/etc/config.site' if it exists. Or, you can set the
|
||||
`CONFIG_SITE' environment variable to the location of the site script.
|
||||
|
|
@ -179,7 +229,7 @@ A warning: not all `configure' scripts look for a site script.
|
|||
Defining Variables
|
||||
==================
|
||||
|
||||
Variables not defined in a site shell script can be set in the
|
||||
Variables not defined in a site shell script can be set in the
|
||||
environment passed to `configure'. However, some packages may run
|
||||
configure again during the build, and the customized values of these
|
||||
variables may be lost. In order to avoid this problem, you should set
|
||||
|
|
@ -198,11 +248,19 @@ an Autoconf bug. Until the bug is fixed you can use this workaround:
|
|||
`configure' Invocation
|
||||
======================
|
||||
|
||||
`configure' recognizes the following options to control how it operates.
|
||||
`configure' recognizes the following options to control how it
|
||||
operates.
|
||||
|
||||
`--help'
|
||||
`-h'
|
||||
Print a summary of the options to `configure', and exit.
|
||||
Print a summary of all of the options to `configure', and exit.
|
||||
|
||||
`--help=short'
|
||||
`--help=recursive'
|
||||
Print a summary of the options unique to this package's
|
||||
`configure', and exit. The `short' variant lists options used
|
||||
only in the top level, while the `recursive' variant lists options
|
||||
also present in any nested packages.
|
||||
|
||||
`--version'
|
||||
`-V'
|
||||
|
|
@ -229,6 +287,16 @@ an Autoconf bug. Until the bug is fixed you can use this workaround:
|
|||
Look for the package's source code in directory DIR. Usually
|
||||
`configure' can determine that directory automatically.
|
||||
|
||||
`--prefix=DIR'
|
||||
Use DIR as the installation prefix. *Note Installation Names::
|
||||
for more details, including other options available for fine-tuning
|
||||
the installation locations.
|
||||
|
||||
`--no-create'
|
||||
`-n'
|
||||
Run the configure checks, but stop before creating any output
|
||||
files.
|
||||
|
||||
`configure' also accepts some other, not widely useful, options. Run
|
||||
`configure --help' for more details.
|
||||
|
||||
|
|
|
|||
5
linphone/mingw-envsetup.sh
Normal file
5
linphone/mingw-envsetup.sh
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
export PATH=$PATH:/c/Program\ Files/GnuWin32/bin
|
||||
export PERL=/c/Perl/bin/perl.exe
|
||||
export INTLTOOL_PERL=/c/Perl/bin/perl.exe
|
||||
|
||||
|
||||
|
|
@ -1,151 +1,151 @@
|
|||
/*
|
||||
* The Apache Software License, Version 1.1
|
||||
*
|
||||
*
|
||||
* Copyright (c) 1999 The Apache Software Foundation. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in
|
||||
* the documentation and/or other materials provided with the
|
||||
* distribution.
|
||||
*
|
||||
* 3. The end-user documentation included with the redistribution,
|
||||
* if any, must include the following acknowledgment:
|
||||
* "This product includes software developed by the
|
||||
* Apache Software Foundation (http://www.apache.org/)."
|
||||
* Alternately, this acknowledgment may appear in the software itself,
|
||||
* if and wherever such third-party acknowledgments normally appear.
|
||||
*
|
||||
* 4. The names "Xindice" and "Apache Software Foundation" must
|
||||
* not be used to endorse or promote products derived from this
|
||||
* software without prior written permission. For written
|
||||
* permission, please contact apache@apache.org.
|
||||
*
|
||||
* 5. Products derived from this software may not be called "Apache",
|
||||
* nor may "Apache" appear in their name, without prior written
|
||||
* permission of the Apache Software Foundation.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
|
||||
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
|
||||
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
||||
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
* ====================================================================
|
||||
*
|
||||
* This software consists of voluntary contributions made by many
|
||||
* individuals on behalf of the Apache Software Foundation and was
|
||||
* originally based on software copyright (c) 1999-2001, The dbXML
|
||||
* Group, L.L.C., http://www.dbxmlgroup.com. For more
|
||||
* information on the Apache Software Foundation, please see
|
||||
* <http://www.apache.org/>.
|
||||
*
|
||||
*/
|
||||
package net.jxta.impl.xindice.core.data;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* Record is a container for Key/Value pairs. Record also provides
|
||||
* metadata for a Value stored in the database.
|
||||
*/
|
||||
public final class Record {
|
||||
public static final String CREATED = "created";
|
||||
public static final String MODIFIED = "modified";
|
||||
public static final String LIFETIME = "lifetime";
|
||||
public static final String EXPIRATION = "expiration";
|
||||
public static final String OWNER = "owner";
|
||||
public static final String GROUP = "group";
|
||||
|
||||
private Key key = null;
|
||||
private Value value = null;
|
||||
private Map meta = null;
|
||||
|
||||
public Record() {}
|
||||
|
||||
public Record(Key key, Value value, Map meta) {
|
||||
this.key = key;
|
||||
this.value = value;
|
||||
this.meta = meta;
|
||||
}
|
||||
|
||||
public Record(Key key, Value value) {
|
||||
this.key = key;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* setKey sets the Record's Key.
|
||||
*
|
||||
* @param key The new key
|
||||
*/
|
||||
public void setKey(Key key) {
|
||||
this.key = key;
|
||||
}
|
||||
|
||||
/**
|
||||
* getKey returns the Record's Key.
|
||||
*
|
||||
* @return The Record's Key
|
||||
*/
|
||||
public Key getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* setValue sets the Record's Value.
|
||||
*
|
||||
* @param value The new Value
|
||||
*/
|
||||
public void setValue(Value value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* setValue sets the Record's Value.
|
||||
*
|
||||
* @param value The new Value
|
||||
*/
|
||||
public void setValue(String value) {
|
||||
this.value = new Value(value);
|
||||
}
|
||||
|
||||
/**
|
||||
* getValue returns the Record's Value.
|
||||
*
|
||||
* @return The Record's Value
|
||||
*/
|
||||
public Value getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* getMetaData returns metadata about the Value.
|
||||
*
|
||||
* @param name The property name
|
||||
* @return The metadata value
|
||||
*/
|
||||
public Object getMetaData(Object name) {
|
||||
return meta != null ? meta.get(name) : null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return
|
||||
(key != null ? key.toString() : "") + (value != null ? " = " + value.toString() : "")
|
||||
+ (meta != null ? " meta " + meta.toString() : "");
|
||||
}
|
||||
}
|
||||
/*
|
||||
* The Apache Software License, Version 1.1
|
||||
*
|
||||
*
|
||||
* Copyright (c) 1999 The Apache Software Foundation. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in
|
||||
* the documentation and/or other materials provided with the
|
||||
* distribution.
|
||||
*
|
||||
* 3. The end-user documentation included with the redistribution,
|
||||
* if any, must include the following acknowledgment:
|
||||
* "This product includes software developed by the
|
||||
* Apache Software Foundation (http://www.apache.org/)."
|
||||
* Alternately, this acknowledgment may appear in the software itself,
|
||||
* if and wherever such third-party acknowledgments normally appear.
|
||||
*
|
||||
* 4. The names "Xindice" and "Apache Software Foundation" must
|
||||
* not be used to endorse or promote products derived from this
|
||||
* software without prior written permission. For written
|
||||
* permission, please contact apache@apache.org.
|
||||
*
|
||||
* 5. Products derived from this software may not be called "Apache",
|
||||
* nor may "Apache" appear in their name, without prior written
|
||||
* permission of the Apache Software Foundation.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
|
||||
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
|
||||
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
||||
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
* ====================================================================
|
||||
*
|
||||
* This software consists of voluntary contributions made by many
|
||||
* individuals on behalf of the Apache Software Foundation and was
|
||||
* originally based on software copyright (c) 1999-2001, The dbXML
|
||||
* Group, L.L.C., http://www.dbxmlgroup.com. For more
|
||||
* information on the Apache Software Foundation, please see
|
||||
* <http://www.apache.org/>.
|
||||
*
|
||||
*/
|
||||
package net.jxta.impl.xindice.core.data;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* Record is a container for Key/Value pairs. Record also provides
|
||||
* metadata for a Value stored in the database.
|
||||
*/
|
||||
public final class Record {
|
||||
public static final String CREATED = "created";
|
||||
public static final String MODIFIED = "modified";
|
||||
public static final String LIFETIME = "lifetime";
|
||||
public static final String EXPIRATION = "expiration";
|
||||
public static final String OWNER = "owner";
|
||||
public static final String GROUP = "group";
|
||||
|
||||
private Key key = null;
|
||||
private Value value = null;
|
||||
private Map meta = null;
|
||||
|
||||
public Record() {}
|
||||
|
||||
public Record(Key key, Value value, Map meta) {
|
||||
this.key = key;
|
||||
this.value = value;
|
||||
this.meta = meta;
|
||||
}
|
||||
|
||||
public Record(Key key, Value value) {
|
||||
this.key = key;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* setKey sets the Record's Key.
|
||||
*
|
||||
* @param key The new key
|
||||
*/
|
||||
public void setKey(Key key) {
|
||||
this.key = key;
|
||||
}
|
||||
|
||||
/**
|
||||
* getKey returns the Record's Key.
|
||||
*
|
||||
* @return The Record's Key
|
||||
*/
|
||||
public Key getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
/**
|
||||
* setValue sets the Record's Value.
|
||||
*
|
||||
* @param value The new Value
|
||||
*/
|
||||
public void setValue(Value value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
/**
|
||||
* setValue sets the Record's Value.
|
||||
*
|
||||
* @param value The new Value
|
||||
*/
|
||||
public void setValue(String value) {
|
||||
this.value = new Value(value);
|
||||
}
|
||||
|
||||
/**
|
||||
* getValue returns the Record's Value.
|
||||
*
|
||||
* @return The Record's Value
|
||||
*/
|
||||
public Value getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* getMetaData returns metadata about the Value.
|
||||
*
|
||||
* @param name The property name
|
||||
* @return The metadata value
|
||||
*/
|
||||
public Object getMetaData(Object name) {
|
||||
return meta != null ? meta.get(name) : null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return
|
||||
(key != null ? key.toString() : "") + (value != null ? " = " + value.toString() : "")
|
||||
+ (meta != null ? " meta " + meta.toString() : "");
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,137 +1,137 @@
|
|||
/*
|
||||
* The Apache Software License, Version 1.1
|
||||
*
|
||||
*
|
||||
* Copyright (c) 1999 The Apache Software Foundation. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in
|
||||
* the documentation and/or other materials provided with the
|
||||
* distribution.
|
||||
*
|
||||
* 3. The end-user documentation included with the redistribution,
|
||||
* if any, must include the following acknowledgment:
|
||||
* "This product includes software developed by the
|
||||
* Apache Software Foundation (http://www.apache.org/)."
|
||||
* Alternately, this acknowledgment may appear in the software itself,
|
||||
* if and wherever such third-party acknowledgments normally appear.
|
||||
*
|
||||
* 4. The names "Xindice" and "Apache Software Foundation" must
|
||||
* not be used to endorse or promote products derived from this
|
||||
* software without prior written permission. For written
|
||||
* permission, please contact apache@apache.org.
|
||||
*
|
||||
* 5. Products derived from this software may not be called "Apache",
|
||||
* nor may "Apache" appear in their name, without prior written
|
||||
* permission of the Apache Software Foundation.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
|
||||
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
|
||||
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
||||
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
* ====================================================================
|
||||
*
|
||||
* This software consists of voluntary contributions made by many
|
||||
* individuals on behalf of the Apache Software Foundation and was
|
||||
* originally based on software copyright (c) 1999-2001, The dbXML
|
||||
* Group, L.L.C., http://www.dbxmlgroup.com. For more
|
||||
* information on the Apache Software Foundation, please see
|
||||
* <http://www.apache.org/>.
|
||||
*
|
||||
*/
|
||||
package net.jxta.impl.xindice.core.filer;
|
||||
|
||||
import net.jxta.impl.xindice.core.DBException;
|
||||
import net.jxta.impl.xindice.core.DBObject;
|
||||
import net.jxta.impl.xindice.core.data.Key;
|
||||
import net.jxta.impl.xindice.core.data.Record;
|
||||
import net.jxta.impl.xindice.core.data.RecordSet;
|
||||
import net.jxta.impl.xindice.core.data.Value;
|
||||
import net.jxta.impl.xindice.util.Named;
|
||||
|
||||
/**
|
||||
* Filer is the low-level file management interface for Xindice. A Filer object
|
||||
* is implemented in order to provide a data source to the Xindice Collection
|
||||
* class. Filers are developed to perform transparent storage and retrieval to
|
||||
* and from heterogenous data sources (such as FTP, HTTP, RDBMS, etc...)
|
||||
*/
|
||||
public interface Filer extends Named, DBObject {
|
||||
|
||||
/**
|
||||
* readRecord returns a Record from the Filer based on the specified
|
||||
* Key.
|
||||
*
|
||||
* @param key The Record's Key
|
||||
* @return The returned Record
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
Record readRecord(Key key) throws DBException;
|
||||
|
||||
/**
|
||||
* readRecord returns a Record from the Filer at the specified
|
||||
* position. The Record's Key will be set to null.
|
||||
*
|
||||
* @param pos The Record's position
|
||||
* @return The returned Record
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
Record readRecord(long pos) throws DBException;
|
||||
|
||||
/**
|
||||
* writeRecord writes a Value to the Filer based on the specified Key.
|
||||
*
|
||||
* @param key The Record's Key
|
||||
* @param value The Record's Value
|
||||
* @return 0 if the Record could not be written, the starting
|
||||
* offset of the Record otherwise (used for indexing)
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
long writeRecord(Key key, Value value) throws DBException;
|
||||
|
||||
/**
|
||||
* deleteRecord removes a Record from the Filer based on the
|
||||
* specified Key.
|
||||
*
|
||||
* @param key The Record's Key
|
||||
* @return Whether or not the Record was deleted
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
boolean deleteRecord(Key key) throws DBException;
|
||||
|
||||
/**
|
||||
* getRecordCount returns the number of Records in the Filer.
|
||||
*
|
||||
* @return The Record count
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
long getRecordCount() throws DBException;
|
||||
|
||||
/**
|
||||
* getRecordSet returns a RecordSet object for the current Filer.
|
||||
*
|
||||
* @return The Filer Enumerator
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
RecordSet getRecordSet() throws DBException;
|
||||
|
||||
/**
|
||||
* flush forcefully flushes any unwritten buffers to disk.
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
void flush() throws DBException;
|
||||
}
|
||||
/*
|
||||
* The Apache Software License, Version 1.1
|
||||
*
|
||||
*
|
||||
* Copyright (c) 1999 The Apache Software Foundation. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in
|
||||
* the documentation and/or other materials provided with the
|
||||
* distribution.
|
||||
*
|
||||
* 3. The end-user documentation included with the redistribution,
|
||||
* if any, must include the following acknowledgment:
|
||||
* "This product includes software developed by the
|
||||
* Apache Software Foundation (http://www.apache.org/)."
|
||||
* Alternately, this acknowledgment may appear in the software itself,
|
||||
* if and wherever such third-party acknowledgments normally appear.
|
||||
*
|
||||
* 4. The names "Xindice" and "Apache Software Foundation" must
|
||||
* not be used to endorse or promote products derived from this
|
||||
* software without prior written permission. For written
|
||||
* permission, please contact apache@apache.org.
|
||||
*
|
||||
* 5. Products derived from this software may not be called "Apache",
|
||||
* nor may "Apache" appear in their name, without prior written
|
||||
* permission of the Apache Software Foundation.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
|
||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
|
||||
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
|
||||
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
||||
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
* ====================================================================
|
||||
*
|
||||
* This software consists of voluntary contributions made by many
|
||||
* individuals on behalf of the Apache Software Foundation and was
|
||||
* originally based on software copyright (c) 1999-2001, The dbXML
|
||||
* Group, L.L.C., http://www.dbxmlgroup.com. For more
|
||||
* information on the Apache Software Foundation, please see
|
||||
* <http://www.apache.org/>.
|
||||
*
|
||||
*/
|
||||
package net.jxta.impl.xindice.core.filer;
|
||||
|
||||
import net.jxta.impl.xindice.core.DBException;
|
||||
import net.jxta.impl.xindice.core.DBObject;
|
||||
import net.jxta.impl.xindice.core.data.Key;
|
||||
import net.jxta.impl.xindice.core.data.Record;
|
||||
import net.jxta.impl.xindice.core.data.RecordSet;
|
||||
import net.jxta.impl.xindice.core.data.Value;
|
||||
import net.jxta.impl.xindice.util.Named;
|
||||
|
||||
/**
|
||||
* Filer is the low-level file management interface for Xindice. A Filer object
|
||||
* is implemented in order to provide a data source to the Xindice Collection
|
||||
* class. Filers are developed to perform transparent storage and retrieval to
|
||||
* and from heterogenous data sources (such as FTP, HTTP, RDBMS, etc...)
|
||||
*/
|
||||
public interface Filer extends Named, DBObject {
|
||||
|
||||
/**
|
||||
* readRecord returns a Record from the Filer based on the specified
|
||||
* Key.
|
||||
*
|
||||
* @param key The Record's Key
|
||||
* @return The returned Record
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
Record readRecord(Key key) throws DBException;
|
||||
|
||||
/**
|
||||
* readRecord returns a Record from the Filer at the specified
|
||||
* position. The Record's Key will be set to null.
|
||||
*
|
||||
* @param pos The Record's position
|
||||
* @return The returned Record
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
Record readRecord(long pos) throws DBException;
|
||||
|
||||
/**
|
||||
* writeRecord writes a Value to the Filer based on the specified Key.
|
||||
*
|
||||
* @param key The Record's Key
|
||||
* @param value The Record's Value
|
||||
* @return 0 if the Record could not be written, the starting
|
||||
* offset of the Record otherwise (used for indexing)
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
long writeRecord(Key key, Value value) throws DBException;
|
||||
|
||||
/**
|
||||
* deleteRecord removes a Record from the Filer based on the
|
||||
* specified Key.
|
||||
*
|
||||
* @param key The Record's Key
|
||||
* @return Whether or not the Record was deleted
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
boolean deleteRecord(Key key) throws DBException;
|
||||
|
||||
/**
|
||||
* getRecordCount returns the number of Records in the Filer.
|
||||
*
|
||||
* @return The Record count
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
long getRecordCount() throws DBException;
|
||||
|
||||
/**
|
||||
* getRecordSet returns a RecordSet object for the current Filer.
|
||||
*
|
||||
* @return The Filer Enumerator
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
RecordSet getRecordSet() throws DBException;
|
||||
|
||||
/**
|
||||
* flush forcefully flushes any unwritten buffers to disk.
|
||||
* @throws net.jxta.impl.xindice.core.DBException if a db exception occurs
|
||||
*/
|
||||
void flush() throws DBException;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,22 +1,22 @@
|
|||
MjSip - http://www.mjsip.org
|
||||
|
||||
Copyright (C) 2005 by Luca Veltri - University of Parma - Italy.
|
||||
__________________________________________________
|
||||
|
||||
|
||||
MjSip is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
MjSip is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with MjSip; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
|
||||
MjSip - http://www.mjsip.org
|
||||
|
||||
Copyright (C) 2005 by Luca Veltri - University of Parma - Italy.
|
||||
__________________________________________________
|
||||
|
||||
|
||||
MjSip is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
MjSip is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with MjSip; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
|
||||
PLEASE READ CAREFULLY THE LICENSE DOCUMENT RECEIVED ALONG WITH THIS LIBRARY.
|
||||
Loading…
Add table
Reference in a new issue