Update Mroonga to the latest version on 2014-09-21T00:33:44+0900
505
storage/mroonga/vendor/groonga/CMakeLists.txt
vendored
Normal file
|
|
@ -0,0 +1,505 @@
|
|||
# Copyright(C) 2012-2013 Brazil
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License version 2.1 as published by the Free Software Foundation.
|
||||
#
|
||||
# This library 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
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
# https://buildbot.askmonty.org/buildbot/builders/work-amd64-valgrind/builds/5263/steps/compile/logs/stdio
|
||||
# says CMake 2.6.2... We want to drop old software support...
|
||||
cmake_minimum_required(VERSION 2.6.2)
|
||||
# cmake_minimum_required(VERSION 2.6.4) # CentOS 5
|
||||
set(GRN_PROJECT_NAME "groonga")
|
||||
project("${GRN_PROJECT_NAME}")
|
||||
|
||||
file(READ "${CMAKE_CURRENT_SOURCE_DIR}/base_version" VERSION)
|
||||
if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/version.sh")
|
||||
file(READ "${CMAKE_CURRENT_SOURCE_DIR}/version.sh" GRN_VERSION)
|
||||
else()
|
||||
if(NOT EXISTS "${CMAKE_CURRENT_BINARY_DIR}/version.sh")
|
||||
if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/.git")
|
||||
execute_process(COMMAND "${CMAKE_CURRENT_SOURCE_DIR}/version-gen.sh")
|
||||
file(READ "${CMAKE_CURRENT_BINARY_DIR}/version.sh" GRN_VERSION)
|
||||
else()
|
||||
set(GRN_VERSION "${VERSION}")
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
string(REGEX REPLACE "(^.*=|\n)" "" GRN_VERSION "${GRN_VERSION}")
|
||||
|
||||
include(CheckIncludeFile)
|
||||
include(CheckFunctionExists)
|
||||
include(CheckLibraryExists)
|
||||
include(CheckSymbolExists)
|
||||
include(CheckCCompilerFlag)
|
||||
include(CheckCXXCompilerFlag)
|
||||
include(FindPkgConfig)
|
||||
include(${CMAKE_CURRENT_SOURCE_DIR}/build/cmake_modules/ReadFileList.cmake)
|
||||
|
||||
set(BIN_DIR "bin")
|
||||
set(SBIN_DIR "sbin")
|
||||
set(LIB_DIR "lib")
|
||||
set(INCLUDE_DIR "include")
|
||||
set(GRN_INCLUDE_DIR "include/groonga")
|
||||
set(DATA_DIR "share")
|
||||
set(GRN_DATA_DIR "${DATA_DIR}/${GRN_PROJECT_NAME}")
|
||||
set(CONFIG_DIR "etc")
|
||||
set(GRN_CONFIG_DIR "${CONFIG_DIR}/${GRN_PROJECT_NAME}")
|
||||
|
||||
set(GRN_LOG_PATH
|
||||
"${CMAKE_INSTALL_PREFIX}/var/log/${GRN_PROJECT_NAME}/${GRN_PROJECT_NAME}.log"
|
||||
CACHE FILEPATH "log file path")
|
||||
set(GRN_DEFAULT_MATCH_ESCALATION_THRESHOLD
|
||||
0
|
||||
CACHE STRING "groonga default match escalation threshold")
|
||||
set(GRN_DEFAULT_DOCUMENT_ROOT_BASE
|
||||
"html/admin"
|
||||
CACHE PATH "groonga default document root base path")
|
||||
set(GRN_DEFAULT_RELATIVE_DOCUMENT_ROOT
|
||||
"share/${GRN_PROJECT_NAME}/${GRN_DEFAULT_DOCUMENT_ROOT_BASE}"
|
||||
CACHE PATH "groonga default relative document root")
|
||||
set(GRN_DEFAULT_DOCUMENT_ROOT
|
||||
"${CMAKE_INSTALL_PREFIX}/${GRN_DATA_DIR}/${GRN_DEFAULT_DOCUMENT_ROOT_BASE}"
|
||||
CACHE PATH "groonga default document root")
|
||||
set(GRN_STACK_SIZE
|
||||
1024
|
||||
CACHE STRING
|
||||
"DANGER!!! groonga stack size. Normarlly, you should not change this variable.")
|
||||
set(GRN_LOCK_TIMEOUT
|
||||
10000000
|
||||
CACHE STRING
|
||||
"timeout to acquire a lock.")
|
||||
set(GRN_LOCK_WAIT_TIME_NANOSECOND
|
||||
1000000
|
||||
CACHE STRING
|
||||
"wait time in nanosecond to acquire a lock.")
|
||||
set(GRN_RELATIVE_PLUGINS_DIR
|
||||
"${LIB_DIR}/${GRN_PROJECT_NAME}/plugins")
|
||||
set(GRN_PLUGINS_DIR
|
||||
"${CMAKE_INSTALL_PREFIX}/${GRN_RELATIVE_PLUGINS_DIR}")
|
||||
set(GRN_PLUGIN_SUFFIX "${CMAKE_SHARED_MODULE_SUFFIX}")
|
||||
set(GRN_DLL_FILENAME
|
||||
"${CMAKE_SHARED_LIBRARY_PREFIX}groonga${CMAKE_SHARED_LIBRARY_SUFFIX}")
|
||||
set(GRN_QUERY_EXPANDER_TSV_RELATIVE_SYNONYMS_FILE "synonyms.tsv")
|
||||
set(GRN_QUERY_EXPANDER_TSV_SYNONYMS_FILE
|
||||
"${CMAKE_INSTALL_PREFIX}/${GRN_DATA_DIR}/${GRN_QUERY_EXPANDER_TSV_RELATIVE_SYNONYMS_FILE}")
|
||||
set(GRN_RELATIVE_RUBY_SCRIPTS_DIR
|
||||
"${LIB_DIR}/${GRN_PROJECT_NAME}/scripts/ruby")
|
||||
set(GRN_RUBY_SCRIPTS_DIR
|
||||
"${CMAKE_INSTALL_PREFIX}/${GRN_RELATIVE_RUBY_SCRIPTS_DIR}")
|
||||
|
||||
macro(check_cflag flag)
|
||||
set(checking_message "checking for C flag '${flag}'")
|
||||
string(REGEX REPLACE "[-=]" "_" temporary_variable_name ${flag})
|
||||
string(TOUPPER "${temporary_variable_name}" temporary_variable_name)
|
||||
set(temporary_variable_name "CFLAG${temporary_variable_name}")
|
||||
# unset(${temporary_variable_name})
|
||||
check_c_compiler_flag(${flag} ${temporary_variable_name})
|
||||
if(${temporary_variable_name})
|
||||
message(STATUS "${checking_message} - available")
|
||||
set(GRN_C_COMPILE_FLAGS "${GRN_C_COMPILE_FLAGS} ${flag}")
|
||||
else()
|
||||
message(STATUS "${checking_message} - not available")
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
macro(check_cxxflag flag)
|
||||
set(checking_message "checking for CXX flag '${flag}'")
|
||||
string(REGEX REPLACE "[-=]" "_" temporary_variable_name ${flag})
|
||||
string(TOUPPER "${temporary_variable_name}" temporary_variable_name)
|
||||
set(temporary_variable_name "CXXFLAG${temporary_variable_name}")
|
||||
# unset(${temporary_variable_name})
|
||||
check_cxx_compiler_flag(${flag} ${temporary_variable_name})
|
||||
if(${temporary_variable_name})
|
||||
message(STATUS "${checking_message} - available")
|
||||
set(GRN_CXX_COMPILE_FLAGS "${GRN_CXX_COMPILE_FLAGS} ${flag}")
|
||||
else()
|
||||
message(STATUS "${checking_message} - not available")
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
macro(check_build_flag flag)
|
||||
check_cflag(${flag})
|
||||
check_cxxflag(${flag})
|
||||
endmacro()
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUCXX)
|
||||
check_build_flag("-Wall")
|
||||
check_build_flag("-Wextra")
|
||||
check_build_flag("-Wno-unused-but-set-variable")
|
||||
check_build_flag("-Wno-unused-parameter")
|
||||
check_build_flag("-Wno-sign-compare")
|
||||
check_cflag("-Wno-pointer-sign")
|
||||
check_build_flag("-Wno-missing-field-initializers")
|
||||
check_build_flag("-Wformat=2")
|
||||
check_build_flag("-Wstrict-aliasing=2")
|
||||
check_build_flag("-fno-strict-aliasing")
|
||||
check_build_flag("-Wdisabled-optimization")
|
||||
check_build_flag("-Wfloat-equal")
|
||||
check_build_flag("-Wpointer-arith")
|
||||
check_cflag("-Wdeclaration-after-statement")
|
||||
check_cflag("-Wbad-function-cast")
|
||||
check_build_flag("-Wcast-align")
|
||||
check_build_flag("-Wredundant-decls")
|
||||
check_build_flag("-Wwrite-strings")
|
||||
check_cxxflag("-fexceptions")
|
||||
check_cxxflag("-fimplicit-templates")
|
||||
check_build_flag("-Wno-clobbered")
|
||||
if(MRN_GROONGA_BUNDLED)
|
||||
check_build_flag("-fPIC")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
option(GRN_WITH_DEBUG "enable debug build." OFF)
|
||||
if(GRN_WITH_DEBUG)
|
||||
if(CMAKE_COMPILER_IS_GNUCXX)
|
||||
set(GRN_C_COMPILE_FLAGS "${GRN_C_COMPILE_FLAGS} -g3 -O0")
|
||||
set(GRN_CXX_COMPILE_FLAGS "${GRN_CXX_COMPILE_FLAGS} -g3 -O0")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_definitions(
|
||||
-DHAVE_CONFIG_H
|
||||
)
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUC OR
|
||||
CMAKE_COMPILER_IS_GNUCXX OR
|
||||
CMAKE_C_COMPILER_ID STREQUAL "Clang")
|
||||
set(_GNU_SOURCE TRUE)
|
||||
endif()
|
||||
|
||||
include_directories(
|
||||
BEFORE
|
||||
${CMAKE_CURRENT_BINARY_DIR}
|
||||
${CMAKE_CURRENT_SOURCE_DIR}
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/include
|
||||
)
|
||||
|
||||
macro(ac_check_headers header)
|
||||
string(REGEX REPLACE "[/.]" "_" output_variable_name ${header})
|
||||
string(TOUPPER "${output_variable_name}" output_variable_name)
|
||||
set(output_variable_name "HAVE_${output_variable_name}")
|
||||
# unset(${output_variable_name})
|
||||
check_include_file(${header} ${output_variable_name})
|
||||
endmacro()
|
||||
|
||||
macro(ac_check_funcs function)
|
||||
string(TOUPPER "${function}" output_variable_name)
|
||||
set(output_variable_name "HAVE_${output_variable_name}")
|
||||
# unset(${output_variable_name})
|
||||
check_function_exists(${function} ${output_variable_name})
|
||||
endmacro()
|
||||
|
||||
macro(ac_check_symbols symbol files)
|
||||
string(TOUPPER "${symbol}" output_variable_name)
|
||||
set(output_variable_name "HAVE_${output_variable_name}")
|
||||
# unset(${output_variable_name})
|
||||
check_symbol_exists(${symbol} ${files} ${output_variable_name})
|
||||
endmacro()
|
||||
|
||||
macro(ac_check_lib library function)
|
||||
string(REGEX REPLACE "[/.]" "_" output_variable_base_name ${library})
|
||||
string(TOUPPER "${output_variable_base_name}" output_variable_base_name)
|
||||
set(output_variable_name "HAVE_LIB${output_variable_base_name}")
|
||||
set(location "${ARG2}")
|
||||
# unset(${output_variable_name})
|
||||
check_library_exists(${library} ${function} "${location}"
|
||||
${output_variable_name})
|
||||
if(${output_variable_name})
|
||||
set(${output_variable_base_name}_LIBS "${library}")
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
include(build/ac_macros/check_headers.m4)
|
||||
include(build/ac_macros/check_functions.m4)
|
||||
|
||||
ac_check_symbols(fpclassify math.h)
|
||||
|
||||
ac_check_lib(dl dlopen)
|
||||
ac_check_lib(execinfo backtrace)
|
||||
if(HAVE_LIBEXECINFO)
|
||||
set(HAVE_BACKTRACE TRUE)
|
||||
else()
|
||||
ac_check_funcs(backtrace)
|
||||
endif()
|
||||
ac_check_lib(rt clock_gettime)
|
||||
if(HAVE_LIBRT)
|
||||
set(HAVE_CLOCK_GETTIME TRUE)
|
||||
endif()
|
||||
if(MRN_GROONGA_BUNDLED)
|
||||
ac_check_lib(m sincos)
|
||||
check_library_exists(stdc++ __cxa_begin_catch "${ARG2}"
|
||||
STDCPP)
|
||||
if(STDCPP)
|
||||
set(STDCPP_LIBS "stdc++")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(UNIX)
|
||||
ac_check_headers(pthread.h)
|
||||
ac_check_lib(pthread pthread_mutex_init)
|
||||
if(NOT ${HAVE_LIBPTHREAD})
|
||||
message(FATAL_ERROR "No libpthread found")
|
||||
endif()
|
||||
ac_check_funcs(pthread_mutexattr_setpshared)
|
||||
ac_check_funcs(pthread_condattr_setpshared)
|
||||
endif()
|
||||
|
||||
option(GRN_WITH_NFKC "use NFKC based UTF8 normalization." ON)
|
||||
|
||||
if(WIN32)
|
||||
ac_check_headers(winsock2.h)
|
||||
if(NOT ${HAVE_WINSOCK2_H})
|
||||
message(FATAL_ERROR "No winsock2.h found")
|
||||
endif()
|
||||
|
||||
# FIXME: CMake couldn't detect ws2_32.lib on Windows 8 64bit.
|
||||
# It may be caused by missing library search path for ws2_32.lib.
|
||||
# It seems that Visual Studio (devenv.exe) can find it but link.exe
|
||||
# can't. "cmake --build" can find it because it uses Visual Studio
|
||||
# internally. So we assume that we always have ws2_32.lib on Windows.
|
||||
# ac_check_lib(ws2_32 select)
|
||||
set(HAVE_LIBWS2_32 TRUE)
|
||||
set(WS2_32_LIBS "ws2_32.lib")
|
||||
|
||||
set(USE_SELECT TRUE)
|
||||
else()
|
||||
ac_check_headers(sys/epoll.h)
|
||||
if(${HAVE_SYS_EPOLL_H})
|
||||
ac_check_funcs(epoll_create)
|
||||
if(${HAVE_EPOLL_CREATE})
|
||||
set(USE_EPOLL TRUE)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(NOT USE_EPOLL)
|
||||
ac_check_headers(sys/event.h)
|
||||
if(${HAVE_SYS_EVENT_H})
|
||||
ac_check_funcs(kevent)
|
||||
if(${HAVE_KEVENT})
|
||||
set(USE_KQUEUE TRUE)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(NOT USE_KQUEUE)
|
||||
ac_check_headers(sys/poll.h)
|
||||
if(${HAVE_SYS_POLL_H})
|
||||
ac_check_funcs(poll)
|
||||
if(${HAVE_POLL})
|
||||
set(USE_POLL TRUE)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(NOT USE_POLL)
|
||||
ac_check_funcs(select)
|
||||
if(${HAVE_SELECT})
|
||||
set(USE_SELECT TRUE)
|
||||
ac_check_headers(sys/select.h)
|
||||
endif()
|
||||
|
||||
if(NOT USE_SELECT)
|
||||
message(FATAL_ERROR "All epoll/kqueue/poll/select are missing")
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
option(GRN_WITH_ZLIB "use zlib for data compression." OFF)
|
||||
if(GRN_WITH_ZLIB)
|
||||
ac_check_lib(z compress)
|
||||
if(NOT HAVE_LIBZ)
|
||||
message(FATAL_ERROR "No libz found")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
option(GRN_WITH_LZO "use LZO for data compression." OFF)
|
||||
if(GRN_WITH_LZO)
|
||||
ac_check_lib(lzo2 lzo1_compress)
|
||||
if(NOT HAVE_LIBLZO2)
|
||||
message(FATAL_ERROR "No liblzo2 found")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(GRN_WITH_MECAB "auto"
|
||||
CACHE STRING "use MeCab for morphological analysis")
|
||||
if(NOT ${GRN_WITH_MECAB} STREQUAL "no")
|
||||
set(MECAB_CONFIG "mecab-config" CACHE FILEPATH "mecab-config path")
|
||||
if(NOT CMAKE_CROSSCOMPILING)
|
||||
find_program(MECAB_CONFIG_ABSOLUTE_PATH "${MECAB_CONFIG}")
|
||||
endif()
|
||||
if(EXISTS "${MECAB_CONFIG_ABSOLUTE_PATH}")
|
||||
execute_process(COMMAND "${MECAB_CONFIG_ABSOLUTE_PATH}" --inc-dir
|
||||
OUTPUT_VARIABLE MECAB_INCLUDE_DIRS
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||
execute_process(COMMAND "${MECAB_CONFIG_ABSOLUTE_PATH}" --libs-only-L
|
||||
OUTPUT_VARIABLE MECAB_LIBRARY_DIRS
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||
set(MECAB_LIBRARIES "mecab")
|
||||
ac_check_lib(${MECAB_LIBRARIES} mecab_new)
|
||||
if(HAVE_LIBMECAB)
|
||||
set(GRN_WITH_MECAB TRUE)
|
||||
else()
|
||||
if(${GRN_WITH_MECAB} STREQUAL "yes")
|
||||
message(FATAL_ERROR
|
||||
"No MeCab library found: "
|
||||
"include directories: <${MECAB_INCLUDE_DIRS}>, "
|
||||
"library directories: <${MECAB_LIBRARY_DIRS}>")
|
||||
endif()
|
||||
set(GRN_WITH_MECAB FALSE)
|
||||
endif()
|
||||
else()
|
||||
if(${GRN_WITH_MECAB} STREQUAL "yes")
|
||||
message(FATAL_ERROR "No mecab-config found: <${MECAB_CONFIG}>")
|
||||
endif()
|
||||
set(GRN_WITH_MECAB FALSE)
|
||||
endif()
|
||||
else()
|
||||
set(GRN_WITH_MECAB FALSE)
|
||||
endif()
|
||||
|
||||
set(GRN_WITH_KYTEA "auto"
|
||||
CACHE STRING "use KyTea for morphological analysis")
|
||||
if(NOT ${GRN_WITH_KYTEA} STREQUAL "no")
|
||||
pkg_check_modules(KYTEA kytea)
|
||||
if(KYTEA_FOUND)
|
||||
set(GRN_WITH_KYTEA TRUE)
|
||||
else()
|
||||
if(${GRN_WITH_KYTEA} STREQUAL "yes")
|
||||
message(FATAL_ERROR "No KyTea found")
|
||||
endif()
|
||||
set(GRN_WITH_KYTEA FALSE)
|
||||
endif()
|
||||
else()
|
||||
set(GRN_WITH_KYTEA FALSE)
|
||||
endif()
|
||||
|
||||
set(GRN_WITH_ZEROMQ "auto"
|
||||
CACHE STRING "use ZeroMQ for suggestion")
|
||||
if(NOT ${GRN_WITH_ZEROMQ} STREQUAL "no")
|
||||
pkg_check_modules(ZEROMQ libzmq)
|
||||
if(ZEROMQ_FOUND)
|
||||
set(GRN_WITH_ZEROMQ TRUE)
|
||||
else()
|
||||
if(${GRN_WITH_ZEROMQ} STREQUAL "yes")
|
||||
message(FATAL_ERROR "No ZeroMQ found")
|
||||
endif()
|
||||
set(GRN_WITH_ZEROMQ FALSE)
|
||||
endif()
|
||||
else()
|
||||
set(GRN_WITH_ZEROMQ FALSE)
|
||||
endif()
|
||||
|
||||
set(GRN_WITH_LIBEVENT "auto"
|
||||
CACHE STRING "use libevent for suggestion")
|
||||
if(NOT ${GRN_WITH_LIBEVENT} STREQUAL "no")
|
||||
if("${GRN_WITH_LIBEVENT}" STREQUAL "yes" OR
|
||||
"${GRN_WITH_LIBEVENT}" STREQUAL "auto")
|
||||
set(LIBEVENT_INCLUDE_DIRS "")
|
||||
set(LIBEVENT_LIBRARY_DIRS "")
|
||||
else()
|
||||
set(LIBEVENT_INCLUDE_DIRS "${GRN_WITH_LIBEVENT}/include")
|
||||
set(LIBEVENT_LIBRARY_DIRS "${GRN_WITH_LIBEVENT}/lib")
|
||||
endif()
|
||||
set(CMAKE_REQUIRED_INCLUDES_SAVE ${CMAKE_REQUIRED_INCLUDES})
|
||||
ac_check_lib(event event_init "${LIBEVENT_LIBRARY_DIRS}")
|
||||
set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES_SAVE})
|
||||
if(HAVE_LIBEVENT)
|
||||
set(LIBEVENT_LIBRARIES "event")
|
||||
set(GRN_WITH_LIBEVENT TRUE)
|
||||
else()
|
||||
if(${GRN_WITH_LIBEVENT} STREQUAL "yes")
|
||||
message(FATAL_ERROR "No libevent found")
|
||||
endif()
|
||||
set(GRN_WITH_LIBEVENT FALSE)
|
||||
endif()
|
||||
else()
|
||||
set(GRN_WITH_LIBEVENT FALSE)
|
||||
endif()
|
||||
|
||||
set(GRN_WITH_MESSAGE_PACK "auto"
|
||||
CACHE STRING "use MessagePack for suggestion")
|
||||
if(NOT ${GRN_WITH_MESSAGE_PACK} STREQUAL "no")
|
||||
if("${GRN_WITH_MESSAGE_PACK}" STREQUAL "yes" OR
|
||||
"${GRN_WITH_MESSAGE_PACK}" STREQUAL "auto")
|
||||
set(MESSAGE_PACK_INCLUDE_DIRS "")
|
||||
set(MESSAGE_PACK_LIBRARY_DIRS "")
|
||||
else()
|
||||
set(MESSAGE_PACK_INCLUDE_DIRS "${GRN_WITH_MESSAGE_PACK}/include")
|
||||
set(MESSAGE_PACK_LIBRARY_DIRS "${GRN_WITH_MESSAGE_PACK}/lib")
|
||||
endif()
|
||||
set(CMAKE_REQUIRED_INCLUDES_SAVE ${CMAKE_REQUIRED_INCLUDES})
|
||||
ac_check_lib(msgpack msgpack_version "${MESSAGE_PACK_LIBRARY_DIRS}")
|
||||
set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES_SAVE})
|
||||
if(HAVE_LIBMSGPACK)
|
||||
set(MESSAGE_PACK_LIBRARIES "msgpack")
|
||||
set(GRN_WITH_MESSAGE_PACK TRUE)
|
||||
else()
|
||||
if(${GRN_WITH_MESSAGE_PACK} STREQUAL "yes")
|
||||
message(FATAL_ERROR "No MessagePack found")
|
||||
endif()
|
||||
set(GRN_WITH_MESSAGE_PACK FALSE)
|
||||
endif()
|
||||
else()
|
||||
set(GRN_WITH_MESSAGE_PACK FALSE)
|
||||
endif()
|
||||
|
||||
option(GRN_WITH_MRUBY "use mruby" OFF)
|
||||
if(GRN_WITH_MRUBY)
|
||||
if(CMAKE_VERSION VERSION_LESS "2.8.8")
|
||||
message(FATAL_ERROR
|
||||
"Your CMake (${CMAKE_VERSION}) is old. "
|
||||
"CMake 2.8.8 or later is required for mruby supported build")
|
||||
endif()
|
||||
set(MRUBY_INCLUDE_DIRS
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/vendor/mruby-source/include")
|
||||
set(MRUBY_LIBS "$<TARGET_OBJECTS:mruby>")
|
||||
else()
|
||||
set(MRUBY_INCLUDE_DIRS "")
|
||||
set(MRUBY_LIBS "")
|
||||
endif()
|
||||
|
||||
add_subdirectory(vendor)
|
||||
add_subdirectory(lib)
|
||||
add_subdirectory(src)
|
||||
add_subdirectory(plugins)
|
||||
add_subdirectory(include)
|
||||
add_subdirectory(data)
|
||||
|
||||
configure_file(config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h)
|
||||
|
||||
set(RUBY "ruby") # TODO: support customization
|
||||
set(GROONGA "${CMAKE_CURRENT_BINARY_DIR}/src/groonga")
|
||||
set(GROONGA_SUGGEST_CREATE_DATASET
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/src/suggest/groonga-suggest-create-dataset")
|
||||
set(GROONGA_BENCHMARK "${CMAKE_CURRENT_BINARY_DIR}/src/groonga-benchmark")
|
||||
configure_file(config.sh.in "${CMAKE_CURRENT_BINARY_DIR}/config.sh" @ONLY)
|
||||
|
||||
set(prefix "${CMAKE_INSTALL_PREFIX}")
|
||||
set(exec_prefix "${prefix}")
|
||||
set(bindir "${CMAKE_INSTALL_PREFIX}/${BIN_DIR}")
|
||||
set(sbindir "${CMAKE_INSTALL_PREFIX}/${SBIN_DIR}")
|
||||
set(libdir "${CMAKE_INSTALL_PREFIX}/${LIB_DIR}")
|
||||
set(includedir "${CMAKE_INSTALL_PREFIX}/${INCLUDE_DIR}")
|
||||
set(datarootdir "${CMAKE_INSTALL_PREFIX}/${DATA_DIR}")
|
||||
set(datadir "${datarootdir}")
|
||||
set(expanded_pluginsdir "${GRN_PLUGINS_DIR}")
|
||||
set(GRN_EXPANDED_DEFAULT_DOCUMENT_ROOT "${GRN_DEFAULT_DOCUMENT_ROOT}")
|
||||
set(EXEEXT "${CMAKE_EXECUTABLE_SUFFIX}")
|
||||
configure_file(groonga.pc.in "${CMAKE_CURRENT_BINARY_DIR}/groonga.pc" @ONLY)
|
||||
|
||||
if(NOT MRN_GROONGA_BUNDLED)
|
||||
install(
|
||||
FILES "${CMAKE_CURRENT_BINARY_DIR}/groonga.pc"
|
||||
DESTINATION "${LIB_DIR}/pkgconfig/")
|
||||
endif()
|
||||
|
||||
add_subdirectory(vendor/plugins)
|
||||
135
storage/mroonga/vendor/groonga/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,135 @@
|
|||
# release: update-latest-release (commit) tag
|
||||
|
||||
LOCALES = ja
|
||||
|
||||
ACLOCAL_AMFLAGS = ${ACLOCAL_ARGS} -I .
|
||||
AUTOMAKE_OPTIONS = 1.9.6
|
||||
SUBDIRS = \
|
||||
build \
|
||||
include \
|
||||
vendor \
|
||||
lib \
|
||||
plugins \
|
||||
src \
|
||||
examples \
|
||||
test \
|
||||
benchmark \
|
||||
packages \
|
||||
data \
|
||||
tools \
|
||||
doc
|
||||
#dist_data_DATA =
|
||||
EXTRA_DIST = \
|
||||
README.md \
|
||||
bindings \
|
||||
version-gen.sh \
|
||||
base_version \
|
||||
gpg_uid \
|
||||
CMakeLists.txt \
|
||||
config.h.cmake
|
||||
|
||||
pkgconfigdir = $(libdir)/pkgconfig
|
||||
pkgconfig_DATA = groonga.pc
|
||||
|
||||
.PHONY: FORCE
|
||||
|
||||
FORCE:
|
||||
|
||||
$(srcdir)/version.sh: FORCE
|
||||
@$(SHELL_PATH) $(srcdir)/version-gen.sh
|
||||
|
||||
include $(srcdir)/version.sh
|
||||
|
||||
dist-hook:
|
||||
echo "$(GRN_VERSION)" > $(distdir)/version
|
||||
|
||||
benchmark:
|
||||
cd test/benchmark && $(MAKE) benchmark
|
||||
|
||||
tag:
|
||||
cd $(top_srcdir) && git tag v$(VERSION) -a -m 'Groonga $(VERSION)!!!'
|
||||
|
||||
echo-version:
|
||||
@echo $(VERSION)
|
||||
|
||||
update-latest-release: misc
|
||||
@if test -z "$(OLD_RELEASE)"; then \
|
||||
echo "\$$(OLD_RELEASE) is missing"; \
|
||||
exit 1; \
|
||||
fi
|
||||
@if test -z "$(OLD_RELEASE_DATE)"; then \
|
||||
echo "\$$(OLD_RELEASE_DATE) is missing"; \
|
||||
exit 1; \
|
||||
fi
|
||||
@if test -z "$(NEW_RELEASE_DATE)"; then \
|
||||
echo "\$$(NEW_RELEASE_DATE) is missing"; \
|
||||
exit 1; \
|
||||
fi
|
||||
cd $(top_srcdir) && \
|
||||
misc/update-latest-release.rb \
|
||||
$(PACKAGE) $(OLD_RELEASE) $(OLD_RELEASE_DATE) \
|
||||
$(VERSION) $(NEW_RELEASE_DATE) \
|
||||
packages/rpm/fedora/groonga.spec.in \
|
||||
packages/rpm/centos/groonga.spec.in \
|
||||
packages/debian/changelog \
|
||||
doc/source/install.rst \
|
||||
doc/source/install/*.rst \
|
||||
doc/locale/*/LC_MESSAGES/install.po \
|
||||
$(GROONGA_ORG_PATH)/index.html \
|
||||
$(GROONGA_ORG_PATH)/ja/index.html
|
||||
|
||||
update-po:
|
||||
@for lang in $(LOCALES); do \
|
||||
(cd $(top_srcdir)/doc/locale/$$lang/LC_MESSAGES && $(MAKE) update) \
|
||||
done
|
||||
|
||||
update-document:
|
||||
@if test -z "$(GROONGA_ORG_PATH)"; then \
|
||||
echo "\$$(GROONGA_ORG_PATH) is missing"; \
|
||||
echo "add --with-groonga-github-com-path in configure"; \
|
||||
exit 1; \
|
||||
fi
|
||||
rm -rf tmp-doc
|
||||
mkdir tmp-doc
|
||||
(cd doc && $(MAKE) clean-html)
|
||||
(cd doc && $(MAKE) install docdir=$(abs_srcdir)/tmp-doc/install)
|
||||
ruby $(srcdir)/tools/prepare-sphinx-html.rb tmp-doc/install tmp-doc/dist
|
||||
rm -rf $(GROONGA_ORG_PATH)/docs
|
||||
mv tmp-doc/dist/en $(GROONGA_ORG_PATH)/docs
|
||||
for locale in `cd tmp-doc/dist; echo *`; do \
|
||||
dest_base_dir=$(GROONGA_ORG_PATH)/$${locale}; \
|
||||
mkdir -p $${dest_base_dir}; \
|
||||
dest_dir=$${dest_base_dir}/docs; \
|
||||
rm -rf $${dest_dir}; \
|
||||
mv tmp-doc/dist/$${locale} $${dest_dir}; \
|
||||
done
|
||||
|
||||
|
||||
update-version:
|
||||
@if test -z "$(NEW_VERSION)"; then \
|
||||
echo "\$$(NEW_VERSION) is missing"; \
|
||||
exit 1; \
|
||||
fi
|
||||
@echo -n $(NEW_VERSION) > $(srcdir)/base_version
|
||||
|
||||
update-files:
|
||||
cd doc && $(MAKE) update-files
|
||||
cd data/html && $(MAKE) update-files
|
||||
|
||||
update-mruby:
|
||||
cd $(top_srcdir)/vendor/mruby && make update
|
||||
|
||||
update-nginx:
|
||||
@if test -z "$(NEW_NGINX_VERSION)"; then \
|
||||
echo "\$$(NEW_NGINX_VERSION) is missing"; \
|
||||
exit 1; \
|
||||
fi
|
||||
cd $(top_srcdir)/vendor && ./update_nginx.sh $(NEW_NGINX_VERSION)
|
||||
|
||||
misc:
|
||||
@if test -z "$(CUTTER_SOURCE_PATH)"; then \
|
||||
echo "\$$(CUTTER_SOURCE_PATH) is missing"; \
|
||||
exit 1; \
|
||||
fi
|
||||
ln -s "$(CUTTER_SOURCE_PATH)/misc" misc
|
||||
|
||||
49
storage/mroonga/vendor/groonga/README.md
vendored
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
# README
|
||||
|
||||
Groonga is an open-source fulltext search engine and column store.
|
||||
|
||||
## Reference manual
|
||||
|
||||
See doc/source/ directory or http://groonga.org/docs/.
|
||||
|
||||
## Bundled software
|
||||
|
||||
### mruby
|
||||
|
||||
* Path: vendor/mruby-source
|
||||
* License: The MIT license. See vendor/mruby-source/MITL for details.
|
||||
|
||||
### Onigmo
|
||||
|
||||
* Path: vendor/onigmo-source
|
||||
* License: BSD license. See vendor/onigmo-source/COPYING for details.
|
||||
|
||||
### nginx
|
||||
|
||||
* Path: vendor/nginx-${VERSION}
|
||||
* License: BSD license. See vendor/nginx-${VERSION}/LICENSE for details.
|
||||
|
||||
## Authors
|
||||
|
||||
### Primary authors
|
||||
|
||||
* Daijiro MORI <morita at razil. jp>
|
||||
* Tasuku SUENAGA <a at razil. jp>
|
||||
* Yutaro Shimamura <yu at razil. jp>
|
||||
* Kouhei Sutou <kou at cozmixng. org>
|
||||
* Kazuho Oku <kazuhooku at gmail. com>
|
||||
* Moriyoshi Koizumi <moriyoshi at gmail. com>
|
||||
|
||||
### Patches and modules from
|
||||
|
||||
TODO: Update or use
|
||||
https://github.com/groonga/groonga/graphs/contributors instead.
|
||||
|
||||
* Daisuke Maki <dmaki at cpan. org>
|
||||
* Kazuhiro Osawa <ko at yappo. ne. jp>
|
||||
* Hiroyuki OYAMA <oyama at module. jp>
|
||||
* Nguyen Anh Phu <phuna at users. sourceforge. net>
|
||||
* Hideyuki KUROSU <hideyuki. kurosu at gmail. com>
|
||||
* Takuo Kitame <kitame at valinux. co. jp>
|
||||
* Yoshihiro Oyama <yos-o at smilemark. com>
|
||||
* cZfSunOs.U <sunos at saita. ma>
|
||||
21
storage/mroonga/vendor/groonga/autogen.sh
vendored
Executable file
|
|
@ -0,0 +1,21 @@
|
|||
#!/bin/sh
|
||||
|
||||
./version-gen.sh
|
||||
|
||||
case `uname -s` in
|
||||
Darwin)
|
||||
homebrew_aclocal=/usr/local/share/aclocal
|
||||
if [ -d $homebrew_aclocal ]; then
|
||||
ACLOCAL_ARGS="$ACLOCAL_ARGS -I $homebrew_aclocal"
|
||||
fi
|
||||
gettext_aclocal="$(echo /usr/local/Cellar/gettext/*/share/aclocal)"
|
||||
if [ -d $gettext_aclocal ]; then
|
||||
ACLOCAL_ARGS="$ACLOCAL_ARGS -I $gettext_aclocal"
|
||||
fi
|
||||
;;
|
||||
FreeBSD)
|
||||
ACLOCAL_ARGS="$ACLOCAL_ARGS -I /usr/local/share/aclocal/"
|
||||
;;
|
||||
esac
|
||||
|
||||
${AUTORECONF:-autoreconf} --force --install
|
||||
1
storage/mroonga/vendor/groonga/base_version
vendored
Normal file
|
|
@ -0,0 +1 @@
|
|||
4.0.5
|
||||
89
storage/mroonga/vendor/groonga/benchmark/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,89 @@
|
|||
SUBDIRS = \
|
||||
fixtures \
|
||||
lib
|
||||
|
||||
NONEXISTENT_CXX_SOURCE = nonexistent.cpp
|
||||
|
||||
if WITH_BENCHMARK
|
||||
noinst_PROGRAMS = \
|
||||
bench-table-factory \
|
||||
bench-geo-distance \
|
||||
bench-geo-select \
|
||||
bench-ctx-create \
|
||||
bench-query-optimizer
|
||||
endif
|
||||
|
||||
EXTRA_DIST = \
|
||||
bench-query-optimizer-ddl.grn
|
||||
|
||||
AM_CPPFLAGS = \
|
||||
-I$(srcdir) \
|
||||
-I$(srcdir)/lib \
|
||||
-I$(top_srcdir)/include \
|
||||
-I$(top_srcdir)/lib \
|
||||
$(GROONGA_INCLUDEDIR)
|
||||
|
||||
AM_CFLAGS = \
|
||||
$(GLIB_CFLAGS)
|
||||
|
||||
LIBS = \
|
||||
$(top_builddir)/lib/libgroonga.la \
|
||||
$(top_builddir)/benchmark/lib/libbenchmark.la \
|
||||
$(GLIB_LIBS)
|
||||
|
||||
bench_table_factory_SOURCES = bench-table-factory.c
|
||||
nodist_EXTRA_bench_table_factory_SOURCES = $(NONEXISTENT_CXX_SOURCE)
|
||||
|
||||
bench_geo_distance_SOURCES = bench-geo-distance.c
|
||||
nodist_EXTRA_bench_geo_distance_SOURCES = $(NONEXISTENT_CXX_SOURCE)
|
||||
|
||||
bench_geo_select_SOURCES = bench-geo-select.c
|
||||
nodist_EXTRA_bench_geo_select_SOURCES = $(NONEXISTENT_CXX_SOURCE)
|
||||
|
||||
bench_ctx_create_SOURCES = bench-ctx-create.c
|
||||
nodist_EXTRA_bench_ctx_create_SOURCES = $(NONEXISTENT_CXX_SOURCE)
|
||||
|
||||
bench_query_optimizer_SOURCES = bench-query-optimizer.c
|
||||
nodist_EXTRA_bench_query_optimizer_SOURCES = $(NONEXISTENT_CXX_SOURCE)
|
||||
|
||||
benchmarks = \
|
||||
run-bench-table-factory \
|
||||
run-bench-geo-distance \
|
||||
run-bench-geo-select \
|
||||
run-bench-ctx-create \
|
||||
run-bench-query-optimizer
|
||||
|
||||
run-bench-table-factory: bench-table-factory
|
||||
@echo $@:
|
||||
./bench-table-factory
|
||||
|
||||
run-bench-geo-distance: bench-geo-distance
|
||||
@echo $@:
|
||||
./bench-geo-distance
|
||||
|
||||
run-bench-geo-select: bench-geo-select
|
||||
@echo $@:
|
||||
env \
|
||||
RUBY="$(RUBY)" \
|
||||
GROONGA="$(GROONGA)" \
|
||||
srcdir="$(srcdir)" \
|
||||
$(srcdir)/bench-geo-select.sh
|
||||
|
||||
run-bench-ctx-create: bench-ctx-create
|
||||
@echo $@:
|
||||
./bench-ctx-create
|
||||
|
||||
run-bench-query-optimizer: bench-query-optimizer
|
||||
@echo $@:
|
||||
@rm -rf tmp/query-optimizer
|
||||
@mkdir -p tmp/query-optimizer
|
||||
@env \
|
||||
GRN_RUBY_SCRIPTS_DIR=$(top_srcdir)/lib/mrb/scripts \
|
||||
../src/groonga \
|
||||
--file $(srcdir)/bench-query-optimizer-ddl.grn \
|
||||
-n tmp/query-optimizer/db > /dev/null
|
||||
env \
|
||||
GRN_RUBY_SCRIPTS_DIR=$(top_srcdir)/lib/mrb/scripts \
|
||||
./bench-query-optimizer
|
||||
|
||||
benchmark: $(benchmarks)
|
||||
192
storage/mroonga/vendor/groonga/benchmark/bench-ctx-create.c
vendored
Normal file
|
|
@ -0,0 +1,192 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2013-2014 Kouhei Sutou <kou@clear-code.com>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/*
|
||||
Groonga: 6b128f318d682e50648f3b82c5f7956f3bcb3fe8
|
||||
CFLAGS: -O0 -g3
|
||||
% (cd benchmark/ && make --quiet run-bench-ctx-create)
|
||||
run-bench-ctx-create:
|
||||
(time)
|
||||
with mruby1: 288KB (0.0091s)
|
||||
without mruby1: 28KB (0.0240ms)
|
||||
with mruby2: 0KB (0.0097s)
|
||||
without mruby2: 0KB (0.0220ms)
|
||||
|
||||
Groonga: c4379140c02699e3c74b94cd9e7b88d372202aa5
|
||||
CFLAGS: -O2 -g
|
||||
% make --quiet -C benchmark run-bench-ctx-create
|
||||
run-bench-ctx-create:
|
||||
(time)
|
||||
with mruby1: 524KB (0.0041s)
|
||||
without mruby1: 32KB (0.0220ms)
|
||||
with mruby2: 0KB (0.0040s)
|
||||
without mruby2: 0KB (0.0200ms)
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
#include <groonga.h>
|
||||
|
||||
#include "lib/benchmark.h"
|
||||
|
||||
typedef struct _BenchmarkData {
|
||||
grn_ctx context;
|
||||
grn_obj *database;
|
||||
guint memory_usage_before;
|
||||
} BenchmarkData;
|
||||
|
||||
static guint
|
||||
get_memory_usage(void)
|
||||
{
|
||||
GRegex *vm_rss_pattern;
|
||||
gchar *status;
|
||||
GMatchInfo *match_info;
|
||||
gchar *vm_rss_string;
|
||||
guint vm_rss;
|
||||
|
||||
g_file_get_contents("/proc/self/status", &status, NULL, NULL);
|
||||
|
||||
vm_rss_pattern = g_regex_new("VmRSS:\\s*(\\d*)\\s+kB", 0, 0, NULL);
|
||||
if (!g_regex_match(vm_rss_pattern, status, 0, &match_info)) {
|
||||
g_print("not match...: %s\n", status);
|
||||
return 0;
|
||||
}
|
||||
vm_rss_string = g_match_info_fetch(match_info, 1);
|
||||
vm_rss = atoi(vm_rss_string);
|
||||
g_free(vm_rss_string);
|
||||
g_match_info_free(match_info);
|
||||
g_regex_unref(vm_rss_pattern);
|
||||
g_free(status);
|
||||
|
||||
return vm_rss;
|
||||
}
|
||||
|
||||
static void
|
||||
bench_with_mruby(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
g_setenv("GRN_MRUBY_ENABLED", "yes", TRUE);
|
||||
grn_ctx_init(&(data->context), 0);
|
||||
grn_ctx_use(&(data->context), data->database);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_without_mruby(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
g_setenv("GRN_MRUBY_ENABLED", "no", TRUE);
|
||||
grn_ctx_init(&(data->context), 0);
|
||||
grn_ctx_use(&(data->context), data->database);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
data->memory_usage_before = get_memory_usage();
|
||||
}
|
||||
|
||||
static void
|
||||
bench_teardown(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
grn_ctx_fin(&(data->context));
|
||||
g_print("%3dKB ", get_memory_usage() - data->memory_usage_before);
|
||||
}
|
||||
|
||||
static gchar *
|
||||
get_tmp_dir(void)
|
||||
{
|
||||
gchar *current_dir;
|
||||
gchar *tmp_dir;
|
||||
|
||||
current_dir = g_get_current_dir();
|
||||
tmp_dir = g_build_filename(current_dir, "tmp", NULL);
|
||||
g_free(current_dir);
|
||||
|
||||
return tmp_dir;
|
||||
}
|
||||
|
||||
static grn_obj *
|
||||
setup_database(grn_ctx *context)
|
||||
{
|
||||
gchar *tmp_dir;
|
||||
gchar *database_path;
|
||||
grn_obj *database;
|
||||
|
||||
tmp_dir = get_tmp_dir();
|
||||
database_path = g_build_filename(tmp_dir, "ctx-create", "db", NULL);
|
||||
database = grn_db_open(context, database_path);
|
||||
|
||||
g_free(database_path);
|
||||
|
||||
return database;
|
||||
}
|
||||
|
||||
static void
|
||||
teardown_database(grn_ctx *context, grn_obj *database)
|
||||
{
|
||||
grn_obj_close(context, database);
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, gchar **argv)
|
||||
{
|
||||
grn_ctx context;
|
||||
BenchmarkData data;
|
||||
BenchReporter *reporter;
|
||||
gint n = 1;
|
||||
|
||||
grn_init();
|
||||
bench_init(&argc, &argv);
|
||||
|
||||
grn_ctx_init(&context, 0);
|
||||
|
||||
data.database = setup_database(&context);
|
||||
|
||||
reporter = bench_reporter_new();
|
||||
|
||||
#define REGISTER(label, bench_function) \
|
||||
bench_reporter_register(reporter, label, n, \
|
||||
bench_setup, \
|
||||
bench_function, \
|
||||
bench_teardown, \
|
||||
&data)
|
||||
REGISTER("with mruby1", bench_with_mruby);
|
||||
REGISTER("without mruby1", bench_without_mruby);
|
||||
REGISTER("with mruby2", bench_with_mruby);
|
||||
REGISTER("without mruby2", bench_without_mruby);
|
||||
#undef REGISTER
|
||||
|
||||
bench_reporter_run(reporter);
|
||||
g_object_unref(reporter);
|
||||
|
||||
teardown_database(&context, data.database);
|
||||
|
||||
grn_ctx_fin(&context);
|
||||
|
||||
grn_fin();
|
||||
|
||||
return 0;
|
||||
}
|
||||
499
storage/mroonga/vendor/groonga/benchmark/bench-geo-distance.c
vendored
Normal file
|
|
@ -0,0 +1,499 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2009 Kouhei Sutou <kou@clear-code.com>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/*
|
||||
groonga: 3ad91b868909444f66a36dbcbdbe2292ed14bd72
|
||||
CFLAGS: -O0 -g
|
||||
CPU: AMD Athlon(tm) 64 Processor 3000+
|
||||
|
||||
% test/benchmark/bench-geo-distance
|
||||
(time)
|
||||
rectangular (WGS84): (0.0813662)
|
||||
rectangular (TOKYO): (0.0621928)
|
||||
spherical (WGS84): (0.0760155)
|
||||
spherical (TOKYO): (0.0660843)
|
||||
hubeny (WGS84): (0.110684)
|
||||
hubeny (TOKYO): (0.0702277)
|
||||
% test/benchmark/bench-geo-distance
|
||||
(time)
|
||||
rectangular (WGS84): (0.0742154)
|
||||
rectangular (TOKYO): (0.0816863)
|
||||
spherical (WGS84): (0.074316)
|
||||
spherical (TOKYO): (0.0696254)
|
||||
hubeny (WGS84): (0.0650147)
|
||||
hubeny (TOKYO): (0.0644057)
|
||||
% test/benchmark/bench-geo-distance
|
||||
(time)
|
||||
rectangular (WGS84): (0.0781161)
|
||||
rectangular (TOKYO): (0.0706679)
|
||||
spherical (WGS84): (0.075739)
|
||||
spherical (TOKYO): (0.0809402)
|
||||
hubeny (WGS84): (0.0727023)
|
||||
hubeny (TOKYO): (0.0718146)
|
||||
*/
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include <db.h>
|
||||
#include <groonga.h>
|
||||
|
||||
#include "lib/benchmark.h"
|
||||
|
||||
#define GET(context, name) (grn_ctx_get(context, name, strlen(name)))
|
||||
|
||||
grn_obj *grn_expr_get_value(grn_ctx *ctx, grn_obj *expr, int offset);
|
||||
|
||||
typedef struct _BenchmarkData
|
||||
{
|
||||
gchar *base_dir;
|
||||
gboolean report_result;
|
||||
|
||||
grn_ctx *context;
|
||||
grn_obj *database;
|
||||
grn_obj *geo_distance_proc;
|
||||
grn_obj *expression;
|
||||
grn_obj *start_point;
|
||||
grn_obj *end_point;
|
||||
} BenchmarkData;
|
||||
|
||||
static void
|
||||
bench_geo_distance(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
grn_proc_call(data->context, data->geo_distance_proc,
|
||||
2, data->expression);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_common(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
grn_ctx_init(data->context, GRN_CTX_USE_QL);
|
||||
data->database = grn_db_create(data->context, NULL, NULL);
|
||||
data->expression = grn_expr_create(data->context, NULL, 0);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_points(gpointer user_data,
|
||||
const gchar *start_point_string,
|
||||
const gchar *end_point_string,
|
||||
grn_builtin_type wgs84_or_tgs)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
grn_obj start_point_text, end_point_text;
|
||||
|
||||
GRN_TEXT_INIT(&start_point_text, 0);
|
||||
GRN_TEXT_INIT(&end_point_text, 0);
|
||||
GRN_TEXT_SETS(data->context, &start_point_text, start_point_string);
|
||||
GRN_TEXT_SETS(data->context, &end_point_text, end_point_string);
|
||||
|
||||
data->start_point = grn_obj_open(data->context, GRN_BULK, 0, wgs84_or_tgs);
|
||||
data->end_point = grn_obj_open(data->context, GRN_BULK, 0, wgs84_or_tgs);
|
||||
grn_obj_cast(data->context, &start_point_text, data->start_point, GRN_FALSE);
|
||||
grn_obj_cast(data->context, &end_point_text, data->end_point, GRN_FALSE);
|
||||
grn_ctx_push(data->context, data->start_point);
|
||||
grn_ctx_push(data->context, data->end_point);
|
||||
|
||||
grn_obj_unlink(data->context, &start_point_text);
|
||||
grn_obj_unlink(data->context, &end_point_text);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_wgs84(gpointer user_data)
|
||||
{
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"127980000x502560000",
|
||||
"128880000x503640000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_tgs(gpointer user_data)
|
||||
{
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"127980000x502560000",
|
||||
"128880000x503640000",
|
||||
GRN_DB_TOKYO_GEO_POINT);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_wgs84(user_data);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_tgs(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_tgs(user_data);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_1st_to_2nd_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"128452975x503157902",
|
||||
"139380000x-31920000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_2nd_to_1st_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"139380000x-31920000",
|
||||
"128452975x503157902",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_1st_to_3rd_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"128452975x503157902",
|
||||
"-56880000x-172310000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_3rd_to_1st_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-56880000x-172310000",
|
||||
"128452975x503157902",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_1st_to_4th_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"128452975x503157902",
|
||||
"-122100000x66300000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_4th_to_1st_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-122100000x66300000",
|
||||
"128452975x503157902",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_2nd_to_4th_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"139380000x-31920000",
|
||||
"-122100000x66300000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_4th_to_2nd_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-122100000x66300000",
|
||||
"139380000x-31920000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_1st_to_2nd_quadrant_long(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"128452975x503157902",
|
||||
"135960000x-440760000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_2nd_to_1st_quadrant_long(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"135960000x-440760000",
|
||||
"128452975x503157902",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_2nd_to_3rd_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"135960000x-440760000",
|
||||
"-56880000x-172310000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_3rd_to_2nd_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-56880000x-172310000",
|
||||
"135960000x-440760000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_3rd_to_4th_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-56880000x-172310000",
|
||||
"-122100000x66300000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_4th_to_3rd_quadrant_short(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-122100000x66300000",
|
||||
"-56880000x-172310000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_3rd_to_4th_quadrant_long(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-56880000x-172310000",
|
||||
"-121926000x544351000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_rectangular_wgs84_4th_to_3rd_quadrant_long(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_points(user_data,
|
||||
"-121926000x544351000",
|
||||
"-56880000x-172310000",
|
||||
GRN_DB_WGS84_GEO_POINT);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_spherical_wgs84(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_wgs84(user_data);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance2");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_spherical_tgs(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_tgs(user_data);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance2");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_hubeny_wgs84(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_wgs84(user_data);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance3");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_hubeny_tgs(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
bench_setup_tgs(user_data);
|
||||
data->geo_distance_proc = GET(data->context, "geo_distance3");
|
||||
}
|
||||
|
||||
static void
|
||||
bench_teardown(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
if (data->report_result) {
|
||||
grn_obj *result;
|
||||
result = grn_expr_get_value(data->context, data->expression, 0);
|
||||
g_print("result: %g\n", GRN_FLOAT_VALUE(result));
|
||||
/* http://vldb.gsi.go.jp/ says '38820.79' in WGS84 and
|
||||
'38816.42' in Tokyo geodetic system for a distance
|
||||
between '127980000x502560000' and '128880000x503640000'. */
|
||||
}
|
||||
|
||||
grn_obj_unlink(data->context, data->end_point);
|
||||
grn_obj_unlink(data->context, data->start_point);
|
||||
grn_obj_unlink(data->context, data->expression);
|
||||
grn_obj_unlink(data->context, data->database);
|
||||
grn_ctx_fin(data->context);
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, gchar **argv)
|
||||
{
|
||||
BenchmarkData data;
|
||||
BenchReporter *reporter;
|
||||
gint n = 1000;
|
||||
|
||||
grn_init();
|
||||
bench_init(&argc, &argv);
|
||||
|
||||
data.report_result = g_getenv("GROONGA_BENCH_REPORT_RESULT") != NULL;
|
||||
data.context = g_new(grn_ctx, 1);
|
||||
|
||||
{
|
||||
const gchar *groonga_bench_n;
|
||||
groonga_bench_n = g_getenv("GROONGA_BENCH_N");
|
||||
if (groonga_bench_n) {
|
||||
n = atoi(groonga_bench_n);
|
||||
}
|
||||
}
|
||||
|
||||
reporter = bench_reporter_new();
|
||||
|
||||
#define REGISTER(label, setup) \
|
||||
bench_reporter_register(reporter, label, n, \
|
||||
bench_setup_ ## setup, \
|
||||
bench_geo_distance, \
|
||||
bench_teardown, \
|
||||
&data)
|
||||
REGISTER("rectangular (WGS84)", rectangular_wgs84);
|
||||
REGISTER("rectangular (TOKYO)", rectangular_tgs);
|
||||
REGISTER("rectangular (WGS84 Tokyo to Lisbon)",
|
||||
rectangular_wgs84_1st_to_2nd_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Lisbon to Tokyo)",
|
||||
rectangular_wgs84_2nd_to_1st_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Tokyo to San Francisco)",
|
||||
rectangular_wgs84_1st_to_2nd_quadrant_long);
|
||||
REGISTER("rectangular (WGS84 San Francisco to Tokyo)",
|
||||
rectangular_wgs84_2nd_to_1st_quadrant_long);
|
||||
REGISTER("rectangular (WGS84 Brasplia to Cape Town)",
|
||||
rectangular_wgs84_3rd_to_4th_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Cape Town to Brasplia)",
|
||||
rectangular_wgs84_4th_to_3rd_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Brasplia to Sydney)",
|
||||
rectangular_wgs84_3rd_to_4th_quadrant_long);
|
||||
REGISTER("rectangular (WGS84 Sydney to Brasplia)",
|
||||
rectangular_wgs84_4th_to_3rd_quadrant_long);
|
||||
REGISTER("rectangular (WGS84 Tokyo to Brasplia)",
|
||||
rectangular_wgs84_1st_to_4th_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Brasplia to Tokyo)",
|
||||
rectangular_wgs84_4th_to_1st_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Lisbon to Cape Town)",
|
||||
rectangular_wgs84_2nd_to_3rd_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Cape Town to Lisbon)",
|
||||
rectangular_wgs84_3rd_to_2nd_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Tokyo to Cape Town)",
|
||||
rectangular_wgs84_1st_to_3rd_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Cape Town to Tokyo)",
|
||||
rectangular_wgs84_3rd_to_1st_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Lisbon to Cape Town)",
|
||||
rectangular_wgs84_2nd_to_4th_quadrant_short);
|
||||
REGISTER("rectangular (WGS84 Cape Town to Lisbon)",
|
||||
rectangular_wgs84_4th_to_2nd_quadrant_short);
|
||||
REGISTER("spherical (WGS84)", spherical_wgs84);
|
||||
REGISTER("spherical (TOKYO)", spherical_tgs);
|
||||
REGISTER("hubeny (WGS84)", hubeny_wgs84);
|
||||
REGISTER("hubeny (TOKYO)", hubeny_tgs);
|
||||
#undef REGISTER
|
||||
|
||||
bench_reporter_run(reporter);
|
||||
g_object_unref(reporter);
|
||||
|
||||
g_free(data.context);
|
||||
|
||||
bench_quit();
|
||||
grn_fin();
|
||||
|
||||
return 0;
|
||||
}
|
||||
269
storage/mroonga/vendor/groonga/benchmark/bench-geo-select.c
vendored
Normal file
|
|
@ -0,0 +1,269 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2011 Kouhei Sutou <kou@clear-code.com>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/*
|
||||
groonga: f56f466a05d756336f26ea5c2e54e9bdf5d3d681
|
||||
CFLAGS: -O0 -ggdb3
|
||||
CPU: Intel(R) Core(TM) i7 CPU 860 @ 2.80GHz stepping 05
|
||||
% (cd test/benchmark/ && make --quiet run-bench-geo-select)
|
||||
run-bench-geo-select:
|
||||
(time)
|
||||
1st: select_in_rectangle (partial): (0.819828)
|
||||
2nd: select_in_rectangle (partial): (0.832293)
|
||||
1st: select_in_rectangle (all): (8.82504)
|
||||
2nd: select_in_rectangle (all): (8.97628)
|
||||
|
||||
% (cd test/benchmark; GRN_GEO_CURSOR_STRICTLY=yes make --quiet run-bench-geo-select)
|
||||
run-bench-geo-select:
|
||||
(time)
|
||||
1st: select_in_rectangle (partial): (0.528143)
|
||||
2nd: select_in_rectangle (partial): (0.518647)
|
||||
1st: select_in_rectangle (all): (8.77378)
|
||||
2nd: select_in_rectangle (all): (8.76765)
|
||||
|
||||
groonga: f56f466a05d756336f26ea5c2e54e9bdf5d3d681
|
||||
CFLAGS: -O3 -ggdb3
|
||||
CPU: Intel(R) Core(TM) i7 CPU 860 @ 2.80GHz stepping 05
|
||||
% (cd test/benchmark/ && make --quiet run-bench-geo-select)
|
||||
run-bench-geo-select:
|
||||
(time)
|
||||
1st: select_in_rectangle (partial): (0.415439)
|
||||
2nd: select_in_rectangle (partial): (0.423479)
|
||||
1st: select_in_rectangle (all): (4.63983)
|
||||
2nd: select_in_rectangle (all): (4.53055)
|
||||
|
||||
% (cd test/benchmark; GRN_GEO_CURSOR_STRICTLY=yes make --quiet run-bench-geo-select)
|
||||
run-bench-geo-select:
|
||||
(time)
|
||||
1st: select_in_rectangle (partial): (0.26974)
|
||||
2nd: select_in_rectangle (partial): (0.250247)
|
||||
1st: select_in_rectangle (all): (4.45263)
|
||||
2nd: select_in_rectangle (all): (4.61558)
|
||||
*/
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include <db.h>
|
||||
#include <groonga.h>
|
||||
|
||||
#include "lib/benchmark.h"
|
||||
|
||||
#define GET(context, name) (grn_ctx_get(context, name, strlen(name)))
|
||||
|
||||
typedef struct _BenchmarkData
|
||||
{
|
||||
gboolean report_result;
|
||||
|
||||
grn_ctx *context;
|
||||
grn_obj *database;
|
||||
grn_obj *table;
|
||||
grn_obj *index_column;
|
||||
grn_obj *result;
|
||||
|
||||
grn_obj top_left_point;
|
||||
grn_obj bottom_right_point;
|
||||
} BenchmarkData;
|
||||
|
||||
static void
|
||||
set_geo_point(grn_ctx *context, grn_obj *geo_point, const gchar *geo_point_text)
|
||||
{
|
||||
grn_obj point_text;
|
||||
|
||||
GRN_TEXT_INIT(&point_text, 0);
|
||||
GRN_TEXT_PUTS(context, &point_text, geo_point_text);
|
||||
grn_obj_cast(context, &point_text, geo_point, GRN_FALSE);
|
||||
grn_obj_unlink(context, &point_text);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_common(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
const gchar *tokyo_station = "35.68136,139.76609";
|
||||
const gchar *ikebukuro_station = "35.72890,139.71036";
|
||||
|
||||
data->result = grn_table_create(data->context, NULL, 0, NULL,
|
||||
GRN_OBJ_TABLE_HASH_KEY | GRN_OBJ_WITH_SUBREC,
|
||||
data->table, NULL);
|
||||
|
||||
set_geo_point(data->context, &(data->top_left_point),
|
||||
ikebukuro_station);
|
||||
set_geo_point(data->context, &(data->bottom_right_point),
|
||||
tokyo_station);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_query_partial(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
const gchar *tokyo_station = "35.68136,139.76609";
|
||||
const gchar *ikebukuro_station = "35.72890,139.71036";
|
||||
|
||||
set_geo_point(data->context, &(data->top_left_point),
|
||||
ikebukuro_station);
|
||||
set_geo_point(data->context, &(data->bottom_right_point),
|
||||
tokyo_station);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_query_all(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
const gchar *tokyo_station = "35.0,140.0";
|
||||
const gchar *ikebukuro_station = "36.0,139.0";
|
||||
|
||||
set_geo_point(data->context, &(data->top_left_point),
|
||||
ikebukuro_station);
|
||||
set_geo_point(data->context, &(data->bottom_right_point),
|
||||
tokyo_station);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_in_rectangle_partial(gpointer user_data)
|
||||
{
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_query_partial(user_data);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup_in_rectangle_all(gpointer user_data)
|
||||
{
|
||||
bench_setup_common(user_data);
|
||||
bench_setup_query_all(user_data);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_geo_select_in_rectangle(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
grn_geo_select_in_rectangle(data->context,
|
||||
data->index_column,
|
||||
&(data->top_left_point),
|
||||
&(data->bottom_right_point),
|
||||
data->result,
|
||||
GRN_OP_OR);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_teardown(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
if (data->report_result) {
|
||||
g_print("result: %d\n", grn_table_size(data->context, data->result));
|
||||
}
|
||||
|
||||
grn_obj_unlink(data->context, data->result);
|
||||
}
|
||||
|
||||
static gchar *
|
||||
get_tmp_dir(void)
|
||||
{
|
||||
gchar *current_dir;
|
||||
gchar *tmp_dir;
|
||||
|
||||
current_dir = g_get_current_dir();
|
||||
tmp_dir = g_build_filename(current_dir, "tmp", NULL);
|
||||
g_free(current_dir);
|
||||
|
||||
return tmp_dir;
|
||||
}
|
||||
|
||||
static void
|
||||
setup_database(BenchmarkData *data)
|
||||
{
|
||||
gchar *tmp_dir;
|
||||
gchar *database_path;
|
||||
|
||||
tmp_dir = get_tmp_dir();
|
||||
database_path = g_build_filename(tmp_dir, "geo-select", "db", NULL);
|
||||
data->database = grn_db_open(data->context, database_path);
|
||||
|
||||
data->table = GET(data->context, "Addresses");
|
||||
data->index_column = GET(data->context, "Locations.address");
|
||||
|
||||
g_free(database_path);
|
||||
}
|
||||
|
||||
static void
|
||||
teardown_database(BenchmarkData *data)
|
||||
{
|
||||
grn_obj_unlink(data->context, data->index_column);
|
||||
grn_obj_unlink(data->context, data->table);
|
||||
grn_obj_unlink(data->context, data->database);
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, gchar **argv)
|
||||
{
|
||||
BenchmarkData data;
|
||||
BenchReporter *reporter;
|
||||
gint n = 100;
|
||||
|
||||
grn_init();
|
||||
bench_init(&argc, &argv);
|
||||
|
||||
data.report_result = g_getenv("GROONGA_BENCH_REPORT_RESULT") != NULL;
|
||||
|
||||
data.context = g_new(grn_ctx, 1);
|
||||
grn_ctx_init(data.context, 0);
|
||||
|
||||
setup_database(&data);
|
||||
GRN_WGS84_GEO_POINT_INIT(&(data.top_left_point), 0);
|
||||
GRN_WGS84_GEO_POINT_INIT(&(data.bottom_right_point), 0);
|
||||
|
||||
{
|
||||
const gchar *groonga_bench_n;
|
||||
groonga_bench_n = g_getenv("GROONGA_BENCH_N");
|
||||
if (groonga_bench_n) {
|
||||
n = atoi(groonga_bench_n);
|
||||
}
|
||||
}
|
||||
|
||||
reporter = bench_reporter_new();
|
||||
|
||||
#define REGISTER(label, type, area) \
|
||||
bench_reporter_register(reporter, \
|
||||
label, \
|
||||
n, \
|
||||
bench_setup_ ## type ## _ ## area, \
|
||||
bench_geo_select_ ## type, \
|
||||
bench_teardown, \
|
||||
&data)
|
||||
REGISTER("1st: select_in_rectangle (partial)", in_rectangle, partial);
|
||||
REGISTER("2nd: select_in_rectangle (partial)", in_rectangle, partial);
|
||||
REGISTER("1st: select_in_rectangle (all)", in_rectangle, all);
|
||||
REGISTER("2nd: select_in_rectangle (all)", in_rectangle, all);
|
||||
#undef REGISTER
|
||||
|
||||
bench_reporter_run(reporter);
|
||||
g_object_unref(reporter);
|
||||
|
||||
grn_obj_unlink(data.context, &(data.top_left_point));
|
||||
grn_obj_unlink(data.context, &(data.bottom_right_point));
|
||||
teardown_database(&data);
|
||||
|
||||
grn_ctx_fin(data.context);
|
||||
g_free(data.context);
|
||||
|
||||
bench_quit();
|
||||
grn_fin();
|
||||
|
||||
return 0;
|
||||
}
|
||||
38
storage/mroonga/vendor/groonga/benchmark/bench-geo-select.sh
vendored
Executable file
|
|
@ -0,0 +1,38 @@
|
|||
#!/bin/sh
|
||||
|
||||
base_dir="$(dirname $0)"
|
||||
|
||||
fixture_dir="${srcdir}/fixtures/geo-select"
|
||||
data_dir="${base_dir}/fixtures/geo-select"
|
||||
csv_xz="${fixture_dir}/13_2010.CSV.xz"
|
||||
csv="${data_dir}/13_2010.CSV"
|
||||
grn="${data_dir}/load.grn"
|
||||
|
||||
geo_select_generate_grn_rb="${base_dir}/geo-select-generate-grn.rb"
|
||||
|
||||
db="${base_dir}/tmp/geo-select/db"
|
||||
|
||||
bench_geo_select="./bench-geo-select"
|
||||
|
||||
mkdir -p "${data_dir}"
|
||||
if [ ! -s "${csv}" ] || [ "${csv}" -ot "${csv_xz}" ]; then
|
||||
echo "extracting ${csv_xz}..."
|
||||
xzcat "${csv_xz}" | iconv --from-code cp932 --to-code utf-8 > "${csv}"
|
||||
fi
|
||||
|
||||
if [ ! -s "${grn}" ] || [ "${grn}" -ot "${csv}" ]; then
|
||||
echo "generating test data..."
|
||||
"${RUBY}" "${geo_select_generate_grn_rb}" "${csv}" "${grn}"
|
||||
fi
|
||||
|
||||
if [ ! -s "${db}" ] || [ "${db}" -ot "${grn}" ]; then
|
||||
echo "creating test database..."
|
||||
rm -rf "$(dirname ${db})"
|
||||
mkdir -p "$(dirname ${db})"
|
||||
"${GROONGA}" -n "${db}" < "${grn}"
|
||||
fi
|
||||
|
||||
if [ "${GROONGA_BENCH_DEBUG}" = "yes" ]; then
|
||||
bench_geo_select="../../libtool --mode=execute gdb --args ${bench_geo_select}"
|
||||
fi
|
||||
${bench_geo_select}
|
||||
16
storage/mroonga/vendor/groonga/benchmark/bench-query-optimizer-ddl.grn
vendored
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
table_create Entries TABLE_PAT_KEY ShortText
|
||||
column_create Entries name COLUMN_SCALAR ShortText
|
||||
column_create Entries description COLUMN_SCALAR Text
|
||||
column_create Entries last_modified COLUMN_SCALAR Time
|
||||
|
||||
table_create Bigram TABLE_PAT_KEY ShortText \
|
||||
--default_tokenizer TokenBigram \
|
||||
--normalizer NormalizerAuto
|
||||
column_create Bigram entries_name COLUMN_INDEX|WITH_POSITION \
|
||||
Entries name
|
||||
column_create Bigram entries_description COLUMN_INDEX|WITH_POSITION \
|
||||
Entries description
|
||||
|
||||
table_create Times TABLE_PAT_KEY Time
|
||||
column_create Times entries_last_modified COLUMN_INDEX \
|
||||
Entries last_modified
|
||||
208
storage/mroonga/vendor/groonga/benchmark/bench-query-optimizer.c
vendored
Normal file
|
|
@ -0,0 +1,208 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2014 Kouhei Sutou <kou@clear-code.com>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/*
|
||||
Groonga: c4379140c02699e3c74b94cd9e7b88d372202aa5
|
||||
|
||||
CFLAGS: -O0 -g3
|
||||
% make --quiet -C benchmark run-bench-query-optimizer
|
||||
run-bench-query-optimizer:
|
||||
Process 100 times in each pattern
|
||||
(time)
|
||||
1 condition: with mruby: (0.0362s)
|
||||
1 condition: without mruby: (0.0216s)
|
||||
4 conditions: with mruby: (0.0864s)
|
||||
4 conditions: without mruby: (0.0271s)
|
||||
|
||||
CFLAGS: -O2 -g
|
||||
% make --quiet -C benchmark run-bench-query-optimizer
|
||||
run-bench-query-optimizer:
|
||||
Process 100 times in each pattern
|
||||
(time)
|
||||
1 condition: with mruby: (0.0243s)
|
||||
1 condition: without mruby: (0.0159s)
|
||||
4 conditions: with mruby: (0.0452s)
|
||||
4 conditions: without mruby: (0.0188s)
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
#include <groonga.h>
|
||||
|
||||
#include "lib/benchmark.h"
|
||||
|
||||
typedef struct _BenchmarkData {
|
||||
grn_ctx context;
|
||||
grn_obj *database;
|
||||
grn_bool use_mruby;
|
||||
GString *command;
|
||||
} BenchmarkData;
|
||||
|
||||
static void
|
||||
bench(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
grn_ctx *context = &(data->context);
|
||||
char *response;
|
||||
unsigned int response_length;
|
||||
int flags;
|
||||
|
||||
grn_ctx_send(context, data->command->str, data->command->len, 0);
|
||||
grn_ctx_recv(context, &response, &response_length, &flags);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
if (data->use_mruby) {
|
||||
g_setenv("GRN_MRUBY_ENABLED", "yes", TRUE);
|
||||
} else {
|
||||
g_setenv("GRN_MRUBY_ENABLED", "no", TRUE);
|
||||
}
|
||||
grn_ctx_init(&(data->context), 0);
|
||||
grn_ctx_use(&(data->context), data->database);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_teardown(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
grn_ctx_fin(&(data->context));
|
||||
}
|
||||
|
||||
static gchar *
|
||||
get_tmp_dir(void)
|
||||
{
|
||||
gchar *current_dir;
|
||||
gchar *tmp_dir;
|
||||
|
||||
current_dir = g_get_current_dir();
|
||||
tmp_dir = g_build_filename(current_dir, "tmp", NULL);
|
||||
g_free(current_dir);
|
||||
|
||||
return tmp_dir;
|
||||
}
|
||||
|
||||
static grn_obj *
|
||||
setup_database(grn_ctx *context)
|
||||
{
|
||||
gchar *tmp_dir;
|
||||
gchar *database_path;
|
||||
grn_obj *database;
|
||||
const gchar *warmup_command = "dump";
|
||||
gchar *response;
|
||||
unsigned int response_length;
|
||||
int flags;
|
||||
|
||||
tmp_dir = get_tmp_dir();
|
||||
database_path = g_build_filename(tmp_dir, "query-optimizer", "db", NULL);
|
||||
database = grn_db_open(context, database_path);
|
||||
grn_ctx_send(context, warmup_command, strlen(warmup_command), 0);
|
||||
grn_ctx_recv(context, &response, &response_length, &flags);
|
||||
|
||||
g_free(database_path);
|
||||
|
||||
return database;
|
||||
}
|
||||
|
||||
static void
|
||||
teardown_database(grn_ctx *context, grn_obj *database)
|
||||
{
|
||||
grn_obj_close(context, database);
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, gchar **argv)
|
||||
{
|
||||
grn_ctx context;
|
||||
grn_obj *database;
|
||||
BenchReporter *reporter;
|
||||
gint n = 100;
|
||||
|
||||
grn_init();
|
||||
bench_init(&argc, &argv);
|
||||
|
||||
grn_ctx_init(&context, 0);
|
||||
|
||||
database = setup_database(&context);
|
||||
|
||||
reporter = bench_reporter_new();
|
||||
|
||||
g_print("Process %d times in each pattern\n", n);
|
||||
{
|
||||
BenchmarkData data_one_condition_with_mruby;
|
||||
BenchmarkData data_one_condition_without_mruby;
|
||||
BenchmarkData data_multiple_conditions_with_mruby;
|
||||
BenchmarkData data_multiple_conditions_without_mruby;
|
||||
|
||||
#define REGISTER(label, data, use_mruby_, command_) \
|
||||
data.database = database; \
|
||||
data.use_mruby = use_mruby_; \
|
||||
data.command = g_string_new(command_); \
|
||||
bench_reporter_register(reporter, label, \
|
||||
n, \
|
||||
bench_setup, \
|
||||
bench, \
|
||||
bench_teardown, \
|
||||
&data)
|
||||
|
||||
REGISTER("1 condition: with mruby", data_one_condition_with_mruby,
|
||||
GRN_TRUE,
|
||||
"select Entries --cache no --query 'name:@Groonga'");
|
||||
REGISTER("1 condition: without mruby", data_one_condition_without_mruby,
|
||||
GRN_FALSE,
|
||||
"select Entries --cache no --query 'name:@Groonga'");
|
||||
REGISTER("4 conditions: with mruby",
|
||||
data_multiple_conditions_with_mruby,
|
||||
GRN_TRUE,
|
||||
"select Entries --cache no --filter '"
|
||||
"name @ \"Groonga\" && "
|
||||
"description @ \"search\" && "
|
||||
"last_modified >= \"2014-2-9 00:00:00\" && "
|
||||
"last_modified <= \"2014-11-29 00:00:00\""
|
||||
"'");
|
||||
REGISTER("4 conditions: without mruby",
|
||||
data_multiple_conditions_without_mruby,
|
||||
GRN_FALSE,
|
||||
"select Entries --cache no --filter '"
|
||||
"name @ \"Groonga\" && "
|
||||
"description @ \"search\" && "
|
||||
"last_modified >= \"2014-2-9 00:00:00\" && "
|
||||
"last_modified <= \"2014-11-29 00:00:00\""
|
||||
"'");
|
||||
|
||||
#undef REGISTER
|
||||
|
||||
bench_reporter_run(reporter);
|
||||
}
|
||||
g_object_unref(reporter);
|
||||
|
||||
teardown_database(&context, database);
|
||||
|
||||
grn_ctx_fin(&context);
|
||||
|
||||
grn_fin();
|
||||
|
||||
return 0;
|
||||
}
|
||||
270
storage/mroonga/vendor/groonga/benchmark/bench-table-factory.c
vendored
Normal file
|
|
@ -0,0 +1,270 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2008 Kouhei Sutou <kou@cozmixng.org>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include <groonga.h>
|
||||
|
||||
#include "lib/benchmark.h"
|
||||
|
||||
#define DEFAULT_FLAGS (GRN_OBJ_PERSISTENT | GRN_OBJ_TABLE_PAT_KEY)
|
||||
#define DEFAULT_VALUE_SIZE (1024)
|
||||
#define VALUE_TYPE_NAME "<value_type>"
|
||||
|
||||
typedef struct _BenchmarkData
|
||||
{
|
||||
gchar *base_dir;
|
||||
|
||||
grn_ctx *context;
|
||||
const char *name;
|
||||
unsigned name_size;
|
||||
char *path;
|
||||
grn_obj_flags flags;
|
||||
grn_obj *key_type;
|
||||
unsigned value_size;
|
||||
grn_encoding encoding;
|
||||
} BenchmarkData;
|
||||
|
||||
static void
|
||||
bench_normal(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
grn_obj *table;
|
||||
grn_obj *value_type = grn_ctx_get(data->context, VALUE_TYPE_NAME, strlen(VALUE_TYPE_NAME));
|
||||
if (!value_type) {
|
||||
value_type = grn_type_create(data->context, VALUE_TYPE_NAME, strlen(VALUE_TYPE_NAME),
|
||||
0, data->value_size);
|
||||
}
|
||||
table = grn_table_create(data->context,
|
||||
data->name, data->name_size,
|
||||
data->path, data->flags,
|
||||
data->key_type, value_type);
|
||||
grn_obj_close(data->context, table);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_normal_temporary(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
grn_obj *table;
|
||||
grn_obj *value_type = grn_ctx_get(data->context, VALUE_TYPE_NAME, strlen(VALUE_TYPE_NAME));
|
||||
if (!value_type) {
|
||||
value_type = grn_type_create(data->context, VALUE_TYPE_NAME, strlen(VALUE_TYPE_NAME),
|
||||
0, data->value_size);
|
||||
}
|
||||
GRN_CTX_SET_ENCODING(data->context, data->encoding);
|
||||
table = grn_table_create(data->context,
|
||||
data->name, data->name_size,
|
||||
NULL, data->flags & ~GRN_OBJ_PERSISTENT,
|
||||
data->key_type, value_type);
|
||||
grn_obj_close(data->context, table);
|
||||
}
|
||||
|
||||
typedef struct _grn_table_factory
|
||||
{
|
||||
grn_ctx *context;
|
||||
char *name;
|
||||
unsigned name_size;
|
||||
char *path;
|
||||
grn_obj_flags flags;
|
||||
grn_obj *key_type;
|
||||
unsigned value_size;
|
||||
grn_encoding encoding;
|
||||
} grn_table_factory;
|
||||
|
||||
static grn_table_factory *
|
||||
grn_table_factory_create(void)
|
||||
{
|
||||
grn_table_factory *factory;
|
||||
|
||||
factory = g_new0(grn_table_factory, 1);
|
||||
|
||||
factory->context = NULL;
|
||||
factory->name = NULL;
|
||||
factory->name_size = 0;
|
||||
factory->path = NULL;
|
||||
factory->flags = DEFAULT_FLAGS;
|
||||
factory->key_type = NULL;
|
||||
factory->value_size = DEFAULT_VALUE_SIZE;
|
||||
factory->encoding = GRN_ENC_DEFAULT;
|
||||
|
||||
return factory;
|
||||
}
|
||||
|
||||
static void
|
||||
grn_table_factory_set_context(grn_table_factory *factory, grn_ctx *context)
|
||||
{
|
||||
factory->context = context;
|
||||
}
|
||||
|
||||
static void
|
||||
grn_table_factory_set_name(grn_table_factory *factory, const char *name)
|
||||
{
|
||||
factory->name = g_strdup(name);
|
||||
factory->name_size = strlen(name);
|
||||
}
|
||||
|
||||
static void
|
||||
grn_table_factory_set_path(grn_table_factory *factory, const char *path)
|
||||
{
|
||||
factory->path = g_strdup(path);
|
||||
if (path)
|
||||
factory->flags |= GRN_OBJ_PERSISTENT;
|
||||
else
|
||||
factory->flags &= ~GRN_OBJ_PERSISTENT;
|
||||
}
|
||||
|
||||
static void
|
||||
grn_table_factory_set_key_type(grn_table_factory *factory, grn_obj *key_type)
|
||||
{
|
||||
factory->key_type = key_type;
|
||||
}
|
||||
|
||||
static grn_obj *
|
||||
grn_table_factory_make(grn_table_factory *factory)
|
||||
{
|
||||
grn_obj *value_type = grn_ctx_get(factory->context, VALUE_TYPE_NAME, strlen(VALUE_TYPE_NAME));
|
||||
if (!value_type) {
|
||||
value_type = grn_type_create(factory->context, VALUE_TYPE_NAME, strlen(VALUE_TYPE_NAME),
|
||||
0, factory->value_size);
|
||||
}
|
||||
GRN_CTX_SET_ENCODING(factory->context, factory->encoding);
|
||||
return grn_table_create(factory->context,
|
||||
factory->name, factory->name_size,
|
||||
factory->path, factory->flags,
|
||||
factory->key_type, value_type);
|
||||
}
|
||||
|
||||
static void
|
||||
grn_table_factory_close(grn_table_factory *factory)
|
||||
{
|
||||
g_free(factory->name);
|
||||
g_free(factory->path);
|
||||
g_free(factory);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_factory(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
grn_table_factory *factory;
|
||||
grn_obj *table;
|
||||
|
||||
factory = grn_table_factory_create();
|
||||
grn_table_factory_set_context(factory, data->context);
|
||||
grn_table_factory_set_name(factory, data->name);
|
||||
grn_table_factory_set_path(factory, data->path);
|
||||
grn_table_factory_set_key_type(factory, data->key_type);
|
||||
|
||||
table = grn_table_factory_make(factory);
|
||||
grn_obj_close(data->context, table);
|
||||
|
||||
grn_table_factory_close(factory);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_factory_temporary(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
grn_table_factory *factory;
|
||||
grn_obj *table;
|
||||
|
||||
factory = grn_table_factory_create();
|
||||
grn_table_factory_set_context(factory, data->context);
|
||||
grn_table_factory_set_name(factory, data->name);
|
||||
grn_table_factory_set_key_type(factory, data->key_type);
|
||||
|
||||
table = grn_table_factory_make(factory);
|
||||
grn_obj_close(data->context, table);
|
||||
|
||||
grn_table_factory_close(factory);
|
||||
}
|
||||
|
||||
static void
|
||||
bench_setup(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
const gchar *type_name;
|
||||
|
||||
bench_utils_remove_path_recursive_force(data->base_dir);
|
||||
g_mkdir_with_parents(data->base_dir, 0755);
|
||||
|
||||
grn_ctx_init(data->context, GRN_CTX_USE_QL);
|
||||
|
||||
type_name = "name";
|
||||
data->key_type = grn_type_create(data->context,
|
||||
type_name, strlen(type_name),
|
||||
GRN_OBJ_KEY_UINT, sizeof(grn_id));
|
||||
|
||||
}
|
||||
|
||||
static void
|
||||
bench_teardown(gpointer user_data)
|
||||
{
|
||||
BenchmarkData *data = user_data;
|
||||
|
||||
grn_obj_close(data->context, data->key_type);
|
||||
grn_ctx_fin(data->context);
|
||||
bench_utils_remove_path_recursive_force(data->base_dir);
|
||||
}
|
||||
|
||||
int
|
||||
main(int argc, gchar **argv)
|
||||
{
|
||||
BenchmarkData data;
|
||||
BenchReporter *reporter;
|
||||
gint n = 100;
|
||||
|
||||
grn_init();
|
||||
bench_init(&argc, &argv);
|
||||
|
||||
data.context = g_new(grn_ctx, 1);
|
||||
data.base_dir = g_build_filename(g_get_tmp_dir(), "groonga-bench", NULL);
|
||||
data.name = "table";
|
||||
data.name_size = strlen(data.name);
|
||||
data.path = g_build_filename(data.base_dir, "table", NULL);
|
||||
data.flags = DEFAULT_FLAGS;
|
||||
data.key_type = NULL;
|
||||
data.value_size = DEFAULT_VALUE_SIZE;
|
||||
data.encoding = GRN_ENC_DEFAULT;
|
||||
|
||||
reporter = bench_reporter_new();
|
||||
bench_reporter_register(reporter, "normal (persistent)", n,
|
||||
bench_setup, bench_normal, bench_teardown, &data);
|
||||
bench_reporter_register(reporter, "factory (persistent)", n,
|
||||
bench_setup, bench_factory, bench_teardown, &data);
|
||||
bench_reporter_register(reporter, "normal (temporary)", n,
|
||||
bench_setup, bench_normal_temporary, bench_teardown,
|
||||
&data);
|
||||
bench_reporter_register(reporter, "factory (temporary)", n,
|
||||
bench_setup, bench_factory_temporary, bench_teardown,
|
||||
&data);
|
||||
bench_reporter_run(reporter);
|
||||
g_object_unref(reporter);
|
||||
|
||||
bench_utils_remove_path_recursive_force(data.base_dir);
|
||||
|
||||
g_free(data.path);
|
||||
g_free(data.base_dir);
|
||||
g_free(data.context);
|
||||
|
||||
bench_quit();
|
||||
grn_fin();
|
||||
|
||||
return 0;
|
||||
}
|
||||
2
storage/mroonga/vendor/groonga/benchmark/fixtures/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
SUBDIRS = \
|
||||
geo-select
|
||||
BIN
storage/mroonga/vendor/groonga/benchmark/fixtures/geo-select/13_2010.CSV.xz
vendored
Normal file
4
storage/mroonga/vendor/groonga/benchmark/fixtures/geo-select/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
EXTRA_DIST = \
|
||||
README.txt \
|
||||
13_2010.CSV.xz \
|
||||
format_2010.html
|
||||
6
storage/mroonga/vendor/groonga/benchmark/fixtures/geo-select/README.txt
vendored
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
位置情報検索ベンチマーク用テストデータについて
|
||||
--------------------------------------------
|
||||
|
||||
13_2010.CSV.xzは国土交通相の `位置参照情報ダウンロードサービス <http://nlftp.mlit.go.jp/isj/>`_ からダウンロードした2010年版の東京都の「大字・町丁目位置参照情報 国土交通省」です。xz圧縮しているだけでデータの編集・加工はしていません。CSVのフォーマットについてはformat_2010.htmlを参照してください。こちらもダウンロードサービスに含まれているものを編集・加工していません。
|
||||
|
||||
`位置参照情報ダウンロードサービス利用約款 <http://nlftp.mlit.go.jp/isj/agreement.html>`_ に従い、上記のように出典を明記して利用しています。
|
||||
111
storage/mroonga/vendor/groonga/benchmark/fixtures/geo-select/format_2010.html
vendored
Normal file
|
|
@ -0,0 +1,111 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>街区レベル位置参照情報 (2010)</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h3 align="center">街区レベル位置参照情報 (2010年版) データ形式</h3>
|
||||
<table width="90%" align="center">
|
||||
<tr>
|
||||
<td>
|
||||
ファイル形式はCSV(Camma Separated Values)です。<br/>
|
||||
文字コードは、Shift-JISです。<br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<table width="100%" align="center" border="1">
|
||||
<tr>
|
||||
<th>項目</th>
|
||||
<th>備考</th>
|
||||
<th>例</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>都道府県名</td>
|
||||
<td><br/></td>
|
||||
<td>"東京都"</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>市区町村名</td>
|
||||
<td>郡部は郡名、政令指定都市の区名も含む。</td>
|
||||
<td>"千代田区"</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>大字・町丁目</td>
|
||||
<td>町丁目の数字は漢数字</td>
|
||||
<td>"霞が関二丁目"</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>街区符号・地番</td>
|
||||
<td>原則として半角整数(一部漢字等あり)</td>
|
||||
<td>"1"</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>座標系番号</td>
|
||||
<td>平面直角座標系の座標系番号(1~19:半角整数)</td>
|
||||
<td>9</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>X座標</td>
|
||||
<td>
|
||||
平面直角座標系の座標系原点からのずれ<br/>
|
||||
(単位:メートル、北方向がプラス値、小数点以下第1位まで)
|
||||
</td>
|
||||
<td>-35925.9</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Y座標</td>
|
||||
<td>
|
||||
平面直角座標系の座標系原点からのずれ<br/>
|
||||
(単位:メートル、東方向がプラス値、小数点以下第1位まで)
|
||||
</td>
|
||||
<td>-7446.2</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>緯度</td>
|
||||
<td>十進経緯度(単位:度、小数点以下第6位まで)</td>
|
||||
<td>35.676155</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>経度</td>
|
||||
<td>十進経緯度(単位:度、小数点以下第6位まで)</td>
|
||||
<td>139.751075</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>住居表示フラグ</td>
|
||||
<td>1:住居表示実施、0:住居表示未実施</td>
|
||||
<td>1</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>代表フラグ</td>
|
||||
<td>
|
||||
1つの街区符号が複数の代表点に対応付けられる場合などに、そのうちの1つに便宜的に代表フラグを立てています。<br/>
|
||||
1:代表する、0:代表しない
|
||||
<td>1</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>更新前履歴フラグ</td>
|
||||
<td>2007年度および2008年度データに含まれるフラグを立てています。<br/>
|
||||
1:新規作成、2:名称変更、3:削除、0:変更なし</td>
|
||||
<td>0</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>更新後履歴フラグ</td>
|
||||
<td>2009年度以降のデータに含まれるフラグを立てています。<br/>
|
||||
1:新規作成、2:名称変更、3:削除、0:変更なし</td>
|
||||
<td>0</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">
|
||||
平成23年04月18日作成
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
140
storage/mroonga/vendor/groonga/benchmark/geo-distance-summary.rb
vendored
Executable file
|
|
@ -0,0 +1,140 @@
|
|||
#!/usr/bin/env ruby
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
require 'fileutils'
|
||||
require 'optparse'
|
||||
|
||||
class BenchmarkSummary
|
||||
attr_accessor :options
|
||||
|
||||
def initialize(options)
|
||||
@options = options
|
||||
@options[:count] ||= 10
|
||||
end
|
||||
|
||||
def calc_total(data)
|
||||
total = {}
|
||||
@options[:count].times do |i|
|
||||
data[i + 1].each do |key, value|
|
||||
if total[key]
|
||||
total[key] = total[key] + value
|
||||
else
|
||||
total[key] = value
|
||||
end
|
||||
end
|
||||
end
|
||||
total
|
||||
end
|
||||
|
||||
def print_average(data)
|
||||
total = calc_total(data)
|
||||
text = "|項目|"
|
||||
@options[:count].times do |i|
|
||||
text << "#{i + 1}|"
|
||||
text << "平均|\n" if i == @options[:count] - 1
|
||||
end
|
||||
total.each do |key, value|
|
||||
line = [key]
|
||||
@options[:count].times do |i|
|
||||
data[i + 1].each do |data_key, data_value|
|
||||
if key == data_key
|
||||
line << data_value
|
||||
end
|
||||
end
|
||||
end
|
||||
line << [value / @options[:count].to_f]
|
||||
text << sprintf("|%s|\n", line.join("|"))
|
||||
end
|
||||
puts text
|
||||
end
|
||||
|
||||
def print_performance(before, after)
|
||||
before_total = calc_total(before)
|
||||
after_total = calc_total(after)
|
||||
ratio = {}
|
||||
before_total.each do |key, value|
|
||||
ratio[key] = after_total[key] / value
|
||||
end
|
||||
text = "|項目|変更前|変更後|比率|備考|\n"
|
||||
ratio.each do |key, value|
|
||||
text << sprintf("|%s|%f|%f|%f||\n",
|
||||
key,
|
||||
before_total[key] / @options[:count].to_f,
|
||||
after_total[key] / @options[:count].to_f,
|
||||
ratio[key])
|
||||
end
|
||||
puts text
|
||||
end
|
||||
|
||||
def parse_log(logs)
|
||||
parse_result = {}
|
||||
logs.each do |index, log|
|
||||
File.open(log, "r") do |file|
|
||||
data = file.read
|
||||
entry = {}
|
||||
data.split("\n").each do |line|
|
||||
if line =~ /\s*(.+?):\s+\((.+)\)/
|
||||
entry[$1] = $2.to_f
|
||||
end
|
||||
end
|
||||
parse_result[index] = entry
|
||||
end
|
||||
end
|
||||
parse_result
|
||||
end
|
||||
end
|
||||
|
||||
=begin
|
||||
|
||||
Usage: geo-distance-summary.rb \
|
||||
-b run-bench-geo-distance-orig-N1000 \
|
||||
-a run-bench-geo-distance-work-N1000
|
||||
|
||||
NOTE: expected that there are run-bench-geo-distance-orig-N1000-1.log \
|
||||
... \
|
||||
run-bench-geo-distance-orig-N1000-[N].log.
|
||||
|
||||
=end
|
||||
|
||||
if __FILE__ == $0
|
||||
|
||||
options = {}
|
||||
parser = OptionParser.new
|
||||
parser.on("-b", "--before PREFIX",
|
||||
"log file name must be PREFIX-[N].log") do |prefix|
|
||||
options[:before] = prefix
|
||||
end
|
||||
parser.on("-a", "--after PREFIX",
|
||||
"log file name must be PREFIX-[N].log") do |prefix|
|
||||
options[:after] = prefix
|
||||
end
|
||||
parser.on("-n", "data count") do |count|
|
||||
options[:count] = count
|
||||
end
|
||||
|
||||
parser.parse!(ARGV)
|
||||
|
||||
if not options.has_key?(:before) or not options.has_key?(:after)
|
||||
puts(parser.to_s)
|
||||
exit
|
||||
end
|
||||
|
||||
bench_before_log = {}
|
||||
bench_after_log = {}
|
||||
Dir.glob("#{options[:before]}*.log") do |log|
|
||||
log =~ /(.+)-(\d+)\.log$/
|
||||
bench_before_log[$2.to_i] = log
|
||||
end
|
||||
Dir.glob("#{options[:after]}*.log") do |log|
|
||||
log =~ /(.+)-(\d+)\.log$/
|
||||
bench_after_log[$2.to_i] = log
|
||||
end
|
||||
|
||||
bench = BenchmarkSummary.new(options)
|
||||
bench_before = bench.parse_log(bench_before_log)
|
||||
bench_after = bench.parse_log(bench_after_log)
|
||||
|
||||
bench.print_average(bench_before)
|
||||
bench.print_average(bench_after)
|
||||
bench.print_performance(bench_before, bench_after)
|
||||
end
|
||||
53
storage/mroonga/vendor/groonga/benchmark/geo-select-generate-grn.rb
vendored
Executable file
|
|
@ -0,0 +1,53 @@
|
|||
#!/usr/bin/env ruby
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
if ARGV.size != 2
|
||||
puts "Usage: #{$0} SOURCE_CSV OUTPUT_GRN"
|
||||
puts " e.g.: #{$0} fixtures/geo-select/13_2010.CSV fixtures/geo-select/load.grn"
|
||||
exit(false)
|
||||
end
|
||||
|
||||
csv, grn = ARGV
|
||||
|
||||
require "fileutils"
|
||||
require "csv"
|
||||
|
||||
FileUtils.mkdir_p(File.dirname(grn))
|
||||
File.open(grn, "w") do |output|
|
||||
output.print(<<-EOH.strip)
|
||||
table_create Addresses TABLE_HASH_KEY ShortText
|
||||
column_create Addresses location COLUMN_SCALAR WGS84GeoPoint
|
||||
|
||||
table_create Locations TABLE_PAT_KEY WGS84GeoPoint
|
||||
column_create Locations address COLUMN_INDEX Addresses location
|
||||
|
||||
load --table Addresses
|
||||
[
|
||||
["_key", "location"]
|
||||
EOH
|
||||
|
||||
headers = nil
|
||||
csv_foreach_args = [csv]
|
||||
csv_foreach_args << {:encoding => "UTF-8"} if defined?(Encoding)
|
||||
CSV.foreach(*csv_foreach_args) do |row|
|
||||
if headers.nil?
|
||||
headers = row
|
||||
else
|
||||
record = {}
|
||||
headers.each_with_index do |header, i|
|
||||
record[header] = row[i]
|
||||
end
|
||||
central_value_p = record["代表フラグ"] == "1"
|
||||
next unless central_value_p
|
||||
name =
|
||||
record["都道府県名"] + record["市区町村名"] +
|
||||
record["大字・町丁目"] + record["街区符号・地番"]
|
||||
location = "%sx%s" % [record["緯度"], record["経度"]]
|
||||
output.print(",\n[\"#{name}\", \"#{location}\"]")
|
||||
end
|
||||
end
|
||||
output.print(<<-EOF)
|
||||
|
||||
]
|
||||
EOF
|
||||
end
|
||||
21
storage/mroonga/vendor/groonga/benchmark/lib/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
if WITH_BENCHMARK
|
||||
noinst_LTLIBRARIES = \
|
||||
libbenchmark.la
|
||||
endif
|
||||
|
||||
AM_CPPFLAGS = \
|
||||
-I$(srcdir)
|
||||
|
||||
AM_CFLAGS = \
|
||||
$(GLIB_CFLAGS)
|
||||
|
||||
LIBS = \
|
||||
$(GLIB_LIBS)
|
||||
|
||||
libbenchmark_la_SOURCES = \
|
||||
benchmark.c \
|
||||
benchmark.h \
|
||||
bench-reporter.c \
|
||||
bench-reporter.h \
|
||||
bench-utils.c \
|
||||
bench-utils.h
|
||||
315
storage/mroonga/vendor/groonga/benchmark/lib/bench-reporter.c
vendored
Normal file
|
|
@ -0,0 +1,315 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2008 Kouhei Sutou <kou@cozmixng.org>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include "bench-reporter.h"
|
||||
|
||||
typedef struct _BenchItem BenchItem;
|
||||
struct _BenchItem
|
||||
{
|
||||
gchar *label;
|
||||
gint n;
|
||||
BenchSetupFunc bench_setup;
|
||||
BenchFunc bench;
|
||||
BenchTeardownFunc bench_teardown;
|
||||
gpointer data;
|
||||
};
|
||||
|
||||
static BenchItem *
|
||||
bench_item_new(const gchar *label, gint n,
|
||||
BenchSetupFunc bench_setup,
|
||||
BenchFunc bench,
|
||||
BenchTeardownFunc bench_teardown,
|
||||
gpointer data)
|
||||
{
|
||||
BenchItem *item;
|
||||
|
||||
item = g_slice_new(BenchItem);
|
||||
|
||||
item->label = g_strdup(label);
|
||||
item->n = n;
|
||||
item->bench_setup = bench_setup;
|
||||
item->bench = bench;
|
||||
item->bench_teardown = bench_teardown;
|
||||
item->data = data;
|
||||
|
||||
return item;
|
||||
}
|
||||
|
||||
static void
|
||||
bench_item_free(BenchItem *item)
|
||||
{
|
||||
if (item->label)
|
||||
g_free(item->label);
|
||||
|
||||
g_slice_free(BenchItem, item);
|
||||
}
|
||||
|
||||
#define BENCH_REPORTER_GET_PRIVATE(obj) \
|
||||
(G_TYPE_INSTANCE_GET_PRIVATE((obj), \
|
||||
BENCH_TYPE_REPORTER, \
|
||||
BenchReporterPrivate))
|
||||
|
||||
typedef struct _BenchReporterPrivate BenchReporterPrivate;
|
||||
struct _BenchReporterPrivate
|
||||
{
|
||||
GList *items;
|
||||
};
|
||||
|
||||
G_DEFINE_TYPE(BenchReporter, bench_reporter, G_TYPE_OBJECT)
|
||||
|
||||
static void dispose (GObject *object);
|
||||
|
||||
static void
|
||||
bench_reporter_class_init(BenchReporterClass *klass)
|
||||
{
|
||||
GObjectClass *gobject_class;
|
||||
|
||||
gobject_class = G_OBJECT_CLASS(klass);
|
||||
|
||||
gobject_class->dispose = dispose;
|
||||
|
||||
g_type_class_add_private(gobject_class, sizeof(BenchReporterPrivate));
|
||||
}
|
||||
|
||||
static void
|
||||
bench_reporter_init(BenchReporter *reporter)
|
||||
{
|
||||
BenchReporterPrivate *priv;
|
||||
|
||||
priv = BENCH_REPORTER_GET_PRIVATE(reporter);
|
||||
|
||||
priv->items = NULL;
|
||||
}
|
||||
|
||||
static void
|
||||
dispose(GObject *object)
|
||||
{
|
||||
BenchReporterPrivate *priv;
|
||||
|
||||
priv = BENCH_REPORTER_GET_PRIVATE(object);
|
||||
|
||||
if (priv->items) {
|
||||
g_list_foreach(priv->items, (GFunc)bench_item_free, NULL);
|
||||
g_list_free(priv->items);
|
||||
priv->items = NULL;
|
||||
}
|
||||
|
||||
G_OBJECT_CLASS(bench_reporter_parent_class)->dispose(object);
|
||||
}
|
||||
|
||||
BenchReporter *
|
||||
bench_reporter_new(void)
|
||||
{
|
||||
return g_object_new(BENCH_TYPE_REPORTER, NULL);
|
||||
}
|
||||
|
||||
void
|
||||
bench_reporter_register(BenchReporter *reporter,
|
||||
const gchar *label, gint n,
|
||||
BenchSetupFunc bench_setup,
|
||||
BenchFunc bench,
|
||||
BenchTeardownFunc bench_teardown,
|
||||
gpointer data)
|
||||
{
|
||||
BenchReporterPrivate *priv;
|
||||
|
||||
priv = BENCH_REPORTER_GET_PRIVATE(reporter);
|
||||
|
||||
priv->items = g_list_append(priv->items, bench_item_new(label, n,
|
||||
bench_setup,
|
||||
bench,
|
||||
bench_teardown,
|
||||
data));
|
||||
}
|
||||
|
||||
#define INDENT " "
|
||||
|
||||
static void
|
||||
print_header(BenchReporterPrivate *priv, gint max_label_length)
|
||||
{
|
||||
gint n_spaces;
|
||||
|
||||
g_print(INDENT);
|
||||
for (n_spaces = max_label_length + strlen(": ");
|
||||
n_spaces > 0;
|
||||
n_spaces--) {
|
||||
g_print(" ");
|
||||
}
|
||||
g_print("(total) ");
|
||||
g_print("(average) ");
|
||||
g_print("(median)\n");
|
||||
}
|
||||
|
||||
static void
|
||||
print_label(BenchReporterPrivate *priv, BenchItem *item, gint max_label_length)
|
||||
{
|
||||
gint n_left_spaces;
|
||||
|
||||
g_print(INDENT);
|
||||
if (item->label) {
|
||||
n_left_spaces = max_label_length - strlen(item->label);
|
||||
} else {
|
||||
n_left_spaces = max_label_length;
|
||||
}
|
||||
for (; n_left_spaces > 0; n_left_spaces--) {
|
||||
g_print(" ");
|
||||
}
|
||||
if (item->label)
|
||||
g_print("%s", item->label);
|
||||
g_print(": ");
|
||||
}
|
||||
|
||||
static void
|
||||
report_elapsed_time(gdouble elapsed_time)
|
||||
{
|
||||
gdouble one_second = 1.0;
|
||||
gdouble one_millisecond = one_second / 1000.0;
|
||||
gdouble one_microsecond = one_millisecond / 1000.0;
|
||||
|
||||
if (elapsed_time < one_microsecond) {
|
||||
g_print("(%.8fms)", elapsed_time * 1000.0);
|
||||
} else if (elapsed_time < one_millisecond) {
|
||||
g_print("(%.4fms)", elapsed_time * 1000.0);
|
||||
} else {
|
||||
g_print("(%.4fs) ", elapsed_time);
|
||||
}
|
||||
}
|
||||
|
||||
static gdouble
|
||||
compute_total_elapsed_time(GArray *elapsed_times)
|
||||
{
|
||||
guint i;
|
||||
gdouble total = 0.0;
|
||||
|
||||
for (i = 0; i< elapsed_times->len; i++) {
|
||||
gdouble elapsed_time = g_array_index(elapsed_times, gdouble, i);
|
||||
total += elapsed_time;
|
||||
}
|
||||
|
||||
return total;
|
||||
}
|
||||
|
||||
static void
|
||||
report_elapsed_time_total(GArray *elapsed_times)
|
||||
{
|
||||
report_elapsed_time(compute_total_elapsed_time(elapsed_times));
|
||||
}
|
||||
|
||||
static void
|
||||
report_elapsed_time_average(GArray *elapsed_times)
|
||||
{
|
||||
gdouble total;
|
||||
gdouble average;
|
||||
|
||||
total = compute_total_elapsed_time(elapsed_times);
|
||||
average = total / elapsed_times->len;
|
||||
report_elapsed_time(average);
|
||||
}
|
||||
|
||||
static gint
|
||||
compare_elapsed_time(gconstpointer a, gconstpointer b)
|
||||
{
|
||||
const gdouble *elapsed_time1 = a;
|
||||
const gdouble *elapsed_time2 = b;
|
||||
|
||||
if (*elapsed_time1 > *elapsed_time2) {
|
||||
return 1;
|
||||
} else if (*elapsed_time1 < *elapsed_time2) {
|
||||
return -1;
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
report_elapsed_time_median(GArray *elapsed_times)
|
||||
{
|
||||
gdouble median;
|
||||
|
||||
g_array_sort(elapsed_times, compare_elapsed_time);
|
||||
median = g_array_index(elapsed_times, gdouble, elapsed_times->len / 2);
|
||||
report_elapsed_time(median);
|
||||
}
|
||||
|
||||
static void
|
||||
report_elapsed_time_statistics(GArray *elapsed_times)
|
||||
{
|
||||
report_elapsed_time_total(elapsed_times);
|
||||
g_print(" ");
|
||||
report_elapsed_time_average(elapsed_times);
|
||||
g_print(" ");
|
||||
report_elapsed_time_median(elapsed_times);
|
||||
g_print("\n");
|
||||
}
|
||||
|
||||
static void
|
||||
run_item(BenchReporterPrivate *priv, BenchItem *item, gint max_label_length)
|
||||
{
|
||||
GTimer *timer;
|
||||
GArray *elapsed_times;
|
||||
gint i;
|
||||
|
||||
print_label(priv, item, max_label_length);
|
||||
|
||||
elapsed_times = g_array_new(FALSE, FALSE, sizeof(gdouble));
|
||||
|
||||
timer = g_timer_new();
|
||||
for (i = 0; i < item->n; i++) {
|
||||
gdouble elapsed_time;
|
||||
if (item->bench_setup)
|
||||
item->bench_setup(item->data);
|
||||
g_timer_start(timer);
|
||||
item->bench(item->data);
|
||||
g_timer_stop(timer);
|
||||
elapsed_time = g_timer_elapsed(timer, NULL);
|
||||
g_array_append_val(elapsed_times, elapsed_time);
|
||||
if (item->bench_teardown)
|
||||
item->bench_teardown(item->data);
|
||||
}
|
||||
g_timer_destroy(timer);
|
||||
|
||||
report_elapsed_time_statistics(elapsed_times);
|
||||
|
||||
g_array_free(elapsed_times, TRUE);
|
||||
|
||||
}
|
||||
|
||||
void
|
||||
bench_reporter_run(BenchReporter *reporter)
|
||||
{
|
||||
BenchReporterPrivate *priv;
|
||||
GList *node;
|
||||
gint max_label_length = 0;
|
||||
|
||||
priv = BENCH_REPORTER_GET_PRIVATE(reporter);
|
||||
for (node = priv->items; node; node = g_list_next(node)) {
|
||||
BenchItem *item = node->data;
|
||||
|
||||
if (item->label)
|
||||
max_label_length = MAX(max_label_length, strlen(item->label));
|
||||
}
|
||||
|
||||
print_header(priv, max_label_length);
|
||||
for (node = priv->items; node; node = g_list_next(node)) {
|
||||
BenchItem *item = node->data;
|
||||
|
||||
run_item(priv, item, max_label_length);
|
||||
}
|
||||
}
|
||||
64
storage/mroonga/vendor/groonga/benchmark/lib/bench-reporter.h
vendored
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2008 Kouhei Sutou <kou@cozmixng.org>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#ifndef __BENCH_REPORTER_H__
|
||||
#define __BENCH_REPORTER_H__
|
||||
|
||||
#include <glib-object.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define BENCH_TYPE_REPORTER (bench_reporter_get_type())
|
||||
#define BENCH_REPORTER(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), BENCH_TYPE_REPORTER, BenchReporter))
|
||||
#define BENCH_REPORTER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), BENCH_TYPE_REPORTER, BenchReporterClass))
|
||||
#define BENCH_IS_REPORTER(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), BENCH_TYPE_REPORTER))
|
||||
#define BENCH_IS_REPORTER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), BENCH_TYPE_REPORTER))
|
||||
#define BENCH_REPORTER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), BENCH_TYPE_REPORTER, BenchReporterClass))
|
||||
|
||||
typedef struct _BenchReporter BenchReporter;
|
||||
typedef struct _BenchReporterClass BenchReporterClass;
|
||||
|
||||
typedef void (*BenchSetupFunc) (gpointer user_data);
|
||||
typedef void (*BenchFunc) (gpointer user_data);
|
||||
typedef void (*BenchTeardownFunc) (gpointer user_data);
|
||||
|
||||
struct _BenchReporter
|
||||
{
|
||||
GObject object;
|
||||
};
|
||||
|
||||
struct _BenchReporterClass
|
||||
{
|
||||
GObjectClass parent_class;
|
||||
};
|
||||
|
||||
GType bench_reporter_get_type (void) G_GNUC_CONST;
|
||||
|
||||
BenchReporter *bench_reporter_new (void);
|
||||
void bench_reporter_register (BenchReporter *reporter,
|
||||
const gchar *label,
|
||||
gint n,
|
||||
BenchSetupFunc bench_setup,
|
||||
BenchFunc bench,
|
||||
BenchTeardownFunc bench_teardown,
|
||||
gpointer data);
|
||||
void bench_reporter_run (BenchReporter *reporter);
|
||||
|
||||
#endif /* __BENCH_REPORTER_H__ */
|
||||
|
||||
|
||||
83
storage/mroonga/vendor/groonga/benchmark/lib/bench-utils.c
vendored
Normal file
|
|
@ -0,0 +1,83 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2008 Kouhei Sutou <kou@cozmixng.org>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <errno.h>
|
||||
#include <glib/gstdio.h>
|
||||
|
||||
#include "bench-utils.h"
|
||||
|
||||
gboolean
|
||||
bench_utils_remove_path(const gchar *path, GError **error)
|
||||
{
|
||||
if (!g_file_test(path, G_FILE_TEST_EXISTS)) {
|
||||
g_set_error(error, G_FILE_ERROR, G_FILE_ERROR_NOENT,
|
||||
"path doesn't exist: %s", path);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (g_file_test(path, G_FILE_TEST_IS_DIR)) {
|
||||
if (g_rmdir(path) == -1) {
|
||||
g_set_error(error, G_FILE_ERROR, g_file_error_from_errno(errno),
|
||||
"can't remove directory: %s", path);
|
||||
return FALSE;
|
||||
}
|
||||
} else {
|
||||
if (g_unlink(path) == -1) {
|
||||
g_set_error(error, G_FILE_ERROR, g_file_error_from_errno(errno),
|
||||
"can't remove path: %s", path);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
gboolean
|
||||
bench_utils_remove_path_recursive(const gchar *path, GError **error)
|
||||
{
|
||||
if (g_file_test(path, G_FILE_TEST_IS_DIR)) {
|
||||
GDir *dir;
|
||||
const gchar *name;
|
||||
|
||||
dir = g_dir_open(path, 0, error);
|
||||
if (!dir)
|
||||
return FALSE;
|
||||
|
||||
while ((name = g_dir_read_name(dir))) {
|
||||
const gchar *full_path;
|
||||
|
||||
full_path = g_build_filename(path, name, NULL);
|
||||
if (!bench_utils_remove_path_recursive(full_path, error))
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
g_dir_close(dir);
|
||||
|
||||
return bench_utils_remove_path(path, error);
|
||||
} else {
|
||||
return bench_utils_remove_path(path, error);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void
|
||||
bench_utils_remove_path_recursive_force(const gchar *path)
|
||||
{
|
||||
bench_utils_remove_path_recursive(path, NULL);
|
||||
}
|
||||
34
storage/mroonga/vendor/groonga/benchmark/lib/bench-utils.h
vendored
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2008 Kouhei Sutou <kou@cozmixng.org>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#ifndef __BENCH_UTILS_H__
|
||||
#define __BENCH_UTILS_H__
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
gboolean bench_utils_remove_path (const gchar *path,
|
||||
GError **error);
|
||||
gboolean bench_utils_remove_path_recursive (const gchar *path,
|
||||
GError **error);
|
||||
void bench_utils_remove_path_recursive_force (const gchar *path);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __BENCH_UTILS_H__ */
|
||||
35
storage/mroonga/vendor/groonga/benchmark/lib/benchmark.c
vendored
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2008-2013 Kouhei Sutou <kou@clear-code.com>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include "benchmark.h"
|
||||
|
||||
void
|
||||
bench_init(gint *argc, gchar ***argv)
|
||||
{
|
||||
#if !GLIB_CHECK_VERSION(2, 36, 0)
|
||||
if (!g_thread_supported())
|
||||
g_thread_init(NULL);
|
||||
|
||||
g_type_init();
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
bench_quit(void)
|
||||
{
|
||||
}
|
||||
32
storage/mroonga/vendor/groonga/benchmark/lib/benchmark.h
vendored
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
/* -*- c-basic-offset: 2; coding: utf-8 -*- */
|
||||
/*
|
||||
Copyright (C) 2008 Kouhei Sutou <kou@cozmixng.org>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License version 2.1 as published by the Free Software Foundation.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#ifndef __BENCHMARK_H__
|
||||
#define __BENCHMARK_H__
|
||||
|
||||
#include "bench-reporter.h"
|
||||
#include "bench-utils.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
void bench_init(gint *argc, gchar ***argv);
|
||||
void bench_quit(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif
|
||||
66
storage/mroonga/vendor/groonga/bindings/php/config.m4
vendored
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
|
||||
PHP_ARG_WITH(groonga, whether groonga is available,[ --with-groonga[=DIR] With groonga support])
|
||||
|
||||
|
||||
if test "$PHP_GROONGA" != "no"; then
|
||||
|
||||
|
||||
if test -r "$PHP_GROONGA/include/groonga.h"; then
|
||||
PHP_GROONGA_DIR="$PHP_GROONGA"
|
||||
PHP_ADD_INCLUDE($PHP_GROONGA_DIR/include)
|
||||
elif test -r "$PHP_GROONGA/include/groonga/groonga.h"; then
|
||||
PHP_GROONGA_DIR="$PHP_GROONGA"
|
||||
PHP_ADD_INCLUDE($PHP_GROONGA_DIR/include/groonga)
|
||||
else
|
||||
AC_MSG_CHECKING(for groonga in default path)
|
||||
for i in /usr /usr/local; do
|
||||
if test -r "$i/include/groonga/groonga.h"; then
|
||||
PHP_GROONGA_DIR=$i
|
||||
AC_MSG_RESULT(found in $i)
|
||||
break
|
||||
fi
|
||||
done
|
||||
if test "x" = "x$PHP_GROONGA_DIR"; then
|
||||
AC_MSG_ERROR(not found)
|
||||
fi
|
||||
PHP_ADD_INCLUDE($PHP_GROONGA_DIR/include)
|
||||
fi
|
||||
|
||||
export OLD_CPPFLAGS="$CPPFLAGS"
|
||||
export CPPFLAGS="$CPPFLAGS $INCLUDES -DHAVE_GROONGA"
|
||||
AC_CHECK_HEADER([groonga.h], [], AC_MSG_ERROR('groonga.h' header not found))
|
||||
PHP_SUBST(GROONGA_SHARED_LIBADD)
|
||||
|
||||
|
||||
PHP_CHECK_LIBRARY(groonga, grn_init,
|
||||
[
|
||||
PHP_ADD_LIBRARY_WITH_PATH(groonga, $PHP_GROONGA_DIR/lib, GROONGA_SHARED_LIBADD)
|
||||
],[
|
||||
AC_MSG_ERROR([wrong groonga lib version or lib not found])
|
||||
],[
|
||||
-L$PHP_GROONGA_DIR/lib
|
||||
])
|
||||
export CPPFLAGS="$OLD_CPPFLAGS"
|
||||
|
||||
export OLD_CPPFLAGS="$CPPFLAGS"
|
||||
export CPPFLAGS="$CPPFLAGS $INCLUDES -DHAVE_GROONGA"
|
||||
|
||||
AC_MSG_CHECKING(PHP version)
|
||||
AC_TRY_COMPILE([#include <php_version.h>], [
|
||||
#if PHP_VERSION_ID < 40000
|
||||
#error this extension requires at least PHP version 4.0.0
|
||||
#endif
|
||||
],
|
||||
[AC_MSG_RESULT(ok)],
|
||||
[AC_MSG_ERROR([need at least PHP 4.0.0])])
|
||||
|
||||
export CPPFLAGS="$OLD_CPPFLAGS"
|
||||
|
||||
|
||||
PHP_SUBST(GROONGA_SHARED_LIBADD)
|
||||
AC_DEFINE(HAVE_GROONGA, 1, [ ])
|
||||
|
||||
PHP_NEW_EXTENSION(groonga, groonga.c , $ext_shared)
|
||||
|
||||
fi
|
||||
|
||||
6
storage/mroonga/vendor/groonga/bindings/php/config.w32
vendored
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
ARG_WITH('groonga', 'Groonga', 'no');
|
||||
|
||||
if (PHP_GROONGA == "yes") {
|
||||
EXTENSION("groonga", "groonga.c");
|
||||
AC_DEFINE("HAVE_GROONGA", 1, "groonga support");
|
||||
}
|
||||
218
storage/mroonga/vendor/groonga/bindings/php/groonga.c
vendored
Normal file
|
|
@ -0,0 +1,218 @@
|
|||
|
||||
#include "php_groonga.h"
|
||||
|
||||
#if HAVE_GROONGA
|
||||
|
||||
int le_grn_ctx;
|
||||
void grn_ctx_dtor(zend_rsrc_list_entry *rsrc TSRMLS_DC)
|
||||
{
|
||||
grn_ctx *ctx = (grn_ctx *)(rsrc->ptr);
|
||||
grn_ctx_close(ctx);
|
||||
}
|
||||
|
||||
zend_function_entry groonga_functions[] = {
|
||||
PHP_FE(grn_ctx_init , grn_ctx_init_arg_info)
|
||||
PHP_FE(grn_ctx_close , grn_ctx_close_arg_info)
|
||||
PHP_FE(grn_ctx_connect , grn_ctx_connect_arg_info)
|
||||
PHP_FE(grn_ctx_send , grn_ctx_send_arg_info)
|
||||
PHP_FE(grn_ctx_recv , grn_ctx_recv_arg_info)
|
||||
{ NULL, NULL, NULL }
|
||||
};
|
||||
|
||||
|
||||
zend_module_entry groonga_module_entry = {
|
||||
STANDARD_MODULE_HEADER,
|
||||
"groonga",
|
||||
groonga_functions,
|
||||
PHP_MINIT(groonga),
|
||||
PHP_MSHUTDOWN(groonga),
|
||||
PHP_RINIT(groonga),
|
||||
PHP_RSHUTDOWN(groonga),
|
||||
PHP_MINFO(groonga),
|
||||
"0.1",
|
||||
STANDARD_MODULE_PROPERTIES
|
||||
};
|
||||
|
||||
#ifdef COMPILE_DL_GROONGA
|
||||
ZEND_GET_MODULE(groonga)
|
||||
#endif
|
||||
|
||||
|
||||
PHP_MINIT_FUNCTION(groonga)
|
||||
{
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_USE_QL", GRN_CTX_USE_QL, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_BATCH_MODE", GRN_CTX_BATCH_MODE, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_ENC_DEFAULT", GRN_ENC_DEFAULT, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_ENC_NONE", GRN_ENC_NONE, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_ENC_EUC_JP", GRN_ENC_EUC_JP, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_ENC_UTF8", GRN_ENC_UTF8, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_ENC_SJIS", GRN_ENC_SJIS, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_ENC_LATIN1", GRN_ENC_LATIN1, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_ENC_KOI8R", GRN_ENC_KOI8R, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_MORE", GRN_CTX_MORE, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_TAIL", GRN_CTX_TAIL, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_HEAD", GRN_CTX_HEAD, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_QUIET", GRN_CTX_QUIET, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_QUIT", GRN_CTX_QUIT, CONST_PERSISTENT | CONST_CS);
|
||||
REGISTER_LONG_CONSTANT("GRN_CTX_FIN", GRN_CTX_FIN, CONST_PERSISTENT | CONST_CS);
|
||||
le_grn_ctx = zend_register_list_destructors_ex(
|
||||
grn_ctx_dtor, NULL, "grn_ctx", module_number);
|
||||
|
||||
grn_init();
|
||||
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
PHP_MSHUTDOWN_FUNCTION(groonga)
|
||||
{
|
||||
grn_fin();
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
PHP_RINIT_FUNCTION(groonga)
|
||||
{
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
PHP_RSHUTDOWN_FUNCTION(groonga)
|
||||
{
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
PHP_MINFO_FUNCTION(groonga)
|
||||
{
|
||||
php_info_print_box_start(0);
|
||||
php_printf("<p>Groonga</p>\n");
|
||||
php_printf("<p>Version 0.2 (ctx)</p>\n");
|
||||
php_printf("<p><b>Authors:</b></p>\n");
|
||||
php_printf("<p>yu <yu@irx.jp> (lead)</p>\n");
|
||||
php_info_print_box_end();
|
||||
}
|
||||
|
||||
|
||||
PHP_FUNCTION(grn_ctx_init)
|
||||
{
|
||||
grn_ctx *ctx = (grn_ctx *) malloc(sizeof(grn_ctx));
|
||||
long res_id = -1;
|
||||
long flags = 0;
|
||||
grn_rc rc;
|
||||
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &flags) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
if ((rc = grn_ctx_init(ctx, flags)) != GRN_SUCCESS) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
res_id = ZEND_REGISTER_RESOURCE(return_value, ctx, le_grn_ctx);
|
||||
RETURN_RESOURCE(res_id);
|
||||
}
|
||||
|
||||
|
||||
PHP_FUNCTION(grn_ctx_close)
|
||||
{
|
||||
zval *res = NULL;
|
||||
int res_id = -1;
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &res) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
zend_list_delete(Z_LVAL_P(res)); // call grn_ctx_dtor
|
||||
RETURN_TRUE;
|
||||
}
|
||||
|
||||
|
||||
PHP_FUNCTION(grn_ctx_connect)
|
||||
{
|
||||
zval *res = NULL;
|
||||
int res_id = -1;
|
||||
|
||||
grn_rc rc;
|
||||
grn_ctx *ctx;
|
||||
char *host = "localhost";
|
||||
int host_len = 0;
|
||||
long port = 10041;
|
||||
long flags = 0;
|
||||
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs|ll", &res, &host, &host_len, &port, &flags) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
ZEND_FETCH_RESOURCE(ctx, grn_ctx *, &res, res_id, "grn_ctx", le_grn_ctx);
|
||||
|
||||
if ((rc = grn_ctx_connect(ctx, host, port, flags)) != GRN_SUCCESS) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
RETURN_TRUE;
|
||||
}
|
||||
|
||||
|
||||
PHP_FUNCTION(grn_ctx_send)
|
||||
{
|
||||
zval *res = NULL;
|
||||
int res_id = -1;
|
||||
|
||||
grn_ctx *ctx;
|
||||
char *query = NULL;
|
||||
unsigned int query_len, qid;
|
||||
long flags = 0;
|
||||
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs|l", &res, &query, &query_len, &flags) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
ZEND_FETCH_RESOURCE(ctx, grn_ctx *, &res, res_id, "grn_ctx", le_grn_ctx);
|
||||
qid = grn_ctx_send(ctx, query, query_len, flags);
|
||||
if (ctx->rc != GRN_SUCCESS) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
RETURN_LONG(qid)
|
||||
|
||||
}
|
||||
|
||||
|
||||
PHP_FUNCTION(grn_ctx_recv)
|
||||
{
|
||||
zval *res,*ret = NULL;
|
||||
int res_id = -1;
|
||||
grn_ctx *ctx;
|
||||
|
||||
char *str;
|
||||
int flags;
|
||||
unsigned int str_len, qid;
|
||||
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &res) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
ZEND_FETCH_RESOURCE(ctx, grn_ctx *, &res, res_id, "grn_ctx", le_grn_ctx);
|
||||
|
||||
qid = grn_ctx_recv(ctx, &str, &str_len, &flags);
|
||||
|
||||
if (ctx->rc != GRN_SUCCESS) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
MAKE_STD_ZVAL(ret);
|
||||
array_init(ret);
|
||||
array_init(return_value);
|
||||
|
||||
add_next_index_long(ret, flags);
|
||||
add_next_index_stringl(ret, str, str_len, 1);
|
||||
|
||||
add_index_zval(return_value, qid, ret);
|
||||
}
|
||||
|
||||
#endif /* HAVE_GROONGA */
|
||||
125
storage/mroonga/vendor/groonga/bindings/php/php_groonga.h
vendored
Normal file
|
|
@ -0,0 +1,125 @@
|
|||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
| unknown license: |
|
||||
+----------------------------------------------------------------------+
|
||||
| Authors: yu <yu@irx.jp> |
|
||||
+----------------------------------------------------------------------+
|
||||
*/
|
||||
|
||||
#ifndef PHP_GROONGA_H
|
||||
#define PHP_GROONGA_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <php.h>
|
||||
|
||||
#ifdef HAVE_GROONGA
|
||||
|
||||
#include <php_ini.h>
|
||||
#include <SAPI.h>
|
||||
#include <ext/standard/info.h>
|
||||
#include <Zend/zend_extensions.h>
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
#include <groonga.h>
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern zend_module_entry groonga_module_entry;
|
||||
#define phpext_groonga_ptr &groonga_module_entry
|
||||
|
||||
#ifdef PHP_WIN32
|
||||
#define PHP_GROONGA_API __declspec(dllexport)
|
||||
#else
|
||||
#define PHP_GROONGA_API
|
||||
#endif
|
||||
|
||||
PHP_MINIT_FUNCTION(groonga);
|
||||
PHP_MSHUTDOWN_FUNCTION(groonga);
|
||||
PHP_RINIT_FUNCTION(groonga);
|
||||
PHP_RSHUTDOWN_FUNCTION(groonga);
|
||||
PHP_MINFO_FUNCTION(groonga);
|
||||
|
||||
#ifdef ZTS
|
||||
#include "TSRM.h"
|
||||
#endif
|
||||
|
||||
#define FREE_RESOURCE(resource) zend_list_delete(Z_LVAL_P(resource))
|
||||
|
||||
#define PROP_GET_LONG(name) Z_LVAL_P(zend_read_property(_this_ce, _this_zval, #name, strlen(#name), 1 TSRMLS_CC))
|
||||
#define PROP_SET_LONG(name, l) zend_update_property_long(_this_ce, _this_zval, #name, strlen(#name), l TSRMLS_CC)
|
||||
|
||||
#define PROP_GET_DOUBLE(name) Z_DVAL_P(zend_read_property(_this_ce, _this_zval, #name, strlen(#name), 1 TSRMLS_CC))
|
||||
#define PROP_SET_DOUBLE(name, d) zend_update_property_double(_this_ce, _this_zval, #name, strlen(#name), d TSRMLS_CC)
|
||||
|
||||
#define PROP_GET_STRING(name) Z_STRVAL_P(zend_read_property(_this_ce, _this_zval, #name, strlen(#name), 1 TSRMLS_CC))
|
||||
#define PROP_GET_STRLEN(name) Z_STRLEN_P(zend_read_property(_this_ce, _this_zval, #name, strlen(#name), 1 TSRMLS_CC))
|
||||
#define PROP_SET_STRING(name, s) zend_update_property_string(_this_ce, _this_zval, #name, strlen(#name), s TSRMLS_CC)
|
||||
#define PROP_SET_STRINGL(name, s, l) zend_update_property_stringl(_this_ce, _this_zval, #name, strlen(#name), s, l TSRMLS_CC)
|
||||
|
||||
|
||||
PHP_FUNCTION(grn_ctx_init);
|
||||
#if (PHP_MAJOR_VERSION >= 5)
|
||||
ZEND_BEGIN_ARG_INFO_EX(grn_ctx_init_arg_info, ZEND_SEND_BY_VAL, ZEND_RETURN_VALUE, 1)
|
||||
ZEND_ARG_INFO(0, flags)
|
||||
ZEND_END_ARG_INFO()
|
||||
#else /* PHP 4.x */
|
||||
#define grn_ctx_init_arg_info NULL
|
||||
#endif
|
||||
|
||||
PHP_FUNCTION(grn_ctx_close);
|
||||
#if (PHP_MAJOR_VERSION >= 5)
|
||||
ZEND_BEGIN_ARG_INFO_EX(grn_ctx_close_arg_info, ZEND_SEND_BY_VAL, ZEND_RETURN_VALUE, 1)
|
||||
ZEND_ARG_INFO(0, res)
|
||||
ZEND_END_ARG_INFO()
|
||||
#else /* PHP 4.x */
|
||||
#define grn_ctx_close_arg_info NULL
|
||||
#endif
|
||||
|
||||
PHP_FUNCTION(grn_ctx_connect);
|
||||
#if (PHP_MAJOR_VERSION >= 5)
|
||||
ZEND_BEGIN_ARG_INFO_EX(grn_ctx_connect_arg_info, ZEND_SEND_BY_VAL, ZEND_RETURN_VALUE, 4)
|
||||
ZEND_ARG_INFO(0, res)
|
||||
ZEND_ARG_INFO(0, host)
|
||||
ZEND_ARG_INFO(0, port)
|
||||
ZEND_ARG_INFO(0, flags)
|
||||
ZEND_END_ARG_INFO()
|
||||
#else /* PHP 4.x */
|
||||
#define grn_ctx_connect_arg_info NULL
|
||||
#endif
|
||||
|
||||
PHP_FUNCTION(grn_ctx_send);
|
||||
#if (PHP_MAJOR_VERSION >= 5)
|
||||
ZEND_BEGIN_ARG_INFO_EX(grn_ctx_send_arg_info, ZEND_SEND_BY_VAL, ZEND_RETURN_VALUE, 3)
|
||||
ZEND_ARG_INFO(0, res)
|
||||
ZEND_ARG_INFO(0, query)
|
||||
ZEND_ARG_INFO(0, flags)
|
||||
ZEND_END_ARG_INFO()
|
||||
#else /* PHP 4.x */
|
||||
#define grn_ctx_send_arg_info NULL
|
||||
#endif
|
||||
|
||||
PHP_FUNCTION(grn_ctx_recv);
|
||||
#if (PHP_MAJOR_VERSION >= 5)
|
||||
ZEND_BEGIN_ARG_INFO_EX(grn_ctx_recv_arg_info, ZEND_SEND_BY_VAL, ZEND_RETURN_VALUE, 1)
|
||||
ZEND_ARG_INFO(0, res)
|
||||
ZEND_END_ARG_INFO()
|
||||
#else /* PHP 4.x */
|
||||
#define grn_ctx_recv_arg_info NULL
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
} // extern "C"
|
||||
#endif
|
||||
|
||||
#endif /* PHP_HAVE_GROONGA */
|
||||
|
||||
#endif /* PHP_GROONGA_H */
|
||||
29
storage/mroonga/vendor/groonga/bindings/php/tests/001.phpt
vendored
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
--TEST--
|
||||
groonga connection
|
||||
--DESCRIPTION--
|
||||
required: variables_order includes "E"
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (!extension_loaded("groonga")) print "skip";
|
||||
if (!getenv('GROONGA_TEST_HOST')) print "skip";
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$host = getenv('GROONGA_TEST_HOST');
|
||||
$port = getenv('GROONGA_TEST_PORT') ? getenv('GROONGA_TEST_PORT') : 10041;
|
||||
|
||||
$grn = grn_ctx_init();
|
||||
grn_ctx_connect($grn, $host, $port) or die("cannot connect groong server ({$host}:{$port})");
|
||||
grn_ctx_send($grn, 'table_list');
|
||||
var_dump(grn_ctx_recv($grn));
|
||||
grn_ctx_close($grn);
|
||||
--EXPECTF--
|
||||
array(1) {
|
||||
[0]=>
|
||||
array(2) {
|
||||
[0]=>
|
||||
int(0)
|
||||
[1]=>
|
||||
string(%d) "%s"
|
||||
}
|
||||
}
|
||||
364
storage/mroonga/vendor/groonga/bindings/python/ql/groongaql.c
vendored
Normal file
|
|
@ -0,0 +1,364 @@
|
|||
/* Copyright(C) 2007 Brazil
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
#include <Python.h>
|
||||
#include <groonga.h>
|
||||
|
||||
/* TODO: use exception */
|
||||
|
||||
typedef struct {
|
||||
PyObject_HEAD
|
||||
grn_ctx ctx;
|
||||
int closed;
|
||||
} groongaql_ContextObject;
|
||||
|
||||
static PyTypeObject groongaql_ContextType;
|
||||
|
||||
/* Object methods */
|
||||
|
||||
static PyObject *
|
||||
groongaql_ContextObject_new(PyTypeObject *type, PyObject *args, PyObject *keywds)
|
||||
{
|
||||
grn_rc rc;
|
||||
int flags;
|
||||
grn_encoding encoding;
|
||||
groongaql_ContextObject *self;
|
||||
|
||||
static char *kwlist[] = {"flags", "encoding", NULL};
|
||||
|
||||
if (!PyArg_ParseTupleAndKeywords(args, keywds, "ii", kwlist,
|
||||
&flags, &encoding)) {
|
||||
return NULL;
|
||||
}
|
||||
if (!(self = (groongaql_ContextObject *)type->tp_alloc(type, 0))) {
|
||||
return NULL;
|
||||
}
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
rc = grn_ctx_init(&self->ctx, flags);
|
||||
GRN_CTX_SET_ENCODING(&self->ctx, encoding);
|
||||
Py_END_ALLOW_THREADS
|
||||
if (rc) {
|
||||
self->ob_type->tp_free(self);
|
||||
return NULL;
|
||||
}
|
||||
self->closed = 0;
|
||||
return (PyObject *)self;
|
||||
}
|
||||
|
||||
static void
|
||||
groongaql_ContextObject_dealloc(groongaql_ContextObject *self)
|
||||
{
|
||||
if (!self->closed) {
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
grn_ctx_fin(&self->ctx);
|
||||
Py_END_ALLOW_THREADS
|
||||
}
|
||||
self->ob_type->tp_free(self);
|
||||
}
|
||||
|
||||
/* Class methods */
|
||||
|
||||
/* instance methods */
|
||||
|
||||
static PyObject *
|
||||
groongaql_ContextClass_ql_connect(groongaql_ContextObject *self, PyObject *args, PyObject *keywds)
|
||||
{
|
||||
grn_rc rc;
|
||||
int port, flags;
|
||||
const char *host;
|
||||
static char *kwlist[] = {"host", "port", "flags", NULL};
|
||||
|
||||
if (!PyArg_ParseTupleAndKeywords(args, keywds, "sii", kwlist,
|
||||
&host, &port, &flags)) {
|
||||
return NULL;
|
||||
}
|
||||
if (self->closed) { return NULL; }
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
rc = grn_ctx_connect(&self->ctx, host, port, flags);
|
||||
Py_END_ALLOW_THREADS
|
||||
return Py_BuildValue("i", rc);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
groongaql_Context_ql_send(groongaql_ContextObject *self, PyObject *args, PyObject *keywds)
|
||||
{
|
||||
grn_rc rc;
|
||||
char *str;
|
||||
int str_len, flags;
|
||||
static char *kwlist[] = {"str", "flags", NULL};
|
||||
|
||||
if (!PyArg_ParseTupleAndKeywords(args, keywds, "s#i", kwlist,
|
||||
&str,
|
||||
&str_len,
|
||||
&flags)) {
|
||||
return NULL;
|
||||
}
|
||||
if (self->closed) { return NULL; }
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
rc = grn_ctx_send(&self->ctx, str, str_len, flags);
|
||||
Py_END_ALLOW_THREADS
|
||||
return Py_BuildValue("i", rc);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
groongaql_Context_ql_recv(groongaql_ContextObject *self)
|
||||
{
|
||||
grn_rc rc;
|
||||
int flags;
|
||||
char *str;
|
||||
unsigned int str_len;
|
||||
|
||||
if (self->closed) { return NULL; }
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
rc = grn_ctx_recv(&self->ctx, &str, &str_len, &flags);
|
||||
Py_END_ALLOW_THREADS
|
||||
return Py_BuildValue("(is#i)", rc, str, str_len, flags);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
groongaql_Context_fin(groongaql_ContextObject *self)
|
||||
{
|
||||
grn_rc rc;
|
||||
|
||||
if (self->closed) { return NULL; }
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
rc = grn_ctx_fin(&self->ctx);
|
||||
Py_END_ALLOW_THREADS
|
||||
if (!rc) {
|
||||
self->closed = 1;
|
||||
}
|
||||
return Py_BuildValue("i", rc);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
groongaql_Context_ql_info_get(groongaql_ContextObject *self)
|
||||
{
|
||||
grn_rc rc;
|
||||
grn_ctx_info info;
|
||||
|
||||
if (self->closed) { return NULL; }
|
||||
rc = grn_ctx_info_get(&self->ctx, &info);
|
||||
/* TODO: handling unsigned int properlly */
|
||||
/* TODO: get outbuf */
|
||||
return Py_BuildValue("{s:i,s:i,s:i}",
|
||||
"rc", rc,
|
||||
"com_status", info.com_status,
|
||||
/* "outbuf", info.outbuf, */
|
||||
"stat", info.stat
|
||||
);
|
||||
}
|
||||
|
||||
/* methods of classes */
|
||||
|
||||
static PyMethodDef groongaql_Context_methods[] = {
|
||||
{"ql_connect", (PyCFunction)groongaql_ContextClass_ql_connect,
|
||||
METH_VARARGS | METH_KEYWORDS,
|
||||
"Create a remote groonga context."},
|
||||
{"ql_send", (PyCFunction)groongaql_Context_ql_send,
|
||||
METH_VARARGS | METH_KEYWORDS,
|
||||
"Send message to context."},
|
||||
{"ql_recv", (PyCFunction)groongaql_Context_ql_recv,
|
||||
METH_NOARGS,
|
||||
"Receive message from context."},
|
||||
{"fin", (PyCFunction)groongaql_Context_fin,
|
||||
METH_NOARGS,
|
||||
"Release groonga context."},
|
||||
{"ql_info_get", (PyCFunction)groongaql_Context_ql_info_get,
|
||||
METH_NOARGS,
|
||||
"Get QL context information."},
|
||||
{NULL, NULL, 0, NULL}
|
||||
};
|
||||
|
||||
static PyMethodDef module_methods[] = {
|
||||
{NULL, NULL, 0, NULL}
|
||||
};
|
||||
|
||||
/* type objects */
|
||||
|
||||
static PyTypeObject groongaql_ContextType = {
|
||||
PyObject_HEAD_INIT(NULL)
|
||||
0, /* ob_size */
|
||||
"groongaql.Context", /* tp_name */
|
||||
sizeof(groongaql_ContextObject), /* tp_basicsize */
|
||||
0, /* tp_itemsize */
|
||||
(destructor)groongaql_ContextObject_dealloc, /* tp_dealloc */
|
||||
0, /* tp_print */
|
||||
0, /* tp_getattr */
|
||||
0, /* tp_setattr */
|
||||
0, /* tp_compare */
|
||||
0, /* tp_repr */
|
||||
0, /* tp_as_number */
|
||||
0, /* tp_as_sequence */
|
||||
0, /* tp_as_mapping */
|
||||
0, /* tp_hash */
|
||||
0, /* tp_call */
|
||||
0, /* tp_str */
|
||||
0, /* tp_getattro */
|
||||
0, /* tp_setattro */
|
||||
0, /* tp_as_buffer */
|
||||
Py_TPFLAGS_DEFAULT, /* tp_flags */
|
||||
"groonga Context objects", /* tp_doc */
|
||||
0, /* tp_traverse */
|
||||
0, /* tp_clear */
|
||||
0, /* tp_richcompare */
|
||||
0, /* tp_weaklistoffset */
|
||||
0, /* tp_iter */
|
||||
0, /* tp_iternext */
|
||||
groongaql_Context_methods, /* tp_methods */
|
||||
0, /* tp_members */
|
||||
0, /* tp_getset */
|
||||
0, /* tp_base */
|
||||
0, /* tp_dict */
|
||||
0, /* tp_descr_get */
|
||||
0, /* tp_descr_set */
|
||||
0, /* tp_dictoffset */
|
||||
0, /* tp_init */
|
||||
0, /* tp_alloc */
|
||||
groongaql_ContextObject_new, /* tp_new */
|
||||
};
|
||||
|
||||
/* consts */
|
||||
|
||||
typedef struct _ConstPair {
|
||||
const char *name;
|
||||
int value;
|
||||
} ConstPair;
|
||||
|
||||
static ConstPair consts[] = {
|
||||
/* grn_rc */
|
||||
{"SUCCESS", GRN_SUCCESS},
|
||||
{"END_OF_DATA", GRN_END_OF_DATA},
|
||||
{"UNKNOWN_ERROR", GRN_UNKNOWN_ERROR},
|
||||
{"OPERATION_NOT_PERMITTED", GRN_OPERATION_NOT_PERMITTED},
|
||||
{"NO_SUCH_FILE_OR_DIRECTORY", GRN_NO_SUCH_FILE_OR_DIRECTORY},
|
||||
{"NO_SUCH_PROCESS", GRN_NO_SUCH_PROCESS},
|
||||
{"INTERRUPTED_FUNCTION_CALL", GRN_INTERRUPTED_FUNCTION_CALL},
|
||||
{"INPUT_OUTPUT_ERROR", GRN_INPUT_OUTPUT_ERROR},
|
||||
{"NO_SUCH_DEVICE_OR_ADDRESS", GRN_NO_SUCH_DEVICE_OR_ADDRESS},
|
||||
{"ARG_LIST_TOO_LONG", GRN_ARG_LIST_TOO_LONG},
|
||||
{"EXEC_FORMAT_ERROR", GRN_EXEC_FORMAT_ERROR},
|
||||
{"BAD_FILE_DESCRIPTOR", GRN_BAD_FILE_DESCRIPTOR},
|
||||
{"NO_CHILD_PROCESSES", GRN_NO_CHILD_PROCESSES},
|
||||
{"RESOURCE_TEMPORARILY_UNAVAILABLE", GRN_RESOURCE_TEMPORARILY_UNAVAILABLE},
|
||||
{"NOT_ENOUGH_SPACE", GRN_NOT_ENOUGH_SPACE},
|
||||
{"PERMISSION_DENIED", GRN_PERMISSION_DENIED},
|
||||
{"BAD_ADDRESS", GRN_BAD_ADDRESS},
|
||||
{"RESOURCE_BUSY", GRN_RESOURCE_BUSY},
|
||||
{"FILE_EXISTS", GRN_FILE_EXISTS},
|
||||
{"IMPROPER_LINK", GRN_IMPROPER_LINK},
|
||||
{"NO_SUCH_DEVICE", GRN_NO_SUCH_DEVICE},
|
||||
{"NOT_A_DIRECTORY", GRN_NOT_A_DIRECTORY},
|
||||
{"IS_A_DIRECTORY", GRN_IS_A_DIRECTORY},
|
||||
{"INVALID_ARGUMENT", GRN_INVALID_ARGUMENT},
|
||||
{"TOO_MANY_OPEN_FILES_IN_SYSTEM", GRN_TOO_MANY_OPEN_FILES_IN_SYSTEM},
|
||||
{"TOO_MANY_OPEN_FILES", GRN_TOO_MANY_OPEN_FILES},
|
||||
{"INAPPROPRIATE_I_O_CONTROL_OPERATION", GRN_INAPPROPRIATE_I_O_CONTROL_OPERATION},
|
||||
{"FILE_TOO_LARGE", GRN_FILE_TOO_LARGE},
|
||||
{"NO_SPACE_LEFT_ON_DEVICE", GRN_NO_SPACE_LEFT_ON_DEVICE},
|
||||
{"INVALID_SEEK", GRN_INVALID_SEEK},
|
||||
{"READ_ONLY_FILE_SYSTEM", GRN_READ_ONLY_FILE_SYSTEM},
|
||||
{"TOO_MANY_LINKS", GRN_TOO_MANY_LINKS},
|
||||
{"BROKEN_PIPE", GRN_BROKEN_PIPE},
|
||||
{"DOMAIN_ERROR", GRN_DOMAIN_ERROR},
|
||||
{"RESULT_TOO_LARGE", GRN_RESULT_TOO_LARGE},
|
||||
{"RESOURCE_DEADLOCK_AVOIDED", GRN_RESOURCE_DEADLOCK_AVOIDED},
|
||||
{"NO_MEMORY_AVAILABLE", GRN_NO_MEMORY_AVAILABLE},
|
||||
{"FILENAME_TOO_LONG", GRN_FILENAME_TOO_LONG},
|
||||
{"NO_LOCKS_AVAILABLE", GRN_NO_LOCKS_AVAILABLE},
|
||||
{"FUNCTION_NOT_IMPLEMENTED", GRN_FUNCTION_NOT_IMPLEMENTED},
|
||||
{"DIRECTORY_NOT_EMPTY", GRN_DIRECTORY_NOT_EMPTY},
|
||||
{"ILLEGAL_BYTE_SEQUENCE", GRN_ILLEGAL_BYTE_SEQUENCE},
|
||||
{"SOCKET_NOT_INITIALIZED", GRN_SOCKET_NOT_INITIALIZED},
|
||||
{"OPERATION_WOULD_BLOCK", GRN_OPERATION_WOULD_BLOCK},
|
||||
{"ADDRESS_IS_NOT_AVAILABLE", GRN_ADDRESS_IS_NOT_AVAILABLE},
|
||||
{"NETWORK_IS_DOWN", GRN_NETWORK_IS_DOWN},
|
||||
{"NO_BUFFER", GRN_NO_BUFFER},
|
||||
{"SOCKET_IS_ALREADY_CONNECTED", GRN_SOCKET_IS_ALREADY_CONNECTED},
|
||||
{"SOCKET_IS_NOT_CONNECTED", GRN_SOCKET_IS_NOT_CONNECTED},
|
||||
{"SOCKET_IS_ALREADY_SHUTDOWNED", GRN_SOCKET_IS_ALREADY_SHUTDOWNED},
|
||||
{"OPERATION_TIMEOUT", GRN_OPERATION_TIMEOUT},
|
||||
{"CONNECTION_REFUSED", GRN_CONNECTION_REFUSED},
|
||||
{"RANGE_ERROR", GRN_RANGE_ERROR},
|
||||
{"TOKENIZER_ERROR", GRN_TOKENIZER_ERROR},
|
||||
{"FILE_CORRUPT", GRN_FILE_CORRUPT},
|
||||
{"INVALID_FORMAT", GRN_INVALID_FORMAT},
|
||||
{"OBJECT_CORRUPT", GRN_OBJECT_CORRUPT},
|
||||
{"TOO_MANY_SYMBOLIC_LINKS", GRN_TOO_MANY_SYMBOLIC_LINKS},
|
||||
{"NOT_SOCKET", GRN_NOT_SOCKET},
|
||||
{"OPERATION_NOT_SUPPORTED", GRN_OPERATION_NOT_SUPPORTED},
|
||||
{"ADDRESS_IS_IN_USE", GRN_ADDRESS_IS_IN_USE},
|
||||
{"ZLIB_ERROR", GRN_ZLIB_ERROR},
|
||||
{"LZO_ERROR", GRN_LZO_ERROR},
|
||||
/* grn_encoding */
|
||||
{"ENC_DEFAULT", GRN_ENC_DEFAULT},
|
||||
{"ENC_NONE", GRN_ENC_NONE},
|
||||
{"ENC_EUC_JP", GRN_ENC_EUC_JP},
|
||||
{"ENC_UTF8", GRN_ENC_UTF8},
|
||||
{"ENC_SJIS", GRN_ENC_SJIS},
|
||||
{"ENC_LATIN1", GRN_ENC_LATIN1},
|
||||
{"ENC_KOI8R", GRN_ENC_KOI8R},
|
||||
/* grn_ctx flags */
|
||||
{"CTX_USE_QL", GRN_CTX_USE_QL},
|
||||
{"CTX_BATCH_MODE", GRN_CTX_BATCH_MODE},
|
||||
{"CTX_MORE", GRN_CTX_MORE},
|
||||
{"CTX_TAIL", GRN_CTX_TAIL},
|
||||
{"CTX_HEAD", GRN_CTX_HEAD},
|
||||
{"CTX_QUIET", GRN_CTX_QUIET},
|
||||
{"CTX_QUIT", GRN_CTX_QUIT},
|
||||
{"CTX_FIN", GRN_CTX_FIN},
|
||||
/* end */
|
||||
{NULL, 0}
|
||||
};
|
||||
|
||||
#ifndef PyMODINIT_FUNC
|
||||
#define PyMODINIT_FUNC void
|
||||
#endif
|
||||
PyMODINIT_FUNC
|
||||
initgroongaql(void)
|
||||
{
|
||||
unsigned int i;
|
||||
PyObject *m, *dict;
|
||||
|
||||
if (!(m = Py_InitModule3("groongaql", module_methods,
|
||||
"groonga ql module."))) {
|
||||
goto exit;
|
||||
}
|
||||
grn_init();
|
||||
|
||||
/* register classes */
|
||||
|
||||
if (PyType_Ready(&groongaql_ContextType) < 0) { goto exit; }
|
||||
Py_INCREF(&groongaql_ContextType);
|
||||
PyModule_AddObject(m, "Context", (PyObject *)&groongaql_ContextType);
|
||||
|
||||
/* register consts */
|
||||
|
||||
if (!(dict = PyModule_GetDict(m))) { goto exit; }
|
||||
|
||||
for (i = 0; consts[i].name; i++) {
|
||||
PyObject *v;
|
||||
if (!(v = PyInt_FromLong(consts[i].value))) {
|
||||
goto exit;
|
||||
}
|
||||
PyDict_SetItemString(dict, consts[i].name, v);
|
||||
Py_DECREF(v);
|
||||
}
|
||||
if (Py_AtExit((void (*)(void))grn_fin)) { goto exit; }
|
||||
exit:
|
||||
if (PyErr_Occurred()) {
|
||||
PyErr_SetString(PyExc_ImportError, "groongaql: init failed");
|
||||
}
|
||||
}
|
||||
22
storage/mroonga/vendor/groonga/bindings/python/ql/setup.py
vendored
Executable file
|
|
@ -0,0 +1,22 @@
|
|||
#!/usr/bin/python
|
||||
from distutils.core import setup, Extension
|
||||
|
||||
#cflags = ['-Wall', '-fPIC', '-g', '-O0']
|
||||
cflags = ['-Wall', '-fPIC', '-O3']
|
||||
|
||||
ext = Extension('groongaql',
|
||||
libraries = ['groonga'],
|
||||
sources = ['groongaql.c'],
|
||||
extra_compile_args = cflags)
|
||||
|
||||
setup(name = 'groongaql',
|
||||
version = '1.0',
|
||||
description = 'python GQTP',
|
||||
long_description = '''
|
||||
This is a GQTP Python API package.
|
||||
''',
|
||||
license='GNU LESSER GENERAL PUBLIC LICENSE',
|
||||
author = 'Brazil',
|
||||
author_email = 'groonga at razil.jp',
|
||||
ext_modules = [ext]
|
||||
)
|
||||
2
storage/mroonga/vendor/groonga/build/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
SUBDIRS = \
|
||||
cmake_modules
|
||||
13
storage/mroonga/vendor/groonga/build/ac_macros/check_functions.m4
vendored
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
# -*- autoconf -*-
|
||||
|
||||
AC_CHECK_FUNCS(_strnicmp)
|
||||
AC_CHECK_FUNCS(_strtoui64)
|
||||
AC_CHECK_FUNCS(close)
|
||||
AC_CHECK_FUNCS(gmtime_r)
|
||||
AC_CHECK_FUNCS(localtime_r)
|
||||
AC_CHECK_FUNCS(mkostemp)
|
||||
AC_CHECK_FUNCS(open)
|
||||
AC_CHECK_FUNCS(read)
|
||||
AC_CHECK_FUNCS(strncasecmp)
|
||||
AC_CHECK_FUNCS(strtoull)
|
||||
AC_CHECK_FUNCS(write)
|
||||
24
storage/mroonga/vendor/groonga/build/ac_macros/check_headers.m4
vendored
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
# -*- autoconf -*-
|
||||
|
||||
AC_CHECK_HEADERS(dlfcn.h)
|
||||
AC_CHECK_HEADERS(errno.h)
|
||||
AC_CHECK_HEADERS(execinfo.h)
|
||||
AC_CHECK_HEADERS(inttypes.h)
|
||||
AC_CHECK_HEADERS(netdb.h)
|
||||
AC_CHECK_HEADERS(netinet/in.h)
|
||||
AC_CHECK_HEADERS(netinet/tcp.h)
|
||||
AC_CHECK_HEADERS(signal.h)
|
||||
AC_CHECK_HEADERS(stdint.h)
|
||||
AC_CHECK_HEADERS(stdlib.h)
|
||||
AC_CHECK_HEADERS(sys/mman.h)
|
||||
AC_CHECK_HEADERS(sys/param.h)
|
||||
AC_CHECK_HEADERS(sys/resource.h)
|
||||
AC_CHECK_HEADERS(sys/socket.h)
|
||||
AC_CHECK_HEADERS(sys/sysctl.h)
|
||||
AC_CHECK_HEADERS(sys/time.h)
|
||||
AC_CHECK_HEADERS(sys/timeb.h)
|
||||
AC_CHECK_HEADERS(sys/types.h)
|
||||
AC_CHECK_HEADERS(sys/wait.h)
|
||||
AC_CHECK_HEADERS(time.h)
|
||||
AC_CHECK_HEADERS(ucontext.h)
|
||||
AC_CHECK_HEADERS(unistd.h)
|
||||
2
storage/mroonga/vendor/groonga/build/cmake_modules/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
EXTRA_DIST = \
|
||||
ReadFileList.cmake
|
||||
27
storage/mroonga/vendor/groonga/build/cmake_modules/ReadFileList.cmake
vendored
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
# Copyright(C) 2012 Brazil
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License version 2.1 as published by the Free Software Foundation.
|
||||
#
|
||||
# This library 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
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
macro(read_file_list file_name output_variable)
|
||||
file(READ ${file_name} ${output_variable})
|
||||
# Remove variable declaration at the first line:
|
||||
# "libgroonga_la_SOURCES = \" -> ""
|
||||
string(REGEX REPLACE "^.*=[ \t]*\\\\" ""
|
||||
${output_variable} "${${output_variable}}")
|
||||
# Remove white spaces: " com.c \\\n com.h \\\n" -> "com.c\\com.h"
|
||||
string(REGEX REPLACE "[ \t\n]" "" ${output_variable} "${${output_variable}}")
|
||||
# Convert string to list: "com.c\\com.h" -> "com.c;com.h"
|
||||
# NOTE: List in CMake is ";" separated string.
|
||||
string(REGEX REPLACE "\\\\" ";" ${output_variable} "${${output_variable}}")
|
||||
endmacro()
|
||||
5
storage/mroonga/vendor/groonga/build/makefiles/LC_MESSAGES.am
vendored
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
BUILT_SOURCES =
|
||||
EXTRA_DIST =
|
||||
SUFFIXES =
|
||||
|
||||
include $(top_srcdir)/build/makefiles/gettext.am
|
||||
73
storage/mroonga/vendor/groonga/build/makefiles/gettext.am
vendored
Normal file
|
|
@ -0,0 +1,73 @@
|
|||
include $(top_srcdir)/doc/files.am
|
||||
include $(top_srcdir)/build/makefiles/sphinx-build.am
|
||||
|
||||
EXTRA_DIST += \
|
||||
$(po_files)
|
||||
|
||||
if DOCUMENT_AVAILABLE
|
||||
EXTRA_DIST += \
|
||||
$(mo_files)
|
||||
endif
|
||||
|
||||
if DOCUMENT_BUILDABLE
|
||||
BUILT_SOURCES += \
|
||||
pot-build-stamp \
|
||||
edit-po-build-stamp \
|
||||
$(mo_files)
|
||||
endif
|
||||
|
||||
SUFFIXES += .pot .po .mo .edit
|
||||
|
||||
.PHONY: gettext update build
|
||||
|
||||
.pot.edit:
|
||||
if test -f $*.po; then \
|
||||
msgmerge \
|
||||
--quiet \
|
||||
--sort-by-file \
|
||||
--output-file=$@.tmp \
|
||||
$*.po \
|
||||
$<; \
|
||||
else \
|
||||
msginit \
|
||||
--input=$< \
|
||||
--output-file=$@.tmp \
|
||||
--locale=$(LOCALE) \
|
||||
--no-translator; \
|
||||
fi
|
||||
(echo "# -*- po -*-"; \
|
||||
GREP_OPTIONS= grep -v '^# -\*- po -\*-' $@.tmp | \
|
||||
GREP_OPTIONS= grep -v '^"POT-Creation-Date:') > $@
|
||||
rm $@.tmp
|
||||
|
||||
.edit.po:
|
||||
msgcat --no-location --output $@ $<
|
||||
|
||||
.po.mo:
|
||||
msgfmt -o $@ $<
|
||||
|
||||
if DOCUMENT_BUILDABLE
|
||||
update: pot-build-stamp edit-po-build-stamp
|
||||
build: update $(mo_files)
|
||||
else
|
||||
update:
|
||||
build:
|
||||
endif
|
||||
|
||||
html: build
|
||||
man: build
|
||||
pdf: build
|
||||
|
||||
gettext:
|
||||
rm *.pot || true
|
||||
$(SPHINX_BUILD_COMMAND) -d doctrees -b gettext $(ALLSPHINXOPTS) .
|
||||
xgettext --language Python --output conf.pot \
|
||||
$(top_srcdir)/doc/source/conf.py
|
||||
|
||||
pot-build-stamp: $(absolute_source_files)
|
||||
$(MAKE) gettext
|
||||
@touch $@
|
||||
|
||||
edit-po-build-stamp: $(absolute_source_files)
|
||||
$(MAKE) $(edit_po_files)
|
||||
@touch $@
|
||||
12
storage/mroonga/vendor/groonga/build/makefiles/locale.am
vendored
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
SUBDIRS = LC_MESSAGES
|
||||
|
||||
BUILT_SOURCES =
|
||||
EXTRA_DIST =
|
||||
|
||||
include $(top_srcdir)/build/makefiles/sphinx.am
|
||||
|
||||
init:
|
||||
cd LC_MESSAGES && $(MAKE) $@
|
||||
|
||||
update-po:
|
||||
cd LC_MESSAGES && $(MAKE) update
|
||||
19
storage/mroonga/vendor/groonga/build/makefiles/sphinx-build.am
vendored
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
# You can set these variables from the command line.
|
||||
DOCTREES_BASE = doctrees
|
||||
|
||||
SPHINXOPTS =
|
||||
PAPER =
|
||||
|
||||
# Internal variables.
|
||||
SOURCE_DIR = $(abs_top_srcdir)/doc/source
|
||||
PAPEROPT_a4 = -D latex_paper_size=a4
|
||||
PAPEROPT_letter = -D latex_paper_size=letter
|
||||
ALLSPHINXOPTS = $(PAPEROPT_$(PAPER)) -E $(SPHINXOPTS) $(SOURCE_DIR)
|
||||
|
||||
SPHINX_DIR = $(abs_top_builddir)/doc/sphinx
|
||||
SPHINX_BUILD_COMMAND = \
|
||||
DOCUMENT_VERSION="$(DOCUMENT_VERSION)" \
|
||||
DOCUMENT_VERSION_FULL="$(DOCUMENT_VERSION_FULL)" \
|
||||
LOCALE="$(LOCALE)" \
|
||||
PYTHONPATH="$(SPHINX_DIR):$$PYTHONPATH" \
|
||||
$(SPHINX_BUILD)
|
||||
179
storage/mroonga/vendor/groonga/build/makefiles/sphinx.am
vendored
Normal file
|
|
@ -0,0 +1,179 @@
|
|||
include $(top_srcdir)/doc/files.am
|
||||
include $(top_srcdir)/build/makefiles/sphinx-build.am
|
||||
|
||||
$(html_files): html-build-stamp
|
||||
$(html_files_relative_from_locale_dir): html-build-stamp
|
||||
$(man_files): man-build-stamp
|
||||
|
||||
am__nobase_dist_doc_locale_DATA_DIST =
|
||||
if DOCUMENT_AVAILABLE
|
||||
doc_localedir = $(docdir)/$(LOCALE)
|
||||
nobase_dist_doc_locale_DATA = \
|
||||
$(html_files_relative_from_locale_dir)
|
||||
am__nobase_dist_doc_locale_DATA_DIST += \
|
||||
$(nobase_dist_doc_locale_DATA)
|
||||
endif
|
||||
|
||||
document_source_files = \
|
||||
$(absolute_source_files) \
|
||||
$(absolute_theme_files) \
|
||||
$(po_files_relative_from_locale_dir) \
|
||||
$(mo_files_relative_from_locale_dir)
|
||||
|
||||
required_build_stamps = \
|
||||
html-build-stamp \
|
||||
man-build-stamp \
|
||||
mo-build-stamp
|
||||
|
||||
if DOCUMENT_BUILDABLE
|
||||
EXTRA_DIST += $(required_build_stamps)
|
||||
endif
|
||||
|
||||
man_files = \
|
||||
man/$(PACKAGE_NAME).1
|
||||
|
||||
generated_files = \
|
||||
$(DOCTREES_BASE) \
|
||||
man \
|
||||
man-build-stamp \
|
||||
html \
|
||||
html-build-stamp \
|
||||
pdf \
|
||||
pdf-build-stamp \
|
||||
dirhtml \
|
||||
dirhtml-build-stamp \
|
||||
pickle \
|
||||
pikcle-build-stamp \
|
||||
json \
|
||||
json-build-stamp \
|
||||
htmlhelp \
|
||||
htmlhelp-build-stamp \
|
||||
qthelp \
|
||||
qthelp-build-stamp \
|
||||
latex \
|
||||
latex-build-stamp \
|
||||
changes \
|
||||
changes-build-stamp \
|
||||
linkcheck \
|
||||
linkcheck-build-stamp \
|
||||
doctest
|
||||
|
||||
$(mo_files_relative_from_locale_dir): mo-build-stamp
|
||||
|
||||
mo-build-stamp: $(po_files_relative_from_locale_dir)
|
||||
cd LC_MESSAGES && $(MAKE) build
|
||||
@touch $@
|
||||
|
||||
if DOCUMENT_BUILDABLE
|
||||
clean-local: $(clean_targets) clean-doctrees
|
||||
|
||||
clean-doctrees:
|
||||
rm -rf $(DOCTREES_BASE)
|
||||
|
||||
maintainer-clean-local:
|
||||
rm -rf -- $(generated_files)
|
||||
endif
|
||||
|
||||
.PHONY: help
|
||||
.PHONY: man clean-man
|
||||
.PHONY: html clean-html
|
||||
.PHONY: pdf
|
||||
.PHONY: dirhtml
|
||||
.PHONY: pickle
|
||||
.PHONY: json
|
||||
.PHONY: htmlhelp
|
||||
.PHONY: qthelp
|
||||
.PHONY: latex
|
||||
.PHONY: changes
|
||||
.PHONY: linkcheck
|
||||
.PHONY: doctest
|
||||
|
||||
if DOCUMENT_BUILDABLE
|
||||
help:
|
||||
@echo "Please use \`make <target>' where <target> is one of"
|
||||
@echo " man to make man files"
|
||||
@echo " html to make standalone HTML files"
|
||||
@echo " dirhtml to make HTML files named index.html in directories"
|
||||
@echo " pickle to make pickle files"
|
||||
@echo " json to make JSON files"
|
||||
@echo " htmlhelp to make HTML files and a HTML help project"
|
||||
@echo " qthelp to make HTML files and a qthelp project"
|
||||
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
|
||||
@echo " rdoc to make RDoc files"
|
||||
@echo " textile to make Textile files"
|
||||
@echo " changes to make an overview of all changed/added/deprecated items"
|
||||
@echo " linkcheck to check all external links for integrity"
|
||||
@echo " doctest to run all doctests embedded in the documentation (if enabled)"
|
||||
|
||||
man: man-build-stamp
|
||||
html: html-build-stamp
|
||||
dirhtml: dirhtml-build-stamp
|
||||
pickle: pickle-build-stamp
|
||||
json: json-build-stamp
|
||||
htmlhelp: htmlhelp-build-stamp
|
||||
qthelp: qthelp-build-stamp
|
||||
latex: latex-build-stamp
|
||||
rdoc: rdoc-build-stamp
|
||||
textile: textile-build-stamp
|
||||
changes: changes-build-stamp
|
||||
linkcheck: linkcheck-build-stamp
|
||||
doctest: doctest-build-stamp
|
||||
|
||||
clean_targets = \
|
||||
clean-man \
|
||||
clean-html \
|
||||
clean-dirhtml \
|
||||
clean-pickle \
|
||||
clean-json \
|
||||
clean-htmlhelp \
|
||||
clean-qthelp \
|
||||
clean-latex \
|
||||
clean-rdoc \
|
||||
clean-textile \
|
||||
clean-changes \
|
||||
clean-linkcheck \
|
||||
clean-doctest
|
||||
|
||||
$(clean_targets):
|
||||
target=`echo $@ | sed -e 's/^clean-//'`; \
|
||||
rm -rf $${target}-build-stamp $${target}
|
||||
|
||||
build_stamps = \
|
||||
man-build-stamp \
|
||||
html-build-stamp \
|
||||
dirhtml-build-stamp \
|
||||
pickle-build-stamp \
|
||||
json-build-stamp \
|
||||
htmlhelp-build-stamp \
|
||||
qthelp-build-stamp \
|
||||
latex-build-stamp \
|
||||
rdoc-build-stamp \
|
||||
textile-build-stamp \
|
||||
changes-build-stamp \
|
||||
linkcheck-build-stamp \
|
||||
doctest-build-stamp
|
||||
|
||||
$(build_stamps): $(document_source_files)
|
||||
target=`echo $@ | sed -e 's/-build-stamp$$//'`; \
|
||||
$(SPHINX_BUILD_COMMAND) \
|
||||
-Dlanguage=$(LOCALE) \
|
||||
-d $(DOCTREES_BASE)/$${target} \
|
||||
-b $${target} \
|
||||
$(ALLSPHINXOPTS) \
|
||||
$${target}
|
||||
@touch $@
|
||||
|
||||
qthelp: qthelp-message
|
||||
qthelp-message: qthelp-build-stamp
|
||||
@echo "Build finished; now you can run 'qcollectiongenerator' with the" \
|
||||
".qhcp project file in qthelp/*, like this:"
|
||||
@echo "# qcollectiongenerator qthelp/groonga.qhcp"
|
||||
@echo "To view the help file:"
|
||||
@echo "# assistant -collectionFile qthelp/groonga.qhc"
|
||||
|
||||
latex: latex-message
|
||||
latex-message: latex-build-stamp
|
||||
@echo "Build finished; the LaTeX files are in latex/*."
|
||||
@echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \
|
||||
"run these through (pdf)latex."
|
||||
endif
|
||||
153
storage/mroonga/vendor/groonga/config.h.cmake
vendored
Normal file
|
|
@ -0,0 +1,153 @@
|
|||
/* config.h.cmake. Generated from CMakeLists.txt by cmake. */
|
||||
|
||||
/* general constants */
|
||||
#define CONFIGURE_OPTIONS "${CONFIGURE_OPTIONS}"
|
||||
|
||||
#define HOST_CPU "${CMAKE_HOST_SYSTEM_PROCESSOR}"
|
||||
#define HOST_OS "${CMAKE_HOST_SYSTEM_NAME}"
|
||||
|
||||
#define VERSION "${VERSION}"
|
||||
#define PACKAGE "${PROJECT_NAME}"
|
||||
#define PACKAGE_NAME "${PROJECT_NAME}"
|
||||
#define PACKAGE_STRING "${PROJECT_NAME} ${VERSION}"
|
||||
#define PACKAGE_TARNAME "${PROJECT_NAME}"
|
||||
#define PACKAGE_URL "${PACKAGE_URL}"
|
||||
#define PACKAGE_VERSION "${VERSION}"
|
||||
|
||||
/* groonga related constants */
|
||||
#define GRN_CONFIG_PATH "${GRN_CONFIG_PATH}"
|
||||
#define GRN_LOG_PATH "${GRN_LOG_PATH}"
|
||||
#define GRN_VERSION "${GRN_VERSION}"
|
||||
|
||||
#define GRN_DEFAULT_DB_KEY "${GRN_DEFAULT_DB_KEY}"
|
||||
#define GRN_DEFAULT_ENCODING "${GRN_DEFAULT_ENCODING}"
|
||||
#define GRN_DEFAULT_MATCH_ESCALATION_THRESHOLD \
|
||||
${GRN_DEFAULT_MATCH_ESCALATION_THRESHOLD}
|
||||
#define GRN_DEFAULT_RELATIVE_DOCUMENT_ROOT \
|
||||
"${GRN_DEFAULT_RELATIVE_DOCUMENT_ROOT}"
|
||||
#define GRN_DEFAULT_DOCUMENT_ROOT \
|
||||
"${GRN_DEFAULT_DOCUMENT_ROOT}"
|
||||
|
||||
#define GRN_STACK_SIZE ${GRN_STACK_SIZE}
|
||||
|
||||
#define GRN_LOCK_TIMEOUT ${GRN_LOCK_TIMEOUT}
|
||||
#define GRN_LOCK_WAIT_TIME_NANOSECOND \
|
||||
${GRN_LOCK_WAIT_TIME_NANOSECOND}
|
||||
|
||||
#define GRN_RELATIVE_PLUGINS_DIR \
|
||||
"${GRN_RELATIVE_PLUGINS_DIR}"
|
||||
#define GRN_PLUGINS_DIR "${GRN_PLUGINS_DIR}"
|
||||
#define GRN_PLUGIN_SUFFIX "${GRN_PLUGIN_SUFFIX}"
|
||||
|
||||
#define GRN_QUERY_EXPANDER_TSV_RELATIVE_SYNONYMS_FILE "${GRN_QUERY_EXPANDER_TSV_RELATIVE_SYNONYMS_FILE}"
|
||||
#define GRN_QUERY_EXPANDER_TSV_SYNONYMS_FILE "${GRN_QUERY_EXPANDER_TSV_SYNONYMS_FILE}"
|
||||
|
||||
#define GRN_RELATIVE_RUBY_SCRIPTS_DIR \
|
||||
"${GRN_RELATIVE_RUBY_SCRIPTS_DIR}"
|
||||
#define GRN_RUBY_SCRIPTS_DIR "${GRN_RUBY_SCRIPTS_DIR}"
|
||||
|
||||
#define GRN_DLL_FILENAME L"${GRN_DLL_FILENAME}"
|
||||
|
||||
/* build switches */
|
||||
#cmakedefine USE_MEMORY_DEBUG
|
||||
#cmakedefine USE_MAP_HUGETLB
|
||||
#cmakedefine USE_AIO
|
||||
#cmakedefine USE_DYNAMIC_MALLOC_CHANGE
|
||||
#cmakedefine USE_EPOLL
|
||||
#cmakedefine USE_EXACT_ALLOC_COUNT
|
||||
#cmakedefine USE_FAIL_MALLOC
|
||||
#cmakedefine USE_FUTEX
|
||||
#cmakedefine USE_KQUEUE
|
||||
#cmakedefine USE_MSG_MORE
|
||||
#cmakedefine USE_MSG_NOSIGNAL
|
||||
#cmakedefine USE_POLL
|
||||
#cmakedefine USE_QUERY_ABORT
|
||||
#cmakedefine USE_SELECT
|
||||
|
||||
/* compiler specific build options */
|
||||
#cmakedefine _FILE_OFFSET_BITS @_FILE_OFFSET_BITS@
|
||||
#ifndef _GNU_SOURCE
|
||||
#cmakedefine _GNU_SOURCE
|
||||
#endif
|
||||
#cmakedefine _ISOC99_SOURCE
|
||||
#cmakedefine _LARGE_FILES
|
||||
#cmakedefine _NETBSD_SOURCE
|
||||
#cmakedefine _XOPEN_SOURCE
|
||||
#cmakedefine _XPG4_2
|
||||
#cmakedefine __EXTENSIONS__
|
||||
|
||||
/* build environment */
|
||||
#cmakedefine WORDS_BIGENDIAN
|
||||
|
||||
/* packages */
|
||||
#cmakedefine GRN_WITH_BENCHMARK
|
||||
#cmakedefine GRN_WITH_CUTTER
|
||||
#cmakedefine GRN_WITH_KYTEA
|
||||
#cmakedefine GRN_WITH_LIBMEMCACHED
|
||||
#cmakedefine GRN_WITH_LZO
|
||||
#cmakedefine GRN_WITH_MECAB
|
||||
#cmakedefine GRN_WITH_MESSAGE_PACK
|
||||
#cmakedefine GRN_WITH_MRUBY
|
||||
#cmakedefine GRN_WITH_NFKC
|
||||
#cmakedefine GRN_WITH_ZEROMQ
|
||||
#cmakedefine GRN_WITH_ZLIB
|
||||
|
||||
/* headers */
|
||||
#cmakedefine HAVE_DLFCN_H
|
||||
#cmakedefine HAVE_ERRNO_H
|
||||
#cmakedefine HAVE_EXECINFO_H
|
||||
#cmakedefine HAVE_INTTYPES_H
|
||||
#cmakedefine HAVE_LINUX_FUTEX_H
|
||||
#cmakedefine HAVE_MEMORY_H
|
||||
#cmakedefine HAVE_NETDB_H
|
||||
#cmakedefine HAVE_NETINET_IN_H
|
||||
#cmakedefine HAVE_NETINET_TCP_H
|
||||
#cmakedefine HAVE_PTHREAD_H
|
||||
#cmakedefine HAVE_SIGNAL_H
|
||||
#cmakedefine HAVE_STDINT_H
|
||||
#cmakedefine HAVE_STDLIB_H
|
||||
#cmakedefine HAVE_STRINGS_H
|
||||
#cmakedefine HAVE_STRING_H
|
||||
#cmakedefine HAVE_SYS_MMAN_H
|
||||
#cmakedefine HAVE_SYS_PARAM_H
|
||||
#cmakedefine HAVE_SYS_RESOURCE_H
|
||||
#cmakedefine HAVE_SYS_SELECT_H
|
||||
#cmakedefine HAVE_SYS_SOCKET_H
|
||||
#cmakedefine HAVE_SYS_STAT_H
|
||||
#cmakedefine HAVE_SYS_SYSCALL_H
|
||||
#cmakedefine HAVE_SYS_SYSCTL_H
|
||||
#cmakedefine HAVE_SYS_TIMEB_H
|
||||
#cmakedefine HAVE_SYS_TIME_H
|
||||
#cmakedefine HAVE_SYS_TYPES_H
|
||||
#cmakedefine HAVE_SYS_WAIT_H
|
||||
#cmakedefine HAVE_TIME_H
|
||||
#cmakedefine HAVE_UCONTEXT_H
|
||||
#cmakedefine HAVE_UNISTD_H
|
||||
|
||||
/* libraries */
|
||||
#cmakedefine HAVE_LIBEDIT
|
||||
#cmakedefine HAVE_LIBEVENT
|
||||
#cmakedefine HAVE_LIBM
|
||||
#cmakedefine HAVE_LIBRT
|
||||
|
||||
/* structs */
|
||||
#cmakedefine HAVE_MECAB_DICTIONARY_INFO_T
|
||||
|
||||
/* functions */
|
||||
#cmakedefine HAVE__STRNICMP
|
||||
#cmakedefine HAVE__STRTOUI64
|
||||
#cmakedefine HAVE_BACKTRACE
|
||||
#cmakedefine HAVE_CLOCK
|
||||
#cmakedefine HAVE_CLOCK_GETTIME
|
||||
#cmakedefine HAVE_CLOSE
|
||||
#cmakedefine HAVE_FPCLASSIFY
|
||||
#cmakedefine HAVE_GMTIME_R
|
||||
#cmakedefine HAVE_LOCALTIME_R
|
||||
#cmakedefine HAVE_MKOSTEMP
|
||||
#cmakedefine HAVE_OPEN
|
||||
#cmakedefine HAVE_READ
|
||||
#cmakedefine HAVE_STRNCASECMP
|
||||
#cmakedefine HAVE_STRTOULL
|
||||
#cmakedefine HAVE_WRITE
|
||||
#cmakedefine HAVE_PTHREAD_MUTEXATTR_SETPSHARED
|
||||
#cmakedefine HAVE_PTHREAD_CONDATTR_SETPSHARED
|
||||
6
storage/mroonga/vendor/groonga/config.sh.in
vendored
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
export CUTTER="@CUTTER@"
|
||||
export RUBY="@RUBY@"
|
||||
export GROONGA="@GROONGA@"
|
||||
export GROONGA_HTTPD="@GROONGA_HTTPD@"
|
||||
export GROONGA_SUGGEST_CREATE_DATASET="@GROONGA_SUGGEST_CREATE_DATASET@"
|
||||
export GROONGA_BENCHMARK="@GROONGA_BENCHMARK@"
|
||||
1514
storage/mroonga/vendor/groonga/configure.ac
vendored
Normal file
20
storage/mroonga/vendor/groonga/data/CMakeLists.txt
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
# Copyright(C) 2012 Brazil
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License version 2.1 as published by the Free Software Foundation.
|
||||
#
|
||||
# This library 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
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
add_subdirectory(html)
|
||||
|
||||
if(NOT MRN_GROONGA_BUNDLED)
|
||||
install(FILES groonga.conf DESTINATION "${GRN_CONFIG_DIR}/")
|
||||
endif()
|
||||
20
storage/mroonga/vendor/groonga/data/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
SUBDIRS = \
|
||||
images \
|
||||
html \
|
||||
munin \
|
||||
init.d \
|
||||
logrotate.d \
|
||||
systemd \
|
||||
scripts
|
||||
|
||||
pkgsysconfdir = $(sysconfdir)/$(PACKAGE)
|
||||
dist_pkgsysconf_DATA = \
|
||||
groonga.conf \
|
||||
synonyms.tsv
|
||||
|
||||
httpdconfdir = $(pkgsysconfdir)/httpd
|
||||
dist_httpdconf_DATA = \
|
||||
groonga-httpd.conf
|
||||
|
||||
EXTRA_DIST = \
|
||||
CMakeLists.txt
|
||||
BIN
storage/mroonga/vendor/groonga/data/account/twitter.gpg.hayashi
vendored
Normal file
BIN
storage/mroonga/vendor/groonga/data/account/twitter.gpg.kou
vendored
Normal file
BIN
storage/mroonga/vendor/groonga/data/account/twitter.gpg.yuki
vendored
Normal file
57
storage/mroonga/vendor/groonga/data/groonga-httpd.conf.in
vendored
Normal file
|
|
@ -0,0 +1,57 @@
|
|||
worker_processes 1;
|
||||
|
||||
# Match this to the file owner of groonga database files if groonga-httpd is
|
||||
# run as root.
|
||||
user groonga groonga;
|
||||
|
||||
events {
|
||||
worker_connections 1024;
|
||||
}
|
||||
|
||||
http {
|
||||
include mime.types;
|
||||
default_type application/octet-stream;
|
||||
sendfile on;
|
||||
keepalive_timeout 65;
|
||||
|
||||
# The default groonga database path.
|
||||
groonga_database @GROONGA_HTTPD_DEFAULT_DATABASE_PATH@;
|
||||
|
||||
# Create a groonga database automatically if the groonga database doesn't
|
||||
# exist.
|
||||
#
|
||||
# Note that this option is danger when worker_processes is greater than 1.
|
||||
# Because one or more worker processes may create the same groonga database
|
||||
# at the same time. If you can create a groonga database before running
|
||||
# groonga-httpd, you should do it.
|
||||
groonga_database_auto_create on;
|
||||
|
||||
# The default groonga cache limit. The cache limit can be set
|
||||
# for each worker. It can't be set for each groonga database.
|
||||
# groonga_cache_limit 100;
|
||||
|
||||
server {
|
||||
listen 10041;
|
||||
server_name localhost;
|
||||
|
||||
location /d/ {
|
||||
groonga on;
|
||||
# You can disable log for groonga.
|
||||
# groonga_log_path off;
|
||||
# You can disable query log for groonga.
|
||||
# groonga_query_log_path off;
|
||||
# You can custom database path.
|
||||
# groonga_database /path/to/groonga/db;
|
||||
}
|
||||
|
||||
location / {
|
||||
root @GROONGA_HTTPD_DOCUMENT_ROOT@;
|
||||
index index.html;
|
||||
}
|
||||
|
||||
error_page 500 502 503 504 /50x.html;
|
||||
location = /50x.html {
|
||||
root html;
|
||||
}
|
||||
}
|
||||
}
|
||||
11
storage/mroonga/vendor/groonga/data/groonga.conf
vendored
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
# encoding = utf-8
|
||||
# log-level = 1
|
||||
# address = 0.0.0.0
|
||||
# port = 10041
|
||||
# server-id = groonga.example.com
|
||||
# max-threads = 2
|
||||
# admin-html-path = /usr/share/groonga/admin_html
|
||||
# protocol = http
|
||||
# log-path = /var/log/groonga/groonga.log
|
||||
# query-log-path = /var/log/groonga/query.log
|
||||
# cache-limit = 100
|
||||
18
storage/mroonga/vendor/groonga/data/html/CMakeLists.txt
vendored
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
# Copyright(C) 2012 Brazil
|
||||
#
|
||||
# This library is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU Lesser General Public
|
||||
# License version 2.1 as published by the Free Software Foundation.
|
||||
#
|
||||
# This library 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
|
||||
# Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public
|
||||
# License along with this library; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
if(NOT MRN_GROONGA_BUNDLED)
|
||||
install(DIRECTORY admin DESTINATION "${GRN_DATA_DIR}/html")
|
||||
endif()
|
||||
9
storage/mroonga/vendor/groonga/data/html/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
htmldir = $(pkgdatadir)/html
|
||||
|
||||
include files.am
|
||||
|
||||
EXTRA_DIST = \
|
||||
CMakeLists.txt
|
||||
|
||||
update-files:
|
||||
cd $(srcdir); ./update-files.sh > files.am
|
||||
120
storage/mroonga/vendor/groonga/data/html/admin/css/groonga-admin.css
vendored
Normal file
|
|
@ -0,0 +1,120 @@
|
|||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
background: white;
|
||||
color: #333;
|
||||
font-size:11px;
|
||||
}
|
||||
|
||||
form {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
img {
|
||||
border: none;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #2e6e9e;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
input {
|
||||
border: 1px solid;
|
||||
}
|
||||
|
||||
input[type="text"] {
|
||||
width: 12em;
|
||||
}
|
||||
|
||||
#header {
|
||||
height: 80px;
|
||||
background: url(../images/groonga.png) no-repeat left center;
|
||||
}
|
||||
|
||||
#locale-list {
|
||||
float: right;
|
||||
width: 4em;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
#locale-list li {
|
||||
float: left;
|
||||
width: 2em;
|
||||
}
|
||||
|
||||
#side-menu {
|
||||
width: 12em;
|
||||
}
|
||||
|
||||
#side-menu ul {
|
||||
padding-left: 1.5em;
|
||||
}
|
||||
|
||||
#left-column {
|
||||
height: 100%;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
#right-column {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
#database-tabs {
|
||||
}
|
||||
|
||||
#table-tabs {
|
||||
display: none;
|
||||
}
|
||||
|
||||
table.records {
|
||||
border: #333 1px solid;
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
margin: 0.2em;
|
||||
}
|
||||
|
||||
table.records th {
|
||||
color: white;
|
||||
background-color: #5c9ccc;
|
||||
border: #333 solid;
|
||||
border-width: 0 0 1px 1px;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
padding: 0.3em;
|
||||
}
|
||||
|
||||
table.records td {
|
||||
background-color: white;
|
||||
border: #333 solid;
|
||||
border-width: 0 0 1px 1px;
|
||||
padding: 0.3em;
|
||||
}
|
||||
|
||||
span.pager {
|
||||
display: inline-block;
|
||||
border: #333 1px solid;
|
||||
padding: 0.1em;
|
||||
margin: 0.1em;
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
span.pager-current {
|
||||
display: inline-block;
|
||||
border: #333 1px solid;
|
||||
padding: 0.1em;
|
||||
margin: 0.1em;
|
||||
background-color: #333;
|
||||
}
|
||||
|
||||
span.pager-current a {
|
||||
color: white;
|
||||
font-weight: bold;
|
||||
}
|
||||
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-bg_flat_0_aaaaaa_40x100.png
vendored
Normal file
|
After Width: | Height: | Size: 180 B |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-bg_flat_55_fbec88_40x100.png
vendored
Normal file
|
After Width: | Height: | Size: 182 B |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-bg_glass_75_d0e5f5_1x400.png
vendored
Normal file
|
After Width: | Height: | Size: 124 B |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-bg_glass_85_dfeffc_1x400.png
vendored
Normal file
|
After Width: | Height: | Size: 123 B |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-bg_glass_95_fef1ec_1x400.png
vendored
Normal file
|
After Width: | Height: | Size: 119 B |
|
After Width: | Height: | Size: 3.9 KiB |
|
After Width: | Height: | Size: 104 B |
|
After Width: | Height: | Size: 88 B |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-icons_217bc0_256x240.png
vendored
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-icons_2e83ff_256x240.png
vendored
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-icons_469bdd_256x240.png
vendored
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-icons_6da8d5_256x240.png
vendored
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-icons_cd0a0a_256x240.png
vendored
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-icons_d8e7f3_256x240.png
vendored
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/images/ui-icons_f9bd01_256x240.png
vendored
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
565
storage/mroonga/vendor/groonga/data/html/admin/css/redmond/jquery-ui-1.8.18.custom.css
vendored
Normal file
|
|
@ -0,0 +1,565 @@
|
|||
/*
|
||||
* jQuery UI CSS Framework 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Theming/API
|
||||
*/
|
||||
|
||||
/* Layout helpers
|
||||
----------------------------------*/
|
||||
.ui-helper-hidden { display: none; }
|
||||
.ui-helper-hidden-accessible { position: absolute !important; clip: rect(1px 1px 1px 1px); clip: rect(1px,1px,1px,1px); }
|
||||
.ui-helper-reset { margin: 0; padding: 0; border: 0; outline: 0; line-height: 1.3; text-decoration: none; font-size: 100%; list-style: none; }
|
||||
.ui-helper-clearfix:before, .ui-helper-clearfix:after { content: ""; display: table; }
|
||||
.ui-helper-clearfix:after { clear: both; }
|
||||
.ui-helper-clearfix { zoom: 1; }
|
||||
.ui-helper-zfix { width: 100%; height: 100%; top: 0; left: 0; position: absolute; opacity: 0; filter:Alpha(Opacity=0); }
|
||||
|
||||
|
||||
/* Interaction Cues
|
||||
----------------------------------*/
|
||||
.ui-state-disabled { cursor: default !important; }
|
||||
|
||||
|
||||
/* Icons
|
||||
----------------------------------*/
|
||||
|
||||
/* states and images */
|
||||
.ui-icon { display: block; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat; }
|
||||
|
||||
|
||||
/* Misc visuals
|
||||
----------------------------------*/
|
||||
|
||||
/* Overlays */
|
||||
.ui-widget-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
|
||||
|
||||
|
||||
/*
|
||||
* jQuery UI CSS Framework 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Theming/API
|
||||
*
|
||||
* To view and modify this theme, visit http://jqueryui.com/themeroller/?ffDefault=Lucida%20Grande,%20Lucida%20Sans,%20Arial,%20sans-serif&fwDefault=bold&fsDefault=1.1em&cornerRadius=5px&bgColorHeader=5c9ccc&bgTextureHeader=12_gloss_wave.png&bgImgOpacityHeader=55&borderColorHeader=4297d7&fcHeader=ffffff&iconColorHeader=d8e7f3&bgColorContent=fcfdfd&bgTextureContent=06_inset_hard.png&bgImgOpacityContent=100&borderColorContent=a6c9e2&fcContent=222222&iconColorContent=469bdd&bgColorDefault=dfeffc&bgTextureDefault=02_glass.png&bgImgOpacityDefault=85&borderColorDefault=c5dbec&fcDefault=2e6e9e&iconColorDefault=6da8d5&bgColorHover=d0e5f5&bgTextureHover=02_glass.png&bgImgOpacityHover=75&borderColorHover=79b7e7&fcHover=1d5987&iconColorHover=217bc0&bgColorActive=f5f8f9&bgTextureActive=06_inset_hard.png&bgImgOpacityActive=100&borderColorActive=79b7e7&fcActive=e17009&iconColorActive=f9bd01&bgColorHighlight=fbec88&bgTextureHighlight=01_flat.png&bgImgOpacityHighlight=55&borderColorHighlight=fad42e&fcHighlight=363636&iconColorHighlight=2e83ff&bgColorError=fef1ec&bgTextureError=02_glass.png&bgImgOpacityError=95&borderColorError=cd0a0a&fcError=cd0a0a&iconColorError=cd0a0a&bgColorOverlay=aaaaaa&bgTextureOverlay=01_flat.png&bgImgOpacityOverlay=0&opacityOverlay=30&bgColorShadow=aaaaaa&bgTextureShadow=01_flat.png&bgImgOpacityShadow=0&opacityShadow=30&thicknessShadow=8px&offsetTopShadow=-8px&offsetLeftShadow=-8px&cornerRadiusShadow=8px
|
||||
*/
|
||||
|
||||
|
||||
/* Component containers
|
||||
----------------------------------*/
|
||||
.ui-widget { font-family: Lucida Grande, Lucida Sans, Arial, sans-serif; font-size: 1.1em; }
|
||||
.ui-widget .ui-widget { font-size: 1em; }
|
||||
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button { font-family: Lucida Grande, Lucida Sans, Arial, sans-serif; font-size: 1em; }
|
||||
.ui-widget-content { border: 1px solid #a6c9e2; background: #fcfdfd url(images/ui-bg_inset-hard_100_fcfdfd_1x100.png) 50% bottom repeat-x; color: #222222; }
|
||||
.ui-widget-content a { color: #222222; }
|
||||
.ui-widget-header { border: 1px solid #4297d7; background: #5c9ccc url(images/ui-bg_gloss-wave_55_5c9ccc_500x100.png) 50% 50% repeat-x; color: #ffffff; font-weight: bold; }
|
||||
.ui-widget-header a { color: #ffffff; }
|
||||
|
||||
/* Interaction states
|
||||
----------------------------------*/
|
||||
.ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default { border: 1px solid #c5dbec; background: #dfeffc url(images/ui-bg_glass_85_dfeffc_1x400.png) 50% 50% repeat-x; font-weight: bold; color: #2e6e9e; }
|
||||
.ui-state-default a, .ui-state-default a:link, .ui-state-default a:visited { color: #2e6e9e; text-decoration: none; }
|
||||
.ui-state-hover, .ui-widget-content .ui-state-hover, .ui-widget-header .ui-state-hover, .ui-state-focus, .ui-widget-content .ui-state-focus, .ui-widget-header .ui-state-focus { border: 1px solid #79b7e7; background: #d0e5f5 url(images/ui-bg_glass_75_d0e5f5_1x400.png) 50% 50% repeat-x; font-weight: bold; color: #1d5987; }
|
||||
.ui-state-hover a, .ui-state-hover a:hover { color: #1d5987; text-decoration: none; }
|
||||
.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active { border: 1px solid #79b7e7; background: #f5f8f9 url(images/ui-bg_inset-hard_100_f5f8f9_1x100.png) 50% 50% repeat-x; font-weight: bold; color: #e17009; }
|
||||
.ui-state-active a, .ui-state-active a:link, .ui-state-active a:visited { color: #e17009; text-decoration: none; }
|
||||
.ui-widget :active { outline: none; }
|
||||
|
||||
/* Interaction Cues
|
||||
----------------------------------*/
|
||||
.ui-state-highlight, .ui-widget-content .ui-state-highlight, .ui-widget-header .ui-state-highlight {border: 1px solid #fad42e; background: #fbec88 url(images/ui-bg_flat_55_fbec88_40x100.png) 50% 50% repeat-x; color: #363636; }
|
||||
.ui-state-highlight a, .ui-widget-content .ui-state-highlight a,.ui-widget-header .ui-state-highlight a { color: #363636; }
|
||||
.ui-state-error, .ui-widget-content .ui-state-error, .ui-widget-header .ui-state-error {border: 1px solid #cd0a0a; background: #fef1ec url(images/ui-bg_glass_95_fef1ec_1x400.png) 50% 50% repeat-x; color: #cd0a0a; }
|
||||
.ui-state-error a, .ui-widget-content .ui-state-error a, .ui-widget-header .ui-state-error a { color: #cd0a0a; }
|
||||
.ui-state-error-text, .ui-widget-content .ui-state-error-text, .ui-widget-header .ui-state-error-text { color: #cd0a0a; }
|
||||
.ui-priority-primary, .ui-widget-content .ui-priority-primary, .ui-widget-header .ui-priority-primary { font-weight: bold; }
|
||||
.ui-priority-secondary, .ui-widget-content .ui-priority-secondary, .ui-widget-header .ui-priority-secondary { opacity: .7; filter:Alpha(Opacity=70); font-weight: normal; }
|
||||
.ui-state-disabled, .ui-widget-content .ui-state-disabled, .ui-widget-header .ui-state-disabled { opacity: .35; filter:Alpha(Opacity=35); background-image: none; }
|
||||
|
||||
/* Icons
|
||||
----------------------------------*/
|
||||
|
||||
/* states and images */
|
||||
.ui-icon { width: 16px; height: 16px; background-image: url(images/ui-icons_469bdd_256x240.png); }
|
||||
.ui-widget-content .ui-icon {background-image: url(images/ui-icons_469bdd_256x240.png); }
|
||||
.ui-widget-header .ui-icon {background-image: url(images/ui-icons_d8e7f3_256x240.png); }
|
||||
.ui-state-default .ui-icon { background-image: url(images/ui-icons_6da8d5_256x240.png); }
|
||||
.ui-state-hover .ui-icon, .ui-state-focus .ui-icon {background-image: url(images/ui-icons_217bc0_256x240.png); }
|
||||
.ui-state-active .ui-icon {background-image: url(images/ui-icons_f9bd01_256x240.png); }
|
||||
.ui-state-highlight .ui-icon {background-image: url(images/ui-icons_2e83ff_256x240.png); }
|
||||
.ui-state-error .ui-icon, .ui-state-error-text .ui-icon {background-image: url(images/ui-icons_cd0a0a_256x240.png); }
|
||||
|
||||
/* positioning */
|
||||
.ui-icon-carat-1-n { background-position: 0 0; }
|
||||
.ui-icon-carat-1-ne { background-position: -16px 0; }
|
||||
.ui-icon-carat-1-e { background-position: -32px 0; }
|
||||
.ui-icon-carat-1-se { background-position: -48px 0; }
|
||||
.ui-icon-carat-1-s { background-position: -64px 0; }
|
||||
.ui-icon-carat-1-sw { background-position: -80px 0; }
|
||||
.ui-icon-carat-1-w { background-position: -96px 0; }
|
||||
.ui-icon-carat-1-nw { background-position: -112px 0; }
|
||||
.ui-icon-carat-2-n-s { background-position: -128px 0; }
|
||||
.ui-icon-carat-2-e-w { background-position: -144px 0; }
|
||||
.ui-icon-triangle-1-n { background-position: 0 -16px; }
|
||||
.ui-icon-triangle-1-ne { background-position: -16px -16px; }
|
||||
.ui-icon-triangle-1-e { background-position: -32px -16px; }
|
||||
.ui-icon-triangle-1-se { background-position: -48px -16px; }
|
||||
.ui-icon-triangle-1-s { background-position: -64px -16px; }
|
||||
.ui-icon-triangle-1-sw { background-position: -80px -16px; }
|
||||
.ui-icon-triangle-1-w { background-position: -96px -16px; }
|
||||
.ui-icon-triangle-1-nw { background-position: -112px -16px; }
|
||||
.ui-icon-triangle-2-n-s { background-position: -128px -16px; }
|
||||
.ui-icon-triangle-2-e-w { background-position: -144px -16px; }
|
||||
.ui-icon-arrow-1-n { background-position: 0 -32px; }
|
||||
.ui-icon-arrow-1-ne { background-position: -16px -32px; }
|
||||
.ui-icon-arrow-1-e { background-position: -32px -32px; }
|
||||
.ui-icon-arrow-1-se { background-position: -48px -32px; }
|
||||
.ui-icon-arrow-1-s { background-position: -64px -32px; }
|
||||
.ui-icon-arrow-1-sw { background-position: -80px -32px; }
|
||||
.ui-icon-arrow-1-w { background-position: -96px -32px; }
|
||||
.ui-icon-arrow-1-nw { background-position: -112px -32px; }
|
||||
.ui-icon-arrow-2-n-s { background-position: -128px -32px; }
|
||||
.ui-icon-arrow-2-ne-sw { background-position: -144px -32px; }
|
||||
.ui-icon-arrow-2-e-w { background-position: -160px -32px; }
|
||||
.ui-icon-arrow-2-se-nw { background-position: -176px -32px; }
|
||||
.ui-icon-arrowstop-1-n { background-position: -192px -32px; }
|
||||
.ui-icon-arrowstop-1-e { background-position: -208px -32px; }
|
||||
.ui-icon-arrowstop-1-s { background-position: -224px -32px; }
|
||||
.ui-icon-arrowstop-1-w { background-position: -240px -32px; }
|
||||
.ui-icon-arrowthick-1-n { background-position: 0 -48px; }
|
||||
.ui-icon-arrowthick-1-ne { background-position: -16px -48px; }
|
||||
.ui-icon-arrowthick-1-e { background-position: -32px -48px; }
|
||||
.ui-icon-arrowthick-1-se { background-position: -48px -48px; }
|
||||
.ui-icon-arrowthick-1-s { background-position: -64px -48px; }
|
||||
.ui-icon-arrowthick-1-sw { background-position: -80px -48px; }
|
||||
.ui-icon-arrowthick-1-w { background-position: -96px -48px; }
|
||||
.ui-icon-arrowthick-1-nw { background-position: -112px -48px; }
|
||||
.ui-icon-arrowthick-2-n-s { background-position: -128px -48px; }
|
||||
.ui-icon-arrowthick-2-ne-sw { background-position: -144px -48px; }
|
||||
.ui-icon-arrowthick-2-e-w { background-position: -160px -48px; }
|
||||
.ui-icon-arrowthick-2-se-nw { background-position: -176px -48px; }
|
||||
.ui-icon-arrowthickstop-1-n { background-position: -192px -48px; }
|
||||
.ui-icon-arrowthickstop-1-e { background-position: -208px -48px; }
|
||||
.ui-icon-arrowthickstop-1-s { background-position: -224px -48px; }
|
||||
.ui-icon-arrowthickstop-1-w { background-position: -240px -48px; }
|
||||
.ui-icon-arrowreturnthick-1-w { background-position: 0 -64px; }
|
||||
.ui-icon-arrowreturnthick-1-n { background-position: -16px -64px; }
|
||||
.ui-icon-arrowreturnthick-1-e { background-position: -32px -64px; }
|
||||
.ui-icon-arrowreturnthick-1-s { background-position: -48px -64px; }
|
||||
.ui-icon-arrowreturn-1-w { background-position: -64px -64px; }
|
||||
.ui-icon-arrowreturn-1-n { background-position: -80px -64px; }
|
||||
.ui-icon-arrowreturn-1-e { background-position: -96px -64px; }
|
||||
.ui-icon-arrowreturn-1-s { background-position: -112px -64px; }
|
||||
.ui-icon-arrowrefresh-1-w { background-position: -128px -64px; }
|
||||
.ui-icon-arrowrefresh-1-n { background-position: -144px -64px; }
|
||||
.ui-icon-arrowrefresh-1-e { background-position: -160px -64px; }
|
||||
.ui-icon-arrowrefresh-1-s { background-position: -176px -64px; }
|
||||
.ui-icon-arrow-4 { background-position: 0 -80px; }
|
||||
.ui-icon-arrow-4-diag { background-position: -16px -80px; }
|
||||
.ui-icon-extlink { background-position: -32px -80px; }
|
||||
.ui-icon-newwin { background-position: -48px -80px; }
|
||||
.ui-icon-refresh { background-position: -64px -80px; }
|
||||
.ui-icon-shuffle { background-position: -80px -80px; }
|
||||
.ui-icon-transfer-e-w { background-position: -96px -80px; }
|
||||
.ui-icon-transferthick-e-w { background-position: -112px -80px; }
|
||||
.ui-icon-folder-collapsed { background-position: 0 -96px; }
|
||||
.ui-icon-folder-open { background-position: -16px -96px; }
|
||||
.ui-icon-document { background-position: -32px -96px; }
|
||||
.ui-icon-document-b { background-position: -48px -96px; }
|
||||
.ui-icon-note { background-position: -64px -96px; }
|
||||
.ui-icon-mail-closed { background-position: -80px -96px; }
|
||||
.ui-icon-mail-open { background-position: -96px -96px; }
|
||||
.ui-icon-suitcase { background-position: -112px -96px; }
|
||||
.ui-icon-comment { background-position: -128px -96px; }
|
||||
.ui-icon-person { background-position: -144px -96px; }
|
||||
.ui-icon-print { background-position: -160px -96px; }
|
||||
.ui-icon-trash { background-position: -176px -96px; }
|
||||
.ui-icon-locked { background-position: -192px -96px; }
|
||||
.ui-icon-unlocked { background-position: -208px -96px; }
|
||||
.ui-icon-bookmark { background-position: -224px -96px; }
|
||||
.ui-icon-tag { background-position: -240px -96px; }
|
||||
.ui-icon-home { background-position: 0 -112px; }
|
||||
.ui-icon-flag { background-position: -16px -112px; }
|
||||
.ui-icon-calendar { background-position: -32px -112px; }
|
||||
.ui-icon-cart { background-position: -48px -112px; }
|
||||
.ui-icon-pencil { background-position: -64px -112px; }
|
||||
.ui-icon-clock { background-position: -80px -112px; }
|
||||
.ui-icon-disk { background-position: -96px -112px; }
|
||||
.ui-icon-calculator { background-position: -112px -112px; }
|
||||
.ui-icon-zoomin { background-position: -128px -112px; }
|
||||
.ui-icon-zoomout { background-position: -144px -112px; }
|
||||
.ui-icon-search { background-position: -160px -112px; }
|
||||
.ui-icon-wrench { background-position: -176px -112px; }
|
||||
.ui-icon-gear { background-position: -192px -112px; }
|
||||
.ui-icon-heart { background-position: -208px -112px; }
|
||||
.ui-icon-star { background-position: -224px -112px; }
|
||||
.ui-icon-link { background-position: -240px -112px; }
|
||||
.ui-icon-cancel { background-position: 0 -128px; }
|
||||
.ui-icon-plus { background-position: -16px -128px; }
|
||||
.ui-icon-plusthick { background-position: -32px -128px; }
|
||||
.ui-icon-minus { background-position: -48px -128px; }
|
||||
.ui-icon-minusthick { background-position: -64px -128px; }
|
||||
.ui-icon-close { background-position: -80px -128px; }
|
||||
.ui-icon-closethick { background-position: -96px -128px; }
|
||||
.ui-icon-key { background-position: -112px -128px; }
|
||||
.ui-icon-lightbulb { background-position: -128px -128px; }
|
||||
.ui-icon-scissors { background-position: -144px -128px; }
|
||||
.ui-icon-clipboard { background-position: -160px -128px; }
|
||||
.ui-icon-copy { background-position: -176px -128px; }
|
||||
.ui-icon-contact { background-position: -192px -128px; }
|
||||
.ui-icon-image { background-position: -208px -128px; }
|
||||
.ui-icon-video { background-position: -224px -128px; }
|
||||
.ui-icon-script { background-position: -240px -128px; }
|
||||
.ui-icon-alert { background-position: 0 -144px; }
|
||||
.ui-icon-info { background-position: -16px -144px; }
|
||||
.ui-icon-notice { background-position: -32px -144px; }
|
||||
.ui-icon-help { background-position: -48px -144px; }
|
||||
.ui-icon-check { background-position: -64px -144px; }
|
||||
.ui-icon-bullet { background-position: -80px -144px; }
|
||||
.ui-icon-radio-off { background-position: -96px -144px; }
|
||||
.ui-icon-radio-on { background-position: -112px -144px; }
|
||||
.ui-icon-pin-w { background-position: -128px -144px; }
|
||||
.ui-icon-pin-s { background-position: -144px -144px; }
|
||||
.ui-icon-play { background-position: 0 -160px; }
|
||||
.ui-icon-pause { background-position: -16px -160px; }
|
||||
.ui-icon-seek-next { background-position: -32px -160px; }
|
||||
.ui-icon-seek-prev { background-position: -48px -160px; }
|
||||
.ui-icon-seek-end { background-position: -64px -160px; }
|
||||
.ui-icon-seek-start { background-position: -80px -160px; }
|
||||
/* ui-icon-seek-first is deprecated, use ui-icon-seek-start instead */
|
||||
.ui-icon-seek-first { background-position: -80px -160px; }
|
||||
.ui-icon-stop { background-position: -96px -160px; }
|
||||
.ui-icon-eject { background-position: -112px -160px; }
|
||||
.ui-icon-volume-off { background-position: -128px -160px; }
|
||||
.ui-icon-volume-on { background-position: -144px -160px; }
|
||||
.ui-icon-power { background-position: 0 -176px; }
|
||||
.ui-icon-signal-diag { background-position: -16px -176px; }
|
||||
.ui-icon-signal { background-position: -32px -176px; }
|
||||
.ui-icon-battery-0 { background-position: -48px -176px; }
|
||||
.ui-icon-battery-1 { background-position: -64px -176px; }
|
||||
.ui-icon-battery-2 { background-position: -80px -176px; }
|
||||
.ui-icon-battery-3 { background-position: -96px -176px; }
|
||||
.ui-icon-circle-plus { background-position: 0 -192px; }
|
||||
.ui-icon-circle-minus { background-position: -16px -192px; }
|
||||
.ui-icon-circle-close { background-position: -32px -192px; }
|
||||
.ui-icon-circle-triangle-e { background-position: -48px -192px; }
|
||||
.ui-icon-circle-triangle-s { background-position: -64px -192px; }
|
||||
.ui-icon-circle-triangle-w { background-position: -80px -192px; }
|
||||
.ui-icon-circle-triangle-n { background-position: -96px -192px; }
|
||||
.ui-icon-circle-arrow-e { background-position: -112px -192px; }
|
||||
.ui-icon-circle-arrow-s { background-position: -128px -192px; }
|
||||
.ui-icon-circle-arrow-w { background-position: -144px -192px; }
|
||||
.ui-icon-circle-arrow-n { background-position: -160px -192px; }
|
||||
.ui-icon-circle-zoomin { background-position: -176px -192px; }
|
||||
.ui-icon-circle-zoomout { background-position: -192px -192px; }
|
||||
.ui-icon-circle-check { background-position: -208px -192px; }
|
||||
.ui-icon-circlesmall-plus { background-position: 0 -208px; }
|
||||
.ui-icon-circlesmall-minus { background-position: -16px -208px; }
|
||||
.ui-icon-circlesmall-close { background-position: -32px -208px; }
|
||||
.ui-icon-squaresmall-plus { background-position: -48px -208px; }
|
||||
.ui-icon-squaresmall-minus { background-position: -64px -208px; }
|
||||
.ui-icon-squaresmall-close { background-position: -80px -208px; }
|
||||
.ui-icon-grip-dotted-vertical { background-position: 0 -224px; }
|
||||
.ui-icon-grip-dotted-horizontal { background-position: -16px -224px; }
|
||||
.ui-icon-grip-solid-vertical { background-position: -32px -224px; }
|
||||
.ui-icon-grip-solid-horizontal { background-position: -48px -224px; }
|
||||
.ui-icon-gripsmall-diagonal-se { background-position: -64px -224px; }
|
||||
.ui-icon-grip-diagonal-se { background-position: -80px -224px; }
|
||||
|
||||
|
||||
/* Misc visuals
|
||||
----------------------------------*/
|
||||
|
||||
/* Corner radius */
|
||||
.ui-corner-all, .ui-corner-top, .ui-corner-left, .ui-corner-tl { -moz-border-radius-topleft: 5px; -webkit-border-top-left-radius: 5px; -khtml-border-top-left-radius: 5px; border-top-left-radius: 5px; }
|
||||
.ui-corner-all, .ui-corner-top, .ui-corner-right, .ui-corner-tr { -moz-border-radius-topright: 5px; -webkit-border-top-right-radius: 5px; -khtml-border-top-right-radius: 5px; border-top-right-radius: 5px; }
|
||||
.ui-corner-all, .ui-corner-bottom, .ui-corner-left, .ui-corner-bl { -moz-border-radius-bottomleft: 5px; -webkit-border-bottom-left-radius: 5px; -khtml-border-bottom-left-radius: 5px; border-bottom-left-radius: 5px; }
|
||||
.ui-corner-all, .ui-corner-bottom, .ui-corner-right, .ui-corner-br { -moz-border-radius-bottomright: 5px; -webkit-border-bottom-right-radius: 5px; -khtml-border-bottom-right-radius: 5px; border-bottom-right-radius: 5px; }
|
||||
|
||||
/* Overlays */
|
||||
.ui-widget-overlay { background: #aaaaaa url(images/ui-bg_flat_0_aaaaaa_40x100.png) 50% 50% repeat-x; opacity: .30;filter:Alpha(Opacity=30); }
|
||||
.ui-widget-shadow { margin: -8px 0 0 -8px; padding: 8px; background: #aaaaaa url(images/ui-bg_flat_0_aaaaaa_40x100.png) 50% 50% repeat-x; opacity: .30;filter:Alpha(Opacity=30); -moz-border-radius: 8px; -khtml-border-radius: 8px; -webkit-border-radius: 8px; border-radius: 8px; }/*
|
||||
* jQuery UI Resizable 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Resizable#theming
|
||||
*/
|
||||
.ui-resizable { position: relative;}
|
||||
.ui-resizable-handle { position: absolute;font-size: 0.1px;z-index: 99999; display: block; }
|
||||
.ui-resizable-disabled .ui-resizable-handle, .ui-resizable-autohide .ui-resizable-handle { display: none; }
|
||||
.ui-resizable-n { cursor: n-resize; height: 7px; width: 100%; top: -5px; left: 0; }
|
||||
.ui-resizable-s { cursor: s-resize; height: 7px; width: 100%; bottom: -5px; left: 0; }
|
||||
.ui-resizable-e { cursor: e-resize; width: 7px; right: -5px; top: 0; height: 100%; }
|
||||
.ui-resizable-w { cursor: w-resize; width: 7px; left: -5px; top: 0; height: 100%; }
|
||||
.ui-resizable-se { cursor: se-resize; width: 12px; height: 12px; right: 1px; bottom: 1px; }
|
||||
.ui-resizable-sw { cursor: sw-resize; width: 9px; height: 9px; left: -5px; bottom: -5px; }
|
||||
.ui-resizable-nw { cursor: nw-resize; width: 9px; height: 9px; left: -5px; top: -5px; }
|
||||
.ui-resizable-ne { cursor: ne-resize; width: 9px; height: 9px; right: -5px; top: -5px;}/*
|
||||
* jQuery UI Selectable 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Selectable#theming
|
||||
*/
|
||||
.ui-selectable-helper { position: absolute; z-index: 100; border:1px dotted black; }
|
||||
/*
|
||||
* jQuery UI Accordion 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Accordion#theming
|
||||
*/
|
||||
/* IE/Win - Fix animation bug - #4615 */
|
||||
.ui-accordion { width: 100%; }
|
||||
.ui-accordion .ui-accordion-header { cursor: pointer; position: relative; margin-top: 1px; zoom: 1; }
|
||||
.ui-accordion .ui-accordion-li-fix { display: inline; }
|
||||
.ui-accordion .ui-accordion-header-active { border-bottom: 0 !important; }
|
||||
.ui-accordion .ui-accordion-header a { display: block; font-size: 1em; padding: .5em .5em .5em .7em; }
|
||||
.ui-accordion-icons .ui-accordion-header a { padding-left: 2.2em; }
|
||||
.ui-accordion .ui-accordion-header .ui-icon { position: absolute; left: .5em; top: 50%; margin-top: -8px; }
|
||||
.ui-accordion .ui-accordion-content { padding: 1em 2.2em; border-top: 0; margin-top: -2px; position: relative; top: 1px; margin-bottom: 2px; overflow: auto; display: none; zoom: 1; }
|
||||
.ui-accordion .ui-accordion-content-active { display: block; }
|
||||
/*
|
||||
* jQuery UI Autocomplete 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Autocomplete#theming
|
||||
*/
|
||||
.ui-autocomplete { position: absolute; cursor: default; }
|
||||
|
||||
/* workarounds */
|
||||
* html .ui-autocomplete { width:1px; } /* without this, the menu expands to 100% in IE6 */
|
||||
|
||||
/*
|
||||
* jQuery UI Menu 1.8.18
|
||||
*
|
||||
* Copyright 2010, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Menu#theming
|
||||
*/
|
||||
.ui-menu {
|
||||
list-style:none;
|
||||
padding: 2px;
|
||||
margin: 0;
|
||||
display:block;
|
||||
float: left;
|
||||
}
|
||||
.ui-menu .ui-menu {
|
||||
margin-top: -3px;
|
||||
}
|
||||
.ui-menu .ui-menu-item {
|
||||
margin:0;
|
||||
padding: 0;
|
||||
zoom: 1;
|
||||
float: left;
|
||||
clear: left;
|
||||
width: 100%;
|
||||
}
|
||||
.ui-menu .ui-menu-item a {
|
||||
text-decoration:none;
|
||||
display:block;
|
||||
padding:.2em .4em;
|
||||
line-height:1.5;
|
||||
zoom:1;
|
||||
}
|
||||
.ui-menu .ui-menu-item a.ui-state-hover,
|
||||
.ui-menu .ui-menu-item a.ui-state-active {
|
||||
font-weight: normal;
|
||||
margin: -1px;
|
||||
}
|
||||
/*
|
||||
* jQuery UI Button 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Button#theming
|
||||
*/
|
||||
.ui-button { display: inline-block; position: relative; padding: 0; margin-right: .1em; text-decoration: none !important; cursor: pointer; text-align: center; zoom: 1; overflow: hidden; *overflow: visible; } /* the overflow property removes extra width in IE */
|
||||
.ui-button-icon-only { width: 2.2em; } /* to make room for the icon, a width needs to be set here */
|
||||
button.ui-button-icon-only { width: 2.4em; } /* button elements seem to need a little more width */
|
||||
.ui-button-icons-only { width: 3.4em; }
|
||||
button.ui-button-icons-only { width: 3.7em; }
|
||||
|
||||
/*button text element */
|
||||
.ui-button .ui-button-text { display: block; line-height: 1.4; }
|
||||
.ui-button-text-only .ui-button-text { padding: .4em 1em; }
|
||||
.ui-button-icon-only .ui-button-text, .ui-button-icons-only .ui-button-text { padding: .4em; text-indent: -9999999px; }
|
||||
.ui-button-text-icon-primary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 1em .4em 2.1em; }
|
||||
.ui-button-text-icon-secondary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 2.1em .4em 1em; }
|
||||
.ui-button-text-icons .ui-button-text { padding-left: 2.1em; padding-right: 2.1em; }
|
||||
/* no icon support for input elements, provide padding by default */
|
||||
input.ui-button { padding: .4em 1em; }
|
||||
|
||||
/*button icon element(s) */
|
||||
.ui-button-icon-only .ui-icon, .ui-button-text-icon-primary .ui-icon, .ui-button-text-icon-secondary .ui-icon, .ui-button-text-icons .ui-icon, .ui-button-icons-only .ui-icon { position: absolute; top: 50%; margin-top: -8px; }
|
||||
.ui-button-icon-only .ui-icon { left: 50%; margin-left: -8px; }
|
||||
.ui-button-text-icon-primary .ui-button-icon-primary, .ui-button-text-icons .ui-button-icon-primary, .ui-button-icons-only .ui-button-icon-primary { left: .5em; }
|
||||
.ui-button-text-icon-secondary .ui-button-icon-secondary, .ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
|
||||
.ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
|
||||
|
||||
/*button sets*/
|
||||
.ui-buttonset { margin-right: 7px; }
|
||||
.ui-buttonset .ui-button { margin-left: 0; margin-right: -.3em; }
|
||||
|
||||
/* workarounds */
|
||||
button.ui-button::-moz-focus-inner { border: 0; padding: 0; } /* reset extra padding in Firefox */
|
||||
/*
|
||||
* jQuery UI Dialog 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Dialog#theming
|
||||
*/
|
||||
.ui-dialog { position: absolute; padding: .2em; width: 300px; overflow: hidden; }
|
||||
.ui-dialog .ui-dialog-titlebar { padding: .4em 1em; position: relative; }
|
||||
.ui-dialog .ui-dialog-title { float: left; margin: .1em 16px .1em 0; }
|
||||
.ui-dialog .ui-dialog-titlebar-close { position: absolute; right: .3em; top: 50%; width: 19px; margin: -10px 0 0 0; padding: 1px; height: 18px; }
|
||||
.ui-dialog .ui-dialog-titlebar-close span { display: block; margin: 1px; }
|
||||
.ui-dialog .ui-dialog-titlebar-close:hover, .ui-dialog .ui-dialog-titlebar-close:focus { padding: 0; }
|
||||
.ui-dialog .ui-dialog-content { position: relative; border: 0; padding: .5em 1em; background: none; overflow: auto; zoom: 1; }
|
||||
.ui-dialog .ui-dialog-buttonpane { text-align: left; border-width: 1px 0 0 0; background-image: none; margin: .5em 0 0 0; padding: .3em 1em .5em .4em; }
|
||||
.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset { float: right; }
|
||||
.ui-dialog .ui-dialog-buttonpane button { margin: .5em .4em .5em 0; cursor: pointer; }
|
||||
.ui-dialog .ui-resizable-se { width: 14px; height: 14px; right: 3px; bottom: 3px; }
|
||||
.ui-draggable .ui-dialog-titlebar { cursor: move; }
|
||||
/*
|
||||
* jQuery UI Slider 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Slider#theming
|
||||
*/
|
||||
.ui-slider { position: relative; text-align: left; }
|
||||
.ui-slider .ui-slider-handle { position: absolute; z-index: 2; width: 1.2em; height: 1.2em; cursor: default; }
|
||||
.ui-slider .ui-slider-range { position: absolute; z-index: 1; font-size: .7em; display: block; border: 0; background-position: 0 0; }
|
||||
|
||||
.ui-slider-horizontal { height: .8em; }
|
||||
.ui-slider-horizontal .ui-slider-handle { top: -.3em; margin-left: -.6em; }
|
||||
.ui-slider-horizontal .ui-slider-range { top: 0; height: 100%; }
|
||||
.ui-slider-horizontal .ui-slider-range-min { left: 0; }
|
||||
.ui-slider-horizontal .ui-slider-range-max { right: 0; }
|
||||
|
||||
.ui-slider-vertical { width: .8em; height: 100px; }
|
||||
.ui-slider-vertical .ui-slider-handle { left: -.3em; margin-left: 0; margin-bottom: -.6em; }
|
||||
.ui-slider-vertical .ui-slider-range { left: 0; width: 100%; }
|
||||
.ui-slider-vertical .ui-slider-range-min { bottom: 0; }
|
||||
.ui-slider-vertical .ui-slider-range-max { top: 0; }/*
|
||||
* jQuery UI Tabs 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Tabs#theming
|
||||
*/
|
||||
.ui-tabs { position: relative; padding: .2em; zoom: 1; } /* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */
|
||||
.ui-tabs .ui-tabs-nav { margin: 0; padding: .2em .2em 0; }
|
||||
.ui-tabs .ui-tabs-nav li { list-style: none; float: left; position: relative; top: 1px; margin: 0 .2em 1px 0; border-bottom: 0 !important; padding: 0; white-space: nowrap; }
|
||||
.ui-tabs .ui-tabs-nav li a { float: left; padding: .5em 1em; text-decoration: none; }
|
||||
.ui-tabs .ui-tabs-nav li.ui-tabs-selected { margin-bottom: 0; padding-bottom: 1px; }
|
||||
.ui-tabs .ui-tabs-nav li.ui-tabs-selected a, .ui-tabs .ui-tabs-nav li.ui-state-disabled a, .ui-tabs .ui-tabs-nav li.ui-state-processing a { cursor: text; }
|
||||
.ui-tabs .ui-tabs-nav li a, .ui-tabs.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-selected a { cursor: pointer; } /* first selector in group seems obsolete, but required to overcome bug in Opera applying cursor: text overall if defined elsewhere... */
|
||||
.ui-tabs .ui-tabs-panel { display: block; border-width: 0; padding: 1em 1.4em; background: none; }
|
||||
.ui-tabs .ui-tabs-hide { display: none !important; }
|
||||
/*
|
||||
* jQuery UI Datepicker 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Datepicker#theming
|
||||
*/
|
||||
.ui-datepicker { width: 17em; padding: .2em .2em 0; display: none; }
|
||||
.ui-datepicker .ui-datepicker-header { position:relative; padding:.2em 0; }
|
||||
.ui-datepicker .ui-datepicker-prev, .ui-datepicker .ui-datepicker-next { position:absolute; top: 2px; width: 1.8em; height: 1.8em; }
|
||||
.ui-datepicker .ui-datepicker-prev-hover, .ui-datepicker .ui-datepicker-next-hover { top: 1px; }
|
||||
.ui-datepicker .ui-datepicker-prev { left:2px; }
|
||||
.ui-datepicker .ui-datepicker-next { right:2px; }
|
||||
.ui-datepicker .ui-datepicker-prev-hover { left:1px; }
|
||||
.ui-datepicker .ui-datepicker-next-hover { right:1px; }
|
||||
.ui-datepicker .ui-datepicker-prev span, .ui-datepicker .ui-datepicker-next span { display: block; position: absolute; left: 50%; margin-left: -8px; top: 50%; margin-top: -8px; }
|
||||
.ui-datepicker .ui-datepicker-title { margin: 0 2.3em; line-height: 1.8em; text-align: center; }
|
||||
.ui-datepicker .ui-datepicker-title select { font-size:1em; margin:1px 0; }
|
||||
.ui-datepicker select.ui-datepicker-month-year {width: 100%;}
|
||||
.ui-datepicker select.ui-datepicker-month,
|
||||
.ui-datepicker select.ui-datepicker-year { width: 49%;}
|
||||
.ui-datepicker table {width: 100%; font-size: .9em; border-collapse: collapse; margin:0 0 .4em; }
|
||||
.ui-datepicker th { padding: .7em .3em; text-align: center; font-weight: bold; border: 0; }
|
||||
.ui-datepicker td { border: 0; padding: 1px; }
|
||||
.ui-datepicker td span, .ui-datepicker td a { display: block; padding: .2em; text-align: right; text-decoration: none; }
|
||||
.ui-datepicker .ui-datepicker-buttonpane { background-image: none; margin: .7em 0 0 0; padding:0 .2em; border-left: 0; border-right: 0; border-bottom: 0; }
|
||||
.ui-datepicker .ui-datepicker-buttonpane button { float: right; margin: .5em .2em .4em; cursor: pointer; padding: .2em .6em .3em .6em; width:auto; overflow:visible; }
|
||||
.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current { float:left; }
|
||||
|
||||
/* with multiple calendars */
|
||||
.ui-datepicker.ui-datepicker-multi { width:auto; }
|
||||
.ui-datepicker-multi .ui-datepicker-group { float:left; }
|
||||
.ui-datepicker-multi .ui-datepicker-group table { width:95%; margin:0 auto .4em; }
|
||||
.ui-datepicker-multi-2 .ui-datepicker-group { width:50%; }
|
||||
.ui-datepicker-multi-3 .ui-datepicker-group { width:33.3%; }
|
||||
.ui-datepicker-multi-4 .ui-datepicker-group { width:25%; }
|
||||
.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header { border-left-width:0; }
|
||||
.ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header { border-left-width:0; }
|
||||
.ui-datepicker-multi .ui-datepicker-buttonpane { clear:left; }
|
||||
.ui-datepicker-row-break { clear:both; width:100%; font-size:0em; }
|
||||
|
||||
/* RTL support */
|
||||
.ui-datepicker-rtl { direction: rtl; }
|
||||
.ui-datepicker-rtl .ui-datepicker-prev { right: 2px; left: auto; }
|
||||
.ui-datepicker-rtl .ui-datepicker-next { left: 2px; right: auto; }
|
||||
.ui-datepicker-rtl .ui-datepicker-prev:hover { right: 1px; left: auto; }
|
||||
.ui-datepicker-rtl .ui-datepicker-next:hover { left: 1px; right: auto; }
|
||||
.ui-datepicker-rtl .ui-datepicker-buttonpane { clear:right; }
|
||||
.ui-datepicker-rtl .ui-datepicker-buttonpane button { float: left; }
|
||||
.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current { float:right; }
|
||||
.ui-datepicker-rtl .ui-datepicker-group { float:right; }
|
||||
.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
|
||||
.ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
|
||||
|
||||
/* IE6 IFRAME FIX (taken from datepicker 1.5.3 */
|
||||
.ui-datepicker-cover {
|
||||
display: none; /*sorry for IE5*/
|
||||
display/**/: block; /*sorry for IE5*/
|
||||
position: absolute; /*must have*/
|
||||
z-index: -1; /*must have*/
|
||||
filter: mask(); /*must have*/
|
||||
top: -4px; /*must have*/
|
||||
left: -4px; /*must have*/
|
||||
width: 200px; /*must have*/
|
||||
height: 200px; /*must have*/
|
||||
}/*
|
||||
* jQuery UI Progressbar 1.8.18
|
||||
*
|
||||
* Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
* http://jquery.org/license
|
||||
*
|
||||
* http://docs.jquery.com/UI/Progressbar#theming
|
||||
*/
|
||||
.ui-progressbar { height:2em; text-align: left; overflow: hidden; }
|
||||
.ui-progressbar .ui-progressbar-value {margin: -1px; height:100%; }
|
||||
BIN
storage/mroonga/vendor/groonga/data/html/admin/favicon.ico
vendored
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/favicon.png
vendored
Normal file
|
After Width: | Height: | Size: 682 B |
121
storage/mroonga/vendor/groonga/data/html/admin/favicon.svg
vendored
Normal file
|
|
@ -0,0 +1,121 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="60.000706"
|
||||
height="60.001022"
|
||||
id="svg5342"
|
||||
version="1.1"
|
||||
inkscape:version="0.48.1 r9760"
|
||||
sodipodi:docname="favicon.svg"
|
||||
inkscape:export-filename="favicon.png"
|
||||
inkscape:export-xdpi="24"
|
||||
inkscape:export-ydpi="24">
|
||||
<defs
|
||||
id="defs5344">
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#SVGID_9_"
|
||||
id="linearGradient5521"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="470.15039"
|
||||
y1="437.05859"
|
||||
x2="470.15039"
|
||||
y2="497.05859" />
|
||||
<linearGradient
|
||||
id="SVGID_9_"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="470.15039"
|
||||
y1="437.05859"
|
||||
x2="470.15039"
|
||||
y2="497.05859">
|
||||
<stop
|
||||
offset="0"
|
||||
style="stop-color:#3FA9F5"
|
||||
id="stop4050" />
|
||||
<stop
|
||||
offset="1"
|
||||
style="stop-color:#0071BC"
|
||||
id="stop4052" />
|
||||
</linearGradient>
|
||||
<linearGradient
|
||||
y2="497.05859"
|
||||
x2="470.15039"
|
||||
y1="437.05859"
|
||||
x1="470.15039"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
id="linearGradient5566"
|
||||
xlink:href="#SVGID_9_"
|
||||
inkscape:collect="always" />
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#SVGID_9_"
|
||||
id="linearGradient5599"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="470.15039"
|
||||
y1="437.05859"
|
||||
x2="470.15039"
|
||||
y2="497.05859" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="1.979899"
|
||||
inkscape:cx="61.872887"
|
||||
inkscape:cy="42.401151"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
fit-margin-top="0"
|
||||
fit-margin-left="0"
|
||||
fit-margin-right="0"
|
||||
fit-margin-bottom="0"
|
||||
inkscape:window-width="902"
|
||||
inkscape:window-height="442"
|
||||
inkscape:window-x="2773"
|
||||
inkscape:window-y="302"
|
||||
inkscape:window-maximized="0" />
|
||||
<metadata
|
||||
id="metadata5347">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="レイヤー 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-343.75609,-530.41738)">
|
||||
<g
|
||||
id="g5587">
|
||||
<polygon
|
||||
style="fill:url(#linearGradient5599)"
|
||||
id="polygon4054"
|
||||
points="440.15,437.059 440.15,497.059 466.012,497.059 500.15,497.059 500.15,462.92 500.15,437.059 "
|
||||
transform="translate(-96.393911,93.359403)" />
|
||||
<path
|
||||
style="fill:#ffffff"
|
||||
inkscape:connector-curvature="0"
|
||||
id="path4107"
|
||||
d="m 397.29009,567.3004 c 7.502,-7.505 9.8,-20.401 -0.335,-30.538 -4.224,-4.222 -9.514,-6.337 -14.8,-6.345 h -0.005 c -5.286,-0.007 -10.567,2.093 -14.774,6.299 -2.522,2.52 -4.434,5.76 -5.428,9.33 -6.49,-0.099 -13.001,2.411 -18.191,7.53 v 36.479 c 0.114,0.121 0.227,0.242 0.344,0.361 h 25.518 11.027 c 4.434,-4.717 7.233,-11.018 7.295,-17.672 3.385,-0.898 6.606,-2.7 9.349,-5.444 z m -13.748,-2.759 c -1.121,1.873 -0.997,2.089 -0.949,5.602 0.062,3.979 -1.437,8.102 -5.189,11.854 -5.736,5.737 -16.326,7.017 -24.119,-0.776 -6.139,-6.14 -9.021,-16.475 -0.84,-24.658 3.038,-3.034 7.406,-4.827 11.998,-4.745 3.193,0.055 3.564,0.174 5.621,-0.76 2.058,-0.938 1.166,-3.019 2.396,-6.692 0.6,-1.792 1.666,-3.551 3.332,-5.224 4.451,-4.448 12.643,-5.469 18.643,0.531 4.887,4.887 6.96,12.677 0.572,19.065 -1.441,1.444 -3.284,2.509 -5.319,3.087 -3.266,0.937 -5.023,0.838 -6.146,2.716 z" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 4.2 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/images/groonga.png
vendored
Normal file
|
After Width: | Height: | Size: 5.9 KiB |
121
storage/mroonga/vendor/groonga/data/html/admin/images/groonga.svg
vendored
Normal file
|
|
@ -0,0 +1,121 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="232.17999"
|
||||
height="73.112274"
|
||||
id="svg3635"
|
||||
version="1.1"
|
||||
inkscape:version="0.48.1 r9760"
|
||||
sodipodi:docname="groonga.svg"
|
||||
inkscape:export-filename="groonga.png"
|
||||
inkscape:export-xdpi="90"
|
||||
inkscape:export-ydpi="90">
|
||||
<defs
|
||||
id="defs3637">
|
||||
<linearGradient
|
||||
gradientTransform="translate(-419.62671,208.8676)"
|
||||
id="SVGID_1_"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="223.6167"
|
||||
y1="76.3564"
|
||||
x2="223.6167"
|
||||
y2="137.38029">
|
||||
<stop
|
||||
offset="0"
|
||||
style="stop-color:#3FA9F5"
|
||||
id="stop160" />
|
||||
<stop
|
||||
offset="1"
|
||||
style="stop-color:#0071BC"
|
||||
id="stop162" />
|
||||
</linearGradient>
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#SVGID_1_"
|
||||
id="linearGradient3693"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
gradientTransform="translate(-419.62671,208.8676)"
|
||||
x1="223.6167"
|
||||
y1="76.3564"
|
||||
x2="223.6167"
|
||||
y2="137.38029" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="1.4"
|
||||
inkscape:cx="202.10766"
|
||||
inkscape:cy="3.8593771"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
fit-margin-top="5"
|
||||
fit-margin-left="5"
|
||||
fit-margin-right="5"
|
||||
fit-margin-bottom="5"
|
||||
inkscape:window-width="902"
|
||||
inkscape:window-height="442"
|
||||
inkscape:window-x="2411"
|
||||
inkscape:window-y="568"
|
||||
inkscape:window-maximized="0" />
|
||||
<metadata
|
||||
id="metadata3640">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="レイヤー 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-229.62429,-318.66319)">
|
||||
<g
|
||||
id="g3685"
|
||||
transform="translate(520,37.142857)">
|
||||
<path
|
||||
id="path149"
|
||||
d="m -228.72771,306.3346 c -1.336,-0.29 -2.281,-0.448 -3.442,-0.448 -2.847,0 -5.33,0.831 -7.391,2.468 -0.091,0.06 -0.192,0.14 -0.303,0.245 -0.231,0.197 -0.452,0.406 -0.668,0.621 -1.478,1.314 -2.76,1.952 -2.76,-1.235 v -0.666 c 0,-0.404 -0.327,-0.732 -0.732,-0.732 h -2.101 c -0.198,0 -0.388,0.081 -0.525,0.223 -0.139,0.143 -0.212,0.335 -0.206,0.532 0.105,3.333 0.215,6.778 0.215,9.621 v 18.75 c 0,0.404 0.328,0.731 0.732,0.731 h 2.209 c 0.404,0 0.732,-0.328 0.732,-0.731 v -9.914 c 0,-1.37 0.107,-3.805 0.309,-4.813 1.569,-7.797 4.982,-11.588 10.435,-11.588 0.979,0 1.881,0.165 2.874,0.363 0.048,0.011 0.096,0.015 0.144,0.015 0.148,0 0.294,-0.045 0.417,-0.131 0.163,-0.113 0.273,-0.288 0.306,-0.484 l 0.323,-1.994 c 0.062,-0.384 -0.187,-0.752 -0.568,-0.833 z"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path151"
|
||||
d="m -139.68071,307.9266 c -2.512,-1.774 -5.292,-2.04 -6.726,-2.04 -2.91,0 -5.648,0.912 -7.822,2.495 -0.005,0.004 -0.01,0.005 -0.014,0.009 -1.004,0.648 -2.627,0.909 -2.618,-0.625 l 0,-0.021 c 0.002,-0.107 -0.003,-0.199 -0.013,-0.277 l -0.008,-0.182 c -0.019,-0.391 -0.34,-0.698 -0.731,-0.698 h -2.102 c -0.203,0 -0.396,0.084 -0.535,0.232 -0.138,0.148 -0.209,0.347 -0.195,0.549 0.152,2.28 0.214,4.171 0.214,6.524 v 21.821 c 0,0.404 0.328,0.731 0.731,0.731 h 2.209 c 0.404,0 0.732,-0.328 0.732,-0.731 v -17.511 c 0,-0.813 0.253,-1.761 0.49,-2.377 0.004,-0.008 0.006,-0.018 0.01,-0.026 1.043,-3.042 4.224,-6.12 8.417,-6.475 3.236,0.002 8.327,2.358 9.024,8.226 0.016,0.15 0.03,0.299 0.042,0.444 0.004,0.049 0.008,0.099 0.011,0.149 0.005,0.07 0.009,0.139 0.014,0.209 0.009,0.19 0.015,0.384 0.015,0.582 0,0.335 0.006,0.638 0.017,0.911 v 15.869 c 0,0.404 0.328,0.731 0.733,0.731 h 2.208 c 0.404,0 0.732,-0.328 0.732,-0.731 v -16.272 c 0,-5.375 -1.627,-9.248 -4.835,-11.516 z"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path153"
|
||||
d="m -63.456714,333.2686 c -0.133,-0.113 -0.301,-0.174 -0.473,-0.174 -0.04,0 -0.08,0.003 -0.12,0.01 -0.587,0.098 -0.965,0.098 -1.442,0.098 -1.147,0 -2.177,-0.335 -2.177,-4.387 v -9.913 c 0,-2.343 -0.179,-5.368 -1.583,-7.972 -1.822,-3.382 -5.181,-5.098 -9.978,-5.098 -2.475,0 -6.217,0.516 -9.99,2.974 -0.315,0.205 -0.422,0.615 -0.25,0.949 l 0.861,1.67 c 0.098,0.189 0.272,0.326 0.478,0.375 0.058,0.014 0.116,0.021 0.173,0.021 0.151,0 0.299,-0.047 0.424,-0.135 2.314,-1.639 5.186,-2.504 8.305,-2.504 3.995,0 6.004,1.854 7,3.939 l 0,0 c 1.004,2.221 -0.561,4.404 -2.285,4.584 -0.085,0.005 -0.17,0.008 -0.254,0.013 -0.014,0 -0.028,0.001 -0.042,0 -0.055,-10e-4 -0.101,0.003 -0.143,0.009 -10.978,0.626 -16.538,4.313 -16.538,10.98 0,2.027 0.803,4.057 2.202,5.569 1.233,1.333 3.56,2.921 7.635,2.921 3.471,0 6.271,-1.112 8.325,-2.472 0.061,-0.031 0.13,-0.076 0.211,-0.141 0.023,-0.017 0.042,-0.031 0.064,-0.048 0.128,-0.088 0.256,-0.177 0.378,-0.268 1.275,-0.825 1.969,-0.351 2.623,0.504 0.002,0.002 0.006,0.005 0.008,0.007 0.84,1.14 2.161,1.718 3.962,1.718 0.846,0 1.591,-0.094 2.344,-0.294 0.32,-0.085 0.543,-0.375 0.543,-0.707 v -1.67 c -0.002,-0.214 -0.097,-0.419 -0.261,-0.558 z m -18.252,0.527 c -3.042,0 -6.111,-1.723 -6.111,-5.572 0,-4.863 5.936,-6.58 12.167,-7.043 2.32,-0.043 4.097,2.162 4.311,4.575 v 0.989 c -0.062,0.647 -0.246,1.289 -0.568,1.888 -0.162,0.263 -0.356,0.556 -0.589,0.864 -0.04,0.047 -0.075,0.093 -0.103,0.134 -1.442,1.848 -4.223,4.165 -9.107,4.165 z"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path155"
|
||||
d="m -257.43671,306.5866 h -2.047 c -0.392,0 -0.715,0.311 -0.731,0.703 -0.065,1.618 -0.892,1.836 -2.704,0.766 -0.01,-0.006 -0.018,-0.014 -0.026,-0.019 -0.178,-0.119 -0.361,-0.231 -0.545,-0.339 -0.011,-0.007 -0.021,-0.012 -0.032,-0.02 -0.088,-0.059 -0.169,-0.104 -0.245,-0.14 -1.982,-1.096 -4.306,-1.65 -6.923,-1.65 -3.739,0 -7.428,1.548 -10.122,4.25 -2.083,2.087 -4.564,5.826 -4.564,11.784 0,3.818 1.347,7.413 3.792,10.122 2.594,2.875 6.234,4.458 10.249,4.458 3.11,0 5.514,-0.819 7.334,-1.897 0.004,-0.002 0.008,-0.003 0.012,-0.005 1.953,-0.873 3.601,-2.182 3.135,2.232 -0.875,5.678 -4.519,8.765 -10.482,8.765 -4.175,0 -7.31,-1.404 -9.204,-2.583 -0.117,-0.072 -0.251,-0.11 -0.387,-0.11 -0.061,0 -0.122,0.008 -0.182,0.023 -0.193,0.049 -0.358,0.176 -0.456,0.35 l -0.969,1.725 c -0.189,0.336 -0.085,0.761 0.237,0.972 2.852,1.863 6.909,2.975 10.853,2.975 2.691,0 9.293,-0.625 12.494,-6.412 1.384,-2.481 2.03,-5.968 2.03,-10.968 v -17.457 c 0,-2.474 0.07,-4.679 0.214,-6.738 0.014,-0.202 -0.057,-0.402 -0.195,-0.549 -0.139,-0.153 -0.333,-0.238 -0.536,-0.238 z m -16.892,26.028 c -0.605,-0.24 -7.609,-3.216 -7.013,-11.811 0.551,-7.946 5.723,-10.459 6.518,-10.798 1.278,-0.5 2.7,-0.769 4.241,-0.769 1.664,0 3.112,0.327 4.354,0.873 6.846,3.871 7.696,16.453 0.885,21.467 -1.592,0.999 -3.437,1.573 -5.346,1.573 -1.342,0 -2.552,-0.194 -3.639,-0.535 z"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path157"
|
||||
d="m -99.588714,306.5866 h -2.046996 c -0.393,0 -0.716,0.311 -0.731,0.703 -0.066,1.618 -0.892,1.836 -2.703,0.766 -0.009,-0.005 -0.018,-0.014 -0.027,-0.019 -0.178,-0.119 -0.362,-0.231 -0.546,-0.339 -0.011,-0.008 -0.02,-0.014 -0.031,-0.02 -0.087,-0.059 -0.168,-0.104 -0.244,-0.139 -1.982,-1.097 -4.307,-1.651 -6.924,-1.651 -3.739,0 -7.429,1.548 -10.122,4.25 -2.082,2.087 -4.564,5.826 -4.564,11.784 0,3.818 1.346,7.413 3.792,10.122 2.595,2.875 6.234,4.458 10.248,4.458 3.111,0 5.514,-0.819 7.335,-1.897 0.004,-0.002 0.007,-0.003 0.012,-0.005 1.954,-0.874 3.603,-2.183 3.135,2.233 -0.875,5.678 -4.519,8.764 -10.482,8.764 -4.175,0 -7.31,-1.404 -9.204,-2.583 -0.118,-0.072 -0.251,-0.11 -0.387,-0.11 -0.06,0 -0.122,0.008 -0.182,0.023 -0.193,0.049 -0.358,0.176 -0.456,0.35 l -0.97,1.725 c -0.189,0.336 -0.085,0.761 0.237,0.972 2.853,1.863 6.91,2.975 10.854,2.975 2.689,0 9.293,-0.625 12.493,-6.412 1.384996,-2.481 2.030996,-5.968 2.030996,-10.968 v -17.457 c 0,-2.474 0.07,-4.679 0.214,-6.738 0.014,-0.202 -0.057,-0.402 -0.195,-0.549 -0.139,-0.153 -0.332,-0.238 -0.536,-0.238 z m -16.891996,26.028 c -0.605,-0.24 -7.609,-3.216 -7.013,-11.811 0.551,-7.94 5.716,-10.455 6.517,-10.798 1.278,-0.5 2.701,-0.769 4.242,-0.769 1.665,0 3.113,0.327 4.354,0.873 6.845,3.871 7.696,16.453 0.884,21.467 -1.592,1 -3.436,1.573 -5.345,1.573 -1.343,0 -2.553,-0.194 -3.639,-0.535 z"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path164"
|
||||
d="m -198.36371,292.3616 c -2.337,2.336 -4.109,5.342 -5.032,8.654 -6.076,-0.093 -12.171,2.273 -17.007,7.11 -8.142,8.141 -10.674,22.913 0.667,34.253 9.542,9.543 23.793,9.687 33.145,0.333 4.421,-4.424 7.236,-10.506 7.297,-16.94 3.14,-0.835 6.125,-2.507 8.67,-5.049 6.956,-6.959 9.086,-18.919 -0.311,-28.318 -7.833,-7.83 -19.626,-7.847 -27.429,-0.043 z m 25.622,20.422 c -1.335,1.338 -3.045,2.324 -4.932,2.864 -3.027,0.867 -4.657,0.777 -5.698,2.515 -1.041,1.735 -0.926,1.94 -0.88,5.194 0.056,3.689 -1.333,7.513 -4.813,10.995 -5.32,5.318 -15.14,6.504 -22.366,-0.721 -5.693,-5.694 -8.365,-15.278 -0.778,-22.865 2.816,-2.813 6.866,-4.477 11.124,-4.402 2.961,0.053 3.306,0.161 5.212,-0.704 1.909,-0.869 1.082,-2.799 2.222,-6.205 0.556,-1.66 1.545,-3.294 3.092,-4.844 4.126,-4.126 11.721,-5.072 17.285,0.491 4.533,4.535 6.455,11.759 0.532,17.682 z"
|
||||
inkscape:connector-curvature="0"
|
||||
style="fill:url(#linearGradient3693)" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 9.8 KiB |
BIN
storage/mroonga/vendor/groonga/data/html/admin/images/loading.gif
vendored
Normal file
|
After Width: | Height: | Size: 673 B |
297
storage/mroonga/vendor/groonga/data/html/admin/index.html
vendored
Normal file
|
|
@ -0,0 +1,297 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
|
||||
"http://www.w3.org/TR/html4/strict.dtd">
|
||||
<html lang="ja">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta name="robots" content="noindex,nofollow,noarchive">
|
||||
<title>groonga admin</title>
|
||||
<link rel="shortcut icon" href="favicon.ico">
|
||||
<link rel="icon" href="favicon.png">
|
||||
<link rel="stylesheet" type="text/css" href="css/groonga-admin.css">
|
||||
<link rel="stylesheet" type="text/css" href="css/redmond/jquery-ui-1.8.18.custom.css">
|
||||
<script type="text/javascript" src="js/jquery-1.7.2.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery-ui-1.8.18.custom.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery.flot-0.7.min.js"></script>
|
||||
<script type="text/javascript" src="js/groonga-admin.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="header">
|
||||
<ul id="locale-list">
|
||||
<li>en</li>
|
||||
<li><a href="index.ja.html">ja</a>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="body">
|
||||
<table>
|
||||
<tr>
|
||||
<td id="left-column">
|
||||
<div id="side-menu">
|
||||
<h2>List of view</h2>
|
||||
<ul id="side-menu-view-list">
|
||||
<li><a href="#side-menu-summary" id="side-menu-summary">Summary</a></li>
|
||||
<li><a href="#side-menu-suggest" id="side-menu-suggest">Suggest</a></li>
|
||||
</ul>
|
||||
<h2>List of table</h2>
|
||||
<ul id="side-menu-tablelist" />
|
||||
</div>
|
||||
</td>
|
||||
|
||||
<td id="right-column">
|
||||
<!-- database view -->
|
||||
<div id="database-tabs">
|
||||
<ul>
|
||||
<li><a href="#database-tab-summary">Summary</a></li>
|
||||
<li><a href="#database-tab-tablelist" id="tab-tablelist-link">List table</a></li>
|
||||
<li><a href="#database-tab-createtable">Create table</a></li>
|
||||
</ul>
|
||||
<div id="database-tab-summary">
|
||||
<p>
|
||||
Groonga administration tool.
|
||||
</p>
|
||||
<ul>
|
||||
<li>Start time: <span id="status-starttime"></span></li>
|
||||
<li>Uptime: <span id="status-uptime"></span></li>
|
||||
<li>Number of query: <span id="status-n-queries"></span></li>
|
||||
<li>Cache hit rate: <span id="status-cache-hit-rate"></span></li>
|
||||
</ul>
|
||||
<div id="throughput-chart" style="height: 300px; max-width: 500px;">
|
||||
</div>
|
||||
</div>
|
||||
<div id="database-tab-tablelist">
|
||||
<div id="tab-tablelist-table">
|
||||
</div>
|
||||
<input type="button" id="tablelist-remove-table" value="Remove table">
|
||||
</div>
|
||||
<div id="database-tab-createtable">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<label for="createtable-name">Table name</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" id="createtable-name">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Primary key
|
||||
</td>
|
||||
<td>
|
||||
<label for="createtable-key-type">Key type:</label>
|
||||
<select id="createtable-key-type">
|
||||
<optgroup label="Built-in types" id="createtable-key-type-builtin">
|
||||
</optgroup>
|
||||
<optgroup label="Key of Table" id="createtable-key-type-table">
|
||||
</optgroup>
|
||||
</select>
|
||||
<label for="createtable-key-index">Key index types:</label>
|
||||
<select id="createtable-key-index">
|
||||
<option value="GRN_OBJ_TABLE_PAT_KEY">Patricia trie</option>
|
||||
<option value="GRN_OBJ_TABLE_HASH_KEY">Hash table</option>
|
||||
<option value="GRN_OBJ_TABLE_NO_KEY">No key</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Flags
|
||||
</td>
|
||||
<td id="createtable-flags">
|
||||
<input type="checkbox" value="GRN_OBJ_PERSISTENT" checked>Persistent</input>
|
||||
<input type="checkbox" value="GRN_OBJ_KEY_NORMALIZE">Normalize key</input>
|
||||
<input type="checkbox" value="GRN_OBJ_KEY_WITH_SIS">Key with suffix</input>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Value types
|
||||
</td>
|
||||
<td>
|
||||
<select id="createtable-value-type">
|
||||
<optgroup label="Built-in types" id="createtable-value-type-builtin">
|
||||
</optgroup>
|
||||
<optgroup label="Use table as value type" id="createtable-value-type-table">
|
||||
</optgroup>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Default tokenizer
|
||||
</td>
|
||||
<td>
|
||||
<select id="createtable-default-tokenizer">
|
||||
<optgroup label="Built-in tokenizer" id="createtable-default-tokenizer-builtin">
|
||||
</optgroup>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<input type="button" id="createtable-add-table" value="Create table">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- table view -->
|
||||
<div id="table-tabs">
|
||||
<ul>
|
||||
<li><a href="#table-tab-recordlist" id="tab-recordlist-link">List records</a></li>
|
||||
<li><a href="#table-tab-columnlist" id="tab-columnlist-link">List columns</a></li>
|
||||
<li><a href="#table-tab-createrecord" id="tab-createrecord-link">Create record</a></li>
|
||||
<li><a href="#table-tab-createcolumn">Create columns</a></li>
|
||||
</ul>
|
||||
<div id="table-tab-recordlist">
|
||||
<input type="checkbox" id="table-tab-recordlist-full-checkbox" /><label for="table-tab-recordlist-full-checkbox">Advanced search</label>
|
||||
<form id="tab-recordlist-form">
|
||||
<div id="table-tab-recordlist-form-simple">
|
||||
<label for="tab-recordlist-simplequery">Query: </label><input type="text" id="tab-recordlist-simplequery">
|
||||
<select id="tab-recordlist-simplequerytype">
|
||||
<option value="query" data-placeholder="e.g.)column:@value">query</option>
|
||||
<option value="filter" data-placeholder="e.g.)column == "value"">filter</option>
|
||||
</select>
|
||||
<input type="checkbox" id="tab-recordlist-incremental" /><label for="tab-recordlist-incremental" id="tab-recordlist-incremental-label">Incremental search</label>
|
||||
</div>
|
||||
<div id="table-tab-recordlist-form-full">
|
||||
<table>
|
||||
<tr><td>match_columns</td><td><input type="text" id="tab-recordlist-match_columns" /></td></tr>
|
||||
<tr><td>query</td><td><input type="text" id="tab-recordlist-query" /></td></tr>
|
||||
<tr><td>filter</td><td><input type="text" id="tab-recordlist-filter" /></td></tr>
|
||||
<tr><td>scorer</td><td><input type="text" id="tab-recordlist-scorer" /></td></tr>
|
||||
<tr><td>sortby</td><td><input type="text" id="tab-recordlist-sortby" /></td></tr>
|
||||
<tr><td>output_columns</td><td><input type="text" id="tab-recordlist-output_columns" /></td></tr>
|
||||
<tr><td>offset</td><td><input type="text" id="tab-recordlist-offset" /></td></tr>
|
||||
<tr><td>limit</td><td><input type="text" id="tab-recordlist-limit" /></td></tr>
|
||||
<tr><td>drilldown</td><td><input type="text" id="tab-recordlist-drilldown" /></td></tr>
|
||||
<tr><td>drilldown_sortby</td><td><input type="text" id="tab-recordlist-drilldown_sortby" /></td></tr>
|
||||
<tr><td>drilldown_output_columns</td><td><input type="text" id="tab-recordlist-drilldown_output_columns" /></td></tr>
|
||||
<tr><td>drilldown_offset</td><td><input type="text" id="tab-recordlist-drilldown_offset" /></td></tr>
|
||||
<tr><td>drilldown_limit</td><td><input type="text" id="tab-recordlist-drilldown_limit" /></td></tr>
|
||||
</table>
|
||||
</div>
|
||||
<input type="submit" id="tab-recordlist-submit" value="Search"/>
|
||||
</form>
|
||||
<div id="tab-recordlist-table">
|
||||
</div>
|
||||
<input type="button" id="recordlist-remove-record" value="Remove records">
|
||||
</div>
|
||||
<div id="table-tab-columnlist">
|
||||
<div id="tab-columnlist-table">
|
||||
</div>
|
||||
<input type="button" id="columnlist-remove-column" value="Remove columns">
|
||||
</div>
|
||||
<div id="table-tab-createrecord">
|
||||
<table id="table-createrecord">
|
||||
</table>
|
||||
<input type="button" id="createrecord-add-record" value="Create record">
|
||||
</div>
|
||||
<div id="table-tab-createcolumn">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<label for="createcolumn-name">Column name</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" id="createcolumn-name">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Column types
|
||||
</td>
|
||||
<td>
|
||||
<label for="createcolumn-type">Types:</label>
|
||||
<select id="createcolumn-type">
|
||||
<optgroup label="Built-in types" id="createcolumn-type-builtin">
|
||||
</optgroup>
|
||||
<optgroup label="Table" id="createcolumn-type-table">
|
||||
</optgroup>
|
||||
</select>
|
||||
|
||||
<label for="createcolumn-column-type">Column stores:</label>
|
||||
<select id="createcolumn-column-type">
|
||||
<option value="GRN_OBJ_COLUMN_SCALAR">Scalar</option>
|
||||
<option value="GRN_OBJ_COLUMN_VECTOR">Vector</option>
|
||||
<option value="GRN_OBJ_COLUMN_INDEX">Inverted index</option>
|
||||
</select>
|
||||
|
||||
<label for="createcolumn-compress">Compression:</label>
|
||||
<select id="createcolumn-compress" disabled>
|
||||
<option value="GRN_OBJ_COMPRESS_NONE">No compression</option>
|
||||
<option value="GRN_OBJ_COMPRESS_ZLIB">zlib</option>
|
||||
<option value="GRN_OBJ_COMPRESS_LZO">lzo</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Flags
|
||||
</td>
|
||||
<td id="createcolumn-flags">
|
||||
<input type="checkbox" value="GRN_OBJ_PERSISTENT" checked>Persistent</input>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Flags for inverted index
|
||||
</td>
|
||||
<td id="createcolumn-ii-flags">
|
||||
<input type="checkbox" value="GRN_OBJ_WITH_SECTION">With section information</input>
|
||||
<input type="checkbox" value="GRN_OBJ_WITH_WEIGHT">With weight information</input>
|
||||
<input type="checkbox" value="GRN_OBJ_WITH_POSITION">With position information</input>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<input type="button" id="createcolumn-add-column" value="Create column">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- suggest view -->
|
||||
<div id="suggest-tabs">
|
||||
<ul>
|
||||
<li><a href="#suggest-tab-search">Search</a></li>
|
||||
</ul>
|
||||
<div id="suggest-tab-search">
|
||||
<form id="suggest-tab-search-form">
|
||||
<p>
|
||||
<label for="suggest-dataset">Dataset: </label>
|
||||
<input type="text" id="suggest-dataset">
|
||||
</p>
|
||||
<label for="suggest-query">Suggest query: </label>
|
||||
<input type="text" id="suggest-query">
|
||||
<input type="button" id="suggest-submit" value="Search" />
|
||||
</form>
|
||||
<div id="suggest-result-tabs">
|
||||
<ul>
|
||||
<li><a href="#suggest-result-tab-suggest">Suggestion</a></li>
|
||||
<li><a href="#suggest-result-tab-complete">Completion</a></li>
|
||||
<li><a href="#suggest-result-tab-correct">Correction</a></li>
|
||||
</ul>
|
||||
<div id="suggest-result-tab-suggest">
|
||||
</div>
|
||||
<div id="suggest-result-tab-complete">
|
||||
</div>
|
||||
<div id="suggest-result-tab-correct">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div id="footer">
|
||||
Powered by <a href="http://jquery.com/">jQuery</a> and <a href="http://jqueryui.com/">jQuery UI</a>.
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
var admin = new GroongaAdmin();
|
||||
$(location.hash).click();
|
||||
$.ajaxSetup({
|
||||
timeout: 10000,
|
||||
cache: false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
301
storage/mroonga/vendor/groonga/data/html/admin/index.ja.html
vendored
Normal file
|
|
@ -0,0 +1,301 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
|
||||
"http://www.w3.org/TR/html4/strict.dtd">
|
||||
<html lang="ja">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta name="robots" content="noindex,nofollow,noarchive">
|
||||
<title>groonga admin</title>
|
||||
<link rel="shortcut icon" href="favicon.ico">
|
||||
<link rel="icon" href="favicon.png">
|
||||
<link rel="stylesheet" type="text/css" href="css/groonga-admin.css">
|
||||
<link rel="stylesheet" type="text/css" href="css/redmond/jquery-ui-1.8.18.custom.css">
|
||||
<script type="text/javascript" src="js/jquery-1.7.2.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery-ui-1.8.18.custom.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery.flot-0.7.min.js"></script>
|
||||
<script type="text/javascript" src="js/groonga-admin.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="header">
|
||||
<ul id="locale-list">
|
||||
<li><a href="index.html">en</a></li>
|
||||
<li>ja</a>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="body">
|
||||
<table>
|
||||
<tr>
|
||||
<td id="left-column">
|
||||
<div id="side-menu">
|
||||
<h2>画面一覧</h2>
|
||||
<ul id="side-menu-view-list">
|
||||
<li><a href="#side-menu-summary" id="side-menu-summary">サマリー</a></li>
|
||||
<li><a href="#side-menu-suggest" id="side-menu-suggest">サジェスト</a></li>
|
||||
</ul>
|
||||
<h2>テーブル一覧</h2>
|
||||
<ul id="side-menu-tablelist" />
|
||||
</div>
|
||||
</td>
|
||||
|
||||
<td id="right-column">
|
||||
<!-- database view -->
|
||||
<div id="database-tabs">
|
||||
<ul>
|
||||
<li><a href="#database-tab-summary">サマリー</a></li>
|
||||
<li><a href="#database-tab-tablelist" id="tab-tablelist-link">テーブル一覧</a></li>
|
||||
<li><a href="#database-tab-createtable">テーブル作成</a></li>
|
||||
</ul>
|
||||
<div id="database-tab-summary">
|
||||
<p>
|
||||
groongaの管理ツールです。
|
||||
</p>
|
||||
<ul>
|
||||
<li>開始時間: <span id="status-starttime"></span></li>
|
||||
<li>uptime: <span id="status-uptime"></span></li>
|
||||
<li>クエリ数: <span id="status-n-queries"></span></li>
|
||||
<li>キャッシュヒット率: <span id="status-cache-hit-rate"></span></li>
|
||||
</ul>
|
||||
<div id="throughput-chart" style="height: 300px; max-width: 500px;">
|
||||
</div>
|
||||
</div>
|
||||
<div id="database-tab-tablelist">
|
||||
<div id="tab-tablelist-table">
|
||||
</div>
|
||||
<input type="button" id="tablelist-remove-table" value="選択テーブル削除">
|
||||
</div>
|
||||
<div id="database-tab-createtable">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<label for="createtable-name">テーブル名</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" id="createtable-name">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
主キー
|
||||
</td>
|
||||
<td>
|
||||
<label for="createtable-key-type">keyの型:</label>
|
||||
<select id="createtable-key-type">
|
||||
<optgroup label="組み込み型" id="createtable-key-type-builtin">
|
||||
</optgroup>
|
||||
<optgroup label="テーブル" id="createtable-key-type-table">
|
||||
</optgroup>
|
||||
</select>
|
||||
<label for="createtable-key-index">keyのインデックス種類:</label>
|
||||
<select id="createtable-key-index">
|
||||
<option value="GRN_OBJ_TABLE_PAT_KEY">パトリシア木</option>
|
||||
<option value="GRN_OBJ_TABLE_HASH_KEY">ハッシュテーブル</option>
|
||||
<option value="GRN_OBJ_TABLE_NO_KEY">キーなし</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
フラグ
|
||||
</td>
|
||||
<td id="createtable-flags">
|
||||
<input type="checkbox" value="GRN_OBJ_PERSISTENT" checked>永続化</input>
|
||||
<input type="checkbox" value="GRN_OBJ_KEY_NORMALIZE">key文字列の正規化</input>
|
||||
<input type="checkbox" value="GRN_OBJ_KEY_WITH_SIS">key文字列のsuffix登録</input>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
valueの型
|
||||
</td>
|
||||
<td>
|
||||
<select id="createtable-value-type">
|
||||
<optgroup label="組み込み型" id="createtable-value-type-builtin">
|
||||
</optgroup>
|
||||
<optgroup label="テーブル" id="createtable-value-type-table">
|
||||
</optgroup>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
デフォルトトークナイザ
|
||||
</td>
|
||||
<td>
|
||||
<select id="createtable-default-tokenizer">
|
||||
<optgroup label="組み込み" id="createtable-default-tokenizer-builtin">
|
||||
</optgroup>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<input type="button" id="createtable-add-table" value="テーブル追加">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- table view -->
|
||||
<div id="table-tabs">
|
||||
<ul>
|
||||
<li><a href="#table-tab-recordlist" id="tab-recordlist-link">レコード一覧</a></li>
|
||||
<li><a href="#table-tab-columnlist" id="tab-columnlist-link">カラム一覧</a></li>
|
||||
<li><a href="#table-tab-createrecord" id="tab-createrecord-link">レコード作成</a></li>
|
||||
<li><a href="#table-tab-createcolumn">カラム作成</a></li>
|
||||
</ul>
|
||||
<div id="table-tab-recordlist">
|
||||
<input type="checkbox" id="table-tab-recordlist-full-checkbox" /><label for="table-tab-recordlist-full-checkbox">管理モード</label>
|
||||
<form id="tab-recordlist-form">
|
||||
<div id="table-tab-recordlist-form-simple">
|
||||
<label for="tab-recordlist-simplequery">検索クエリ: </label><input type="text" id="tab-recordlist-simplequery">
|
||||
<select id="tab-recordlist-simplequerytype">
|
||||
<option value="query" data-placeholder="例)column:@value">query</option>
|
||||
<option value="filter" data-placeholder="例)column == "value"">filter</option>
|
||||
</select>
|
||||
<input type="checkbox" id="tab-recordlist-incremental" /><label for="tab-recordlist-incremental" id="tab-recordlist-incremental-label">インクリメンタル検索</label>
|
||||
</div>
|
||||
<div id="table-tab-recordlist-form-full">
|
||||
<table>
|
||||
<tr><td>match_columns</td><td><input type="text" id="tab-recordlist-match_columns" /></td></tr>
|
||||
<tr><td>query</td><td><input type="text" id="tab-recordlist-query" /></td></tr>
|
||||
<tr><td>filter</td><td><input type="text" id="tab-recordlist-filter" /></td></tr>
|
||||
<tr><td>scorer</td><td><input type="text" id="tab-recordlist-scorer" /></td></tr>
|
||||
<tr><td>sortby</td><td><input type="text" id="tab-recordlist-sortby" /></td></tr>
|
||||
<tr><td>output_columns</td><td><input type="text" id="tab-recordlist-output_columns" /></td></tr>
|
||||
<tr><td>offset</td><td><input type="text" id="tab-recordlist-offset" /></td></tr>
|
||||
<tr><td>limit</td><td><input type="text" id="tab-recordlist-limit" /></td></tr>
|
||||
<tr><td>drilldown</td><td><input type="text" id="tab-recordlist-drilldown" /></td></tr>
|
||||
<tr><td>drilldown_sortby</td><td><input type="text" id="tab-recordlist-drilldown_sortby" /></td></tr>
|
||||
<tr><td>drilldown_output_columns</td><td><input type="text" id="tab-recordlist-drilldown_output_columns" /></td></tr>
|
||||
<tr><td>drilldown_offset</td><td><input type="text" id="tab-recordlist-drilldown_offset" /></td></tr>
|
||||
<tr><td>drilldown_limit</td><td><input type="text" id="tab-recordlist-drilldown_limit" /></td></tr>
|
||||
</table>
|
||||
</div>
|
||||
<input type="submit" id="tab-recordlist-submit" value="検索"/>
|
||||
</form>
|
||||
<div id="tab-recordlist-table">
|
||||
</div>
|
||||
<input type="button" id="recordlist-remove-record" value="選択レコード削除">
|
||||
</div>
|
||||
<div id="table-tab-columnlist">
|
||||
<div id="tab-columnlist-table">
|
||||
</div>
|
||||
<input type="button" id="columnlist-remove-column" value="選択カラム削除">
|
||||
</div>
|
||||
<div id="table-tab-createrecord">
|
||||
<table id="table-createrecord">
|
||||
</table>
|
||||
<input type="button" id="createrecord-add-record" value="レコード追加">
|
||||
</div>
|
||||
<div id="table-tab-createcolumn">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<label for="createcolumn-name">カラム名</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" id="createcolumn-name">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
設定
|
||||
</td>
|
||||
<td>
|
||||
<label for="createcolumn-type">型:</label>
|
||||
<select id="createcolumn-type">
|
||||
<optgroup label="組み込み型" id="createcolumn-type-builtin">
|
||||
</optgroup>
|
||||
<optgroup label="テーブル" id="createcolumn-type-table">
|
||||
</optgroup>
|
||||
</select>
|
||||
|
||||
<label for="createcolumn-source">テーブル型の場合カラム</label>
|
||||
<select id="createcolumn-source" disabled>
|
||||
</select>
|
||||
|
||||
<label for="createcolumn-column-type">カラム種別:</label>
|
||||
<select id="createcolumn-column-type">
|
||||
<option value="GRN_OBJ_COLUMN_SCALAR">スカラ</option>
|
||||
<option value="GRN_OBJ_COLUMN_VECTOR">ベクタ</option>
|
||||
<option value="GRN_OBJ_COLUMN_INDEX">転置インデックス</option>
|
||||
</select>
|
||||
|
||||
<label for="createcolumn-compress">圧縮:</label>
|
||||
<select id="createcolumn-compress">
|
||||
<option value="GRN_OBJ_COMPRESS_NONE">圧縮なし</option>
|
||||
<option value="GRN_OBJ_COMPRESS_ZLIB">zlib</option>
|
||||
<option value="GRN_OBJ_COMPRESS_LZO">lzo</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
フラグ
|
||||
</td>
|
||||
<td id="createcolumn-flags">
|
||||
<input type="checkbox" value="GRN_OBJ_PERSISTENT" checked>永続化</input>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
転置インデックス用フラグ
|
||||
</td>
|
||||
<td id="createcolumn-ii-flags">
|
||||
<input type="checkbox" value="GRN_OBJ_WITH_SECTION">段落情報を含める</input>
|
||||
<input type="checkbox" value="GRN_OBJ_WITH_WEIGHT">重みを含める</input>
|
||||
<input type="checkbox" value="GRN_OBJ_WITH_POSITION">位置情報を含める</input>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<input type="button" id="createcolumn-add-column" value="カラム追加">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- suggest view -->
|
||||
<div id="suggest-tabs">
|
||||
<ul>
|
||||
<li><a href="#suggest-tab-search">検索</a></li>
|
||||
</ul>
|
||||
<div id="suggest-tab-search">
|
||||
<form id="suggest-tab-search-form">
|
||||
<p>
|
||||
<label for="suggest-dataset">データセット: </label>
|
||||
<input type="text" id="suggest-dataset">
|
||||
</p>
|
||||
<label for="suggest-query">検索クエリ: </label>
|
||||
<input type="text" id="suggest-query">
|
||||
<input type="button" id="suggest-submit" value="検索" />
|
||||
</form>
|
||||
<div id="suggest-result-tabs">
|
||||
<ul>
|
||||
<li><a href="#suggest-result-tab-suggest">提案</a></li>
|
||||
<li><a href="#suggest-result-tab-complete">補完</a></li>
|
||||
<li><a href="#suggest-result-tab-correct">補正</a></li>
|
||||
</ul>
|
||||
<div id="suggest-result-tab-suggest">
|
||||
</div>
|
||||
<div id="suggest-result-tab-complete">
|
||||
</div>
|
||||
<div id="suggest-result-tab-correct">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div id="footer">
|
||||
Powered by <a href="http://jquery.com/">jQuery</a> and <a href="http://jqueryui.com/">jQuery UI</a>.
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
var admin = new GroongaAdmin();
|
||||
$(location.hash).click();
|
||||
$.ajaxSetup({
|
||||
timeout: 10000,
|
||||
cache: false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
1372
storage/mroonga/vendor/groonga/data/html/admin/js/groonga-admin.ja.js
vendored
Normal file
1372
storage/mroonga/vendor/groonga/data/html/admin/js/groonga-admin.js
vendored
Normal file
4
storage/mroonga/vendor/groonga/data/html/admin/js/jquery-1.7.2.min.js
vendored
Normal file
356
storage/mroonga/vendor/groonga/data/html/admin/js/jquery-ui-1.8.18.custom.min.js
vendored
Normal file
6
storage/mroonga/vendor/groonga/data/html/admin/js/jquery.flot-0.7.min.js
vendored
Normal file
22
storage/mroonga/vendor/groonga/data/html/admin/js/jquery.flot.license.txt
vendored
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
Copyright (c) 2007-2009 IOLA and Ole Laursen
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
files (the "Software"), to deal in the Software without
|
||||
restriction, including without limitation the rights to use,
|
||||
copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the
|
||||
Software is furnished to do so, subject to the following
|
||||
conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
||||
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||
OTHER DEALINGS IN THE SOFTWARE.
|
||||
34
storage/mroonga/vendor/groonga/data/html/files.am
vendored
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
nobase_dist_html_DATA = \
|
||||
admin/css/groonga-admin.css \
|
||||
admin/css/redmond/images/ui-bg_flat_0_aaaaaa_40x100.png \
|
||||
admin/css/redmond/images/ui-bg_flat_55_fbec88_40x100.png \
|
||||
admin/css/redmond/images/ui-bg_glass_75_d0e5f5_1x400.png \
|
||||
admin/css/redmond/images/ui-bg_glass_85_dfeffc_1x400.png \
|
||||
admin/css/redmond/images/ui-bg_glass_95_fef1ec_1x400.png \
|
||||
admin/css/redmond/images/ui-bg_gloss-wave_55_5c9ccc_500x100.png \
|
||||
admin/css/redmond/images/ui-bg_inset-hard_100_f5f8f9_1x100.png \
|
||||
admin/css/redmond/images/ui-bg_inset-hard_100_fcfdfd_1x100.png \
|
||||
admin/css/redmond/images/ui-icons_217bc0_256x240.png \
|
||||
admin/css/redmond/images/ui-icons_2e83ff_256x240.png \
|
||||
admin/css/redmond/images/ui-icons_469bdd_256x240.png \
|
||||
admin/css/redmond/images/ui-icons_6da8d5_256x240.png \
|
||||
admin/css/redmond/images/ui-icons_cd0a0a_256x240.png \
|
||||
admin/css/redmond/images/ui-icons_d8e7f3_256x240.png \
|
||||
admin/css/redmond/images/ui-icons_f9bd01_256x240.png \
|
||||
admin/css/redmond/jquery-ui-1.8.18.custom.css \
|
||||
admin/favicon.ico \
|
||||
admin/favicon.png \
|
||||
admin/favicon.svg \
|
||||
admin/images/groonga.png \
|
||||
admin/images/groonga.svg \
|
||||
admin/images/loading.gif \
|
||||
admin/index.html \
|
||||
admin/index.ja.html \
|
||||
admin/js/groonga-admin.ja.js \
|
||||
admin/js/groonga-admin.js \
|
||||
admin/js/jquery-1.7.2.min.js \
|
||||
admin/js/jquery-ui-1.8.18.custom.min.js \
|
||||
admin/js/jquery.flot-0.7.min.js \
|
||||
admin/js/jquery.flot.license.txt \
|
||||
$(NULL)
|
||||
|
||||
17
storage/mroonga/vendor/groonga/data/html/update-files.sh
vendored
Executable file
|
|
@ -0,0 +1,17 @@
|
|||
#!/bin/sh
|
||||
|
||||
list_paths()
|
||||
{
|
||||
variable_name=$1
|
||||
echo "$variable_name = \\"
|
||||
sort | \
|
||||
sed \
|
||||
-e 's,^,\t,' \
|
||||
-e 's,$, \\,'
|
||||
echo "\t\$(NULL)"
|
||||
echo
|
||||
}
|
||||
|
||||
find "admin" -type f | \
|
||||
sort | \
|
||||
list_paths "nobase_dist_html_DATA"
|
||||
2
storage/mroonga/vendor/groonga/data/images/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
SUBDIRS = \
|
||||
logo
|
||||
22
storage/mroonga/vendor/groonga/data/images/logo/Makefile.am
vendored
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
include files.am
|
||||
|
||||
logodir = $(pkgdatadir)/images/logo
|
||||
logo_DATA = $(image_files)
|
||||
|
||||
EXTRA_DIST = \
|
||||
$(logo_DATA) \
|
||||
update-files.sh
|
||||
|
||||
SUFFIXES =
|
||||
if WITH_INKSCAPE
|
||||
SUFFIXES += .svg .png
|
||||
.svg.png:
|
||||
$(INKSCAPE) --export-dpi 90 --export-png $@ $<
|
||||
endif
|
||||
|
||||
$(srcdir)/files.am: $(srcdir)/update-files.sh
|
||||
(cd $(srcdir) && ./update-files.sh) > $(srcdir)/files.am
|
||||
|
||||
update-files:
|
||||
rm $(srcdir)/files.am
|
||||
$(MAKE) $(srcdir)/files.am
|
||||
53
storage/mroonga/vendor/groonga/data/images/logo/files.am
vendored
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
image_files = \
|
||||
groonga-icon-foreground-white.png \
|
||||
groonga-icon-foreground-white.svg \
|
||||
groonga-icon-full-size.png \
|
||||
groonga-icon-full-size.svg \
|
||||
groonga-icon.png \
|
||||
groonga-icon.svg \
|
||||
groonga-logo-foreground-white.png \
|
||||
groonga-logo-foreground-white.svg \
|
||||
groonga-logo.png \
|
||||
groonga-logo.svg \
|
||||
groonga-powered-by-banner-bar-foreground-white.png \
|
||||
groonga-powered-by-banner-bar-foreground-white.svg \
|
||||
groonga-powered-by-banner-bar.png \
|
||||
groonga-powered-by-banner-bar.svg \
|
||||
groonga-powered-by-banner-foreground-white.png \
|
||||
groonga-powered-by-banner-foreground-white.svg \
|
||||
groonga-powered-by-banner-large.png \
|
||||
groonga-powered-by-banner-large.svg \
|
||||
groonga-powered-by-banner.png \
|
||||
groonga-powered-by-banner.svg \
|
||||
mroonga-icon-foreground-white.png \
|
||||
mroonga-icon-foreground-white.svg \
|
||||
mroonga-icon-full-size.png \
|
||||
mroonga-icon-full-size.svg \
|
||||
mroonga-icon.png \
|
||||
mroonga-icon.svg \
|
||||
mroonga-logo-foreground-white.png \
|
||||
mroonga-logo-foreground-white.svg \
|
||||
mroonga-logo.png \
|
||||
mroonga-logo.svg \
|
||||
nroonga-icon-foreground-white.png \
|
||||
nroonga-icon-foreground-white.svg \
|
||||
nroonga-icon-full-size.png \
|
||||
nroonga-icon-full-size.svg \
|
||||
nroonga-icon.png \
|
||||
nroonga-icon.svg \
|
||||
nroonga-logo-foreground-white.png \
|
||||
nroonga-logo-foreground-white.svg \
|
||||
nroonga-logo.png \
|
||||
nroonga-logo.svg \
|
||||
rroonga-icon-foreground-white.png \
|
||||
rroonga-icon-foreground-white.svg \
|
||||
rroonga-icon-full-size.png \
|
||||
rroonga-icon-full-size.svg \
|
||||
rroonga-icon.png \
|
||||
rroonga-icon.svg \
|
||||
rroonga-logo-foreground-white.png \
|
||||
rroonga-logo-foreground-white.svg \
|
||||
rroonga-logo.png \
|
||||
rroonga-logo.svg \
|
||||
$(NULL)
|
||||
|
||||
BIN
storage/mroonga/vendor/groonga/data/images/logo/groonga-icon-foreground-white.png
vendored
Normal file
|
After Width: | Height: | Size: 2.2 KiB |
118
storage/mroonga/vendor/groonga/data/images/logo/groonga-icon-foreground-white.svg
vendored
Normal file
|
|
@ -0,0 +1,118 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="60.000706"
|
||||
height="60.001022"
|
||||
id="svg5342"
|
||||
version="1.1"
|
||||
inkscape:version="0.48.1 r9760"
|
||||
sodipodi:docname="新規ドキュメント 41">
|
||||
<defs
|
||||
id="defs5344">
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#SVGID_9_"
|
||||
id="linearGradient5521"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="470.15039"
|
||||
y1="437.05859"
|
||||
x2="470.15039"
|
||||
y2="497.05859" />
|
||||
<linearGradient
|
||||
id="SVGID_9_"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="470.15039"
|
||||
y1="437.05859"
|
||||
x2="470.15039"
|
||||
y2="497.05859">
|
||||
<stop
|
||||
offset="0"
|
||||
style="stop-color:#3FA9F5"
|
||||
id="stop4050" />
|
||||
<stop
|
||||
offset="1"
|
||||
style="stop-color:#0071BC"
|
||||
id="stop4052" />
|
||||
</linearGradient>
|
||||
<linearGradient
|
||||
y2="497.05859"
|
||||
x2="470.15039"
|
||||
y1="437.05859"
|
||||
x1="470.15039"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
id="linearGradient5566"
|
||||
xlink:href="#SVGID_9_"
|
||||
inkscape:collect="always" />
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#SVGID_9_"
|
||||
id="linearGradient5599"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="470.15039"
|
||||
y1="437.05859"
|
||||
x2="470.15039"
|
||||
y2="497.05859" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="1.979899"
|
||||
inkscape:cx="61.872887"
|
||||
inkscape:cy="42.401151"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
fit-margin-top="0"
|
||||
fit-margin-left="0"
|
||||
fit-margin-right="0"
|
||||
fit-margin-bottom="0"
|
||||
inkscape:window-width="902"
|
||||
inkscape:window-height="442"
|
||||
inkscape:window-x="2773"
|
||||
inkscape:window-y="302"
|
||||
inkscape:window-maximized="0" />
|
||||
<metadata
|
||||
id="metadata5347">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="レイヤー 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-343.75609,-530.41738)">
|
||||
<g
|
||||
id="g5587">
|
||||
<polygon
|
||||
style="fill:url(#linearGradient5599)"
|
||||
id="polygon4054"
|
||||
points="440.15,437.059 440.15,497.059 466.012,497.059 500.15,497.059 500.15,462.92 500.15,437.059 "
|
||||
transform="translate(-96.393911,93.359403)" />
|
||||
<path
|
||||
style="fill:#ffffff"
|
||||
inkscape:connector-curvature="0"
|
||||
id="path4107"
|
||||
d="m 397.29009,567.3004 c 7.502,-7.505 9.8,-20.401 -0.335,-30.538 -4.224,-4.222 -9.514,-6.337 -14.8,-6.345 h -0.005 c -5.286,-0.007 -10.567,2.093 -14.774,6.299 -2.522,2.52 -4.434,5.76 -5.428,9.33 -6.49,-0.099 -13.001,2.411 -18.191,7.53 v 36.479 c 0.114,0.121 0.227,0.242 0.344,0.361 h 25.518 11.027 c 4.434,-4.717 7.233,-11.018 7.295,-17.672 3.385,-0.898 6.606,-2.7 9.349,-5.444 z m -13.748,-2.759 c -1.121,1.873 -0.997,2.089 -0.949,5.602 0.062,3.979 -1.437,8.102 -5.189,11.854 -5.736,5.737 -16.326,7.017 -24.119,-0.776 -6.139,-6.14 -9.021,-16.475 -0.84,-24.658 3.038,-3.034 7.406,-4.827 11.998,-4.745 3.193,0.055 3.564,0.174 5.621,-0.76 2.058,-0.938 1.166,-3.019 2.396,-6.692 0.6,-1.792 1.666,-3.551 3.332,-5.224 4.451,-4.448 12.643,-5.469 18.643,0.531 4.887,4.887 6.96,12.677 0.572,19.065 -1.441,1.444 -3.284,2.509 -5.319,3.087 -3.266,0.937 -5.023,0.838 -6.146,2.716 z" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 4.1 KiB |
BIN
storage/mroonga/vendor/groonga/data/images/logo/groonga-icon-full-size.png
vendored
Normal file
|
After Width: | Height: | Size: 6.7 KiB |
97
storage/mroonga/vendor/groonga/data/images/logo/groonga-icon-full-size.svg
vendored
Normal file
|
|
@ -0,0 +1,97 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="199.804"
|
||||
height="200.85736"
|
||||
id="svg3635"
|
||||
version="1.1"
|
||||
inkscape:version="0.48.3.1 r9886"
|
||||
sodipodi:docname="groonga-icon-full-size.svg"
|
||||
inkscape:export-filename="groonga-icon-full-size.png"
|
||||
inkscape:export-xdpi="90"
|
||||
inkscape:export-ydpi="90">
|
||||
<defs
|
||||
id="defs3637">
|
||||
<linearGradient
|
||||
gradientTransform="translate(-419.62671,208.8676)"
|
||||
id="SVGID_1_"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="223.6167"
|
||||
y1="76.3564"
|
||||
x2="223.6167"
|
||||
y2="137.38029">
|
||||
<stop
|
||||
offset="0"
|
||||
style="stop-color:#3FA9F5"
|
||||
id="stop160" />
|
||||
<stop
|
||||
offset="1"
|
||||
style="stop-color:#0071BC"
|
||||
id="stop162" />
|
||||
</linearGradient>
|
||||
<linearGradient
|
||||
inkscape:collect="always"
|
||||
xlink:href="#SVGID_1_"
|
||||
id="linearGradient2994"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
gradientTransform="matrix(3.0240925,0,0,3.0240925,-289.39052,88.167588)"
|
||||
x1="223.6167"
|
||||
y1="76.3564"
|
||||
x2="223.6167"
|
||||
y2="137.38029" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="1.4"
|
||||
inkscape:cx="144.78679"
|
||||
inkscape:cy="33.072478"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
fit-margin-top="5"
|
||||
fit-margin-left="5"
|
||||
fit-margin-right="5"
|
||||
fit-margin-bottom="5"
|
||||
inkscape:window-width="902"
|
||||
inkscape:window-height="705"
|
||||
inkscape:window-x="2174"
|
||||
inkscape:window-y="122"
|
||||
inkscape:window-maximized="0" />
|
||||
<metadata
|
||||
id="metadata3640">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="レイヤー 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-286.94516,-317.99663)">
|
||||
<path
|
||||
style="fill:url(#linearGradient2994)"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 379.72928,340.66117 c -7.06731,7.06429 -12.426,16.1547 -15.21724,26.1705 -18.37438,-0.28124 -36.80623,6.87377 -51.43075,21.5013 -24.62215,24.61914 -32.27916,69.29104 2.01708,103.58424 28.8559,28.85891 71.95223,29.29438 100.23355,1.00702 13.36951,-13.37859 21.88233,-31.77111 22.0668,-51.22813 9.49565,-2.52511 18.52257,-7.58139 26.21888,-15.26864 21.03559,-21.04466 27.47691,-57.2128 -0.94049,-85.63625 -23.68772,-23.67865 -59.35084,-23.73005 -82.94783,-0.13004 z m 77.4833,61.75802 c -4.03716,4.04623 -9.20837,7.028 -14.91483,8.66101 -9.15393,2.62188 -14.0832,2.34972 -17.23128,7.60558 -3.14808,5.24681 -2.80031,5.86675 -2.66121,15.70714 0.16935,11.15588 -4.03111,22.72001 -14.55495,33.2499 -16.08818,16.08212 -45.78476,19.6687 -67.63685,-2.18037 -17.21617,-17.21918 -25.29654,-46.20209 -2.35275,-69.14587 8.51585,-8.50678 20.76342,-13.53887 33.64001,-13.31207 8.95434,0.16028 9.99765,0.48689 15.76156,-2.12895 5.773,-2.62794 3.27207,-8.46443 6.71955,-18.7645 1.68139,-5.01999 4.67221,-9.96136 9.35049,-14.6487 12.4774,-12.47741 35.44539,-15.33821 52.27144,1.48483 13.70821,13.71425 19.52052,35.5603 1.60882,53.472 z"
|
||||
id="path164" />
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.8 KiB |
BIN
storage/mroonga/vendor/groonga/data/images/logo/groonga-icon.png
vendored
Normal file
|
After Width: | Height: | Size: 2.2 KiB |
93
storage/mroonga/vendor/groonga/data/images/logo/groonga-icon.svg
vendored
Normal file
|
|
@ -0,0 +1,93 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="59.99931"
|
||||
height="59.999016"
|
||||
id="svg5041"
|
||||
version="1.1"
|
||||
inkscape:version="0.48.1 r9760"
|
||||
sodipodi:docname="新規ドキュメント 28">
|
||||
<defs
|
||||
id="defs5043">
|
||||
<linearGradient
|
||||
id="SVGID_13_"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="147.7168"
|
||||
y1="437.05859"
|
||||
x2="147.7168"
|
||||
y2="505.11819">
|
||||
<stop
|
||||
offset="0"
|
||||
style="stop-color:#3FA9F5"
|
||||
id="stop4080" />
|
||||
<stop
|
||||
offset="1"
|
||||
style="stop-color:#0071BC"
|
||||
id="stop4082" />
|
||||
</linearGradient>
|
||||
<linearGradient
|
||||
gradientTransform="translate(283.71192,-26.123877)"
|
||||
y2="505.11819"
|
||||
x2="147.7168"
|
||||
y1="437.05859"
|
||||
x1="147.7168"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
id="linearGradient5070"
|
||||
xlink:href="#SVGID_13_"
|
||||
inkscape:collect="always" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="1.979899"
|
||||
inkscape:cx="-109.40067"
|
||||
inkscape:cy="43.539451"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
fit-margin-top="0"
|
||||
fit-margin-left="0"
|
||||
fit-margin-right="0"
|
||||
fit-margin-bottom="0"
|
||||
inkscape:window-width="902"
|
||||
inkscape:window-height="442"
|
||||
inkscape:window-x="1928"
|
||||
inkscape:window-y="52"
|
||||
inkscape:window-maximized="0" />
|
||||
<metadata
|
||||
id="metadata5046">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="レイヤー 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-401.42892,-410.9341)">
|
||||
<path
|
||||
style="fill:url(#linearGradient5070)"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 454.96192,447.81712 c 7.502,-7.505 9.799,-20.401 -0.335,-30.538 -4.223,-4.222 -9.513,-6.337 -14.799,-6.345 h -0.005 c -5.286,-0.007 -10.568,2.093 -14.775,6.299 -2.522,2.52 -4.433,5.76 -5.428,9.33 -6.49,-0.099 -13.001,2.411 -18.191,7.53 v 36.48 c 0.114,0.12 0.227,0.241 0.344,0.36 h 25.518 11.027 c 4.434,-4.717 7.234,-11.018 7.295,-17.672 3.385,-0.898 6.606,-2.7 9.349,-5.444 z m -13.748,-2.759 c -1.122,1.873 -0.998,2.089 -0.95,5.602 0.062,3.979 -1.436,8.102 -5.188,11.854 -5.737,5.737 -16.327,7.017 -24.119,-0.776 -6.14,-6.14 -9.021,-16.475 -0.84,-24.658 3.038,-3.034 7.405,-4.827 11.998,-4.745 3.193,0.055 3.564,0.174 5.621,-0.76 2.058,-0.938 1.166,-3.019 2.396,-6.692 0.6,-1.792 1.667,-3.551 3.333,-5.224 4.451,-4.448 12.642,-5.469 18.642,0.531 4.887,4.887 6.96,12.677 0.573,19.065 -1.442,1.444 -3.285,2.509 -5.32,3.087 -3.265,0.937 -5.023,0.838 -6.146,2.716 z"
|
||||
id="path4084" />
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 3.4 KiB |
BIN
storage/mroonga/vendor/groonga/data/images/logo/groonga-logo-foreground-white.png
vendored
Normal file
|
After Width: | Height: | Size: 7.2 KiB |
108
storage/mroonga/vendor/groonga/data/images/logo/groonga-logo-foreground-white.svg
vendored
Normal file
|
|
@ -0,0 +1,108 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="232.18001"
|
||||
height="73.112274"
|
||||
id="svg4711"
|
||||
version="1.1"
|
||||
inkscape:version="0.48.1 r9760"
|
||||
sodipodi:docname="新規ドキュメント 16">
|
||||
<defs
|
||||
id="defs4713">
|
||||
<linearGradient
|
||||
gradientTransform="translate(-433.94514,340.29617)"
|
||||
id="SVGID_5_"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="589.36517"
|
||||
y1="78"
|
||||
x2="589.36517"
|
||||
y2="143.0079">
|
||||
<stop
|
||||
offset="0"
|
||||
style="stop-color:#3FA9F5"
|
||||
id="stop3978" />
|
||||
<stop
|
||||
offset="1"
|
||||
style="stop-color:#0071BC"
|
||||
id="stop3980" />
|
||||
</linearGradient>
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#000000"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="1"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="1.4"
|
||||
inkscape:cx="249.78391"
|
||||
inkscape:cy="36.547406"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
fit-margin-top="5"
|
||||
fit-margin-left="5"
|
||||
fit-margin-right="5"
|
||||
fit-margin-bottom="5"
|
||||
inkscape:window-width="902"
|
||||
inkscape:window-height="442"
|
||||
inkscape:window-x="2119"
|
||||
inkscape:window-y="331"
|
||||
inkscape:window-maximized="0" />
|
||||
<metadata
|
||||
id="metadata4716">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="レイヤー 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-61.052857,-412.9489)">
|
||||
<path
|
||||
style="fill:#ffffff"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 122.70286,437.76317 c -1.337,-0.29 -2.28,-0.448 -3.441,-0.448 -2.848,0 -5.33,0.831 -7.393,2.468 -0.09,0.06 -0.191,0.14 -0.302,0.245 -0.23,0.197 -0.452,0.406 -0.669,0.621 -1.477,1.314 -2.759,1.952 -2.759,-1.235 v -0.666 c 0,-0.404 -0.327,-0.732 -0.732,-0.732 h -2.1 c -0.2,0 -0.389,0.081 -0.527,0.223 -0.138,0.143 -0.212,0.335 -0.206,0.532 0.106,3.333 0.215,6.778 0.215,9.621 v 18.75 c 0,0.404 0.328,0.731 0.732,0.731 h 2.209 c 0.403,0 0.732,-0.328 0.732,-0.731 v -9.914 c 0,-1.37 0.107,-3.805 0.31,-4.813 1.568,-7.797 4.982,-11.588 10.435,-11.588 0.979,0 1.88,0.165 2.874,0.363 0.047,0.011 0.095,0.015 0.143,0.015 0.148,0 0.294,-0.045 0.417,-0.131 0.162,-0.113 0.273,-0.288 0.307,-0.484 l 0.322,-1.994 c 0.062,-0.384 -0.187,-0.752 -0.567,-0.833 z"
|
||||
id="path3967" />
|
||||
<path
|
||||
style="fill:#ffffff"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 211.74986,439.35517 c -2.513,-1.774 -5.294,-2.04 -6.727,-2.04 -2.911,0 -5.648,0.912 -7.821,2.495 -0.005,0.004 -0.011,0.005 -0.015,0.009 -1.006,0.648 -2.627,0.909 -2.617,-0.625 v -0.021 c 0,-0.107 -0.005,-0.199 -0.014,-0.277 l -0.009,-0.182 c -0.018,-0.391 -0.341,-0.698 -0.731,-0.698 h -2.102 c -0.202,0 -0.396,0.084 -0.534,0.232 -0.139,0.148 -0.21,0.347 -0.195,0.549 0.152,2.28 0.212,4.171 0.212,6.524 v 21.821 c 0,0.404 0.33,0.731 0.733,0.731 h 2.209 c 0.404,0 0.731,-0.328 0.731,-0.731 v -17.511 c 0,-0.813 0.253,-1.761 0.49,-2.377 0.005,-0.008 0.007,-0.018 0.01,-0.026 1.044,-3.042 4.223,-6.12 8.417,-6.475 3.236,0.002 8.326,2.358 9.024,8.226 0.016,0.15 0.03,0.299 0.041,0.444 0.005,0.049 0.008,0.099 0.013,0.149 0.005,0.07 0.009,0.139 0.014,0.209 0.009,0.19 0.015,0.384 0.015,0.582 0,0.335 0.005,0.638 0.018,0.911 v 15.869 c 0,0.404 0.326,0.731 0.73,0.731 h 2.21 c 0.403,0 0.732,-0.328 0.732,-0.731 v -16.272 c 0.001,-5.375 -1.627,-9.248 -4.834,-11.516 z"
|
||||
id="path3969" />
|
||||
<path
|
||||
style="fill:#ffffff"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 287.97386,464.69717 c -0.133,-0.113 -0.301,-0.174 -0.474,-0.174 -0.039,0 -0.079,0.003 -0.118,0.01 -0.588,0.098 -0.964,0.098 -1.444,0.098 -1.147,0 -2.177,-0.335 -2.177,-4.387 v -9.913 c 0,-2.343 -0.18,-5.368 -1.583,-7.972 -1.824,-3.382 -5.181,-5.098 -9.979,-5.098 -2.475,0 -6.218,0.516 -9.99,2.974 -0.313,0.205 -0.424,0.615 -0.252,0.949 l 0.862,1.67 c 0.098,0.189 0.272,0.326 0.479,0.375 0.058,0.014 0.116,0.021 0.174,0.021 0.15,0 0.296,-0.047 0.422,-0.135 2.314,-1.639 5.188,-2.504 8.306,-2.504 3.995,0 6.004,1.854 7,3.939 l 0,0 c 1.002,2.221 -0.563,4.404 -2.286,4.584 -0.084,0.005 -0.169,0.008 -0.253,0.013 -0.015,0 -0.027,10e-4 -0.043,0 -0.055,-0.001 -0.101,0.003 -0.143,0.009 -10.979,0.626 -16.537,4.313 -16.537,10.98 0,2.027 0.801,4.057 2.201,5.569 1.235,1.333 3.56,2.921 7.637,2.921 3.471,0 6.27,-1.112 8.324,-2.472 0.061,-0.031 0.131,-0.076 0.211,-0.141 0.021,-0.017 0.044,-0.031 0.064,-0.048 0.127,-0.088 0.257,-0.177 0.377,-0.268 1.277,-0.825 1.97,-0.351 2.623,0.504 0.002,0.002 0.006,0.005 0.008,0.007 0.839,1.14 2.162,1.718 3.963,1.718 0.847,0 1.59,-0.094 2.343,-0.294 0.322,-0.085 0.544,-0.375 0.544,-0.707 v -1.67 c 0,-0.214 -0.096,-0.419 -0.259,-0.558 z m -18.252,0.527 c -3.042,0 -6.111,-1.723 -6.111,-5.572 0,-4.863 5.936,-6.58 12.166,-7.043 2.32,-0.043 4.098,2.162 4.313,4.575 v 0.989 c -0.063,0.647 -0.246,1.289 -0.569,1.888 -0.161,0.263 -0.354,0.556 -0.588,0.864 -0.04,0.047 -0.076,0.093 -0.104,0.134 -1.442,1.848 -4.223,4.165 -9.107,4.165 z"
|
||||
id="path3971" />
|
||||
<path
|
||||
style="fill:#ffffff"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 93.993857,438.01517 h -2.048 c -0.393,0 -0.716,0.311 -0.731,0.703 -0.066,1.618 -0.892,1.836 -2.703,0.766 -0.01,-0.006 -0.017,-0.014 -0.026,-0.019 -0.179,-0.119 -0.362,-0.231 -0.546,-0.339 -0.011,-0.007 -0.021,-0.012 -0.032,-0.02 -0.087,-0.059 -0.17,-0.104 -0.245,-0.14 -1.981,-1.096 -4.305,-1.65 -6.922,-1.65 -3.739,0 -7.429,1.548 -10.123,4.25 -2.083,2.087 -4.565,5.826 -4.565,11.784 0,3.818 1.349,7.413 3.793,10.122 2.595,2.875 6.234,4.458 10.248,4.458 3.111,0 5.514,-0.819 7.336,-1.897 0.003,-0.002 0.008,-0.003 0.011,-0.005 1.953,-0.873 3.603,-2.182 3.136,2.232 -0.876,5.678 -4.518,8.765 -10.482,8.765 -4.176,0 -7.309,-1.404 -9.202,-2.583 -0.118,-0.072 -0.253,-0.11 -0.388,-0.11 -0.061,0 -0.122,0.008 -0.183,0.023 -0.192,0.049 -0.357,0.176 -0.456,0.35 l -0.971,1.725 c -0.188,0.336 -0.084,0.761 0.238,0.972 2.853,1.863 6.908,2.975 10.854,2.975 2.69,0 9.293,-0.625 12.494,-6.412 1.385,-2.481 2.03,-5.968 2.03,-10.968 v -17.457 c 0,-2.474 0.069,-4.679 0.214,-6.738 0.015,-0.202 -0.055,-0.402 -0.194,-0.549 -0.141,-0.153 -0.334,-0.238 -0.537,-0.238 z m -16.892,26.028 c -0.605,-0.24 -7.608,-3.216 -7.015,-11.811 0.554,-7.946 5.725,-10.459 6.519,-10.798 1.279,-0.5 2.702,-0.769 4.241,-0.769 1.665,0 3.113,0.327 4.354,0.873 6.848,3.871 7.696,16.453 0.886,21.467 -1.592,0.999 -3.438,1.573 -5.346,1.573 -1.343,0 -2.553,-0.194 -3.639,-0.535 z"
|
||||
id="path3973" />
|
||||
<path
|
||||
style="fill:#ffffff"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 251.84086,438.01517 h -2.047 c -0.392,0 -0.716,0.311 -0.731,0.703 -0.064,1.618 -0.892,1.836 -2.701,0.766 -0.011,-0.005 -0.02,-0.014 -0.028,-0.019 -0.179,-0.119 -0.362,-0.231 -0.547,-0.339 -0.01,-0.008 -0.02,-0.014 -0.031,-0.02 -0.087,-0.059 -0.168,-0.104 -0.243,-0.139 -1.982,-1.097 -4.308,-1.651 -6.925,-1.651 -3.739,0 -7.428,1.548 -10.121,4.25 -2.082,2.087 -4.564,5.826 -4.564,11.784 0,3.818 1.347,7.413 3.791,10.122 2.597,2.875 6.233,4.458 10.249,4.458 3.11,0 5.514,-0.819 7.335,-1.897 0.004,-0.002 0.007,-0.003 0.012,-0.005 1.953,-0.874 3.602,-2.183 3.134,2.233 -0.875,5.678 -4.518,8.764 -10.48,8.764 -4.176,0 -7.31,-1.404 -9.204,-2.583 -0.116,-0.072 -0.251,-0.11 -0.388,-0.11 -0.06,0 -0.123,0.008 -0.182,0.023 -0.192,0.049 -0.356,0.176 -0.456,0.35 l -0.968,1.725 c -0.19,0.336 -0.086,0.761 0.237,0.972 2.853,1.863 6.909,2.975 10.852,2.975 2.689,0 9.294,-0.625 12.493,-6.412 1.385,-2.481 2.031,-5.968 2.031,-10.968 v -17.457 c 0,-2.474 0.07,-4.679 0.216,-6.738 0.013,-0.202 -0.058,-0.402 -0.196,-0.549 -0.14,-0.153 -0.334,-0.238 -0.538,-0.238 z m -16.892,26.028 c -0.604,-0.24 -7.607,-3.216 -7.011,-11.811 0.549,-7.94 5.715,-10.455 6.518,-10.798 1.276,-0.5 2.698,-0.769 4.24,-0.769 1.663,0 3.112,0.327 4.354,0.873 6.845,3.871 7.696,16.453 0.883,21.467 -1.592,1 -3.437,1.573 -5.346,1.573 -1.341,0 -2.551,-0.194 -3.638,-0.535 z"
|
||||
id="path3975" />
|
||||
<path
|
||||
style="fill:url(#SVGID_5_)"
|
||||
inkscape:connector-curvature="0"
|
||||
d="m 153.06686,423.79017 c -2.338,2.336 -4.11,5.342 -5.031,8.654 -6.076,-0.093 -12.172,2.273 -17.008,7.11 -8.143,8.141 -10.674,22.913 0.668,34.253 9.542,9.543 23.793,9.687 33.144,0.333 4.422,-4.424 7.237,-10.506 7.298,-16.94 3.14,-0.835 6.125,-2.507 8.67,-5.049 6.957,-6.959 9.085,-18.919 -0.311,-28.318 -7.835,-7.83 -19.628,-7.847 -27.43,-0.043 z m 25.622,20.422 c -1.335,1.338 -3.046,2.324 -4.934,2.864 -3.026,0.867 -4.655,0.777 -5.696,2.515 -1.042,1.735 -0.925,1.94 -0.881,5.194 0.056,3.689 -1.332,7.513 -4.813,10.995 -5.319,5.318 -15.139,6.504 -22.366,-0.721 -5.692,-5.694 -8.363,-15.278 -0.776,-22.865 2.816,-2.813 6.867,-4.477 11.123,-4.402 2.961,0.053 3.306,0.161 5.213,-0.704 1.907,-0.869 1.082,-2.799 2.222,-6.205 0.557,-1.66 1.544,-3.294 3.093,-4.844 4.125,-4.126 11.721,-5.072 17.284,0.491 4.532,4.535 6.456,11.759 0.531,17.682 z"
|
||||
id="path3982" />
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 9.3 KiB |